make check: avoid an error when no .git dir present.
[gnulib.git] / ChangeLog
1 2010-04-24  Ian Beckwith  <ianb@erislabs.net>
2
3         make check: avoid an error when no .git dir present.
4         * Makefile (sc_prefer_ac_check_funcs_once): Don't run git grep
5         if .git directory is not present (e.g. in stable snapshot tarballs).
6
7 2010-04-24  Bruno Haible  <bruno@clisp.org>
8
9         Avoid a gcc warning.
10         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Pass argument
11         of correct type for %08lx directive.
12         Reported by Eric Blake.
13
14 2010-04-24  Bruno Haible  <bruno@clisp.org>
15
16         vasnprintf: Correct errno value in case of out-of-memory.
17         * lib/vasnprintf.c (VASNPRINTF): Set errno to 0 before calling SNPRINTF
18         or sprintf. Use the errno value from SNPRINTF or sprintf.
19         Reported by Ian Beckwith <ianb@erislabs.net>.
20
21 2010-04-24  Bruno Haible  <bruno@clisp.org>
22
23         ansi-c++-opt: Find correct compiler when cross-compiling.
24         * m4/ansi-c++.m4 (gl_PROG_ANSI_CXX): Use AC_CHECK_TOOLS instead of
25         AC_CHECK_PROGS.
26         Reported by Simon Josefsson.
27
28 2010-04-24  Giuseppe Scrivano  <gscrivano@gnu.org>
29
30         vc-list-files: Add support for subversion
31         * build-aux/vc-list-files: Use "svn list" to generate the list of
32         files controlled by subversion.
33
34 2010-04-23  Jim Meyering  <meyering@redhat.com>
35
36         vc-list-files tests: convert to use init.sh
37         * tests/test-vc-list-files-cvs.sh: Invoke "$srcdir/init.sh" and
38         path_prepend_.
39         Use Exit, not exit.
40         Use skip_ rather than open coding it.
41         Remove trap set-up and compare definitions.
42         * tests/test-vc-list-files-git.sh: Likewise.
43         * modules/vc-list-files-tests (Files): Add tests/init.sh.
44
45 2010-04-22  Simon Josefsson  <simon@josefsson.org>
46
47         * top/maint.mk (sc_prohibit_backup_files): Prohibit checked in
48         backup files.
49
50 2010-04-21  Simon Josefsson  <simon@josefsson.org>
51
52         * tests/test-vasprintf.c (test_vasprintf, test_asprintf): Test %08lx.
53
54 2010-04-20  Eric Blake  <eblake@redhat.com>
55
56         tests: be robust to ignored SIGPIPE
57         * tests/test-select-in.sh: Consume all output.
58         * tests/test-lseek.sh: Check correct exit status, while avoiding
59         EPIPE.
60
61 2010-04-20  Simon Josefsson  <simon@josefsson.org>
62             Bruno Haible  <bruno@clisp.org>
63
64         visibility: Don't use -fvisibility if it leads to a warning.
65         * m4/visibility.m4 (gl_VISIBILITY): Check whether -Werror is usable. If
66         yes, don't pretend that visibility works if it leads to a warning.
67         Reported by Mike Gran <spk121@yahoo.com>.
68
69 2010-04-20  Andreas Gruenbacher  <agruen@suse.de>
70
71         * build-aux/bootstrap: Use "git -h" for testing for supported options
72         instead of "git --help".  The short-form option only shows a summary,
73         and doesn't layout the full man page.  Grep for the full option name
74         in the summary, too.
75
76 2010-04-19  Bruno Haible  <bruno@clisp.org>
77
78         relocatable: Drop the need to define RELOCATABLE_STRIP in Makefile.am.
79         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Set RELOCATABLE_STRIP.
80         * doc/relocatable-maint.texi (Supporting Relocation): Remove the
81         mention of RELOCATABLE_STRIP.
82         Reported by Sylvain Beucler <beuc@beuc.net>.
83
84 2010-04-19  Bruno Haible  <bruno@clisp.org>
85
86         * lib/diffseq.h: Fix typo in comment.
87         Reported by Eric Blake.
88
89 2010-04-19  Bruno Haible  <bruno@clisp.org>
90
91         ioctl: Move autoconf macro to a .m4 file.
92         * m4/ioctl.m4: New file, extracted from modules/ioctl.
93         * modules/ioctl (Files): Add it.
94         (configure.ac): Simply invoke gl_FUNC_IOCTL.
95         Reported by Ian Beckwith <ianb@erislabs.net>.
96
97 2010-04-18  Andreas Gruenbacher  <agruen@suse.de>
98             Bruno Haible  <bruno@clisp.org>
99
100         diffseq: Accommodate use-case with abstract arrays.
101         * lib/diffseq.h (struct context): Remove xvec, yvec fields if ELEMENT
102         is not defined.
103         (diag, compareseq): Remove local variables xv, yv if ELEMENT is not
104         defined. Use local macro XREF_YREF_EQUAL instead of EQUAL.
105
106 2010-04-18  Bruno Haible  <bruno@clisp.org>
107
108         * doc/posix-headers/stdbool.texi: More precise wording.
109
110 2010-04-17  Jim Meyering  <meyering@redhat.com>
111
112         maint.mk: use gnu-style indentation in an embedded perl script
113         * top/maint.mk (detect_empty_lines_at_EOF_): Clean up formatting.
114         Rename variable: s/two/last_two_bytes/
115
116 2010-04-16  Eric Blake  <eblake@redhat.com>
117
118         test-stdbool: skip test that fails with Solaris CC
119         * tests/test-stdbool.c (f): Skip test that causes compilation
120         error under buggy C++ compiler.
121         * lib/stdbool.in.h: Document the limitation.
122         * doc/posix-headers/stdbool.texi (stdbool.h): Likewise.
123
124         setenv: allow compilation with C++
125         * lib/setenv.c (__add_to_environ): Add a cast.  Also, drop use of
126         register keyword.
127
128         stdint: allow test to pass with C++
129         * tests/test-stdint.c: Define __STDC_CONSTANT_MACROS, for glibc.
130
131         getopt: allow compilation with C++
132         * lib/getopt_int.h (__ordering): Hoist enum declaration outside
133         struct.
134         * lib/getopt.c (_getopt_internal_r): Use correct type.
135         Reported by Dagobert Michelson, via Joel E. Denny.
136
137 2010-04-16  Bruno Haible  <bruno@clisp.org>
138
139         Override netdb.h always.
140         * modules/netdb (Makefile.am): Augment BUILT_SOURCES always.
141         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't set NETDB_H.
142         Reported by Ludovic Courtès <ludo@gnu.org>.
143
144 2010-04-15  Bruno Haible  <bruno@clisp.org>
145
146         openpty: Fix mistake from 2010-03-21.
147         * m4/pty.m4 (gl_FUNC_OPENPTY): Define HAVE_OPENPTY when openpty exists.
148         Reported by Simon Josefsson.
149
150 2010-04-15  Eric Blake  <eblake@redhat.com>
151
152         test-forkpty: fix expected signature
153         * tests/test-forkpty.c (SIGNATURE_CHECK): Add appropriate const.
154         Reported by Simon Josefsson.
155
156 2010-04-15  Jim Meyering  <meyering@redhat.com>
157
158         maint.mk: texinfo_suffix_re_: correct the default regexp
159         * top/maint.mk (texinfo_suffix_re_): Fix default regexp.
160
161         * top/maint.mk (sc_texinfo_acronym): Improve filename regexp, and
162         make it configurable via texinfo_suffix_re_.
163
164 2010-04-14  Eric Blake  <eblake@redhat.com>
165
166         strtok_r: relax license to LGPLv2+
167         * modules/strtok_r (License): Relax license.
168         Reported by Matthias Bolte.
169
170 2010-04-14  Simon Josefsson  <simon@josefsson.org>
171
172         * lib/gc-libgcrypt.c (gc_init): Use MIN_GCRYPT_VERSION set to
173         version 1.4.4 by default instead of requiring the libgcrypt
174         version used during build.  This makes it possible to use the
175         application with older but still binary compatible libgcrypt
176         versions.
177
178 2010-04-13  Eric Blake  <eblake@redhat.com>
179
180         getopt-gnu: match recent glibc fixes and posix ruling
181         * tests/test-getopt.h (test_getopt): Strengthen tests of leading
182         '+' handling, when requesting extensions.
183         * tests/test-getopt_long.h (test_getopt_long): Strengthen test of
184         'W;' handling.
185         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Detect glibc 2.11 bug.
186         * doc/posix-functions/getopt.texi (getopt): Document this.
187         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
188         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
189         Likewise.
190
191         getopt: merge bug fixes from glibc
192         * lib/getopt.c (_getopt_internal_r): Use correct message for 'W;'
193         diagnostics.  Honor '+:' correctly.  Reject ';'.
194
195         getopt-posix: detect MacOS bug
196         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Reject MacOS botch of
197         optind when missing a required argument.
198         * doc/posix-functions/getopt.texi (getopt): Document the bug.
199         * doc/glibc-functions/getopt_long.texi (getopt_long): Likewise.
200         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
201         Likewise.
202
203         getopt-posix: avoid spurious failure on Solaris
204         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for getopt_clip as
205         an indicator that setting optind=1 is sufficient for reset.
206
207         getopt-posix: avoid spurious failure on FreeBSD
208         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Check for optreset even
209         in POSIX mode, since the m4 test uses it.
210
211         gnulib-tool: silence warning on BSD sh
212         * gnulib-tool: Avoid leaking warning about unknown 'declare'.
213
214 2010-04-13  Jim Meyering  <meyering@redhat.com>
215
216         doc: users.txt: GNU patch now uses gnulib
217         * users.txt: Add patch.
218
219 2010-04-12  Jim Meyering  <meyering@redhat.com>
220
221         maint.mk: generate more concise timing data for syntax-check rules
222         * top/maint.mk ($(sc_z_rules_)): Remove the ":", "sc_" prefix and
223         " done" from each line that reports a syntax-check test duration.
224
225 2010-04-12  Andreas Gruenbacher  <agruen@suse.de>
226
227         git-version-gen: use "git update-index..." rather than "git status"
228         * build-aux/git-version-gen: Use git update-index --refresh, not
229         "git status".  With some versions of git, "git status" would fail
230         to update the index and result in an unwarranted "-dirty" suffix.
231
232 2010-04-11  Jim Meyering  <meyering@redhat.com>
233
234         openat: correct formatting (no semantic change)
235         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Correct formatting in AC_DEFINE.
236         Suggested by Bruno Haible.
237
238 2010-04-11  Bruno Haible  <bruno@clisp.org>
239
240         Stricter declaration checking in testdirs.
241         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
242         If for_tests is true, augment AM_CPPFLAGS to define
243         GNULIB_STRICT_CHECKING.
244         * build-aux/warn-on-use.h (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): When
245         GNULIB_STRICT_CHECKING is defined, verify that the function is
246         declared.
247
248 2010-04-11  Paolo Bonzini  <bonzini@gnu.org>
249             Bruno Haible  <bruno@clisp.org>
250
251         libunistring: Improve configure output.
252         * m4/libunistring.m4 (gl_LIBUNISTRING): Check for libiconv first.
253         Don't say "consider installing GNU libunistring" when checking again
254         with libiconv.
255
256 2010-04-11  Bruno Haible  <bruno@clisp.org>
257
258         libunistring: Correct value of $LTLIBUNISTRING.
259         * m4/libunistring.m4 (gl_LIBUNISTRING): When it depends on libiconv,
260         correct the value of $LTLIBUNISTRING.
261
262 2010-04-11  Bruno Haible  <bruno@clisp.org>
263
264         havelib: Add static libraries to LIBS in the right order.
265         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): When $LIB[]NAME contains no
266         -l options, prepend it to $LIBS, instead of appending it to $LIBS.
267
268 2010-04-11  Bruno Haible  <bruno@clisp.org>
269
270         libunistring: Detect libunistring also when it depends on libiconv.
271         * m4/libunistring.m4 (gl_LIBUNISTRING): Unset the cached result before
272         the second AC_LIB_HAVE_LINKFLAGS invocation.
273
274 2010-04-11  James Youngman  <jay@gnu.org>
275
276         close-stream: declare local scalars to be "const"
277         * lib/close-stream.c (close_stream): Make boolean variables const
278         to document the fact that we set but do not change them.
279
280 2010-04-11  Bruno Haible  <bruno@clisp.org>
281
282         * m4/libunistring.m4 (gl_LIBUNISTRING): Fix typo in comment.
283
284 2010-04-11  Jim Meyering  <meyering@redhat.com>
285
286         maint.mk: don't include dist-check.mk
287         * top/maint.mk: Remove bogus include directive.
288
289         maint.mk: improve empty-line-at-EOF check
290         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): Use Perl-based
291         solution, rather than tail+Perl-based one.  The latter would read
292         a few kilobytes from the end of each file, and did not handle empty
293         files properly.
294
295         maint.mk: print the elapsed time for each syntax-check rule
296         * top/maint.mk (sc_m_rules_): Save start time in a file.
297         (sc_z_rules_): New rules: remove temp file and print elapsed time.
298         (local-check): Interpose the .z rules
299
300 2010-04-11  Jim Meyering  <meyering@redhat.com>
301
302         maint.mk: detect_empty_lines_at_EOF_: avoid FP for an empty file
303         * top/maint.mk (detect_empty_lines_at_EOF_): Don't confuse an
304         empty file with one that ends in an empty line.
305
306 2010-04-10  Bruno Haible  <bruno@clisp.org>
307
308         mkdir: Make it work on mingw64.
309         * lib/sys_stat.in.h: Include <direct.h> together with <io.h>.
310         * lib/mkdir.c: Update comment.
311         Reported by Roman Donchenko (Роман Донченко) <dxdragon@yandex.ru>.
312
313 2010-04-10  Bruno Haible  <bruno@clisp.org>
314
315         Don't override improved macro from newer autoconf.
316         * m4/gnulib-common.m4 (AC_C_RESTRICT): Don't define for
317         autoconf >= 2.62.
318         Reported by Joel E. Denny <jdenny@clemson.edu>.
319
320 2010-04-10  Jim Meyering  <meyering@redhat.com>
321
322         maint.mk: new syntax-check rule: prohibit empty lines at end of file
323         * top/maint.mk (sc_prohibit_empty_lines_at_EOF): New rule.
324
325         maint.mk: correct a diagnostic
326         * top/maint.mk (sc_prohibit_HAVE_MBRTOWC): Fix obsolete use of $re
327         in diagnostic; now use $prohibit.
328
329 2010-04-10  Bruno Haible  <address@hidden>
330
331         fchownat: Fix a C++ test error on Solaris 8.
332         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Don't set REPLACE_FCHOWNAT to 1 if
333         the function does not exist.
334
335 2010-04-10  Bruno Haible  <bruno@clisp.org>
336
337         vasnprintf: Add more tests.
338         * tests/test-vasnprintf-posix.c: Include <errno.h>.
339         (test_function): Test converting an invalid wide string.
340
341         vasnprintf: Correct handling of unconvertible wide string arguments.
342         * lib/vasnprintf.c (MAX_ROOM_NEEDED): New function, extracted from
343         VASNPRINTF.
344         (VASNPRINTF): Use it. After snprintf failed, allocate more memory only
345         if HAVE_SNPRINTF_RETVAL_C99 is false and the allocated memory is
346         smaller than the expected maximum need for the directive. Set errno to
347         EILSEQ, not EINVAL, when the directive is 'c' or 's'.
348         (local_strnlen, local_wcslen, local_wcsnlen): Update conditions.
349         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Require AC_C_INLINE and
350         gl_SNPRINTF_RETVAL_C99. Define HAVE_SNPRINTF_RETVAL_C99.
351         * modules/vasnprintf (Files): Add m4/printf.m4.
352         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
353
354 2010-04-10  Bruno Haible  <bruno@clisp.org>
355
356         vasnprintf: Fix crash in %ls directive.
357         * lib/vasnprintf.c (VASNPRINTF): Don't abort when a unconvertible wide
358         string is passed as argument to %ls, with no precision and no width.
359         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
360
361 2010-04-10  Bruno Haible  <bruno@clisp.org>
362
363         vasnprintf: Fix multiple test failures on mingw.
364         * lib/vasnprintf.c (SNPRINTF) [mingw]: Define to snprintf, not
365         _snprintf, or snwprintf, not _snwprintf.
366
367 2010-04-10  Bruno Haible  <bruno@clisp.org>
368
369         write: Fix a C++ test error on mingw.
370         * lib/unistd.in.h (write): Use _GL_CXXALIAS_SYS_CAST.
371
372 2010-04-10  Bruno Haible  <bruno@clisp.org>
373
374         vasnprintf test: Reduce code duplication.
375         * tests/test-vasnprintf.c (test_function): New function, extracted from
376         test_vasnprintf.
377         (test_vasnprintf, test_asnprintf): Invoke it.
378
379 2010-04-10  Bruno Haible  <bruno@clisp.org>
380
381         strnlen: Fix warning in C++ mode on MacOS X.
382         * lib/string.in.h (strnlen): Use the modern idiom.
383         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set REPLACE_STRNLEN to 1, instead of
384         defining strnlen as a macro already in <config.h>.
385         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
386         REPLACE_STRNLEN.
387         * modules/string (Makefile.am): Substitute REPLACE_STRNLEN.
388         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
389
390 2010-04-08  James Youngman  <jay@gnu.org>
391
392         * doc/manywarnings.texi (manywarnings): Add missing parenthesis in
393         the example.
394
395 2010-04-09  Jim Meyering  <meyering@redhat.com>
396
397         maint.mk: print better diagnostic when there is no $(_hv_file)
398         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): Skip test and
399         announce that when $(_hv_file) (aka help-version) does not exist.
400
401         init.sh: run tr in the "C" locale to avoid multibyte interpretation
402         * tests/init.sh (rand_bytes_): Run tr in the "C" locale so it does
403         not try to interpret its random input bytes.  Jarno Rajahalme reported
404         that ./test-xalloc-die.sh would fail with "tr: Illegal byte sequence".
405         on Darwin 10.3.0 with LC_CTYPE=UTF-8.
406         (mktempd_): Likewise, just in case.
407
408         ftruncate: add two years to projected module removal date: 2012
409         * m4/ftruncate.m4: Adjust comments.
410
411         ftruncate: mark module as obsolete; even MinGW provides it, now
412         * modules/ftruncate (Status): Obsolete.
413         (Notice): Say that.
414         * doc/posix-functions/ftruncate.texi: Don't say MinGW lacks it.
415         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/9203
416
417 2010-04-08  Bruno Haible  <bruno@clisp.org>
418
419         Fix side effects from tests-related modules.
420         * modules/dprintf-posix (Comment): New section.
421         * modules/fprintf-posix (Comment): Likewise.
422         * modules/obstack-printf-posix (Comment): Likewise.
423         * modules/printf-posix (Comment): Likewise.
424         * modules/snprintf-posix (Comment): Likewise.
425         * modules/sprintf-posix (Comment): Likewise.
426         * modules/vasnprintf-posix (Comment): Likewise.
427         * modules/vasprintf-posix (Comment): Likewise.
428         * modules/vdprintf-posix (Comment): Likewise.
429         * modules/vfprintf-posix (Comment): Likewise.
430         * modules/vprintf-posix (Comment): Likewise.
431         * modules/vsnprintf-posix (Comment): Likewise.
432         * modules/vsprintf-posix (Comment): Likewise.
433         * modules/xprintf-posix (Comment): Likewise.
434         * modules/xvasprintf-posix (Comment): Likewise.
435         * modules/ceilf-tests (Depends-on): Remove fprintf-posix.
436         * modules/floorf-tests (Depends-on): Likewise.
437         * modules/round-tests (Depends-on): Likewise.
438         * modules/roundf-tests (Depends-on): Likewise.
439         * modules/trunc-tests (Depends-on): Likewise.
440         * modules/truncf-tests (Depends-on): Likewise.
441         * tests/test-ceilf2.c (check): Don't invoke fprintf if the
442         'fprintf-posix' module is not present.
443         * tests/test-floorf2.c (check): Likewise.
444         * tests/test-trunc2.c (check): Likewise.
445         * tests/test-truncf2.c (check): Likewise.
446         * tests/test-round2.c (equal): Likewise.
447         Reported by Jarno Rajahalme <jarno.rajahalme@nsn.com>.
448
449 2010-04-07  Karl Berry  <karl@gnu.org>
450
451         * config/srclist.txt,
452         * config/srclistvars.sh,
453         * config/srclist-update: doc fixes.
454
455 2010-04-07  Jim Meyering  <meyering@redhat.com>
456
457         maint.mk: add a PATH crosschecking syntax-check rule
458         * top/maint.mk (sc_cross_check_PATH_usage_in_tests): New rule.
459         Useful if you use a test like the one in help-version (coreutils,
460         diffutils, grep, gzip) that ensures $(VERSION) matches what is
461         printed by prog --version.
462
463 2010-04-06  Bruno Haible  <bruno@clisp.org>
464
465         Fix link error on mingw.
466         * modules/unistd-c++-tests (test_unistd_c___LDADD): Add LIBSOCKET.
467         * modules/fcntl-h-c++-tests (test_fcntl_h_c___LDADD): Likewise.
468
469 2010-04-06  Bruno Haible  <bruno@clisp.org>
470
471         Assume rmdir exists.
472         * lib/rmdir.c (rpl_rmdir): Remove code that invokes the rmdir program.
473
474 2010-04-06  Giuseppe Scrivano <gscrivano@gnu.org>
475
476         doc: update users.txt
477         * users.txt: Add gcal.
478
479 2010-04-06  Jim Meyering  <meyering@redhat.com>
480
481         init.sh: simply unset TMPDIR rather than risking env -i
482         * tests/init.sh (mktempd_): Using env -i is rather harsh, and
483         although it probably works fine on all Unix-based systems, some
484         systems (Cygwin?) cannot tolerate a totally cleared environment.
485         Suggestion from Eric Blake.
486
487 2010-04-06  Jim Meyering  <meyering@redhat.com>
488
489         init.sh: portability fix: use env's POSIX-specified -i option not -u
490         * tests/init.sh (mktempd_): Use env -i and set PATH explicitly rather
491         than unportable env -u.  Solaris 5.11's env lacks support for -u.
492
493 2010-04-05  Bruno Haible  <bruno@clisp.org>
494
495         btowc: Work around Cygwin 1.7.2 bug.
496         * m4/btowc.m4 (gl_FUNC_BTOWC): Set REPLACE_BTOWC to 1 if the function
497         does not map NUL to 0.
498         * doc/posix-functions/btowc.texi: Mention the Cygwin bug.
499
500 2010-04-05  Bruno Haible  <bruno@clisp.org>
501
502         Make the multithread modules work on Cygwin 1.7.2.
503         * m4/threadlib.m4 (gl_THREADLIB_BODY): Improve the test whether
504         imported symbols can be declared weak, so that it returns "no" on
505         Cygwin 1.7.2.
506
507 2010-04-05  Bruno Haible  <bruno@clisp.org>
508
509         Use the module 'strncat'.
510         * modules/unistr/u8-strncat (Depends-on): Add strncat.
511
512         Tests for module 'strncat'.
513         * modules/strncat-tests: New file.
514         * tests/test-strncat.c: New file.
515
516         New module 'strncat'.
517         * lib/string.in.h (strncat): New declaration.
518         * lib/strncat.c: New file, based on lib/unistr/u-strncat.h.
519         * m4/strncat.m4: New file, based on m4/memchr.m4.
520         * modules/strncat: New file.
521         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Also check whether strncat
522         is declared.
523         (gl_HEADER_STRING_H_DEFAULTS): Initialize GNULIB_STRNCAT,
524         REPLACE_STRNCAT.
525         * modules/string (Makefile.am): Substitute GNULIB_STRNCAT,
526         REPLACE_STRNCAT.
527         * doc/posix-functions/strncat.texi: Mention the Solaris bug and the new
528         module.
529         * tests/test-string-c++.cc: Check signature of strncat.
530
531 2010-04-05  Jim Meyering  <meyering@redhat.com>
532
533         xstrtoumax-tests: convert to use init.sh
534         * modules/xstrtoumax-tests (Files): Add tests/init.sh.
535         * tests/test-xstrtoumax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
536         Use Exit, not exit.
537         Remove uses of $EXEEXT and "./" to run a program in the current dir.
538
539         xstrtoimax-tests: convert to use init.sh
540         * modules/xstrtoimax-tests (Files): Add tests/init.sh.
541         * tests/test-xstrtoimax.sh: Invoke "$srcdir/init.sh" and path_prepend_.
542         Use Exit, not exit.
543         Remove uses of $EXEEXT and "./" to run a program in the current dir.
544
545 2010-04-05  Bruno Haible  <bruno@clisp.org>
546
547         sys_socket: Avoid #define replacements in C++ mode.
548         * lib/sys_socket.in.h (close, gethostname, select): In C++, attach a
549         warning to the function if possible, rather than #defining the symbol
550         to a dysfunctional alias.
551
552 2010-04-05  Bruno Haible  <bruno@clisp.org>
553
554         fseeko: Fix C++ test error on mingw.
555         * m4/fseeko.m4 (gl_HAVE_FSEEKO): New macro, extracted from
556         gl_FUNC_FSEEKO.
557         (gl_REPLACE_FSEEKO): Also set REPLACE_FSEEKO if appropriate.
558         (gl_FUNC_FSEEKO): Require gl_HAVE_FSEEKO. Update.
559         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't fiddle with internals of the
560         fseeko module. Instead, invoke gl_REPLACE_FSEEKO.
561
562 2010-04-05  Bruno Haible  <bruno@clisp.org>
563
564         duplocale: Improve test output.
565         * tests/test-duplocale.c (main): Print reason for skipped test.
566
567 2010-04-05  Bruno Haible  <bruno@clisp.org>
568
569         Assume rmdir exists.
570         * m4/rmdir.m4 (gl_FUNC_RMDIR): Remove test whether rmdir exists.
571         * doc/posix-functions/rmdir.texi: Remove mention of "old platforms".
572
573 2010-04-05  Bruno Haible  <bruno@clisp.org>
574
575         Fix link error on Solaris 8 with cc.
576         * modules/pty-c++-tests (test_pty_c___LDADD): Add LIBINTL.
577
578 2010-04-05  Bruno Haible  <bruno@clisp.org>
579
580         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
581         * lib/math.in.h (frexpl): Fix condition on _GL_CXXALIASWARN invocation.
582
583 2010-04-05  Bruno Haible  <bruno@clisp.org>
584
585         vasprintf: Update documentation.
586         * doc/glibc-functions/asprintf.texi: Mention the 'vasprintf' module.
587
588 2010-04-05  Bruno Haible  <bruno@clisp.org>
589
590         ptsname: Improve test.
591         * tests/test-ptsname.c (main): Also try the various master names of BSD
592         systems.
593
594 2010-04-05  Bruno Haible  <bruno@clisp.org>
595
596         memchr: Avoid a possible C++ test error.
597         * lib/string.in.h (memchr): Provide declaration if function is missing.
598         * m4/memchr.m4 (gl_FUNC_MEMCHR): If the function is missing, set
599         HAVE_MEMCHR to 0, not REPLACE_MEMCHR to 1.
600         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MEMCHR.
601         * modules/string (Makefile.am): Substitute HAVE_MEMCHR.
602
603 2010-04-05  Bruno Haible  <bruno@clisp.org>
604
605         strtok_r: Improve idiom.
606         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Invoke gl_PREREQ_STRDUP only when
607         AC_LIBOBJ is used.
608
609 2010-04-05  Bruno Haible  <bruno@clisp.org>
610
611         strdup: Improve idiom.
612         * m4/strdup.m4 (gl_FUNC_STRDUP): Invoke gl_PREREQ_STRDUP only when
613         AC_LIBOBJ is used.
614         (gl_FUNC_STRDUP_POSIX): When strdup is missing and malloc is not POSIX
615         compliant, don't set REPLACE_STRDUP to 1. Invoke gl_PREREQ_STRDUP only
616         when AC_LIBOBJ is used.
617
618 2010-04-05  Bruno Haible  <bruno@clisp.org>
619
620         mbsinit, mbrtowc, wcrtomb: Improve idioms.
621         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): When the function does not exist,
622         don't set REPLACE_MBSINIT to 1.
623         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): When the function does not exist,
624         don't set REPLACE_MBRTOWC to 1.
625         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): When the function does not
626         exist, don't set REPLACE_MBSRTOWCS to 1.
627         * m4/mbsnrtowcs.m4 (gl_FUNC_MBSNRTOWCS): When the function does not
628         exist, don't set REPLACE_MBSNRTOWCS to 1.
629         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): When the function does not exist,
630         don't set REPLACE_WCRTOMB to 1.
631         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): When the function does not
632         exist, don't set REPLACE_WCSRTOMBS to 1.
633         * m4/wcsnrtombs.m4 (gl_FUNC_WCSNRTOMBS): When the function does not
634         exist, don't set REPLACE_WCSNRTOMBS to 1.
635
636 2010-04-05  Bruno Haible  <bruno@clisp.org>
637
638         ldexpl: Improve idiom.
639         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): When the function is not declared,
640         make sure to set HAVE_DECL_LDEXPL to 0.
641
642 2010-04-05  Jim Meyering  <meyering@redhat.com>
643
644         xstrtol-tests: convert to use init.sh
645         * modules/xstrtol-tests (Files): Add tests/init.sh.
646         * tests/test-xstrtol.sh: Invoke "$srcdir/init.sh" and path_prepend_.
647         Use Exit, not exit.
648         Remove uses of $EXEEXT and "./" to run a program in the current dir.
649
650         atexit-tests: convert to use init.sh
651         * modules/atexit-tests (Files): Add tests/init.sh.
652         * tests/test-atexit.sh: Invoke "$srcdir/init.sh" and path_prepend_.
653         Use Exit, not exit.
654         Remove uses of $EXEEXT and "./" to run a program in the current dir.
655
656         init.sh: fix typo
657         * tests/init.sh: Restore omitted ":" before stderr_fileno_ initialization.
658
659         init.sh: make it easier for a test script to write to the tty, ...
660         when using automake's parallel-tests mode.
661         * tests/init.sh (stderr_fileno_): Define overridable variable.
662         (warn_): New function, to use it.
663         (fail_, skip_, framework_failure_): Use warn_.
664
665 2010-04-04  Bruno Haible  <bruno@clisp.org>
666
667         btowc: Avoid warning.
668         * lib/btowc.c: Include <stdlib.h>.
669         Reported by Hauke Fath <hauke@espresso.rhein-neckar.de>.
670
671 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
672             Bruno Haible  <bruno@clisp.org>
673
674         wchar: Port to NetBSD 1.5.
675         * lib/wchar.in.h (WEOF): Provide fallback also when wint_t exists.
676         * lib/wctype.in.h (WEOF): Likewise.
677
678 2010-04-04  Hauke Fath  <hauke@espresso.rhein-neckar.de>  (tiny change)
679             Bruno Haible  <bruno@clisp.org>
680
681         Port extended stdio to NetBSD 1.5.
682         * lib/stdio-impl.h [NetBSD]: Include <sys/param.h>.
683         (struct __sfileext, fp_ub): Define the "old way" for NetBSD 1.5Z and
684         older.
685
686 2010-04-04  Bruno Haible  <bruno@clisp.org>
687
688         string: Remove unused substitution.
689         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
690         HAVE_DECL_STRERROR.
691         * modules/string (Makefile.am): Don't substitute HAVE_DECL_STRERROR.
692
693 2010-04-04  Bruno Haible  <bruno@clisp.org>
694
695         strtod: Avoid a possible C++ test error.
696         * m4/strtod.m4 (gl_FUNC_STRTOD): When setting HAVE_STRTOD to 0, don't
697         set REPLACE_STRTOD.
698
699 2010-04-04  Bruno Haible  <bruno@clisp.org>
700
701         strerror: Update documentation.
702         * doc/posix-functions/strerror.texi: Remove mention of old platforms.
703
704 2010-04-04  Bruno Haible  <bruno@clisp.org>
705
706         stdio: Fix some C++ test errors on Solaris 8 with GCC.
707         * lib/stdio.in.h (vdprintf, vfprintf, vprintf, vsprintf): Use
708         _GL_CXXALIAS_SYS_CAST.
709
710 2010-04-04  Bruno Haible  <bruno@clisp.org>
711
712         frexpl: Fix a C++ test error on Solaris 8 and Cygwin.
713         * m4/frexpl.m4 (gl_FUNC_FREXPL, gl_FUNC_FREXPL_NO_LIBM): When the
714         function is not declared, set HAVE_DECL_FREXPL to 0, instead of setting
715         REPLACE_FREXPL to 1.
716         * doc/posix-functions/frexpl.texi: Update documentation.
717
718 2010-04-04  Bruno Haible  <bruno@clisp.org>
719
720         math: Fix some C++ test errors on Solaris 8 and Cygwin.
721         * lib/math.in.h (cosl, logl, sinl): Use simpler idiom.
722
723 2010-04-04  Bruno Haible  <bruno@clisp.org>
724
725         Implement nanosleep for native Windows.
726         * lib/nanosleep.c (nanosleep): New implementation for native Windows.
727
728 2010-04-04  Bruno Haible  <bruno@clisp.org>
729
730         math: Fix some C++ test errors on Solaris 8.
731         * lib/math.in.h (truncf, trunc): Use simpler idiom.
732
733 2010-04-04  Bruno Haible  <bruno@clisp.org>
734
735         math: Fix some C++ test errors on Cygwin.
736         * lib/math.in.h (ceilf, ceill, floorf, floorl, roundf, round, roundl,
737         truncl): Provide declaration if the system does not have it.
738         * m4/ceilf.m4 (gl_FUNC_CEILF): If the function is not declared, set
739         HAVE_DECL_CEILF to 0, not REPLACE_CEILF to 1.
740         * m4/ceill.m4 (gl_FUNC_CEILL): If the function is not declared, set
741         HAVE_DECL_CEILL to 0, not REPLACE_CEILL to 1.
742         * m4/floorf.m4 (gl_FUNC_FLOORF): If the function is not declared, set
743         HAVE_DECL_FLOORF to 0, not REPLACE_FLOORF to 1.
744         * m4/floorl.m4 (gl_FUNC_FLOORL): If the function is not declared, set
745         HAVE_DECL_FLOORL to 0, not REPLACE_FLOORL to 1.
746         * m4/round.m4 (gl_FUNC_ROUND): If the function is not declared, set
747         HAVE_DECL_ROUND to 0, not REPLACE_ROUND to 1.
748         * m4/roundf.m4 (gl_FUNC_ROUNDF): If the function is not declared, set
749         HAVE_DECL_ROUNDF to 0, not REPLACE_ROUNDF to 1.
750         * m4/roundl.m4 (gl_FUNC_ROUNDL): If the function is not declared, set
751         HAVE_DECL_ROUNDL to 0, not REPLACE_ROUNDL to 1.
752         * m4/truncl.m4 (gl_FUNC_TRUNCL): If the function is not declared, set
753         HAVE_DECL_TRUNCL to 0, not REPLACE_TRUNCL to 1.
754         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize HAVE_DECL_CEILF,
755         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
756         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
757         * modules/math (Makefile.am): Substitute HAVE_DECL_CEILF,
758         HAVE_DECL_CEILL, HAVE_DECL_FLOORF, HAVE_DECL_FLOORL, HAVE_DECL_ROUND,
759         HAVE_DECL_ROUNDF, HAVE_DECL_ROUNDL, HAVE_DECL_TRUNCL.
760
761 2010-04-04  Bruno Haible  <bruno@clisp.org>
762
763         * m4/ceilf.m4 (gl_FUNC_CEILF): Remove redundant AC_SUBST invocation.
764         * m4/ceill.m4 (gl_FUNC_CEILL): Likewise.
765         * m4/floorf.m4 (gl_FUNC_FLOORF): Likewise.
766         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
767         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
768         * m4/isinf.m4 (gl_ISINF): Likewise.
769         * m4/truncl.m4 (gl_FUNC_TRUNCL): Likewise.
770
771 2010-04-04  Bruno Haible  <bruno@clisp.org>
772
773         * m4/trunc.m4 (gl_FUNC_TRUNC): Remove redundant AC_SUBST invocation.
774         * m4/truncf.m4 (gl_FUNC_TRUNCF): Likewise.
775
776 2010-04-04  Bruno Haible  <bruno@clisp.org>
777
778         * m4/tmpfile.m4 (gl_FUNC_TMPFILE): Renamed from gl_TMPFILE.
779         * modules/tmpfile (configure.ac): Update.
780
781         tmpfile: Fix C++ test error on mingw.
782         * lib/stdio.in.h (tmpfile): New declaration.
783         * m4/tmpfile.m4 (gl_TMPFILE): Require gl_STDIO_H_DEFAULTS. Set
784         REPLACE_TMPFILE instead of defining tmpfile as a macro in config.h.
785         * modules/tmpfile (Depends-on): Add stdio.
786         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
787         * m4/stdio_h.m4 (gl_STDIO_H): Also check whether tmpfile is declared.
788         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_TMPFILE and REPLACE_TMPFILE.
789         * modules/stdio (Makefile.am): Substitute GNULIB_TMPFILE and
790         REPLACE_TMPFILE.
791         * tests/test-stdio-c++.cc (tmpfile): Verify signature.
792
793 2010-04-04  Bruno Haible  <bruno@clisp.org>
794
795         ioctl: Fix C++ test error on mingw.
796         * lib/ioctl.c (ioctl): Renamed from rpl_ioctl.
797         * lib/sys_ioctl.in.h (ioctl): When SYS_IOCTL_H_HAVE_WINSOCK2_H is 1,
798         use _GL_FUNCDECL_SYS, not _GL_FUNCDECL_RPL.
799
800 2010-04-03  Bruno Haible  <bruno@clisp.org>
801
802         wcwidth: Fix C++ test error on mingw.
803         * lib/wcwidth.c (wcwidth): Renamed from rpl_wcwidth.
804         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): If the wcwidth function does not
805         exist, don't set REPLACE_WCWIDTH. Instead, rely on HAVE_DECL_WCWIDTH.
806
807 2010-04-03  Bruno Haible  <bruno@clisp.org>
808
809         nanosleep: Fix C++ test error on mingw.
810         * lib/nanosleep.c (nanosleep): Renamed from rpl_nanosleep.
811         * lib/time.in.h (nanosleep): Use modern idiom.
812         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): When the system does not have a
813         nanosleep function, set HAVE_NANOSLEEP to 0, instead of setting
814         REPLACE_NANOSLEEP to 1.
815         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_NANOSLEEP.
816         * modules/time (Makefile.am): Substitute HAVE_NANOSLEEP.
817
818 2010-04-03  Bruno Haible  <bruno@clisp.org>
819
820         strptime: Fix C++ test error on mingw.
821         * lib/time.in.h (strptime): Use HAVE_STRPTIME, not REPLACE_STRPTIME.
822         * m4/strptime.m4 (gl_FUNC_STRPTIME): Set HAVE_STRPTIME, not
823         REPLACE_STRPTIME. Invoke gl_PREREQ_STRPTIME.
824         (gl_PREREQ_STRPTIME): New macro, extracted from gl_FUNC_STRPTIME.
825         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_STRPTIME,
826         not REPLACE_STRPTIME.
827         * modules/time (Makefile.am): Substitute HAVE_STRPTIME, not
828         REPLACE_STRPTIME.
829
830 2010-04-03  Bruno Haible  <bruno@clisp.org>
831
832         timegm: Fix C++ test error on mingw.
833         * lib/time.in.h (timegm): Use modern idiom.
834         * m4/timegm.m4 (gl_FUNC_TIMEGM): When timegm does not exist, set
835         HAVE_TIMEGM to 0, not REPLACE_TIMEGM to 1.
836         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_TIMEGM.
837         * modules/time (Makefile.am): Substitute HAVE_TIMEGM.
838
839 2010-04-03  Bruno Haible  <bruno@clisp.org>
840
841         timegm: Assume declaration if function exists.
842         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume timegm is declared if and only
843         if it exists. Don't clobber ac_cv_func_timegm.
844
845 2010-04-03  Bruno Haible  <bruno@clisp.org>
846
847         time_r: Fix C++ test error on mingw.
848         * lib/time.in.h (localtime_r, gmtime_r): Use modern idiom.
849         * m4/time_r.m4 (gl_TIME_R): When localtime_r does not exist, set
850         HAVE_LOCALTIME_R to 0, not REPLACE_LOCALTIME_R to 1.
851         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize HAVE_LOCALTIME_R.
852         * modules/time (Makefile.am): Substitute HAVE_LOCALTIME_R.
853
854 2010-04-03  Bruno Haible  <bruno@clisp.org>
855
856         time_r: Minor updates.
857         * modules/time_r (Description): Mention the provided functions.
858         * lib/time_r.c: Don't include <string.h>.
859         * doc/posix-functions/gmtime_r.texi: Mention the 'time_r' module.
860         * doc/posix-functions/localtime_r.texi: Likewise.
861
862 2010-04-03  Bruno Haible  <bruno@clisp.org>
863
864         time: Fix regression introduced on 2010-03-08.
865         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Require
866         gl_HEADER_TIME_H_DEFAULTS, not gl_HEADER_STRING_H_DEFAULTS.
867
868 2010-04-03  Jim Meyering  <meyering@redhat.com>
869
870         maint.mk: don't silently disable project-specific syntax-check rules
871         * top/maint.mk (_prohibit_regexp): Define, to help people realize
872         that they need to convert their project-specific syntax-check rules
873         to use the new _sc_search_regexp.
874
875 2010-04-03  Bruno Haible  <bruno@clisp.org>
876
877         fchdir: Fix regression introduced on 2010-03-08.
878         * lib/unistd.in.h (fchdir): Fix declaration.
879         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set HAVE_FCHDIR, not REPLACE_FCHDIR.
880         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_FCHDIR, not
881         REPLACE_FCHDIR.
882         * modules/unistd (Makefile.am): Substitute HAVE_FCHDIR, not
883         REPLACE_FCHDIR.
884
885 2010-04-03  Bruno Haible  <bruno@clisp.org>
886
887         getpagesize: Fix C++ test error on mingw.
888         * lib/unistd.in.h (getpagesize): Don't use _GL_CXXALIASWARN if the
889         system does not declare the function.
890         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Also check whether it's
891         declared.
892         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
893         HAVE_DECL_GETPAGESIZE.
894         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETPAGESIZE.
895
896 2010-04-03  Bruno Haible  <bruno@clisp.org>
897
898         stdio: Make C++ tests work on mingw.
899         * lib/stdio.in.h (getline): Don't use _GL_CXXALIASWARN if the system
900         does not declare the function.
901
902 2010-04-03  Bruno Haible  <bruno@clisp.org>
903
904         ftello: Fix C++ test error on mingw.
905         * lib/stdio.in.h (ftello): Use modern idiom.
906         * lib/ftello.c (ftello): Renamed from rpl_ftello.
907         * m4/ftello.m4 (gl_FUNC_FTELLO): Distinguish the case that the function
908         is missing and that it needs to be replaced.
909         (gl_REPLACE_FTELLO): Don't set REPLACE_FTELLO here.
910         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FTELLO.
911         * modules/stdio (Makefile.am): Substitute HAVE_FTELLO.
912
913 2010-04-03  Bruno Haible  <bruno@clisp.org>
914
915         fseeko: Fix C++ test error on mingw.
916         * lib/stdio.in.h (fseeko): Use modern idiom.
917         * lib/fseeko.c (fseeko): Renamed from rpl_fseeko.
918         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Distinguish the case that the function
919         is missing and that it needs to be replaced.
920         (gl_REPLACE_FSEEKO): Don't set REPLACE_FSEEKO here.
921         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_FSEEKO.
922         * modules/stdio (Makefile.am): Substitute HAVE_FSEEKO.
923
924 2010-04-03  Bruno Haible  <bruno@clisp.org>
925
926         mkstemp: Fix C++ test error on mingw.
927         * lib/stdlib.in.h (mkstemp): Use modern idiom.
928         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Distinguish the case that the
929         function is missing and that it needs to be replaced.
930         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_MKSTEMP.
931         * modules/stdlib (Makefile.am): Substitute HAVE_MKSTEMP.
932
933 2010-04-03  Bruno Haible  <bruno@clisp.org>
934
935         stpncpy: Fix C++ test error on mingw.
936         * lib/string.in.h (stpncpy): Use modern idiom.
937         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Distinguish the case that the
938         function is missing and that it needs to be replaced.
939         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
940         REPLACE_STPNCPY.
941         * modules/string (Makefile.am): Substitute REPLACE_STPNCPY.
942
943 2010-04-03  Bruno Haible  <bruno@clisp.org>
944
945         sys_stat: Fix C++ test error on mingw.
946         * build-aux/c++defs.h (_GL_CXXALIAS_RPL_CAST_1): New macro.
947         * lib/sys_stat.in.h (lchmod): Use it instead of _GL_CXXALIAS_RPL_1.
948
949 2010-04-03  Bruno Haible  <bruno@clisp.org>
950
951         pty: Update doc.
952         * doc/glibc-headers/pty.texi: Mention changes done since 2010-03-18.
953
954 2010-04-03  Bruno Haible  <bruno@clisp.org>
955
956         unistd: Fix C++ test error on mingw.
957         * lib/unistd.in.h (getcwd): Use _GL_CXXALIAS_SYS_CAST.
958
959 2010-04-03  Bruno Haible  <bruno@clisp.org>
960
961         Update doc regarding mingw.
962         * doc/glibc-functions/openpty.texi: Update regarding mingw.
963         * doc/glibc-functions/login_tty.texi: Likewise.
964         * doc/glibc-functions/forkpty.texi: Likewise.
965
966 2010-04-03  Bruno Haible  <bruno@clisp.org>
967
968         stdlib: Avoid compilation failure of c-strtold on mingw.
969         * lib/stdlib.in.h: Don't include <unistd.h> on native Windows systems.
970
971 2010-04-03  Bruno Haible  <bruno@clisp.org>
972
973         locale: Make C++ tests work on Cygwin and mingw.
974         * lib/locale.in.h (duplocale): Don't use _GL_CXXALIASWARN if gnulib
975         cannot provide the function.
976         Reported by Simon Josefsson.
977
978 2010-04-03  Bruno Haible  <bruno@clisp.org>
979
980         localename: Port to MacOS X 10.6.
981         * lib/localename.c (gl_locale_name_thread_unsafe): On MacOS X, try the
982         memory layout of the locales in MacOS X 10.6 as well.
983         Reported by Panu Kekäläinen <panu@kekalainen.eu>.
984
985 2010-04-02  Bruno Haible  <bruno@clisp.org>
986
987         gnulib-tool: Ensure that long-running tests are executed last.
988         * gnulib-tool (func_emit_tests_Makefile_am): Emit the code for long-
989         running tests after the one for the other tests.
990
991 2010-04-02  Bruno Haible  <bruno@clisp.org>
992
993         gnulib-tool: Ensure the tests in the main directory are executed first.
994         * gnulib-tool (func_emit_tests_Makefile_am): Initialize SUBDIRS to
995         start with the current directory.
996
997 2010-04-02  Bruno Haible  <bruno@clisp.org>
998
999         Tests for module 'havelib', moved here from GNU gettext.
1000         * modules/havelib-tests: New file, from gettext/autoconf-lib-link with
1001         modifications.
1002         * tests/havelib/README: New file, from gettext/autoconf-lib-link.
1003         * tests/havelib/Makefile.am: New file, from gettext/autoconf-lib-link
1004         with modifications.
1005         * tests/havelib/rpath-1: New file, from gettext/autoconf-lib-link with
1006         modifications.
1007         * tests/havelib/rpath-1a: New file, from gettext/autoconf-lib-link.
1008         * tests/havelib/rpath-1b: New file, from gettext/autoconf-lib-link.
1009         * tests/havelib/rpath-2_a: New file, from gettext/autoconf-lib-link
1010         with modifications.
1011         * tests/havelib/rpath-2_b: New file, from gettext/autoconf-lib-link
1012         with modifications.
1013         * tests/havelib/rpath-2aaa: New file, from gettext/autoconf-lib-link.
1014         * tests/havelib/rpath-2aab: New file, from gettext/autoconf-lib-link.
1015         * tests/havelib/rpath-2aac: New file, from gettext/autoconf-lib-link.
1016         * tests/havelib/rpath-2aad: New file, from gettext/autoconf-lib-link.
1017         * tests/havelib/rpath-2aba: New file, from gettext/autoconf-lib-link.
1018         * tests/havelib/rpath-2abb: New file, from gettext/autoconf-lib-link.
1019         * tests/havelib/rpath-2abc: New file, from gettext/autoconf-lib-link.
1020         * tests/havelib/rpath-2abd: New file, from gettext/autoconf-lib-link.
1021         * tests/havelib/rpath-2baa: New file, from gettext/autoconf-lib-link.
1022         * tests/havelib/rpath-2bab: New file, from gettext/autoconf-lib-link.
1023         * tests/havelib/rpath-2bac: New file, from gettext/autoconf-lib-link.
1024         * tests/havelib/rpath-2bad: New file, from gettext/autoconf-lib-link.
1025         * tests/havelib/rpath-2bba: New file, from gettext/autoconf-lib-link.
1026         * tests/havelib/rpath-2bbb: New file, from gettext/autoconf-lib-link.
1027         * tests/havelib/rpath-2bbc: New file, from gettext/autoconf-lib-link.
1028         * tests/havelib/rpath-2bbd: New file, from gettext/autoconf-lib-link.
1029         * tests/havelib/rpath-3_a: New file, from gettext/autoconf-lib-link
1030         with modifications.
1031         * tests/havelib/rpath-3_b: New file, from gettext/autoconf-lib-link
1032         with modifications.
1033         * tests/havelib/rpath-3aaa: New file, from gettext/autoconf-lib-link.
1034         * tests/havelib/rpath-3aab: New file, from gettext/autoconf-lib-link.
1035         * tests/havelib/rpath-3aac: New file, from gettext/autoconf-lib-link.
1036         * tests/havelib/rpath-3aad: New file, from gettext/autoconf-lib-link.
1037         * tests/havelib/rpath-3aae: New file, from gettext/autoconf-lib-link.
1038         * tests/havelib/rpath-3aaf: New file, from gettext/autoconf-lib-link.
1039         * tests/havelib/rpath-3aag: New file, from gettext/autoconf-lib-link.
1040         * tests/havelib/rpath-3aah: New file, from gettext/autoconf-lib-link.
1041         * tests/havelib/rpath-3aba: New file, from gettext/autoconf-lib-link.
1042         * tests/havelib/rpath-3abb: New file, from gettext/autoconf-lib-link.
1043         * tests/havelib/rpath-3abc: New file, from gettext/autoconf-lib-link.
1044         * tests/havelib/rpath-3abd: New file, from gettext/autoconf-lib-link.
1045         * tests/havelib/rpath-3abe: New file, from gettext/autoconf-lib-link.
1046         * tests/havelib/rpath-3abf: New file, from gettext/autoconf-lib-link.
1047         * tests/havelib/rpath-3abg: New file, from gettext/autoconf-lib-link.
1048         * tests/havelib/rpath-3abh: New file, from gettext/autoconf-lib-link.
1049         * tests/havelib/rpath-3baa: New file, from gettext/autoconf-lib-link.
1050         * tests/havelib/rpath-3bab: New file, from gettext/autoconf-lib-link.
1051         * tests/havelib/rpath-3bac: New file, from gettext/autoconf-lib-link.
1052         * tests/havelib/rpath-3bad: New file, from gettext/autoconf-lib-link.
1053         * tests/havelib/rpath-3bae: New file, from gettext/autoconf-lib-link.
1054         * tests/havelib/rpath-3baf: New file, from gettext/autoconf-lib-link.
1055         * tests/havelib/rpath-3bag: New file, from gettext/autoconf-lib-link.
1056         * tests/havelib/rpath-3bah: New file, from gettext/autoconf-lib-link.
1057         * tests/havelib/rpath-3bba: New file, from gettext/autoconf-lib-link.
1058         * tests/havelib/rpath-3bbb: New file, from gettext/autoconf-lib-link.
1059         * tests/havelib/rpath-3bbc: New file, from gettext/autoconf-lib-link.
1060         * tests/havelib/rpath-3bbd: New file, from gettext/autoconf-lib-link.
1061         * tests/havelib/rpath-3bbe: New file, from gettext/autoconf-lib-link.
1062         * tests/havelib/rpath-3bbf: New file, from gettext/autoconf-lib-link.
1063         * tests/havelib/rpath-3bbg: New file, from gettext/autoconf-lib-link.
1064         * tests/havelib/rpath-3bbh: New file, from gettext/autoconf-lib-link.
1065         * tests/havelib/rpathx/rpathx.c: New file, from
1066         gettext/autoconf-lib-link.
1067         * tests/havelib/rpathx/Makefile.am: New file, from
1068         gettext/autoconf-lib-link.
1069         * tests/havelib/rpathx/configure.ac: New file, from
1070         gettext/autoconf-lib-link with modifications.
1071         * tests/havelib/rpathy/rpathy.c: New file, from
1072         gettext/autoconf-lib-link.
1073         * tests/havelib/rpathy/Makefile.am: New file, from
1074         gettext/autoconf-lib-link.
1075         * tests/havelib/rpathy/configure.ac: New file, from
1076         gettext/autoconf-lib-link with modifications.
1077         * tests/havelib/rpathz/rpathz.c: New file, from
1078         gettext/autoconf-lib-link.
1079         * tests/havelib/rpathz/Makefile.am: New file, from
1080         gettext/autoconf-lib-link.
1081         * tests/havelib/rpathz/configure.ac: New file, from
1082         gettext/autoconf-lib-link with modifications.
1083         * tests/havelib/rpathlx/usex.c: New file, from
1084         gettext/autoconf-lib-link.
1085         * tests/havelib/rpathlx/Makefile.am: New file, from
1086         gettext/autoconf-lib-link.
1087         * tests/havelib/rpathlx/configure.ac: New file, from
1088         gettext/autoconf-lib-link with modifications.
1089         * tests/havelib/rpathly/usey.c: New file, from
1090         gettext/autoconf-lib-link.
1091         * tests/havelib/rpathly/Makefile.am: New file, from
1092         gettext/autoconf-lib-link.
1093         * tests/havelib/rpathly/configure.ac: New file, from
1094         gettext/autoconf-lib-link with modifications.
1095         * tests/havelib/rpathlz/usez.c: New file, from
1096         gettext/autoconf-lib-link.
1097         * tests/havelib/rpathlz/Makefile.am: New file, from
1098         gettext/autoconf-lib-link.
1099         * tests/havelib/rpathlz/configure.ac: New file, from
1100         gettext/autoconf-lib-link with modifications.
1101         * tests/havelib/rpathlyx/usey.c: New file, from
1102         gettext/autoconf-lib-link.
1103         * tests/havelib/rpathlyx/Makefile.am: New file, from
1104         gettext/autoconf-lib-link.
1105         * tests/havelib/rpathlyx/configure.ac: New file, from
1106         gettext/autoconf-lib-link with modifications.
1107         * tests/havelib/rpathlzyx/usez.c: New file, from
1108         gettext/autoconf-lib-link.
1109         * tests/havelib/rpathlzyx/Makefile.am: New file, from
1110         gettext/autoconf-lib-link.
1111         * tests/havelib/rpathlzyx/configure.ac: New file, from
1112         gettext/autoconf-lib-link with modifications.
1113         * tests/havelib/rpathcfg.sh: New file, from gettext/autoconf-lib-link
1114         with modifications.
1115
1116 2010-04-02  Bruno Haible  <bruno@clisp.org>
1117
1118         gnulib-tool: Create distributed built sources also for the tests.
1119         * gnulib-tool (func_create_testdir): Also generate distributed built
1120         sources in the tests directory.
1121
1122 2010-04-02  Bruno Haible  <bruno@clisp.org>
1123
1124         gnulib-tool: Obey user's environment variables.
1125         * gnulib-tool (func_create_testdir): When creating built sources,
1126         respect the environment variables for autoconf, automake, etc. given by
1127         the user.
1128
1129 2010-04-02  Bruno Haible  <bruno@clisp.org>
1130
1131         gnulib-tool: Provide the value of --m4-base to modules.
1132         * gnulib-tool (func_import, func_create_testdir): Emit a definition
1133         of gl_m4_base.
1134
1135 2010-04-02  Eric Blake  <eblake@redhat.com>
1136
1137         maint.mk: fix some fallout
1138         * NEWS: Document the incompatible change, and its effect on cfg.mk.
1139         * top/maint.mk (sc_prohibit_test_minus_ao): Update.
1140
1141 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
1142
1143         maint.mk: _sc_search_regexp: generalize and rename from _prohibit_regexp
1144         * top/maint.mk (_sc_search_regexp): Rename from _prohibit_regexp.
1145         (sc_cast_of_argument_to_free): Adapt to use _sc_search_regexp.
1146         (sc_cast_of_x_alloc_return_value): Likewise.
1147         (sc_cast_of_alloca_return_value): Likewise.
1148         (sc_space_tab): Likewise.
1149         (sc_prohibit_atoi_atof): Likewise.
1150         (sc_prohibit_magic_number_exit): Likewise.
1151         (sc_error_exit_success): Likewise.
1152         (sc_file_system): Likewise.
1153         (sc_prohibit_have_config_h): Likewise.
1154         (sc_require_config_h): Likewise.
1155         (sc_prohibit_HAVE_MBRTOWC): Likewise.
1156         (sc_obsolete_symbols): Likewise.
1157         (sc_changelog): Likewise.
1158         (sc_program_name): Likewise.
1159         (sc_the_the): Likewise.
1160         (sc_trailing_blank): Likewise.
1161         (sc_two_space_separator_in_usage): Likewise.
1162         (sc_useless_cpp_parens): Likewise.
1163         (sc_GPL_version): Likewise.
1164         (sc_GFDL_version): Likewise.
1165         (sc_texinfo_acronym): Likewise.
1166         (sc_prohibit_cvs_keyword): Likewise.
1167         (sc_prohibit_stat_st_blocks): Likewise.
1168         (sc_prohibit_S_IS_definition): Likewise.
1169         (sc_redundant_const): Likewise.
1170         (sc_makefile_TAB_only_indentation): Likewise.
1171         (sc_m4_quote_check): Likewise.
1172         (sc_makefile_path_separator_check): Likewise.
1173         (sc_copyright_check): Likewise.
1174         (sc_Wundef_boolean): Likewise.
1175         (sc_vulnerable_makefile_CVE-2009-4029): Likewise.
1176
1177         maint.mk: match 0 or more whitespace-before-function-call '('
1178         * top/maint.mk (sc_error_exit_success): Relax regexp to match uses
1179         that have zero or two-and-more spaces between the function name
1180         and the open parenthesis.
1181         (sc_error_message_warn_fatal): Likewise.
1182         (sc_error_message_uppercase): Likewise.
1183         (sc_error_message_period): Likewise.
1184
1185 2010-03-31  Eric Blake  <eblake@redhat.com>
1186
1187         maint.mk: check for [ as well as test
1188         * top/maint.mk (sc_prohibit_test_minus_ao): Extend test.
1189         Based on a libvirt report by Matthias Bolte.
1190
1191         gnumakefile: don't squelch _version output
1192         * top/GNUmakefile (_version): Create one-shot dependency rather
1193         than using $(shell) when version must be regenerated.
1194         (_autoreconf): Run verbosely, by default.
1195
1196         sys_time: avoid compiler warnings
1197         * lib/sys_time.in.h (includes): Ensure gcc pragma is
1198         unconditional, fixing regression from 2010-03-29.
1199         Reported by Simon Josefsson.
1200
1201 2010-03-28  Jose E. Marchesi  <jemarch@gnu.org>
1202
1203         maint.mk: s/_header_without_use/_sc_header_without_use/
1204         * top/maint.mk (_sc_header_without_use): Rename from _header_without_use.
1205         (sc_prohibit_assert_without_use): Use the new name.
1206         (sc_prohibit_close_stream_without_use): Likewise.
1207         (sc_prohibit_getopt_without_use): Likewise.
1208         (sc_prohibit_quotearg_without_use): Likewise.
1209         (sc_prohibit_quote_without_use): Likewise.
1210         (sc_prohibit_long_options_without_use): Likewise.
1211         (sc_prohibit_inttostr_without_use): Likewise.
1212         (sc_prohibit_ignore_value_without_use): Likewise.
1213         (sc_prohibit_error_without_use): Likewise.
1214         (sc_prohibit_xalloc_without_use): Likewise.
1215         (sc_prohibit_hash_without_use): Likewise.
1216         (sc_prohibit_hash_pjw_without_use): Likewise.
1217         (sc_prohibit_safe_read_without_use): Likewise.
1218         (sc_prohibit_argmatch_without_use): Likewise.
1219         (sc_prohibit_canonicalize_without_use): Likewise.
1220         (sc_prohibit_root_dev_ino_without_use): Likewise.
1221         (sc_prohibit_openat_without_use): Likewise.
1222         (sc_prohibit_c_ctype_without_use): Likewise.
1223         (sc_prohibit_signal_without_use): Likewise.
1224         (sc_prohibit_intprops_without_use): Likewise.
1225
1226 2010-03-30  Eric Blake  <eblake@redhat.com>
1227
1228         maint: improve module indicators
1229         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE)
1230         (gl_MODULE_INDICATOR, gl_MODULE_INDICATOR_FOR_TESTS): Fit in 80
1231         columns, and avoid extra macro expansion.
1232
1233         fdopendir: work around FreeBSD bug
1234         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
1235         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Set it.
1236         * modules/dirent (Makefile.am): Substitute it.
1237         * lib/dirent.in.h (fdopendir): Supply missing FreeBSD
1238         declaration.
1239         * doc/posix-functions/fdopendir.texi (fdopendir): Document the
1240         fix.
1241         Reported by Christian Weisgerber <naddy@mips.inka.de>.
1242
1243 2010-03-29  Bruno Haible  <bruno@clisp.org>
1244
1245         Emit #pragma system_header after the inclusion guard, not before.
1246         * lib/arpa_inet.in.h: Emit #pragma system_header after the inclusion
1247         guard that spans the entire file, not before. This enables an
1248         optimization in GCC's preprocessor.
1249         * lib/ctype.in.h: Likewise.
1250         * lib/dirent.in.h: Likewise.
1251         * lib/errno.in.h: Likewise.
1252         * lib/float.in.h: Likewise.
1253         * lib/getopt.in.h: Likewise.
1254         * lib/iconv.in.h: Likewise.
1255         * lib/langinfo.in.h: Likewise.
1256         * lib/locale.in.h: Likewise.
1257         * lib/math.in.h: Likewise.
1258         * lib/netdb.in.h: Likewise.
1259         * lib/netinet_in.in.h: Likewise.
1260         * lib/pty.in.h: Likewise.
1261         * lib/sched.in.h: Likewise.
1262         * lib/se-selinux.in.h: Likewise.
1263         * lib/search.in.h: Likewise.
1264         * lib/spawn.in.h: Likewise.
1265         * lib/stdarg.in.h: Likewise.
1266         * lib/stdint.in.h: Likewise.
1267         * lib/string.in.h: Likewise.
1268         * lib/strings.in.h: Likewise.
1269         * lib/sys_file.in.h: Likewise.
1270         * lib/sys_ioctl.in.h: Likewise.
1271         * lib/sys_time.in.h: Likewise.
1272         * lib/sys_times.in.h: Likewise.
1273         * lib/sys_utsname.in.h: Likewise.
1274         * lib/sys_wait.in.h: Likewise.
1275         * lib/sysexits.in.h: Likewise.
1276         * lib/wctype.in.h: Likewise.
1277
1278 2010-03-28  James Youngman  <jay@gnu.org>
1279
1280         save-cwd: don't leak a file descriptor when the caller execs.
1281         * lib/save-cwd.c (save_cwd): set the close-on-exec flag for the
1282         saved file descriptor.
1283         * modules/save-cwd (Depends-on): Depend on cloexec.
1284
1285 2010-03-29  Bruno Haible  <bruno@clisp.org>
1286
1287         Remove vestiges of fts-lgpl module.
1288         * lib/fts_.h: Assume GNULIB_FTS is 1.
1289         * lib/fts.c: Likewise.
1290         * modules/fts (configure.ac): Remove gl_MODULE_INDICATOR invocation.
1291
1292 2010-03-28  Bruno Haible  <bruno@clisp.org>
1293
1294         Fix definition of tests witness macro.
1295         * gnulib-tool (func_import): Fix definition of witness macro.
1296
1297 2010-03-28  Bruno Haible  <bruno@clisp.org>
1298
1299         Fix ioctl's protoype on glibc systems.
1300         * lib/sys_ioctl.in.h (ioctl): If REPLACE_IOCTL is 1, use a wrapper. Use
1301         _GL_CXXALIAS_SYS, not _GL_CXXALIAS_SYS_CAST.
1302         * lib/ioctl.c (rpl_ioctl) [HAVE_IOCTL]: New wrapper.
1303         * modules/ioctl (configure.ac): Test whether ioctl has the POSIX
1304         signature. If not, arrange to replace the ioctl function.
1305         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
1306         REPLACE_IOCTL.
1307         * modules/sys_ioctl (Makefile.am): Substitute REPLACE_IOCTL.
1308         * doc/posix-functions/ioctl.texi: Mention the glibc problem.
1309         Reported by Ludovic Courtès <ludo@gnu.org>.
1310
1311 2010-03-28  Javier Villavicencio  <the_paya@gentoo.org>
1312
1313         exclude: fix the case of globs vs. EXCLUDE_INCLUDE
1314         * lib/exclude.c (excluded_file_pattern_p): Fix logic error that
1315         made it so grep -r --include=GLOB* ... did not work.
1316
1317 2010-03-26  Jim Meyering  <meyering@redhat.com>
1318             Eric Blake  <eblake@redhat.com>
1319
1320         maint.mk: prohibit use of test's -o and -a operators
1321         * top/maint.mk (sc_prohibit_test_minus_ao): New rule.
1322
1323 2010-03-28  Bruno Haible  <bruno@clisp.org>
1324
1325         Remove unused GNULIB_XYZ macro definitions.
1326         * modules/crypto/gc-camellia (configure.ac): Remove gl_MODULE_INDICATOR
1327         invocation.
1328
1329 2010-03-28  Bruno Haible  <bruno@clisp.org>
1330
1331         Mark privileged tests modules.
1332         * modules/idpriv-drop-tests (Status): New section.
1333         * modules/idpriv-droptemp-tests (Status): New section.
1334
1335 2010-03-28  Bruno Haible  <bruno@clisp.org>
1336
1337         Split C++ tests into separate tests modules.
1338         * modules/dirent-c++-tests: New file, extracted from
1339         modules/dirent-tests.
1340         * modules/dirent-tests: Depend on it.
1341         * modules/fcntl-h-c++-tests: New file, extracted from
1342         modules/fcntl-h-tests.
1343         * modules/fcntl-h-tests: Depend on it.
1344         * modules/glob-c++-tests: New file, extracted from modules/glob-tests.
1345         * modules/glob-tests: Depend on it.
1346         * modules/iconv-h-c++-tests: New file, extracted from
1347         modules/iconv-h-tests.
1348         * modules/iconv-h-tests: Depend on it.
1349         * modules/langinfo-c++-tests: New file, extracted from
1350         modules/langinfo-tests.
1351         * modules/langinfo-tests: Depend on it.
1352         * modules/locale-c++-tests: New file, extracted from
1353         modules/locale-tests.
1354         * modules/locale-tests: Depend on it.
1355         * modules/math-c++-tests: New file, extracted from modules/math-tests.
1356         * modules/math-tests: Depend on it.
1357         * modules/pty-c++-tests: New file, extracted from modules/pty-tests.
1358         * modules/pty-tests: Depend on it.
1359         * modules/search-c++-tests: New file, extracted from
1360         modules/search-tests.
1361         * modules/search-tests: Depend on it.
1362         * modules/signal-c++-tests: New file, extracted from
1363         modules/signal-tests.
1364         * modules/signal-tests: Depend on it.
1365         * modules/spawn-c++-tests: New file, extracted from
1366         modules/spawn-tests.
1367         * modules/spawn-tests: Depend on it.
1368         * modules/stdio-c++-tests: New file, extracted from
1369         modules/stdio-tests.
1370         * modules/stdio-tests: Depend on it.
1371         * modules/stdlib-c++-tests: New file, extracted from
1372         modules/stdlib-tests.
1373         * modules/stdlib-tests: Depend on it.
1374         * modules/string-c++-tests: New file, extracted from
1375         modules/string-tests.
1376         * modules/string-tests: Depend on it.
1377         * modules/sys_ioctl-c++-tests: New file, extracted from
1378         modules/sys_ioctl-tests.
1379         * modules/sys_ioctl-tests: Depend on it.
1380         * modules/sys_select-c++-tests: New file, extracted from
1381         modules/sys_select-tests.
1382         * modules/sys_select-tests: Depend on it.
1383         * modules/sys_socket-c++-tests: New file, extracted from
1384         modules/sys_socket-tests.
1385         * modules/sys_socket-tests: Depend on it.
1386         * modules/sys_stat-c++-tests: New file, extracted from
1387         modules/sys_stat-tests.
1388         * modules/sys_stat-tests: Depend on it.
1389         * modules/sys_time-c++-tests: New file, extracted from
1390         modules/sys_time-tests.
1391         * modules/sys_time-tests: Depend on it.
1392         * modules/time-c++-tests: New file, extracted from modules/time-tests.
1393         * modules/time-tests: Depend on it.
1394         * modules/unistd-c++-tests: New file, extracted from
1395         modules/unistd-tests.
1396         * modules/unistd-tests: Depend on it.
1397         * modules/wchar-c++-tests: New file, extracted from
1398         modules/wchar-tests.
1399         * modules/wchar-tests: Depend on it.
1400         * modules/wctype-c++-tests: New file, extracted from
1401         modules/wctype-tests.
1402         * modules/wctype-tests: Depend on it.
1403         Reported by Simon Josefsson.
1404
1405 2010-03-28  Bruno Haible  <bruno@clisp.org>
1406
1407         gnulib-tool: Allow 'foo-tests' module even if there is no module 'foo'.
1408         * gnulib-tool (func_exists_module): New function, extracted from
1409         func_verify_module.
1410         (func_verify_module): Use it.
1411         (func_get_dependencies): Synthetize a dependency from 'foo-tests' to
1412         'foo' only if 'foo' exists.
1413         * doc/gnulib.texi (Extra tests modules): Explain how to split a tests
1414         module.
1415
1416 2010-03-28  Bruno Haible  <bruno@clisp.org>
1417
1418         gnulib-tool: Add support for special categories of tests.
1419         * gnulib-tool: New options --with-c++-tests, --with-longrunning-tests,
1420         --with-privileged-tests, --with-unportable-tests, --with-all-tests.
1421         (func_usage): Document them.
1422         (inc_cxx_tests, inc_longrunning_tests, inc_privileged_tests,
1423         inc_unportable_tests, inc_all_tests): New variables.
1424         (func_acceptable): Consider these variables.
1425         (func_modules_transitive_closure): Make it work when the 'Status' field
1426         consists of multiple words.
1427         (func_import): Store and restore the values of inc_cxx_tests,
1428         inc_longrunning_tests, inc_privileged_tests, inc_unportable_tests,
1429         inc_all_tests in gnulib-comp.m4.
1430         (func_create_testdir): Set inc_all_tests to true.
1431         * doc/gnulib.texi (Extra tests modules): New section.
1432         Suggested by Jim Meyering.
1433
1434 2010-03-28  Bruno Haible  <bruno@clisp.org>
1435
1436         ansi-c++-opt: Allow turning off the C++ build by default.
1437         * m4/ansi-c++.m4 (gl_CXX_CHOICE): Let CXX_CHOICE default to 'no' if
1438         gl_CXX_CHOICE_DEFAULT_NO is defined.
1439         Requested by Eric Blake.
1440
1441 2010-03-28  Bruno Haible  <bruno@clisp.org>
1442
1443         unistd: Avoid #define replacements in C++ mode.
1444         * lib/unistd.in.h (socket, connect, accept, bind, getpeername,
1445         getsockname, getsockopt, listen, recv, send, recvfrom, sendto,
1446         setsockopt, shutdown, select): In C++, attach a warning to the function
1447         if possible, rather than #defining the symbol to a dysfunctional alias.
1448         Reported by John W. Eaton <jwe@gnu.org>.
1449
1450 2010-03-28  Bruno Haible  <bruno@clisp.org>
1451
1452         Fix link errors on mingw.
1453         * lib/sys_ioctl.in.h (ioctl): Fix declaration idiom.
1454         * modules/sys_ioctl-tests (Makefile.am): Link test-sys_ioctl-c++ with
1455         $(LIBSOCKET).
1456         * modules/sys_select-tests (Makefile.am): Link test-sys_select-c++ with
1457         $(LIBSOCKET).
1458
1459 2010-03-28  Bruno Haible  <bruno@clisp.org>
1460             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1461
1462         lib-ignore: Determine different options for different compilers.
1463         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Set a variable which
1464         depends on the current language (C/C++/Fortran). Don't set LDFLAGS.
1465         Add comments.
1466         (_gl_IGNORE_UNUSED_LIBRARIES_OPTIONS): New macro.
1467         * NEWS: Mention the change.
1468
1469 2010-03-27  Bruno Haible  <bruno@clisp.org>
1470
1471         Remove unused GNULIB_XYZ macro definitions.
1472         * modules/dup3 (configure.ac): Remove gl_MODULE_INDICATOR invocation.
1473         * modules/fseek (configure.ac): Likewise.
1474         * modules/ioctl (configure.ac): Likewise.
1475         * modules/open (configure.ac): Likewise.
1476         * modules/stdlib-safer (configure.ac): Likewise.
1477
1478 2010-03-27  Bruno Haible  <bruno@clisp.org>
1479
1480         Add a remark about certain modules.
1481         * modules/malloc (Comment): New section.
1482         * modules/realloc (Comment): Likewise.
1483         * modules/sigpipe (Comment): Likewise.
1484
1485 2010-03-27  Bruno Haible  <bruno@clisp.org>
1486
1487         Resolve conflict between the two kinds of module indicators.
1488         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Define
1489         GNULIB_TEST_XYZ instead of GNULIB_XYZ.
1490         * modules/canonicalize (configure.ac): Invoke
1491         gl_MODULE_INDICATOR_FOR_TESTS.
1492         * tests/test-canonicalize-lgpl.c: Test GNULIB_TEST_XYZ instead of
1493         GNULIB_XYZ.
1494         * tests/test-dirent-c++.cc: Likewise.
1495         * tests/test-dirent-safer.c: Likewise.
1496         * tests/test-dup2.c: Likewise.
1497         * tests/test-fchdir.c: Likewise.
1498         * tests/test-fcntl-h-c++.cc: Likewise.
1499         * tests/test-getopt.c: Likewise.
1500         * tests/test-getopt.h: Likewise.
1501         * tests/test-langinfo-c++.cc: Likewise.
1502         * tests/test-locale-c++.cc: Likewise.
1503         * tests/test-math-c++.cc: Likewise.
1504         * tests/test-pty-c++.cc: Likewise.
1505         * tests/test-search-c++.cc: Likewise.
1506         * tests/test-signal-c++.cc: Likewise.
1507         * tests/test-spawn-c++.cc: Likewise.
1508         * tests/test-stdio-c++.cc: Likewise.
1509         * tests/test-stdlib-c++.cc: Likewise.
1510         * tests/test-string-c++.cc: Likewise.
1511         * tests/test-sys_ioctl-c++.cc: Likewise.
1512         * tests/test-sys_select-c++.cc: Likewise.
1513         * tests/test-sys_socket-c++.cc: Likewise.
1514         * tests/test-sys_stat-c++.cc: Likewise.
1515         * tests/test-sys_time-c++.cc: Likewise.
1516         * tests/test-time-c++.cc: Likewise.
1517         * tests/test-unistd-c++.cc: Likewise.
1518         * tests/test-wchar-c++.cc: Likewise.
1519         * tests/uninorm/test-u8-nfc.c: Likewise.
1520         * tests/uninorm/test-u8-nfd.c: Likewise.
1521         * tests/uninorm/test-u8-nfkc.c: Likewise.
1522         * tests/uninorm/test-u8-nfkd.c: Likewise.
1523         * tests/uninorm/test-u16-nfc.c: Likewise.
1524         * tests/uninorm/test-u16-nfd.c: Likewise.
1525         * tests/uninorm/test-u16-nfkc.c: Likewise.
1526         * tests/uninorm/test-u16-nfkd.c: Likewise.
1527         * tests/uninorm/test-u32-nfc.c: Likewise.
1528         * tests/uninorm/test-u32-nfc-big.c: Likewise.
1529         * tests/uninorm/test-u32-nfd.c: Likewise.
1530         * tests/uninorm/test-u32-nfd-big.c: Likewise.
1531         * tests/uninorm/test-u32-nfkc.c: Likewise.
1532         * tests/uninorm/test-u32-nfkc-big.c: Likewise.
1533         * tests/uninorm/test-u32-nfkd.c: Likewise.
1534         * tests/uninorm/test-u32-nfkd-big.c: Likewise.
1535         * tests/uninorm/test-u32-normalize-big.c: Likewise.
1536
1537 2010-03-27  Bruno Haible  <bruno@clisp.org>
1538
1539         Distinguish two kinds of module indicators.
1540         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_FOR_TESTS): Renamed from
1541         gl_MODULE_INDICATOR.
1542         (gl_MODULE_INDICATOR): New macro.
1543         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
1544         gl_MODULE_INDICATOR_FOR_TESTS instead of gl_MODULE_INDICATOR.
1545         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
1546         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
1547         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
1548         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
1549         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
1550         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
1551         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
1552         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
1553         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
1554         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
1555         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
1556         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
1557         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
1558         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
1559         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
1560         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
1561         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
1562         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
1563         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
1564         * modules/cloexec (configure.ac): Likewise.
1565         * modules/getopt-gnu (configure.ac): Likewise.
1566         * modules/uninorm/u8-normalize (configure.ac): Likewise.
1567         * modules/uninorm/u16-normalize (configure.ac): Likewise.
1568         * modules/uninorm/u32-normalize (configure.ac): Likewise.
1569         * modules/fdopendir (configure.ac): Invoke gl_MODULE_INDICATOR.
1570
1571 2010-03-27  Bruno Haible  <bruno@clisp.org>
1572
1573         New module description field 'Comment'.
1574         * gnulib-tool: New option --extract-comment.
1575         (func_usage): Document it.
1576         (sed_extract_prog, sed_extract_field_header): Support 'Comment' field.
1577         (func_get_comment): New function.
1578         * modules/TEMPLATE-EXTENDED: Add a blank Comment field.
1579
1580 2010-03-27  Bruno Haible  <bruno@clisp.org>
1581
1582         Addendum to 2010-02-07 commit.
1583         * gnulib-tool (func_usage): Document --extract-applicability option.
1584
1585 2010-03-27  Bruno Haible  <bruno@clisp.org>
1586
1587         Use GNULIB_POSIXCHECK instead of GNULIB_PORTCHECK.
1588         * lib/time.in.h (asctime, asctime_r, ctime, ctime_r): Test
1589         GNULIB_POSIXCHECK, not GNULIB_PORTCHECK. Provide compile-time warnings
1590         rather than link errors.
1591
1592 2010-03-27  Bruno Haible  <bruno@clisp.org>
1593
1594         Avoid side effects from tests-related modules on the compilation of lib.
1595         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_CONDITION): New macro.
1596         (gl_MODULE_INDICATOR_SET_VARIABLE): Use its expansion as a value.
1597         * gnulib-tool (func_emit_tests_Makefile_am): Accept a witness_macro
1598         parameter. Emit into AM_CPPFLAGS a definition of the designated C
1599         macro.
1600         (func_import): Define a witness macro. Assign it a value that depends
1601         on the current package. Override gl_MODULE_INDICATOR_CONDITION for the
1602         tests-related modules.
1603         (func_create_testdir): Update func_emit_tests_Makefile_am invocation.
1604         Reported by Jim Meyering.
1605
1606 2010-03-27  Bruno Haible  <bruno@clisp.org>
1607
1608         Factorize common .m4 code.
1609         * m4/gnulib-common.m4 (gl_MODULE_INDICATOR_SET_VARIABLE): New macro.
1610         * m4/arpa_inet_h.m4 (gl_ARPA_INET_MODULE_INDICATOR): Use it.
1611         * m4/ctype.m4 (gl_CTYPE_MODULE_INDICATOR): Likewise.
1612         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Likewise.
1613         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Likewise.
1614         * m4/iconv_h.m4 (gl_ICONV_MODULE_INDICATOR): Likewise.
1615         * m4/inttypes.m4 (gl_INTTYPES_MODULE_INDICATOR): Likewise.
1616         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Likewise.
1617         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Likewise.
1618         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Likewise.
1619         * m4/netdb_h.m4 (gl_NETDB_MODULE_INDICATOR): Likewise.
1620         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Likewise.
1621         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Likewise.
1622         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Likewise.
1623         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Likewise.
1624         * m4/stddef_h.m4 (gl_STDDEF_MODULE_INDICATOR): Likewise.
1625         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Likewise.
1626         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Likewise.
1627         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Likewise.
1628         * m4/strings_h.m4 (gl_STRINGS_MODULE_INDICATOR): Likewise.
1629         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_MODULE_INDICATOR): Likewise.
1630         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Likewise.
1631         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Likewise.
1632         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Likewise.
1633         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Likewise.
1634         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Likewise.
1635         * m4/sys_times_h.m4 (gl_SYS_TIMES_MODULE_INDICATOR): Likewise.
1636         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_MODULE_INDICATOR): Likewise.
1637         * m4/sys_wait_h.m4 (gl_SYS_WAIT_MODULE_INDICATOR): Likewise.
1638         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Likewise.
1639         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Likewise.
1640         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Likewise.
1641
1642 2010-03-27  Bruno Haible  <bruno@clisp.org>
1643
1644         Fix a compilation error on Cygwin with g++ >= 4.3.
1645         * lib/sys_stat.in.h (lchmod): Don't warn about the use of this function
1646         if it is undefined or if we alias it to chmod.
1647         (lstat): Don't warn about the use of this function if it is undefined
1648         or if we alias it to stat.
1649         Reported by Simon Josefsson.
1650
1651 2010-03-27  Bruno Haible  <bruno@clisp.org>
1652
1653         * m4/getlogin.m4 (gl_FUNC_GETLOGIN): Renamed from gl_GETLOGIN.
1654         * modules/getlogin (configure.ac): Update.
1655
1656         * m4/getlogin_r.m4 (gl_FUNC_GETLOGIN_R): Renamed from gl_GETLOGIN_R.
1657         * modules/getlogin_r (configure.ac): Update.
1658
1659         * m4/inet_ntop.m4 (gl_FUNC_INET_NTOP): Renamed from gl_INET_NTOP.
1660         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Update.
1661         * modules/inet_ntop (configure.ac): Update.
1662
1663         * m4/inet_pton.m4 (gl_FUNC_INET_PTON): Renamed from gl_INET_PTON.
1664         * modules/inet_pton (configure.ac): Update.
1665
1666         * m4/mbslen.m4 (gl_FUNC_MBSLEN): Renamed from gl_MBSLEN.
1667         * modules/mbslen (configure.ac): Update.
1668
1669         * m4/pty.m4 (gl_FUNC_FORKPTY): Renamed from gl_FORKPTY.
1670         (gl_FUNC_OPENPTY): Renamed from gl_OPENPTY.
1671         * modules/forkpty (configure.ac): Update.
1672         * modules/openpty (configure.ac): Update.
1673
1674 2010-03-26  Simon Josefsson  <simon@josefsson.org>
1675
1676         * top/maint.mk (sc_texinfo_acronym): Don't infloop if there is
1677         no *.texi files.  Reported by Eric Blake <eblake@redhat.com>.
1678
1679 2010-03-25  Eric Blake  <eblake@redhat.com>
1680
1681         maint: use pragma consistently across replacement headers
1682         * lib/ctype.in.h (system_header): Hoist for consistent placement.
1683         * lib/dirent.in.h (system_header): Likewise.
1684         * lib/errno.in.h (system_header): Likewise.
1685         * lib/float.in.h (system_header): Likewise.
1686         * lib/getopt.in.h (system_header): Likewise.
1687         * lib/iconv.in.h (system_header): Likewise.
1688         * lib/inttypes.in.h (system_header): Likewise.
1689         * lib/langinfo.in.h (system_header): Likewise.
1690         * lib/locale.in.h (system_header): Likewise.
1691         * lib/math.in.h (system_header): Likewise.
1692         * lib/netdb.in.h (system_header): Likewise.
1693         * lib/netinet_in.in.h (system_header): Likewise.
1694         * lib/pty.in.h (system_header): Likewise.
1695         * lib/sched.in.h (system_header): Likewise.
1696         * lib/se-selinux.in.h (system_header): Likewise.
1697         * lib/search.in.h (system_header): Likewise.
1698         * lib/spawn.in.h (system_header): Likewise.
1699         * lib/stdarg.in.h (system_header): Likewise.
1700         * lib/stdint.in.h (system_header): Likewise.
1701         * lib/string.in.h (system_header): Likewise.
1702         * lib/strings.in.h (system_header): Likewise.
1703         * lib/sys_file.in.h (system_header): Likewise.
1704         * lib/sys_ioctl.in.h (system_header): Likewise.
1705         * lib/sys_socket.in.h (system_header): Likewise.
1706         * lib/sys_times.in.h (system_header): Likewise.
1707         * lib/sys_utsname.in.h (system_header): Likewise.
1708         * lib/sys_wait.in.h (system_header): Likewise.
1709         * lib/sysexits.in.h (system_header): Likewise.
1710         * lib/unistd.in.h (system_header): Likewise.
1711         * lib/wctype.in.h (system_header): Likewise.
1712
1713         arpa/inet: fix mingw compilation warning
1714         * lib/arpa_inet.in.h (system_header): Hoist to be unconditional.
1715         Reported by Matthew Bolte.
1716
1717 2010-03-25  Bruno Haible  <bruno@clisp.org>
1718
1719         Avoid collision between gnulib wrapper and libintl wrapper.
1720         * lib/printf.c (printf): Don't define if a printf wrapper is already
1721         defined in intl/printf.c.
1722         Reported by Michel Boaventura <michel@michelboaventura.com>.
1723
1724 2010-03-25  Bruno Haible  <bruno@clisp.org>
1725
1726         Use ANSI C.
1727         * lib/readutmp.h (getutent): Provide ANSI C prototype.
1728
1729 2010-03-25  Bruno Haible  <bruno@clisp.org>
1730
1731         Minor formatting changes.
1732         * lib/acosl.c: Insert space before function argument list.
1733         * lib/argz.c: Likewise.
1734         * lib/asinl.c: Likewise.
1735         * lib/expl.c: Likewise.
1736         * lib/gen-uni-tables.c: Likewise.
1737         * lib/gettext.h: Likewise.
1738         * lib/glthread/lock.h: Likewise.
1739         * lib/tanl.c: Likewise.
1740         * lib/uniname/uniname.c: Likewise.
1741         * tests/test-idpriv-drop.c: Likewise.
1742         * tests/test-idpriv-droptemp.c: Likewise.
1743         * tests/test-lock.c: Likewise.
1744         * tests/test-tls.c: Likewise.
1745         * lib/argp-help.c: Insert space before function-like macro argument
1746         list.
1747         * lib/memcmp.c: Likewise.
1748         * tests/test-base64.c: Likewise.
1749         * lib/localename.c: Insert space before sizeof's argument list.
1750         * lib/safe-alloc.h: Likewise.
1751         * lib/file-set.h: Insert space before macro argument list.
1752         * tests/test-argp.c: Likewise.
1753         * lib/argp-namefrob.h: Insert space before function parameter list.
1754         * lib/getaddrinfo.c: Likewise.
1755         * lib/netdb.in.h: Likewise.
1756         * lib/parse-duration.h: Likewise.
1757         * lib/parse-duration.c: Likewise.
1758         * lib/poll.c: Likewise.
1759         * lib/select.c: Likewise.
1760         * lib/trim.h: Likewise.
1761         * tests/test-usleep.c: Likewise.
1762         * lib/ldexpl.c: Insert space before function parameter list and before
1763         function argument list.
1764         * lib/logl.c: Likewise.
1765         * lib/sqrtl.c: Likewise.
1766         * lib/trim.c: Likewise.
1767         * lib/cosl.c: Use GNU style indentation. Insert space before function
1768         argument list.
1769         * lib/sinl.c: Likewise.
1770         * lib/tsearch.c: Insert space after 'for'.
1771         Reported by Jim Meyering.
1772
1773 2010-03-23  Pádraig Brady  <P@draigBrady.com>  (tiny change)
1774
1775         * maint.mk (sc_Wundef_boolean): Check for the presence of the
1776         config header before grepping, as it's not present before
1777         autoreconf/configure are run.  Reported by Simon Josefsson.
1778
1779 2010-03-23  Bruno Haible  <bruno@clisp.org>
1780
1781         pt_chown: Make it work with automake < 1.11.
1782         * modules/pt_chown (Makefile.am): Define pkglibexecdir.
1783         Reported by Simon Josefsson.
1784
1785 2010-03-23  Bruno Haible  <bruno@clisp.org>
1786
1787         pt_chown: Don't depend on GPLed modules.
1788         * lib/pt_chown.c: Don't include idpriv.h.
1789         (main): Don't drop privileges.
1790         * modules/pt_chown (Depends-on): Remove idpriv-drop.
1791         Reported by Simon Josefsson.
1792
1793 2010-03-24  Simon Josefsson  <simon@josefsson.org>
1794
1795         * top/maint.mk (sc_texinfo_acronym): Add rule, based on
1796         suggestions from karl@freefriends.org (Karl Berry).
1797
1798 2010-03-22  Eric Blake  <eblake@redhat.com>
1799
1800         gethostname: further tweaks
1801         * lib/unistd.in.h (includes): Only worry about <winsock2.h> if we
1802         are overriding gethostname.
1803         Suggested by Bruno Haible.
1804
1805 2010-03-21  Bruno Haible  <bruno@clisp.org>
1806
1807         Fix comments.
1808         * lib/forkpty.c (rpl_forkpty): Fix comment.
1809         * lib/openpty.c (rpl_openpty): Likewise.
1810         Reported by Eric Blake.
1811
1812 2010-03-22  Eric Blake  <eblake@redhat.com>
1813
1814         gethostname: fix build on mingw
1815         * lib/unistd.in.h (includes): Work around fact that mingw
1816         <winsock2.h> re-includes <unistd.h>, by avoiding any
1817         redeclarations if we are being included by <winsock2.h>.
1818         Reported by Matthias Bolte.
1819
1820 2010-03-21  Bruno Haible  <bruno@clisp.org>
1821
1822         forkpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
1823         * lib/forkpty.c (forkpty): New replacement function, from glibc with
1824         modifications.
1825         * lib/pty.in.h (forkpty): Update declaration. Add comments.
1826         * m4/pty.m4 (gl_FORKPTY): If forkpty is not declared, arrange to
1827         provide the replacement.
1828         * modules/forkpty (Depends-on): Add openpty, login_tty.
1829         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_FORKPTY.
1830         * modules/pty (Makefile.am): Substitute HAVE_FORKPTY.
1831         * doc/glibc-functions/forkpty.texi: More supported platforms.
1832         * config/srclist.txt: Add forkpty.c (commented).
1833
1834 2010-03-21  Bruno Haible  <bruno@clisp.org>
1835
1836         * modules/forkpty-tests: Use the common TEMPLATE-TESTS.
1837         (Makefile.am): Verify that PTY_LIB is defined.
1838
1839         * modules/openpty-tests: Use the common TEMPLATE-TESTS.
1840
1841 2010-03-21  Bruno Haible  <bruno@clisp.org>
1842
1843         Tests for module 'login_tty'.
1844         * modules/login_tty-tests: New file.
1845         * tests/test-login_tty.c: New file.
1846
1847         New module 'login_tty'.
1848         * lib/login_tty.c: New file.
1849         * m4/pty.m4 (gl_FUNC_LOGIN_TTY): New macro.
1850         * modules/login_tty: New file.
1851         * doc/glibc-functions/login_tty.texi: Mention the new module.
1852
1853 2010-03-21  Bruno Haible  <bruno@clisp.org>
1854
1855         login_tty: Documentation.
1856         * doc/glibc-functions/login_tty.texi: New file.
1857         * doc/gnulib.texi (Glibc <utmp.h>): Include it.
1858
1859 2010-03-21  Bruno Haible  <bruno@clisp.org>
1860
1861         pty: Consistent macro naming.
1862         * m4/pty_h.m4 (gl_PTY_H): Renamed from gl_PTY.
1863         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): Update.
1864         * modules/pty (configure.ac): Update.
1865
1866 2010-03-21  Bruno Haible  <bruno@clisp.org>
1867
1868         Tests for openpty: Make stricter.
1869         * tests/test-openpty.c (main): Add test of canonical processing and
1870         erase.
1871         * modules/openpty-tests (Makefile.am): Verify that PTY_LIB is defined.
1872
1873         openpty: Provide replacement on AIX, HP-UX, IRIX, Solaris.
1874         * lib/openpty.c (openpty): New replacement function.
1875         * lib/pty.in.h: Include <termios.h>.
1876         (openpty): Update declaration. Add comments.
1877         * m4/pty.m4 (gl_OPENPTY): Require AC_USE_SYSTEM_EXTENSIONS. If openpty
1878         is not declared, arrange to provide the replacement. Check for _getpty
1879         and posix_openpt.
1880         * modules/openpty (Depends-on): Add extensions, fcntl-h, ioctl.
1881         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Initialize HAVE_OPENPTY.
1882         * modules/pty (Makefile.am): Substitute HAVE_OPENPTY.
1883         * modules/pty-tests (test_pty_c___LDADD): New variable.
1884         * doc/glibc-functions/openpty.texi: More supported platforms.
1885
1886 2010-03-21  Bruno Haible  <bruno@clisp.org>
1887
1888         setenv: Tweaks.
1889         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Include necessary headers in
1890         the test program.
1891         * doc/posix-functions/setenv.texi: Update platforms list.
1892
1893 2010-03-21  Bruno Haible  <bruno@clisp.org>
1894
1895         New module 'unlockpt'.
1896         * lib/unlockpt.c: New file, from glibc with modifications.
1897         * m4/unlockpt.m4: New file.
1898         * modules/unlockpt: New file.
1899         * lib/stdlib.in.h (unlockpt): New declaration.
1900         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether unlockpt is declared.
1901         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_UNLOCKPT, HAVE_UNLOCKPT.
1902         * modules/stdlib (Makefile.am): Substitute GNULIB_UNLOCKPT,
1903         HAVE_UNLOCKPT.
1904         * doc/posix-functions/unlockpt.texi: Mention the new module.
1905         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::unlockpt.
1906         * config/srclist.txt: Add unlockpt.c (commented).
1907
1908 2010-03-21  Jim Meyering  <meyering@redhat.com>
1909
1910         maint.mk: prohibit inclusion of "intprops.h" without use
1911         * top/maint.mk (sc_prohibit_intprops_without_use): New rule.
1912
1913 2010-03-21  Bruno Haible  <bruno@clisp.org>
1914
1915         New module 'grantpt'.
1916         * lib/grantpt.c: New file, from glibc with modifications.
1917         * m4/grantpt.m4: New file.
1918         * modules/grantpt: New file.
1919         * lib/stdlib.in.h (grantpt): New declaration.
1920         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether grantpt is declared.
1921         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GRANTPT, HAVE_GRANTPT.
1922         * modules/stdlib (Makefile.am): Substitute GNULIB_GRANTPT,
1923         HAVE_GRANTPT.
1924         * doc/posix-functions/grantpt.texi: Mention the new module.
1925         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::grantpt.
1926         * config/srclist.txt: Add grantpt.c (commented).
1927
1928 2010-03-21  Bruno Haible  <bruno@clisp.org>
1929
1930         New module 'pt_chown'.
1931         * lib/pt_chown.c: New file, from glibc with modifications.
1932         * lib/pty-private.h: New file, from glibc with modifications.
1933         * modules/pt_chown: New file.
1934         * config/srclist.txt: Add pt_chown.c, pty-private.h (commented).
1935
1936 2010-03-21  Bruno Haible  <bruno@clisp.org>
1937
1938         Tests for module 'ptsname'.
1939         * modules/ptsname-tests: New file.
1940         * tests/test-ptsname.c: New file.
1941
1942         New module 'ptsname'.
1943         * lib/ptsname.c: New file, from glibc with modifications.
1944         * m4/ptsname.m4: New file.
1945         * modules/ptsname: New file.
1946         * lib/stdlib.in.h (ptsname): New declaration.
1947         * m4/stdlib_h.m4 (gl_STDLIB_H): Check whether ptsname is declared.
1948         (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PTSNAME, HAVE_PTSNAME.
1949         * modules/stdlib (Makefile.am): Substitute GNULIB_PTSNAME,
1950         HAVE_PTSNAME.
1951         * doc/posix-functions/ptsname.texi: Mention the new module.
1952         * tests/test-stdlib-c++.cc: Check GNULIB_NAMESPACE::ptsname.
1953         * config/srclist.txt: Add ptsname.c (commented).
1954
1955 2010-03-21  Bruno Haible  <bruno@clisp.org>
1956
1957         Tests for module 'ttyname_r'.
1958         * modules/ttyname_r-tests: New file.
1959         * tests/test-ttyname_r.c: New file.
1960
1961         New module 'ttyname_r'.
1962         * lib/ttyname_r.c: New file.
1963         * m4/ttyname_r.m4: New file.
1964         * modules/ttyname_r: New file.
1965         * lib/unistd.in.h (ttyname_r): New declaration.
1966         * m4/unistd_h.m4 (gl_UNISTD_H): Check whether ttyname_r is declared.
1967         (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_TTYNAME_R, HAVE_TTYNAME_R.
1968         * modules/unistd (Makefile.am): Substitute GNULIB_TTYNAME_R,
1969         HAVE_TTYNAME_R.
1970         * tests/test-unistd-c++.cc: Check GNULIB_NAMESPACE::ttyname_r.
1971         * doc/posix-functions/ttyname_r.texi: Mention the new module.
1972
1973 2010-03-20  Bruno Haible  <bruno@clisp.org>
1974
1975         signal: Undefine macro definitions in C++ mode.
1976         * lib/signal.in.h (sigismember, sigemptyset, sigaddset, sigdelset,
1977         sigfillset): Undefine macro definitions from the system header in C++
1978         mode.
1979         Reported by John W. Eaton <jwe@gnu.org>.
1980
1981 2010-03-20  Bruno Haible  <bruno@clisp.org>
1982
1983         Ensure no #include statements inside extern "C" { ... }.
1984         * lib/obstack.h: Shrink extern "C" { ... } region so that it does not
1985         contain #include statements.
1986         * lib/time.in.h: Likewise.
1987
1988 2010-03-20  Bruno Haible  <bruno@clisp.org>
1989
1990         Make _GL_WARN_ON_USE usable in C++ and C mode in the same compilation.
1991         * build-aux/warn-on-use.h (_GL_WARN_EXTERN_C): New macro.
1992         (_GL_WARN_ON_USE, _GL_WARN_ON_USE_CXX): Likewise.
1993         Reported by John W. Eaton <jwe@gnu.org>.
1994
1995 2010-03-20  Bruno Haible  <bruno@clisp.org>
1996
1997         * m4/unlink.m4 (gl_FUNC_UNLINK): Fix last commit.
1998         Reported by Jim Meyering.
1999
2000 2010-03-20  Bruno Haible  <bruno@clisp.org>
2001
2002         pipe: Set errno upon failure.
2003         * lib/pipe.h: Specify that when -1 is returned, errno is set.
2004         * lib/pipe.c (create_pipe): Set errno when returning -1. Use the right
2005         errno value in error message.
2006
2007 2010-03-20  Bruno Haible  <bruno@clisp.org>
2008             Jim Meyering  <meyering@redhat.com>
2009
2010         lchown: Avoid "unused variable" warning.
2011         * lib/lchown.c (rpl_lchown): Move variable 'st' into #if block.
2012
2013 2010-03-20  Bruno Haible  <bruno@clisp.org>
2014
2015         Work around unlink() bug on MacOS X 10.5.6.
2016         * lib/unlink.c (rpl_unlink): If UNLINK_PARENT_BUG is defined, fail when
2017         attempting to unlink a parent directory.
2018         * m4/unlink.m4 (gl_FUNC_UNLINK): Require AC_CANONICAL_HOST. Test for
2019         MacOS X 10.5 bug. If the bug is present, define UNLINK_PARENT_BUG and
2020         activate for the replacement function.
2021         * doc/posix-functions/unlink.texi: Mention the MacOS X 10.5 bug.
2022
2023 2010-03-20  Bruno Haible  <bruno@clisp.org>
2024
2025         Fix link errors on Solaris 8.
2026         * modules/dirent-tests (test_dirent_c___LDADD): Add LIB_NANOSLEEP.
2027         * modules/wctype-tests (test_wctype_c___LDADD): Likewise.
2028
2029 2010-03-19  Jim Meyering  <meyering@redhat.com>
2030
2031         regcomp.c: make non-_LIBC implementation of build_range_exp consistent
2032         The _LIBC implementation of build_range_exp correctly honors the
2033         RE_NO_EMPTY_RANGES flag when checking for reversed range endpoints.
2034         However, the non-_LIBC implementation would ignore that syntax-bit
2035         flag and return REG_ERANGE unconditionally.
2036         This change makes it honor that flag.
2037         * lib/regcomp.c (build_range_exp) [!_LIBC]: Add a parameter: "syntax".
2038         Make two pointer parameters "const".
2039         Use "syntax" bits in order to honor RE_NO_EMPTY_RANGES.
2040         (parse_bracket_exp): Update caller.
2041
2042         regex.m4: correct the reversed range endpoint ([b-a]) test
2043         * m4/regex.m4: When requiring that [b-a] evoke failure,
2044         use RE_NO_EMPTY_RANGES.  This makes this entire configure-time
2045         test pass once again for x86-based systems.
2046
2047 2010-03-19  Bruno Haible  <bruno@clisp.org>
2048
2049         scandir: Fix link error on Solaris 8.
2050         * lib/scandir.c (_D_EXACT_NAMLEN, _D_ALLOC_NAMLEN): New fallback
2051         macros.
2052
2053 2010-03-19  Bruno Haible  <bruno@clisp.org>
2054
2055         getusershell: Fix documentation.
2056         * doc/glibc-functions/endusershell.texi: Refer to the getusershell
2057         module.
2058         * doc/glibc-functions/setusershell.texi: Likewise.
2059
2060         getusershell: Provide declaration, missing on Solaris 9.
2061         * lib/unistd.in.h (getusershell, setusershell, endusershell): Declare
2062         also if HAVE_GETUSERSHELL && !HAVE_DECL_GETUSERSHELL.
2063         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): When the function exists,
2064         check whether it is declared. Set HAVE_DECL_GETUSERSHELL.
2065         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
2066         HAVE_DECL_GETUSERSHELL, not HAVE_GETUSERSHELL.
2067         * modules/unistd (Makefile.am): Substitute HAVE_DECL_GETUSERSHELL, not
2068         HAVE_GETUSERSHELL.
2069         * doc/glibc-functions/getusershell.texi: Mention the Solaris problem.
2070
2071 2010-03-19  Bruno Haible  <bruno@clisp.org>
2072
2073         wctype: Provide iswblank function.
2074         * lib/wctype.in.h (iswblank): Provide a replacement also when iswcntrl
2075         exists and is fine.
2076         * m4/wctype_h.m4 (gl_WCTYPE_H): Also check whether iswcntrl exists.
2077         * modules/wctype (Makefile.am): Substitute HAVE_ISWBLANK.
2078         * tests/test-wctype.c (main): Re-enable the iswblank tests.
2079         * doc/posix-functions/iswblank.texi: Update.
2080
2081 2010-03-19  Bruno Haible  <bruno@clisp.org>
2082
2083         Tests of module 'pty' in C++ mode.
2084         * modules/pty-tests: New file.
2085         * tests/test-pty-c++.cc: New file.
2086         * m4/pty_h.m4 (gl_PTY_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
2087
2088 2010-03-19  Eric Blake  <eblake@redhat.com>
2089
2090         logb: fix documentation
2091         * doc/posix-functions/logb.texi (logb): Gnulib fixes the cygwin
2092         1.5 declaration bug.
2093
2094         forkpty, openpty: prefer glibc's const-safe prototype
2095         * lib/forkpty.c (rpl_forkpty): New file.
2096         * lib/openpty.c (rpl_openpty): Likewise.
2097         * modules/forkpty (Files): Distribute it.
2098         * modules/openpty (Files): Likewise.
2099         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.  Move decl
2100         check...
2101         * m4/pty.m4 (gl_FORKPTY, gl_OPENPTY): ...here.  Request
2102         replacement for for non-const BSD signature.
2103         * modules/pty (Makefile.am): Substitute witnesses.
2104         * lib/pty.in.h (forkpty, openpty): Declare replacements.
2105         * tests/test-forkpty.c: Update signature check.
2106         * tests/test-openpty.c: Likewise.
2107         * doc/glibc-functions/forkpty.texi (forkpty): Document the fix.
2108         * doc/glibc-functions/openpty.texi (openpty): Likewise.
2109
2110         forkpty, openpty: split functions into new modules
2111         * modules/pty (Makefile.am): Substitute new witnesses.
2112         (Libraries): Move library detection...
2113         * modules/forkpty: ...into new module.
2114         * modules/openpty: Another new module.
2115         * modules/pty-tests: Rename and split...
2116         * modules/forkpty-tests: ...to this...
2117         * modules/openpty-tests: ...and this.
2118         * tests/test-pty.c: Rename and split...
2119         * tests/test-forkpty.c: ...to this...
2120         * tests/test-openpty.c: ...and this.
2121         * m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Add new witnesses.
2122         (gl_PTY): Split library searching...
2123         * m4/pty.m4 (gl_PTY_LIB): ...into new file.
2124         (gl_FORKPTY, gl_OPENPTY): New macros.
2125         * lib/pty.in.h (forkpty, openpty): Honor new witnesses.
2126         * NEWS: Mention the split.
2127         * MODULES.html.sh (Misc): Document the modules.
2128         * doc/glibc-functions/forkpty.texi (forkpty): Likewise.
2129         * doc/glibc-functions/openpty.texi (openpty): Likewise.
2130
2131         pty: improve replacement header
2132         * lib/pty.in.h: New file.
2133         * modules/pty (Files): Ship it.
2134         (Makefile.am): Always build replacement.
2135         * m4/pty.m4: Rename...
2136         * m4/pty_h.m4: ...to this.
2137         (gl_PTY): Modernize setting of witness macros; update check of
2138         forkpty to take proper advantage of cache.
2139         (gl_PTY_MODULE_INDICATOR, gl_PTY_H_DEFAULTS): New macros.
2140
2141         getopt: avoid compiler warning
2142         * lib/getopt.c (attribute_hidden): Remove unused macro.
2143
2144 2010-03-18  Bruno Haible  <bruno@clisp.org>
2145
2146         Fix link errors on Solaris 8.
2147         * modules/iconv-h-tests (test_iconv_h_c___LDADD): Add LIB_NANOSLEEP.
2148         * modules/search-tests (test_search_c___LDADD): Likewise.
2149         * modules/signal-tests (test_signal_c___LDADD): Likewise.
2150         * modules/spawn-tests (test_spawn_c___LDADD): Likewise.
2151         * modules/stdio-tests (test_stdio_c___LDADD): Likewise.
2152         * modules/sys_select-tests (test_sys_select_c___LDADD): Likewise.
2153         * modules/sys_socket-tests (test_sys_socket_c___LDADD): Likewise.
2154         * modules/sys_time-tests (test_sys_time_c___LDADD): Likewise.
2155         * modules/wchar-tests (test_wchar_c___LDADD): Likewise.
2156
2157 2010-03-18  Bruno Haible  <bruno@clisp.org>
2158
2159         Fix bug introduced on 2010-03-14.
2160         * m4/spawn_h.m4 (gl_HAVE_POSIX_SPAWN): New macro.
2161         (gl_SPAWN_H): Require it.
2162         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Likewise.
2163         Reported by Simon Josefsson.
2164
2165 2010-03-18  Bruno Haible  <bruno@clisp.org>
2166
2167         Fix typo introduced on 2009-12-31.
2168         * m4/spawn_h.m4 (gl_SPAWN_H): Check for the declaration of
2169         posix_spawn_file_actions_adddup2.
2170
2171 2010-03-17  Bert Wesarg  <bert.wesarg@googlemail.com>  (tiny change)
2172         and Eric Blake  <eblake@redhat.com>
2173
2174         test-vc-list-files-git: make more robust
2175         * tests/test-vc-list-files-git.sh: Unset problematic environment
2176         variables.  Chain commands together.
2177
2178 2010-03-17  Ludovic Courtès <ludo@gnu.org>  (tiny change)
2179
2180         * m4/pty.m4: Unset $ac_cv_have_decl_forkpty before the second
2181         `AC_CHECK_DECL' invocation.
2182
2183 2010-03-15  Sergey Poznyakoff  <gray@gnu.org.ua>
2184
2185         * lib/inttostr.c (inttostr): Make sure the invocation of verify
2186         appears before executable statements. Suggested by Petr Sumbera
2187         <Petr.Sumbera@Sun.COM>.
2188
2189 2010-03-14  Bruno Haible  <bruno@clisp.org>
2190
2191         * tests/test-flock.c (test_exclusive): Comment out a test that causes
2192         portability problems. Instead use a simpler test.
2193         (main): Check that invalid arguments are rejected only on Linux.
2194
2195 2010-03-14  Bruno Haible  <bruno@clisp.org>
2196
2197         Fix bug introduced on 2009-12-31.
2198         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
2199         gl_PREREQ_SYS_H_WINSOCK2 always.
2200         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise. Remove
2201         SYS_SOCKET_H variable.
2202         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Remove test for flock.
2203         Update comments.
2204         * m4/ctype.m4 (gl_CTYPE_H): Update comments.
2205         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
2206         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
2207         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
2208         * m4/sys_wait_h.m4 (gl_SYS_WAIT_H): Likewise.
2209
2210 2010-03-14  Bruno Haible  <bruno@clisp.org>
2211
2212         Fix values returned by sinl, cosl.
2213         * lib/trigl.h: Add specification comments.
2214         * lib/sincosl.c (kernel_sinl, kernel_cosl): Fix comments and formula
2215         that combines the values from the precomputed table with the values of
2216         the Chebyshev polynomials.
2217
2218 2010-03-14  Bruno Haible  <bruno@clisp.org>
2219
2220         Fix compilation error when modules 'posix_spawn[p]' are not used.
2221         * m4/spawn_h.m4 (gl_SPAWN_H): Set HAVE_POSIX_SPAWN here.
2222         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): ... not here.
2223
2224 2010-03-14  Bruno Haible  <bruno@clisp.org>
2225
2226         Fix compilation error on mingw when module 'time_r' is not used.
2227         * lib/time.in.h (localtime_r, gmtime_r): Declare only if GNULIB_TIME_R
2228         is 1.
2229         * tests/test-time-c++.cc (localtime_r, gmtime_r): Likewise.
2230         * modules/time_r (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
2231         * modules/time (Makefile.am): Substitute GNULIB_TIME_R.
2232         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize GNULIB_TIME_R.
2233
2234 2010-03-14  Bruno Haible  <bruno@clisp.org>
2235
2236         Fix compilation error with Sun C.
2237         * lib/strtol.c: Use LLONG_MIN instead of GCC specific LONG_LONG_MIN.
2238         Use LLONG_MAX instead of GCC specific LONG_LONG_MAX. Use ULLONG_MAX
2239         instead of GCC specific ULONG_LONG_MAX.
2240         * lib/xstrtoll.c: Likewise.
2241         * lib/xstrtoull.c: Likewise.
2242
2243 2010-03-13  Bruno Haible  <bruno@clisp.org>
2244
2245         Allow the user to disable C++ code and tests.
2246         * m4/ansi-c++.m4 (gl_CXX_CHOICE): New macro.
2247         (gl_PROG_ANSI_CXX): Require it.
2248
2249 2010-03-13  Bruno Haible  <bruno@clisp.org>
2250
2251         * DEPENDENCIES (libtool): Mention libtool 2.2.x requirement in special
2252         cases.
2253
2254 2010-03-13  Bruno Haible  <bruno@clisp.org>
2255
2256         Test that gnulib does not break the standard C++ headers.
2257         * tests/test-locale-c++2.cc: New file.
2258         * modules/locale-tests (Files): Add it.
2259         (Makefile.am): Compile it for test-locale-c++.
2260         * tests/test-math-c++2.cc: New file.
2261         * modules/math-tests (Files): Add it.
2262         (Makefile.am): Compile it for test-math-c++.
2263         * tests/test-signal-c++2.cc: New file.
2264         * modules/signal-tests (Files): Add it.
2265         (Makefile.am): Compile it for test-signal-c++.
2266         * tests/test-stdio-c++2.cc: New file.
2267         * modules/stdio-tests (Files): Add it.
2268         (Makefile.am): Compile it for test-stdio-c++.
2269         * tests/test-stdlib-c++2.cc: New file.
2270         * modules/stdlib-tests (Files): Add it.
2271         (Makefile.am): Compile it for test-stdlib-c++.
2272         * tests/test-string-c++2.cc: New file.
2273         * modules/string-tests (Files): Add it.
2274         (Makefile.am): Compile it for test-string-c++.
2275         * tests/test-time-c++2.cc: New file.
2276         * modules/time-tests (Files): Add it.
2277         (Makefile.am): Compile it for test-time-c++.
2278         Reported by John W. Eaton <jwe@gnu.org>.
2279
2280 2010-03-13  Bruno Haible  <bruno@clisp.org>
2281
2282         * gnulib-tool (func_usage): Clarify which options are available for
2283         --create-testdir and --create-megatestdir.
2284
2285 2010-03-13  Bruno Haible  <bruno@clisp.org>
2286
2287         Fix compilation error with glibc >= 2.10 and g++ >= 4.4.
2288         * build-aux/warn-on-use.h (_GL_WARN_ON_USE_CXX): New macro.
2289         * build-aux/c++defs.h (_GL_CXXALIASWARN1): New macro.
2290         * lib/string.in.h (memchr, memrchr, rawmemchr, strchrnul, strpbrk,
2291         strstr, strcasestr): Use _GL_CXXALIASWARN1 instead of _GL_CXXALIASWARN
2292         when appropriate.
2293         Reported by Jim Meyering.
2294
2295 2010-03-12  Simon Josefsson  <simon@josefsson.org>
2296
2297         * gnulib-tool (func_import): Explain origin of code.
2298
2299 2010-03-12  Bruno Haible  <bruno@clisp.org>
2300
2301         Fix problem with automake's definition of CXXLINK.
2302         * gnulib-tool (func_create_testdir): After LT_INIT, also use LT_LANG.
2303         Reported by Simon Josefsson and Ludovic Courtès.
2304
2305 2010-03-12  Bruno Haible  <bruno@clisp.org>
2306
2307         * doc/gnulib-intro.texi (Steady Development): Mention Ian Beckwith's
2308         stable releases.
2309
2310 2010-03-11  Bruno Haible  <bruno@clisp.org>
2311
2312         Fix problems with overloaded C++ definitions of memchr, strpbrk, etc.
2313         * build-aux/c++defs.h (_GL_CXXALIAS_SYS_CAST2): Make it work regardless
2314         whether the system provides one variant or multiple variants of the
2315         function.
2316         * lib/string.in.h (memchr, strpbrk): Use _GL_CXXALIAS_SYS_CAST2 for all
2317         C++ compilers.
2318         (memrchr, rawmemchr, strchrnul, strstr, strcasestr): Use
2319         _GL_CXXALIAS_SYS_CAST2 instead of _GL_CXXALIAS_SYS.
2320         Reported by Jim Meyering.
2321
2322 2010-03-09  Simon Josefsson  <simon@josefsson.org>
2323
2324         * gnulib-tool (LIBTOOLPATH): Fix cut'n'paste bug.
2325
2326 2010-03-08  Bruno Haible  <bruno@clisp.org>
2327
2328         gnulib-tool: Add support for --libtool in --create-testdir.
2329         * gnulib-tool (LIBTOOLPATH, LIBTOOLIZE): New variables.
2330         (func_create_testdir): Emit LT_INIT invocations. Invoke LIBTOOLIZE.
2331
2332 2010-03-08  Eric Blake  <eblake@redhat.com>
2333
2334         gnulib-tool.texi: mention possibility of git submodule
2335         * doc/gnulib-tool.texi (VCS Issues): Add details about using git
2336         submodules.
2337         * doc/.gitignore: Ignore another generated file.
2338
2339 2010-03-08  Karl Berry  <karl@gnu.org>
2340
2341         * doc/gnulib-tool.texi (VCS Issues): Mention third option
2342         of committing gnulib files while skipping others.
2343
2344 2010-03-07  Bruno Haible  <bruno@clisp.org>
2345
2346         Tests of module 'wctype' in C++ mode.
2347         * tests/test-wctype-c++.cc: New file.
2348         * modules/wctype-tests (Files): Add it and tests/signature.h.
2349         (Depends-on): Add ansi-c++-opt.
2350         (Makefile.am): Arrange to compile and run test-wctype-c++.
2351
2352         Tests of module 'wchar' in C++ mode.
2353         * tests/test-wchar-c++.cc: New file.
2354         * modules/wchar-tests (Files): Add it and tests/signature.h.
2355         (Depends-on): Add ansi-c++-opt.
2356         (Makefile.am): Arrange to compile and run test-wchar-c++.
2357         * m4/wchar_h.m4 (gl_WCHAR_MODULE_INDICATOR): Invoke
2358         gl_MODULE_INDICATOR.
2359
2360         Tests of module 'unistd' in C++ mode.
2361         * tests/test-unistd-c++.cc: New file.
2362         * modules/unistd-tests (Files): Add it and tests/signature.h.
2363         (Depends-on): Add ansi-c++-opt.
2364         (Makefile.am): Arrange to compile and run test-unistd-c++.
2365         * m4/unistd_h.m4 (gl_UNISTD_MODULE_INDICATOR): Invoke
2366         gl_MODULE_INDICATOR.
2367
2368         Tests of module 'time' in C++ mode.
2369         * tests/test-time-c++.cc: New file.
2370         * modules/time-tests (Files): Add it and tests/signature.h.
2371         (Depends-on): Add ansi-c++-opt.
2372         (Makefile.am): Arrange to compile and run test-time-c++.
2373         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
2374
2375         Tests of module 'sys_time' in C++ mode.
2376         * tests/test-sys_time-c++.cc: New file.
2377         * modules/sys_time-tests (Files): Add it and tests/signature.h.
2378         (Depends-on): Add ansi-c++-opt.
2379         (Makefile.am): Arrange to compile and run test-sys_time-c++.
2380         * m4/sys_time_h.m4 (gl_SYS_TIME_MODULE_INDICATOR): Invoke
2381         gl_MODULE_INDICATOR.
2382
2383         Tests of module 'sys_stat' in C++ mode.
2384         * tests/test-sys_stat-c++.cc: New file.
2385         * modules/sys_stat-tests (Files): Add it and tests/signature.h.
2386         (Depends-on): Add ansi-c++-opt.
2387         (Makefile.am): Arrange to compile and run test-sys_stat-c++.
2388         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): Invoke
2389         gl_MODULE_INDICATOR.
2390
2391         Tests of module 'sys_socket' in C++ mode.
2392         * tests/test-sys_socket-c++.cc: New file.
2393         * modules/sys_socket-tests (Files): Add it and tests/signature.h.
2394         (Depends-on): Add ansi-c++-opt.
2395         (Makefile.am): Arrange to compile and run test-sys_socket-c++.
2396         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Invoke
2397         gl_MODULE_INDICATOR.
2398
2399         Tests of module 'sys_select' in C++ mode.
2400         * tests/test-sys_select-c++.cc: New file.
2401         * modules/sys_select-tests (Files): Add it and tests/signature.h.
2402         (Depends-on): Add ansi-c++-opt.
2403         (Makefile.am): Arrange to compile and run test-sys_select-c++.
2404         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): Invoke
2405         gl_MODULE_INDICATOR.
2406
2407         Tests of module 'sys_ioctl' in C++ mode.
2408         * tests/test-sys_ioctl-c++.cc: New file.
2409         * modules/sys_ioctl-tests (Files): Add it and tests/signature.h.
2410         (Depends-on): Add ansi-c++-opt.
2411         (Makefile.am): Arrange to compile and run test-sys_ioctl-c++.
2412         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_MODULE_INDICATOR): Invoke
2413         gl_MODULE_INDICATOR.
2414
2415         Tests of module 'string' in C++ mode.
2416         * tests/test-string-c++.cc: New file.
2417         * modules/string-tests (Files): Add it and tests/signature.h.
2418         (Depends-on): Add ansi-c++-opt.
2419         (Makefile.am): Arrange to compile and run test-string-c++.
2420         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Invoke
2421         gl_MODULE_INDICATOR.
2422
2423         Tests of module 'stdlib' in C++ mode.
2424         * tests/test-stdlib-c++.cc: New file.
2425         * modules/stdlib-tests (Files): Add it and tests/signature.h.
2426         (Depends-on): Add ansi-c++-opt.
2427         (Makefile.am): Arrange to compile and run test-stdlib-c++.
2428         * m4/stdlib_h.m4 (gl_STDLIB_MODULE_INDICATOR): Invoke
2429         gl_MODULE_INDICATOR.
2430
2431         Tests of module 'stdio' in C++ mode.
2432         * tests/test-stdio-c++.cc: New file.
2433         * modules/stdio-tests (Files): Add it and tests/signature.h.
2434         (Depends-on): Add ansi-c++-opt.
2435         (Makefile.am): Arrange to compile and run test-stdio-c++.
2436         * m4/stdio_h.m4 (gl_STDIO_MODULE_INDICATOR): Invoke
2437         gl_MODULE_INDICATOR.
2438
2439         Tests of module 'spawn' in C++ mode.
2440         * tests/test-spawn-c++.cc: New file.
2441         * modules/spawn-tests (Files): Add it and tests/signature.h.
2442         (Depends-on): Add ansi-c++-opt.
2443         (Makefile.am): Arrange to compile and run test-spawn-c++.
2444         * m4/spawn_h.m4 (gl_SPAWN_MODULE_INDICATOR): Invoke
2445         gl_MODULE_INDICATOR.
2446
2447         Tests of module 'signal' in C++ mode.
2448         * tests/test-signal-c++.cc: New file.
2449         * modules/signal-tests (Files): Add it and tests/signature.h.
2450         (Depends-on): Add ansi-c++-opt.
2451         (Makefile.am): Arrange to compile and run test-signal-c++.
2452         * m4/signal_h.m4 (gl_SIGNAL_MODULE_INDICATOR): Invoke
2453         gl_MODULE_INDICATOR.
2454
2455         Tests of module 'search' in C++ mode.
2456         * tests/test-search-c++.cc: New file.
2457         * modules/search-tests (Files): Add it and tests/signature.h.
2458         (Depends-on): Add ansi-c++-opt.
2459         (Makefile.am): Arrange to compile and run test-search-c++.
2460         * m4/search_h.m4 (gl_SEARCH_MODULE_INDICATOR): Invoke
2461         gl_MODULE_INDICATOR.
2462
2463         Tests of module 'math' in C++ mode.
2464         * tests/test-math-c++.cc: New file.
2465         * modules/math-tests (Files): Add it and tests/signature.h.
2466         (Depends-on): Add ansi-c++-opt.
2467         (Makefile.am): Arrange to compile and run test-math-c++.
2468         * m4/math_h.m4 (gl_MATH_MODULE_INDICATOR): Invoke gl_MODULE_INDICATOR.
2469
2470         Tests of module 'locale' in C++ mode.
2471         * tests/test-locale-c++.cc: New file.
2472         * modules/locale-tests (Files): Add it and tests/signature.h.
2473         (Depends-on): Add ansi-c++-opt.
2474         (Makefile.am): Arrange to compile and run test-locale-c++.
2475         * m4/locale_h.m4 (gl_LOCALE_MODULE_INDICATOR): Invoke
2476         gl_MODULE_INDICATOR.
2477
2478         Tests of module 'langinfo' in C++ mode.
2479         * tests/test-langinfo-c++.cc: New file.
2480         * modules/langinfo-tests (Files): Add it and tests/signature.h.
2481         (Depends-on): Add ansi-c++-opt.
2482         (Makefile.am): Arrange to compile and run test-langinfo-c++.
2483         * m4/langinfo_h.m4 (gl_LANGINFO_MODULE_INDICATOR): Invoke
2484         gl_MODULE_INDICATOR.
2485
2486         Tests of module 'iconv-h' in C++ mode.
2487         * tests/test-iconv-h-c++.cc: New file.
2488         * modules/iconv-h-tests (Files): Add it and tests/signature.h.
2489         (Depends-on): Add ansi-c++-opt.
2490         (Makefile.am): Arrange to compile and run test-iconv-h-c++.
2491
2492         Tests of module 'glob' in C++ mode.
2493         * tests/test-glob-c++.cc: New file.
2494         * modules/glob-tests (Files): Add it.
2495         (Depends-on): Add ansi-c++-opt.
2496         (Makefile.am): Arrange to compile and run test-glob-c++.
2497
2498         Tests of module 'fcntl-h' in C++ mode.
2499         * tests/test-fcntl-h-c++.cc: New file.
2500         * modules/fcntl-h-tests (Files): Add it and tests/signature.h.
2501         (Depends-on): Add ansi-c++-opt.
2502         (Makefile.am): Arrange to compile and run test-fcntl-h-c++.
2503         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR): Invoke
2504         gl_MODULE_INDICATOR.
2505
2506         Tests of module 'dirent' in C++ mode.
2507         * tests/test-dirent-c++.cc: New file.
2508         * modules/dirent-tests (Files): Add it and tests/signature.h.
2509         (Depends-on): Add ansi-c++-opt.
2510         (Makefile.am): Arrange to compile and run test-dirent-c++.
2511         * m4/dirent_h.m4 (gl_DIRENT_MODULE_INDICATOR): Invoke
2512         gl_MODULE_INDICATOR.
2513
2514         New module 'ansi-c++-opt'.
2515         * modules/ansi-c++-opt: New file.
2516         * m4/ansi-c++.m4: New file, from GNU gettext with modifications.
2517
2518         Document C++ namespace mode.
2519         * doc/gnulib.texi (A C++ namespace for gnulib): New section.
2520
2521         wctype: Avoid #define replacements in C++ mode.
2522         * lib/wctype.in.h: Include c++defs.h, warn-on-use.h.
2523         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower,
2524         iswprint, iswpunct, iswspace, iswupper, iswxdigit, towlower, towupper):
2525         In C++, define a namespaced alias symbol.
2526         * m4/wctype_h.m4 (gl_WCTYPE_H): Don't set WCTYPE_H.
2527         * modules/wctype (Depends-on): Add c++defs, warn-on-use.
2528         (Makefile.am): Provide a wctype.h replacement always. Update wctype.h
2529         rule.
2530
2531         wchar: Avoid #define replacements in C++ mode.
2532         * lib/wchar.in.h: Include c++defs.h.
2533         (btowc, wctob, mbsinit, mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs,
2534         wcrtomb, wcsrtombs, wcsnrtombs): In C++, define a namespaced alias
2535         symbol.
2536         (wcwidth): Likewise. Fix prototype to be POSIX compliant.
2537         * modules/wchar (Depends-on): Add c++defs.
2538         (Makefile.am): Update wchar.h rule.
2539
2540         unistd: Avoid #define replacements in C++ mode.
2541         * lib/unistd.in.h: Include c++defs.h.
2542         (chown, close, dup, dup2, dup3, euidaccess, faccessat, fchdir,
2543         fchownat, fsync, ftruncate, getcwd, getdomainname, getdtablesize,
2544         getgroups, gethostname, getlogin, getlogin_r, getpagesize,
2545         getusershell, setusershell, endusershell, lchown, link, linkat, lseek,
2546         pipe2, pread, readlink, readlinkat, rmdir, sleep, symlink, symlinkat,
2547         unlink, unlinkat, usleep, write): In C++, define a namespaced alias
2548         symbol.
2549         (environ): Update.
2550         * modules/unistd (Depends-on): Add c++defs.
2551         (Makefile.am): Update unistd.h rule.
2552
2553         time: Avoid #define replacements in C++ mode.
2554         * lib/time.in.h: Include c++defs.h, warn-on-use.h.
2555         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): In C++,
2556         define a namespaced alias symbol.
2557         * m4/time_h.m4 (gl_TIME_MODULE_INDICATOR): New macro.
2558         (gl_HEADER_TIME_H_DEFAULTS): Initialize also GNULIB_MKTIME,
2559         GNULIB_NANOSLEEP, GNULIB_STRPTIME, GNULIB_TIMEGM.
2560         * modules/time (Depends-on): Add c++defs, warn-on-use.
2561         (Makefile.am): Update time.h rule.
2562         * modules/mktime (configure.ac): Invoke gl_TIME_MODULE_INDICATOR.
2563         * modules/nanosleep (configure.ac): Likewise.
2564         * modules/strptime (configure.ac): Likewise.
2565         * modules/timegm (configure.ac): Likewise.
2566
2567         sys_time: Avoid #define replacements in C++ mode.
2568         * lib/sys_time.in.h: Include c++defs.h.
2569         (gettimeofday): In C++, define a namespaced alias symbol.
2570         * modules/sys_time (Depends-on): Add c++defs.
2571         (Makefile.am): Update sys/time.h rule.
2572
2573         sys_stat: Avoid #define replacements in C++ mode.
2574         * lib/sys_stat.in.h: Include c++defs.h.
2575         (fchmodat, fstat, fstatat, futimens, lchmod, lstat, mkdir, mkdirat,
2576         mkfifo, mkfifoat, mknod, mknodat, utimensat): In C++, define a
2577         namespaced alias symbol.
2578         In C++, define a namespaced alias symbol.
2579         * modules/sys_stat (Depends-on): Add c++defs.
2580         (Makefile.am): Update sys/stat.h rule.
2581
2582         sys_socket: Avoid #define replacements in C++ mode.
2583         * lib/sys_socket.in.h: Handle the case of recursive include on Cygwin.
2584         Include c++defs.h. Include warn-on-use.h earlier. Enable the function
2585         definitions also when the system has a <sys/socket.h>.
2586         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
2587         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, accept4):
2588         In C++, define a namespaced alias symbol.
2589         * modules/sys_socket (Depends-on): Add c++defs.
2590         (Makefile.am): Update sys/socket.h rule.
2591
2592         sys_select: Avoid #define replacements in C++ mode.
2593         * lib/sys_select.in.h: Include c++defs.h. Enable the function
2594         definitions also when the system has a <sys/select.h>.
2595         (select): In C++, define a namespaced alias symbol.
2596         * modules/sys_select (Depends-on): Add c++defs.
2597         (Makefile.am): Update sys/select.h rule.
2598
2599         sys_ioctl: Avoid #define replacements in C++ mode.
2600         * lib/sys_ioctl.in.h: Include c++defs.h.
2601         (ioctl): In C++, define a namespaced alias symbol.
2602         * modules/sys_ioctl (Depends-on): Add c++defs.
2603         (Makefile.am): Update sys/ioctl.h rule.
2604
2605         string: Avoid #define replacements in C++ mode.
2606         * lib/string.in.h: Include c++defs.h.
2607         (stpncpy): Define to rpl_stpncpy, not gnu_stpncpy.
2608         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
2609         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
2610         strcasestr, strtok_r, mbslen, mbschr, mbsrchr, mbspbrk, strerror,
2611         strsignal, strverscmp): In C++, define a namespaced alias symbol.
2612         * modules/string (Depends-on): Add c++defs.
2613         (Makefile.am): Update string.h rule.
2614
2615         stdlib: Avoid #define replacements in C++ mode.
2616         * lib/stdlib.in.h: Include c++defs.h.
2617         (atoll, calloc, canonicalize_file_name, getloadavg, getsubopt, malloc,
2618         mkdtemp, mkostemp, mkostemps, mkstemp, mkstemps, putenv, random_r,
2619         srandom_r, initstate_r, setstate_r, realloc, realpath, rpmatch, setenv,
2620         strtod, strtoll, strtoull, unsetenv): In C++, define a namespaced alias
2621         symbol.
2622         * modules/stdlib (Depends-on): Add c++defs.
2623         (Makefile.am): Update stdlib.h rule.
2624
2625         stdio: Avoid #define replacements in C++ mode.
2626         * lib/stdio.in.h: Include c++defs.h.
2627         (dprintf, fclose, fflush, fopen, fprintf, fpurge, fputc, fputs,
2628         freopen, fseek, fseeko, ftell, ftello, fwrite, getdelim, getline,
2629         obstack_printf, obstack_vprintf, perror, popen, printf, fputc, putchar,
2630         puts, remove, rename, renameat, snprintf, sprintf, asprintf, vasprintf,
2631         vdprintf, vfprintf, vprintf, vsnprintf, vsprintf): In C++, define a
2632         namespaced alias symbol.
2633         * modules/stdio (Depends-on): Add c++defs.
2634         (Makefile.am): Update stdio.h rule.
2635
2636         spawn: Avoid #define replacements in C++ mode.
2637         * lib/spawn.in.h: Include c++defs.h.
2638         (posix_spawn, posix_spawnp, posix_spawnattr_init,
2639         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
2640         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
2641         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
2642         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
2643         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
2644         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
2645         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
2646         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
2647         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
2648         In C++, define a namespaced alias symbol.
2649         * modules/spawn (Depends-on): Add c++defs.
2650         (Makefile.am): Update spawn.h rule.
2651
2652         signal: Avoid #define replacements in C++ mode.
2653         * lib/signal.in.h: Include c++defs.h.
2654         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
2655         sigpending, sigprocmask, signal, raise, sigaction): In C++, define a
2656         namespaced alias symbol.
2657         * modules/signal (Depends-on): Add c++defs.
2658         (Makefile.am): Update signal.h rule.
2659
2660         search: Avoid #define replacements in C++ mode.
2661         * lib/search.in.h: Include c++defs.h.
2662         (_gl_search_compar_fn, _gl_search_action_fn): New types.
2663         (tsearch, tfind, tdelete, twalk): In C++, define a namespaced alias
2664         symbol.
2665         * modules/search (Depends-on): Add c++defs.
2666         (Makefile.am): Update search.h rule.
2667
2668         math: Avoid #define replacements in C++ mode.
2669         * lib/math.in.h: Include c++defs.h.
2670         (frexp, acosl, asinl, atanl, ceilf, ceill, cosl, expl, floorf, floorl,
2671         frexpl, ldexpl, logl, roundf, round, roundl, sinl, sqrtl, tanl, truncf,
2672         trunc, truncl): In C++, define a namespaced alias symbol.
2673         * modules/math (Depends-on): Add c++defs.
2674         (Makefile.am): Update math.h rule.
2675
2676         locale: Avoid #define replacements in C++ mode.
2677         * lib/locale.in.h: Include c++defs.h.
2678         (duplocale): In C++, define a namespaced alias symbol.
2679         * m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Initialize HAVE_DUPLOCALE.
2680         * m4/duplocale.m4 (gl_FUNC_DUPLOCALE): Set HAVE_DUPLOCALE.
2681         * modules/locale (Depends-on): Add c++defs.
2682         (Makefile.am): Update locale.h rule. Substitute HAVE_DUPLOCALE.
2683
2684         langinfo: Avoid #define replacements in C++ mode.
2685         * lib/langinfo.in.h: Include c++defs.h.
2686         (nl_langinfo): In C++, define a namespaced alias symbol.
2687         * modules/langinfo (Depends-on): Add c++defs.
2688         (Makefile.am): Update langinfo.h rule.
2689
2690         iconv-h: Avoid #define replacements in C++ mode.
2691         * lib/iconv.in.h: Include c++defs.h, warn-on-use.h.
2692         (iconv_open, iconv, iconv_close): In C++, define a namespaced alias
2693         symbol.
2694         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
2695         whenever iconv is present.
2696         * modules/iconv-h (Depends-on): Add c++defs, warn-on-use.
2697         (Makefile.am): Update iconv.h rule.
2698
2699         glob: Avoid #define replacements in C++ mode.
2700         * lib/glob.in.h: Include c++defs.h, warn-on-use.h.
2701         (_gl_glob_errfunc_fn): New type.
2702         (glob, globfree, glob_pattern_p): In C++, define a namespaced alias
2703         symbol.
2704         * modules/glob (Depends-on): Add c++defs, warn-on-use.
2705         (Makefile.am): Update glob.h rule.
2706
2707         fcntl-h: Avoid #define replacements in C++ mode.
2708         * lib/fcntl.in.h: Include c++defs.h.
2709         (fcntl, open, openat): In C++, define a namespaced alias symbol.
2710         * modules/fcntl-h (Depends-on): Add c++defs.
2711         (Makefile.am): Update fcntl.h rule.
2712
2713         dirent: Avoid #define replacements in C++ mode.
2714         * lib/dirent.in.h: Include c++defs.h.
2715         (closedir, fdopendir, opendir, scandir, alphasort): In C++, define a
2716         namespaced alias symbol.
2717         (dirfd): Update declaration.
2718         * modules/dirent (Depends-on): Add c++defs.
2719         (Makefile.am): Update dirent.h rule.
2720
2721         ctype: Make it usable in C++ code.
2722         * lib/ctype.in.h: Include c++defs.h.
2723         (isblank): Declare as extern "C".
2724         * modules/ctype (Depends-on): Add c++defs.
2725         (Makefile.am): Update ctype.h rule.
2726
2727         New module 'c++defs'.
2728         * modules/c++defs: New file.
2729         * build-aux/c++defs.h: New file.
2730         Reported by John W. Eaton <jwe@gnu.org>.
2731
2732 2010-03-07  Bruno Haible  <bruno@clisp.org>
2733
2734         logb: Provide missing declaration for Cygwin.
2735         * lib/math.in.h (logb): New declaration.
2736         * m4/logb.m4: New file.
2737         * modules/logb (Files): Add m4/logb.m4.
2738         (Depends-on): Add math.
2739         (configure.ac): Invoke gl_FUNC_LOGB, gl_MATH_MODULE_INDICATOR.
2740         * m4/math_h.m4 (gl_MATH_H): Check also for logb declaration.
2741         (gl_MATH_H_DEFAULTS): Initialize GNULIB_LOGB, HAVE_DECL_LOGB.
2742         * modules/math (Makefile.am): Substitute GNULIB_LOGB, HAVE_DECL_LOGB.
2743         * doc/posix-functions/logb.texi: Mention the Cygwin bug.
2744
2745 2010-03-07  Bruno Haible  <bruno@clisp.org>
2746
2747         Fix test-cond link error.
2748         * tests/test-cond.c: Include <stdio.h>.
2749
2750 2010-03-07  Bruno Haible  <bruno@clisp.org>
2751
2752         Fix test-dirent-safer link error.
2753         * modules/dirent-safer-tests (Makefile.am): Define
2754         test_dirent_safer_LDADD.
2755
2756 2010-03-07  Bruno Haible  <bruno@clisp.org>
2757
2758         * gnulib-tool (func_create_testdir): Don't use 'lib-ignore' module
2759         among default module list.
2760
2761 2010-03-07  Bruno Haible  <bruno@clisp.org>
2762
2763         Fix link error on platforms with GNU libiconv.
2764         * modules/unistr/u8-strcoll-tests (Makefile): Define
2765         test_u8_strcoll_LDADD.
2766         * modules/unistr/u16-strcoll-tests (Makefile): Define
2767         test_u16_strcoll_LDADD.
2768         * modules/unistr/u32-strcoll-tests (Makefile): Define
2769         test_u32_strcoll_LDADD.
2770
2771 2010-03-07  Bruno Haible  <bruno@clisp.org>
2772
2773         Use POSIX declarations for socket functions.
2774         * lib/sys_socket.in.h (rpl_connect, rpl_accept, rpl_bind,
2775         rpl_getpeername, rpl_getsockname, rpl_recv, rpl_send, rpl_recvfrom,
2776         rpl_sendto): Change declaration to match POSIX.
2777         * lib/connect.c (rpl_connect): Likewise.
2778         * lib/accept.c (rpl_accept): Likewise.
2779         * lib/bind.c (rpl_bind): Likewise.
2780         * lib/getpeername.c (rpl_getpeername): Likewise.
2781         * lib/getsockname.c (rpl_getsockname): Likewise.
2782         * lib/recv.c (rpl_recv): Likewise.
2783         * lib/send.c (rpl_send): Likewise.
2784         * lib/recvfrom.c (rpl_recvfrom): Likewise.
2785         * lib/sendto.c (rpl_sendto): Likewise.
2786
2787 2010-03-06  Bruno Haible  <bruno@clisp.org>
2788
2789         Clarify access, euidaccess, faccessat.
2790         * doc/posix-functions/faccessat.texi: Mention security problem under
2791         "Other problems", not "Portability problems".
2792         * doc/posix-functions/access.texi: Likewise. Mention a related security
2793         problem.
2794         * doc/glibc-functions/euidaccess.texi: Mention security problems.
2795         * lib/euidaccess.c: Add comments about platforms.
2796         * lib/unistd.in.h (access, euidaccess): Add warnings.
2797
2798 2010-03-07  Bruno Haible  <bruno@clisp.org>
2799
2800         Ensure posix_spawnattr_{get,set}sched{policy,param} are defined.
2801         * lib/spawn.in.h (POSIX_SPAWN_SETSCHEDPARAM): Define fallback.
2802         (POSIX_SPAWN_SETSCHEDULER): Likewise.
2803         (POSIX_SPAWN_USEVFORK): Define in a way that works when
2804         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
2805         (posix_spawnattr_getschedpolicy, posix_spawnattr_setschedpolicy): Also
2806         declare when POSIX_SPAWN_SETSCHEDULER is zero.
2807         (posix_spawnattr_getschedparam, posix_spawnattr_setschedparam): Also
2808         declare when POSIX_SPAWN_SETSCHEDPARAM is zero.
2809         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_BODY): Test whether
2810         POSIX_SPAWN_SETSCHEDULER or POSIX_SPAWN_SETSCHEDPARAM are zero.
2811         * modules/posix_spawnattr_getschedparam (configure.ac): Enable the
2812         replacement also when POSIX_SPAWN_SETSCHEDPARAM is zero.
2813         * modules/posix_spawnattr_setschedparam (configure.ac): Likewise.
2814         * modules/posix_spawnattr_getschedpolicy (configure.ac): Enable the
2815         replacement also when POSIX_SPAWN_SETSCHEDULER is zero.
2816         * modules/posix_spawnattr_setschedpolicy (configure.ac): Likewise.
2817         * lib/spawnattr_getschedparam.c (posix_spawnattr_getschedparam): Do
2818         nothing if POSIX_SPAWN_SETSCHEDPARAM is zero.
2819         * lib/spawnattr_setschedparam.c (posix_spawnattr_setschedparam):
2820         Likewise.
2821         * lib/spawnattr_getschedpolicy.c (posix_spawnattr_getschedpolicy): Do
2822         nothing if POSIX_SPAWN_SETSCHEDULER is zero.
2823         * lib/spawnattr_setschedpolicy.c (posix_spawnattr_setschedpolicy):
2824         Likewise.
2825         * tests/test-spawn.c (main): Make it work when
2826         POSIX_SPAWN_SETSCHEDPARAM and POSIX_SPAWN_SETSCHEDULER are zero.
2827
2828 2010-03-07  Bruno Haible  <bruno@clisp.org>
2829
2830         Fix incorrect Makefile.am generation in German locale.
2831         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
2832         Execute sed command with character range in C locale.
2833
2834 2010-03-06  Bruno Haible  <bruno@clisp.org>
2835
2836         Tests for module 'iconv-h'.
2837         * modules/iconv-h-tests: New file.
2838         * tests/test-iconv-h.c: New file.
2839
2840         New module 'iconv-h'.
2841         * modules/iconv-h: New file.
2842         * modules/iconv_open (Files): Remove lib/iconv.in.h, m4/iconv_h.m4.
2843         (Depends-on): Add iconv-h. Remove include_next, arg-nonnull.
2844         (configure.ac): Remove gl_ICONV_H.
2845         (Makefile.am): Remove rule for iconv.h.
2846
2847 2010-03-06  Bruno Haible  <bruno@clisp.org>
2848
2849         More consistent naming of *.m4 files.
2850         * m4/wctype_h.m4: Renamed from m4/wctype.m4.
2851         * modules/wctype (Files): Update.
2852
2853         More consistent naming of *.m4 files.
2854         * m4/wchar_h.m4: Renamed from m4/wchar.m4.
2855         * modules/wchar (Files): Update.
2856
2857 2010-03-06  Jim Meyering  <meyering@redhat.com>
2858
2859         euidaccess: relax license to LGPLv2+
2860         * modules/euidaccess (License): Relax to LGPLv2+.
2861
2862 2010-03-06  Bruno Haible  <bruno@clisp.org>
2863
2864         Prefer lib_SOURCES over unconditional AC_LIBOBJ.
2865         * modules/exitfail (configure.ac): Remove AC_LIBOBJ invocation.
2866         (Makefile.am): Augment lib_SOURCES instead.
2867
2868 2010-03-04  Jim Meyering  <meyering@redhat.com>
2869
2870         utime: remove obsolete module
2871         This module, like autoconf's AC_FUNC_UTIME_NULL macro, has been
2872         unnecessary for years, and has been marked as obsolete for 10 months.
2873         * modules/utime: Remove file.
2874         * lib/utime.c: Remove file.
2875         * m4/utime.m4: Remove file.
2876         * m4/utimes-null.m4: Remove file.
2877         * doc/posix-functions/utime.texi (utime): Remove reference to
2878         the module.  Move the sole "fixed by gnulib" item into the
2879         "problems not fixed by Gnulib" list.
2880         * MODULES.html.sh (func_all_modules): Remove reference to "utime".
2881
2882 2010-03-05  Simon Josefsson  <simon@josefsson.org>
2883
2884         * modules/exit (License): Relax license to LGPLv2+.
2885         (Status): Mark as obsolete.
2886         * NEWS: Mention deprecated 'exit' module.
2887         * doc/posix-functions/exit.texi: Recommend 'stdlib' module instead
2888         of now obsolete 'exit'.
2889
2890 2010-03-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2891
2892         fts-lgpl: remove unused module
2893         * modules/fts-lgpl: Remove.
2894         * MODULES.html.sh (func_all_modules): Adjust.
2895         * check-module (find_included_lib_files): Adjust.
2896         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove.
2897
2898 2010-03-02  Ben Walton  <bwalton@artsci.utoronto.ca>  (tiny change)
2899
2900         copy-acl: enhance Solaris ACL error handling
2901         * lib/copy-acl.c (qcopy_acl): Also ignore EOPNOTSUPP.
2902         * lib/set-mode-acl.c (qset_acl): Likewise.
2903
2904 2010-03-02  Bruno Haible  <bruno@clisp.org>
2905
2906         spawn: Don't override the system defined values on FreeBSD 8.
2907         * lib/spawn.in.h (POSIX_SPAWN_RESETIDS, POSIX_SPAWN_SETPGROUP,
2908         POSIX_SPAWN_SETSIGDEF, POSIX_SPAWN_SETSIGMASK,
2909         POSIX_SPAWN_SETSCHEDPARAM, POSIX_SPAWN_SETSCHEDULER): Don't redefine
2910         if HAVE_POSIX_SPAWN is 1.
2911         Reported by Johan van Selst <johans@stack.nl> via Eric Blake.
2912
2913 2010-03-01  Bruno Haible  <bruno@clisp.org>
2914
2915         * doc/gnulib-tool.texi (Initial import): Clarify the requirements
2916         regarding Automake.
2917
2918 2010-02-25  Bruno Haible  <bruno@clisp.org>
2919
2920         Fix breakage of gnulib-tool with ksh, introduced on 2010-02-21.
2921         * gnulib-tool: Define 'echo' as a function only before the ksh alias
2922         setting, not afterwards.
2923         Reported by Ben Walton <bwalton@artsci.utoronto.ca>.
2924
2925 2010-02-24  Eric Blake  <eblake@redhat.com>
2926
2927         bootstrap, git-version-gen: use timestamp
2928         * build-aux/git-version-gen (scriptversion): Force UTC.
2929         * build-aux/bootstrap (scriptversion): New variable.
2930
2931         bootstrap: allow older git
2932         * build-aux/bootstrap (GNULIB_SRCDIR): Add fallback if git is
2933         older than 1.6.4.  Requested by the libvirt project.
2934
2935 2010-02-23  Eric Blake  <eblake@redhat.com>
2936
2937         warn-on-use: work with old autoconf
2938         * m4/warn-on-use.m4 (gl_WARN_ON_USE_PREPARE): Accomodate older
2939         AS_VAR semantics of autoconf 2.60.
2940         Reported by Bruno Haible.
2941
2942         bootstrap: improve some comments
2943         * build-aux/bootstrap: Drop unneeded emacs hint.  Add some
2944         clarification comments.
2945
2946         gettimeofday: provide correct function
2947         * lib/gettimeofday.c (gettimeofday): Provide rpl_gettimeofday only
2948         when replacement is declared, otherwise provide gettimeofday.
2949         Reported by Michael Goffioul.
2950
2951 2010-02-23  Jim Meyering  <meyering@redhat.com>
2952
2953         lib-ignore: relax license to "unlimited", not LGPLv2+
2954         * modules/lib-ignore (License): Relax to "unlimited".
2955
2956 2010-02-23  Jim Meyering  <meyering@redhat.com>
2957
2958         lib-ignore: relax license to LGPLv2+
2959         * modules/lib-ignore (License): Relax to LGPLv2+.
2960
2961 2010-02-22  Eric Blake  <eblake@redhat.com>
2962
2963         lseek: avoid bash 3.2 broken pipe bug
2964         * m4/lseek.m4 (gl_FUNC_LSEEK): Drain pipe, to avoid spurious
2965         warning from bash 3.2.
2966         Reported by Ben Pfaff, with analysis from Bruno Haible.
2967
2968         bootstrap: support non-FSF copyright holder
2969         * build-aux/bootstrap (COPYRIGHT_HOLDER, with_gettext): Allow
2970         bootstrap.conf override of COPYRIGHT_HOLDER.
2971         (MSGID_BUGS_ADDRESS): Allow URL rather than email.
2972
2973         bootstrap: interoperate with gettext 0.14.1
2974         * build-aux/bootstrap (slurp): Fix typo when using older gettext.
2975
2976         bootstrap: allow for alternate submodule location
2977         * build-aux/bootstrap (gnulib_path): New variable; use instead of
2978         hardcoding submodule location.
2979         (gnulib_mk): Allow direct use of Makefile.am.
2980
2981         bootstrap: use GNULIB_SRCDIR to reduce disk usage
2982         * build-aux/bootstrap (GNULIB_SRCDIR): If set, use as a reference,
2983         rather than reconfiguring where the submodule points.
2984
2985         gettimeofday: restore support for platforms that lack function
2986         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Also compile
2987         replacement if function is missing.
2988         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): New witness.
2989         * modules/sys_time (Makefile.am): Substitute it.
2990         * lib/sys_time.in.h (gettimeofday): Check it.
2991         Reported by Michael Goffioul.
2992
2993 2010-02-21  Bruno Haible  <bruno@clisp.org>
2994
2995         * lib/stdio.in.h (obstack_printf): Fix typo.
2996
2997 2010-02-21  Jose E. Marchesi  <jemarch@gnu.org>
2998
2999         vc-list-files: use bzr ls's -R option
3000         * build-aux/vc-list-files: Invoke bazaar to generate a recursive
3001         list of versioned files based on 'dir' (usage of -R in 'bzr ls').
3002
3003 2010-02-21  Jim Meyering  <meyering@redhat.com>
3004
3005         init.sh: fix EXEEXT shims to work also for names like test-prog
3006         * tests/init.sh: Re-exec a better shell, when needed.
3007         If the current shell lacks support for posix $(...), an init.sh-using
3008         test will now try to find a shell that supports that.  If EXEEXT is
3009         nonempty, we also require support for hyphen-in-alias-name and shell
3010         substitutions like ${var#glob}.  Failure to find such a shell results
3011         in a skipped test.
3012
3013 2010-02-21  Bruno Haible  <bruno@clisp.org>
3014
3015         Really work around around "broken pipe" error message from bash 3.2.
3016         * gnulib-tool (func_reset_sigpipe): Remove function.
3017         (echo): In bash 3.2, define to a function that uses printf.
3018         Analyzed by Ralf Wildenhues, Chet Ramey, Ben Pfaff.
3019
3020 2010-02-20  Bruno Haible  <bruno@clisp.org>
3021
3022         Restore support for automake 1.9.6 with autoconf 2.61.
3023         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Ensure MKDIR_P is AC_SUBSTed.
3024         Reported by James Youngman <jay@gnu.org>.
3025
3026 2010-02-20  Bruno Haible  <bruno@clisp.org>
3027
3028         Improve *printf warning condition.
3029         * lib/stdio.in.h (fprintf, printf, vfprintf, vprintf): Emit warning
3030         also if GNULIB_POSIXCHECK is defined, the *-posix module is not used,
3031         and the function is overridden due to SIGPIPE emulation.
3032
3033 2010-02-20  Bruno Haible  <bruno@clisp.org>
3034
3035         * lib/stdio.in.h: Tweak comments.
3036
3037 2010-02-19  Bruno Haible  <bruno@clisp.org>
3038
3039         Make it easier to find modules. New gnulib-tool option '--find'.
3040         * gnulib-tool: New option --find.
3041         (func_usage): Document it.
3042         (func_sanitize_modulelist): New function, extracted from
3043         func_all_modules.
3044         (func_all_modules): Invoke it.
3045         * doc/gnulib-tool.texi (Which modules?): New node.
3046
3047 2010-02-18  Markus Duft <mduft@gentoo.org>  (tiny change)
3048
3049         * lib/sys_select.in.h: Provide select replacement even if
3050         sys/select.h exists on a system, for Interix.
3051
3052 2010-02-18  Jim Meyering  <meyering@redhat.com>
3053
3054         init.sh: don't use $(...) just yet
3055         * tests/init.sh (create_exe_shim_functions_): Use `...`, not $(...),
3056         to accommodate e.g., Solaris' /bin/sh.
3057
3058 2010-02-17  Bruno Haible  <bruno@clisp.org>
3059
3060         * doc/posix-headers/netdb.texi: Mention NetBSD 5.0 problem.
3061         Reported by Ludovic Courtès <ludo@gnu.org>.
3062
3063 2010-02-16  Simon Josefsson  <simon@josefsson.org>
3064
3065         * modules/userspec-tests (test_userspec_LDADD): Add variable, for
3066         linking with -lintl.
3067
3068 2010-02-17  Simon Josefsson  <simon@josefsson.org>
3069
3070         * lib/netdb.in.h (AI_V4MAPPED, AI_ALL, AI_ADDRCONFIG): Define to 0
3071         if not provided by the system's netdb.h.  Reported by
3072         ludo@gnu.org (Ludovic Courtès).
3073
3074 2010-02-15  Jim Meyering  <meyering@redhat.com>
3075
3076         init.sh: improve portability and efficiency
3077         * tests/init.sh (find_exe_basenames_): Remove unnecessary use of
3078         "dummy" in a for loop.
3079         Use '!', not '^' to select the complement of a character set used
3080         in a "case" statement.
3081         Use shell variable manipulation, a la ${...%.exe}, rather than sed.
3082         Suggestions from Eric Blake.
3083
3084         init.sh: automatically accommodate programs with the .exe suffix
3085         Automatically arrange for an invocation of "prog" to execute the
3086         program named "prog$EXEEXT" (usually prog.exe).  Thus, all invocations
3087         may use the simpler "prog", yet still work when built on a system
3088         that requires specifying the added suffix.
3089         Do this by constructing a function named "prog" that invokes
3090         "prog.exe" for each .exe file in selected directories.
3091         * tests/init.sh (find_exe_basenames_): New function.
3092         (create_exe_shim_functions_): New function.
3093         (path_prepend_): Use it.
3094
3095         maint.mk: mark syntax-check sc_*.m rules as .PHONY
3096         * top/maint.mk ($(syntax-check-rules)): Add .PHONY, so that
3097         "make -t syntax-check" doesn't create a ton of sc_*.m files.
3098
3099 2010-02-14  Jim Meyering  <meyering@redhat.com>
3100
3101         maint.mk: prohibit inclusion of "hash-pjw.h" without_use
3102         * top/maint.mk (sc_prohibit_hash_without_use): Re-add "@".
3103         (sc_prohibit_hash_pjw_without_use): New rule.
3104
3105         maint.mk: allow the default upload destination dir to be overridden
3106         * top/maint.mk (upload_dest_dir_): Define with a default that
3107         preserves the status quo.
3108         (emit_upload_commands): Use it, rather than hard-coding $(PACKAGE).
3109         Reported by Peter Simons.
3110
3111         maint.mk: prohibit inclusion of "hash.h" without_use
3112         * top/maint.mk (sc_prohibit_hash_without_use): New rule.
3113
3114 2010-02-10  Jim Meyering  <meyering@redhat.com>
3115
3116         maint.mk: prohibit inclusion of "ignore-value.h" without_use
3117         * top/maint.mk (sc_prohibit_ignore_value_without_use): New rule.
3118
3119 2010-02-09  Eric Blake  <ebb9@byu.net>
3120         and Bruno Haible  <bruno@clisp.org>
3121
3122         obstack-printf-posix: ensure declaration
3123         * m4/obstack-printf.m4 (gl_DECL_OBSTACK_PRINTF): New macro,
3124         extracted from gl_FUNC_OBSTACK_PRINTF.
3125         (gl_FUNC_OBSTACK_PRINTF): Invoke it.
3126         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
3127         Likewise.
3128         * lib/stdio.in.h (obstack_printf, obstack_vprintf): Declare also
3129         if GNULIB_OBSTACK_PRINTF_POSIX is 1 and GNULIB_OBSTACK_PRINTF is
3130         0.
3131
3132 2010-02-08  Bruno Haible  <bruno@clisp.org>
3133
3134         gnulib-tool: Fix typo in 2010-02-07 commit.
3135         * gnulib-tool (func_get_dependencies): Fix typo in last commit.
3136         Reported by Eric Blake.
3137
3138 2010-02-07  Bruno Haible  <bruno@clisp.org>
3139
3140         gnulib-tool: Fix up caching patches.
3141         * gnulib-tool: New options --cache-modules, --no-cache-modules. Remove
3142         option --no-cache. Use associative arrays when supported by the shell.
3143         (sed_comments): New variable.
3144         (modcache): Renamed from do_cache.
3145         (sed_extract_field_header): Renamed from sed_extract_cache_prog. Don't
3146         abbreviate unnecessarily.
3147         (have_associative): New variable.
3148         (func_cache_var): Define correctly for bash 1.x. Define in an optimized
3149         way also for ksh and zsh.
3150         (func_init_sed_convert_to_cache_statements): New function, extracted
3151         from func_cache_lookup_module. Add support for associative arrays.
3152         Don't set the c_MODULE_cached variable here. Ignore all lines before
3153         the first field header. Remove only the final newline, not all trailing
3154         newlines. Support empty fields correctly. Limit the use of 'eval' to
3155         assignments.
3156         (func_get_description, func_get_status, func_get_notice,
3157         func_get_applicability, func_get_filelist, func_get_dependencies,
3158         func_get_autoconf_early_snippet, func_get_autoconf_snippet,
3159         func_get_automake_snippet, func_get_include_directive,
3160         func_get_link_directive, func_get_license, func_get_maintainer):
3161         Update documentation. List the unoptimized code first. Add support for
3162         associative arrays. Limit the use of 'eval' to assignments.
3163         (func_get_applicability): Undo stylistic pessimisations.
3164         (func_get_automake_snippet, func_get_include_directive): Reduce code
3165         duplication.
3166         (func_modules_transitive_closure, func_modules_add_dummy,
3167         func_modules_notice, func_modules_to_filelist, func_add_file,
3168         func_update_file, func_emit_lib_Makefile_am, func_emit_po_Makevars,
3169         func_emit_po_POTFILES_in, func_emit_tests_Makefile_am, func_import,
3170         func_create_testdir, func_create_megatestdir): Update documentation.
3171
3172 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3173
3174         * gnulib-tool (func_cache_lookup_module): Store the module name
3175         belonging to the cache variable; error out if two different
3176         module names map to the same cache variable name.
3177
3178 2010-01-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3179
3180         gnulib-tool: Make caching optional.
3181         * gnulib-tool: Accept option --no-cache, turning off $do_cache.
3182         Update matching short versions of --no-changelog.
3183         (func_usage): Update.
3184         (sed_extract_cache_prog): Renamed from ...
3185         (sed_extract_prog): ... this; revert to old extraction script.
3186         (func_get_description, func_get_status)
3187         (func_get_notice, func_get_applicability, func_get_filelist)
3188         (func_get_dependencies, func_get_autoconf_early_snippet)
3189         (func_get_autoconf_snippet, func_get_automake_snippet)
3190         (func_get_include_directive, func_get_link_directive)
3191         (func_get_license, func_get_maintainer): If $do_cache is false,
3192         use old, non-caching extraction scripts.
3193         Suggestion by Bruno Haible.
3194
3195 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3196
3197         gnulib-tool: cache module metainformation.
3198         * gnulib-tool (sed_extract_prog): Match newline before each
3199         header, and rewrite header to a shell variable suffix.
3200         (func_cache_var, func_cache_lookup_module): New functions,
3201         to turn a module name into a cache variable prefix, and to
3202         look up and cache module metainformation.
3203         (func_get_description, func_get_status)
3204         (func_get_notice, func_get_applicability, func_get_filelist)
3205         (func_get_dependencies, func_get_autoconf_early_snippet)
3206         (func_get_autoconf_snippet, func_get_automake_snippet)
3207         (func_get_include_directive, func_get_link_directive)
3208         (func_get_license, func_get_maintainer): Use
3209         func_cache_lookup_module.
3210
3211 2010-02-07  Bruno Haible  <bruno@clisp.org>
3212
3213         fnctl: Fix missing dependency.
3214         * modules/fcntl (Depends-on): Add getdtablesize.
3215         Reported by John W. Eaton <jwe@gnu.org>.
3216
3217 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
3218
3219         Argp: fix recognition of short alias options.
3220
3221         * lib/argp-parse.c (convert_options): Fix improper use of
3222         `|' between character values.
3223         * tests/test-argp.c (group1_option): New alias option
3224         --read (-r).
3225         (group1_parser): Special handling for 'r'.
3226         (test15): New test case.
3227         (test_fun): Add test15.
3228         * tests/test-argp-2.sh: Update expected --help and --usage
3229         outputs.
3230
3231 2010-02-05  Sergey Poznyakoff  <gray@gnu.org.ua>
3232
3233         * tests/test-argp.c: Fix indentation.
3234
3235 2010-02-04  Eric Blake  <ebb9@byu.net>
3236
3237         gettimeofday: expose type of second argument
3238         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Do better detection
3239         of glibc extension signature, and define GETTIMEOFDAY_TIMEZONE.
3240         * tests/test-gettimeofday.c: Use it to silence warning.
3241         * doc/posix-functions/gettimeofday.texi (gettimeofday): Document
3242         the issue.
3243
3244 2010-02-03  Jim Meyering  <meyering@redhat.com>
3245
3246         regcomp.c: avoid the sole warning from gcc's -Wtype-limits
3247         * lib/regcomp.c (TYPE_SIGNED): Define.
3248         (parse_dup_op): Use it to avoid the sole warning from -Wtype-limits.
3249
3250         regcomp.c: avoid a new -Wshadow warning
3251         * lib/regcomp.c (create_initial_state): Do not shadow local "err".
3252
3253 2010-02-01  Jim Meyering  <meyering@redhat.com>
3254
3255         removing useless parentheses in cpp #define directives
3256         For motivation, see commit c0221df4, "define STREQ(a,b)
3257         consistently, removing useless parentheses"
3258         * lib/memcmp.c (CMP_LT_OR_GT): Remove useless parentheses.
3259         * lib/mountlist.c (MNT_IGNORE): Likewise.
3260         * lib/trim.h (trim, trim_trailing, trim_leading): Likewise.
3261
3262 2010-02-01  Eric Blake  <ebb9@byu.net>
3263
3264         sys_time: use link-warning
3265         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Split defaults...
3266         (gl_HEADER_SYS_TIME_H_DEFAULTS): ...into new macro.
3267         (gl_SYS_TIME_MODULE_INDICATOR): New macro.
3268         * modules/sys_time (Depends-on): Add warn-on-use.
3269         (Makefile.am): Always build replacement.
3270         (configure.ac): Update substitutions.
3271         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY)
3272         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Include defaults, and no longer
3273         bother with SYS_TIME_H.
3274         * modules/gettimeofday (configure.ac): Declare indicator.
3275         * lib/sys_time.in.h (gettimeofday): Warn if gnulib module is not
3276         in use.
3277
3278         closein-tests: silence compiler warning
3279         * tests/test-closein.c (main): Ignore fread result.
3280         * modules/closein-tests (Depends-on): Add ignore-value.
3281
3282         tests: silence warning about system return
3283         * tests/test-areadlink-with-size.c (main): Ignore system result.
3284         * tests/test-areadlink.c (main): Likewise.
3285         * tests/test-areadlinkat-with-size.c (main): Likewise.
3286         * tests/test-areadlinkat.c (main): Likewise.
3287         * tests/test-canonicalize-lgpl.c (main): Likewise.
3288         * tests/test-canonicalize.c (main): Likewise.
3289         * tests/test-chown.c (main): Likewise.
3290         * tests/test-fchownat.c (main): Likewise.
3291         * tests/test-fdutimensat.c (main): Likewise.
3292         * tests/test-fstatat.c (main): Likewise.
3293         * tests/test-futimens.c (main): Likewise.
3294         * tests/test-lchown.c (main): Likewise.
3295         * tests/test-link.c (main): Likewise.
3296         * tests/test-linkat.c (main): Likewise.
3297         * tests/test-lstat.c (main): Likewise.
3298         * tests/test-mkdir.c (main): Likewise.
3299         * tests/test-mkdirat.c (main): Likewise.
3300         * tests/test-mkfifo.c (main): Likewise.
3301         * tests/test-mkfifoat.c (main): Likewise.
3302         * tests/test-mknod.c (main): Likewise.
3303         * tests/test-readlink.c (main): Likewise.
3304         * tests/test-remove.c (main): Likewise.
3305         * tests/test-rename.c (main): Likewise.
3306         * tests/test-renameat.c (main): Likewise.
3307         * tests/test-rmdir.c (main): Likewise.
3308         * tests/test-symlink.c (main): Likewise.
3309         * tests/test-symlinkat.c (main): Likewise.
3310         * tests/test-unlink.c (main): Likewise.
3311         * tests/test-unlinkat.c (main): Likewise.
3312         * tests/test-utimens.c (main): Likewise.
3313         * tests/test-utimensat.c (main): Likewise.
3314         * modules/areadlink-tests (Depends-on): Add ignore-value.
3315         * modules/areadlink-with-size-tests (Depends-on): Likewise.
3316         * modules/areadlinkat-tests (Depends-on): Likewise.
3317         * modules/areadlinkat-with-size-tests (Depends-on): Likewise.
3318         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
3319         * modules/canonicalize-tests (Depends-on): Likewise.
3320         * modules/chown-tests (Depends-on): Likewise.
3321         * modules/fdutimensat-tests (Depends-on): Likewise.
3322         * modules/futimens-tests (Depends-on): Likewise.
3323         * modules/lchown-tests (Depends-on): Likewise.
3324         * modules/link-tests (Depends-on): Likewise.
3325         * modules/linkat-tests (Depends-on): Likewise.
3326         * modules/lstat-tests (Depends-on): Likewise.
3327         * modules/mkdir-tests (Depends-on): Likewise.
3328         * modules/mkfifo-tests (Depends-on): Likewise.
3329         * modules/mkfifoat-tests (Depends-on): Likewise.
3330         * modules/mknod-tests (Depends-on): Likewise.
3331         * modules/openat-tests (Depends-on): Likewise.
3332         * modules/readlink-tests (Depends-on): Likewise.
3333         * modules/remove-tests (Depends-on): Likewise.
3334         * modules/rename-tests (Depends-on): Likewise.
3335         * modules/renameat-tests (Depends-on): Likewise.
3336         * modules/rmdir-tests (Depends-on): Likewise.
3337         * modules/symlink-tests (Depends-on): Likewise.
3338         * modules/symlinkat-tests (Depends-on): Likewise.
3339         * modules/unlink-tests (Depends-on): Likewise.
3340         * modules/utimens-tests (Depends-on): Likewise.
3341         * modules/utimensat-tests (Depends-on): Likewise.
3342
3343 2010-01-31  Bruno Haible  <bruno@clisp.org>
3344
3345         Perform the same test for many <math.h> functions.
3346         * m4/mathfunc.m4 (gl_COMMON_DOUBLE_MATHFUNC,
3347         gl_COMMON_DOUBLE_MATHFUNC_TEST): New macros.
3348         * m4/sqrt.m4 (gl_FUNC_SQRT): Invoke gl_COMMON_DOUBLE_MATHFUNC instead
3349         of gl_MATHFUNC.
3350         * modules/acos (configure.ac): Likewise.
3351         * modules/asin (configure.ac): Likewise.
3352         * modules/atan (configure.ac): Likewise.
3353         * modules/atan2 (configure.ac): Likewise.
3354         * modules/cbrt (configure.ac): Likewise.
3355         * modules/copysign (configure.ac): Likewise.
3356         * modules/cos (configure.ac): Likewise.
3357         * modules/cosh (configure.ac): Likewise.
3358         * modules/erf (configure.ac): Likewise.
3359         * modules/erfc (configure.ac): Likewise.
3360         * modules/exp (configure.ac): Likewise.
3361         * modules/fmod (configure.ac): Likewise.
3362         * modules/hypot (configure.ac): Likewise.
3363         * modules/j0 (configure.ac): Likewise.
3364         * modules/j1 (configure.ac): Likewise.
3365         * modules/jn (configure.ac): Likewise.
3366         * modules/lgamma (configure.ac): Likewise.
3367         * modules/log (configure.ac): Likewise.
3368         * modules/log10 (configure.ac): Likewise.
3369         * modules/log1p (configure.ac): Likewise.
3370         * modules/pow (configure.ac): Likewise.
3371         * modules/remainder (configure.ac): Likewise.
3372         * modules/sin (configure.ac): Likewise.
3373         * modules/sinh (configure.ac): Likewise.
3374         * modules/tan (configure.ac): Likewise.
3375         * modules/tanh (configure.ac): Likewise.
3376         * modules/y0 (configure.ac): Likewise.
3377         * modules/y1 (configure.ac): Likewise.
3378         * modules/yn (configure.ac): Likewise.
3379         Suggested by Paolo Bonzini.
3380
3381 2010-01-31  Bruno Haible  <bruno@clisp.org>
3382
3383         * m4/getline.m4 (gl_FUNC_GETLINE): Add comment about REPLACE_GETLINE.
3384
3385 2010-01-31  Bruno Haible  <bruno@clisp.org>
3386
3387         Work around getdelim() bug on FreeBSD 8.0.
3388         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Test whether getdelim supports an
3389         initially NULL line. Set REPLACE_GETDELIM if getdelim exists but does
3390         not work.
3391         * lib/stdio.in.h (getdelim): Define as an alias if REPLACE_GETDELIM
3392         is 1.
3393         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize REPLACE_GETDELIM.
3394         * modules/stdio (Makefile.am): Also substitute REPLACE_GETDELIM.
3395         * tests/test-getdelim.c (main): Also test result for a NULL buffer and
3396         a non-zero size.
3397         * doc/posix-functions/getdelim.texi: Mention the FreeBSD bug.
3398
3399 2010-01-31  Bruno Haible  <bruno@clisp.org>
3400
3401         Work around getline() bug on FreeBSD 8.0.
3402         * m4/getline.m4 (gl_FUNC_GETLINE): Also test result for a NULL buffer
3403         and a non-zero size.
3404         * tests/test-getline.c (main): Likewise.
3405         * doc/posix-functions/getline.texi: Mention the FreeBSD bug.
3406         Reported by Dennis <noordsij@cs.helsinki.fi> via Eric Blake.
3407
3408 2010-01-28  Eric Blake  <ebb9@byu.net>
3409
3410         regex: fix build failure
3411         * lib/regex_internal.h (__GNUC_PREREQ): Define for non-glibc
3412         platforms.
3413
3414 2010-01-28  Jim Meyering  <meyering@redhat.com>
3415
3416         regex: do not ignore memory allocation failure
3417         * lib/regex_internal.c (create_cd_newstate): Detect
3418         re_node_set_init_copy failure.   Extracted from glibc commit
3419         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
3420
3421         regex: sync more white-space changes from libc
3422         * lib/regex_internal.c: White-space only changes.
3423         * lib/regexec.c: Likewise.
3424
3425         regex: add many uses of __attribute_warn_unused_result__
3426         * lib/regex_internal.c: Use __attribute_warn_unused_result__.
3427         * lib/regexec.c: Likewise.
3428         Extracted from a messy glibc commit.
3429
3430         regcomp.c: spelling and merge-artifact from glibc
3431         * lib/regcomp.c: Merge remainder of glibc's
3432         2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
3433
3434         regcomp.c: sync white-space changes from glibc
3435         * lib/regcomp.c: Merge to accommodate white space
3436         changes from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c.
3437
3438         regcomp.c: do not ignore internal return values
3439         * lib/regcomp.c: Do not ignore internal return values.
3440         This is from glibc's 2da42bc06566bc89785e580fa1ac89b4c9f2a63c,
3441         but without its white-space changes and spelling fixes.
3442
3443         regex_internal.h: define __attribute_warn_unused_result__
3444         * lib/regex_internal.h (__attribute_warn_unused_result__): Define.
3445
3446         maint: add a syntax-check rule to check for vulnerable Makefile.in
3447         * top/maint.mk (sc_vulnerable_makefile_CVE-2009-4029): New rule.
3448
3449 2010-01-27  Jim Meyering  <meyering@redhat.com>
3450
3451         ncftpput-ftp: clean up spaces
3452         * build-aux/ncftpput-ftp: Make Copyright line consistent.
3453         Remove trailing blanks.
3454
3455 2010-01-27  Simon Josefsson  <simon@josefsson.org>
3456
3457         * build-aux/git-version-gen: Fix copyright statement.
3458         * build-aux/gnupload: Likewise.
3459         * tests/test-arcfour.c: Likewise.
3460         * tests/test-arctwo.c: Likewise.
3461         * tests/test-count-one-bits.c: Likewise.
3462         * tests/test-crc.c: Likewise.
3463         * tests/test-des.c: Likewise.
3464         * tests/test-gc-arcfour.c: Likewise.
3465         * tests/test-gc-arctwo.c: Likewise.
3466         * tests/test-gc-des.c: Likewise.
3467         * tests/test-gc-hmac-md5.c: Likewise.
3468         * tests/test-gc-hmac-sha1.c: Likewise.
3469         * tests/test-gc-md2.c: Likewise.
3470         * tests/test-gc-md4.c: Likewise.
3471         * tests/test-gc-md5.c: Likewise.
3472         * tests/test-gc-pbkdf2-sha1.c: Likewise.
3473         * tests/test-gc-rijndael.c: Likewise.
3474         * tests/test-gc-sha1.c: Likewise.
3475         * tests/test-gc.c: Likewise.
3476         * tests/test-gethostname.c: Likewise.
3477         * tests/test-gettimeofday.c: Likewise.
3478         * tests/test-hash.c: Likewise.
3479         * tests/test-hmac-md5.c: Likewise.
3480         * tests/test-hmac-sha1.c: Likewise.
3481         * tests/test-md2.c: Likewise.
3482         * tests/test-md4.c: Likewise.
3483         * tests/test-md5.c: Likewise.
3484         * tests/test-memchr.c: Likewise.
3485         * tests/test-memchr2.c: Likewise.
3486         * tests/test-memcmp.c: Likewise.
3487         * tests/test-memmem.c: Likewise.
3488         * tests/test-memrchr.c: Likewise.
3489         * tests/test-rawmemchr.c: Likewise.
3490         * tests/test-read-file.c: Likewise.
3491         * tests/test-rijndael.c: Likewise.
3492         * tests/test-sockets.c: Likewise.
3493         * tests/test-strchrnul.c: Likewise.
3494         * tests/test-strstr.c: Likewise.
3495         * tests/test-strtod.c: Likewise.
3496         * build-aux/ncftpput-ftp: Likewise.
3497
3498 2010-01-26  Eric Blake  <ebb9@byu.net>
3499
3500         ignore-value: update recommended header name
3501         * modules/ignore-value (Include): Only use <> for headers that
3502         exist in glibc.
3503
3504 2010-01-26  Jim Meyering  <meyering@redhat.com>
3505
3506         test-userspec.c: avoid compiler warnings
3507         * tests/test-userspec.c (main): Avoid shadowing ("uid"),
3508         and "initialization discards qualifiers..." warnings.
3509         Put the first "uid" in its own scope, and make char* members "const".
3510
3511 2010-01-25  Bruno Haible  <bruno@clisp.org>
3512
3513         gnulib-tool: Make warning diagnostics consistent.
3514         * gnulib-tool (func_warning): New function.
3515         Use it everywhere where gnulib-tool produces output to stderr and it is
3516         not a fatal error.
3517
3518 2010-01-25  Bruno Haible  <bruno@clisp.org>
3519
3520         Fix test dependencies.
3521         * modules/xstrtol-tests (Depends-on): Add inttypes.
3522         * modules/xstrtoll-tests (Depends-on): Likewise. Remove xstrtoll.
3523
3524 2010-01-25 Pádraig Brady <P@draigBrady.com>
3525
3526         syntax-check: detect incorrect boolean macro values in config.h
3527         * modules/maintainer-makefile (configure.ac): Parameterize the location
3528         of config.h which will be available to makefiles as $(CONFIG_INCLUDE).
3529         The logic is from Eric Blake and the location indicated by Jim Meyering.
3530         Note the more natural CONFIG_HEADER name is prohibited by automake
3531         for backwards compatibility reasons.
3532         * top/maint.mk (sc_Wundef_boolean): New rule.
3533
3534 2010-01-25  Jim Meyering  <meyering@redhat.com>
3535
3536         bootstrap: detect MacOS 10.6's shasum, too
3537         * build-aux/bootstrap: Also recognize MacOS 10.6's shasum.
3538         Suggested by Thomas Treichl <Thomas.Treichl@gmx.net>.
3539
3540 2010-01-23  Jim Meyering  <meyering@redhat.com>
3541
3542         xstrtoll: new module
3543         * modules/xstrtoll: New file.
3544         * MODULES.html.sh (Numeric conversion functions): Add xstrtoll.
3545         * lib/xstrtol.h [HAVE_LONG_LONG_INT]: Declare xstrtoll and xstrtoull.
3546         * lib/xstrtoll.c, lib/xstrtoull.c: New files.
3547         ./configure fails if you use this module and lack "long long".
3548         * modules/xstrtoll-tests: New module.
3549         * tests/test-xstrtoll.c, tests/test-xstrtoull.c: New files.
3550         * tests/test-xstrtoll.sh: Like test-xstrtol.c, but use the
3551         new init.sh-based test framework.
3552
3553 2010-01-24  Bruno Haible  <bruno@clisp.org>
3554
3555         Tests for module 'yn'.
3556         * modules/yn-tests: New file.
3557         * tests/test-yn.c: New file.
3558
3559         Tests for module 'y1'.
3560         * modules/y1-tests: New file.
3561         * tests/test-y1.c: New file.
3562
3563         Tests for module 'y0'.
3564         * modules/y0-tests: New file.
3565         * tests/test-y0.c: New file.
3566
3567         Tests for module 'tanh'.
3568         * modules/tanh-tests: New file.
3569         * tests/test-tanh.c: New file.
3570
3571         Tests for module 'tan'.
3572         * modules/tan-tests: New file.
3573         * tests/test-tan.c: New file.
3574
3575         Tests for module 'sqrt'.
3576         * modules/sqrt-tests: New file.
3577         * tests/test-sqrt.c: New file.
3578
3579         Tests for module 'sinh'.
3580         * modules/sinh-tests: New file.
3581         * tests/test-sinh.c: New file.
3582
3583         Tests for module 'sin'.
3584         * modules/sin-tests: New file.
3585         * tests/test-sin.c: New file.
3586
3587         Tests for module 'rint'.
3588         * modules/rint-tests: New file.
3589         * tests/test-rint.c: New file.
3590
3591         Tests for module 'remainder'.
3592         * modules/remainder-tests: New file.
3593         * tests/test-remainder.c: New file.
3594
3595         Tests for module 'pow'.
3596         * modules/pow-tests: New file.
3597         * tests/test-pow.c: New file.
3598
3599         Tests for module 'nextafter'.
3600         * modules/nextafter-tests: New file.
3601         * tests/test-nextafter.c: New file.
3602
3603         Tests for module 'modf'.
3604         * modules/modf-tests: New file.
3605         * tests/test-modf.c: New file.
3606
3607         Tests for module 'logb'.
3608         * modules/logb-tests: New file.
3609         * tests/test-logb.c: New file.
3610
3611         Tests for module 'log1p'.
3612         * modules/log1p-tests: New file.
3613         * tests/test-log1p.c: New file.
3614
3615         Tests for module 'log10'.
3616         * modules/log10-tests: New file.
3617         * tests/test-log10.c: New file.
3618
3619         Tests for module 'log'.
3620         * modules/log-tests: New file.
3621         * tests/test-log.c: New file.
3622
3623         Tests for module 'lgamma'.
3624         * modules/lgamma-tests: New file.
3625         * tests/test-lgamma.c: New file.
3626
3627         Tests for module 'ldexp'.
3628         * modules/ldexp-tests: New file.
3629         * tests/test-ldexp.c: New file.
3630
3631         Tests for module 'jn'.
3632         * modules/jn-tests: New file.
3633         * tests/test-jn.c: New file.
3634
3635         Tests for module 'j1'.
3636         * modules/j1-tests: New file.
3637         * tests/test-j1.c: New file.
3638
3639         Tests for module 'j0'.
3640         * modules/j0-tests: New file.
3641         * tests/test-j0.c: New file.
3642
3643         Tests for module 'hypot'.
3644         * modules/hypot-tests: New file.
3645         * tests/test-hypot.c: New file.
3646
3647         Tests for module 'fmod'.
3648         * modules/fmod-tests: New file.
3649         * tests/test-fmod.c: New file.
3650
3651         Tests for module 'fabs'.
3652         * modules/fabs-tests: New file.
3653         * tests/test-fabs.c: New file.
3654
3655         Tests for module 'exp'.
3656         * modules/exp-tests: New file.
3657         * tests/test-exp.c: New file.
3658
3659         Tests for module 'erfc'.
3660         * modules/erfc-tests: New file.
3661         * tests/test-erfc.c: New file.
3662
3663         Tests for module 'erf'.
3664         * modules/erf-tests: New file.
3665         * tests/test-erf.c: New file.
3666
3667         Tests for module 'cosh'.
3668         * modules/cosh-tests: New file.
3669         * tests/test-cosh.c: New file.
3670
3671         Tests for module 'cos'.
3672         * modules/cos-tests: New file.
3673         * tests/test-cos.c: New file.
3674
3675         Tests for module 'copysign'.
3676         * modules/copysign-tests: New file.
3677         * tests/test-copysign.c: New file.
3678
3679         Tests for module 'cbrt'.
3680         * modules/cbrt-tests: New file.
3681         * tests/test-cbrt.c: New file.
3682
3683         Tests for module 'atan2'.
3684         * modules/atan2-tests: New file.
3685         * tests/test-atan2.c: New file.
3686
3687         Tests for module 'atan'.
3688         * modules/atan-tests: New file.
3689         * tests/test-atan.c: New file.
3690
3691         Tests for module 'asin'.
3692         * modules/asin-tests: New file.
3693         * tests/test-asin.c: New file.
3694
3695         Tests for module 'acos'.
3696         * modules/acos-tests: New file.
3697         * tests/test-acos.c: New file.
3698
3699 2010-01-24  Bruno Haible  <bruno@clisp.org>
3700
3701         Fix tests for common <math.h> functions.
3702         * m4/mathfunc.m4 (gl_MATHFUNC): Take two additional parameters. Use a
3703         code snippet that references the function pointer, rather than merely
3704         calling the function. Substitute the FUNC_LIBM variable.
3705         * m4/sqrt.m4 (gl_FUNC_SQRT): Update gl_MATHFUNC invocation.
3706         * modules/acos (configure.ac): Likewise.
3707         * modules/asin (configure.ac): Likewise.
3708         * modules/atan (configure.ac): Likewise.
3709         * modules/atan2 (configure.ac): Likewise.
3710         * modules/cbrt (configure.ac): Likewise.
3711         * modules/copysign (configure.ac): Likewise.
3712         * modules/cos (configure.ac): Likewise.
3713         * modules/cosh (configure.ac): Likewise.
3714         * modules/erf (configure.ac): Likewise.
3715         * modules/erfc (configure.ac): Likewise.
3716         * modules/exp (configure.ac): Likewise.
3717         * modules/fabs (configure.ac): Likewise.
3718         * modules/fmod (configure.ac): Likewise.
3719         * modules/hypot (configure.ac): Likewise.
3720         * modules/j0 (configure.ac): Likewise.
3721         * modules/j1 (configure.ac): Likewise.
3722         * modules/jn (configure.ac): Likewise.
3723         * modules/ldexp (configure.ac): Likewise.
3724         * modules/lgamma (configure.ac): Likewise.
3725         * modules/log (configure.ac): Likewise.
3726         * modules/log10 (configure.ac): Likewise.
3727         * modules/log1p (configure.ac): Likewise.
3728         * modules/logb (configure.ac): Likewise.
3729         * modules/modf (configure.ac): Likewise.
3730         * modules/nextafter (configure.ac): Likewise.
3731         * modules/pow (configure.ac): Likewise.
3732         * modules/remainder (configure.ac): Likewise.
3733         * modules/rint (configure.ac): Likewise.
3734         * modules/sin (configure.ac): Likewise.
3735         * modules/sinh (configure.ac): Likewise.
3736         * modules/tan (configure.ac): Likewise.
3737         * modules/tanh (configure.ac): Likewise.
3738         * modules/y0 (configure.ac): Likewise.
3739         * modules/y1 (configure.ac): Likewise.
3740         * modules/yn (configure.ac): Likewise.
3741
3742 2010-01-24  Bruno Haible  <bruno@clisp.org>
3743
3744         Tests: Defeat inlining of math functions by GCC >= 4.3.0.
3745         * tests/test-acosl.c (x): New variable.
3746         (main): Store argument in x and fetch it from x.
3747         * tests/test-asinl.c (x): New variable.
3748         (main): Store argument in x and fetch it from x.
3749         * tests/test-atanl.c (x): New variable.
3750         (main): Store argument in x and fetch it from x.
3751         * tests/test-cosl.c (x): New variable.
3752         (main): Store argument in x and fetch it from x.
3753         * tests/test-expl.c (x): New variable.
3754         (main): Store argument in x and fetch it from x.
3755         * tests/test-logl.c (x): New variable.
3756         (main): Store argument in x and fetch it from x.
3757         * tests/test-sinl.c (x): New variable.
3758         (main): Store argument in x and fetch it from x.
3759         * tests/test-sqrtl.c (x): New variable.
3760         (main): Store argument in x and fetch it from x.
3761         * tests/test-tanl.c (x): New variable.
3762         (main): Store argument in x and fetch it from x.
3763
3764 2010-01-24  Bruno Haible  <bruno@clisp.org>
3765
3766         Provide EXEEXT and srcdir in TESTS_ENVIRONMENT by default.
3767         * gnulib-tool (func_emit_tests_Makefile_am): Add EXEEXT and srcdir
3768         assignments to the initial TESTS_ENVIRONMENT.
3769         * doc/gnulib.texi (Unit test modules): Document it.
3770         * modules/acl-tests (Makefile.am): Drop EXEEXT assignment from
3771         TESTS_ENVIRONMENT.
3772         * modules/btowc-tests (Makefile.am): Likewise.
3773         * modules/c-stack-tests (Makefile.am): Likewise.
3774         * modules/c-strcase-tests (Makefile.am): Likewise.
3775         * modules/copy-file-tests (Makefile.am): Likewise.
3776         * modules/mbmemcasecmp-tests (Makefile.am): Likewise.
3777         * modules/mbmemcasecoll-tests (Makefile.am): Likewise.
3778         * modules/mbrtowc-tests (Makefile.am): Likewise.
3779         * modules/mbscasecmp-tests (Makefile.am): Likewise.
3780         * modules/mbscasestr-tests (Makefile.am): Likewise.
3781         * modules/mbschr-tests (Makefile.am): Likewise.
3782         * modules/mbscspn-tests (Makefile.am): Likewise.
3783         * modules/mbsinit-tests (Makefile.am): Likewise.
3784         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
3785         * modules/mbsnrtowcs-tests (Makefile.am): Likewise.
3786         * modules/mbspbrk-tests (Makefile.am): Likewise.
3787         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
3788         * modules/mbsrchr-tests (Makefile.am): Likewise.
3789         * modules/mbsrtowcs-tests (Makefile.am): Likewise.
3790         * modules/mbsspn-tests (Makefile.am): Likewise.
3791         * modules/mbsstr-tests (Makefile.am): Likewise.
3792         * modules/nl_langinfo-tests (Makefile.am): Likewise.
3793         * modules/unicase/locale-language-tests (Makefile.am): Likewise.
3794         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
3795         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
3796         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
3797         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
3798         * modules/uniwbrk/ulc-wordbreaks-tests (Makefile.am): Likewise.
3799         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
3800         * modules/wcrtomb-tests (Makefile.am): Likewise.
3801         * modules/wcsnrtombs-tests (Makefile.am): Likewise.
3802         * modules/wcsrtombs-tests (Makefile.am): Likewise.
3803         * modules/quotearg-tests (Makefile.am): Drop EXEEXT and srcdir
3804         assignments from TESTS_ENVIRONMENT.
3805         * modules/argp-tests (Makefile.am): Drop TESTS_ENVIRONMENT
3806         augmentation.
3807         * modules/argp-version-etc-tests (Makefile.am): Likewise.
3808         * modules/atexit-tests (Makefile.am): Likewise.
3809         * modules/binary-io-tests (Makefile.am): Likewise.
3810         * modules/closein-tests (Makefile.am): Likewise.
3811         * modules/dprintf-posix-tests (Makefile.am): Likewise.
3812         * modules/exclude-tests (Makefile.am): Likewise.
3813         * modules/fflush-tests (Makefile.am): Likewise.
3814         * modules/fpending-tests (Makefile.am): Likewise.
3815         * modules/fprintf-posix-tests (Makefile.am): Likewise.
3816         * modules/freadahead-tests (Makefile.am): Likewise.
3817         * modules/freadptr-tests (Makefile.am): Likewise.
3818         * modules/freadseek-tests (Makefile.am): Likewise.
3819         * modules/fseek-tests (Makefile.am): Likewise.
3820         * modules/fseeko-tests (Makefile.am): Likewise.
3821         * modules/ftell-tests (Makefile.am): Likewise.
3822         * modules/ftello-tests (Makefile.am): Likewise.
3823         * modules/idpriv-drop-tests (Makefile.am): Likewise.
3824         * modules/idpriv-droptemp-tests (Makefile.am): Likewise.
3825         * modules/lseek-tests (Makefile.am): Likewise.
3826         * modules/parse-duration-tests (Makefile.am): Likewise.
3827         * modules/perror-tests (Makefile.am): Likewise.
3828         * modules/pipe-filter-gi-tests (Makefile.am): Likewise.
3829         * modules/pipe-filter-ii-tests (Makefile.am): Likewise.
3830         * modules/pipe-tests (Makefile.am): Likewise.
3831         * modules/pread-tests (Makefile.am): Likewise.
3832         * modules/printf-posix-tests (Makefile.am): Likewise.
3833         * modules/select-tests (Makefile.am): Likewise.
3834         * modules/sigpipe-tests (Makefile.am): Likewise.
3835         * modules/tsearch-tests (Makefile.am): Likewise.
3836         * modules/unicase/ulc-casecmp-tests (Makefile.am): Likewise.
3837         * modules/unicase/ulc-casecoll-tests (Makefile.am): Likewise.
3838         * modules/uniname/uniname-tests (Makefile.am): Likewise.
3839         * modules/uniwidth/width-tests (Makefile.am): Likewise.
3840         * modules/vdprintf-posix-tests (Makefile.am): Likewise.
3841         * modules/version-etc-tests (Makefile.am): Likewise.
3842         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
3843         * modules/vprintf-posix-tests (Makefile.am): Likewise.
3844         * modules/xalloc-die-tests (Makefile.am): Likewise.
3845         * modules/xprintf-posix-tests (Makefile.am): Likewise.
3846         * modules/xstrtoimax-tests (Makefile.am): Likewise.
3847         * modules/xstrtol-tests (Makefile.am): Likewise.
3848         * modules/xstrtoumax-tests (Makefile.am): Likewise.
3849         * modules/yesno-tests (Makefile.am): Likewise.
3850         Suggested by Jim Meyering.
3851
3852 2010-01-24  Bruno Haible  <bruno@clisp.org>
3853
3854         More documentation.
3855         * doc/gnulib.texi (Writing modules): New chapter.
3856         (Miscellaneous Notes): Move sections "Comments" and "Header files" to
3857         the new chapter.
3858
3859 2010-01-24  Jim Meyering  <meyering@redhat.com>
3860
3861         maint.mk: do not prepend "./" after filtering
3862         * top/maint.mk (_prepend_srcdir_prefix): New variable
3863         (VC_LIST_EXCEPT): Use it to avoid prepending (post-filter)
3864         "./" when $(srcdir) is ".".
3865
3866         define STREQ(a,b) consistently, removing useless parentheses
3867         #define STREQ(a, b) (strcmp ((a), (b)) == 0) is over-parenthesized,
3868         since the only risk is that "a" or "b" contains an unparenthesized
3869         comma, but if either did that, STREQ would have 3 or more arguments.
3870         Hence, #define STREQ(a, b) (strcmp (a, b) == 0) is better.
3871         * lib/fts.c (STREQ): Remove unnecessary parentheses.
3872         * lib/hash-triple.c (STREQ): Likewise.
3873         * tests/test-argv-iter.c (STREQ): Use a and b, not s1 and s2.
3874         * lib/getugroups.c (STREQ): Likewise.
3875
3876 2010-01-23  Jim Meyering  <meyering@redhat.com>
3877
3878         maint.mk: fix syntax-check in a non-srcdir build directory
3879         * top/maint.mk (_dot_escaped_srcdir): Remove erroneous backslash,
3880         introduced in my 2010-01-21 commit, a6da6c45.  Reported by Eric Blake.
3881
3882 2010-01-22  Jim Meyering  <meyering@redhat.com>
3883
3884         userspec: add unit tests
3885         * tests/test-userspec.c: New file.
3886         * modules/userspec-tests: Likewise.
3887
3888 2010-01-21  Jim Meyering  <meyering@redhat.com>
3889
3890         maint.mk: handle source file names containing "." robustly
3891         * top/maint.mk (_dot_escaped_srcdir): Define.
3892         (VC_LIST): Use it in LHS of sed substitution.
3893
3894 2010-01-21  Jiri Denemark  <jdenemar@redhat.com>
3895
3896         maint.mk: fix VC_LIST_EXCEPT for srcdir != builddir
3897         * top/maint.mk (VC_LIST_EXCEPT): Preprocess the output of
3898         $(VC_LIST) to remove a prefix of '$(srcdir)/', so that it works
3899         from a non-srcdir build.
3900
3901 2010-01-20  Eric Blake  <ebb9@byu.net>
3902
3903         warn-on-use: use instead of link-warning
3904         * modules/stdio (Depends-on, Makefile.am): Drop link-warning.
3905         * modules/unistd (Depends-on, Makefile.am): Likewise.
3906         * modules/arpa_inet (Depends-on): Replace link-warning with
3907         warn-on-use.
3908         (Makefile.am): Update rules accordingly.
3909         * modules/ctype (Depends-on, Makefile.am): Likewise.
3910         * modules/dirent (Depends-on, Makefile.am): Likewise.
3911         * modules/fcntl-h (Depends-on, Makefile.am): Likewise.
3912         * modules/inttypes (Depends-on, Makefile.am): Likewise.
3913         * modules/langinfo (Depends-on, Makefile.am): Likewise.
3914         * modules/locale (Depends-on, Makefile.am): Likewise.
3915         * modules/math (Depends-on, Makefile.am): Likewise.
3916         * modules/search (Depends-on, Makefile.am): Likewise.
3917         * modules/signal (Depends-on, Makefile.am): Likewise.
3918         * modules/spawn (Depends-on, Makefile.am): Likewise.
3919         * modules/stdlib (Depends-on, Makefile.am): Likewise.
3920         * modules/string (Depends-on, Makefile.am): Likewise.
3921         * modules/strings (Depends-on, Makefile.am): Likewise.
3922         * modules/sys_file (Depends-on, Makefile.am): Likewise.
3923         * modules/sys_ioctl (Depends-on, Makefile.am): Likewise.
3924         * modules/sys_select (Depends-on, Makefile.am): Likewise.
3925         * modules/sys_socket (Depends-on, Makefile.am): Likewise.
3926         * modules/sys_stat (Depends-on, Makefile.am): Likewise.
3927         * modules/sys_times (Depends-on, Makefile.am): Likewise.
3928         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
3929         * modules/wchar (Depends-on, Makefile.am): Likewise.
3930         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Check which functions
3931         should be poisoned.
3932         * m4/ctype.m4 (gl_CTYPE_H): Likewise.
3933         * m4/dirent_h.m4 (gl_DIRENT_H): Likewise.
3934         * m4/fcntl_h.m4 (gl_FCNTL_H): Likewise.
3935         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
3936         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
3937         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
3938         * m4/math_h.m4 (gl_MATH_H): Likewise.
3939         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
3940         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
3941         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
3942         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
3943         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
3944         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
3945         * m4/strings_h.m4 (gl_HEADER_STRINGS_H_BODY): Likewise.
3946         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
3947         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Likewise.
3948         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
3949         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
3950         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
3951         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
3952         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H): Likewise.
3953         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
3954         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
3955         * lib/arpa_inet.in.h: Use _GL_WARN_ON_USE instead of
3956         GL_LINK_WARNING.
3957         * lib/ctype.in.h: Likewise.
3958         * lib/dirent.in.h: Likewise.
3959         * lib/fcntl.in.h: Likewise.
3960         * lib/inttypes.in.h: Likewise.
3961         * lib/langinfo.in.h: Likewise.
3962         * lib/locale.in.h: Likewise.
3963         * lib/math.in.h: Likewise.
3964         * lib/search.in.h: Likewise.
3965         * lib/signal.in.h: Likewise.
3966         * lib/spawn.in.h: Likewise.
3967         * lib/stdio.in.h: Likewise.
3968         * lib/stdlib.in.h: Likewise.
3969         * lib/string.in.h: Likewise.
3970         * lib/strings.in.h: Likewise.
3971         * lib/sys_file.in.h: Likewise.
3972         * lib/sys_ioctl.in.h: Likewise.
3973         * lib/sys_select.in.h: Likewise.
3974         * lib/sys_socket.in.h: Likewise.
3975         * lib/sys_stat.in.h: Likewise.
3976         * lib/sys_times.in.h: Likewise.
3977         * lib/sys_utsname.in.h: Likewise.
3978         * lib/unistd.in.h: Likewise.
3979         * lib/wchar.in.h: Likewise.
3980
3981 2010-01-20  Bruno Haible  <bruno@clisp.org>
3982
3983         Avoid duplicate -lm.
3984         * m4/isnan.m4 (gl_ISNAN): Avoid duplicate -lm in $ISNAN_LIBM.
3985         * m4/round.m4 (gl_FUNC_ROUND): Avoid duplicate -lm in $ROUND_LIBM.
3986         * m4/roundf.m4 (gl_FUNC_ROUNDF): Avoid duplicate -lm in $ROUNDF_LIBM.
3987         * m4/roundl.m4 (gl_FUNC_ROUNDL): Avoid duplicate -lm in $ROUNDL_LIBM.
3988         * m4/acosl.m4 (gl_FUNC_ACOSL): Avoid duplicate -lm in $ACOSL_LIBM.
3989         * m4/cosl.m4 (gl_FUNC_COSL): Avoid duplicate -lm in $COSL_LIBM.
3990         * m4/logl.m4 (gl_FUNC_LOGL): Avoid duplicate -lm in $LOGL_LIBM.
3991         * m4/sinl.m4 (gl_FUNC_SINL): Avoid duplicate -lm in $SINL_LIBM.
3992         * m4/sqrtl.m4 (gl_FUNC_SQRTL): Avoid duplicate -lm in $SQRTL_LIBM.
3993         * m4/tanl.m4 (gl_FUNC_TANL): Avoid duplicate -lm in $TANL_LIBM.
3994         * m4/asinl.m4 (gl_FUNC_ASINL): Same change, for consistency.
3995         * m4/atanl.m4 (gl_FUNC_ATANL): Likewise.
3996         Reported by Paolo Bonzini.
3997
3998 2010-01-19  Bruno Haible  <bruno@clisp.org>
3999
4000         langinfo, nl_langinfo: Relicense under LGPLv2+.
4001         * modules/langinfo (License): Change to LGPLv2+.
4002         * modules/nl_langinfo (License): Likewise.
4003         Patch by David Lutterkort <lutter@redhat.com>.
4004
4005 2010-01-19  Bruno Haible  <bruno@clisp.org>
4006
4007         Avoid compilation error with cc on OSF/1 5.1.
4008         * lib/fcntl.in.h: Include <unistd.h> after the #include_next <fcntl.h>
4009         statement, not before.
4010         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4011
4012 2010-01-18  Bruno Haible  <bruno@clisp.org>
4013
4014         Avoid a link error due to the __printf__ symbol.
4015         * lib/stdio.in.h (__attribute__): Define to empty also for gcc 2.5.x
4016         and 2.6.x.
4017         (__format__, __printf__): Remove definitions.
4018         * lib/argp-fmtstream.h: Likewise.
4019         * lib/argp.h: Likewise.
4020         * lib/error.h: Likewise.
4021         * lib/vasnprintf.h: Likewise.
4022         * lib/xprintf.h: Likewise.
4023         * lib/xvasprintf.h: Likewise.
4024         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4025
4026 2010-01-18  Bruno Haible  <bruno@clisp.org>
4027
4028         Tests for module 'tanl'.
4029         * modules/tanl-tests: New file.
4030         * tests/test-tanl.c: New file.
4031
4032         Tests for module 'sqrtl'.
4033         * modules/sqrtl-tests: New file.
4034         * tests/test-sqrtl.c: New file.
4035
4036         Tests for module 'sinl'.
4037         * modules/sinl-tests: New file.
4038         * tests/test-sinl.c: New file.
4039
4040         Tests for module 'logl'.
4041         * modules/logl-tests: New file.
4042         * tests/test-logl.c: New file.
4043
4044         Tests for module 'expl'.
4045         * modules/expl-tests: New file.
4046         * tests/test-expl.c: New file.
4047
4048         Tests for module 'cosl'.
4049         * modules/cosl-tests: New file.
4050         * tests/test-cosl.c: New file.
4051
4052         Tests for module 'atanl'.
4053         * modules/atanl-tests: New file.
4054         * tests/test-atanl.c: New file.
4055
4056         Tests for module 'asinl'.
4057         * modules/asinl-tests: New file.
4058         * tests/test-asinl.c: New file.
4059
4060         Tests for module 'acosl'.
4061         * modules/acosl-tests: New file.
4062         * tests/test-acosl.c: New file.
4063
4064         New modules acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
4065         * lib/math.in.h (acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl,
4066         tanl): Use the standard gnulib idiom.
4067         * lib/cosl.c: Don't include trigl.c and sincosl.c.
4068         * lib/sinl.c: Likewise.
4069         * lib/tanl.c: Don't include trigl.c.
4070         (kernel_tanl): Make static.
4071         * lib/sincosl.c: Include trigl.h first.
4072         * lib/trigl.c: Likewise.
4073         * m4/acosl.m4: New file.
4074         * m4/asinl.m4: New file.
4075         * m4/atanl.m4: New file.
4076         * m4/cosl.m4: New file.
4077         * m4/expl.m4: New file.
4078         * m4/logl.m4: New file.
4079         * m4/sinl.m4: New file.
4080         * m4/sqrtl.m4: New file.
4081         * m4/tanl.m4: New file.
4082         * m4/mathl.m4: Remove file.
4083         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_* and HAVE_*
4084         variables for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl.
4085         Don't initialize GNULIB_MATHL.
4086         * modules/acosl: New file.
4087         * modules/asinl: New file.
4088         * modules/atanl: New file.
4089         * modules/cosl: New file.
4090         * modules/expl: New file.
4091         * modules/logl: New file.
4092         * modules/sinl: New file.
4093         * modules/sqrtl: New file.
4094         * modules/tanl: New file.
4095         * modules/math (Makefile.am): Substitute GNULIB_* and HAVE_* variables
4096         for acosl, asinl, atanl, cosl, expl, logl, sinl, sqrtl, tanl. Don't
4097         substitute GNULIB_MATHL.
4098         * modules/mathl: Rewritten.
4099         * doc/posix-functions/acosl.texi: Mention the 'acosl' module.
4100         * doc/posix-functions/asinl.texi: Mention the 'asinl' module.
4101         * doc/posix-functions/atanl.texi: Mention the 'atanl' module.
4102         * doc/posix-functions/cosl.texi: Mention the 'cosl' module.
4103         * doc/posix-functions/expl.texi: Mention the 'expl' module.
4104         * doc/posix-functions/logl.texi: Mention the 'logl' module.
4105         * doc/posix-functions/sinl.texi: Mention the 'sinl' module.
4106         * doc/posix-functions/sqrtl.texi: Mention the 'sqrtl' module.
4107         * doc/posix-functions/tanl.texi: Mention the 'tanl' module.
4108
4109 2010-01-18  Bruno Haible  <bruno@clisp.org>
4110
4111         sqrt: Make gl_FUNC_SQRT requirable.
4112         * m4/sqrt.m4: New file.
4113         * modules/sqrt (Files): Add it.
4114         (configure.ac): Invoke gl_FUNC_SQRT.
4115
4116 2010-01-18  Bruno Haible  <bruno@clisp.org>
4117
4118         New modules for common <math.h> functions.
4119         * m4/mathfunc.m4: New file.
4120         * modules/acos: New file.
4121         * modules/asin: New file.
4122         * modules/atan: New file.
4123         * modules/atan2: New file.
4124         * modules/cbrt: New file.
4125         * modules/copysign: New file.
4126         * modules/cos: New file.
4127         * modules/cosh: New file.
4128         * modules/erf: New file.
4129         * modules/erfc: New file.
4130         * modules/exp: New file.
4131         * modules/fabs: New file.
4132         * modules/fmod: New file.
4133         * modules/hypot: New file.
4134         * modules/j0: New file.
4135         * modules/j1: New file.
4136         * modules/jn: New file.
4137         * modules/ldexp: New file.
4138         * modules/lgamma: New file.
4139         * modules/log: New file.
4140         * modules/log10: New file.
4141         * modules/log1p: New file.
4142         * modules/logb: New file.
4143         * modules/modf: New file.
4144         * modules/nextafter: New file.
4145         * modules/pow: New file.
4146         * modules/remainder: New file.
4147         * modules/rint: New file.
4148         * modules/sin: New file.
4149         * modules/sinh: New file.
4150         * modules/sqrt: New file.
4151         * modules/tan: New file.
4152         * modules/tanh: New file.
4153         * modules/y0: New file.
4154         * modules/y1: New file.
4155         * modules/yn: New file.
4156         * doc/posix-functions/acos.texi: Mention the 'acos' module.
4157         * doc/posix-functions/asin.texi: Mention the 'asin' module.
4158         * doc/posix-functions/atan.texi: Mention the 'atan' module.
4159         * doc/posix-functions/atan2.texi: Mention the 'atan2' module.
4160         * doc/posix-functions/cbrt.texi: Mention the 'cbrt' module.
4161         * doc/posix-functions/copysign.texi: Mention the 'copysign' module.
4162         * doc/posix-functions/cos.texi: Mention the 'cos' module.
4163         * doc/posix-functions/cosh.texi: Mention the 'cosh' module.
4164         * doc/posix-functions/erf.texi: Mention the 'erf' module.
4165         * doc/posix-functions/erfc.texi: Mention the 'erfc' module.
4166         * doc/posix-functions/exp.texi: Mention the 'exp' module.
4167         * doc/posix-functions/fabs.texi: Mention the 'fabs' module.
4168         * doc/posix-functions/fmod.texi: Mention the 'fmod' module.
4169         * doc/posix-functions/hypot.texi: Mention the 'hypot' module.
4170         * doc/posix-functions/j0.texi: Mention the 'j0' module.
4171         * doc/posix-functions/j1.texi: Mention the 'j1' module.
4172         * doc/posix-functions/jn.texi: Mention the 'jn' module.
4173         * doc/posix-functions/ldexp.texi: Mention the 'ldexp' module.
4174         * doc/posix-functions/lgamma.texi: Mention the 'lgamma' module.
4175         * doc/posix-functions/log.texi: Mention the 'log' module.
4176         * doc/posix-functions/log10.texi: Mention the 'log10' module.
4177         * doc/posix-functions/log1p.texi: Mention the 'log1p' module.
4178         * doc/posix-functions/logb.texi: Mention the 'logb' module.
4179         * doc/posix-functions/modf.texi: Mention the 'modf' module.
4180         * doc/posix-functions/nextafter.texi: Mention the 'nextafter' module.
4181         * doc/posix-functions/pow.texi: Mention the 'pow' module.
4182         * doc/posix-functions/remainder.texi: Mention the 'remainder' module.
4183         * doc/posix-functions/rint.texi: Mention the 'rint' module.
4184         * doc/posix-functions/sin.texi: Mention the 'sin' module.
4185         * doc/posix-functions/sinh.texi: Mention the 'sinh' module.
4186         * doc/posix-functions/sqrt.texi: Mention the 'sqrt' module.
4187         * doc/posix-functions/tan.texi: Mention the 'tan' module.
4188         * doc/posix-functions/tanh.texi: Mention the 'tanh' module.
4189         * doc/posix-functions/y0.texi: Mention the 'y0' module.
4190         * doc/posix-functions/y1.texi: Mention the 'y1' module.
4191         * doc/posix-functions/yn.texi: Mention the 'yn' module.
4192
4193 2010-01-18  Jim Meyering  <meyering@redhat.com>
4194
4195         ignore-value: relax license to LGPLv2+
4196         * modules/ignore-value (License): Relax to LGPLv2+.
4197
4198         getdate: don't leak when TZ contains two or more '"'s
4199         * lib/getdate.y (get_date): Don't leak a copy of TZ for each
4200         double quote in TZ after the first one.
4201
4202         readtokens: do not leak internal token_lengths buffer
4203         * lib/readtokens.c (readtokens): Free the local, lengths,
4204         when the supplied "token_lengths" parameter is NULL.
4205
4206 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4207
4208         Fix a couple of missing LIBTHREAD link failures on AIX.
4209         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add
4210         $(LIBTHREAD).
4211         * modules/strsignal-tests (test_strsignal_LDADD): Likewise.
4212
4213         Link test-poll against INET_PTON_LIB.
4214         * modules/poll-tests (test_poll_LDADD): Add $(INET_PTON_LIB),
4215         for inet_pton on Solaris 10.
4216
4217 2010-01-17  Bruno Haible  <bruno@clisp.org>
4218
4219         unistdio/*-sprintf: Fix typo in module description.
4220         * modules/unistdio/u8-sprintf (Depends-on): Fix typo.
4221         * modules/unistdio/u8-u8-sprintf (Depends-on): Likewise.
4222         * modules/unistdio/u16-sprintf (Depends-on): Likewise.
4223         * modules/unistdio/u16-u16-sprintf (Depends-on): Likewise.
4224         * modules/unistdio/u32-sprintf (Depends-on): Likewise.
4225         * modules/unistdio/u32-u32-sprintf (Depends-on): Likewise.
4226         * modules/unistdio/ulc-sprintf (Depends-on): Likewise.
4227         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4228
4229 2010-01-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4230
4231         gnulib-tool: fix filelist for AIX, HP-UX ksh.
4232         * gnulib-tool (func_filter_filelist): Do not quote possibly-empty
4233         variables in shell case patterns, for AIX and HP-UX ksh.
4234
4235         Split large sed scripts, for HP-UX sed.
4236         * modules/stdio: Split sed scripts around 50 sed commands,
4237         to avoid HP-UX limit of 99 commands, in the near future.
4238         * modules/string: Likewise.
4239         * modules/unistd: Likewise.
4240
4241         gnulib-tool: avoid writing in the current directory.
4242         * gnulib-tool (func_emit_lib_Makefile_am)
4243         (func_emit_tests_Makefile_am): Put temporary files in $tmp,
4244         not in the current directory, so concurrent gnulib-tool
4245         instances do not interfere.
4246
4247 2010-01-16  Jim Meyering  <meyering@redhat.com>
4248
4249         doc: update users.txt
4250         * users.txt: Add grep.
4251         (diffutils, gzip): Update URLs.
4252
4253 2010-01-12  Bruno Haible  <bruno@clisp.org>
4254
4255         posix_spawn: Avoid test failure on Cygwin.
4256         * tests/test-posix_spawn3.c (DATA_FILENAME) [CYGWIN]: Use less risky
4257         characters.
4258         Reported by Simon Josefsson.
4259
4260 2010-01-12  Bruno Haible  <bruno@clisp.org>
4261
4262         * tests/test-cond.c (main): When skipping the test, show the reason.
4263
4264 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4265
4266         * lib/striconv.c (str_cd_iconv): Avoid if before free.
4267
4268 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4269
4270         * top/maint.mk (VC_LIST_EXCEPT): Filter list through
4271         VC_LIST_ALWAYS_EXCLUDE_REGEX.
4272
4273 2010-01-12  Eric Blake  <ebb9@byu.net>
4274
4275         build: guarantee AS_VAR_IF
4276         * m4/warnings.m4 (gl_WARN_ADD): Use autoconf name.
4277         (gl_AS_VAR_IF): Move...
4278         * m4/gnulib-common.m4 (AS_VAR_IF): ...here.
4279         Reported by Simon Josefsson.
4280
4281 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4282
4283         * lib/stdio.in.h: Fix typo.
4284
4285 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4286
4287         * m4/gc.m4: Check if linking to libgcrypt also needs linking to
4288         libgpg-error.
4289
4290 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4291
4292         * tests/test-xalloc-die.sh: Use $EXEEXT.
4293
4294 2010-01-12  Simon Josefsson  <simon@josefsson.org>
4295             Bruno Haible  <bruno@clisp.org>
4296
4297         getlogin, getlogin_r: Avoid test failure.
4298         * tests/test-getlogin.c: Include <stdio.h>.
4299         (main): Skip the test when the function fails because stdin is not a
4300         tty.
4301         * tests/test-getlogin_r.c: Include <stdio.h>.
4302         (main): Skip the test when the function fails because stdin is not a
4303         tty.
4304
4305 2010-01-11  Eric Blake  <ebb9@byu.net>
4306
4307         tests: avoid more large file warnings
4308         * tests/test-fflush.c: Avoid warning about ftell use.
4309         * tests/test-fseek.c: Avoid warning about fseek use.
4310
4311 2010-01-10  Bruno Haible  <bruno@clisp.org>
4312
4313         nproc: Work better on Linux when /proc and /sys are not mounted.
4314         * lib/nproc.c (num_processors): Use num_processors_via_affinity_mask ()
4315         as lower bound when, on glibc/Linux systems,
4316         sysconf (_SC_NPROCESSORS_CONF) returns 1.
4317         Suggested by Pádraig Brady <P@draigbrady.com>.
4318         Reported by Dmitry V. Levin <ldv@altlinux.org>.
4319
4320         nproc: Refactor.
4321         * lib/nproc.c (num_processors_via_affinity_mask): New function,
4322         extracted from num_processors.
4323         (num_processors): Call it.
4324
4325 2010-01-11  Jim Meyering  <meyering@redhat.com>
4326
4327         utimecmp: avoid new warning from upcoming gcc-4.5.0
4328         * lib/utimecmp.c (BILLION): Define using #define rather than an
4329         anonymous enum, to placate upcoming gcc-4.5.0's -Wenum-compare.
4330
4331 2010-01-11  Eric Blake  <ebb9@byu.net>
4332
4333         math: add portability warnings for classification macros
4334         * modules/math (Depends-on): Add warn-on-use.
4335         (Makefile.am): Provide new substitutions.
4336         * m4/math_h.m4 (gl_MATH_H): Require inline.
4337         * lib/math.in.h (_GL_WARN_REAL_FLOATING_DECL)
4338         (_GL_WARN_REAL_FLOATING_IMPL): New helper macros.
4339         (isfinite, isinf, isnan, signbit) [GNULIB_POSIXCHECK]: Use them to
4340         implement warnings.
4341
4342         unistd: warn on use of environ without module
4343         * modules/unistd (Depends-on): Add warn-on-use.
4344         (Makefile.am): Provide new substitutions.
4345         * m4/unistd_h.m4 (gl_UNISTD_H): Check for inline and environ.
4346         * lib/unistd.in.h (environ): Wrap with a warning helper function.
4347
4348         stdio: warn on suspicious uses
4349         * modules/stdio (Depends-on): Add warn-on-use.
4350         (Makefile.am): Provide new substitutions.
4351         * m4/stdio_h.m4 (gl_STDIO_H): Check for inline, ftello, and
4352         fseeko.
4353         * lib/stdio.in.h (gets): Always warn on use.
4354         (fseek, ftell): Adjust when warnings are issued, and honor
4355         _GL_NO_LARGE_FILES as a way to silence the warning.
4356         * tests/test-fpurge.c [!GNULIB_FSEEK]: Use new means to squelch
4357         any warning about large file offsets.
4358         * tests/test-freadable.c [!GNULIB_FSEEK]: Likewise.
4359         * tests/test-freading.c [!GNULIB_FSEEK]: Likewise.
4360         * tests/test-fseeko.c [!GNULIB_FSEEK]: Likewise.
4361         * tests/test-ftell.c [!GNULIB_FSEEK]: Likewise.
4362         * tests/test-ftello.c [!GNULIB_FSEEK]: Likewise.
4363         * tests/test-fwritable.c [!GNULIB_FSEEK]: Likewise.
4364         * tests/test-fwriting.c [!GNULIB_FSEEK]: Likewise.
4365         * tests/test-getopt.c [!GNULIB_FTELL]: Likewise.
4366
4367         warn-on-use: new module
4368         * modules/warn-on-use: New file.
4369         * build-aux/warn-on-use.h: Likewise.
4370         * m4/warn-on-use.m4: Likewise.
4371         * MODULES.html.sh (Support for building): Mention it.
4372
4373 2010-01-10  Bruno Haible  <bruno@clisp.org>
4374
4375         Tests for module 'unistr/u32-strdup'.
4376         * modules/unistr/u32-strdup-tests: New file.
4377         * tests/unistr/test-u32-strdup.c: New file.
4378
4379         Tests for module 'unistr/u16-strdup'.
4380         * modules/unistr/u16-strdup-tests: New file.
4381         * tests/unistr/test-u16-strdup.c: New file.
4382
4383         Tests for module 'unistr/u8-strdup'.
4384         * modules/unistr/u8-strdup-tests: New file.
4385         * tests/unistr/test-u8-strdup.c: New file.
4386         * tests/unistr/test-strdup.h: New file.
4387
4388         Tests for module 'unistr/u32-strncmp'.
4389         * modules/unistr/u32-strncmp-tests: New file.
4390         * tests/unistr/test-u32-strncmp.c: New file.
4391
4392         Tests for module 'unistr/u16-strncmp'.
4393         * modules/unistr/u16-strncmp-tests: New file.
4394         * tests/unistr/test-u16-strncmp.c: New file.
4395
4396         Tests for module 'unistr/u8-strncmp'.
4397         * modules/unistr/u8-strncmp-tests: New file.
4398         * tests/unistr/test-u8-strncmp.c: New file.
4399         * tests/unistr/test-strncmp.h: New file.
4400
4401         Tests for module 'unistr/u32-strcoll'.
4402         * modules/unistr/u32-strcoll-tests: New file.
4403         * tests/unistr/test-u32-strcoll.c: New file.
4404
4405         Tests for module 'unistr/u16-strcoll'.
4406         * modules/unistr/u16-strcoll-tests: New file.
4407         * tests/unistr/test-u16-strcoll.c: New file.
4408
4409         Tests for module 'unistr/u8-strcoll'.
4410         * modules/unistr/u8-strcoll-tests: New file.
4411         * tests/unistr/test-u8-strcoll.c: New file.
4412
4413         Tests for module 'unistr/u32-strcmp'.
4414         * modules/unistr/u32-strcmp-tests: New file.
4415         * tests/unistr/test-u32-strcmp.c: New file.
4416         * tests/unistr/test-u32-strcmp.h: New file.
4417
4418         Tests for module 'unistr/u16-strcmp'.
4419         * modules/unistr/u16-strcmp-tests: New file.
4420         * tests/unistr/test-u16-strcmp.c: New file.
4421         * tests/unistr/test-u16-strcmp.h: New file.
4422
4423         Tests for module 'unistr/u8-strcmp'.
4424         * modules/unistr/u8-strcmp-tests: New file.
4425         * tests/unistr/test-u8-strcmp.c: New file.
4426         * tests/unistr/test-u8-strcmp.h: New file.
4427         * tests/unistr/test-strcmp.h: New file.
4428
4429         Tests for module 'unistr/u32-strncat'.
4430         * modules/unistr/u32-strncat-tests: New file.
4431         * tests/unistr/test-u32-strncat.c: New file.
4432
4433         Tests for module 'unistr/u16-strncat'.
4434         * modules/unistr/u16-strncat-tests: New file.
4435         * tests/unistr/test-u16-strncat.c: New file.
4436
4437         Tests for module 'unistr/u8-strncat'.
4438         * modules/unistr/u8-strncat-tests: New file.
4439         * tests/unistr/test-u8-strncat.c: New file.
4440         * tests/unistr/test-strncat.h: New file.
4441
4442         Tests for module 'unistr/u32-strcat'.
4443         * modules/unistr/u32-strcat-tests: New file.
4444         * tests/unistr/test-u32-strcat.c: New file.
4445
4446         Tests for module 'unistr/u16-strcat'.
4447         * modules/unistr/u16-strcat-tests: New file.
4448         * tests/unistr/test-u16-strcat.c: New file.
4449
4450         Tests for module 'unistr/u8-strcat'.
4451         * modules/unistr/u8-strcat-tests: New file.
4452         * tests/unistr/test-u8-strcat.c: New file.
4453         * tests/unistr/test-strcat.h: New file.
4454
4455         Tests for module 'unistr/u32-stpncpy'.
4456         * modules/unistr/u32-stpncpy-tests: New file.
4457         * tests/unistr/test-u32-stpncpy.c: New file.
4458
4459         Tests for module 'unistr/u16-stpncpy'.
4460         * modules/unistr/u16-stpncpy-tests: New file.
4461         * tests/unistr/test-u16-stpncpy.c: New file.
4462
4463         Tests for module 'unistr/u8-stpncpy'.
4464         * modules/unistr/u8-stpncpy-tests: New file.
4465         * tests/unistr/test-u8-stpncpy.c: New file.
4466         * tests/unistr/test-stpncpy.h: New file.
4467
4468         Tests for module 'unistr/u32-strncpy'.
4469         * modules/unistr/u32-strncpy-tests: New file.
4470         * tests/unistr/test-u32-strncpy.c: New file.
4471
4472         Tests for module 'unistr/u16-strncpy'.
4473         * modules/unistr/u16-strncpy-tests: New file.
4474         * tests/unistr/test-u16-strncpy.c: New file.
4475
4476         Tests for module 'unistr/u8-strncpy'.
4477         * modules/unistr/u8-strncpy-tests: New file.
4478         * tests/unistr/test-u8-strncpy.c: New file.
4479         * tests/unistr/test-strncpy.h: New file.
4480
4481         Tests for module 'unistr/u32-stpcpy'.
4482         * modules/unistr/u32-stpcpy-tests: New file.
4483         * tests/unistr/test-u32-stpcpy.c: New file.
4484
4485         Tests for module 'unistr/u16-stpcpy'.
4486         * modules/unistr/u16-stpcpy-tests: New file.
4487         * tests/unistr/test-u16-stpcpy.c: New file.
4488
4489         Tests for module 'unistr/u8-stpcpy'.
4490         * modules/unistr/u8-stpcpy-tests: New file.
4491         * tests/unistr/test-u8-stpcpy.c: New file.
4492         * tests/unistr/test-stpcpy.h: New file.
4493
4494         Tests for module 'unistr/u32-strcpy'.
4495         * modules/unistr/u32-strcpy-tests: New file.
4496         * tests/unistr/test-u32-strcpy.c: New file.
4497
4498         Tests for module 'unistr/u16-strcpy'.
4499         * modules/unistr/u16-strcpy-tests: New file.
4500         * tests/unistr/test-u16-strcpy.c: New file.
4501
4502         Tests for module 'unistr/u8-strcpy'.
4503         * modules/unistr/u8-strcpy-tests: New file.
4504         * tests/unistr/test-u8-strcpy.c: New file.
4505         * tests/unistr/test-strcpy.h: New file.
4506
4507         Tests for module 'unistr/u32-strnlen'.
4508         * modules/unistr/u32-strnlen-tests: New file.
4509         * tests/unistr/test-u32-strnlen.c: New file.
4510
4511         Tests for module 'unistr/u16-strnlen'.
4512         * modules/unistr/u16-strnlen-tests: New file.
4513         * tests/unistr/test-u16-strnlen.c: New file.
4514
4515         Tests for module 'unistr/u8-strnlen'.
4516         * modules/unistr/u8-strnlen-tests: New file.
4517         * tests/unistr/test-u8-strnlen.c: New file.
4518         * tests/unistr/test-strnlen.h: New file.
4519
4520         Tests for module 'unistr/u32-strlen'.
4521         * modules/unistr/u32-strlen-tests: New file.
4522         * tests/unistr/test-u32-strlen.c: New file.
4523
4524         Tests for module 'unistr/u16-strlen'.
4525         * modules/unistr/u16-strlen-tests: New file.
4526         * tests/unistr/test-u16-strlen.c: New file.
4527
4528         Tests for module 'unistr/u8-strlen'.
4529         * modules/unistr/u8-strlen-tests: New file.
4530         * tests/unistr/test-u8-strlen.c: New file.
4531
4532         Tests for module 'unistr/u32-prev'.
4533         * modules/unistr/u32-prev-tests: New file.
4534         * tests/unistr/test-u32-prev.c: New file.
4535
4536         Tests for module 'unistr/u16-prev'.
4537         * modules/unistr/u16-prev-tests: New file.
4538         * tests/unistr/test-u16-prev.c: New file.
4539
4540         Tests for module 'unistr/u8-prev'.
4541         * modules/unistr/u8-prev-tests: New file.
4542         * tests/unistr/test-u8-prev.c: New file.
4543
4544         Tests for module 'unistr/u32-next'.
4545         * modules/unistr/u32-next-tests: New file.
4546         * tests/unistr/test-u32-next.c: New file.
4547
4548         Tests for module 'unistr/u16-next'.
4549         * modules/unistr/u16-next-tests: New file.
4550         * tests/unistr/test-u16-next.c: New file.
4551
4552         Tests for module 'unistr/u8-next'.
4553         * modules/unistr/u8-next-tests: New file.
4554         * tests/unistr/test-u8-next.c: New file.
4555
4556         Tests for module 'unistr/u32-strmbtouc'.
4557         * modules/unistr/u32-strmbtouc-tests: New file.
4558         * tests/unistr/test-u32-strmbtouc.c: New file.
4559
4560         Tests for module 'unistr/u16-strmbtouc'.
4561         * modules/unistr/u16-strmbtouc-tests: New file.
4562         * tests/unistr/test-u16-strmbtouc.c: New file.
4563
4564         Tests for module 'unistr/u8-strmbtouc'.
4565         * modules/unistr/u8-strmbtouc-tests: New file.
4566         * tests/unistr/test-u8-strmbtouc.c: New file.
4567
4568         Tests for module 'unistr/u32-strmblen'.
4569         * modules/unistr/u32-strmblen-tests: New file.
4570         * tests/unistr/test-u32-strmblen.c: New file.
4571
4572         Tests for module 'unistr/u16-strmblen'.
4573         * modules/unistr/u16-strmblen-tests: New file.
4574         * tests/unistr/test-u16-strmblen.c: New file.
4575
4576         Tests for module 'unistr/u8-strmblen'.
4577         * modules/unistr/u8-strmblen-tests: New file.
4578         * tests/unistr/test-u8-strmblen.c: New file.
4579
4580         Tests for module 'unistr/u32-cpy-alloc'.
4581         * modules/unistr/u32-cpy-alloc-tests: New file.
4582         * tests/unistr/test-u32-cpy-alloc.c: New file.
4583
4584         Tests for module 'unistr/u16-cpy-alloc'.
4585         * modules/unistr/u16-cpy-alloc-tests: New file.
4586         * tests/unistr/test-u16-cpy-alloc.c: New file.
4587
4588         Tests for module 'unistr/u8-cpy-alloc'.
4589         * modules/unistr/u8-cpy-alloc-tests: New file.
4590         * tests/unistr/test-u8-cpy-alloc.c: New file.
4591         * tests/unistr/test-cpy-alloc.h: New file.
4592
4593         Tests for module 'unistr/u32-mbsnlen'.
4594         * modules/unistr/u32-mbsnlen-tests: New file.
4595         * tests/unistr/test-u32-mbsnlen.c: New file.
4596
4597         Tests for module 'unistr/u16-mbsnlen'.
4598         * modules/unistr/u16-mbsnlen-tests: New file.
4599         * tests/unistr/test-u16-mbsnlen.c: New file.
4600
4601         Tests for module 'unistr/u8-mbsnlen'.
4602         * modules/unistr/u8-mbsnlen-tests: New file.
4603         * tests/unistr/test-u8-mbsnlen.c: New file.
4604
4605         Tests for module 'unistr/u32-chr'.
4606         * modules/unistr/u32-chr-tests: New file.
4607         * tests/unistr/test-u32-chr.c: New file.
4608
4609         Tests for module 'unistr/u16-chr'.
4610         * modules/unistr/u16-chr-tests: New file.
4611         * tests/unistr/test-u16-chr.c: New file.
4612
4613         Tests for module 'unistr/u8-chr'.
4614         * modules/unistr/u8-chr-tests: New file.
4615         * tests/unistr/test-u8-chr.c: New file.
4616         * tests/unistr/test-chr.h: New file, based on tests/test-memchr.c.
4617
4618         Tests for module 'unistr/u32-cmp2'.
4619         * modules/unistr/u32-cmp2-tests: New file.
4620         * tests/unistr/test-u32-cmp2.c: New file.
4621
4622         Tests for module 'unistr/u16-cmp2'.
4623         * modules/unistr/u16-cmp2-tests: New file.
4624         * tests/unistr/test-u16-cmp2.c: New file.
4625
4626         Tests for module 'unistr/u8-cmp2'.
4627         * modules/unistr/u8-cmp2-tests: New file.
4628         * tests/unistr/test-u8-cmp2.c: New file.
4629         * tests/unistr/test-cmp2.h: New file, based on tests/unistr/test-cmp.h.
4630
4631         Tests for module 'unistr/u32-cmp'.
4632         * modules/unistr/u32-cmp-tests: New file.
4633         * tests/unistr/test-u32-cmp.c: New file.
4634
4635         Tests for module 'unistr/u16-cmp'.
4636         * modules/unistr/u16-cmp-tests: New file.
4637         * tests/unistr/test-u16-cmp.c: New file.
4638
4639         Tests for module 'unistr/u8-cmp'.
4640         * modules/unistr/u8-cmp-tests: New file.
4641         * tests/unistr/test-u8-cmp.c: New file.
4642         * tests/unistr/test-cmp.h: New file, based on tests/test-memcmp.c.
4643
4644         Tests for module 'unistr/u32-set'.
4645         * modules/unistr/u32-set-tests: New file.
4646         * tests/unistr/test-u32-set.c: New file.
4647
4648         Tests for module 'unistr/u16-set'.
4649         * modules/unistr/u16-set-tests: New file.
4650         * tests/unistr/test-u16-set.c: New file.
4651
4652         Tests for module 'unistr/u8-set'.
4653         * modules/unistr/u8-set-tests: New file.
4654         * tests/unistr/test-u8-set.c: New file.
4655         * tests/unistr/test-set.h: New file.
4656
4657         Tests for module 'unistr/u32-move'.
4658         * modules/unistr/u32-move-tests: New file.
4659         * tests/unistr/test-u32-move.c: New file.
4660
4661         Tests for module 'unistr/u16-move'.
4662         * modules/unistr/u16-move-tests: New file.
4663         * tests/unistr/test-u16-move.c: New file.
4664
4665         Tests for module 'unistr/u8-move'.
4666         * modules/unistr/u8-move-tests: New file.
4667         * tests/unistr/test-u8-move.c: New file.
4668         * tests/unistr/test-move.h: New file.
4669
4670         Tests for module 'unistr/u32-cpy'.
4671         * modules/unistr/u32-cpy-tests: New file.
4672         * tests/unistr/test-u32-cpy.c: New file.
4673
4674         Tests for module 'unistr/u16-cpy'.
4675         * modules/unistr/u16-cpy-tests: New file.
4676         * tests/unistr/test-u16-cpy.c: New file.
4677
4678         Tests for module 'unistr/u8-cpy'.
4679         * modules/unistr/u8-cpy-tests: New file.
4680         * tests/unistr/test-u8-cpy.c: New file.
4681         * tests/unistr/test-cpy.h: New file.
4682
4683 2010-01-09  Bruno Haible  <bruno@clisp.org>
4684
4685         Tests for module 'unistr/u32-uctomb'.
4686         * modules/unistr/u32-uctomb-tests: New file.
4687         * tests/unistr/test-u32-uctomb.c: New file.
4688
4689         Tests for module 'unistr/u16-uctomb'.
4690         * modules/unistr/u16-uctomb-tests: New file.
4691         * tests/unistr/test-u16-uctomb.c: New file.
4692
4693         Tests for module 'unistr/u8-uctomb'.
4694         * modules/unistr/u8-uctomb-tests: New file.
4695         * tests/unistr/test-u8-uctomb.c: New file.
4696
4697         Tests for module 'unistr/u32-mbtoucr'.
4698         * modules/unistr/u32-mbtoucr-tests: New file.
4699         * tests/unistr/test-u32-mbtoucr.c: New file.
4700
4701         Tests for module 'unistr/u16-mbtoucr'.
4702         * modules/unistr/u16-mbtoucr-tests: New file.
4703         * tests/unistr/test-u16-mbtoucr.c: New file.
4704
4705         Tests for module 'unistr/u8-mbtoucr'.
4706         * modules/unistr/u8-mbtoucr-tests: New file.
4707         * tests/unistr/test-u8-mbtoucr.c: New file.
4708
4709         Tests for module 'unistr/u32-mbtouc'.
4710         * modules/unistr/u32-mbtouc-tests: New file.
4711         * tests/unistr/test-u32-mbtouc.c: New file.
4712
4713         Tests for module 'unistr/u16-mbtouc'.
4714         * modules/unistr/u16-mbtouc-tests: New file.
4715         * tests/unistr/test-u16-mbtouc.c: New file.
4716
4717         Tests for module 'unistr/u8-mbtouc'.
4718         * modules/unistr/u8-mbtouc-tests: New file.
4719         * tests/unistr/test-u8-mbtouc.c: New file.
4720
4721         Tests for module 'unistr/u32-mbtouc-unsafe'.
4722         * modules/unistr/u32-mbtouc-unsafe-tests: New file.
4723         * tests/unistr/test-u32-mbtouc-unsafe.c: New file.
4724         * tests/unistr/test-u32-mbtouc.h: New file.
4725
4726         Tests for module 'unistr/u16-mbtouc-unsafe'.
4727         * modules/unistr/u16-mbtouc-unsafe-tests: New file.
4728         * tests/unistr/test-u16-mbtouc-unsafe.c: New file.
4729         * tests/unistr/test-u16-mbtouc.h: New file.
4730
4731         Tests for module 'unistr/u8-mbtouc-unsafe'.
4732         * modules/unistr/u8-mbtouc-unsafe-tests: New file.
4733         * tests/unistr/test-u8-mbtouc-unsafe.c: New file.
4734         * tests/unistr/test-u8-mbtouc.h: New file.
4735
4736         Tests for module 'unistr/u32-mblen'.
4737         * modules/unistr/u32-mblen-tests: New file.
4738         * tests/unistr/test-u32-mblen.c: New file.
4739
4740         Tests for module 'unistr/u16-mblen'.
4741         * modules/unistr/u16-mblen-tests: New file.
4742         * tests/unistr/test-u16-mblen.c: New file.
4743
4744         Tests for module 'unistr/u8-mblen'.
4745         * modules/unistr/u8-mblen-tests: New file.
4746         * tests/unistr/test-u8-mblen.c: New file.
4747
4748         Tests for module 'unistr/u32-to-u16'.
4749         * modules/unistr/u32-to-u16-tests: New file.
4750         * tests/unistr/test-u32-to-u16.c: New file.
4751
4752         Tests for module 'unistr/u32-to-u8'.
4753         * modules/unistr/u32-to-u8-tests: New file.
4754         * tests/unistr/test-u32-to-u8.c: New file.
4755
4756         Tests for module 'unistr/u16-to-u32'.
4757         * modules/unistr/u16-to-u32-tests: New file.
4758         * tests/unistr/test-u16-to-u32.c: New file.
4759
4760         Tests for module 'unistr/u16-to-u8'.
4761         * modules/unistr/u16-to-u8-tests: New file.
4762         * tests/unistr/test-u16-to-u8.c: New file.
4763
4764         Tests for module 'unistr/u8-to-u32'.
4765         * modules/unistr/u8-to-u32-tests: New file.
4766         * tests/unistr/test-u8-to-u32.c: New file.
4767
4768         Tests for module 'unistr/u8-to-u16'.
4769         * modules/unistr/u8-to-u16-tests: New file.
4770         * tests/unistr/test-u8-to-u16.c: New file.
4771
4772         Tests for module 'unistr/u32-check'.
4773         * modules/unistr/u32-check-tests: New file.
4774         * tests/unistr/test-u32-check.c: New file.
4775
4776         Tests for module 'unistr/u16-check'.
4777         * modules/unistr/u16-check-tests: New file.
4778         * tests/unistr/test-u16-check.c: New file.
4779
4780         Tests for module 'unistr/u8-check'.
4781         * modules/unistr/u8-check-tests: New file.
4782         * tests/unistr/test-u8-check.c: New file.
4783
4784         * tests/unictype/test-categ_byname.c: Include <stdbool.h>.
4785         (category_equals): New function.
4786         (main): Add more tests.
4787         * modules/unictype/category-byname-tests (Depends-on): Add stdbool.
4788
4789         * tests/unictype/test-bidi_byname.c (main): Add more tests.
4790
4791 2010-01-10  Bruno Haible  <bruno@clisp.org>
4792
4793         unistr/u*-strcoll: Try harder to distinguish different strings.
4794         * lib/unistr/u-strcoll.h (FUNC): When sl1 and sl2 are the same,
4795         compare s1 and s2 to see if they are different.
4796
4797 2010-01-10  Bruno Haible  <bruno@clisp.org>
4798
4799         unistr/u*-stpncpy: Fix the return value.
4800         * lib/unistr.h (u8_stpncpy, u16_stpncpy, u32_stpncpy): Make the
4801         description of the return value consistent with stpncpy in glibc.
4802         * lib/unistr/u-stpncpy.h (FUNC): Return the pointer past the last
4803         written non-NUL unit.
4804
4805 2010-01-10  Bruno Haible  <bruno@clisp.org>
4806
4807         unistr/u*-next: Add missing dependencies.
4808         * modules/unistr/u8-next (Depends-on): Add unistr/u8-strmbtouc.
4809         * modules/unistr/u16-next (Depends-on): Add unistr/u16-strmbtouc.
4810         * modules/unistr/u32-next (Depends-on): Add unistr/u32-strmbtouc.
4811
4812 2010-01-10  Bruno Haible  <bruno@clisp.org>
4813
4814         unistr/u8-mbsnlen: Fix return value for incomplete character.
4815         * lib/unistr/u8-mbsnlen.c (u8_mbsnlen): Use u8_mbtoucr instead of
4816         u8_mblen.
4817         * modules/unistr/u8-mbsnlen (Depends-on): Add unistr/u8-mbtoucr.
4818         Remove unistr/u8-mblen.
4819         * lib/unistr/u16-mbsnlen.c (u16_mbsnlen): Use u16_mbtoucr instead of
4820         u16_mblen.
4821         * modules/unistr/u16-mbsnlen (Depends-on): Add unistr/u16-mbtoucr.
4822         Remove unistr/u16-mblen.
4823
4824 2010-01-10  Bruno Haible  <bruno@clisp.org>
4825
4826         wchar: Fix compilation error when <wchar.h> is used from coreutils.
4827         * lib/wchar.in.h: Treat __need_wint_t like __need_mbstate_t.
4828         Reported by Brian Gough <bjg@gnu.org> and
4829         Chris Clayton <chris2553@googlemail.com> via
4830         Mike Frysinger <vapier@gentoo.org> and Jim Meyering <jim@meyering.net>.
4831
4832 2010-01-09  Bruno Haible  <bruno@clisp.org>
4833
4834         unistr/u16-to-u32: Reject invalid input.
4835         * lib/unistr/u16-to-u32.c (u16_to_u32): Call u16_mbtoucr instead of
4836         u16_mbtouc.
4837         * modules/unistr/u16-to-u32 (Depends-on): Add unistr/u16-mbtoucr.
4838         Remove unistr/u16-mbtouc.
4839
4840         unistr/u16-to-u8: Reject invalid input.
4841         * lib/unistr/u16-to-u8.c (u16_to_u8): Call u16_mbtoucr instead of
4842         u16_mbtouc.
4843         * modules/unistr/u16-to-u8 (Depends-on): Add unistr/u16-mbtoucr.
4844         Remove unistr/u16-mbtouc.
4845
4846         unistr/u8-to-u32: Reject invalid input.
4847         * lib/unistr/u8-to-u32.c (u8_to_u32): Call u8_mbtoucr instead of
4848         u8_mbtouc.
4849         * modules/unistr/u8-to-u32 (Depends-on): Add unistr/u8-mbtoucr.
4850         Remove unistr/u8-mbtouc.
4851
4852         unistr/u8-to-u16: Reject invalid input.
4853         * lib/unistr/u8-to-u16.c (u8_to_u16): Call u8_mbtoucr instead of
4854         u8_mbtouc.
4855         * modules/unistr/u8-to-u16 (Depends-on): Add unistr/u8-mbtoucr.
4856         Remove unistr/u8-mbtouc.
4857
4858 2010-01-09  Bruno Haible  <bruno@clisp.org>
4859
4860         Tests for module 'getlogin'.
4861         * modules/getlogin-tests: New file.
4862         * tests/test-getlogin.c: New file.
4863
4864         New module 'getlogin'.
4865         * lib/unistd.in.h (getlogin): New declaration.
4866         * lib/getlogin.c: New file.
4867         * m4/getlogin.m4: New file.
4868         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETLOGIN,
4869         HAVE_GETLOGIN.
4870         * modules/unistd (Makefile.am): Substitute GNULIB_GETLOGIN,
4871         HAVE_GETLOGIN.
4872         * modules/getlogin: New file.
4873         * doc/posix-functions/getlogin.texi: Mention the new module.
4874         Reported by John W. Eaton <jwe@gnu.org>.
4875
4876 2010-01-09  Bruno Haible  <bruno@clisp.org>
4877
4878         getlogin_r: Support for native Windows.
4879         * lib/getlogin_r.c: Include <windows.h>
4880         (getlogin_r): Implement for native Windows.
4881         * tests/test-getlogin_r.c (main): Also test with a huge buffer.
4882         Reported by Tatsuro MATSUOKA <tmacchant5@yahoo.co.jp>
4883         via John W. Eaton <jwe@gnu.org>.
4884
4885 2010-01-09  Bruno Haible  <bruno@clisp.org>
4886
4887         getlogin_r: Small fixes.
4888         * lib/getlogin_r.c (getlogin_r): Don't set errno if the function
4889         succeeds.
4890         * m4/getlogin_r.m4 (gl_GETLOGIN_R): Require gl_USE_SYSTEM_EXTENSIONS
4891         before testing whether getlogin_r is declared. No need to set
4892         HAVE_DECL_GETLOGIN_R to 1.
4893         (gl_PREREQ_GETLOGIN_R): Don't check for the getlogin_r declaration.
4894
4895 2010-01-09  Bruno Haible  <bruno@clisp.org>
4896
4897         * lib/unistd.in.h (getlogin_r): Add comment.
4898
4899 2010-01-09  Bruno Haible  <bruno@clisp.org>
4900
4901         Tests for module 'getlogin_r'.
4902         * modules/getlogin_r-tests: New file.
4903         * tests/test-getlogin_r.c: New file.
4904
4905 2010-01-09  Jim Meyering  <meyering@redhat.com>
4906
4907         maint.mk: extend proper_name_utf8-vs-LIBICONV-checking rule
4908         * top/maint.mk (sc_proper_name_utf8_requires_ICONV): Adapt to work
4909         also when $(LIBICONV) is part of LDADD, rather than ${prog}_LDADD.
4910
4911 2010-01-08  Simon Josefsson  <simon@josefsson.org>
4912
4913         * lib/dup2.c (rpl_dup2): Improve comment.
4914
4915 2010-01-08  Eric Blake  <ebb9@byu.net>
4916
4917         maint.mk: allow packages to add makefile @@ exceptions
4918         * top/maint.mk (_makefile_at_at_check_exceptions): New hook.
4919         (sc_makefile_check): Rename...
4920         (sc_makefile_at_at_check): ...to this, and use hook.
4921
4922         dup2: work around mingw bug
4923         * lib/dup2.c (rpl_dup2): Sanitize return value on mingw.
4924         Reported by Simon Josefsson.
4925
4926 2010-01-07  John W. Eaton  <jwe@octave.org>  (tiny change)
4927
4928         glob: Fix C++ compilation.
4929         * lib/glob.in.h [__cplusplus]: Define __BEGIN_DECLS and __END_DECLS for
4930         C++.
4931
4932 2010-01-07  Bruno Haible  <bruno@clisp.org>
4933
4934         Fix indentation of wctype.in.h, broken since 2007-01-06.
4935         * lib/wctype.in.h: Fix indentation of preprocessor directives.
4936
4937 2010-01-07  Bruno Haible  <bruno@clisp.org>
4938
4939         mbslen: Avoid collision with system function.
4940         * lib/string.in.h [MirBSD]: Include <wchar.h>.
4941         (mbslen): Undefine first. Alias mbslen to rpl_mbslen.
4942         * m4/mbslen.m4: New file.
4943         * modules/mbslen (Files): Add it.
4944         (configure.ac): Invoke gl_MBSLEN.
4945         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize HAVE_MBSLEN.
4946         * modules/string (Makefile.am): Substitute HAVE_MBSLEN.
4947         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>
4948         via Ian Beckwith <ianb@erislabs.net>.
4949
4950 2010-01-07  Bruno Haible  <bruno@clisp.org>
4951
4952         dirent: Document the last fix.
4953         * doc/posix-headers/dirent.texi: Document the bug of missing 'ino_t'.
4954
4955 2010-01-07  Bruno Haible  <bruno@clisp.org>
4956
4957         stdio: Ensure <stdio.h> defines off_t, ssize_t, va_list.
4958         * lib/stdio.in.h: Include <sys/types.h> unconditionally.
4959         * tests/test-stdio.c: Verify that fpos_t, off_t, size_t, ssize_t,
4960         va_list are defined.
4961         * doc/posix-headers/stdio.texi: Document the bug of missing types.
4962         Reported by Eric Blake.
4963
4964 2010-01-07  Bruno Haible  <bruno@clisp.org>
4965
4966         xlist, xoset: Fix missing dependency bug, introduced on 2009-12-13.
4967         * modules/xlist (Depends-on): Add 'list',
4968         * modules/xoset (Depends-on): Add 'oset'.
4969         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4970
4971 2010-01-07  Bruno Haible  <bruno@clisp.org>
4972
4973         * doc/posix-functions/strcasecmp.texi: Clarify the platforms.
4974         * doc/posix-functions/strncasecmp.texi: Likewise.
4975
4976 2010-01-07  Bruno Haible  <bruno@clisp.org>
4977
4978         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Simplify logic.
4979
4980 2010-01-07  John W. Eaton  <jwe@octave.org>
4981
4982         wctype: allow C++ use
4983         * lib/wctype.in.h: Add extern "C" block for C++.
4984
4985 2010-01-06  Eric Blake  <ebb9@byu.net>
4986
4987         maint.mk: detect incorrect GFDL usage
4988         * top/maint.mk (_GFDL_regexp, sc_GFDL_version): New rule.
4989
4990 2010-01-06  Jim Meyering  <meyering@redhat.com>
4991         and Eric Blake  <ebb9@byu.net>
4992
4993         maint.mk: ignore multi-line copyright in NEWS
4994         * top/maint.mk (NEWS_hash): Add immunity to multi-line copyright.
4995
4996 2010-01-06  Eric Blake  <ebb9@byu.net>
4997
4998         select: add missing dependency
4999         * modules/select-tests (Depends-on): Move sockets dependency...
5000         * modules/select (Depends-on): ...here.
5001         Reported by Ian Beckwith.
5002
5003         doc: regenerate INSTALL
5004         * doc/INSTALL: Reflect recent autoconf update.
5005         * doc/INSTALL.ISO: Likewise.
5006         * doc/INSTALL.UTF-8: Likewise.
5007
5008         pread: fix compilation on glibc
5009         * m4/pread.m4 (gl_FUNC_PREAD): Request all interfaces.
5010         Reported by Ralf Wildenhues.
5011
5012         dirent: fix test failure
5013         * lib/dirent.in.h (includes): Guarantee ino_t.
5014         Reported by Ralf Wildenhues.
5015
5016 2010-01-06  Petr Salinger  <Petr.Salinger@seznam.cz>  (tiny change)
5017
5018         linkat, renameat: avoid bad free
5019         * lib/at-func2.c (at_func2): Fix typo.
5020         Reported via Ian Beckwith, from http://bugs.debian.org/561117.
5021
5022 2010-01-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5023
5024         cleanup after gl_FUNC_READLINK, for gl_FUNC_SYMLINK test
5025         * m4/readlink.m4 (gl_FUNC_READLINK): Remove conftest.lnk2,
5026         to avoid failure of symlink test later.
5027
5028 2010-01-06  Eric Blake  <ebb9@byu.net>
5029
5030         stdio, unistd: guarantee ssize_t
5031         * lib/unistd.in.h (includes): Ensure that types required by POSIX
5032         2008 are exposed when needed.
5033         * lib/stdio.in.h (includes): Likewise.
5034         Reported by Ralf Wildenhues.
5035
5036 2010-01-06  Paolo Bonzini  <bonzini@gnu.org>
5037
5038         nl_langinfo: do not call AC_CHECK_FUNC_ONCE inside if.
5039         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): Do not call
5040         AC_CHECK_FUNC_ONCE inside if, do not adjust ac_cv_func_nl_langinfo.
5041
5042 2010-01-06  Jim Meyering  <meyering@redhat.com>
5043
5044         readtokens: this module *does* require xalloc.h
5045         It uses only functions that were omitted by the old syntax-check rule.
5046         * lib/readtokens.c: Include "xalloc.h" once again.
5047         * modules/readtokens (Depends-on): Add xalloc.
5048         This reverts part of 0e0f8f12ec241c0f1c1f21f960bb5cf908a0fa3c.
5049
5050 2010-01-05  Eric Blake  <ebb9@byu.net>
5051
5052         maint: support 'make announcement' from a VPATH build
5053         * top/maint.mk (announcement): Look for correct NEWS file.
5054
5055 2010-01-05  Aurelien Jarno  <aurelien@aurel32.net>  (tiny change)
5056
5057         utimens (fdutimens): ignore a negative FD, per contract
5058         * lib/utimens.c (fdutimens) [HAVE_FUTIMENS]: Call futimens only
5059         when we have a valid file descriptor.  Otherwise, using a brand
5060         new glibc (with just-patched futimens that now fails with EBADF)
5061         would cause this function to fail with ENOSYS.
5062         Reported by Guillaume Ayoub in http://bugs.debian.org/563726.
5063         See also http://bugzilla.redhat.com/552320.
5064
5065 2010-01-05  Eric Blake  <ebb9@byu.net>
5066
5067         strcase: document what it provides
5068         * doc/posix-functions/strcasecmp.texi (strcasecmp): Mention the
5069         gnulib module.
5070         * doc/posix-functions/strncasecmp.texi (strncasecmp): Likewise.
5071         Reported by Dilyan Palauzov <Dilyan.Palauzov@aegee.org>.
5072
5073 2010-01-05  Jim Meyering  <meyering@redhat.com>
5074
5075         maint: remove useless inclusions of "xalloc.h"
5076         * lib/getloadavg.c: Remove useless inclusion of "xalloc.h".
5077         * lib/readtokens.c: Likewise.
5078         * lib/same.c: Likewise.
5079         * modules/getloadavg (Depends-on): Remove xalloc.
5080         * modules/readtokens: Likewise.
5081         * modules/same: Likewise.
5082
5083         maint.mk: include 4 more function names in alloca.h-checking regexp
5084         * top/maint.mk (sc_prohibit_xalloc_without_use): Use more complete
5085         regexp.  Before, we would give a false-positive (saying alloca.h
5086         is included unnecessarily) when the only uses involved omitted symbols.
5087
5088         xalloc.h: use consistent formatting
5089         * lib/xalloc.h: Move declarations to start in the first column.
5090
5091 2010-01-05  Eric Blake  <ebb9@byu.net>
5092
5093         mkdir: avoid xalloc
5094         * lib/mkdir.c (includes): Drop unused header.
5095         Reported by John W. Eaton.
5096
5097 2010-01-04  Jim Meyering  <meyering@redhat.com>
5098
5099         nl_langinfo: avoid configure-time syntax error
5100         * m4/nl_langinfo.m4 (gl_FUNC_NL_LANGINFO): When we've already tested
5101         for nl_langinfo.h, AC_CHECK_FUNCS_ONCE([nl_langinfo]) expands to
5102         the empty string.  Don't let that provoke a shell syntax error.
5103
5104         regcomp, regexec, fnmatch: avoid array bounds read error
5105         * lib/regcomp.c (build_equiv_class): From glibc:
5106         Use only the low 24 bits of a findidx return value as an index
5107         into the weights array.  Patch by Ulrich Drepper:
5108         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commit;h=b7d1c5fa30
5109         * lib/regexec.c (check_node_accept_bytes): Likewise.
5110         * lib/fnmatch_loop.c (FCT): Likewise.
5111
5112         regcomp: skip collseq lookup when there are no rules
5113         * lib/regcomp.c (lookup_collation_sequence_value): From glibc:
5114         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a532a41df58
5115
5116         regcomp: recognize ill-formed { } expressions
5117         * lib/regcomp.c (parse_dup_op): From glibc:
5118         http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=a87cd2894cb
5119
5120         regcomp: fix typo in comment
5121         * lib/regcomp.c (duplicate_node_closure): Sync from glibc.
5122         s/satisfy/satisfies/.
5123
5124         regcomp: sync from glibc: remove dead store
5125         * lib/regcomp.c (duplicate_node_closure): Remove useless
5126         search_duplicated_node call and dead store.
5127
5128         regcomp: sync from glibc; always use nl_langinfo
5129         * lib/regcomp.c (init_dfa) [!LIBC]: Always use nl_langinfo (CODESET),
5130         now that gnulib provides it.  Recognize UTF8 as well as UTF-8.
5131         * modules/regex (Depends-on): Add nl_langinfo.
5132
5133 2010-01-04  Eric Blake  <ebb9@byu.net>
5134
5135         fdopendir: fix configure test
5136         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for existing file.
5137
5138 2010-01-01  Bruno Haible  <bruno@clisp.org>
5139
5140         wchar: Remove unused configure check.
5141         * m4/wchar.m4 (gl_WCHAR_H): Don't test whether <wchar.h> is standalone.
5142
5143 2010-01-01  Eric Blake  <ebb9@byu.net>
5144
5145         headers: make check of system header explicit
5146         * m4/netdb_h.m4 (gl_HEADER_NETDB): Don't exploit knowledge of
5147         gl_CHECK_NEXT_HEADER internals, but call AC_CHECK_HEADERS_ONCE
5148         ourselves.
5149         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
5150         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
5151         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
5152         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise, for gt_INTTYPES_PRI
5153         internals.
5154         * m4/wchar.m4 (gl_WCHAR_H): Skip followup test if header is
5155         missing.
5156         Suggested by Bruno Haible.
5157
5158 2010-01-01  Jim Meyering  <meyering@redhat.com>
5159
5160         ChangeLog: tweak to eliminate unnecessary copyright line
5161         * ChangeLog: Remove a copyright line that was mistakenly updated
5162         by today's update-copyright run.  Reported by Eric Blake.
5163
5164         test-update-copyright: don't let envvar setting cause test failure
5165         * tests/test-update-copyright.sh: Set UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
5166
5167 2010-01-01  Bruno Haible  <bruno@clisp.org>
5168
5169         localename: Avoid gcc warning.
5170         * lib/localename.c (gl_locale_name_thread_unsafe): Don't define this
5171         function if it is not used.
5172
5173 2010-01-01  Jim Meyering  <meyering@redhat.com>
5174
5175         update nearly all FSF copyright year lists to include 2010
5176         Use the same procedure as for 2009, outlined in
5177         http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/20081
5178
5179         version-etc: set COPYRIGHT_YEAR to 2010
5180         * lib/version-etc.c (COPYRIGHT_YEAR): Manually update the enum.
5181
5182 2009-12-31  Eric Blake  <ebb9@byu.net>
5183
5184         doc: correct availability of cygwin 1.5.x getopt
5185         * doc/posix-functions/optarg.texi (optarg): Cygwin supplies getopt
5186         variables.
5187         * doc/posix-functions/opterr.texi (opterr): Likewise.
5188         * doc/posix-functions/optind.texi (optind): Likewise.
5189         * doc/posix-functions/optopt.texi (optopt): Likewise.
5190         * doc/posix-functions/tzname.texi (tzname): Likewise.
5191
5192         openat: update maintainer
5193         * modules/openat (Maintainer): Add myself.
5194
5195         utimens: avoid shadowing warning
5196         * lib/utimens.c (fdutimens, lutimens): Consolidate separate stat
5197         buffers into one, to avoid shadowing, as well as avoiding a
5198         redundant stat.
5199         Reported by Jim Meyering.
5200
5201         test-dup2: avoid compiler warning
5202         * tests/test-dup2.c (is_inheritable): Only define if used.
5203
5204 2010-01-01  Bruno Haible  <bruno@clisp.org>
5205
5206         vasnprintf: Avoid passing an 'rpl_mbstate_t *' to the system's wcrtomb.
5207         * lib/vasnprintf.c (VASNPRINTF): If GNULIB_defined_mbstate_t is
5208         defined, use wctomb instead of wcrtomb.
5209
5210 2010-01-01  Bruno Haible  <bruno@clisp.org>
5211
5212         iconv: Reject native Solaris iconv.
5213         * m4/iconv.m4 (AM_ICONV_LINK): Recognize native Solaris iconv() bug.
5214         * doc/posix-functions/iconv.texi: Document native Solaris iconv() bug.
5215
5216 2009-12-31  Bruno Haible  <bruno@clisp.org>
5217
5218         * tests/test-signal.c (main): Remove test of 'SIG'.
5219
5220 2009-12-31  Bruno Haible  <bruno@clisp.org>
5221
5222         spawn: Fix incomplete fix.
5223         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
5224         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
5225         warnings for GNULIB_POSIXCHECK again.
5226         Reported by Eric Blake.
5227
5228 2009-12-31  Bruno Haible  <bruno@clisp.org>
5229
5230         Avoid namespace pollution on glibc systems.
5231         * lib/spawn.in.h: Don't include <sched.h>, <signal.h> on glibc systems.
5232         * lib/sys_times.in.h: Don't include <time.h> on glibc systems.
5233         * lib/wchar.in.h: Don't include <stddef.h>, <stdio.h>, <time.h> on
5234         glibc systems.
5235
5236 2009-12-31  Bruno Haible  <bruno@clisp.org>
5237
5238         * m4/wchar.m4 (gl_WCHAR_H): Remove gl_STDDEF_H invocation.
5239         (gl_REPLACE_WCHAR_H): Turn into a no-op.
5240         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Likewise.
5241         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H): Likewise.
5242         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H): Likewise.
5243         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H): Likewise.
5244         * m4/sys_ioctl_h.m4 (gl_REPLACE_SYS_IOCTL_H): Likewise.
5245
5246 2009-12-31  Bruno Haible  <bruno@clisp.org>
5247
5248         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Invoke
5249         gl_CHECK_NEXT_HEADERS before testing ac_cv_header_sys_select_h, not
5250         afterwards.
5251
5252 2009-12-31  Bruno Haible  <bruno@clisp.org>
5253
5254         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Don't set
5255         SYS_UTSNAME_H.
5256
5257 2009-12-31  Bruno Haible  <bruno@clisp.org>
5258
5259         spawn: Fix misapplied patch.
5260         * lib/spawn.in.h (posix_spawnattr_getflags, posix_spawnattr_setflags,
5261         posix_spawnattr_getpgroup, posix_spawnattr_setpgroup): Correct the link
5262         warnings for GNULIB_POSIXCHECK.
5263
5264 2009-12-31  Bruno Haible  <bruno@clisp.org>
5265
5266         times: Update after sys_times changed.
5267         * m4/times.m4: New file, extracted from modules/times. Set HAVE_TIMES.
5268         * modules/times (Files): Add it.
5269         (configure.ac): Invoke gl_FUNC_TIMES.
5270
5271 2009-12-31  Bruno Haible  <bruno@clisp.org>
5272
5273         Use AC_C_INLINE where necessary.
5274         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Require AC_C_INLINE.
5275         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
5276         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
5277         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
5278         * m4/mbfile.m4 (gl_MBFILE): Likewise.
5279         * m4/mbiter.m4 (gl_MBITER): Likewise.
5280         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
5281         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
5282         * m4/wait-process.m4 (gl_WAIT_PROCESS): Likewise.
5283         * modules/u64 (configure.ac): Likewise.
5284
5285 2009-12-31  Bruno Haible  <bruno@clisp.org>
5286
5287         Use AC_C_INLINE instead of module 'inline' where possible.
5288         * modules/inline (Description): Clarify purpose.
5289         * m4/count-one-bits.m4 (gl_COUNT_ONE_BITS): Require AC_C_INLINE.
5290         * modules/count-one-bits (Depends-on): Remove inline.
5291         * m4/openat.m4 (gl_PREREQ_OPENAT): Require AC_C_INLINE.
5292         * modules/openat (Depends-on): Remove inline.
5293         * modules/fdutimensat (Depends-on, configure.ac): Require AC_C_INLINE
5294         instead of depending on module 'inline'.
5295         * modules/filevercmp (Depends-on, configure.ac): Likewise.
5296         * modules/unicase/cased (Depends-on, configure.ac): Likewise.
5297         * modules/unicase/ignorable (Depends-on, configure.ac): Likewise.
5298         * modules/unictype/category-of (Depends-on, configure.ac): Likewise.
5299         * modules/unictype/category-test (Depends-on, configure.ac): Likewise.
5300         * modules/unictype/ctype-alnum (Depends-on, configure.ac): Likewise.
5301         * modules/unictype/ctype-alpha (Depends-on, configure.ac): Likewise.
5302         * modules/unictype/ctype-blank (Depends-on, configure.ac): Likewise.
5303         * modules/unictype/ctype-cntrl (Depends-on, configure.ac): Likewise.
5304         * modules/unictype/ctype-digit (Depends-on, configure.ac): Likewise.
5305         * modules/unictype/ctype-graph (Depends-on, configure.ac): Likewise.
5306         * modules/unictype/ctype-lower (Depends-on, configure.ac): Likewise.
5307         * modules/unictype/ctype-print (Depends-on, configure.ac): Likewise.
5308         * modules/unictype/ctype-punct (Depends-on, configure.ac): Likewise.
5309         * modules/unictype/ctype-space (Depends-on, configure.ac): Likewise.
5310         * modules/unictype/ctype-upper (Depends-on, configure.ac): Likewise.
5311         * modules/unictype/ctype-xdigit (Depends-on, configure.ac): Likewise.
5312         * modules/unictype/property-alphabetic (Depends-on, configure.ac):
5313         Likewise.
5314         * modules/unictype/property-ascii-hex-digit (Depends-on,
5315         configure.ac): Likewise.
5316         * modules/unictype/property-bidi-arabic-digit (Depends-on,
5317         configure.ac): Likewise.
5318         * modules/unictype/property-bidi-arabic-right-to-left (Depends-on,
5319         configure.ac): Likewise.
5320         * modules/unictype/property-bidi-block-separator (Depends-on,
5321         configure.ac): Likewise.
5322         * modules/unictype/property-bidi-boundary-neutral (Depends-on,
5323         configure.ac): Likewise.
5324         * modules/unictype/property-bidi-common-separator (Depends-on,
5325         configure.ac): Likewise.
5326         * modules/unictype/property-bidi-control (Depends-on, configure.ac):
5327         Likewise.
5328         * modules/unictype/property-bidi-embedding-or-override (Depends-on,
5329         configure.ac): Likewise.
5330         * modules/unictype/property-bidi-eur-num-separator (Depends-on,
5331         configure.ac): Likewise.
5332         * modules/unictype/property-bidi-eur-num-terminator (Depends-on,
5333         configure.ac): Likewise.
5334         * modules/unictype/property-bidi-european-digit (Depends-on,
5335         configure.ac): Likewise.
5336         * modules/unictype/property-bidi-hebrew-right-to-left (Depends-on,
5337         configure.ac): Likewise.
5338         * modules/unictype/property-bidi-left-to-right (Depends-on,
5339         configure.ac): Likewise.
5340         * modules/unictype/property-bidi-non-spacing-mark (Depends-on,
5341         configure.ac): Likewise.
5342         * modules/unictype/property-bidi-other-neutral (Depends-on,
5343         configure.ac): Likewise.
5344         * modules/unictype/property-bidi-pdf (Depends-on, configure.ac):
5345         Likewise.
5346         * modules/unictype/property-bidi-segment-separator (Depends-on,
5347         configure.ac): Likewise.
5348         * modules/unictype/property-bidi-whitespace (Depends-on,
5349         configure.ac): Likewise.
5350         * modules/unictype/property-combining (Depends-on, configure.ac):
5351         Likewise.
5352         * modules/unictype/property-composite (Depends-on, configure.ac):
5353         Likewise.
5354         * modules/unictype/property-currency-symbol (Depends-on,
5355         configure.ac): Likewise.
5356         * modules/unictype/property-dash (Depends-on, configure.ac): Likewise.
5357         * modules/unictype/property-decimal-digit (Depends-on, configure.ac):
5358         Likewise.
5359         * modules/unictype/property-default-ignorable-code-point (Depends-on,
5360         configure.ac): Likewise.
5361         * modules/unictype/property-deprecated (Depends-on, configure.ac):
5362         Likewise.
5363         * modules/unictype/property-diacritic (Depends-on, configure.ac):
5364         Likewise.
5365         * modules/unictype/property-extender (Depends-on, configure.ac):
5366         Likewise.
5367         * modules/unictype/property-format-control (Depends-on, configure.ac):
5368         Likewise.
5369         * modules/unictype/property-grapheme-base (Depends-on, configure.ac):
5370         Likewise.
5371         * modules/unictype/property-grapheme-extend (Depends-on, configure.ac):
5372         Likewise.
5373         * modules/unictype/property-grapheme-link (Depends-on, configure.ac):
5374         Likewise.
5375         * modules/unictype/property-hex-digit (Depends-on, configure.ac):
5376         Likewise.
5377         * modules/unictype/property-hyphen (Depends-on, configure.ac):
5378         Likewise.
5379         * modules/unictype/property-id-continue (Depends-on, configure.ac):
5380         Likewise.
5381         * modules/unictype/property-id-start (Depends-on, configure.ac):
5382         Likewise.
5383         * modules/unictype/property-ideographic (Depends-on, configure.ac):
5384         Likewise.
5385         * modules/unictype/property-ids-binary-operator (Depends-on,
5386         configure.ac): Likewise.
5387         * modules/unictype/property-ids-trinary-operator (Depends-on,
5388         configure.ac): Likewise.
5389         * modules/unictype/property-ignorable-control (Depends-on,
5390         configure.ac): Likewise.
5391         * modules/unictype/property-iso-control (Depends-on, configure.ac):
5392         Likewise.
5393         * modules/unictype/property-join-control (Depends-on, configure.ac):
5394         Likewise.
5395         * modules/unictype/property-left-of-pair (Depends-on, configure.ac):
5396         Likewise.
5397         * modules/unictype/property-line-separator (Depends-on, configure.ac):
5398         Likewise.
5399         * modules/unictype/property-logical-order-exception (Depends-on,
5400         configure.ac): Likewise.
5401         * modules/unictype/property-lowercase (Depends-on, configure.ac):
5402         Likewise.
5403         * modules/unictype/property-math (Depends-on, configure.ac): Likewise.
5404         * modules/unictype/property-non-break (Depends-on, configure.ac):
5405         Likewise.
5406         * modules/unictype/property-not-a-character (Depends-on, configure.ac):
5407         Likewise.
5408         * modules/unictype/property-numeric (Depends-on, configure.ac):
5409         Likewise.
5410         * modules/unictype/property-other-alphabetic (Depends-on,
5411         configure.ac): Likewise.
5412         * modules/unictype/property-other-default-ignorable-code-point
5413         (Depends-on, configure.ac): Likewise.
5414         * modules/unictype/property-other-grapheme-extend (Depends-on,
5415         configure.ac): Likewise.
5416         * modules/unictype/property-other-id-continue (Depends-on,
5417         configure.ac): Likewise.
5418         * modules/unictype/property-other-id-start (Depends-on, configure.ac):
5419         Likewise.
5420         * modules/unictype/property-other-lowercase (Depends-on, configure.ac):
5421         Likewise.
5422         * modules/unictype/property-other-math (Depends-on, configure.ac):
5423         Likewise.
5424         * modules/unictype/property-other-uppercase (Depends-on, configure.ac):
5425         Likewise.
5426         * modules/unictype/property-paired-punctuation (Depends-on,
5427         configure.ac): Likewise.
5428         * modules/unictype/property-paragraph-separator (Depends-on,
5429         configure.ac): Likewise.
5430         * modules/unictype/property-pattern-syntax (Depends-on, configure.ac):
5431         Likewise.
5432         * modules/unictype/property-pattern-white-space (Depends-on,
5433         configure.ac): Likewise.
5434         * modules/unictype/property-private-use (Depends-on, configure.ac):
5435         Likewise.
5436         * modules/unictype/property-punctuation (Depends-on, configure.ac):
5437         Likewise.
5438         * modules/unictype/property-quotation-mark (Depends-on, configure.ac):
5439         Likewise.
5440         * modules/unictype/property-radical (Depends-on, configure.ac):
5441         Likewise.
5442         * modules/unictype/property-sentence-terminal (Depends-on,
5443         configure.ac): Likewise.
5444         * modules/unictype/property-soft-dotted (Depends-on, configure.ac):
5445         Likewise.
5446         * modules/unictype/property-space (Depends-on, configure.ac): Likewise.
5447         * modules/unictype/property-terminal-punctuation (Depends-on,
5448         configure.ac): Likewise.
5449         * modules/unictype/property-titlecase (Depends-on, configure.ac):
5450         Likewise.
5451         * modules/unictype/property-unassigned-code-value (Depends-on,
5452         configure.ac): Likewise.
5453         * modules/unictype/property-unified-ideograph (Depends-on,
5454         configure.ac): Likewise.
5455         * modules/unictype/property-uppercase (Depends-on, configure.ac):
5456         Likewise.
5457         * modules/unictype/property-variation-selector (Depends-on,
5458         configure.ac): Likewise.
5459         * modules/unictype/property-white-space (Depends-on, configure.ac):
5460         Likewise.
5461         * modules/unictype/property-xid-continue (Depends-on, configure.ac):
5462         Likewise.
5463         * modules/unictype/property-xid-start (Depends-on, configure.ac):
5464         Likewise.
5465         * modules/unictype/property-zero-width (Depends-on, configure.ac):
5466         Likewise.
5467         * modules/unictype/syntax-c-ident (Depends-on, configure.ac): Likewise.
5468         * modules/unictype/syntax-java-ident (Depends-on, configure.ac):
5469         Likewise.
5470
5471 2009-12-31  Bruno Haible  <bruno@clisp.org>
5472
5473         Remove unnecessary AC_C_INLINE invocation.
5474         * m4/popen.m4 (gl_PREREQ_POPEN): Don't invoke AC_C_INLINE. Not needed
5475         since 2009-08-21.
5476
5477 2009-12-31  Jim Meyering  <meyering@redhat.com>
5478
5479         maint.mk: don't require explicit gpg_key_ID in cfg.mk
5480         * top/maint.mk (gpg_key_ID): Derive key ID from signed release tag.
5481         With this change, we can all remove the gpg_key_ID = ... definition
5482         from our respective cfg.mk files.
5483
5484         maint.mk: create announcement template in ~/, not in /tmp
5485         * top/maint.mk (emit_upload_commands): Adjust.
5486         (release-prep): Emit into ~/announce-..., not /tmp/announce-...
5487         Remove temporary file, .ci-msg.
5488
5489 2009-12-31  Eric Blake  <ebb9@byu.net>
5490
5491         link-warning: always build headers with link warnings
5492         * modules/arpa_inet (Makefile.am): Always build replacement
5493         header.
5494         * modules/ctype (Makefile.am): Likewise.
5495         * modules/dirent (Makefile.am): Likewise.
5496         * modules/inttypes (Makefile.am): Likewise.
5497         * modules/langinfo (Makefile.am): Likewise.
5498         * modules/locale (Makefile.am): Likewise.
5499         * modules/spawn (Makefile.am): Likewise.
5500         * modules/sys_file (Makefile.am): Likewise.
5501         * modules/sys_ioctl (Makefile.am): Likewise.
5502         * modules/sys_select (Makefile.am): Likewise.
5503         * modules/sys_socket (Makefile.am): Likewise.
5504         * modules/sys_times (Makefile.am): Likewise.
5505         * modules/sys_utsname (Makefile.am): Likewise.
5506         * modules/sys_wait (Makefile.am): Likewise.
5507         * modules/wchar (Makefile.am): Likewise.
5508         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET)
5509         (gl_ARPA_INET_H_DEFAULTS): Drop unneeded variable.
5510         * m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
5511         * m4/isblank.m4 (gl_FUNC_ISBLANK): Likewise.
5512         * m4/dirent_h.m4 (gl_REPLACE_DIRENT_H, gl_DIRENT_H_DEFAULTS):
5513         Likewise.
5514         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
5515         * m4/langinfo_h.m4 (gl_LANGINFO_H): Likewise.
5516         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_H_DEFAULTS):
5517         Likewise.
5518         * m4/spawn_h.m4 (gl_REPLACE_SPAWN_H, gl_SPAWN_H_DEFAULTS):
5519         Likewise.
5520         * m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H): Likewise.
5521         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H, gl_REPLACE_SYS_IOCTL_H)
5522         (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
5523         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
5524         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Likewise.
5525         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
5526         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
5527         * m4/wchar.m4 (gl_WCHAR_H, gl_REPLACE_WCHAR_H)
5528         (gl_WCHAR_H_DEFAULTS): Likewise.
5529
5530 2009-12-31  Eric Blake  <ebb9@byu.net>
5531
5532         signal, spawn: use link warnings
5533         * lib/signal.in.h (sigset_t): Make unconditional.
5534         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset)
5535         (sigpending, sigprocmask, sigaction): Add link warnings.
5536         * lib/spawn.in.h (posix_spawn, posix_spawnp, posix_spawnattr_init)
5537         (posix_spawnattr_destroy, posix_spawnattr_getsigdefault)
5538         (posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask)
5539         (posix_spawnattr_setsigmask, posix_spawnattr_getflags)
5540         (posix_spawnattr_setflags, posix_spawnattr_getpgroup)
5541         (posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy)
5542         (posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam)
5543         (posix_spawnattr_setschedparam, posix_spawn_file_actions_init)
5544         (posix_spawn_file_actions_destroy)
5545         (posix_spawn_file_actions_addopen)
5546         (posix_spawn_file_actions_addclose)
5547         (posix_spawn_file_actions_adddup2): Likewise.
5548         * m4/signal_h.m4 (gl_SIGNAL_H): Guarantee uid_t.
5549         * tests/test-signal.c (main): Enhance test.
5550
5551         spawn: improve wrapper support
5552         * m4/spawn_h.m4 (gl_SPAWN_H): Check for type existence.
5553         (gl_SPAWN_H_DEFAULTS): New defaults.
5554         * modules/spawn (Makefile.am): Substitute them.
5555         * lib/spawn.in.h: (posix_spawnattr_t, posix_spawn_file_actions_t):
5556         Only declare if missing or broken.
5557
5558         sys_times, sys_utsname: use include_next
5559         * m4/sys_times_h.m4 (gl_SYS_TIMES_H): Support wrapping an existing
5560         header.
5561         (gl_SYS_TIMES_H_DEFAULTS): Add another variable.
5562         * m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H)
5563         (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
5564         * modules/sys_times (Depends-on): Add include_next.
5565         (Makefile.am): Substitute additional values.
5566         * modules/sys_utsname (Depends-on, Makefile.am): Likewise.
5567         * lib/sys_times.in.h (includes): Include native header, if
5568         available.
5569         * lib/sys_utsname.in.h (includes): Likewise.
5570         * tests/test-sys_times.c (main): Enhance test.
5571
5572         fdutimensat: revert prior patch
5573         * modules/fdutimensat (Depends-on): Re-add inline; it is needed by
5574         utimens.h.
5575         Reported by Bruno Haible.
5576
5577 2009-12-30  Eric Blake  <ebb9@byu.net>
5578
5579         sys_wait: drop link-warning dependency
5580         * modules/sys_wait (Depends-on, Makefile.am): Drop unneeded
5581         link-warning efforts.
5582         * lib/sys_wait.in.h: Likewise.
5583
5584         fdutimensat: remove bogus dependency
5585         * modules/fdutimensat (Depends-on): Drop inline.
5586
5587         unistd: fix typo
5588         * lib/unistd.in.h (linkat) [GNULIB_POSIXCHECK]: Fix typo.
5589
5590 2009-12-30  Bruno Haible  <bruno@clisp.org>
5591
5592         Fix compilation error with Solaris cc.
5593         * lib/unicase/u8-is-invariant.c: Include <stdbool.h>.
5594         * lib/unicase/u16-is-invariant.c: Likewise.
5595         * lib/unicase/u32-is-invariant.c: Likewise.
5596         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
5597
5598 2009-12-30  Bruno Haible  <bruno@clisp.org>
5599
5600         Fix test crash.
5601         * tests/test-localename.c (test_locale_name_thread): Skip unavailable
5602         locales.
5603         Reported by Simon Josefsson <simon@josefsson.org>.
5604
5605 2009-12-30  Bruno Haible  <bruno@clisp.org>
5606
5607         Fix compilation error on most platforms.
5608         * tests/test-localename.c (categories): Define only if HAVE_NEWLOCALE.
5609         Reported by Simon Josefsson <simon@josefsson.org>
5610         and Nelson H. F. Beebe <beebe@math.utah.edu>.
5611
5612 2009-12-30  Eric Blake  <ebb9@byu.net>
5613
5614         futimens, utimensat: work around ntfs-3g bug
5615         * lib/utimensat.c (rpl_utimensat): Drop attempts to cache whether
5616         a ctime bug is present, and expand workaround to cover ntfs-3g.
5617         * lib/utimens.c (fdutimens, lutimens): Likewise.
5618         (utimensat_ctime_really, detect_ctime_bug): Drop cache mechanism.
5619         (validate_timespec): Adjust return value.
5620         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Update comment.
5621         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
5622         Reported by ctrn3e8 <ctrn3e8@gmail.com>.
5623
5624 2009-12-29  Eric Blake  <ebb9@byu.net>
5625
5626         link-warning: make usage consistent
5627         * modules/ctype (Depends-on): Add link-warning.
5628         (Makefile.am): Update rules accordingly.
5629         * modules/langinfo (Depends-on, Makefile.am): Likewise.
5630         * modules/locale (Depends-on, Makefile.am): Likewise.
5631         * modules/sys_file (Makefile.am): Likewise.
5632         * modules/getopt-posix (Makefile.am): Delete unused link warning
5633         efforts.
5634         * lib/ctype.in.h (GL_LINK_WARNING): Ensure definition before use.
5635         * lib/langinfo.in.h (GL_LINK_WARNING): Likewise.
5636         * lib/locale.in.h (GL_LINK_WARNING): Likewise.
5637         * lib/sys_file.in.h (GL_LINK_WARNING): Likewise.
5638
5639         stdio: remove unused variables
5640         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Remove unused variables.
5641         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Likewise.
5642         * m4/ftello.m4 (gl_FUNC_FTELLO): Likewise.
5643
5644         tests: test more substitute headers
5645         * modules/ctype-tests: New file.
5646         * modules/dirent-tests: Likewise.
5647         * modules/spawn-tests: Likewise.
5648         * modules/sys_file-tests: Likewise.
5649         * modules/sys_ioctl-tests: Likewise.
5650         * modules/sys_wait-tests: Likewise.
5651         * tests/test-ctype.c: Likewise.
5652         * tests/test-dirent.c: Likewise.
5653         * tests/test-spawn.c: Likewise.
5654         * tests/test-sys_file.c: Likewise.
5655         * tests/test-sys_ioctl.c: Likewise.
5656         * tests/test-sys_wait.c: Likewise.
5657         * m4/spawn_h.m4 (gl_SPAWN_H): Replace header if it is missing.
5658         * lib/sys_file.in.h (LOCK_SH, LOCK_EX, LOCK_UN, LOCK_NB): Provide
5659         whether or not flock is in use.
5660
5661         tests: remove License section from module
5662         * modules/arpa_inet-tests: Remove unneeded section.
5663         * modules/byteswap-tests: Likewise.
5664         * modules/ceilf-tests: Likewise.
5665         * modules/ceill-tests: Likewise.
5666         * modules/crypto/des-tests: Likewise.
5667         * modules/crypto/gc-arcfour-tests: Likewise.
5668         * modules/crypto/gc-arctwo-tests: Likewise.
5669         * modules/crypto/gc-des-tests: Likewise.
5670         * modules/crypto/gc-hmac-md5-tests: Likewise.
5671         * modules/crypto/gc-hmac-sha1-tests: Likewise.
5672         * modules/crypto/gc-md2-tests: Likewise.
5673         * modules/crypto/gc-md4-tests: Likewise.
5674         * modules/crypto/gc-md5-tests: Likewise.
5675         * modules/crypto/gc-pbkdf2-sha1-tests: Likewise.
5676         * modules/crypto/gc-rijndael-tests: Likewise.
5677         * modules/crypto/gc-sha1-tests: Likewise.
5678         * modules/crypto/gc-tests: Likewise.
5679         * modules/crypto/md2-tests: Likewise.
5680         * modules/crypto/md4-tests: Likewise.
5681         * modules/fcntl-h-tests: Likewise.
5682         * modules/floorf-tests: Likewise.
5683         * modules/floorl-tests: Likewise.
5684         * modules/frexp-nolibm-tests: Likewise.
5685         * modules/frexp-tests: Likewise.
5686         * modules/frexpl-nolibm-tests: Likewise.
5687         * modules/frexpl-tests: Likewise.
5688         * modules/getaddrinfo-tests: Likewise.
5689         * modules/inttypes-tests: Likewise.
5690         * modules/isfinite-tests: Likewise.
5691         * modules/isinf-tests: Likewise.
5692         * modules/ldexpl-tests: Likewise.
5693         * modules/locale-tests: Likewise.
5694         * modules/math-tests: Likewise.
5695         * modules/netdb-tests: Likewise.
5696         * modules/netinet_in-tests: Likewise.
5697         * modules/printf-frexp-tests: Likewise.
5698         * modules/printf-frexpl-tests: Likewise.
5699         * modules/priv-set-tests: Likewise.
5700         * modules/random_r-tests: Likewise.
5701         * modules/round-tests: Likewise.
5702         * modules/roundf-tests: Likewise.
5703         * modules/roundl-tests: Likewise.
5704         * modules/search-tests: Likewise.
5705         * modules/select-tests: Likewise.
5706         * modules/signal-tests: Likewise.
5707         * modules/stdbool-tests: Likewise.
5708         * modules/stddef-tests: Likewise.
5709         * modules/stdint-tests: Likewise.
5710         * modules/stdio-tests: Likewise.
5711         * modules/stdlib-tests: Likewise.
5712         * modules/string-tests: Likewise.
5713         * modules/strings-tests: Likewise.
5714         * modules/sys_select-tests: Likewise.
5715         * modules/sys_socket-tests: Likewise.
5716         * modules/sys_stat-tests: Likewise.
5717         * modules/sys_time-tests: Likewise.
5718         * modules/sys_utsname-tests: Likewise.
5719         * modules/sysexits-tests: Likewise.
5720         * modules/time-tests: Likewise.
5721         * modules/trunc-tests: Likewise.
5722         * modules/truncf-tests: Likewise.
5723         * modules/truncl-tests: Likewise.
5724         * modules/tsearch-tests: Likewise.
5725         * modules/unistd-tests: Likewise.
5726         * modules/wchar-tests: Likewise.
5727         * modules/wctype-tests: Likewise.
5728
5729         tests: fix license on several tests
5730         * tests/test-des.c: Update to GPLv3+.
5731         * tests/test-flock.c: Likewise.
5732         * tests/test-fsync.c: Likewise.
5733         * tests/test-futimens.h: Likewise.
5734         * tests/test-gc-arcfour.c: Likewise.
5735         * tests/test-gc-arctwo.c: Likewise.
5736         * tests/test-gc-des.c: Likewise.
5737         * tests/test-gc-hmac-md5.c: Likewise.
5738         * tests/test-gc-hmac-sha1.c: Likewise.
5739         * tests/test-gc-md2.c: Likewise.
5740         * tests/test-gc-md4.c: Likewise.
5741         * tests/test-gc-md5.c: Likewise.
5742         * tests/test-gc-pbkdf2-sha1.c: Likewise.
5743         * tests/test-gc-rijndael.c: Likewise.
5744         * tests/test-gc-sha1.c: Likewise.
5745         * tests/test-gc.c: Likewise.
5746         * tests/test-getcwd.c: Likewise.
5747         * tests/test-link.c: Likewise.
5748         * tests/test-link.h: Likewise.
5749         * tests/test-lutimens.h: Likewise.
5750         * tests/test-md2.c: Likewise.
5751         * tests/test-md4.c: Likewise.
5752         * tests/test-mkdir.h: Likewise.
5753         * tests/test-rename.c: Likewise.
5754         * tests/test-rename.h: Likewise.
5755         * tests/test-safe-alloc.c: Likewise.
5756         * tests/test-utimens-common.h: Likewise.
5757         * tests/test-utimens.h: Likewise.
5758
5759         maint: sync license texts
5760         * config/srclist.txt: Add gpl-1.3.texi, lgpl-1.3.texi.
5761         * doc/gpl-3.0.texi: Revert copyright year update.
5762         * doc/lgpl-3.0.texi: Likewise.
5763
5764 2009-12-29  Jim Meyering  <meyering@redhat.com>
5765
5766         update nearly all FSF copyright year lists to include 2009
5767         The files named by the following are exempted:
5768             grep -v '^#' config/srclist.txt|grep -v '^$' | while read src dst; do
5769               test -f "$dst" && { echo "$dst"; continue; }
5770               test -d "$dst" || continue
5771               echo "$dst"/$(basename "$src")
5772             done > exempt
5773             git ls-files tests/unictype >> exempt
5774         In the remaining files, convert to all-interval notation if
5775         - there is already at least one year interval like 2000-2003
5776         - the file is maintained by me
5777         - the file is in lib/uni*/, where that style already prevails
5778         Otherwise, use update-copyright's default.
5779
5780 2009-12-29  Simon Josefsson  <simon@josefsson.org>
5781         and Eric Blake  <ebb9@byu.net>
5782
5783         tests: don't require debug system() to pass
5784         * tests/test-lstat.h (test_lstat_func): Move debug cleanup...
5785         * tests/test-rmdir.h (test_rmdir_func): Likewise.
5786         * tests/test-unlink.h (test_unlink_func): Likewise.
5787         * tests/test-fstatat.c (main): ...into callers.
5788         * tests/test-lstat.c (main): Likewise.
5789         * tests/test-rmdir.c (main): Likewise.
5790         * tests/test-unlink.c (main): Likewise.
5791         * tests/test-unlinkat.c (main): Likewise.
5792         * tests/test-areadlink-with-size.c (main): Don't require a
5793         debug-only system call to pass, aiding cross-testing to mingw.
5794         * tests/test-areadlink.c (main): Likewise.
5795         * tests/test-areadlinkat-with-size.c (main): Likewise.
5796         * tests/test-areadlinkat.c (main): Likewise.
5797         * tests/test-canonicalize-lgpl.c (main): Likewise.
5798         * tests/test-canonicalize.c (main): Likewise.
5799         * tests/test-chown.c (main): Likewise.
5800         * tests/test-fchownat.c (main): Likewise.
5801         * tests/test-lchown.c (main): Likewise.
5802         * tests/test-fdutimensat.c (main): Likewise.
5803         * tests/test-futimens.c (main): Likewise.
5804         * tests/test-link.c (main): Likewise.
5805         * tests/test-linkat.c (main): Likewise.
5806         * tests/test-mkdir.c (main): Likewise.
5807         * tests/test-mkdirat.c (main): Likewise.
5808         * tests/test-mkfifo.c (main): Likewise.
5809         * tests/test-mkfifoat.c (main): Likewise.
5810         * tests/test-mknod.c (main): Likewise.
5811         * tests/test-readlink.c (main): Likewise.
5812         * tests/test-remove.c (main): Likewise.
5813         * tests/test-rename.c (main): Likewise.
5814         * tests/test-renameat.c (main): Likewise.
5815         * tests/test-symlink.c (main): Likewise.
5816         * tests/test-symlinkat.c (main): Likewise.
5817         * tests/test-utimens.c (main): Likewise.
5818         * tests/test-utimensat.c (main): Likewise.
5819
5820 2009-12-29  Simon Josefsson  <simon@josefsson.org>
5821
5822         * modules/selinux-h (selinux/selinux.h, selinux/context.h): Depend
5823         on $(UNUSED_PARAMETER_H) to avoid build failure.
5824
5825 2009-12-28  Jim Meyering  <meyering@redhat.com>
5826
5827         update-copyright: you may specify a max. line length other than 72
5828         * build-aux/update-copyright: Honor $UPDATE_COPYRIGHT_MAX_LINE_LENGTH.
5829
5830         maint: use consistent FSF copyright line syntax
5831         * lib/posixtm.c: Add missing comma in FSF copyright line.
5832         * lib/posixtm.h: Likewise.
5833         * lib/getugroups.c: Add missing ", Inc.".
5834
5835         pmccabe2html: emit consistent FSF copyright; remove trailing blanks
5836         * build-aux/pmccabe2html: Insert comma before "Inc." in emitted
5837         FSF copyright line.  Remove trailing blanks.
5838
5839 2009-12-28  Eric Blake  <ebb9@byu.net>
5840
5841         test-dup2: reduce dependencies
5842         * modules/cloexec (Configure.ac): Set witness.
5843         * modules/dup2-tests (Depends-on): Drop cloexec.
5844         * tests/test-dup2.c (main): Skip portion of test if cloexec module
5845         not present.
5846         Suggested by Bruno Haible.
5847
5848 2009-12-26  Bruno Haible  <bruno@clisp.org>
5849
5850         Remove an unneeded dependency.
5851         * modules/fseterr (Depends-on): Remove dup2.
5852
5853 2009-12-26  Eric Blake  <ebb9@byu.net>
5854
5855         tests: use macros.h in more places
5856         * tests/macros.h (ASSERT): Depend on ASSERT_STREAM.
5857         (ASSERT_STREAM): Provide default of stderr.
5858         * tests/test-dirent-safer.c: Include macros.h, using alternate
5859         stream for assertions.
5860         * tests/test-dup-safer.c: Likewise.
5861         * tests/test-freopen-safer.c: Likewise.
5862         * tests/test-getopt.c: Likewise.
5863         * tests/test-openat-safer.c: Likewise.
5864         * tests/test-pipe.c: Likewise.
5865         * tests/test-popen-safer.c: Likewise.
5866         * modules/dirent-safer-tests (Files): Include macros.h.
5867         * modules/unistd-safer-tests (Files): Likewise.
5868         * modules/freopen-safer-tests (Files): Likewise.
5869         * modules/getopt-posix-tests (Files): Likewise.
5870         * modules/openat-safer-tests (Files): Likewise.
5871         * modules/pipe-tests (Files): Likewise.
5872
5873 2009-12-26  Bruno Haible  <bruno@clisp.org>
5874
5875         javacomp: Portability fix.
5876         * m4/javacomp.m4 (gt_JAVACOMP): Fix creation of conftestver.class so
5877         that it also works on Solaris.
5878
5879 2009-12-26  Bruno Haible  <bruno@clisp.org>
5880
5881         localename: Fix storage allocation of gl_locale_name_thread's result.
5882         * lib/localename.c (SIZE_BITS, string_hash, struct hash_node,
5883         HASH_TABLE_SIZE, struniq_hash_table, struniq_lock, struniq): Define on
5884         all platforms that have 'uselocale'.
5885         (gl_locale_name_thread_unsafe): New function, extracted from
5886         gl_locale_name_thread.
5887         (gl_locale_name_thread): Call struniq on all platforms that have
5888         'uselocale'.
5889         * tests/test-localename.c (test_locale_name_thread): Check that the
5890         resulting strings are permanently allocated.
5891         * modules/localename-tests (Depends-on): Add strdup.
5892
5893 2009-12-26  Bruno Haible  <bruno@clisp.org>
5894
5895         * tests/test-localename.c (categories): Fill in the strings.
5896
5897 2009-12-26  Jim Meyering  <meyering@redhat.com>
5898
5899         isdir: complete the removal of m4/isdir.m4
5900         * modules/isdir (configure.ac): Remove reference to gl_ISDIR.
5901
5902         isdir: clean up, since at least grep still uses it
5903         * lib/isdir.c: Include "isdir.h".
5904         (S_ISDIR): Remove now-unneeded definition.
5905         * modules/isdir (Files): Add lib/isdir.h.
5906         * lib/isdir.h: New file, with declaration.
5907         * m4/isdir.m4: Remove file -- unneeded.
5908
5909 2009-12-25  Bruno Haible  <bruno@clisp.org>
5910
5911         selinux-h: Make generated .h files standalone.
5912         * lib/se-context.in.h: Arrange to include _GL_UNUSED_PARAMETER
5913         definition. Use _GL_UNUSED_PARAMETER instead of _GL_UNUSED.
5914         * lib/se-selinux.in.h: Likewise.
5915         * modules/selinux-h (Depends-on): Add unused-parameter.
5916         (Makefile.am): Insert definition of _GL_UNUSED_PARAMETER into
5917         selinux/selinux.h and selinux/context.h.
5918         Suggested by Eric Blake.
5919
5920 2009-12-25  Bruno Haible  <bruno@clisp.org>
5921
5922         Move gl_FCNTL_O_FLAGS to a separate .m4 file.
5923         * m4/fcntl-o.m4: New file, extracted from m4/fcntl_h.m4.
5924         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): Remove macro.
5925         * modules/fcntl-h (Files): Add m4/fcntl-o.m4.
5926         * modules/localcharset (Files): Likewise. Remove m4/fcntl_h.m4.
5927
5928 2009-12-24  Bruno Haible  <bruno@clisp.org>
5929
5930         openat: Fix warning.
5931         * lib/openat-proc.c: Include <unistd.h>.
5932
5933 2009-12-24  Bruno Haible  <bruno@clisp.org>
5934
5935         New module 'unused-parameter'.
5936         * build-aux/unused-parameter.h: New file, extracted from earlier
5937         gnulib-common.m4.
5938         * modules/unused-parameter: New file.
5939         * lib/unistr.h: Include unused-parameter.h.
5940         (u32_mbtouc_unsafe, u32_mbtouc): Use _GL_UNUSED_PARAMETER instead of
5941         _GL_UNUSED.
5942         * modules/unistr/base (Depends-on): Add unused-parameter.
5943
5944 2009-12-24  Bruno Haible  <bruno@clisp.org>
5945
5946         Add missing dependencies to 'extensions' module.
5947         * m4/extensions.m4: Add comment.
5948         * modules/accept4 (Depends-on): Add extensions.
5949         * modules/dup3 (Depends-on): Likewise.
5950         * modules/fcntl (Depends-on): Likewise.
5951         * modules/futimens (Depends-on): Likewise.
5952         * modules/mknod (Depends-on): Likewise.
5953         * modules/pipe2 (Depends-on): Likewise.
5954         * modules/stat-time (Depends-on): Likewise.
5955         * modules/strcasestr-simple (Depends-on): Likewise.
5956         * modules/strsignal (Depends-on): Likewise.
5957         * modules/utimensat (Depends-on): Likewise.
5958         * modules/localcharset (Depends-on): Likewise. Needed because of
5959         gl_FCNTL_O_FLAGS.
5960         * modules/wcrtomb (Depends-on): Likewise. Needed because of
5961         AC_TYPE_MBSTATE_T.
5962         * modules/wcsnrtombs (Depends-on): Likewise.
5963         * modules/wcsrtombs (Depends-on): Likewise.
5964
5965 2009-12-24  Bruno Haible  <bruno@clisp.org>
5966
5967         binary-io: Avoid gcc warning due to SET_BINARY.
5968         * lib/binary-io.h (SET_BINARY): Cast the result to void.
5969         Reported by Jim Meyering <jim@meyering.net>. Suggestion by Eric Blake.
5970
5971 2009-12-24  Bruno Haible  <bruno@clisp.org>
5972
5973         Avoid future namespace pollution on glibc systems.
5974         * lib/arpa_inet.in.h: Don't include <sys/socket.h> on glibc systems.
5975         * lib/sys_ioctl.in.h: Don't include <unistd.h> on glibc systems.
5976         * lib/sys_select.in.h: Don't include <sys/time.h> and <string.h> on
5977         glibc systems.
5978
5979 2009-12-24  Bruno Haible  <bruno@clisp.org>
5980
5981         Refactor common macros used in tests.
5982         * tests/macros.h: New file.
5983         * tests/test-areadlink.c: Include macros.h. Don't include <stdio.h>
5984         and/or <stdlib.h>, if appropriate.
5985         (ASSERT, SIZEOF): Remove macros.
5986         * tests/test-areadlink-with-size.c: Likewise.
5987         * tests/test-areadlinkat.c: Likewise.
5988         * tests/test-areadlinkat-with-size.c: Likewise.
5989         * tests/test-argmatch.c: Likewise.
5990         * tests/test-argv-iter.c: Likewise.
5991         * tests/test-array-mergesort.c: Likewise.
5992         * tests/test-array_list.c: Likewise.
5993         * tests/test-array_oset.c: Likewise.
5994         * tests/test-avltree_list.c: Likewise.
5995         * tests/test-avltree_oset.c: Likewise.
5996         * tests/test-avltreehash_list.c: Likewise.
5997         * tests/test-base64.c: Likewise.
5998         * tests/test-binary-io.c: Likewise.
5999         * tests/test-bitrotate.c: Likewise.
6000         * tests/test-btowc.c: Likewise.
6001         * tests/test-byteswap.c: Likewise.
6002         * tests/test-c-ctype.c: Likewise.
6003         * tests/test-c-stack.c: Likewise.
6004         * tests/test-c-strcasecmp.c: Likewise.
6005         * tests/test-c-strcasestr.c: Likewise.
6006         * tests/test-c-strncasecmp.c: Likewise.
6007         * tests/test-c-strstr.c: Likewise.
6008         * tests/test-canonicalize-lgpl.c: Likewise.
6009         * tests/test-canonicalize.c: Likewise.
6010         * tests/test-carray_list.c: Likewise.
6011         * tests/test-ceilf1.c: Likewise.
6012         * tests/test-ceilf2.c: Likewise.
6013         * tests/test-ceill.c: Likewise.
6014         * tests/test-chown.c: Likewise.
6015         * tests/test-cloexec.c: Likewise.
6016         * tests/test-copy-acl.c: Likewise.
6017         * tests/test-copy-file.c: Likewise.
6018         * tests/test-count-one-bits.c: Likewise.
6019         * tests/test-dprintf-posix.c: Likewise.
6020         * tests/test-dup2.c: Likewise.
6021         * tests/test-dup3.c: Likewise.
6022         * tests/test-duplocale.c: Likewise.
6023         * tests/test-fbufmode.c: Likewise.
6024         * tests/test-fchdir.c: Likewise.
6025         * tests/test-fchownat.c: Likewise.
6026         * tests/test-fcntl-safer.c: Likewise.
6027         * tests/test-fcntl.c: Likewise.
6028         * tests/test-fdopendir.c: Likewise.
6029         * tests/test-fdutimensat.c: Likewise.
6030         * tests/test-fflush2.c: Likewise.
6031         * tests/test-file-has-acl.c: Likewise.
6032         * tests/test-filevercmp.c: Likewise.
6033         * tests/test-flock.c: Likewise.
6034         * tests/test-floorf1.c: Likewise.
6035         * tests/test-floorf2.c: Likewise.
6036         * tests/test-floorl.c: Likewise.
6037         * tests/test-fnmatch.c: Likewise.
6038         * tests/test-fopen.h: Likewise.
6039         * tests/test-fpending.c: Likewise.
6040         * tests/test-fprintf-posix.c: Likewise.
6041         * tests/test-fpurge.c: Likewise.
6042         * tests/test-freadable.c: Likewise.
6043         * tests/test-freadahead.c: Likewise.
6044         * tests/test-freading.c: Likewise.
6045         * tests/test-freadptr.c: Likewise.
6046         * tests/test-freadptr2.c: Likewise.
6047         * tests/test-freadseek.c: Likewise.
6048         * tests/test-freopen.c: Likewise.
6049         * tests/test-frexp.c: Likewise.
6050         * tests/test-frexpl.c: Likewise.
6051         * tests/test-fseek.c: Likewise.
6052         * tests/test-fseeko.c: Likewise.
6053         * tests/test-fstatat.c: Likewise.
6054         * tests/test-fstrcmp.c: Likewise.
6055         * tests/test-fsync.c: Likewise.
6056         * tests/test-ftell.c: Likewise.
6057         * tests/test-ftello.c: Likewise.
6058         * tests/test-func.c: Likewise.
6059         * tests/test-futimens.c: Likewise.
6060         * tests/test-fwritable.c: Likewise.
6061         * tests/test-fwriting.c: Likewise.
6062         * tests/test-getcwd.c: Likewise.
6063         * tests/test-getdate.c: Likewise.
6064         * tests/test-getdelim.c: Likewise.
6065         * tests/test-getdtablesize.c: Likewise.
6066         * tests/test-getgroups.c: Likewise.
6067         * tests/test-getline.c: Likewise.
6068         * tests/test-getndelim2.c: Likewise.
6069         * tests/test-glob.c: Likewise.
6070         * tests/test-hash.c: Likewise.
6071         * tests/test-i-ring.c: Likewise.
6072         * tests/test-iconv-utf.c: Likewise.
6073         * tests/test-iconv.c: Likewise.
6074         * tests/test-idpriv-drop.c: Likewise.
6075         * tests/test-idpriv-droptemp.c: Likewise.
6076         * tests/test-inet_ntop.c: Likewise.
6077         * tests/test-inet_pton.c: Likewise.
6078         * tests/test-isblank.c: Likewise.
6079         * tests/test-isfinite.c: Likewise.
6080         * tests/test-isinf.c: Likewise.
6081         * tests/test-isnan.c: Likewise.
6082         * tests/test-isnand.h: Likewise.
6083         * tests/test-isnanf.h: Likewise.
6084         * tests/test-isnanl.h: Likewise.
6085         * tests/test-lchown.c: Likewise.
6086         * tests/test-ldexpl.c: Likewise.
6087         * tests/test-link.c: Likewise.
6088         * tests/test-linkat.c: Likewise.
6089         * tests/test-linked_list.c: Likewise.
6090         * tests/test-linkedhash_list.c: Likewise.
6091         * tests/test-localename.c: Likewise.
6092         * tests/test-lseek.c: Likewise.
6093         * tests/test-lstat.c: Likewise.
6094         * tests/test-mbmemcasecmp.c: Likewise.
6095         * tests/test-mbmemcasecoll.c: Likewise.
6096         * tests/test-mbrtowc.c: Likewise.
6097         * tests/test-mbscasecmp.c: Likewise.
6098         * tests/test-mbscasestr1.c: Likewise.
6099         * tests/test-mbscasestr2.c: Likewise.
6100         * tests/test-mbscasestr3.c: Likewise.
6101         * tests/test-mbscasestr4.c: Likewise.
6102         * tests/test-mbschr.c: Likewise.
6103         * tests/test-mbscspn.c: Likewise.
6104         * tests/test-mbsinit.c: Likewise.
6105         * tests/test-mbsncasecmp.c: Likewise.
6106         * tests/test-mbsnrtowcs.c: Likewise.
6107         * tests/test-mbspbrk.c: Likewise.
6108         * tests/test-mbspcasecmp.c: Likewise.
6109         * tests/test-mbsrchr.c: Likewise.
6110         * tests/test-mbsrtowcs.c: Likewise.
6111         * tests/test-mbsspn.c: Likewise.
6112         * tests/test-mbsstr1.c: Likewise.
6113         * tests/test-mbsstr2.c: Likewise.
6114         * tests/test-mbsstr3.c: Likewise.
6115         * tests/test-memchr.c: Likewise.
6116         * tests/test-memchr2.c: Likewise.
6117         * tests/test-memcmp.c: Likewise.
6118         * tests/test-memmem.c: Likewise.
6119         * tests/test-memrchr.c: Likewise.
6120         * tests/test-mkdir.c: Likewise.
6121         * tests/test-mkdirat.c: Likewise.
6122         * tests/test-mkfifo.c: Likewise.
6123         * tests/test-mkfifoat.c: Likewise.
6124         * tests/test-mknod.c: Likewise.
6125         * tests/test-nanosleep.c: Likewise.
6126         * tests/test-nl_langinfo.c: Likewise.
6127         * tests/test-obstack-printf.c: Likewise.
6128         * tests/test-open.c: Likewise.
6129         * tests/test-openat.c: Likewise.
6130         * tests/test-pipe-filter-gi1.c: Likewise.
6131         * tests/test-pipe-filter-gi2-main.c: Likewise.
6132         * tests/test-pipe-filter-ii1.c: Likewise.
6133         * tests/test-pipe-filter-ii2-main.c: Likewise.
6134         * tests/test-pipe2.c: Likewise.
6135         * tests/test-popen.h: Likewise.
6136         * tests/test-posixtm.c: Likewise.
6137         * tests/test-pread.c: Likewise.
6138         * tests/test-printf-frexp.c: Likewise.
6139         * tests/test-printf-frexpl.c: Likewise.
6140         * tests/test-printf-posix.c: Likewise.
6141         * tests/test-priv-set.c: Likewise.
6142         * tests/test-quotearg.c: Likewise.
6143         * tests/test-random_r.c: Likewise.
6144         * tests/test-rawmemchr.c: Likewise.
6145         * tests/test-rbtree_list.c: Likewise.
6146         * tests/test-rbtree_oset.c: Likewise.
6147         * tests/test-rbtreehash_list.c: Likewise.
6148         * tests/test-readlink.c: Likewise.
6149         * tests/test-remove.c: Likewise.
6150         * tests/test-rename.c: Likewise.
6151         * tests/test-renameat.c: Likewise.
6152         * tests/test-rmdir.c: Likewise.
6153         * tests/test-round1.c: Likewise.
6154         * tests/test-roundf1.c: Likewise.
6155         * tests/test-roundl.c: Likewise.
6156         * tests/test-safe-alloc.c: Likewise.
6157         * tests/test-sameacls.c: Likewise.
6158         * tests/test-set-mode-acl.c: Likewise.
6159         * tests/test-setenv.c: Likewise.
6160         * tests/test-sigaction.c: Likewise.
6161         * tests/test-signbit.c: Likewise.
6162         * tests/test-sleep.c: Likewise.
6163         * tests/test-snprintf-posix.c: Likewise.
6164         * tests/test-snprintf.c: Likewise.
6165         * tests/test-sprintf-posix.c: Likewise.
6166         * tests/test-stat-time.c: Likewise.
6167         * tests/test-stat.c: Likewise.
6168         * tests/test-strcasestr.c: Likewise.
6169         * tests/test-strchrnul.c: Likewise.
6170         * tests/test-strerror.c: Likewise.
6171         * tests/test-striconv.c: Likewise.
6172         * tests/test-striconveh.c: Likewise.
6173         * tests/test-striconveha.c: Likewise.
6174         * tests/test-strsignal.c: Likewise.
6175         * tests/test-strstr.c: Likewise.
6176         * tests/test-strtod.c: Likewise.
6177         * tests/test-strverscmp.c: Likewise.
6178         * tests/test-symlink.c: Likewise.
6179         * tests/test-symlinkat.c: Likewise.
6180         * tests/test-trunc1.c: Likewise.
6181         * tests/test-trunc2.c: Likewise.
6182         * tests/test-truncf1.c: Likewise.
6183         * tests/test-truncf2.c: Likewise.
6184         * tests/test-truncl.c: Likewise.
6185         * tests/test-uname.c: Likewise.
6186         * tests/test-unlink.c: Likewise.
6187         * tests/test-unlinkat.c: Likewise.
6188         * tests/test-unsetenv.c: Likewise.
6189         * tests/test-usleep.c: Likewise.
6190         * tests/test-utimens.c: Likewise.
6191         * tests/test-utimensat.c: Likewise.
6192         * tests/test-vasnprintf-posix.c: Likewise.
6193         * tests/test-vasnprintf-posix2.c: Likewise.
6194         * tests/test-vasnprintf.c: Likewise.
6195         * tests/test-vasprintf-posix.c: Likewise.
6196         * tests/test-vasprintf.c: Likewise.
6197         * tests/test-vdprintf-posix.c: Likewise.
6198         * tests/test-vfprintf-posix.c: Likewise.
6199         * tests/test-vprintf-posix.c: Likewise.
6200         * tests/test-vsnprintf-posix.c: Likewise.
6201         * tests/test-vsnprintf.c: Likewise.
6202         * tests/test-vsprintf-posix.c: Likewise.
6203         * tests/test-wcrtomb.c: Likewise.
6204         * tests/test-wcsnrtombs.c: Likewise.
6205         * tests/test-wcsrtombs.c: Likewise.
6206         * tests/test-wctype.c: Likewise.
6207         * tests/test-wcwidth.c: Likewise.
6208         * tests/test-xfprintf-posix.c: Likewise.
6209         * tests/test-xmemdup0.c: Likewise.
6210         * tests/test-xprintf-posix.c: Likewise.
6211         * tests/test-xvasprintf.c: Likewise.
6212         * tests/unicase/test-locale-language.c: Likewise.
6213         * tests/unicase/test-mapping-part1.h: Likewise.
6214         * tests/unicase/test-predicate-part1.h: Likewise.
6215         * tests/unicase/test-u8-casecmp.c: Likewise.
6216         * tests/unicase/test-u8-casecoll.c: Likewise.
6217         * tests/unicase/test-u8-casefold.c: Likewise.
6218         * tests/unicase/test-u8-is-cased.c: Likewise.
6219         * tests/unicase/test-u8-is-casefolded.c: Likewise.
6220         * tests/unicase/test-u8-is-lowercase.c: Likewise.
6221         * tests/unicase/test-u8-is-titlecase.c: Likewise.
6222         * tests/unicase/test-u8-is-uppercase.c: Likewise.
6223         * tests/unicase/test-u8-tolower.c: Likewise.
6224         * tests/unicase/test-u8-totitle.c: Likewise.
6225         * tests/unicase/test-u8-toupper.c: Likewise.
6226         * tests/unicase/test-u16-casecmp.c: Likewise.
6227         * tests/unicase/test-u16-casecoll.c: Likewise.
6228         * tests/unicase/test-u16-casefold.c: Likewise.
6229         * tests/unicase/test-u16-is-cased.c: Likewise.
6230         * tests/unicase/test-u16-is-casefolded.c: Likewise.
6231         * tests/unicase/test-u16-is-lowercase.c: Likewise.
6232         * tests/unicase/test-u16-is-titlecase.c: Likewise.
6233         * tests/unicase/test-u16-is-uppercase.c: Likewise.
6234         * tests/unicase/test-u16-tolower.c: Likewise.
6235         * tests/unicase/test-u16-totitle.c: Likewise.
6236         * tests/unicase/test-u16-toupper.c: Likewise.
6237         * tests/unicase/test-u32-casecmp.c: Likewise.
6238         * tests/unicase/test-u32-casecoll.c: Likewise.
6239         * tests/unicase/test-u32-casefold.c: Likewise.
6240         * tests/unicase/test-u32-is-cased.c: Likewise.
6241         * tests/unicase/test-u32-is-casefolded.c: Likewise.
6242         * tests/unicase/test-u32-is-lowercase.c: Likewise.
6243         * tests/unicase/test-u32-is-titlecase.c: Likewise.
6244         * tests/unicase/test-u32-is-uppercase.c: Likewise.
6245         * tests/unicase/test-u32-tolower.c: Likewise.
6246         * tests/unicase/test-u32-totitle.c: Likewise.
6247         * tests/unicase/test-u32-toupper.c: Likewise.
6248         * tests/unicase/test-ulc-casecmp.c: Likewise.
6249         * tests/unicase/test-ulc-casecoll.c: Likewise.
6250         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
6251         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
6252         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
6253         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
6254         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
6255         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
6256         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
6257         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
6258         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
6259         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
6260         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
6261         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
6262         * tests/unictype/test-bidi_byname.c: Likewise.
6263         * tests/unictype/test-bidi_name.c: Likewise.
6264         * tests/unictype/test-bidi_of.c: Likewise.
6265         * tests/unictype/test-bidi_test.c: Likewise.
6266         * tests/unictype/test-block_list.c: Likewise.
6267         * tests/unictype/test-block_of.c: Likewise.
6268         * tests/unictype/test-block_test.c: Likewise.
6269         * tests/unictype/test-categ_and.c: Likewise.
6270         * tests/unictype/test-categ_and_not.c: Likewise.
6271         * tests/unictype/test-categ_byname.c: Likewise.
6272         * tests/unictype/test-categ_name.c: Likewise.
6273         * tests/unictype/test-categ_none.c: Likewise.
6274         * tests/unictype/test-categ_of.c: Likewise.
6275         * tests/unictype/test-categ_or.c: Likewise.
6276         * tests/unictype/test-categ_test_withtable.c: Likewise.
6277         * tests/unictype/test-combining.c: Likewise.
6278         * tests/unictype/test-decdigit.c: Likewise.
6279         * tests/unictype/test-digit.c: Likewise.
6280         * tests/unictype/test-mirror.c: Likewise.
6281         * tests/unictype/test-numeric.c: Likewise.
6282         * tests/unictype/test-pr_byname.c: Likewise.
6283         * tests/unictype/test-pr_test.c: Likewise.
6284         * tests/unictype/test-predicate-part1.h: Likewise.
6285         * tests/unictype/test-scripts.c: Likewise.
6286         * tests/unictype/test-sy_c_ident.c: Likewise.
6287         * tests/unictype/test-sy_java_ident.c: Likewise.
6288         * tests/unilbrk/test-u8-possible-linebreaks.c: Likewise.
6289         * tests/unilbrk/test-u8-width-linebreaks.c: Likewise.
6290         * tests/unilbrk/test-u16-possible-linebreaks.c: Likewise.
6291         * tests/unilbrk/test-u16-width-linebreaks.c: Likewise.
6292         * tests/unilbrk/test-u32-possible-linebreaks.c: Likewise.
6293         * tests/unilbrk/test-u32-width-linebreaks.c: Likewise.
6294         * tests/unilbrk/test-ulc-possible-linebreaks.c: Likewise.
6295         * tests/unilbrk/test-ulc-width-linebreaks.c: Likewise.
6296         * tests/uninorm/test-canonical-decomposition.c: Likewise.
6297         * tests/uninorm/test-compat-decomposition.c: Likewise.
6298         * tests/uninorm/test-composition.c: Likewise.
6299         * tests/uninorm/test-decomposing-form.c: Likewise.
6300         * tests/uninorm/test-decomposition.c: Likewise.
6301         * tests/uninorm/test-u8-nfc.c: Likewise.
6302         * tests/uninorm/test-u8-nfd.c: Likewise.
6303         * tests/uninorm/test-u8-nfkc.c: Likewise.
6304         * tests/uninorm/test-u8-nfkd.c: Likewise.
6305         * tests/uninorm/test-u8-normcmp.c: Likewise.
6306         * tests/uninorm/test-u8-normcoll.c: Likewise.
6307         * tests/uninorm/test-u16-nfc.c: Likewise.
6308         * tests/uninorm/test-u16-nfd.c: Likewise.
6309         * tests/uninorm/test-u16-nfkc.c: Likewise.
6310         * tests/uninorm/test-u16-nfkd.c: Likewise.
6311         * tests/uninorm/test-u16-normcmp.c: Likewise.
6312         * tests/uninorm/test-u16-normcoll.c: Likewise.
6313         * tests/uninorm/test-u32-nfc.c: Likewise.
6314         * tests/uninorm/test-u32-nfd.c: Likewise.
6315         * tests/uninorm/test-u32-nfkc.c: Likewise.
6316         * tests/uninorm/test-u32-nfkd.c: Likewise.
6317         * tests/uninorm/test-u32-normalize-big.c: Likewise.
6318         * tests/uninorm/test-u32-normcmp.c: Likewise.
6319         * tests/uninorm/test-u32-normcoll.c: Likewise.
6320         * tests/uninorm/test-uninorm-filter-nfc.c: Likewise.
6321         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
6322         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
6323         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
6324         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
6325         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
6326         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
6327         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
6328         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
6329         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
6330         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
6331         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
6332         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
6333         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
6334         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
6335         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
6336         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
6337         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
6338         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
6339         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
6340         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
6341         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
6342         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
6343         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
6344         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
6345         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
6346         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
6347         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
6348         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
6349         * tests/uniwbrk/test-u8-wordbreaks.c: Likewise.
6350         * tests/uniwbrk/test-u16-wordbreaks.c: Likewise.
6351         * tests/uniwbrk/test-u32-wordbreaks.c: Likewise.
6352         * tests/uniwbrk/test-ulc-wordbreaks.c: Likewise.
6353         * tests/uniwidth/test-u8-strwidth.c: Likewise.
6354         * tests/uniwidth/test-u8-width.c: Likewise.
6355         * tests/uniwidth/test-u16-strwidth.c: Likewise.
6356         * tests/uniwidth/test-u16-width.c: Likewise.
6357         * tests/uniwidth/test-u32-strwidth.c: Likewise.
6358         * tests/uniwidth/test-u32-width.c: Likewise.
6359         * tests/uniwidth/test-uc_width.c: Likewise.
6360         * tests/uniwidth/test-uc_width2.c: Likewise.
6361         * modules/acl-tests (Files): Add tests/macros.h.
6362         * modules/areadlink-tests (Files): Likewise.
6363         * modules/areadlink-with-size-tests (Files): Likewise.
6364         * modules/areadlinkat-tests (Files): Likewise.
6365         * modules/areadlinkat-with-size-tests (Files): Likewise.
6366         * modules/argmatch-tests (Files): Likewise.
6367         * modules/argv-iter-tests (Files): Likewise.
6368         * modules/array-list-tests (Files): Likewise.
6369         * modules/array-mergesort-tests (Files): Likewise.
6370         * modules/array-oset-tests (Files): Likewise.
6371         * modules/avltree-list-tests (Files): Likewise.
6372         * modules/avltree-oset-tests (Files): Likewise.
6373         * modules/avltreehash-list-tests (Files): Likewise.
6374         * modules/base64-tests (Files): Likewise.
6375         * modules/binary-io-tests (Files): Likewise.
6376         * modules/bitrotate-tests (Files): Likewise.
6377         * modules/btowc-tests (Files): Likewise.
6378         * modules/byteswap-tests (Files): Likewise.
6379         * modules/c-ctype-tests (Files): Likewise.
6380         * modules/c-stack-tests (Files): Likewise.
6381         * modules/c-strcase-tests (Files): Likewise.
6382         * modules/c-strcasestr-tests (Files): Likewise.
6383         * modules/c-strstr-tests (Files): Likewise.
6384         * modules/canonicalize-lgpl-tests (Files): Likewise.
6385         * modules/canonicalize-tests (Files): Likewise.
6386         * modules/carray-list-tests (Files): Likewise.
6387         * modules/ceilf-tests (Files): Likewise.
6388         * modules/ceill-tests (Files): Likewise.
6389         * modules/chown-tests (Files): Likewise.
6390         * modules/cloexec-tests (Files): Likewise.
6391         * modules/copy-file-tests (Files): Likewise.
6392         * modules/count-one-bits-tests (Files): Likewise.
6393         * modules/dprintf-posix-tests (Files): Likewise.
6394         * modules/dup2-tests (Files): Likewise.
6395         * modules/dup3-tests (Files): Likewise.
6396         * modules/duplocale-tests (Files): Likewise.
6397         * modules/fbufmode-tests (Files): Likewise.
6398         * modules/fchdir-tests (Files): Likewise.
6399         * modules/fcntl-safer-tests (Files): Likewise.
6400         * modules/fcntl-tests (Files): Likewise.
6401         * modules/fdopendir-tests (Files): Likewise.
6402         * modules/fdutimensat-tests (Files): Likewise.
6403         * modules/fflush-tests (Files): Likewise.
6404         * modules/filevercmp-tests (Files): Likewise.
6405         * modules/flock-tests (Files): Likewise.
6406         * modules/floorf-tests (Files): Likewise.
6407         * modules/floorl-tests (Files): Likewise.
6408         * modules/fnmatch-tests (Files): Likewise.
6409         * modules/fopen-safer-tests (Files): Likewise.
6410         * modules/fopen-tests (Files): Likewise.
6411         * modules/fpending-tests (Files): Likewise.
6412         * modules/fprintf-posix-tests (Files): Likewise.
6413         * modules/fpurge-tests (Files): Likewise.
6414         * modules/freadable-tests (Files): Likewise.
6415         * modules/freadahead-tests (Files): Likewise.
6416         * modules/freading-tests (Files): Likewise.
6417         * modules/freadptr-tests (Files): Likewise.
6418         * modules/freadseek-tests (Files): Likewise.
6419         * modules/freopen-tests (Files): Likewise.
6420         * modules/frexp-nolibm-tests (Files): Likewise.
6421         * modules/frexp-tests (Files): Likewise.
6422         * modules/frexpl-nolibm-tests (Files): Likewise.
6423         * modules/frexpl-tests (Files): Likewise.
6424         * modules/fseek-tests (Files): Likewise.
6425         * modules/fseeko-tests (Files): Likewise.
6426         * modules/fstrcmp-tests (Files): Likewise.
6427         * modules/fsync-tests (Files): Likewise.
6428         * modules/ftell-tests (Files): Likewise.
6429         * modules/ftello-tests (Files): Likewise.
6430         * modules/func-tests (Files): Likewise.
6431         * modules/futimens-tests (Files): Likewise.
6432         * modules/fwritable-tests (Files): Likewise.
6433         * modules/fwriting-tests (Files): Likewise.
6434         * modules/getcwd-tests (Files): Likewise.
6435         * modules/getdate-tests (Files): Likewise.
6436         * modules/getdelim-tests (Files): Likewise.
6437         * modules/getdtablesize-tests (Files): Likewise.
6438         * modules/getgroups-tests (Files): Likewise.
6439         * modules/getline-tests (Files): Likewise.
6440         * modules/getndelim2-tests (Files): Likewise.
6441         * modules/glob-tests (Files): Likewise.
6442         * modules/hash-tests (Files): Likewise.
6443         * modules/i-ring-tests (Files): Likewise.
6444         * modules/iconv-tests (Files): Likewise.
6445         * modules/iconv_open-utf-tests (Files): Likewise.
6446         * modules/idpriv-drop-tests (Files): Likewise.
6447         * modules/idpriv-droptemp-tests (Files): Likewise.
6448         * modules/inet_ntop-tests (Files): Likewise.
6449         * modules/inet_pton-tests (Files): Likewise.
6450         * modules/isblank-tests (Files): Likewise.
6451         * modules/isfinite-tests (Files): Likewise.
6452         * modules/isinf-tests (Files): Likewise.
6453         * modules/isnan-tests (Files): Likewise.
6454         * modules/isnand-nolibm-tests (Files): Likewise.
6455         * modules/isnand-tests (Files): Likewise.
6456         * modules/isnanf-nolibm-tests (Files): Likewise.
6457         * modules/isnanf-tests (Files): Likewise.
6458         * modules/isnanl-nolibm-tests (Files): Likewise.
6459         * modules/isnanl-tests (Files): Likewise.
6460         * modules/lchown-tests (Files): Likewise.
6461         * modules/ldexpl-tests (Files): Likewise.
6462         * modules/link-tests (Files): Likewise.
6463         * modules/linkat-tests (Files): Likewise.
6464         * modules/linked-list-tests (Files): Likewise.
6465         * modules/linkedhash-list-tests (Files): Likewise.
6466         * modules/localename-tests (Files): Likewise.
6467         * modules/lseek-tests (Files): Likewise.
6468         * modules/lstat-tests (Files): Likewise.
6469         * modules/mbmemcasecmp-tests (Files): Likewise.
6470         * modules/mbmemcasecoll-tests (Files): Likewise.
6471         * modules/mbrtowc-tests (Files): Likewise.
6472         * modules/mbscasecmp-tests (Files): Likewise.
6473         * modules/mbscasestr-tests (Files): Likewise.
6474         * modules/mbschr-tests (Files): Likewise.
6475         * modules/mbscspn-tests (Files): Likewise.
6476         * modules/mbsinit-tests (Files): Likewise.
6477         * modules/mbsncasecmp-tests (Files): Likewise.
6478         * modules/mbsnrtowcs-tests (Files): Likewise.
6479         * modules/mbspbrk-tests (Files): Likewise.
6480         * modules/mbspcasecmp-tests (Files): Likewise.
6481         * modules/mbsrchr-tests (Files): Likewise.
6482         * modules/mbsrtowcs-tests (Files): Likewise.
6483         * modules/mbsspn-tests (Files): Likewise.
6484         * modules/mbsstr-tests (Files): Likewise.
6485         * modules/memchr-tests (Files): Likewise.
6486         * modules/memchr2-tests (Files): Likewise.
6487         * modules/memcmp-tests (Files): Likewise.
6488         * modules/memmem-tests (Files): Likewise.
6489         * modules/memrchr-tests (Files): Likewise.
6490         * modules/mkdir-tests (Files): Likewise.
6491         * modules/mkfifo-tests (Files): Likewise.
6492         * modules/mkfifoat-tests (Files): Likewise.
6493         * modules/mknod-tests (Files): Likewise.
6494         * modules/nanosleep-tests (Files): Likewise.
6495         * modules/nl_langinfo-tests (Files): Likewise.
6496         * modules/obstack-printf-tests (Files): Likewise.
6497         * modules/open-tests (Files): Likewise.
6498         * modules/openat-tests (Files): Likewise.
6499         * modules/pipe-filter-gi-tests (Files): Likewise.
6500         * modules/pipe-filter-ii-tests (Files): Likewise.
6501         * modules/pipe2-tests (Files): Likewise.
6502         * modules/popen-safer-tests (Files): Likewise.
6503         * modules/popen-tests (Files): Likewise.
6504         * modules/posixtm-tests (Files): Likewise.
6505         * modules/pread-tests (Files): Likewise.
6506         * modules/printf-frexp-tests (Files): Likewise.
6507         * modules/printf-frexpl-tests (Files): Likewise.
6508         * modules/printf-posix-tests (Files): Likewise.
6509         * modules/priv-set-tests (Files): Likewise.
6510         * modules/quotearg-tests (Files): Likewise.
6511         * modules/random_r-tests (Files): Likewise.
6512         * modules/rawmemchr-tests (Files): Likewise.
6513         * modules/rbtree-list-tests (Files): Likewise.
6514         * modules/rbtree-oset-tests (Files): Likewise.
6515         * modules/rbtreehash-list-tests (Files): Likewise.
6516         * modules/readlink-tests (Files): Likewise.
6517         * modules/remove-tests (Files): Likewise.
6518         * modules/rename-tests (Files): Likewise.
6519         * modules/renameat-tests (Files): Likewise.
6520         * modules/rmdir-tests (Files): Likewise.
6521         * modules/round-tests (Files): Likewise.
6522         * modules/roundf-tests (Files): Likewise.
6523         * modules/roundl-tests (Files): Likewise.
6524         * modules/safe-alloc-tests (Files): Likewise.
6525         * modules/setenv-tests (Files): Likewise.
6526         * modules/sigaction-tests (Files): Likewise.
6527         * modules/signbit-tests (Files): Likewise.
6528         * modules/sleep-tests (Files): Likewise.
6529         * modules/snprintf-posix-tests (Files): Likewise.
6530         * modules/snprintf-tests (Files): Likewise.
6531         * modules/sprintf-posix-tests (Files): Likewise.
6532         * modules/stat-tests (Files): Likewise.
6533         * modules/stat-time-tests (Files): Likewise.
6534         * modules/strcasestr-tests (Files): Likewise.
6535         * modules/strchrnul-tests (Files): Likewise.
6536         * modules/strerror-tests (Files): Likewise.
6537         * modules/striconv-tests (Files): Likewise.
6538         * modules/striconveh-tests (Files): Likewise.
6539         * modules/striconveha-tests (Files): Likewise.
6540         * modules/strsignal-tests (Files): Likewise.
6541         * modules/strstr-tests (Files): Likewise.
6542         * modules/strtod-tests (Files): Likewise.
6543         * modules/strverscmp-tests (Files): Likewise.
6544         * modules/symlink-tests (Files): Likewise.
6545         * modules/symlinkat-tests (Files): Likewise.
6546         * modules/trunc-tests (Files): Likewise.
6547         * modules/truncf-tests (Files): Likewise.
6548         * modules/truncl-tests (Files): Likewise.
6549         * modules/uname-tests (Files): Likewise.
6550         * modules/unicase/cased-tests (Files): Likewise.
6551         * modules/unicase/ignorable-tests (Files): Likewise.
6552         * modules/unicase/locale-language-tests (Files): Likewise.
6553         * modules/unicase/tolower-tests (Files): Likewise.
6554         * modules/unicase/totitle-tests (Files): Likewise.
6555         * modules/unicase/toupper-tests (Files): Likewise.
6556         * modules/unicase/u8-casecmp-tests (Files): Likewise.
6557         * modules/unicase/u8-casecoll-tests (Files): Likewise.
6558         * modules/unicase/u8-casefold-tests (Files): Likewise.
6559         * modules/unicase/u8-is-cased-tests (Files): Likewise.
6560         * modules/unicase/u8-is-casefolded-tests (Files): Likewise.
6561         * modules/unicase/u8-is-lowercase-tests (Files): Likewise.
6562         * modules/unicase/u8-is-titlecase-tests (Files): Likewise.
6563         * modules/unicase/u8-is-uppercase-tests (Files): Likewise.
6564         * modules/unicase/u8-tolower-tests (Files): Likewise.
6565         * modules/unicase/u8-totitle-tests (Files): Likewise.
6566         * modules/unicase/u8-toupper-tests (Files): Likewise.
6567         * modules/unicase/u16-casecmp-tests (Files): Likewise.
6568         * modules/unicase/u16-casecoll-tests (Files): Likewise.
6569         * modules/unicase/u16-casefold-tests (Files): Likewise.
6570         * modules/unicase/u16-is-cased-tests (Files): Likewise.
6571         * modules/unicase/u16-is-casefolded-tests (Files): Likewise.
6572         * modules/unicase/u16-is-lowercase-tests (Files): Likewise.
6573         * modules/unicase/u16-is-titlecase-tests (Files): Likewise.
6574         * modules/unicase/u16-is-uppercase-tests (Files): Likewise.
6575         * modules/unicase/u16-tolower-tests (Files): Likewise.
6576         * modules/unicase/u16-totitle-tests (Files): Likewise.
6577         * modules/unicase/u16-toupper-tests (Files): Likewise.
6578         * modules/unicase/u32-casecmp-tests (Files): Likewise.
6579         * modules/unicase/u32-casecoll-tests (Files): Likewise.
6580         * modules/unicase/u32-casefold-tests (Files): Likewise.
6581         * modules/unicase/u32-is-cased-tests (Files): Likewise.
6582         * modules/unicase/u32-is-casefolded-tests (Files): Likewise.
6583         * modules/unicase/u32-is-lowercase-tests (Files): Likewise.
6584         * modules/unicase/u32-is-titlecase-tests (Files): Likewise.
6585         * modules/unicase/u32-is-uppercase-tests (Files): Likewise.
6586         * modules/unicase/u32-tolower-tests (Files): Likewise.
6587         * modules/unicase/u32-totitle-tests (Files): Likewise.
6588         * modules/unicase/u32-toupper-tests (Files): Likewise.
6589         * modules/unicase/ulc-casecmp-tests (Files): Likewise.
6590         * modules/unicase/ulc-casecoll-tests (Files): Likewise.
6591         * modules/uniconv/u8-conv-from-enc-tests (Files): Likewise.
6592         * modules/uniconv/u8-conv-to-enc-tests (Files): Likewise.
6593         * modules/uniconv/u8-strconv-from-enc-tests (Files): Likewise.
6594         * modules/uniconv/u8-strconv-to-enc-tests (Files): Likewise.
6595         * modules/uniconv/u16-conv-from-enc-tests (Files): Likewise.
6596         * modules/uniconv/u16-conv-to-enc-tests (Files): Likewise.
6597         * modules/uniconv/u16-strconv-from-enc-tests (Files): Likewise.
6598         * modules/uniconv/u16-strconv-to-enc-tests (Files): Likewise.
6599         * modules/uniconv/u32-conv-from-enc-tests (Files): Likewise.
6600         * modules/uniconv/u32-conv-to-enc-tests (Files): Likewise.
6601         * modules/uniconv/u32-strconv-from-enc-tests (Files): Likewise.
6602         * modules/uniconv/u32-strconv-to-enc-tests (Files): Likewise.
6603         * modules/unictype/bidicategory-byname-tests (Files): Likewise.
6604         * modules/unictype/bidicategory-name-tests (Files): Likewise.
6605         * modules/unictype/bidicategory-of-tests (Files): Likewise.
6606         * modules/unictype/bidicategory-test-tests (Files): Likewise.
6607         * modules/unictype/block-list-tests (Files): Likewise.
6608         * modules/unictype/block-of-tests (Files): Likewise.
6609         * modules/unictype/block-test-tests (Files): Likewise.
6610         * modules/unictype/category-C-tests (Files): Likewise.
6611         * modules/unictype/category-Cc-tests (Files): Likewise.
6612         * modules/unictype/category-Cf-tests (Files): Likewise.
6613         * modules/unictype/category-Cn-tests (Files): Likewise.
6614         * modules/unictype/category-Co-tests (Files): Likewise.
6615         * modules/unictype/category-Cs-tests (Files): Likewise.
6616         * modules/unictype/category-L-tests (Files): Likewise.
6617         * modules/unictype/category-Ll-tests (Files): Likewise.
6618         * modules/unictype/category-Lm-tests (Files): Likewise.
6619         * modules/unictype/category-Lo-tests (Files): Likewise.
6620         * modules/unictype/category-Lt-tests (Files): Likewise.
6621         * modules/unictype/category-Lu-tests (Files): Likewise.
6622         * modules/unictype/category-M-tests (Files): Likewise.
6623         * modules/unictype/category-Mc-tests (Files): Likewise.
6624         * modules/unictype/category-Me-tests (Files): Likewise.
6625         * modules/unictype/category-Mn-tests (Files): Likewise.
6626         * modules/unictype/category-N-tests (Files): Likewise.
6627         * modules/unictype/category-Nd-tests (Files): Likewise.
6628         * modules/unictype/category-Nl-tests (Files): Likewise.
6629         * modules/unictype/category-No-tests (Files): Likewise.
6630         * modules/unictype/category-P-tests (Files): Likewise.
6631         * modules/unictype/category-Pc-tests (Files): Likewise.
6632         * modules/unictype/category-Pd-tests (Files): Likewise.
6633         * modules/unictype/category-Pe-tests (Files): Likewise.
6634         * modules/unictype/category-Pf-tests (Files): Likewise.
6635         * modules/unictype/category-Pi-tests (Files): Likewise.
6636         * modules/unictype/category-Po-tests (Files): Likewise.
6637         * modules/unictype/category-Ps-tests (Files): Likewise.
6638         * modules/unictype/category-S-tests (Files): Likewise.
6639         * modules/unictype/category-Sc-tests (Files): Likewise.
6640         * modules/unictype/category-Sk-tests (Files): Likewise.
6641         * modules/unictype/category-Sm-tests (Files): Likewise.
6642         * modules/unictype/category-So-tests (Files): Likewise.
6643         * modules/unictype/category-Z-tests (Files): Likewise.
6644         * modules/unictype/category-Zl-tests (Files): Likewise.
6645         * modules/unictype/category-Zp-tests (Files): Likewise.
6646         * modules/unictype/category-Zs-tests (Files): Likewise.
6647         * modules/unictype/category-and-not-tests (Files): Likewise.
6648         * modules/unictype/category-and-tests (Files): Likewise.
6649         * modules/unictype/category-byname-tests (Files): Likewise.
6650         * modules/unictype/category-name-tests (Files): Likewise.
6651         * modules/unictype/category-none-tests (Files): Likewise.
6652         * modules/unictype/category-of-tests (Files): Likewise.
6653         * modules/unictype/category-or-tests (Files): Likewise.
6654         * modules/unictype/category-test-withtable-tests (Files): Likewise.
6655         * modules/unictype/combining-class-tests (Files): Likewise.
6656         * modules/unictype/ctype-alnum-tests (Files): Likewise.
6657         * modules/unictype/ctype-alpha-tests (Files): Likewise.
6658         * modules/unictype/ctype-blank-tests (Files): Likewise.
6659         * modules/unictype/ctype-cntrl-tests (Files): Likewise.
6660         * modules/unictype/ctype-digit-tests (Files): Likewise.
6661         * modules/unictype/ctype-graph-tests (Files): Likewise.
6662         * modules/unictype/ctype-lower-tests (Files): Likewise.
6663         * modules/unictype/ctype-print-tests (Files): Likewise.
6664         * modules/unictype/ctype-punct-tests (Files): Likewise.
6665         * modules/unictype/ctype-space-tests (Files): Likewise.
6666         * modules/unictype/ctype-upper-tests (Files): Likewise.
6667         * modules/unictype/ctype-xdigit-tests (Files): Likewise.
6668         * modules/unictype/decimal-digit-tests (Files): Likewise.
6669         * modules/unictype/digit-tests (Files): Likewise.
6670         * modules/unictype/mirror-tests (Files): Likewise.
6671         * modules/unictype/numeric-tests (Files): Likewise.
6672         * modules/unictype/property-alphabetic-tests (Files): Likewise.
6673         * modules/unictype/property-ascii-hex-digit-tests (Files): Likewise.
6674         * modules/unictype/property-bidi-arabic-digit-tests (Files): Likewise.
6675         * modules/unictype/property-bidi-arabic-right-to-left-tests (Files):
6676         Likewise.
6677         * modules/unictype/property-bidi-block-separator-tests (Files):
6678         Likewise.
6679         * modules/unictype/property-bidi-boundary-neutral-tests (Files):
6680         Likewise.
6681         * modules/unictype/property-bidi-common-separator-tests (Files):
6682         Likewise.
6683         * modules/unictype/property-bidi-control-tests (Files): Likewise.
6684         * modules/unictype/property-bidi-embedding-or-override-tests (Files):
6685         Likewise.
6686         * modules/unictype/property-bidi-eur-num-separator-tests (Files):
6687         Likewise.
6688         * modules/unictype/property-bidi-eur-num-terminator-tests (Files):
6689         Likewise.
6690         * modules/unictype/property-bidi-european-digit-tests (Files): Likewise.
6691         * modules/unictype/property-bidi-hebrew-right-to-left-tests (Files):
6692         Likewise.
6693         * modules/unictype/property-bidi-left-to-right-tests (Files): Likewise.
6694         * modules/unictype/property-bidi-non-spacing-mark-tests (Files):
6695         Likewise.
6696         * modules/unictype/property-bidi-other-neutral-tests (Files): Likewise.
6697         * modules/unictype/property-bidi-pdf-tests (Files): Likewise.
6698         * modules/unictype/property-bidi-segment-separator-tests (Files):
6699         Likewise.
6700         * modules/unictype/property-bidi-whitespace-tests (Files): Likewise.
6701         * modules/unictype/property-byname-tests (Files): Likewise.
6702         * modules/unictype/property-combining-tests (Files): Likewise.
6703         * modules/unictype/property-composite-tests (Files): Likewise.
6704         * modules/unictype/property-currency-symbol-tests (Files): Likewise.
6705         * modules/unictype/property-dash-tests (Files): Likewise.
6706         * modules/unictype/property-decimal-digit-tests (Files): Likewise.
6707         * modules/unictype/property-default-ignorable-code-point-tests (Files):
6708         Likewise.
6709         * modules/unictype/property-deprecated-tests (Files): Likewise.
6710         * modules/unictype/property-diacritic-tests (Files): Likewise.
6711         * modules/unictype/property-extender-tests (Files): Likewise.
6712         * modules/unictype/property-format-control-tests (Files): Likewise.
6713         * modules/unictype/property-grapheme-base-tests (Files): Likewise.
6714         * modules/unictype/property-grapheme-extend-tests (Files): Likewise.
6715         * modules/unictype/property-grapheme-link-tests (Files): Likewise.
6716         * modules/unictype/property-hex-digit-tests (Files): Likewise.
6717         * modules/unictype/property-hyphen-tests (Files): Likewise.
6718         * modules/unictype/property-id-continue-tests (Files): Likewise.
6719         * modules/unictype/property-id-start-tests (Files): Likewise.
6720         * modules/unictype/property-ideographic-tests (Files): Likewise.
6721         * modules/unictype/property-ids-binary-operator-tests (Files): Likewise.
6722         * modules/unictype/property-ids-trinary-operator-tests (Files):
6723         Likewise.
6724         * modules/unictype/property-ignorable-control-tests (Files): Likewise.
6725         * modules/unictype/property-iso-control-tests (Files): Likewise.
6726         * modules/unictype/property-join-control-tests (Files): Likewise.
6727         * modules/unictype/property-left-of-pair-tests (Files): Likewise.
6728         * modules/unictype/property-line-separator-tests (Files): Likewise.
6729         * modules/unictype/property-logical-order-exception-tests (Files):
6730         Likewise.
6731         * modules/unictype/property-lowercase-tests (Files): Likewise.
6732         * modules/unictype/property-math-tests (Files): Likewise.
6733         * modules/unictype/property-non-break-tests (Files): Likewise.
6734         * modules/unictype/property-not-a-character-tests (Files): Likewise.
6735         * modules/unictype/property-numeric-tests (Files): Likewise.
6736         * modules/unictype/property-other-alphabetic-tests (Files): Likewise.
6737         * modules/unictype/property-other-default-ignorable-code-point-tests
6738         (Files): Likewise.
6739         * modules/unictype/property-other-grapheme-extend-tests (Files):
6740         Likewise.
6741         * modules/unictype/property-other-id-continue-tests (Files): Likewise.
6742         * modules/unictype/property-other-id-start-tests (Files): Likewise.
6743         * modules/unictype/property-other-lowercase-tests (Files): Likewise.
6744         * modules/unictype/property-other-math-tests (Files): Likewise.
6745         * modules/unictype/property-other-uppercase-tests (Files): Likewise.
6746         * modules/unictype/property-paired-punctuation-tests (Files): Likewise.
6747         * modules/unictype/property-paragraph-separator-tests (Files): Likewise.
6748         * modules/unictype/property-pattern-syntax-tests (Files): Likewise.
6749         * modules/unictype/property-pattern-white-space-tests (Files): Likewise.
6750         * modules/unictype/property-private-use-tests (Files): Likewise.
6751         * modules/unictype/property-punctuation-tests (Files): Likewise.
6752         * modules/unictype/property-quotation-mark-tests (Files): Likewise.
6753         * modules/unictype/property-radical-tests (Files): Likewise.
6754         * modules/unictype/property-sentence-terminal-tests (Files): Likewise.
6755         * modules/unictype/property-soft-dotted-tests (Files): Likewise.
6756         * modules/unictype/property-space-tests (Files): Likewise.
6757         * modules/unictype/property-terminal-punctuation-tests (Files):
6758         Likewise.
6759         * modules/unictype/property-test-tests (Files): Likewise.
6760         * modules/unictype/property-titlecase-tests (Files): Likewise.
6761         * modules/unictype/property-unassigned-code-value-tests (Files):
6762         Likewise.
6763         * modules/unictype/property-unified-ideograph-tests (Files): Likewise.
6764         * modules/unictype/property-uppercase-tests (Files): Likewise.
6765         * modules/unictype/property-variation-selector-tests (Files): Likewise.
6766         * modules/unictype/property-white-space-tests (Files): Likewise.
6767         * modules/unictype/property-xid-continue-tests (Files): Likewise.
6768         * modules/unictype/property-xid-start-tests (Files): Likewise.
6769         * modules/unictype/property-zero-width-tests (Files): Likewise.
6770         * modules/unictype/scripts-tests (Files): Likewise.
6771         * modules/unictype/syntax-c-ident-tests (Files): Likewise.
6772         * modules/unictype/syntax-c-whitespace-tests (Files): Likewise.
6773         * modules/unictype/syntax-java-ident-tests (Files): Likewise.
6774         * modules/unictype/syntax-java-whitespace-tests (Files): Likewise.
6775         * modules/unilbrk/u8-possible-linebreaks-tests (Files): Likewise.
6776         * modules/unilbrk/u8-width-linebreaks-tests (Files): Likewise.
6777         * modules/unilbrk/u16-possible-linebreaks-tests (Files): Likewise.
6778         * modules/unilbrk/u16-width-linebreaks-tests (Files): Likewise.
6779         * modules/unilbrk/u32-possible-linebreaks-tests (Files): Likewise.
6780         * modules/unilbrk/u32-width-linebreaks-tests (Files): Likewise.
6781         * modules/unilbrk/ulc-possible-linebreaks-tests (Files): Likewise.
6782         * modules/unilbrk/ulc-width-linebreaks-tests (Files): Likewise.
6783         * modules/uninorm/canonical-decomposition-tests (Files): Likewise.
6784         * modules/uninorm/compat-decomposition-tests (Files): Likewise.
6785         * modules/uninorm/composition-tests (Files): Likewise.
6786         * modules/uninorm/decomposing-form-tests (Files): Likewise.
6787         * modules/uninorm/decomposition-tests (Files): Likewise.
6788         * modules/uninorm/filter-tests (Files): Likewise.
6789         * modules/uninorm/nfc-tests (Files): Likewise.
6790         * modules/uninorm/nfd-tests (Files): Likewise.
6791         * modules/uninorm/nfkc-tests (Files): Likewise.
6792         * modules/uninorm/nfkd-tests (Files): Likewise.
6793         * modules/uninorm/u8-normcmp-tests (Files): Likewise.
6794         * modules/uninorm/u8-normcoll-tests (Files): Likewise.
6795         * modules/uninorm/u16-normcmp-tests (Files): Likewise.
6796         * modules/uninorm/u16-normcoll-tests (Files): Likewise.
6797         * modules/uninorm/u32-normcmp-tests (Files): Likewise.
6798         * modules/uninorm/u32-normcoll-tests (Files): Likewise.
6799         * modules/unistdio/u8-asnprintf-tests (Files): Likewise.
6800         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
6801         * modules/unistdio/u8-vasprintf-tests (Files): Likewise.
6802         * modules/unistdio/u8-vsnprintf-tests (Files): Likewise.
6803         * modules/unistdio/u8-vsprintf-tests (Files): Likewise.
6804         * modules/unistdio/u16-asnprintf-tests (Files): Likewise.
6805         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
6806         * modules/unistdio/u16-vasprintf-tests (Files): Likewise.
6807         * modules/unistdio/u16-vsnprintf-tests (Files): Likewise.
6808         * modules/unistdio/u16-vsprintf-tests (Files): Likewise.
6809         * modules/unistdio/u32-asnprintf-tests (Files): Likewise.
6810         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
6811         * modules/unistdio/u32-vasprintf-tests (Files): Likewise.
6812         * modules/unistdio/u32-vsnprintf-tests (Files): Likewise.
6813         * modules/unistdio/u32-vsprintf-tests (Files): Likewise.
6814         * modules/unistdio/ulc-asnprintf-tests (Files): Likewise.
6815         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
6816         * modules/unistdio/ulc-vasprintf-tests (Files): Likewise.
6817         * modules/unistdio/ulc-vsnprintf-tests (Files): Likewise.
6818         * modules/unistdio/ulc-vsprintf-tests (Files): Likewise.
6819         * modules/uniwbrk/u8-wordbreaks-tests (Files): Likewise.
6820         * modules/uniwbrk/u16-wordbreaks-tests (Files): Likewise.
6821         * modules/uniwbrk/u32-wordbreaks-tests (Files): Likewise.
6822         * modules/uniwbrk/ulc-wordbreaks-tests (Files): Likewise.
6823         * modules/uniwidth/u8-strwidth-tests (Files): Likewise.
6824         * modules/uniwidth/u8-width-tests (Files): Likewise.
6825         * modules/uniwidth/u16-strwidth-tests (Files): Likewise.
6826         * modules/uniwidth/u16-width-tests (Files): Likewise.
6827         * modules/uniwidth/u32-strwidth-tests (Files): Likewise.
6828         * modules/uniwidth/u32-width-tests (Files): Likewise.
6829         * modules/uniwidth/width-tests (Files): Likewise.
6830         * modules/unlink-tests (Files): Likewise.
6831         * modules/unsetenv-tests (Files): Likewise.
6832         * modules/usleep-tests (Files): Likewise.
6833         * modules/utimens-tests (Files): Likewise.
6834         * modules/utimensat-tests (Files): Likewise.
6835         * modules/vasnprintf-posix-tests (Files): Likewise.
6836         * modules/vasnprintf-tests (Files): Likewise.
6837         * modules/vasprintf-posix-tests (Files): Likewise.
6838         * modules/vasprintf-tests (Files): Likewise.
6839         * modules/vdprintf-posix-tests (Files): Likewise.
6840         * modules/vfprintf-posix-tests (Files): Likewise.
6841         * modules/vprintf-posix-tests (Files): Likewise.
6842         * modules/vsnprintf-posix-tests (Files): Likewise.
6843         * modules/vsnprintf-tests (Files): Likewise.
6844         * modules/vsprintf-posix-tests (Files): Likewise.
6845         * modules/wcrtomb-tests (Files): Likewise.
6846         * modules/wcsnrtombs-tests (Files): Likewise.
6847         * modules/wcsrtombs-tests (Files): Likewise.
6848         * modules/wctype-tests (Files): Likewise.
6849         * modules/wcwidth-tests (Files): Likewise.
6850         * modules/xmemdup0-tests (Files): Likewise.
6851         * modules/xprintf-posix-tests (Files): Likewise.
6852         * modules/xvasprintf-tests (Files): Likewise.
6853
6854 2009-12-24  Eric Blake  <ebb9@byu.net>
6855
6856         test-nanosleep: fix typo
6857         * tests/test-nanosleep.c (SIGNATURE_CHECK): Fix typo in previous
6858         patch.
6859         Reported by Bruno Haible.
6860
6861 2009-12-24  Bruno Haible  <bruno@clisp.org>
6862
6863         Reduce namespace pollution on glibc systems.
6864         * lib/inttypes.in.h: Don't include <stdint.h> on glibc systems.
6865         * lib/stdlib.in.h: Don't include <stdint.h>, <unistd.h> on glibc
6866         systems.
6867         * lib/unistd.in.h: Don't include <stdio.h>, <fcntl.h>, <stdlib.h>,
6868         <getopt.h> on glibc systems.
6869         * lib/fcntl.in.h: Don't include <sys/stat.h>, <unistd.h> on glibc
6870         systems.
6871         * lib/fcntl.c: Include <unistd.h> here instead.
6872
6873 2009-12-24  Bruno Haible  <bruno@clisp.org>
6874
6875         * lib/stdlib.in.h (includes): Fix typo in today's commit.
6876
6877 2009-12-24  Eric Blake  <ebb9@byu.net>
6878
6879         tests: add signature checks
6880         * tests/signature.h (SIGNATURE_CHECK): New file.
6881         * modules/atexit-tests (Files): Use it.
6882         * modules/btowc-tests (Files): Likewise.
6883         * modules/canonicalize-lgpl-tests (Files): Likewise.
6884         * modules/ceilf-tests (Files): Likewise.
6885         * modules/ceill-tests (Files): Likewise.
6886         * modules/chown-tests (Files): Likewise.
6887         * modules/dprintf-posix-tests (Files): Likewise.
6888         * modules/dup2-tests (Files): Likewise.
6889         * modules/dup3-tests (Files): Likewise.
6890         * modules/duplocale-tests (Files): Likewise.
6891         * modules/fchdir-tests (Files): Likewise.
6892         * modules/fcntl-tests (Files): Likewise.
6893         * modules/fdopendir-tests (Files): Likewise.
6894         * modules/fflush-tests (Files): Likewise.
6895         * modules/flock-tests (Files): Likewise.
6896         * modules/floorf-tests (Files): Likewise.
6897         * modules/floorl-tests (Files): Likewise.
6898         * modules/fnmatch-tests (Files): Likewise.
6899         * modules/fopen-tests (Files): Likewise.
6900         * modules/fprintf-posix-tests (Files): Likewise.
6901         * modules/freopen-tests (Files): Likewise.
6902         * modules/frexp-nolibm-tests (Files): Likewise.
6903         * modules/frexp-tests (Files): Likewise.
6904         * modules/frexpl-nolibm-tests (Files): Likewise.
6905         * modules/frexpl-tests (Files): Likewise.
6906         * modules/fseek-tests (Files): Likewise.
6907         * modules/fseeko-tests (Files): Likewise.
6908         * modules/fsync-tests (Files): Likewise.
6909         * modules/ftell-tests (Files): Likewise.
6910         * modules/ftello-tests (Files): Likewise.
6911         * modules/futimens-tests (Files): Likewise.
6912         * modules/getaddrinfo-tests (Files): Likewise.
6913         * modules/getcwd-tests (Files): Likewise.
6914         * modules/getdelim-tests (Files): Likewise.
6915         * modules/getdtablesize-tests (Files): Likewise.
6916         * modules/getgroups-tests (Files): Likewise.
6917         * modules/gethostname-tests (Files): Likewise.
6918         * modules/getline-tests (Files): Likewise.
6919         * modules/getopt-posix-tests (Files): Likewise.
6920         * modules/gettimeofday-tests (Files): Likewise.
6921         * modules/glob-tests (Files): Likewise.
6922         * modules/iconv-tests (Files): Likewise.
6923         * modules/inet_ntop-tests (Files): Likewise.
6924         * modules/inet_pton-tests (Files): Likewise.
6925         * modules/isblank-tests (Files): Likewise.
6926         * modules/lchown-tests (Files): Likewise.
6927         * modules/ldexpl-tests (Files): Likewise.
6928         * modules/link-tests (Files): Likewise.
6929         * modules/linkat-tests (Files): Likewise.
6930         * modules/lseek-tests (Files): Likewise.
6931         * modules/lstat-tests (Files): Likewise.
6932         * modules/mbrtowc-tests (Files): Likewise.
6933         * modules/mbsinit-tests (Files): Likewise.
6934         * modules/mbsnrtowcs-tests (Files): Likewise.
6935         * modules/mbsrtowcs-tests (Files): Likewise.
6936         * modules/memchr-tests (Files): Likewise.
6937         * modules/memcmp-tests (Files): Likewise.
6938         * modules/memmem-tests (Files): Likewise.
6939         * modules/memrchr-tests (Files): Likewise.
6940         * modules/mkdir-tests (Files): Likewise.
6941         * modules/mkfifo-tests (Files): Likewise.
6942         * modules/mkfifoat-tests (Files): Likewise.
6943         * modules/mknod-tests (Files): Likewise.
6944         * modules/nanosleep-tests (Files): Likewise.
6945         * modules/nl_langinfo-tests (Files): Likewise.
6946         * modules/obstack-printf-tests (Files): Likewise.
6947         * modules/open-tests (Files): Likewise.
6948         * modules/openat-tests (Files): Likewise.
6949         * modules/perror-tests (Files): Likewise.
6950         * modules/pipe2-tests (Files): Likewise.
6951         * modules/poll-tests (Files): Likewise.
6952         * modules/popen-tests (Files): Likewise.
6953         * modules/posix_spawn-tests (Files): Likewise.
6954         * modules/posix_spawnp-tests (Files): Likewise.
6955         * modules/pread-tests (Files): Likewise.
6956         * modules/printf-posix-tests (Files): Likewise.
6957         * modules/pty-tests (Files): Likewise.
6958         * modules/random_r-tests (Files): Likewise.
6959         * modules/rawmemchr-tests (Files): Likewise.
6960         * modules/readlink-tests (Files): Likewise.
6961         * modules/remove-tests (Files): Likewise.
6962         * modules/rename-tests (Files): Likewise.
6963         * modules/renameat-tests (Files): Likewise.
6964         * modules/rmdir-tests (Files): Likewise.
6965         * modules/round-tests (Files): Likewise.
6966         * modules/roundf-tests (Files): Likewise.
6967         * modules/roundl-tests (Files): Likewise.
6968         * modules/select-tests (Files): Likewise.
6969         * modules/setenv-tests (Files): Likewise.
6970         * modules/sigaction-tests (Files): Likewise.
6971         * modules/sleep-tests (Files): Likewise.
6972         * modules/snprintf-posix-tests (Files): Likewise.
6973         * modules/snprintf-tests (Files): Likewise.
6974         * modules/sprintf-posix-tests (Files): Likewise.
6975         * modules/stat-tests (Files): Likewise.
6976         * modules/strcasestr-tests (Files): Likewise.
6977         * modules/strchrnul-tests (Files): Likewise.
6978         * modules/strerror-tests (Files): Likewise.
6979         * modules/strsignal-tests (Files): Likewise.
6980         * modules/strstr-tests (Files): Likewise.
6981         * modules/strtod-tests (Files): Likewise.
6982         * modules/strverscmp-tests (Files): Likewise.
6983         * modules/symlink-tests (Files): Likewise.
6984         * modules/symlinkat-tests (Files): Likewise.
6985         * modules/times-tests (Files): Likewise.
6986         * modules/trunc-tests (Files): Likewise.
6987         * modules/truncf-tests (Files): Likewise.
6988         * modules/truncl-tests (Files): Likewise.
6989         * modules/tsearch-tests (Files): Likewise.
6990         * modules/uname-tests (Files): Likewise.
6991         * modules/unlink-tests (Files): Likewise.
6992         * modules/unsetenv-tests (Files): Likewise.
6993         * modules/usleep-tests (Files): Likewise.
6994         * modules/utimensat-tests (Files): Likewise.
6995         * modules/vasprintf-tests (Files): Likewise.
6996         * modules/vdprintf-posix-tests (Files): Likewise.
6997         * modules/vfprintf-posix-tests (Files): Likewise.
6998         * modules/vprintf-posix-tests (Files): Likewise.
6999         * modules/vsnprintf-posix-tests (Files): Likewise.
7000         * modules/vsnprintf-tests (Files): Likewise.
7001         * modules/vsprintf-posix-tests (Files): Likewise.
7002         * modules/wcrtomb-tests (Files): Likewise.
7003         * modules/wcsnrtombs-tests (Files): Likewise.
7004         * modules/wcsrtombs-tests (Files): Likewise.
7005         * modules/wcwidth-tests (Files): Likewise.
7006         * tests/test-isfinite.c (isfinite): Ensure macro declaration.
7007         * tests/test-isinf.c (isinf): Likewise.
7008         * tests/test-isnan.c (isnan): Likewise.
7009         * tests/test-signbit.c (signbit): Likewise.
7010         * tests/test-select.c (FD_CLR, FD_ISSET, FD_SET, FD_ZERO): Ensure
7011         declaration, either as macro or with correct signature.
7012         (select): Ensure function under test is declared with correct
7013         signature in correct header.
7014         * tests/test-atexit.c (atexit): Likewise.
7015         * tests/test-btowc.c (btowc): Likewise.
7016         * tests/test-canonicalize-lgpl.c (realpath)
7017         (canonicalize_file_name): Likewise.
7018         * tests/test-ceilf1.c (ceilf): Likewise.
7019         * tests/test-ceill.c (ceill): Likewise.
7020         * tests/test-chown.c (chown): Likewise.
7021         * tests/test-dprintf-posix.c (dprintf): Likewise.
7022         * tests/test-dup2.c (dup2): Likewise.
7023         * tests/test-dup3.c (dup3): Likewise.
7024         * tests/test-duplocale.c (duplocale): Likewise.
7025         * tests/test-fchdir.c (fchdir): Likewise.
7026         * tests/test-fchownat.c (fchownat): Likewise.
7027         * tests/test-fcntl.c (fcntl): Likewise.
7028         * tests/test-fdopendir.c (fdopendir): Likewise.
7029         * tests/test-fflush.c (fflush): Likewise.
7030         * tests/test-flock.c (flock): Likewise.
7031         * tests/test-floorf1.c (floorf): Likewise.
7032         * tests/test-floorl.c (floorl): Likewise.
7033         * tests/test-fnmatch.c (fnmatch): Likewise.
7034         * tests/test-fopen.c (fopen): Likewise.
7035         * tests/test-fprintf-posix.c (fprintf): Likewise.
7036         * tests/test-freopen.c (freopen): Likewise.
7037         * tests/test-frexp.c (frexp): Likewise.
7038         * tests/test-frexpl.c (frexpl): Likewise.
7039         * tests/test-fseek.c (fseek): Likewise.
7040         * tests/test-fseeko.c (fseeko): Likewise.
7041         * tests/test-fstatat.c (fstatat): Likewise.
7042         * tests/test-fsync.c (fsync): Likewise.
7043         * tests/test-ftell.c (ftell): Likewise.
7044         * tests/test-ftello.c (ftello): Likewise.
7045         * tests/test-futimens.c (futimens): Likewise.
7046         * tests/test-getaddrinfo.c (getaddrinfo, freeaddrinfo)
7047         (gai_strerror): Likewise.
7048         * tests/test-getcwd.c (getcwd): Likewise.
7049         * tests/test-getdelim.c (getdelim): Likewise.
7050         * tests/test-getdtablesize.c (getdtablesize): Likewise.
7051         * tests/test-getgroups.c (getgroups): Likewise.
7052         * tests/test-gethostname.c (gethostname): Likewise.
7053         * tests/test-getline.c (getline): Likewise.
7054         * tests/test-getopt.c (getopt, getopt_long, getopt_long_only):
7055         Likewise.
7056         * tests/test-gettimeofday.c (gettimeofday): Likewise.
7057         * tests/test-glob.c (glob, globfree): Likewise.
7058         * tests/test-iconv.c (iconv, iconv_open, iconv_close): Likewise.
7059         * tests/test-inet_ntop.c (inet_ntop): Likewise.
7060         * tests/test-inet_pton.c (inet_pton): Likewise.
7061         * tests/test-isblank.c (isblank): Likewise.
7062         * tests/test-lchown.c (lchown): Likewise.
7063         * tests/test-ldexpl.c (ldexpl): Likewise.
7064         * tests/test-link.c (link): Likewise.
7065         * tests/test-linkat.c (linkat): Likewise.
7066         * tests/test-lseek.c (lseek): Likewise.
7067         * tests/test-lstat.c (lstat): Likewise.
7068         * tests/test-mbrtowc.c (mbrtowc): Likewise.
7069         * tests/test-mbsinit.c (mbsinit): Likewise.
7070         * tests/test-mbsnrtowcs.c (mbsnrtowcs): Likewise.
7071         * tests/test-mbsrtowcs.c (mbsrtowcs): Likewise.
7072         * tests/test-memchr.c (memchr): Likewise.
7073         * tests/test-memcmp.c (memcmp): Likewise.
7074         * tests/test-memmem.c (memmem): Likewise.
7075         * tests/test-memrchr.c (memrchr): Likewise.
7076         * tests/test-mkdir.c (mkdir): Likewise.
7077         * tests/test-mkdirat.c (mkdirat): Likewise.
7078         * tests/test-mkfifo.c (mkfifo): Likewise.
7079         * tests/test-mkfifoat.c (mkfifoat, mknodat): Likewise.
7080         * tests/test-mknod.c (mknod): Likewise.
7081         * tests/test-nanosleep.c (nanosleep): Likewise.
7082         * tests/test-nl_langinfo.c (nl_langinfo): Likewise.
7083         * tests/test-obstack-printf.c (obstack_printf, obstack_vprintf):
7084         Likewise.
7085         * tests/test-open.c (open): Likewise.
7086         * tests/test-openat.c (openat): Likewise.
7087         * tests/test-perror.c (perror): Likewise.
7088         * tests/test-pipe2.c (pipe2): Likewise.
7089         * tests/test-poll.c (poll): Likewise.
7090         * tests/test-popen.c (popen, pclose): Likewise.
7091         * tests/test-posix_spawn1.c (posix_spawnp, posix_spawnattr_init)
7092         (posix_spawnattr_destroy, posix_spawnattr_setsigmask)
7093         (posix_spawnattr_setflags, posix_spawn_file_actions_init)
7094         (posix_spawn_file_actions_destroy)
7095         (posix_spawn_file_actions_addclose)
7096         (posix_spawn_file_actions_addopen)
7097         (posix_spawn_file_actions_adddup2): Likewise.
7098         * tests/test-posix_spawn3.c (posix_spawn): Likewise.
7099         * tests/test-pread.c (pread): Likewise.
7100         * tests/test-printf-posix.c (printf): Likewise.
7101         * tests/test-pty.c (openpty, forkpty): Likewise.
7102         * tests/test-random_r.c (srandom_r, initstate_r, setstate_r)
7103         (random_r): Likewise.
7104         * tests/test-rawmemchr.c (rawmemchr): Likewise.
7105         * tests/test-readlink.c (readlink): Likewise.
7106         * tests/test-remove.c (remove): Likewise.
7107         * tests/test-rename.c (rename): Likewise.
7108         * tests/test-renameat.c (renameat): Likewise.
7109         * tests/test-rmdir.c (rmdir): Likewise.
7110         * tests/test-round1.c (round): Likewise.
7111         * tests/test-roundf1.c (roundf): Likewise.
7112         * tests/test-roundl.c (roundl): Likewise.
7113         * tests/test-setenv.c (setenv): Likewise.
7114         * tests/test-sigaction.c (sigaction): Likewise.
7115         * tests/test-sleep.c (sleep): Likewise.
7116         * tests/test-snprintf.c (snprintf): Likewise.
7117         * tests/test-sprintf-posix.c (sprintf): Likewise.
7118         * tests/test-stat.c (stat): Likewise.
7119         * tests/test-stpncpy.c (stpncpy): Likewise.
7120         * tests/test-strcasestr.c (strcasestr): Likewise.
7121         * tests/test-strchrnul.c (strchrnul): Likewise.
7122         * tests/test-strerror.c (strerror): Likewise.
7123         * tests/test-strsignal.c (strsignal): Likewise.
7124         * tests/test-strstr.c (strstr): Likewise.
7125         * tests/test-strtod.c (strtod): Likewise.
7126         * tests/test-strverscmp.c (strverscmp): Likewise.
7127         * tests/test-symlink.c (symlink): Likewise.
7128         * tests/test-symlinkat.c (symlinkat, readlinkat): Likewise.
7129         * tests/test-times.c (times): Likewise.
7130         * tests/test-trunc1.c (trunc): Likewise.
7131         * tests/test-truncf1.c (truncf): Likewise.
7132         * tests/test-truncl.c (truncl): Likewise.
7133         * tests/test-tsearch.c (tdelete, tfind, tsearch, twalk):
7134         Likewise.
7135         * tests/test-uname.c (uname): Likewise.
7136         * tests/test-unlink.c (unlink): Likewise.
7137         * tests/test-unlinkat.c (unlinkat): Likewise.
7138         * tests/test-unsetenv.c (unsetenv): Likewise.
7139         * tests/test-usleep.c (usleep): Likewise.
7140         * tests/test-utimensat.c (utimensat): Likewise.
7141         * tests/test-vasprintf.c (asprintf, vasprintf): Likewise.
7142         * tests/test-vdprintf-posix.c (vdprintf): Likewise.
7143         * tests/test-vfprintf-posix.c (vfprintf): Likewise.
7144         * tests/test-vprintf-posix.c (vprintf): Likewise.
7145         * tests/test-vsnprintf.c (vsnprintf): Likewise.
7146         * tests/test-vsprintf-posix.c (vsprintf): Likewise.
7147         * tests/test-wcrtomb.c (wcrtomb): Likewise.
7148         * tests/test-wcsnrtombs.c (wcsnrtombs): Likewise.
7149         * tests/test-wcsrtombs.c (wcsrtombs): Likewise.
7150         * tests/test-wcwidth.c (wcwidth): Likewise.
7151
7152         build: pull in conditional headers during GNULIB_POSIXCHECK
7153         * lib/stdio.in.h (includes): Using GNULIB_POSIXCHECK also requires
7154         definitions from any conditionally-included headers.
7155         * lib/stdlib.in.h (includes): Likewise.
7156         * lib/unistd.in.h (includes): Likewise.
7157
7158 2009-12-24  Bruno Haible  <bruno@clisp.org>
7159
7160         * tests/test-argv-iter.c: Include header file being tested immediately
7161         after config.h.
7162         * tests/test-base64.c: Likewise.
7163         * tests/test-flock.c: Likewise.
7164         * tests/test-fsync.c: Likewise.
7165         * tests/test-getdate.c: Likewise.
7166         * tests/test-getndelim2.c: Likewise.
7167         * tests/test-isfinite.c: Likewise.
7168         * tests/test-isinf.c: Likewise.
7169         * tests/test-strerror.c: Likewise.
7170         * tests/test-strsignal.c: Likewise.
7171
7172 2009-12-23  Eric Blake  <ebb9@byu.net>
7173
7174         unistd: work around cygwin bug
7175         * lib/unistd.in.h (includes): Pick up headers needed for cygwin.
7176         * doc/posix-functions/unlinkat.texi (unlinkat): Document the bug.
7177         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
7178
7179 2009-12-23  Bruno Haible  <bruno@clisp.org>
7180
7181         localename: More tests.
7182         * tests/test-localename.c (SIZEOF): New macro.
7183         (categories): New variable.
7184         (test_locale_name, test_locale_name_posix, test_locale_name_environ,
7185         test_locale_name_default): Add test w.r.t. thread locale.
7186         (test_locale_name_thread): New function.
7187         (main): Invoke it.
7188
7189         localename: Make aware of thread locale.
7190         * lib/localename.h (gl_locale_name_thread): New declaration.
7191         (gl_locale_name, gl_locale_name_posix, gl_locale_name_default): Clarify
7192         behaviour with respect to thread locale.
7193         * lib/localename.c: Include <limits.h>, <stddef.h>, <xlocale.h>,
7194         <langinfo.h>, glthread/lock.h.
7195         (SIZE_BITS): New macro.
7196         (string_hash): New function.
7197         (struct hash_node): New type.
7198         (HASH_TABLE_SIZE): New macro.
7199         (struniq_hash_table, struniq_lock): New variables.
7200         (struniq): New function.
7201         (gl_locale_name_thread): New function.
7202         (gl_locale_name): Invoke it.
7203         * m4/localename.m4 (gl_LOCALENAME): Test for uselocale function.
7204         * modules/localename (Depends-on): Add lock.
7205         Reported by Mike Gran <spk121@yahoo.com>.
7206
7207 2009-12-23  Eric Blake  <ebb9@byu.net>
7208
7209         va-args: new module
7210         * modules/va-args: New file.
7211         * m4/va-args.m4 (gl_VA_ARGS): Likewise.
7212         * MODULES.html.sh (Core language properties): Mention it.
7213
7214         gnulib-common: prefer _GL_UNUSED over _UNUSED_PARAMETER_
7215         * m4/gnulib-common.m4 (gl_COMMON): Create a more-appropriately
7216         named alias for __attribute__((__unused__)).
7217         * lib/chown.c: Update client.
7218         * lib/fchmodat.c: Likewise.
7219         * lib/fts.c: Likewise.
7220         * lib/getdate.y: Likewise.
7221         * lib/getgroups.c: Likewise.
7222         * lib/getopt.c: Likewise.
7223         * lib/getugroups.c: Likewise.
7224         * lib/mkdir.c: Likewise.
7225         * lib/mkfifo.c: Likewise.
7226         * lib/mkfifoat.c: Likewise.
7227         * lib/mknod.c: Likewise.
7228         * lib/mknodat.c: Likewise.
7229         * lib/readlink.c: Likewise.
7230         * lib/se-context.in.h: Likewise.
7231         * lib/se-selinux.in.h: Likewise.
7232         * lib/sockets.c: Likewise.
7233         * lib/symlink.c: Likewise.
7234         * lib/symlinkat.c: Likewise.
7235         * lib/unicodeio.c: Likewise.
7236         * lib/unistr.h: Likewise.
7237         * tests/test-areadlink.c: Likewise.
7238         * tests/test-areadlinkat.c: Likewise.
7239         * tests/test-filenamecat.c: Likewise.
7240         * tests/test-fseeko.c: Likewise.
7241         * tests/test-ftello.c: Likewise.
7242         * tests/test-getdate.c: Likewise.
7243         * tests/test-getgroups.c: Likewise.
7244         * tests/test-gethostname.c: Likewise.
7245         * tests/test-quotearg.c: Likewise.
7246         * tests/test-version-etc.c: Likewise.
7247         * tests/test-xalloc-die.c: Likewise.
7248         * tests/test-xfprintf-posix.c: Likewise.
7249         * tests/test-xprintf-posix.c: Likewise.
7250         * tests/test-xvasprintf.c: Likewise.
7251
7252         tests: avoid compiler warnings
7253         * tests/test-fcntl.c (main): Delete unused parameters.
7254         * tests/test-freopen-safer.c (main): Likewise.
7255         * tests/test-xalloc-die.c (main): Mark unused parameters.
7256         * tests/test-fseeko.c (main): Likewise.
7257         * tests/test-ftello.c (main): Likewise.
7258         * tests/test-nanosleep.c (main): Avoid declaration warning.
7259         * tests/test-sleep.c (main): Likewise.
7260         * tests/test-unsetenv.c (main): Silence warning about string
7261         literal.
7262         * m4/setenv.m4 (gl_FUNC_UNSETENV): Likewise.
7263
7264 2009-12-23  Bruno Haible  <bruno@clisp.org>
7265
7266         * tests/test-localename.c (test_locale_name): New function, extracted
7267         from main. Also test mixed situations.
7268         (test_locale_name_posix, test_locale_name_environ,
7269         test_locale_name_default): New functions.
7270         (main): Invoke them all.
7271         * modules/localename-tests (configure.ac): Test for newlocale.
7272
7273 2009-12-23  Bruno Haible  <bruno@clisp.org>
7274
7275         unistd: Ensure getcwd gets declared before being overridden.
7276         * lib/unistd.in.h: Conditionally include <io.h>.
7277
7278 2009-12-22  Bruno Haible  <bruno@clisp.org>
7279
7280         wchar: Diagnose broken combination of glibc and gcc versions and flags.
7281         * m4/wchar.m4 (gl_WCHAR_H_INLINE_OK): New macro.
7282         (gl_WCHAR_H): Invoke it.
7283         * m4/btowc.m4 (gl_FUNC_BTOWC): Require it.
7284         * doc/posix-headers/wchar.texi: Mention the interoperability problem.
7285         Reported by Karl Berry <karl@freefriends.org>.
7286
7287 2009-12-22  Eric Blake  <ebb9@byu.net>
7288
7289         math, unistd: avoid redundant includes
7290         * lib/math.in.h (isnan): No need to re-include <math.h>.
7291         * lib/unistd.in.h (getcwd): Likewise, for <stdlib.h>.
7292
7293         getsubopt: work around cygwin bug
7294         * lib/stdlib.in.h (includes): Move unistd inclusion sooner, to
7295         avoid conflicting with system getsubopt.
7296         * doc/posix-functions/getsubopt.texi (getsubopt): Document the
7297         bug.
7298
7299         getopt: synchronize from glibc
7300         * lib/getopt.c (_getopt_initialize, _getopt_internal_r): Swap
7301         parameter order.  Adjust all callers.
7302         (_getopt_internal_r, main): Adjust quoting in error messages.
7303         Drop considerations for outdated POSIX 1003.2 error message.
7304         * lib/getopt1.c (_getopt_long_r, _getopt_long_only_r): Adjust
7305         callers.
7306         * lib/getopt_int.h (_getopt_internal_r): Adjust prototype.
7307
7308         test-getopt: test stderr behavior
7309         * modules/getopt-posix-tests (Depends-on): Add dup2.
7310         * tests/test-getopt.c (ASSERT): Avoid stderr.
7311         (main): Move stderr to a temporary file.
7312         * tests/test-getopt.h (getopt_loop): No longer manipulate opterr.
7313         Instead, add parameter to inform caller if output occurred.
7314         (test_getopt): Adjust all existing tests to expect silence, and
7315         add new tests of leading ":".
7316         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
7317         glibc shortcomings with leading "-:" or "+:" in optstring.
7318         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
7319         Likewise.
7320         * doc/posix-functions/getopt.texi (getopt): Likewise.
7321
7322         test-getopt: enhance test
7323         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require that getopt_long
7324         supports optind=0.
7325         * tests/test-getopt.c (OPTIND_MIN): Move...
7326         * tests/test-getopt.h (OPTIND_MIN): ...here.
7327         * tests/test-getopt_long.h (test_getopt_long): Add more coverage.
7328         Require that optind=0 works, since modern BSD supports it in
7329         addition to optreset, and since coreutils expects it.
7330         (test_getopt_long_only): New test.
7331         * doc/glibc-functions/getopt_long.texi (getopt_long): Document
7332         glibc shortcomings with 'W;', and enforcement of optind=0.
7333         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
7334         Likewise.
7335
7336 2009-12-21  Bruno Haible  <bruno@clisp.org>
7337
7338         localename: Improvements for MacOS X and Cygwin.
7339         * lib/localename.h (gl_locale_name_environ): New declaration.
7340         * lib/localename.c (gl_locale_name_environ): New function, extracted from
7341         gl_locale_name_posix. Ignore dummy LANG values on MacOS X and Cygwin.
7342         (gl_locale_name_posix): Invoke it.
7343         (gl_locale_name_default): Add comments. Use Windows native API also on
7344         Cygwin.
7345
7346 2009-12-21  Bruno Haible  <bruno@clisp.org>
7347
7348         Update list of Win32 locale ids.
7349         * lib/localename.c (LANG_ROMANSH): Renamed from LANG_RHAETO_ROMANCE.
7350         (LANG_SAMI): Renamed from LANG_SAAMI.
7351         (LANG_BASHKIR, LANG_LUXEMBOURGISH, LANG_GREENLANDIC,
7352         LANG_MAPUDUNGUN, LANG_MOHAWK, LANG_BRETON, LANG_OCCITAN, LANG_CORSICAN,
7353         LANG_ALSATIAN, LANG_YAKUT, LANG_KICHE, LANG_KINYARWANDA, LANG_WOLOF,
7354         LANG_DARI, LANG_SCOTTISH_GAELIC): New macros.
7355         (SUBLANG_AFRIKAANS_SOUTH_AFRICA, SUBLANG_ALBANIAN_ALBANIA,
7356         SUBLANG_ALSATIAN_FRANCE, SUBLANG_AMHARIC_ETHIOPIA,
7357         SUBLANG_ARMENIAN_ARMENIA, SUBLANG_ASSAMESE_INDIA,
7358         SUBLANG_BASHKIR_RUSSIA, SUBLANG_BASQUE_BASQUE,
7359         SUBLANG_BELARUSIAN_BELARUS, SUBLANG_BRETON_FRANCE,
7360         SUBLANG_BULGARIAN_BULGARIA, SUBLANG_CAMBODIAN_CAMBODIA,
7361         SUBLANG_CATALAN_SPAIN, SUBLANG_CORSICAN_FRANCE,
7362         SUBLANG_CZECH_CZECH_REPUBLIC, SUBLANG_DANISH_DENMARK,
7363         SUBLANG_DARI_AFGHANISTAN, SUBLANG_DIVEHI_MALDIVES,
7364         SUBLANG_DUTCH_SURINAM, SUBLANG_ESTONIAN_ESTONIA,
7365         SUBLANG_FAEROESE_FAROE_ISLANDS, SUBLANG_FARSI_IRAN,
7366         SUBLANG_FINNISH_FINLAND, SUBLANG_FRISIAN_NETHERLANDS,
7367         SUBLANG_GALICIAN_SPAIN, SUBLANG_GEORGIAN_GEORGIA,
7368         SUBLANG_GREEK_GREECE, SUBLANG_GREENLANDIC_GREENLAND,
7369         SUBLANG_GUJARATI_INDIA, SUBLANG_HAUSA_NIGERIA_LATIN,
7370         SUBLANG_HEBREW_ISRAEL, SUBLANG_HINDI_INDIA, SUBLANG_HUNGARIAN_HUNGARY,
7371         SUBLANG_ICELANDIC_ICELAND, SUBLANG_IGBO_NIGERIA,
7372         SUBLANG_INDONESIAN_INDONESIA, SUBLANG_INUKTITUT_CANADA,
7373         SUBLANG_INUKTITUT_CANADA_LATIN, SUBLANG_IRISH_IRELAND,
7374         SUBLANG_JAPANESE_JAPAN, SUBLANG_KANNADA_INDIA,
7375         SUBLANG_KAZAK_KAZAKHSTAN, SUBLANG_KICHE_GUATEMALA,
7376         SUBLANG_KINYARWANDA_RWANDA, SUBLANG_KONKANI_INDIA,
7377         SUBLANG_KYRGYZ_KYRGYZSTAN, SUBLANG_LAO_LAOS, SUBLANG_LATVIAN_LATVIA,
7378         SUBLANG_LITHUANIAN_LITHUANIA, SUBLANG_LOWER_SORBIAN_GERMANY,
7379         SUBLANG_LUXEMBOURGISH_LUXEMBOURG, SUBLANG_MACEDONIAN_MACEDONIA,
7380         SUBLANG_MALAYALAM_INDIA, SUBLANG_MALTESE_MALTA,
7381         SUBLANG_MAORI_NEW_ZEALAND, SUBLANG_MAPUDUNGUN_CHILE,
7382         SUBLANG_MARATHI_INDIA, SUBLANG_MOHAWK_CANADA, SUBLANG_NEPALI_NEPAL,
7383         SUBLANG_OCCITAN_FRANCE, SUBLANG_ORIYA_INDIA,
7384         SUBLANG_PASHTO_AFGHANISTAN, SUBLANG_POLISH_POLAND,
7385         SUBLANG_ROMANSH_SWITZERLAND, SUBLANG_SAMI_NORTHERN_NORWAY,
7386         SUBLANG_SAMI_NORTHERN_SWEDEN, SUBLANG_SAMI_NORTHERN_FINLAND,
7387         SUBLANG_SAMI_LULE_NORWAY, SUBLANG_SAMI_LULE_SWEDEN,
7388         SUBLANG_SAMI_SOUTHERN_NORWAY, SUBLANG_SAMI_SOUTHERN_SWEDEN,
7389         SUBLANG_SAMI_SKOLT_FINLAND, SUBLANG_SAMI_INARI_FINLAND,
7390         SUBLANG_SANSKRIT_INDIA, SUBLANG_SINHALESE_SRI_LANKA,
7391         SUBLANG_SLOVAK_SLOVAKIA, SUBLANG_SLOVENIAN_SLOVENIA,
7392         SUBLANG_SOTHO_SOUTH_AFRICA, SUBLANG_SWAHILI_KENYA,
7393         SUBLANG_SWEDISH_SWEDEN, SUBLANG_SYRIAC_SYRIA,
7394         SUBLANG_TAGALOG_PHILIPPINES, SUBLANG_TAJIK_TAJIKISTAN,
7395         SUBLANG_TAMIL_INDIA, SUBLANG_TATAR_RUSSIA, SUBLANG_TELUGU_INDIA,
7396         SUBLANG_THAI_THAILAND, SUBLANG_TSWANA_SOUTH_AFRICA,
7397         SUBLANG_TURKISH_TURKEY, SUBLANG_TURKMEN_TURKMENISTAN,
7398         SUBLANG_UKRAINIAN_UKRAINE, SUBLANG_UPPER_SORBIAN_GERMANY,
7399         SUBLANG_VIETNAMESE_VIETNAM, SUBLANG_WELSH_UNITED_KINGDOM,
7400         SUBLANG_WOLOF_SENEGAL, SUBLANG_XHOSA_SOUTH_AFRICA,
7401         SUBLANG_YAKUT_RUSSIA, SUBLANG_YI_PRC, SUBLANG_YORUBA_NIGERIA,
7402         SUBLANG_ZULU_SOUTH_AFRICA): New macros.
7403         (gl_locale_name_from_win32_LANGID): Handle also the territory neutral
7404         locale ids. Add support for Alsatian, Bashkir, Breton, Corsican, Dari,
7405         Greenlandic, K'iche', Kinyarwanda, Luxembourgish, Mapudungun, Mohawk,
7406         Occitan, Scottish Gaelic, Wolof, Yakut. Change language code for Yi.
7407         Add more languages and countries for Sami, Sorbian. Add more countries
7408         for Serbian, Dutch. Add more scripts for Inuktitut. Be more precise
7409         for Pashto. Change country for Syriac, Tswana.
7410
7411 2009-12-21  Eric Blake  <ebb9@byu.net>
7412
7413         test-utimens: avoid spurious failure
7414         * tests/test-chown.h (nap): Factor...
7415         * tests/nap.h: ...into new file.
7416         * tests/test-lchown.h (nap): Avoid duplication.
7417         * tests/test-utimens-common.h (nap): Use shared implementation,
7418         necessary on file systems with 1-second resolution.
7419         * modules/chown-tests (Files): Include new file.
7420         * modules/fdutimensat-tests (Files): Likewise.
7421         * modules/futimens-tests (Files): Likewise.
7422         * modules/lchown-tests (Files): Likewise.
7423         * modules/openat-tests (Files): Likewise.
7424         * modules/utimens-tests (Files): Likewise.
7425         * modules/utimensat-tests (Files): Likewise.
7426
7427 2009-12-19  Eric Blake  <ebb9@byu.net>
7428
7429         futimens, utimensat: work around Linux bug
7430         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Detect ctime bug.
7431         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
7432         * lib/utimensat.c (rpl_utimensat): Work around it.
7433         * lib/futimens.c (rpl_futimens): Adjust comment.
7434
7435         utimens: work around Linux ctime bug
7436         * lib/utimens.c (detect_ctime_bug): New helper function.
7437         (update_timespec): Differentiate between workaround needed for
7438         this bug vs. what is needed for systems that lack utimensat.
7439         (fdutimens, lutimens): Work around bug.
7440
7441         utimens: check for ctime update
7442         * tests/test-utimens-common.h (check_ctime): Define.
7443         * tests/test-utimens.h (test_utimens): Expose the Linux bug.
7444         * tests/test-futimens.h (test_futimens): Likewise.
7445         * tests/test-lutimens.h (test_lutimens): Likewise.
7446         * doc/posix-functions/futimens.texi (futimens): Document the bug.
7447         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
7448
7449 2009-12-19  Bruno Haible  <bruno@clisp.org>
7450
7451         dprintf-posix: Check against memory leak fixed on 2009-12-15.
7452         * tests/test-dprintf-posix2.sh: New file.
7453         * tests/test-dprintf-posix2.c: New file.
7454         * modules/dprintf-posix-tests (Files): Add them.
7455         (configure.ac): Check for getrlimit and setrlimit.
7456         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
7457
7458 2009-12-19  Bruno Haible  <bruno@clisp.org>
7459
7460         fprintf-posix: Check against memory leak fixed on 2009-12-15.
7461         * tests/test-fprintf-posix3.sh: New file.
7462         * tests/test-fprintf-posix3.c: New file.
7463         * modules/fprintf-posix-tests (Files): Add them.
7464         (Makefile.am): Augment TESTS and CHECK_PROGRAMS.
7465
7466 2009-12-19  Eric Blake  <ebb9@byu.net>
7467
7468         dirfd: fix prototype
7469         * lib/dirent.in.h (dirfd): Argument is not const, per POSIX.
7470         * lib/dirfd.c (dirfd): Likewise.
7471
7472         canonicalize: reduce memory usage
7473         * lib/canonicalize.c (canonicalize_filename_mode): Trim the
7474         allocation to size.
7475         Reported by Solar Designer <solar@openwall.com>.
7476
7477 2009-12-19  Bruno Haible  <bruno@clisp.org>
7478
7479         New module attribute 'Applicability'.
7480         * modules/TEMPLATE-EXTENDED: New field 'Applicability'.
7481         * gnulib-tool: New option --extract-applicability.
7482         (func_usage): Document it.
7483         (sed_extract_prog): Recognize it.
7484         (func_get_applicability): New function.
7485         (func_import): Generalize handling of 'link-warning' module.
7486         * modules/link-warning (Applicability): New section.
7487         * modules/arg-nonnull (Applicability): New section.
7488         Repoted by Simon Josefsson <simon@josefsson.org>.
7489
7490 2009-12-19  Bruno Haible  <bruno@clisp.org>
7491
7492         fflush: tweak
7493         * lib/fflush.c (update_fpos_cache): Don't use fpos_t on Cygwin.
7494         * lib/fseeko.c (rpl_fseeko): Likewise.
7495
7496 2009-12-16  José E. Marchesi  <jemarch@gnu.org>  (tiny change)
7497
7498         * lib/gl_list.h: Fix typo in comment.
7499
7500 2009-12-16  Eric Blake  <ebb9@byu.net>
7501
7502         fcntl: use to simplify other modules
7503         * modules/cloexec (Depends-on): Add fcntl.
7504         * modules/fchdir (Depends-on): Likewise.
7505         * modules/fd-safer-flag (Depends-on): Likewise.
7506         * modules/unistd-safer (Depends-on): Likewise.
7507         * modules/dup3 (configure.ac): Set module indicator.
7508         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Replace fcntl if fchdir is
7509         missing.
7510         * lib/fchdir.c (_gl_register_dup): Fix comment.
7511         * lib/cloexec.c (dup_cloexec): Simplify, by relying on fcntl.
7512         * lib/dup-safer.c (dup_safer): Likewise.
7513         * lib/dup-safer-flag.c (dup_safer_flag): Likewise.
7514         * lib/dup3.c (dup3): Likewise.
7515         * tests/test-fchdir.c (main): Enhance test.
7516         Fixes a dup_cloexec bug reported by Ondřej Vašík.
7517
7518         fcntl: port portions of fcntl to mingw
7519         * m4/fcntl.m4 (gl_FUNC_FCNTL): Also build fcntl.c on mingw.
7520         * lib/fcntl.c (fcntl) <F_DUPFD, F_DUPFD_CLOEXEC, F_GETFD>: Provide
7521         replacement for mingw.
7522         * modules/fcntl (Description): Update.
7523         (Depends-on): Add dup2.
7524         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness.
7525         * modules/fcntl-h (Makefile.am): Substitute it.
7526         * lib/fcntl.in.h (fcntl): Update declaration.
7527         (F_DUPFD, F_GETFD): New macros, when needed.
7528         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
7529         * doc/posix-functions/fcntl.texi (fcntl): Likewise.
7530         * tests/test-fcntl.c (check_flags, main): Enhance test for items
7531         we now guarantee.
7532
7533         fcntl: work around cygwin bug in F_DUPFD
7534         * m4/fcntl.m4 (gl_REPLACE_FCNTL): New macro.
7535         (gl_FUNC_FCNTL): Use it.  Test for F_DUPFD bug.
7536         * lib/fcntl.c (rpl_fcntl) <F_DUPFD>: Work around it.
7537         <F_DUPFD_CLOEXEC>: Reduce calls to _gl_register_dup.
7538         * doc/posix-functions/fcntl.texi (fcntl): Document it.
7539
7540         fcntl: support F_DUPFD_CLOEXEC on systems with fcntl
7541         * modules/fcntl (Files): List new files.
7542         (configure.ac): Run a test.
7543         * m4/fcntl.m4 (gl_FUNC_FCNTL): New file.
7544         * lib/fcntl.c (rpl_fcntl): Likewise.
7545         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Add witness defaults.
7546         (gl_FCNTL_H): Always replace fcntl.h.
7547         * modules/fcntl-h (Makefile.am): Substitute witnesses.
7548         * lib/fcntl.in.h (fcntl): Declare replacement.
7549         (F_DUPFD_CLOEXEC, GNULIB_defined_F_DUPFD_CLOEXEC): New macro when
7550         needed, plus a witness.
7551         * doc/posix-functions/fcntl.texi (fcntl): Document this.
7552         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
7553         * tests/test-fcntl.c: New file.
7554         * modules/fcntl-tests: Likewise.
7555
7556         binary-io: avoid potential compilation warning
7557         * lib/binary-io.h [__DJGPP__]: Avoid null preprocessor
7558         directives.
7559
7560         fflush: avoid compilation error on NetBSD
7561         * lib/fflush.c (update_fpos_cache): Use a union to safely convert
7562         between off_t and fpos_t, since the latter is sometimes a struct.
7563         * lib/fseeko.c (rpl_fseeko): Likewise.
7564         Reported by Alexander Nasonov <alnsn@yandex.ru>.
7565
7566 2009-12-15  Eric Blake  <ebb9@byu.net>
7567
7568         fcntl-h, stdio, sys_ioctl: fix declarations
7569         * lib/stdio.in.h (dprintf): Use of link warning on a variadic
7570         function must not take arguments.
7571         * lib/sys_ioctl.in.h (ioctl): Likewise.
7572         * lib/fcntl.in.h (openat): Likewise.  Declare extern.
7573         (open): Add a link warning.
7574
7575 2009-12-15  Jim Meyering  <meyering@redhat.com>
7576
7577         areadlink, areadlink-with-size: relax license to LGPLv2+
7578         * modules/areadlink (License): Relax to LGPLv2+.
7579         * modules/areadlink-with-size (License): Likewise.
7580
7581 2009-12-15  Joel E. Denny  <jdenny@clemson.edu>
7582             Bruno Haible  <bruno@clisp.org>
7583
7584         *printf: Fix memory leak.
7585         * lib/fprintf.c (fprintf): Free memory allocated by vasnprintf.
7586         * lib/vfprintf.c (vfprintf): Likewise.
7587         * lib/dprintf.c (dprintf): Likewise.
7588         * lib/vdprintf.c (vdprintf): Likewise.
7589
7590 2009-12-14  Eric Blake  <ebb9@byu.net>
7591
7592         accept4: adjust module dependencies
7593         * modules/accept4 (Depends-on): Use fcntl-h, not fcntl.
7594
7595         utimens: one more try at avoiding compiler warning
7596         * lib/utimens.c (lutimens): Lower scope of result.
7597
7598 2009-12-13  Bruno Haible  <bruno@clisp.org>
7599
7600         Move the malloc checking from module 'list' to new module 'xlist'.
7601         * modules/xlist: New file.
7602         * lib/gl_xlist.h: New file.
7603         * lib/gl_xlist.c: New file.
7604         * lib/gl_list.h (gl_list_create_empty, gl_list_create,
7605         gl_list_node_set_value, gl_list_set_at, gl_list_add_first,
7606         gl_list_add_last, gl_list_add_before, gl_list_add_after,
7607         gl_list_nx_add_at, gl_sortedlist_add): Disable declarations.
7608         (gl_list_nx_create_empty, gl_list_nx_create, gl_list_node_nx_set_value,
7609         gl_list_nx_set_at, gl_list_nx_add_first, gl_list_nx_add_last,
7610         gl_list_nx_add_before, gl_list_nx_add_after, gl_list_nx_add_at,
7611         gl_sortedlist_nx_add): New declarations.
7612         (struct gl_list_implementation): Rename and change methods accordingly.
7613         (gl_list_nx_create_empty): Renamed from gl_list_create_empty.
7614         (gl_list_nx_create): Renamed from gl_list_create.
7615         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
7616         (gl_list_nx_set_at): Renamed from gl_list_set_at.
7617         (gl_list_nx_add_first): Renamed from gl_list_add_first.
7618         (gl_list_nx_add_last): Renamed from gl_list_add_last.
7619         (gl_list_nx_add_before): Renamed from gl_list_add_before.
7620         (gl_list_nx_add_after): Renamed from gl_list_add_after.
7621         (gl_list_nx_add_at): Renamed from gl_list_add_at.
7622         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
7623         * lib/gl_list.c (gl_list_nx_create_empty): Renamed from
7624         gl_list_create_empty.
7625         (gl_list_nx_create): Renamed from gl_list_create.
7626         (gl_list_node_nx_set_value): Renamed from gl_list_node_set_value.
7627         (gl_list_nx_set_at): Renamed from gl_list_set_at.
7628         (gl_list_nx_add_first): Renamed from gl_list_add_first.
7629         (gl_list_nx_add_last): Renamed from gl_list_add_last.
7630         (gl_list_nx_add_before): Renamed from gl_list_add_before.
7631         (gl_list_nx_add_after): Renamed from gl_list_add_after.
7632         (gl_list_nx_add_at): Renamed from gl_list_add_at.
7633         (gl_sortedlist_nx_add): Renamed from gl_sortedlist_add.
7634         * lib/gl_array_list.c: Don't include xalloc.h.
7635         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Return
7636         NULL upon out-of-memory.
7637         (gl_array_nx_create): Renamed from gl_array_create. Return NULL upon
7638         out-of-memory.
7639         (gl_array_node_nx_set_value): Renamed from gl_array_node_set_value.
7640         Change return type to 'int'.
7641         (gl_array_nx_set_at): Renamed from gl_array_set_at.
7642         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
7643         (gl_array_nx_add_first): Renamed from gl_array_add_first. Return NULL
7644         upon out-of-memory.
7645         (gl_array_nx_add_last): Renamed from gl_array_add_last. Return NULL
7646         upon out-of-memory.
7647         (gl_array_nx_add_before): Renamed from gl_array_add_before. Return NULL
7648         upon out-of-memory.
7649         (gl_array_nx_add_after): Renamed from gl_array_add_after. Return NULL
7650         upon out-of-memory.
7651         (gl_array_nx_add_at): Renamed from gl_array_add_at. Return NULL upon
7652         out-of-memory.
7653         (gl_array_sortedlist_nx_add): Renamed from gl_array_sortedlist_add.
7654         Update.
7655         (gl_array_list_implementation): Update.
7656         * lib/gl_carray_list.c: Don't include xalloc.h.
7657         (gl_carray_nx_create_empty): Renamed from gl_carray_create_empty.
7658         Return NULL upon out-of-memory.
7659         (gl_carray_nx_create): Renamed from gl_carray_create. Return NULL upon
7660         out-of-memory.
7661         (gl_carray_node_nx_set_value): Renamed from gl_carray_node_set_value.
7662         Change return type to 'int'.
7663         (gl_carray_nx_set_at): Renamed from gl_carray_set_at.
7664         (grow): Change return type to 'int'. Return -1 upon out-of-memory.
7665         (gl_carray_nx_add_first): Renamed from gl_carray_add_first. Return NULL
7666         upon out-of-memory.
7667         (gl_carray_nx_add_last): Renamed from gl_carray_add_last. Return NULL
7668         upon out-of-memory.
7669         (gl_carray_nx_add_at): Renamed from gl_carray_add_at. Return NULL upon
7670         out-of-memory.
7671         (gl_carray_nx_add_before): Renamed from gl_carray_add_before. Update.
7672         (gl_carray_nx_add_after): Renamed from gl_carray_add_after. Update.
7673         (gl_carray_sortedlist_nx_add): Renamed from gl_carray_sortedlist_add.
7674         Update.
7675         (gl_carray_list_implementation): Update.
7676         * lib/gl_anyhash_list2.h (hash_resize): Do nothing upon out-of-memory.
7677         * lib/gl_anylinked_list2.h (gl_linked_nx_create_empty): Renamed from
7678         gl_linked_create_empty. Return NULL upon out-of-memory.
7679         (gl_linked_nx_create): Renamed from gl_linked_create. Return NULL upon
7680         out-of-memory.
7681         (gl_linked_node_nx_set_value): Renamed from gl_linked_node_set_value.
7682         Change return type to 'int'. Return -1 upon out-of-memory.
7683         (gl_linked_nx_set_at): Renamed from gl_linked_set_at. Return NULL upon
7684         out-of-memory.
7685         (gl_linked_nx_add_first): Renamed from gl_linked_add_first. Return NULL
7686         upon out-of-memory.
7687         (gl_linked_nx_add_last): Renamed from gl_linked_add_last. Return NULL
7688         upon out-of-memory.
7689         (gl_linked_nx_add_before): Renamed from gl_linked_add_before. Return
7690         NULL upon out-of-memory.
7691         (gl_linked_nx_add_after): Renamed from gl_linked_add_after. Return NULL
7692         upon out-of-memory.
7693         (gl_linked_nx_add_at): Renamed from gl_linked_add_at. Return NULL upon
7694         out-of-memory.
7695         (gl_linked_sortedlist_nx_add): Renamed from gl_linked_sortedlist_add.
7696         Update.
7697         * lib/gl_linked_list.c: Don't include xalloc.h.
7698         (gl_linked_list_implementation): Update.
7699         * lib/gl_linkedhash_list.c: Don't include xalloc.h.
7700         (add_to_bucket): Change return type to 'int'.
7701         (gl_linkedhash_list_implementation): Update.
7702         * lib/gl_anytree_list1.h (free_subtree): New function.
7703         * lib/gl_anytree_list2.h (gl_tree_nx_create_empty): Renamed from
7704         gl_tree_create_empty. Return NULL upon out-of-memory.
7705         (gl_tree_node_nx_set_value): Renamed from gl_tree_node_set_value.
7706         Change return type to 'int'. Return -1 upon out-of-memory.
7707         (gl_tree_nx_set_at): Renamed from gl_tree_set_at. Return NULL upon
7708         out-of-memory.
7709         (gl_tree_nx_add_at): Renamed from gl_tree_add_at. Update.
7710         (gl_tree_remove_node): New function, moved here from
7711         lib/gl_anyavltree_list2.h and lib/gl_anyrbtree_list2.h.
7712         (gl_tree_sortedlist_nx_add): Renamed from gl_tree_sortedlist_add.
7713         Update.
7714         * lib/gl_anyavltree_list2.h (create_subtree_with_contents): Use
7715         malloc, not xmalloc. Return NULL upon out-of-memory.
7716         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
7717         out-of-memory.
7718         (gl_tree_remove_node_from_tree): New function, extracted from
7719         gl_tree_remove_node.
7720         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
7721         upon out-of-memory.
7722         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
7723         out-of-memory.
7724         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
7725         upon out-of-memory.
7726         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
7727         upon out-of-memory.
7728         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
7729         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents): Use malloc,
7730         not xmalloc. Return NULL upon out-of-memory.
7731         (gl_tree_nx_create): Renamed from gl_tree_create. Return NULL upon
7732         out-of-memory.
7733         (gl_tree_remove_node_from_tree): New function, extracted from
7734         gl_tree_remove_node.
7735         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Return NULL
7736         upon out-of-memory.
7737         (gl_tree_nx_add_last): Renamed from gl_tree_add_last. Return NULL upon
7738         out-of-memory.
7739         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Return NULL
7740         upon out-of-memory.
7741         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Return NULL
7742         upon out-of-memory.
7743         (gl_tree_remove_node): Remove function. Moved to gl_anytree_list2.h.
7744         * lib/gl_avltree_list.c: Don't include xalloc.h. Include
7745         gl_anytree_list1.h before gl_anyavltree_list2.h.
7746         (gl_avltree_list_implementation): Update.
7747         * lib/gl_rbtree_list.c: Don't include xalloc.h. Include
7748         gl_anytree_list1.h before gl_anyavltree_list2.h.
7749         (gl_rbtree_list_implementation): Update.
7750         * lib/gl_anytreehash_list1.h (add_to_bucket, add_nodes_to_buckets):
7751         Change return type to 'int'. Return -1 upon out-of-memory. Use
7752         __builtin_expect.
7753         * lib/gl_avltreehash_list.c: Don't include xalloc.h.
7754         (gl_avltreehash_list_implementation): Update.
7755         * lib/gl_rbtreehash_list.c: Don't include xalloc.h.
7756         (gl_rbtreehash_list_implementation): Update.
7757         * modules/array-list (Depends-on): Remove xalloc.
7758         * modules/carray-list (Depends-on): Likewise.
7759         * modules/linked-list (Depends-on): Likewise.
7760         * modules/linkedhash-list (Depends-on): Likewise.
7761         * modules/avltree-list (Depends-on): Likewise.
7762         * modules/rbtree-list (Depends-on): Likewise.
7763         * modules/avltreehash-list (Depends-on): Likewise.
7764         * modules/rbtreehash-list (Depends-on): Likewise.
7765
7766         * modules/xsublist: New file.
7767         * lib/gl_xsublist.h: New file.
7768         * lib/gl_xsublist.c: New file.
7769         * lib/gl_sublist.h (gl_sublist_create): Disable declaration.
7770         (gl_sublist_nx_create): New declaration.
7771         * lib/gl_sublist.c: Don't include xalloc.h.
7772         (gl_sublist_nx_create_empty): Renamed from gl_sublist_create_empty.
7773         (gl_sublist_nx_create_fill): Renamed from gl_sublist_create_fill.
7774         (gl_sublist_node_nx_set_value): Renamed from gl_sublist_node_set_value.
7775         Change return type to 'int'. Return -1 upon out-of-memory.
7776         (gl_sublist_nx_set_at): Renamed from gl_sublist_set_at. Return NULL
7777         upon out-of-memory.
7778         (gl_sublist_nx_add_first): Renamed from gl_sublist_add_first. Return
7779         NULL upon out-of-memory.
7780         (gl_sublist_nx_add_last): Renamed from gl_sublist_add_last. Return NULL
7781         upon out-of-memory.
7782         (gl_sublist_nx_add_before): Renamed from gl_sublist_add_before. Return
7783         NULL upon out-of-memory.
7784         (gl_sublist_nx_add_after): Renamed from gl_sublist_add_after. Return
7785         NULL upon out-of-memory.
7786         (gl_sublist_nx_add_at): Renamed from gl_sublist_add_at. Return NULL
7787         upon out-of-memory.
7788         (gl_sublist_sortedlist_nx_add): Renamed from gl_sublist_sortedlist_add.
7789         (gl_sublist_list_implementation): Update.
7790         (gl_sublist_nx_create): Renamed from gl_sublist_create. Return NULL
7791         upon out-of-memory.
7792         * modules/sublist (Depends-on): Remove xalloc.
7793
7794         * tests/test-array_list.c: Use gl_list_nx_* functions where possible.
7795         * tests/test-carray_list.c: Likewise.
7796         * tests/test-linked_list.c: Likewise.
7797         * tests/test-linkedhash_list.c: Likewise.
7798         * tests/test-avltree_list.c: Likewise.
7799         * tests/test-rbtree_list.c: Likewise.
7800         * tests/test-avltreehash_list.c: Likewise.
7801         * tests/test-rbtreehash_list.c: Likewise.
7802         * modules/array-list-tests (Makefile.am): Don't link with @LIBINTL@.
7803         * modules/carray-list-tests (Makefile.am): Likewise.
7804         * modules/linked-list-tests (Makefile.am): Likewise.
7805         * modules/linkedhash-list-tests (Makefile.am): Likewise.
7806         * modules/avltree-list-tests (Makefile.am): Likewise.
7807         * modules/rbtree-list-tests (Makefile.am): Likewise.
7808         * modules/avltreehash-list-tests (Makefile.am): Likewise.
7809         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
7810
7811         * NEWS: Mention the changes.
7812
7813         * lib/clean-temp.c: Include gl_xlist.h.
7814         * modules/clean-temp (Depends-on): Add xlist.
7815
7816         * lib/git-merge-changelog.c: Include gl_xlist.h instead of gl_list.h.
7817         * modules/git-merge-changelog (Depends-on): Add xlist. Remove list.
7818
7819         * tests/test-array_oset.c: Include gl_xlist.h.
7820         * modules/array-oset-tests (Depends-on): Add xlist.
7821
7822         Reported by José E. Marchesi <jemarch@gnu.org>.
7823
7824 2009-12-13  Bruno Haible  <bruno@clisp.org>
7825
7826         Move the malloc checking from module 'oset' to new module 'xoset'.
7827         * modules/xoset: New file.
7828         * lib/gl_xoset.h: New file.
7829         * lib/gl_xoset.c: New file.
7830         * lib/gl_oset.h (gl_oset_create_empty, gl_oset_add): Disable
7831         declarations.
7832         (gl_oset_nx_create_empty, gl_oset_nx_add): New declarations.
7833         (struct gl_oset_implementation): Rename and change methods accordingly.
7834         (gl_oset_nx_create_empty): Renamed from gl_oset_create_empty.
7835         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
7836         'int'. Mark as __warn_unused_result__.
7837         * lib/gl_oset.c (gl_oset_nx_create_empty): Renamed from
7838         gl_oset_create_empty.
7839         (gl_oset_nx_add): Renamed from gl_oset_add. Change return type to
7840         'int'.
7841         * lib/gl_array_oset.c: Don't include xalloc.h.
7842         (gl_array_nx_create_empty): Renamed from gl_array_create_empty. Use
7843         malloc, not xmalloc.
7844         (grow): Change return type to 'int'. Don't call xalloc_die.
7845         (gl_array_nx_add_at): Renamed from gl_array_add_at. Change return type
7846         to 'int'.
7847         (gl_array_nx_add): Renamed from gl_array_add. Change return type to
7848         'int'.
7849         (gl_array_oset_implementation): Update.
7850         * lib/gl_anytree_oset.h (gl_tree_nx_create_empty): Renamed from
7851         gl_tree_create_empty.
7852         (gl_tree_nx_add): Renamed from gl_tree_add. Change return type to
7853         'int'.
7854         * lib/gl_avltree_oset.c: Don't include xalloc.h.
7855         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
7856         xmalloc.
7857         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
7858         not xmalloc.
7859         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
7860         xmalloc.
7861         (gl_avltree_oset_implementation): Update.
7862         * lib/gl_rbtree_oset.c: Don't include xalloc.h.
7863         (gl_tree_nx_add_first): Renamed from gl_tree_add_first. Use malloc, not
7864         xmalloc.
7865         (gl_tree_nx_add_before): Renamed from gl_tree_add_before. Use malloc,
7866         not xmalloc.
7867         (gl_tree_nx_add_after): Renamed from gl_tree_add_after. Use malloc, not
7868         xmalloc.
7869         (gl_rbtree_oset_implementation): Update.
7870         * modules/array-oset (Depends-on): Remove xalloc.
7871         * modules/avltree-oset (Depends-on): Likewise.
7872         * modules/rbtree-oset (Depends-on): Likewise.
7873         * tests/test-array_oset.c: Use gl_oset_nx_* functions where possible.
7874         * tests/test-avltree_oset.c: Likewise.
7875         * tests/test-rbtree_oset.c: Likewise.
7876         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
7877         * modules/avltree-oset-tests (Makefile.am): Don't link with @LIBINTL@.
7878         * modules/rbtree-oset-tests (Makefile.am): Likewise.
7879         * NEWS: Mention the change.
7880
7881 2009-12-05  Alfred M. Szmidt  <ams@gnu.org>
7882
7883         maint.mk: allow a project to override release-prep commands
7884         * top/maint.mk (alpha, beta, stable): Move release-preparatory
7885         commands into a new rule.
7886         (release-prep): New rule.
7887         (release-prep-hook): New overridable variable.
7888
7889 2009-12-13  Bruno Haible  <bruno@clisp.org>
7890
7891         * lib/localcharset.c (locale_charset): Fix comment about use of GetACP.
7892
7893 2009-12-13  Jim Meyering  <meyering@redhat.com>
7894
7895         maint.mk (null_AM_MAKEFLAGS, built_programs): remove unused definitions
7896         * top/maint.mk (null_AM_MAKEFLAGS, built_programs): Remove definitions.
7897
7898 2009-12-12  Bruno Haible  <bruno@clisp.org>
7899
7900         duplocale: Tweak.
7901         * lib/duplocale.c (rpl_duplocale): Mark categories array as 'const'.
7902
7903 2009-12-12  Karl Berry  <karl@gnu.org>
7904
7905         * config/srclist.txt (strtoll.c): tab changes, no more sync.
7906
7907 2009-12-12  Bruno Haible  <bruno@clisp.org>
7908
7909         * m4/po.m4: Undo incorrect untabification.
7910
7911 2009-12-12  Bruno Haible  <bruno@clisp.org>
7912
7913         c-strtod, c-strtold: Use multithread-safe implementation on MacOS X.
7914         * modules/c-strtod (Depends-on): Add locale.
7915         * modules/c-strtold (Depends-on): Likewise.
7916
7917 2009-12-12  Bruno Haible  <bruno@clisp.org>
7918
7919         * lib/localcharset.c (locale_charset): Add comment about use of GetACP.
7920
7921 2009-12-11  Eric Blake  <ebb9@byu.net>
7922
7923         setenv: relax requirement in light of POSIX ruling
7924         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): Test handling of "" but
7925         not NULL.
7926         * tests/test-setenv.c (main): Relax test.
7927         * tests/test-unsetenv.c (main): Likewise.
7928         * doc/posix-functions/setenv.texi (setenv): Document this.
7929         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
7930
7931 2009-12-11  Bruno Haible  <bruno@clisp.org>
7932
7933         New module 'fd-safer-flag'.
7934         * lib/dup-safer-flag.c: New file, extracted from lib/dup-safer.c.
7935         * lib/dup-safer.c (dup_safer_flag): Remove function.
7936         * lib/fd-safer-flag.c: New file, extracted from lib/fd-safer.c.
7937         * lib/fd-safer.c (fd_safer_flag): Remove function.
7938         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): Update condition.
7939         * modules/cloexec (configure.ac): Drop indicator macro.
7940         * modules/fd-safer-flag: New file.
7941         * modules/pipe2-safer (Depends-on): Add fd-safer-flag. Remove cloexec.
7942         * modules/stdlib-safer (Depends-on): Add fd-safer-flag.
7943         * modules/unistd-safer-tests (Depends-on): Add fd-safer-flag.
7944
7945 2009-12-11  Bruno Haible  <bruno@clisp.org>
7946
7947         Tests for module 'nl_langinfo'.
7948         * modules/nl_langinfo-tests: New file.
7949         * tests/test-nl_langinfo.sh: New file.
7950         * tests/test-nl_langinfo.c: New file.
7951
7952         New module 'nl_langinfo'.
7953         * lib/nl_langinfo.c: New file.
7954         * m4/nl_langinfo.m4: New file.
7955         * modules/nl_langinfo: New file.
7956         * doc/posix-functions/nl_langinfo.texi: Mention the new module.
7957
7958 2009-12-11  Bruno Haible  <bruno@clisp.org>
7959
7960         Tests for module 'langinfo'.
7961         * modules/langinfo-tests: New file.
7962         * tests/test-langinfo.c: New file.
7963
7964         New module 'langinfo'.
7965         * lib/langinfo.in.h: New file.
7966         * m4/langinfo_h.m4: New file.
7967         * modules/langinfo: New file.
7968         * doc/posix-headers/langinfo.texi: Mention the new module.
7969
7970 2009-12-11  Bruno Haible  <bruno@clisp.org>
7971
7972         * lib/config.charset: Untabify.
7973
7974 2009-12-11  Bruno Haible  <bruno@clisp.org>
7975
7976         * modules/unistd-safer (configure.ac): Drop indicator macro.
7977
7978 2009-12-11  Bruno Haible  <bruno@clisp.org>
7979
7980         Move pipe2-safer code to its own file.
7981         * lib/pipe2-safer.c: New file, extracted from lib/pipe-safer.c.
7982         * lib/pipe-safer.c (pipe2_safer): Remove function.
7983         * modules/pipe2-safer (Files): Add lib/pipe2-safer.c.
7984         (Makefile.am): Add it to lib_SOURCES.
7985
7986 2009-12-10  Bruno Haible  <bruno@clisp.org>
7987
7988         * lib/recvfrom.c (rpl_recvfrom): Allow the from argument to be NULL.
7989
7990 2009-12-10  Bruno Haible  <bruno@clisp.org>
7991
7992         Declare which arguments expect non-NULL values, for GCC and clang.
7993         * build-aux/arg-nonnull.h: New file.
7994         * modules/arg-nonnull: New file.
7995         * lib/arpa_inet.in.h (_GL_ARG_NONNULL): New placeholder.
7996         (inet_ntop, inet_pton): Use it.
7997         * lib/dirent.in.h (_GL_ARG_NONNULL): New placeholder.
7998         (closedir, dirfd, opendir, scandir, alphasort): Use it.
7999         * lib/fcntl.in.h (_GL_ARG_NONNULL): New placeholder.
8000         (open, openat): Use it.
8001         * lib/fnmatch.in.h (_GL_ARG_NONNULL): New placeholder.
8002         (fnmatch): Use it.
8003         * lib/getopt.in.h (_GL_ARG_NONNULL): New placeholder.
8004         (getopt, getopt_long, getopt_long_only): Use it.
8005         * lib/glob.in.h (_GL_ARG_NONNULL): New placeholder.
8006         * lib/glob-libc.h (glob, globfree, glob64, globfree64, glob_pattern_p):
8007         Use it.
8008         * lib/iconv.in.h (_GL_ARG_NONNULL): New placeholder.
8009         (iconv_open): Use it.
8010         * lib/inttypes.in.h (_GL_ARG_NONNULL): New placeholder.
8011         (strtoimax, strtoumax): Use it.
8012         * lib/locale.in.h (_GL_ARG_NONNULL): New placeholder.
8013         (duplocale): Use it.
8014         * lib/math.in.h (_GL_ARG_NONNULL): New placeholder.
8015         (frexp, frexpl): Use it.
8016         * lib/netdb.in.h (_GL_ARG_NONNULL): New placeholder.
8017         (getaddrinfo, freeaddrinfo, getnameinfo): Use it.
8018         * lib/search.in.h (_GL_ARG_NONNULL): New placeholder.
8019         (tsearch, tfind, tdelete, twalk): Use it.
8020         * lib/signal.in.h (_GL_ARG_NONNULL): New placeholder.
8021         (sigismember, sigemptyset, sigaddset, sigdelset, sigfillset,
8022         sigpending): Use it.
8023         * lib/spawn.in.h (_GL_ARG_NONNULL): New placeholder.
8024         (posix_spawn, posix_spawnp, posix_spawnattr_init,
8025         posix_spawnattr_destroy, posix_spawnattr_getsigdefault,
8026         posix_spawnattr_setsigdefault, posix_spawnattr_getsigmask,
8027         posix_spawnattr_setsigmask, posix_spawnattr_getflags,
8028         posix_spawnattr_setflags, posix_spawnattr_getpgroup,
8029         posix_spawnattr_setpgroup, posix_spawnattr_getschedpolicy,
8030         posix_spawnattr_setschedpolicy, posix_spawnattr_getschedparam,
8031         posix_spawnattr_setschedparam, posix_spawn_file_actions_init,
8032         posix_spawn_file_actions_destroy, posix_spawn_file_actions_addopen,
8033         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2):
8034         Use it.
8035         * lib/stdio.in.h (_GL_ARG_NONNULL): New placeholder.
8036         (dprintf, fclose, fopen, fprintf, fpurge, fputc, fputs, freopen,
8037         rpl_fseek, fseeko, rpl_ftell, ftello, fwrite, getdelim, getline,
8038         obstack_printf, obstack_vprintf, popen, printf, putc, puts, remove,
8039         rename, renameat, snprintf, sprintf, asprintf, vasprintf, vdprintf,
8040         vfprintf, vprintf, vsnprintf, vsprintf): Use it.
8041         * lib/stdlib.in.h (_GL_ARG_NONNULL): New placeholder.
8042         (atoll, canonicalize_file_name, getloadavg, getsubopt, mkdtemp,
8043         mkostemp, mkostemps, mkstemp, mkstemps, putenv, srandom_r, initstate_r,
8044         setstate_r, random_r, realpath, rpmatch, setenv, strtod, strtoll,
8045         strtoull, unsetenv): Use it.
8046         * lib/string.in.h (_GL_ARG_NONNULL): New placeholder.
8047         (memchr, memmem, mempcpy, memrchr, rawmemchr, stpcpy, stpncpy,
8048         strchrnul, strdup, strndup, strnlen, strpbrk, strsep, strstr,
8049         strcasestr, strtok_r, mbslen, mbsnlen, mbschr, mbsrchr, mbsstr,
8050         mbscasecmp, mbsncasecmp, mbspcasecmp, mbscasestr, mbscspn, mbspbrk,
8051         mbsspn, mbssep, mbstok_r, strverscmp): Use it.
8052         * lib/strings.in.h (_GL_ARG_NONNULL): New placeholder.
8053         (strcasecmp, strncasecmp): Use it.
8054         * lib/sys_socket.in.h (_GL_ARG_NONNULL): New placeholder.
8055         (rpl_connect, rpl_bind, rpl_getpeername, rpl_getsockname,
8056         rpl_getsockopt, rpl_recv, rpl_send, rpl_recvfrom, rpl_sendto,
8057         rpl_setsockopt): Use it.
8058         * lib/sys_stat.in.h (_GL_ARG_NONNULL): New placeholder.
8059         (fchmodat, fstat, fstatat, lchmod, rpl_lstat, mkdir, mkdirat, mkfifo,
8060         mkfifoat, mknod, mknodat, stat, utimensat): Use it.
8061         * lib/sys_time.in.h (_GL_ARG_NONNULL): New placeholder.
8062         (gettimeofday): Use it.
8063         * lib/sys_times.in.h (_GL_ARG_NONNULL): New placeholder.
8064         (times): Use it.
8065         * lib/sys_utsname.in.h (_GL_ARG_NONNULL): New placeholder.
8066         (uname): Use it.
8067         * lib/time.in.h (_GL_ARG_NONNULL): New placeholder.
8068         (nanosleep, mktime, localtime_r, gmtime_r, strptime, timegm): Use it.
8069         * lib/unistd.in.h (_GL_ARG_NONNULL): New placeholder.
8070         (chown, euidaccess, faccessat, _gl_register_fd, fchownat,
8071         getdomainname, gethostname, getlogin_r, lchown, link, linkat, pipe2,
8072         pread, readlink, readlinkat, rmdir, symlink, symlinkat, unlink,
8073         unlinkat, write): Use it.
8074         * lib/wchar.in.h (_GL_ARG_NONNULL): New placeholder.
8075         (mbsrtowcs, mbsnrtowcs, wcsrtombs, wcsnrtombs): Use it.
8076         * lib/argv-iter.h: Include arg-nonnull.h.
8077         (_ATTRIBUTE_NONNULL_): Remove macro.
8078         (argv_iter_init_argv, argv_iter_init_stream, argv_iter,
8079         argv_iter_n_args, argv_iter_free): Use _GL_ARG_NONNULL.
8080         * lib/canonicalize-lgpl.c (_GL_ARG_NONNULL): Define, to defeat gcc
8081         optimization.
8082         * lib/getaddrinfo.c (_GL_ARG_NONNULL): Likewise.
8083         * lib/getdelim.c (_GL_ARG_NONNULL): Likewise.
8084         * lib/glob.c (_GL_ARG_NONNULL): Likewise.
8085         * lib/random_r.c (_GL_ARG_NONNULL): Likewise.
8086         * lib/setenv.c (_GL_ARG_NONNULL): Likewise.
8087         * lib/strtod.c (_GL_ARG_NONNULL): Likewise.
8088         * lib/tsearch.c (_GL_ARG_NONNULL): Likewise.
8089         * lib/unsetenv.c (_GL_ARG_NONNULL): Likewise.
8090         * modules/arpa_inet (Depends-on): Add arg-nonnull.
8091         (Makefile.am): Insert arg-nonnull.h into arpa/inet.h.
8092         * modules/dirent (Depends-on): Add arg-nonnull.
8093         (Makefile.am): Insert arg-nonnull.h into dirent.h.
8094         * modules/fcntl-h (Depends-on): Add arg-nonnull.
8095         (Makefile.am): Insert arg-nonnull.h into fcntl.h.
8096         * modules/fnmatch (Depends-on): Add arg-nonnull.
8097         (Makefile.am): Insert arg-nonnull.h into fnmatch.h.
8098         * modules/getopt-posix (Depends-on): Add arg-nonnull.
8099         (Makefile.am): Insert arg-nonnull.h into getopt.h.
8100         * modules/glob (Depends-on): Add arg-nonnull.
8101         (Makefile.am): Insert arg-nonnull.h into glob.h.
8102         * modules/iconv_open (Depends-on): Add arg-nonnull.
8103         (Makefile.am): Insert arg-nonnull.h into iconv.h.
8104         * modules/inttypes (Depends-on): Add arg-nonnull.
8105         (Makefile.am): Insert arg-nonnull.h into inttypes.h.
8106         * modules/locale (Depends-on): Add arg-nonnull.
8107         (Makefile.am): Insert arg-nonnull.h into locale.h.
8108         * modules/math (Depends-on): Add arg-nonnull.
8109         (Makefile.am): Insert arg-nonnull.h into math.h.
8110         * modules/netdb (Depends-on): Add arg-nonnull.
8111         (Makefile.am): Insert arg-nonnull.h into netdb.h.
8112         * modules/search (Depends-on): Add arg-nonnull.
8113         (Makefile.am): Insert arg-nonnull.h into search.h.
8114         * modules/signal (Depends-on): Add arg-nonnull.
8115         (Makefile.am): Insert arg-nonnull.h into signal.h.
8116         * modules/spawn (Depends-on): Add arg-nonnull.
8117         (Makefile.am): Insert arg-nonnull.h into spawn.h.
8118         * modules/stdio (Depends-on): Add arg-nonnull.
8119         (Makefile.am): Insert arg-nonnull.h into stdio.h.
8120         * modules/stdlib (Depends-on): Add arg-nonnull.
8121         (Makefile.am): Insert arg-nonnull.h into stdlib.h.
8122         * modules/string (Depends-on): Add arg-nonnull.
8123         (Makefile.am): Insert arg-nonnull.h into string.h.
8124         * modules/strings (Depends-on): Add arg-nonnull.
8125         (Makefile.am): Insert arg-nonnull.h into strings.h.
8126         * modules/sys_socket (Depends-on): Add arg-nonnull.
8127         (Makefile.am): Insert arg-nonnull.h into sys/socket.h.
8128         * modules/sys_stat (Depends-on): Add arg-nonnull.
8129         (Makefile.am): Insert arg-nonnull.h into sys/stat.h.
8130         * modules/sys_time (Depends-on): Add arg-nonnull.
8131         (Makefile.am): Insert arg-nonnull.h into sys/time.h.
8132         * modules/sys_times (Depends-on): Add arg-nonnull.
8133         (Makefile.am): Insert arg-nonnull.h into sys/times.h.
8134         * modules/sys_utsname (Depends-on): Add arg-nonnull.
8135         (Makefile.am): Insert arg-nonnull.h into sys/utsname.h.
8136         * modules/time (Depends-on): Add arg-nonnull.
8137         (Makefile.am): Insert arg-nonnull.h into time.h.
8138         * modules/unistd (Depends-on): Add arg-nonnull.
8139         (Makefile.am): Insert arg-nonnull.h into unistd.h.
8140         * modules/wchar (Depends-on): Add arg-nonnull.
8141         (Makefile.am): Insert arg-nonnull.h into wchar.h.
8142         * modules/argv-iter (Depends-on): Add arg-nonnull.
8143         * tests/test-canonicalize.c (null_ptr): New function.
8144         (main): Use it.
8145         * tests/test-canonicalize-lgpl.c (null_ptr): New function.
8146         (main): Use it.
8147         * tests/test-memmem.c (null_ptr): New function.
8148         (main): Use it.
8149         Reported by Jim Meyering.
8150
8151 2009-12-10  Bruno Haible  <bruno@clisp.org>
8152
8153         Use spaces for indentation, not tabs.
8154         * lib/**/*.[hcy] except lib/reg*.[hc]: Untabify.
8155         * m4/*.m4: Untabify.
8156         * build-aux/*.h: Untabify.
8157         * tests/**/*.[hc]: Untabify.
8158         * README: New section "Indent with spaces, not TABs", based on
8159         coreutils/HACKING and comments by Pádraig Brady and Paolo Bonzini.
8160         * NEWS: Mention the change.
8161
8162 2009-12-10  Bruno Haible  <bruno@clisp.org>
8163
8164         pty test: Fix link error.
8165         * modules/pty-tests (Makefile.am): Add the default LDADD value to
8166         test_pty_LDADD.
8167
8168 2009-12-07  Simon Josefsson  <simon@josefsson.org>
8169
8170         * modules/pty: New file.
8171         * modules/pty-tests: New file.
8172         * m4/pty.m4: New file.
8173         * tests/test-pty.c: New file.
8174         * doc/glibc-headers/pty.texi: Modified.
8175         * doc/glibc-functions/forkpty.texi: Modified.
8176         * doc/glibc-functions/openpty.texi: Modified.
8177
8178 2009-12-10  Bruno Haible  <bruno@clisp.org>
8179
8180         Avoid syntax error in C++ mode.
8181         * lib/stdio.in.h (rename): Don't use parameter name 'new'.
8182
8183 2009-12-10  Bruno Haible  <bruno@clisp.org>
8184
8185         Use sed with option -e.
8186         * gnulib-tool (func_version, func_emit_copyright_notice,
8187         func_emit_initmacro_end, func_import, func_create_testdir): Pass
8188         option -e to sed.
8189         * modules/link-warning (Makefile.am): Likewise.
8190
8191 2009-12-10  Jim Meyering  <meyering@redhat.com>
8192
8193         mgetgroups: do not write bytes beyond end of malloc'd buffer
8194         * lib/mgetgroups.c: Fix an off-by-one error.  When we have no
8195         username, we call getgroups with a one-element-shorter buffer,
8196         but still told it the length was original, max_n_groups.
8197
8198 2009-12-09  Eric Blake  <ebb9@byu.net>
8199
8200         cloexec: relax license
8201         * modules/cloexec (Maintainer): Add myself.
8202         (License): Use LGPL, not GPL.
8203
8204         link-warning: optimize generation
8205         * modules/link-warning (Makefile.am): Reduce process usage.
8206
8207 2009-12-09  Bruno Haible  <bruno@clisp.org>
8208
8209         * doc/posix-functions/unsetenv.texi: Mention Solaris 10 bug for which a
8210         workaround was added on 2009-11-17.
8211
8212 2009-12-09  Jim Meyering  <meyering@redhat.com>
8213             Bruno Haible  <bruno@clisp.org>
8214
8215         link-warning: Allow extra lines at the top of build-aux/link-warning.h.
8216         * modules/link-warning (Makefile.am): Make the comment-removing sed
8217         command more robust in the face of bootstrap-prepended comment lines.
8218
8219 2009-12-09  Bruno Haible  <bruno@clisp.org>
8220
8221         * lib/mgetgroups.c (mgetgroups): Don't remove duplicates if there is at
8222         most one group.
8223
8224 2009-12-09  Simon Josefsson <simon@josefsson.org>
8225             Bruno Haible  <bruno@clisp.org>
8226
8227         * build-aux/link-warning.h: Add copyright notice.
8228         * modules/link-warning (Makefile.am): Generate link-warning.h from
8229         build-aux/link-warning.h. Update LINK_WARNING_H accordingly.
8230         * NEWS: Mention change in link-warning module.
8231         * modules/arpa_inet (Makefile.am): Add dependency to arpa/inet.h.
8232         * modules/dirent (Makefile.am): Add dependency to dirent.h.
8233         * modules/fcntl-h (Makefile.am): Add dependency to fcntl.h.
8234         * modules/getopt-posix (Makefile.am): Add dependency to getopt.h.
8235         * modules/inttypes (Makefile.am): Add dependency to inttypes.h.
8236         * modules/math (Makefile.am): Add dependency to math.h.
8237         * modules/search (Makefile.am): Add dependency to search.h.
8238         * modules/signal (Makefile.am): Add dependency to signal.h.
8239         * modules/spawn (Makefile.am): Add dependency to spawn.h.
8240         * modules/stdio (Makefile.am): Add dependency to stdio.h.
8241         * modules/stdlib (Makefile.am): Add dependency to stdlib.h.
8242         * modules/string (Makefile.am): Add dependency to string.h.
8243         * modules/strings (Makefile.am): Add dependency to strings.h.
8244         * modules/sys_ioctl (Makefile.am): Add dependency to sys/ioctl.h.
8245         * modules/sys_select (Makefile.am): Add dependency to sys/select.h.
8246         * modules/sys_socket (Makefile.am): Add dependency to sys/socket.h.
8247         * modules/sys_stat (Makefile.am): Add dependency to sys/stat.h.
8248         * modules/sys_times (Makefile.am): Add dependency to sys/times.h.
8249         * modules/sys_utsname (Makefile.am): Add dependency to sys/utsname.h.
8250         * modules/sys_wait (Makefile.am): Add dependency to sys/wait.h.
8251         * modules/unistd (Makefile.am): Add dependency to unistd.h.
8252         * modules/wchar (Makefile.am): Add dependency to wchar.h.
8253
8254 2009-12-09  Bruno Haible  <bruno@clisp.org>
8255
8256         fchdir: Optimize away rpl_fstat when possible.
8257         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set REPLACE_FSTAT only together with
8258         REPLACE_OPEN_DIRECTORY.
8259         * lib/fchdir.c (rpl_fstat): Define only when REPLACE_OPEN_DIRECTORY.
8260
8261 2009-12-09  Bruno Haible  <bruno@clisp.org>
8262
8263         * lib/fchdir.c: Update comment.
8264
8265 2009-12-09  Bruno Haible  <bruno@clisp.org>
8266
8267         * lib/cloexec.c (set_cloexec_flag): Clarify intent of dup2 call.
8268
8269 2009-12-08  Eric Blake  <ebb9@byu.net>
8270
8271         fchdir: avoid memory leak on re-registration.
8272         * lib/fchdir.c (ensure_dirs_slot): Avoid memory leak.
8273
8274 2009-12-08  Jim Meyering  <meyering@redhat.com>
8275
8276         init.sh: avoid Solaris 10 /bin/sh portability problem
8277         Solaris 10's /bin/sh does not pass '.' arguments 2.. to the
8278         sourced script:
8279           $ printf 'echo "$@"\n' > f; /bin/sh -c '. ./f bar'
8280           $ printf 'echo "$@"\n' > f; /bin/bash -c '. ./f bar'
8281           bar
8282         tests/init.sh relied on that, accepting a --set-path=DIR argument,
8283         and two tests used that idiom.
8284         * tests/init.sh: Update suggested usage comments.
8285         (path_prepend_): New function, to be used in place
8286         of the --src-path=DIR option.
8287         (setup_): Move PATH-prepending code into path_prepend_.
8288         * tests/test-pread.sh: Adapt to new usage.
8289         * tests/test-xalloc-die.sh: Likewise.
8290
8291 2009-12-08  Simon Josefsson  <simon@josefsson.org>
8292
8293         * doc/gnulib.texi (Glibc pty.h): Add.
8294         * doc/glibc-functions/forkpty.texi: Add.
8295         * doc/glibc-functions/openpty.texi: Add.
8296         Suggested by Bruno Haible.
8297
8298 2009-12-08  Eric Blake  <ebb9@byu.net>
8299
8300         fchdir: fix logic bugs
8301         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Fix logic bug.
8302         * tests/test-fchdir.c (main): Enhance test.
8303         * lib/fchdir.c (rpl_fstat): Always provide if fchdir replacement
8304         is in use.
8305
8306         dup2: fix logic bugs
8307         * lib/dup2.c (dup2): Fix logic bugs.  Use HAVE_DUP2 rather than
8308         REPLACE_DUP2 to decide when rpl_dup2 is needed.
8309         * m4/dup2.m4 (gl_REPLACE_DUP2): Only define REPLACE_DUP2 when dup2
8310         exists.
8311         (gl_FUNC_DUP2): Drop unneeded AC_DEFINE.
8312
8313 2009-12-07  Eric Blake  <ebb9@byu.net>
8314
8315         unlink: fix m4 detection
8316         * m4/unlink.m4 (gl_FUNC_UNLINK): Include correct header.
8317
8318         unistd-safer: add unit test
8319         * modules/unistd-safer-tests: New file.
8320         * tests/test-dup-safer.c: Likewise.
8321         * tests/test-cloexec.c (setmode): Avoid compiler warning.
8322         * tests/test-dup2.c (setmode): Likewise.
8323         * lib/cloexec.c (dup_cloexec): Fix mingw compile error.
8324
8325         cloexec: preserve text vs. binary across dup_cloexec
8326         * lib/cloexec.c (dup_cloexec) [W32]: Query and use translation
8327         mode.
8328         * modules/dup2-tests (Depends-on): Add binary-io.
8329         * modules/cloexec-tests (Depends-on): Likewise.
8330         * tests/test-dup2.c (setmode, is_mode): New helpers.
8331         (main): Add tests that translation mode is preserved.
8332         * tests/test-cloexec.c (setmode, is_mode, main): Likewise.
8333         Reported by Bruno Haible.
8334
8335         mgetgroups: reduce duplicate listings
8336         * lib/mgetgroups.c (mgetgroups): Reduce duplicates from the
8337         resulting array.
8338         * tests/test-chown.h (test_chown): Simplify client.
8339         * tests/test-lchown.h (test_lchown): Likewise.
8340
8341 2009-12-06  Bruno Haible  <bruno@clisp.org>
8342
8343         * lib/cloexec.c (dup_cloexec): Fix handling of _gl_register_dup return
8344         value.
8345
8346 2009-12-06  Bruno Haible  <bruno@clisp.org>
8347
8348         * lib/progname.c: Include stdio.h, stdlib.h.
8349         (set_program_name): Reject a NULL argument.
8350
8351 2009-12-05  Eric Blake  <ebb9@byu.net>
8352
8353         pipe2-safer: new module
8354         * modules/pipe2-safer: New file.
8355         * lib/unistd-safer.h (pipe2_safer): New prototype.
8356         * lib/unistd--.h (pipe2): New wrapper.
8357         * lib/pipe-safer.c (pipe2_safer): New function.
8358         * modules/pipe (Depends-on): Add pipe2-safer.
8359         * lib/pipe.c (create_pipe) [WIN32]: Let pipe2_safer do the work.
8360
8361         stdlib-safer: preserve cloexec flag for mkostemp[s]
8362         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer): Use new
8363         fd_safer_flag.
8364
8365         unistd-safer: allow preservation of cloexec status via flag
8366         * lib/unistd-safer.h (dup_safer_flag, fd_safer_flag): New
8367         prototypes.
8368         * lib/dup-safer.c (dup_safer_flag): New function.
8369         * lib/fd-safer.c (fd_safer_flag): Likewise.
8370         * modules/cloexec (configure.ac): Set witness.
8371
8372         test-dup2: enhance test
8373         * modules/dup2-tests (Depends-on): Add cloexec.
8374         * tests/test-dup2.c (main): Enhance test.
8375
8376         cloexec: add dup_cloexec
8377         * lib/cloexec.h (dup_cloexec): New prototype.  Add copyright
8378         header and comments.
8379         * lib/cloexec.c (set_cloexec_flag): Add comments.
8380         (dup_cloexec): New function, with mingw implementation borrowed
8381         from...
8382         * lib/w32spawn.h (dup_noinherit): ...here.
8383         * modules/execute (Depends-on): Add cloexec.
8384         * modules/pipe (Depends-on): Likewise.
8385         * modules/cloexec (Depends-on): Add dup2.
8386         * modules/cloexec-tests (Files): New file.
8387         * tests/test-cloexec.c: Likewise.
8388
8389         test-xalloc-die: fix test for mingw
8390         * modules/xalloc-die-tests (Files): Add tests/init.sh.
8391         * tests/test-xalloc-die.sh: Rewrite to use init.sh.  Strip
8392         directory and .exe suffix off argv[0] output.
8393
8394         test-fseeko: fix test for mingw
8395         * tests/test-fseeko.c (fseek): Redefine GL_LINK_WARNING, rather
8396         than undefining fseek, so test will pass on mingw.
8397
8398 2009-12-05  Bruno Haible  <bruno@clisp.org>
8399
8400         * lib/progname.h (set_program_name): Clarify specification.
8401         * lib/progname.c (set_program_name): Likewise.
8402         Reported by Jim Meyering.
8403
8404 2009-12-05  Jim Meyering  <meyering@redhat.com>
8405
8406         maint.mk: backslash-escape parens in default regexp
8407         * top/maint.mk (news-check-regexp): Now that we're using grep -E,
8408         backslash-escape the literal parentheses.
8409
8410         maint.mk: news-date-check: use grep -E
8411         * top/maint.mk (today): Define a Make variable, not a...
8412         (news-date-check): ...shell variable.
8413         (news-date-regexp): Use the Make variable.
8414         Use grep's -E option.  Change the failing diagnostic to mention
8415         the variable, $(news-date-regexp).
8416
8417 2009-12-04  Alfred M. Szmidt  <ams@gnu.org>
8418
8419         maintainer-makefile: allow customization of NEWS entry format
8420         * top/maint.mk (news-date-regexp): New overridable variable.
8421         (news-date-check): Use it.
8422
8423 2009-12-04  Eric Blake  <ebb9@byu.net>
8424
8425         mgetgroups: add xgetgroups, and avoid ENOSYS failures
8426         * lib/mgetgroups.h (xgetgroups): New prototype.
8427         * lib/mgetgroups.c (xgetgroups): New wrapper.
8428         (mgetgroups): Handle ENOSYS.
8429         * modules/mgetgroups (Depends-on): Add realloc.
8430         Reported by Scott Harrison <scott.gnu.2009@scottrix.co.uk>.
8431
8432         mgetgroups: avoid argument promotion issues with -1
8433         * lib/mgetgroups.c (mgetgroups): A cast is required when checking
8434         for invalid gid_t.
8435         * tests/test-chown.h (getegid, test_chown): Likewise.
8436         * tests/test-lchown.h (getegid, test_lchown): Likewise.
8437
8438 2009-12-03  Paolo Bonzini  <bonzini@gnu.org>
8439
8440         exclude: Fix header file problems.
8441         * lib/exclude.h: Add multiple inclusion guards and include stdbool.h.
8442
8443 2009-12-01  Jim Meyering  <meyering@redhat.com>
8444
8445         fts: fts_open: do not let an empty string cause immediate failure
8446         This is required in support of GNU rm, for which the command
8447         "rm A '' B" must process and remove both A and B, in spite of
8448         the empty string argument.
8449         * lib/fts.c (fts_open): Do not let the presence of an empty string
8450         cause fts_open to fail immediately.  Most fts-using tools must be
8451         able to process all arguments, in order, and can be expected to
8452         diagnose such arguments themselves.
8453
8454 2009-11-30  Eric Blake  <ebb9@byu.net>
8455
8456         utimens: fix compilation error
8457         * lib/utimens.c (lutimens) [!HAVE_UTIMENSAT && HAVE_LUTIMES]:
8458         Declare variable at right scope.
8459
8460 2009-11-29  Jim Meyering  <meyering@redhat.com>
8461
8462         bootstrap: handle perl-5.11's changed --version output
8463         * build-aux/bootstrap (get_version): Handle perl separately,
8464         since perl-5.11's --version output is different.
8465
8466 2009-11-28  Jim Meyering  <meyering@redhat.com>
8467
8468         userspec: depend on the inttostr module, too
8469         * modules/userspec (Depends-on): Add inttostr.
8470
8471         userspec: disallow an ID that maps to (uid_t)-1 or (gid_t)-1
8472         * lib/userspec.c (parse_with_separator): Do not accept a user ID
8473         number of MAXUID when it evaluates to (uid_t) -1.
8474         Likewise for group ID.  Reported by Matt McCutchen in
8475         <http://savannah.gnu.org/bugs/?28113>
8476
8477         userspec: reformat to use spaces, not TABs
8478         * lib/userspec.c: Expand TABs to spaces.
8479         Add Emacs' "indent-tabs-mode: nil" hint.
8480
8481 2009-11-27  Eric Blake  <ebb9@byu.net>
8482
8483         getopt-gnu: flush out another BSD bug
8484         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Test for the bug.
8485         * tests/test-getopt.c (main): Check POSIXLY_CORRECT first, to
8486         flush out BSD bug.
8487         * tests/test-getopt.h (test_getopt): End lists with NULL.
8488         * tests/test-getopt_long.h (test_getopt_long): Likewise.
8489         (test_getopt_long_posix): Enhance test.
8490         * modules/getopt-posix-tests (Depends-on): Add stdbool.
8491         * doc/glibc-functions/getopt_long.texi (getopt_long): Mention
8492         getopt-gnu.
8493         * doc/glibc-functions/getopt_long_only.texi (getopt_long_only):
8494         Likewise.
8495
8496 2009-11-27  Simon Josefsson  <simon@josefsson.org>
8497
8498         * modules/idpriv-droptemp-tests (Notice): Fix text.
8499
8500 2009-11-27  Jim Meyering  <meyering@redhat.com>
8501
8502         test-xalloc-die: avoid spurious failure due to libtool argv difference
8503         In a libtool-enabled project, this test would fail due to a difference
8504         in the emitted program name, e.g.,
8505         -test-xalloc-die: memory exhausted
8506         +/tmp/.../tests/.libs/lt-test-xalloc-die: memory exhausted
8507         Use program to avoid that.
8508         * modules/xalloc-die-tests (Depends-on): Add progname.
8509         * tests/test-xalloc-die.c: Include progname.h".
8510         (program_name): Remove decl.
8511         (main): Call set_program_name.
8512         * tests/test-xalloc-die.sh (compare): Remove unnecessary ${EXE}.
8513
8514 2009-11-26  Richard Jones  <rjones@redhat.com>
8515
8516         w32sock: leave win32 error in place.
8517         * lib/w32sock.h (set_winsock_errno): Do not call WSASetLastError.
8518
8519 2009-11-26  Eric Blake  <ebb9@byu.net>
8520
8521         init.sh: suggest to use skip_ and fail_ functions in comments
8522         * tests/init.sh: Add a sentence.
8523
8524 2009-11-25  Bruno Haible  <bruno@clisp.org>
8525
8526         init.sh: add documentation in comments
8527         * tests/init.sh: Add some developer and user documentation.
8528
8529 2009-11-26  Jim Meyering  <meyering@redhat.com>
8530
8531         init.sh: accommodate even those who specify bogus srcdir manually
8532         * tests/init.sh: Normally, srcdir is guaranteed by automake and
8533         configure-time tests to be sanitized, so that there is no need to
8534         use "$srcdir" in Makefile rules and shell scripts.  Using $srcdir
8535         (with no double quotes) suffices.  However, since tests may be
8536         invoked manually, and since you may explicitly set srcdir to the
8537         name of a directory containing spaces, do quote its uses here.
8538         * tests/test-pread.sh: Likewise.
8539         Suggested by Bruno Haible.
8540
8541         test-pread.sh: avoid diagnostics for those who ignore SIGPIPE
8542         * tests/test-pread.sh: Write no data into the pipe, because
8543         test-pread actually reads none.  This avoids a diagnostic,
8544         "bash: echo: write error: Broken pipe", that arises in the unusual
8545         event something is ignoring SIGPIPE, and might be interpreted
8546         as some sort of failure.  Reported by Bruno Haible.
8547
8548 2009-11-25  Jim Meyering  <meyering@redhat.com>
8549
8550         test-pread: cover failure with ESPIPE and EINVAL
8551         * tests/test-pread.c (main): Test for failure, too.
8552         * tests/test-pread.sh: Invoke with stdin on a pipe.
8553         Suggested by Eric Blake.
8554
8555         pread: improvement and fix
8556         * modules/pread (Depends-on): Depend on lseek, for portability to
8557         e.g., mingw.  Suggested by Eric Blake.
8558         * lib/pread.c (__libc_read): Define.  Reported by Richard W.M. Jones.
8559
8560         unistd.in.h: correct declaration of pread
8561         * lib/unistd.in.h: Correct type of "buf" parameter: void*, not char*
8562         Reported by Richard W.M. Jones.
8563
8564         test-pread.sh: distribute the test script
8565         * modules/pread-tests (Files): Include test-pread.sh.
8566
8567         test-pread.sh: clean up
8568         * tests/test-pread.sh: Don't refer to $builddir. Just use equivalent ".".
8569         * modules/pread-tests (TESTS_ENVIRONMENT): Don't export builddir.
8570         That is unnecessary, since it's always ".".
8571         Suggestion from Eric Blake.
8572
8573         test-pread.sh: make executable
8574         * tests/test-pread.sh: Set executable bit.
8575         Reported by Eric Blake.
8576
8577         correct typo in test-pread.sh
8578         * tests/test-pread.sh: Add #! line.
8579
8580         test pread
8581         * tests/test-pread.c: New file.
8582         * tests/test-pread.sh: Likewise.
8583         * modules/pread-tests: Likewise.
8584
8585         pread: new module
8586         * modules/pread: New file.
8587         * lib/unistd.in.h (pread): Define/declare.
8588         * lib/pread.c (pread): New file.
8589         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define defaults.
8590         * modules/unistd (Makefile.am): Substitute witnesses.
8591         * doc/posix-functions/pread.texi (pread): Update.
8592         * MODULES.html.sh: Add pread.
8593
8594 2009-11-25  Jim Meyering  <meyering@redhat.com>
8595
8596         tests/init.sh: new file to be used via most *.sh tests
8597         * tests/init.sh: New file.
8598
8599 2009-11-25  Eric Blake  <ebb9@byu.net>
8600
8601         utimens: work around older Linux failure with symlinks
8602         * lib/utimens.c (lutimensat_works_really): New variable.
8603         (fdutimens, lutimens): Use it to manage kernels that support
8604         nanosecond times on files, but not on symlinks.
8605         Reported by Ondřej Vašík.
8606
8607         utimes: fix configure grammar
8608         * m4/utimes.m4 (gl_FUNC_UTIMES): Delete spurious word.
8609
8610 2009-11-25  Paolo Bonzini  <bonzini@gnu.org>
8611
8612         regex: Fix fastmap for multibyte character ranges.
8613         * lib/regcomp.c (re_compute_fastmap_iter): Add all multibyte lead
8614         characters when a multibyte character range is included.
8615
8616 2009-11-22  Andy Wingo  <wingo@pobox.com>
8617
8618         version-etc: work also with AM_INIT_AUTOMAKE's no-define option
8619         * lib/version-etc.c [!defined PACKAGE]: Define to PACKAGE_TARNAME.
8620
8621 2009-11-24  Bruno Haible  <bruno@clisp.org>
8622
8623         doc: Most *_l functions exist in MacOS X 10.5.
8624         * doc/posix-functions/duplocale.texi: Update platforms list.
8625         * doc/posix-functions/freelocale.texi: Likewise.
8626         * doc/posix-functions/newlocale.texi: Likewise.
8627         * doc/posix-functions/uselocale.texi: Likewise.
8628         * doc/posix-functions/isalnum_l.texi: Likewise.
8629         * doc/posix-functions/isalpha_l.texi: Likewise.
8630         * doc/posix-functions/isblank_l.texi: Likewise.
8631         * doc/posix-functions/iscntrl_l.texi: Likewise.
8632         * doc/posix-functions/isdigit_l.texi: Likewise.
8633         * doc/posix-functions/isgraph_l.texi: Likewise.
8634         * doc/posix-functions/islower_l.texi: Likewise.
8635         * doc/posix-functions/isprint_l.texi: Likewise.
8636         * doc/posix-functions/ispunct_l.texi: Likewise.
8637         * doc/posix-functions/isspace_l.texi: Likewise.
8638         * doc/posix-functions/isupper_l.texi: Likewise.
8639         * doc/posix-functions/iswalnum_l.texi: Likewise.
8640         * doc/posix-functions/iswalpha_l.texi: Likewise.
8641         * doc/posix-functions/iswblank_l.texi: Likewise.
8642         * doc/posix-functions/iswcntrl_l.texi: Likewise.
8643         * doc/posix-functions/iswctype_l.texi: Likewise.
8644         * doc/posix-functions/iswdigit_l.texi: Likewise.
8645         * doc/posix-functions/iswgraph_l.texi: Likewise.
8646         * doc/posix-functions/iswlower_l.texi: Likewise.
8647         * doc/posix-functions/iswprint_l.texi: Likewise.
8648         * doc/posix-functions/iswpunct_l.texi: Likewise.
8649         * doc/posix-functions/iswspace_l.texi: Likewise.
8650         * doc/posix-functions/iswupper_l.texi: Likewise.
8651         * doc/posix-functions/iswxdigit_l.texi: Likewise.
8652         * doc/posix-functions/isxdigit_l.texi: Likewise.
8653         * doc/posix-functions/nl_langinfo_l.texi: Likewise.
8654         * doc/posix-functions/strcasecmp_l.texi: Likewise.
8655         * doc/posix-functions/strcoll_l.texi: Likewise.
8656         * doc/posix-functions/strfmon_l.texi: Likewise.
8657         * doc/posix-functions/strftime_l.texi: Likewise.
8658         * doc/posix-functions/strncasecmp_l.texi: Likewise.
8659         * doc/posix-functions/strxfrm_l.texi: Likewise.
8660         * doc/posix-functions/tolower_l.texi: Likewise.
8661         * doc/posix-functions/toupper_l.texi: Likewise.
8662         * doc/posix-functions/towctrans_l.texi: Likewise.
8663         * doc/posix-functions/towlower_l.texi: Likewise.
8664         * doc/posix-functions/towupper_l.texi: Likewise.
8665         * doc/posix-functions/wcscoll_l.texi: Likewise.
8666         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
8667         * doc/posix-functions/wctrans_l.texi: Likewise.
8668         * doc/posix-functions/wctype_l.texi: Likewise.
8669         * doc/glibc-functions/strptime_l.texi: Likewise.
8670         * doc/glibc-functions/strtod_l.texi: Likewise.
8671         * doc/glibc-functions/strtof_l.texi: Likewise.
8672         * doc/glibc-functions/strtol_l.texi: Likewise.
8673         * doc/glibc-functions/strtold_l.texi: Likewise.
8674         * doc/glibc-functions/strtoll_l.texi: Likewise.
8675         * doc/glibc-functions/strtoul_l.texi: Likewise.
8676         * doc/glibc-functions/strtoull_l.texi: Likewise.
8677         * doc/glibc-functions/wcsftime_l.texi: Likewise.
8678         * doc/glibc-functions/wcstod_l.texi: Likewise.
8679         * doc/glibc-functions/wcstof_l.texi: Likewise.
8680         * doc/glibc-functions/wcstol_l.texi: Likewise.
8681         * doc/glibc-functions/wcstold_l.texi: Likewise.
8682         * doc/glibc-functions/wcstoll_l.texi: Likewise.
8683         * doc/glibc-functions/wcstoul_l.texi: Likewise.
8684         * doc/glibc-functions/wcstoull_l.texi: Likewise.
8685
8686 2009-11-24  Bruno Haible  <bruno@clisp.org>
8687
8688         duplocale: Fix logic bug.
8689         * lib/duplocale.c: Don't include <langinfo.h>.
8690         (_NL_LOCALE_NAME): Remove macro.
8691         (rpl_duplocale): Use setlocale instead of nl_langinfo.
8692         * tests/test-duplocale.c (main): Also test duplocale after uselocale.
8693
8694 2009-11-23  Jim Meyering  <meyering@redhat.com>
8695
8696         test-update-copyright: don't hard-code /usr/bin/perl
8697         * tests/test-update-copyright.sh (YEAR): Use date +%Y, rather than
8698         perl to print the current year.  Gilles Espinasse reported that
8699         the replaced use of perl was hard-coded as /usr/bin/perl.
8700
8701 2009-11-23  Bruno Haible  <bruno@clisp.org>
8702
8703         duplocale: Add support for glibc 2.3.x.
8704         * lib/duplocale.c (rpl_duplocale): Add fallback code for glibc 2.3.x.
8705
8706 2009-11-22  Bruno Haible  <bruno@clisp.org>
8707
8708         vasnprintf: Tiny optimization.
8709         * lib/vasnprintf.c (decimal_point_char): Choose the fast path also on
8710         MacOS X.
8711
8712 2009-11-22  Bruno Haible  <bruno@clisp.org>
8713
8714         Tests for module 'duplocale'.
8715         * modules/duplocale-tests: New file.
8716         * tests/test-duplocale.c: New file.
8717
8718         New module 'duplocale'.
8719         * m4/duplocale.m4: New file.
8720         * lib/locale.in.h (duplocale): New declaration.
8721         * lib/duplocale.c: New file.
8722         * m4/locale_h.m4 (gl_REPLACE_LOCALE_H, gl_LOCALE_MODULE_INDICATOR,
8723         gl_LOCALE_H_DEFAULTS): New macros.
8724         (gl_LOCALE_H): Require gl_LOCALE_H_DEFAULTS. Invoke
8725         gl_CHECK_NEXT_HEADERS unconditionally. Invoke gl_REPLACE_LOCALE_H.
8726         * modules/locale (Makefile.am): Substitute also GNULIB_DUPLOCALE,
8727         REPLACE_DUPLOCALE.
8728         * modules/duplocale: New file.
8729         * doc/posix-functions/duplocale.texi: Mention the glibc bug.
8730
8731 2009-11-22  Bruno Haible  <bruno@clisp.org>
8732
8733         * modules/locale-tests (configure.ac): Test for newlocale function.
8734         * tests/test-locale.c: When the system has extended locale functions,
8735         verify that <locale.h> defines locale_t and LC_GLOBAL_LOCALE.
8736
8737         locale: Make locale_t available when possible.
8738         * lib/locale.in.h: Include <xlocale.h> when it exists.
8739         * m4/locale_h.m4 (gl_LOCALE_H): Check for <xlocale.h> and arrange to
8740         replace <locale.h> if it does not define locale_t but <xlocale.h> does.
8741         * modules/locale (Depends-on): Add extensions.
8742         (Makefile.am): Also substitute HAVE_XLOCALE_H.
8743         * doc/posix-headers/locale.texi: Document the problem with locale_t.
8744
8745 2009-11-22  Bruno Haible  <bruno@clisp.org>
8746
8747         Add comments.
8748         * m4/dirent_h.m4 (gl_DIRENT_H): Add comment about gl_CHECK_NEXT_HEADERS
8749         invocation.
8750         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
8751         * m4/spawn_h.m4 (gl_SPAWN_H): Likewise.
8752         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
8753
8754 2009-11-22  Bruno Haible  <bruno@clisp.org>
8755
8756         error: account for the possibility of freopen (stdout).
8757         * lib/error.c: Include <unistd.h>.
8758         (flush_stdout): New function, extracted from error and error_at_line.
8759         Determine stdout's fd dynamically.
8760         (error, error_at_line): Invoke flush_stdout.
8761         * m4/error.m4 (gl_PREREQ_ERROR): Require AC_C_INLINE.
8762         * modules/error (Depends-on): Add unistd.
8763
8764 2009-11-22  Bruno Haible  <bruno@clisp.org>
8765
8766         diffseq: Add comment.
8767         * lib/diffseq.h (IF_LINT): Add comment about pitfall.
8768
8769 2009-11-22  Jim Meyering  <meyering@redhat.com>
8770
8771         c-stack: avoid defining an unused static function
8772         * lib/c-stack.c (find_stack_direction): Do not define this function
8773         when it will not be used.
8774
8775         diffseq: avoid spurious gcc warnings
8776         * lib/diffseq.h (IF_LINT2): Define.
8777         (compareseq): Use it to initialize two members of "part".
8778         This avoids two used-uninitialized warnings.
8779
8780 2009-11-21  Jim Meyering  <meyering@redhat.com>
8781
8782         c-stack: avoid "ignoring return value of `write'" warning
8783         * lib/c-stack.c: Include "ignore-value.h".
8784         (die): Explicitly ignore each write return value.
8785         * modules/c-stack (Depends-on): Add ignore-value.
8786
8787 2009-11-21  Bruno Haible  <bruno@clisp.org>
8788
8789         diffseq: reduce scope of variable 'best'.
8790         * lib/diffseq.h (diag) [USE_HEURISTIC]: Reduce scope of 'best'
8791         variable, earlier used for two different purposes.
8792
8793 2009-11-21  Jim Meyering  <meyering@redhat.com>
8794
8795         diffseq: remove useless assignment to "best"
8796         * lib/diffseq.h (diag) [USE_HEURISTIC]: Remove useless "best = 0"
8797         assignment.  At that point "best" is already guaranteed to be zero.
8798
8799 2009-11-20  Eric Blake  <ebb9@byu.net>
8800
8801         build: mention ftp redirector in release announcements
8802         * top/maint.mk (gnu_rel_host, url_dir_list): Provide defaults for
8803         values that used to come from cfg.mk; mention FTP redirect URL.
8804         * build-aux/announce-gen: Mention the mirror list.
8805         Suggested by Karl Berry.
8806
8807         nanosleep: improve port to mingw
8808         * lib/nanosleep.c (rpl_nanosleep): Reject invalid arguments.
8809         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Incorporate LIBSOCKET into
8810         LIB_NANOSLEEP, but only when needed.
8811         * modules/select (Link): Document LIBSOCKET.
8812         * m4/select.m4 (gl_FUNC_SELECT): Ensure LIBSOCKET is defined early
8813         enough.
8814
8815         nanosleep: work around cygwin bug
8816         * lib/nanosleep.c (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]:
8817         Fix logic bug when nanosleep fails.  Work around cygwin 1.5.x
8818         bug.
8819         (getnow): Delete, not needed.
8820         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): No longer require
8821         LIB_CLOCK_GETTIME.
8822         * modules/nanosleep (Depends-on): Add intprops and verify.  Drop
8823         clock-time, gettime.
8824         * doc/posix-functions/nanosleep.texi (nanosleep): Document the
8825         bug.
8826         * modules/nanosleep-tests: New test.
8827         * tests/test-nanosleep.c: New file.
8828
8829         sleep: work around cygwin bug
8830         * lib/sleep.c (rpl_sleep): Work around the bug.
8831         * m4/sleep.m4 (gl_FUNC_SLEEP): Detect the bug.
8832         (gl_PREREQ_SLEEP): Delete unused macro.
8833         * modules/sleep (Depends-on): Add verify.
8834         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
8835         * modules/unistd (Makefile.am): Substitute witness.
8836         * lib/unistd.in.h (sleep): Update prototype.
8837         * doc/posix-functions/sleep.texi (sleep): Document the bug.
8838         * tests/test-sleep.c (main) [HAVE_DECL_ALARM]: Test it.
8839         * modules/sleep-tests (Depends-on): Check for alarm.
8840
8841 2009-11-20  Jim Meyering  <meyering@redhat.com>
8842
8843         maint.mk: improve sc_prohibit_magic_number_exit
8844         * top/maint.mk (sc_prohibit_magic_number_exit): Tighten regexp
8845         so it does not match uses like System.exit(1).
8846         Add comments showing how to correct all offenders.
8847
8848 2009-11-19  Eric Blake  <ebb9@byu.net>
8849
8850         xalloc-die-tests: add missing library
8851         * modules/xalloc-die-tests (Makefile.am): Add LDADD line.
8852
8853         test-xvasprintf: silence compiler warnings
8854         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Mask
8855         empty string from gcc.
8856
8857 2009-11-19  Jim Meyering  <meyering@redhat.com>
8858
8859         xfreopen: new module, from coreutils
8860         * modules/xfreopen: New module.
8861         * lib/xfreopen.c: New file.
8862         * lib/xfreopen.h: New file.
8863         * MODULES.html.sh (File stream based Input/Output"): Add it.
8864
8865 2009-11-19  Eric Blake  <ebb9@byu.net>
8866
8867         manywarnings: depend on warnings
8868         * modules/manywarnings (Depends-on): Add warnings.
8869
8870         build: avoid compiler warnings
8871         * lib/select.c (rpl_select): Delete unused variable.
8872         * lib/setsockopt.c (rpl_setsockopt): Avoid incompatible pointer.
8873
8874 2009-11-18  Eric Blake  <ebb9@byu.net>
8875
8876         tests: avoid false negative with --with-packager
8877         * tests/test-version-etc.sh: Discard packager information.
8878         * tests/test-argp-version-etc-1.sh: Likewise.
8879         Reported by Mike Frysinger.
8880
8881         utimens: fix regression on Solaris
8882         * m4/utimens.m4 (gl_UTIMENS): Check for BSD bug.
8883         * lib/utimens.c (fdutimens): Revert 2009-11-08 change; Solaris 10
8884         can only change fd timestamps via futimesat.  Instead, use an
8885         additional witness macro to avoid BSD bug.
8886         Reported by Jim Meyering.
8887
8888 2009-11-17  Eric Blake  <ebb9@byu.net>
8889
8890         usleep: use it to simplify tests
8891         * modules/stat-time-tests (Depends-on): Add usleep.
8892         (configure.ac): Drop usleep check.
8893         * modules/chown-tests (Depends-on, configure.ac): Likewise.
8894         * modules/lchown-tests (Depends-on, configure.ac): Likewise.
8895         * modules/fdutimensat-tests (Depends-on, configure.ac): Likewise.
8896         * modules/futimens-tests (Depends-on, configure.ac): Likewise.
8897         * modules/openat-tests (Depends-on, configure.ac): Likewise.
8898         * modules/utimens-tests (Depends-on, configure.ac): Likewise.
8899         * modules/utimensat-tests (Depends-on, configure.ac): Likewise.
8900         * modules/pipe-filter-gi-tests (Depends-on, configure.ac):
8901         Likewise.
8902         * tests/test-chown.h (nap): Rely on nicer usleep semantics.
8903         * tests/test-lchown.h (nap): Likewise.
8904         * tests/test-pipe-filter-gi2-main.c (small_nap): Likewise.
8905         * tests/test-stat-time.c (nap): Likewise.
8906         * tests/test-utimens-common.h (nap): Update comments.
8907
8908         usleep: new module
8909         * modules/usleep: New file.
8910         * m4/usleep.m4 (gl_FUNC_USLEEP): Likewise.
8911         * lib/usleep.c (usleep): Likewise.
8912         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
8913         * modules/unistd (Makefile.am): Substitute witnesses.
8914         * lib/unistd.in.h (usleep): Add declaration.
8915         * doc/pastposix-functions/usleep.texi (usleep): Document this.
8916         * MODULES.html.sh (Date and time): Likewise.
8917         * modules/usleep-tests (Depends-on): New test.
8918         * tests/test-usleep.c: New file.
8919
8920         chown: work around OpenBSD bug
8921         * lib/chown.c (rpl_chown): Work around the bug.
8922         * lib/lchown.c (rpl_lchown): Attempt to do likewise.
8923         * m4/chown.m4 (gl_FUNC_CHOWN): Test for ctime bug.
8924         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for lchmod.
8925         * modules/chown (Depends-on): Add stdbool.
8926         * modules/lchown (Depends-on): Likewise.
8927         * doc/posix-functions/chown.texi (chown): Document the bug.
8928         * doc/posix-functions/lchown.texi (lchown): Likewise.
8929         * tests/test-lchown.h (test_chown): Relax test.
8930
8931         mkstemp: avoid conflict with C++ keyword template
8932         * lib/mkdtemp.c (mkdtemp): Change spelling of template.
8933         * lib/mkostemp.c (mkostemp): Likewise.
8934         * lib/mkostemps.c (mkostemps): Likewise.
8935         * lib/mkstemp.c (mkstemp): Likewise.
8936         * lib/mkstemps.c (mkstemps): Likewise.
8937
8938         xalloc-die-tests: optimize
8939         * tests/test-xalloc-die.sh: Reduce number of processes.
8940
8941 2009-11-17  Simon Josefsson  <simon@josefsson.org>
8942
8943         * gnulib-tool: Support LGPLv3+ licenses in module files.  Tiny
8944         patch from ludo@gnu.org (Ludovic Courtès).
8945
8946 2009-11-17  Jim Meyering  <meyering@redhat.com>
8947
8948         version-etc: use proper license string
8949         * modules/version-etc (License): Use LGPL, not LGPLv3+.
8950         * modules/version-etc-fsf: Likewise.
8951
8952 2009-11-17  Simon Josefsson  <simon@josefsson.org>
8953
8954         * tests/test-xalloc-die.sh: Add license.  Check that nothing is
8955         printed to stdout.  Deal with EOL differences.
8956
8957 2009-11-17  Eric Blake  <ebb9@byu.net>
8958
8959         unsetenv: work around Solaris bug
8960         * m4/setenv.m4 (gl_FUNC_UNSETENV): Check for bug.
8961         * lib/unsetenv.c (rpl_unsetenv): Work around it.
8962         Reported by Jim Meyering.
8963
8964         vasnprintf: avoid compiler warnings
8965         * lib/vasnprintf.c (VASNPRINTF): Avoid shadowing our own local
8966         variables.
8967         * lib/printf-args.c (PRINTF_FETCHARGS): Avoid type mismatch.
8968
8969 2009-11-17  Simon Josefsson  <simon@josefsson.org>
8970
8971         * modules/xalloc-die-tests (Makefile.am): Drop XFAIL_TESTS
8972         settings since xalloc-die is no longer the self test,
8973         xalloc-die.sh is.
8974
8975 2009-11-17  Jim Meyering  <meyering@redhat.com>
8976
8977         test-xalloc-die.sh: make the code agree with the commit log
8978         * tests/test-xalloc-die.sh: Put "." at the front of $PATH, not
8979         at the end, just in case you happen to have a test-xalloc-die
8980         program in some other PATH directory.
8981
8982         test-xalloc-die.sh: fix a portability bug
8983         * tests/test-xalloc-die.sh: Do not invoke via ./test-xalloc-die.
8984         Instead, set PATH to start with "." and invoke via "test-xalloc-die".
8985         Otherwise, argv[0] (as often seen in diagnostics) would be too
8986         system-dependent, sometimes with, and sometimes without the leading "./".
8987
8988         version-etc-fsf: relax license to LGPLv3+
8989         * modules/version-etc-fsf (License): Relax license.
8990
8991 2009-11-16  Eric Blake  <ebb9@byu.net>
8992
8993         xalloc-die-tests: avoid printing null pointer
8994         * modules/xalloc-die-tests (Files, Makefile.am): Wrap execution in
8995         shell script.
8996         * tests/test-xalloc-die.c (program_name): Declare.
8997         * tests/test-xalloc-die.sh (tmpfiles): New file.
8998
8999         setenv, unsetenv: work around various bugs
9000         * lib/setenv.c (setenv) [!HAVE_SETENV]: Resync from glibc.
9001         (setenv) [HAVE_SETENV]: Work around bugs.
9002         * lib/unsetenv.c (unsetenv) [HAVE_UNSETENV]: Work around bugs.
9003         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE, gl_FUNC_UNSETENV): Check
9004         for bugs.
9005         (gl_FUNC_SETENV): Write in terms of gl_FUNC_SETENV_SEPARATE.
9006         * m4/environ.m4 (gl_ENVIRON): Avoid expand-before-require.
9007         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Update defaults.
9008         * modules/stdlib (Makefile.am): Update substitutions.
9009         * lib/stdlib.in.h (setenv, unsetenv): Update prototypes.
9010         * doc/posix-functions/setenv.texi (setenv): Document the bugs.
9011         * doc/posix-functions/unsetenv.texi (unsetenv): Likewise.
9012         * modules/setenv-tests: New test.
9013         * modules/unsetenv-tests: Likewise.
9014         * tests/test-setenv.c: New file.
9015         * tests/test-unsetenv.c: Likewise.
9016
9017 2009-11-16  Jim Meyering  <meyering@redhat.com>
9018
9019         version-etc: relax license to LGPLv3+
9020         * modules/version-etc (License): Relax license.
9021
9022         better AC_REQUIRE expanded-before-required-warning avoidance
9023         * m4/chown.m4 (gl_FUNC_CHOWN, gl_FUNC_CHOWN_FOLLOWS_SYMLINK): Define
9024         with AC_DEFUN_ONCE, rather than AC_DEFUN, to avoid AC_REQUIRE warnings.
9025         Suggested by Eric Blake.  This change also reverts commit 1b712ba8,
9026         which is no longer needed.
9027
9028 2009-11-16  Eric Blake  <ebb9@byu.net>
9029
9030         test-freading: clean up temporary file
9031         * tests/test-freading.c (main): Remove file on success, and use
9032         ASSERT more liberally.
9033         Reported by Jim Meyering.
9034
9035 2009-11-16  Jim Meyering  <meyering@redhat.com>
9036
9037         avoid new AC_REQUIRE expanded-before-required warnings
9038         * modules/chown (configure.ac): Require gl_FUNC_CHOWN, rather than
9039         merely using it.
9040         * modules/euidaccess (configure.ac): Likewise for gl_FUNC_EUIDACCESS.
9041         * modules/faccessat (configure.ac): Likewise for gl_FUNC_FACCESSAT.
9042
9043 2009-11-15  Simon Josefsson  <simon@josefsson.org>
9044
9045         * tests/test-xalloc-die.c: New file.
9046         * modules/xalloc-die-tests: New file.
9047         * gnulib-tool (func_emit_tests_Makefile_am): Also initialize
9048         XFAIL_TESTS so it can be appended by modules.
9049
9050 2009-11-15  Simon Josefsson  <simon@josefsson.org>
9051
9052         * lib/gc-pbkdf2-sha1.c: Remove comments from RFC 2898.  Reported
9053         by Vladimir 'phcoder' Serbinenko <phcoder@gmail.com>.
9054
9055 2009-11-14  Eric Blake  <ebb9@byu.net>
9056
9057         fnmatch: avoid compiler warning
9058         * lib/fnmatch_loop.c (NEW_PATTERN): Coerce addition to unsigned,
9059         to silence compiler warning about mismatch signedness in ?:.
9060         Reported by Robert Millan.
9061
9062         intprops: add double-inclusion guard
9063         * lib/intprops.h: Allow idempotent includes.
9064         Suggested by Bruce Korb.
9065
9066         openat: detect Solaris fchownat bug
9067         * lib/fchownat.c (rpl_fchownat): Work around Solaris bug.  Avoid
9068         penalizing glibc chownat when only lchownat is broken.
9069         * m4/openat.m4 (gl_FUNC_FCHOWNAT): Replace fchownat if there are
9070         trailing slash bugs.
9071         * doc/posix-functions/fchownat.texi (fchownat): Document the bug.
9072         * modules/openat-tests (Files): Include more files.
9073         (Depends-on): Add mgetgroups, sleep, stat-time.
9074         (configure.ac): Add additional checks.
9075         (Makefile.am): Build new test.
9076         * tests/test-fchownat.c: New file.
9077
9078         lchown: detect Solaris and FreeBSD bug
9079         * lib/lchown.c (rpl_lchown): Work around bug.
9080         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check for trailing slash bugs.
9081         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
9082         * modules/unistd (Makefile.am): Populate it.
9083         * lib/unistd.in.h (lchown): Update declaration.
9084         * doc/posix-functions/lchown.texi (lchown): Document the bug.
9085         * modules/lchown-tests: New file.
9086         * tests/test-lchown.h (test_lchown): Likewise.
9087         * tests/test-lchown.c (main): Likewise.
9088
9089         chown: detect Solaris and FreeBSD bug
9090         * lib/chown.c (rpl_chown): Work around bug.
9091         * m4/chown.m4 (gl_FUNC_CHOWN): Check for trailing slash bugs.
9092         (gl_PREREQ_CHOWN): Delete.
9093         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
9094         * modules/unistd (Makefile.am): Populate it.
9095         * lib/unistd.in.h (chown): Update declaration.
9096         * lib/lchown.c (chown): Update client.
9097         * modules/lchown (Depends-on): Add lstat.
9098         * doc/posix-functions/chown.texi (chown): Document the bug.
9099         * doc/posix-functions/getgroups.texi (getgroups): Document
9100         getgroups pitfall.
9101         * modules/chown-tests: New file.
9102         * tests/test-chown.h (test_chown): Likewise.
9103         * tests/test-chown.c (main): Likewise.
9104
9105 2009-11-14  Robert Millan  <rmh.grub@aybabtu.com>  (tiny change)
9106
9107         gnulib-tool: correctly detect absence of m4 directories
9108         * gnulib-tool: Avoid extra newline on data passed to wc -l.
9109
9110 2009-11-14  Jim Meyering  <meyering@redhat.com>
9111
9112         maint.mk: Prohibit inclusion of "xalloc.h" without use.
9113         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
9114
9115 2009-11-14  John W. Eaton  <jwe@gnu.org>
9116
9117         strftime.h: wrap funtion declaration in extern "C" block
9118         * lib/strftime.h (nstrftime) [__cplusplus]: Wrap declaration.
9119
9120 2009-11-13  Eric Blake  <ebb9@byu.net>
9121
9122         getgroups: avoid compiler warning
9123         * lib/getgroups.c (rpl_getgroups): Delete shadowed variable.
9124
9125         getgroups: work around FreeBSD bug
9126         * lib/getgroups.c (rpl_getgroups): Work around the bug.
9127         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Detect the bug.
9128         * doc/posix-functions/getgroups.texi (getgroups): Document it.
9129         * tests/test-getgroups.c (main): Fix buffer overrun.
9130
9131         getgroups: avoid compilation failure
9132         * lib/getgroups.c (includes): Include <stdint.h> for SIZE_MAX.
9133         * modules/getgroups (Depends-on): Add stdint.
9134
9135 2009-11-13  Jim Meyering  <meyering@redhat.com>
9136
9137         test-getgroups: avoid compilation failure
9138         * tests/test-getgroups.c: Include <stdint.h> for use of SIZE_MAX.
9139
9140 2009-11-13  Eric Blake  <ebb9@byu.net>
9141
9142         mgetgroups: new module, taken from coreutils
9143         * modules/mgetgroups: New file.
9144         * lib/mgetgroups.h: Likewise.
9145         * lib/mgetgroups.c (mgetgroups): Likewise.
9146         * m4/mgetgroups.m4 (gl_MGETGROUPS): Likewise.
9147         * MODULES.html.sh (Users and groups): Mention it.
9148
9149         getgroups: don't expose GETGROUPS_T to user
9150         * lib/getgroups.c (rpl_getgroups): Change signature.  Copy array
9151         an element at a time if GETGROUPS_T is wrong size.
9152         * lib/getugroups.h (getugroups): Change signature.
9153         * lib/unistd.in.h (getgroups): Likewise.
9154         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Use replacement if
9155         signature needs fixing.
9156         * m4/getugroups.m4 (gl_GETUGROUPS): No longer need
9157         AC_TYPE_GETGROUPS.
9158         * modules/group-member (Depends-on): Add getgroups.
9159         * lib/group-member.c (group_info, get_group_info): Use gid_t.
9160         (group_member): Rely on getgroups replacement.
9161         * lib/getugroups.c (getugroups): Use gid_t.
9162         * tests/test-getgroups.c (main): Likewise.
9163         * NEWS: Mention the signature change.
9164         * doc/posix-functions/getgroups.texi (getgroups): Mention the
9165         problem with signature.
9166         * doc/glibc-functions/setgroups.texi (setgroups): Mention that
9167         GETGROUPS_T is still useful for setgroups.
9168
9169         getgroups, getugroups: provide stubs for mingw
9170         * lib/getgroups.c (getgroups): Provide ENOSYS stub for mingw.
9171         * lib/getugroups.c (getugroups): Likewise.
9172         * m4/getgroups.m4 (gl_FUNC_GETGROUPS): Check for missing
9173         function.  Modernize replacement scheme.
9174         (gl_PREREQ_GETGROUPS): Delete.
9175         * m4/getugroups.m4 (gl_GETUGROUPS): Check for <grp.h>.
9176         * modules/getgroups (configure.ac): Declare witness.
9177         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add default.
9178         * modules/unistd (Depends-on): Substitute witness.
9179         * lib/unistd.in.h (getgroups): Declare replacement.
9180
9181         getgroups: avoid calling exit
9182         * modules/getgroups (Depends-on): Add malloc-posix and unistd,
9183         drop xalloc.
9184         * modules/getgroups-tests (Depends-on, Makefile.am): Drop unneeded
9185         dependencies.
9186         * lib/getgroups.c (rpl_getgroups): Fail with ENOMEM rather than
9187         exiting, in the rare case of malloc failure.
9188
9189         getgroups: fix logic error
9190         * lib/getgroups.c (rpl_getgroups): Don't fail if current process
9191         has more than 20 groups.
9192         * modules/getgroups-tests: New test.
9193         * tests/test-getgroups.c: New file.
9194
9195 2009-11-13  Simon Josefsson  <simon@josefsson.org>
9196
9197         * tests/test-base64.c: Improve.
9198
9199 2009-11-13  Simon Josefsson  <simon@josefsson.org>
9200
9201         * tests/test-xvasprintf.c: Fix memory leak, suggested by Eric
9202         Blake <ebb9@byu.net>.
9203
9204 2009-11-13  Simon Josefsson  <simon@josefsson.org>
9205
9206         * tests/test-xvasprintf.c: Add %s%s related checks.
9207
9208 2009-11-12  Eric Blake  <ebb9@byu.net>
9209
9210         version-etc: match standards.texi style
9211         * lib/version-etc.c (emit_bug_reporting_address): Drop periods,
9212         and use <> only for URLs.
9213
9214 2009-11-10  Kamil Dudka  <kdudka@redhat.com>
9215
9216         fts: do not fail on a submount during traversal
9217         * lib/fts.c (fts_build): Read the stat info again after opening
9218         a directory if the FTS_TIGHT_CYCLE_CHECK flag is set.
9219         Original report at http://bugzilla.redhat.com/501848.
9220
9221 2009-11-12  Jim Meyering  <meyering@redhat.com>
9222
9223         bootstrap: sync from coreutils
9224         * build-aux/bootstrap (bootstrap_epilogue): New function.
9225         Use git_modules_config in one more place.  This make bootstrap's
9226         --gnulib-srcdir option more useful for testing.
9227
9228         bootstrap: generalize autoheader check
9229         * build-aux/bootstrap: Look for AC_CONFIG_HEADER as well as
9230         AC_CONFIG_HEADERS.
9231
9232 2009-11-11  Eric Blake  <ebb9@byu.net>
9233
9234         mkfifoat: use new modules for Solaris and BSD bugs
9235         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Simplify.
9236         * lib/mkfifoat.c (mknodat): Split...
9237         * lib/mknodat.c (mknodat): ...into new file.
9238         * modules/mkfifoat (Files): Ship new file.
9239         (Depends-on): Add mkfifo, mknod.
9240         * modules/mkfifoat-tests (Files): Reuse mkfifo tests.
9241         (Depends-on): Add symlink.
9242         * tests/test-mkfifoat.c (main): Enhance test.  Drop portions now
9243         redundant with test_mkfifo.h.
9244         (do_mkfifoat, do_mknodat): New helpers.
9245
9246         mknod: new module
9247         * modules/mknod: New file.
9248         * m4/mknod.m4 (gl_FUNC_MKNOD): Likewise.
9249         * lib/mknod.c (mknod): Likewise.
9250         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
9251         defaults.
9252         * modules/sys_stat (Makefile.am): Substitute them.
9253         * lib/sys_stat.in.h (mknod): Declare replacement.
9254         * MODULES.html.sh (Support for systems lacking POSIX:2008):
9255         Document it.
9256         * doc/posix-functions/mknod.texi (mknod): Likewise.
9257         * modules/mknod-tests: New test.
9258         * tests/test-mknod.c: Likewise.
9259
9260         mkfifo: new module
9261         * modules/mkfifo: New file.
9262         * m4/mkfifo.m4 (gl_FUNC_MKFIFO): Likewise.
9263         * lib/mkfifo.c (mkfifo): Likewise.
9264         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Set witness
9265         defaults.
9266         * modules/sys_stat (Makefile.am): Substitute them.
9267         * lib/sys_stat.in.h (mkfifo): Declare replacement.
9268         * MODULES.html.sh (Support for systems lacking POSIX:2008):
9269         Document it.
9270         * doc/posix-functions/mkfifo.texi (mkfifo): Likewise.
9271         * modules/mkfifo-tests: New test.
9272         * tests/test-mkfifo.h (test_mkfifo): New file, borrowed in part
9273         from test-mkfifoat.c.
9274         * tests/test-mkfifo.c: New file.
9275
9276         readlink: detect FreeBSD bug
9277         * m4/readlink.m4 (gl_FUNC_READLINK): Also detect FreeBSD bug with
9278         slash on symlink.
9279         * doc/posix-functions/readlink.texi (readlink): Document the bug.
9280         * tests/test-readlink.h (test_readlink): Enhance test.
9281
9282         symlink: detect FreeBSD bug
9283         * m4/symlink.m4 (gl_FUNC_SYMLINK): Also detect FreeBSD bug with
9284         slash on symlink.
9285         * doc/posix-functions/symlink.texi (symlink): Document the bug.
9286         * tests/test-symlink.h (test_symlink): Enhance test.
9287
9288 2009-11-10  Eric Blake  <ebb9@byu.net>
9289
9290         link: detect FreeBSD bug
9291         * m4/link.m4 (gl_FUNC_LINK): Also detect FreeBSD bug with slash on
9292         symlink.
9293         * doc/posix-functions/link.texi (link): Document the bug.
9294         * tests/test-link.h (test_link): Enhance test.
9295         * tests/test-linkat.c (main): Update caller.
9296
9297         unlink, remove: detect FreeBSD bug
9298         * m4/unlink.m4 (gl_FUNC_UNLINK): Also detect FreeBSD bug with
9299         slash on symlink.
9300         * doc/posix-functions/unlink.texi (unlink): Document the bug.
9301         * doc/posix-functions/remove.texi (remove): Likewise.
9302         * tests/test-unlink.h (test_unlink): Enhance test.
9303         * tests/test-remove.c (main): Likewise.
9304
9305 2009-11-09  Eric Blake  <ebb9@byu.net>
9306
9307         rename: detect FreeBSD bug
9308         * m4/rename.m4 (gl_FUNC_RENAME): Also detect FreeBSD bug with
9309         slash on symlink.
9310         * modules/renameat-tests (Depends-on): Add filenamecat.
9311         * tests/test-rename.h (test_rename): Allow one more errno.
9312         * tests/test-renameat.c (main): Likewise.
9313         * doc/posix-functions/rename.texi (rename): Document the bug.
9314
9315         open: detect FreeBSD bug
9316         * m4/open.m4 (gl_FUNC_OPEN): Also detect FreeBSD bug with slash on
9317         symlink.
9318         * doc/posix-functions/open.texi (open): Document the bug.
9319         * doc/posix-functions/utimes.texi (utimes): Likewise.
9320         * tests/test-open.h (test_open): Add parameters, and test symlink
9321         handling.
9322         * tests/test-open.c (main): Adjust caller.
9323         * tests/test-fcntl-safer.c (main): Likewise.
9324         * modules/open-tests (Depends-on): Add stdbool, symlink.
9325         * modules/fcntl-safer-tests (Depends-on): Likewise.
9326         * tests/test-openat.c (main): Add test-open tests.
9327
9328         stat: detect FreeBSD bug
9329         * m4/stat.m4 (gl_FUNC_STAT): Also detect FreeBSD bug with slash on
9330         symlink.
9331         * doc/posix-functions/stat.texi (stat): Document the bug.
9332         * tests/test-stat.h (test_stat_func): Add argument.
9333         * tests/test-stat.c (main): Adjust caller.
9334         * tests/test-fstatat.c (main): Likewise.
9335         * modules/stat-tests (Depends-on): Add stdbool, symlink.
9336         Reported by Jim Meyering.
9337
9338 2009-11-09  James Youngman  <jay@gnu.org>
9339
9340         strftime.c: include ignore-value.h only when FPRINTFTIME is defined
9341         * lib/strftime.c: Correct placement of #include "ignore-value.h".
9342
9343 2009-11-08  Jim Meyering  <meyering@redhat.com>
9344
9345         utimens: remove invalid futimesat call
9346         * lib/utimens.c (fdutimens): Remove invalid futimesat call.
9347         It used the file descriptor of the target file as the DIR_FD
9348         parameter and NULL as the file name.  That caused failure with
9349         errno == EFAULT on FreeBSD-8.0-rc2
9350
9351 2009-11-07  Eric Blake  <ebb9@byu.net>
9352
9353         fflush, freadseek: use fseeko, not fseek
9354         * lib/fflush.c (clear_ungetc_buffer_preserving_position)
9355         (clear_ungetc_buffer): Avoid potential problems on large files.
9356         * lib/freadseek.c (freadseek): Likewise.
9357         * modules/freadseek (Depends-on): Add fseeko.
9358         * modules/fseek (configure.ac): Set a witness.
9359         * tests/test-fflush.c (main): Use fseeko.
9360         * tests/test-fpurge.c (fseek): Disable link warning.
9361         * tests/test-freadable.c (fseek): Likewise.
9362         * tests/test-freading.c (fseek): Likewise.
9363         * tests/test-fseeko.c (fseek): Likewise.
9364         * tests/test-ftell.c (fseek): Likewise.
9365         * tests/test-ftello.c (fseek): Likewise.
9366         * tests/test-fwritable.c (fseek): Likewise.
9367         * tests/test-fwriting.c (fseek): Likewise.
9368
9369 2009-11-06  Simon Josefsson  <simon@josefsson.org>
9370
9371         * modules/memchr (Depends-on): Drop getpagesize dependency.
9372
9373 2009-11-06  Simon Josefsson  <simon@josefsson.org>
9374
9375         * build-aux/pmccabe2html: Disable execute bit.  Suggested by
9376         Reported by Ludovic Courtès.
9377         * build-aux/pmccabe2html: Improve example usage.
9378         * build-aux/pmccabe2html: Drop #! header.  Doc fix.
9379
9380 2009-11-06  Jim Meyering  <meyering@redhat.com>
9381
9382         do-release-commit-and-tag: New module.
9383         Automate the release-commit and tag process.
9384         * build-aux/do-release-commit-and-tag: New script, from coreutils.
9385         * modules/do-release-commit-and-tag: New file.
9386         * MODULES.html.sh (Support for maintaining and releasing): Add it.
9387
9388 2009-11-06  Simon Josefsson  <simon@josefsson.org>
9389
9390         * modules/select-tests (test_select_LDADD): Add $(INET_PTON_LIB)
9391         because test-select.c uses inet_pton.
9392
9393 2009-11-06  Simon Josefsson  <simon@josefsson.org>
9394
9395         * m4/getaddrinfo.m4: Add content of INET_NTOP_LIB to
9396         GETADDRINFO_LIB.  Bump serial number.
9397         * modules/getaddrinfo (Link): Only mention GETADDRINFO_LIB again.
9398         Suggested by Eric Blake <ebb9@byu.net>.
9399
9400 2009-11-05  Eric Blake  <ebb9@byu.net>
9401
9402         strtod: detect darwin bug
9403         * m4/strtod.m4 (gl_FUNC_STRTOD): Filter out darwin bug on "nan(".
9404         Reported by Leo Davis.
9405
9406         freopen-safer: new module
9407         * modules/freopen-safer: New module.
9408         * m4/stdio-safer.m4 (gl_FREOPEN_SAFER): New macro.
9409         * lib/freopen-safer.c (freopen_safer): New file.
9410         * lib/stdio-safer.h (freopen_safer): New declaration.
9411         * lib/stdio--.h (freopen): New override.
9412         * MODULES.html.sh (File stream based Input/Output): Mention it.
9413         * doc/posix-functions/freopen.texi (freopen): Mention pitfalls and
9414         freopen-safer module.
9415         * doc/posix-functions/stderr.texi (stderr): Likewise.
9416         * doc/posix-functions/stdin.texi (stdin): Likewise.
9417         * doc/posix-functions/stdout.texi (stdout): Likewise.
9418         * modules/freopen-safer-tests: New test.
9419         * tests/test-reopen-safer.c: New file.
9420
9421 2009-11-05  Jim Meyering  <meyering@redhat.com>
9422
9423         maint.mk: Prohibit inclusion of "close-stream.h" without use.
9424         * top/maint.mk (sc_prohibit_close_stream_without_use): New rule.
9425
9426 2009-11-05  Simon Josefsson  <simon@josefsson.org>
9427
9428         * modules/pmccabe2html (configure.ac): Check for pmccabe tool.
9429
9430 2009-11-05  Simon Josefsson  <simon@josefsson.org>
9431
9432         * modules/getaddrinfo (Link): Add $(INET_NTOP_LIB).
9433
9434 2009-11-05  Simon Josefsson  <simon@josefsson.org>
9435
9436         Fix link error.
9437         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
9438         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
9439
9440 2009-11-05  Simon Josefsson  <simon@josefsson.org>
9441
9442         * tests/test-func.c: Also test value of __func__.
9443
9444 2009-11-05  Simon Josefsson  <simon@josefsson.org>
9445
9446         * tests/test-sys_socket.c: Use smaller constant value, sa_family_t
9447         may be an 8-bit type.  Reported by Bruno Haible <bruno@clisp.org>.
9448
9449 2009-11-05  Bruno Haible  <bruno@clisp.org>
9450
9451         Fix link error.
9452         * m4/inet_ntop.m4 (gl_INET_NTOP): Fix test of AC_SEARCH_LIBS result.
9453         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
9454         Reported by Brad Hards <bradh@frogmouth.net> via Simon Josefsson.
9455
9456 2009-11-05  Bruno Haible  <bruno@clisp.org>
9457
9458         Tests for module 'inet_pton'.
9459         * modules/inet_pton-tests: New file.
9460         * tests/test-inet_pton.c: New file.
9461
9462 2009-11-05  Bruno Haible  <bruno@clisp.org>
9463
9464         Tests for module 'inet_ntop'.
9465         * modules/inet_ntop-tests: New file.
9466         * tests/test-inet_ntop.c: New file.
9467
9468 2009-11-04  Eric Blake  <ebb9@byu.net>
9469
9470         stdlib-safer: wrap all mkstemp variants
9471         * modules/mkostemp (configure.ac): Set witness.
9472         * modules/mkostemps (configure.ac): Likewise.
9473         * modules/mkstemps (configure.ac): Likewise.
9474         * lib/stdlib-safer.h (mkostemp_safer, mkostemps_safer)
9475         (mkstemps_safer): Wrap more functions.
9476         * lib/stdlib--.h (mkostemp, mkostemps, mkstemps): Default the
9477         wrapping.
9478         * lib/mkstemp-safer.c (mkostemp_safer, mkostemps_safer)
9479         (mkstemps_safer): Implement the wrappers.
9480
9481         mkstemps, mkostemps: new modules
9482         * modules/mkostemps: New module.
9483         * modules/mkstemps: Likewise.
9484         * lib/mkostemps.c (mkostemps): New file.
9485         * lib/mkstemps.c (mkstemps): Likewise.
9486         * m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Likewise.
9487         * m4/mkstemps.m4 (gl_FUNC_MKSTEMPS): Likewise.
9488         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add witnesses.
9489         * modules/stdlib (Makefile.am): Substitute them.
9490         * lib/stdlib.in.h (mkostemps, mkstemps): Declare them.
9491         * doc/glibc-functions/mkstemps.texi (mkstemps): New file.
9492         * doc/glibc-functions/mkostemps.texi (mkostemps): Likewise.
9493         * doc/gnulib.texi (Glibc stdlib.h): Include them.
9494         * MODULES.html.sh (File system functions): Mention them.
9495
9496         tempname: resync from glibc
9497         * lib/tempname.c (__gen_tempname): Add suffixlen argument.  Use
9498         same values for __GT_FILE as glibc.  Abort even when assertions
9499         are disabled.
9500         * lib/tempname.h (GT_FILE): Use glibc __GT_FILE, if available, and
9501         match its value otherwise.  Allow idempotent inclusion.
9502         * lib/mkdtemp.c (mkdtemp): Adjust caller.
9503         * lib/mkostemp.c (mkostemp): Likewise.
9504         * lib/mkstemp.c (mkstemp): Likewise.
9505         * lib/tmpfile.c (tmpfile): Likewise.
9506         * NEWS: Document this.
9507
9508         utimens: fix use of futimens on older Linux
9509         * lib/utimens.c (fdutimens): Use updated, rather than original,
9510         timespec to avoid bug in older Linux kernel.
9511         Reported by Simon Josefsson.
9512
9513 2009-11-04  Bruno Haible  <bruno@clisp.org>
9514
9515         Make num_processors more flexible and consistent.
9516         * lib/nproc.h (enum nproc_query): New type.
9517         (num_processors): Add a 'query' argument.
9518         * lib/nproc.c: Include <stdlib.h>, <sched.h>, c-ctype.h.
9519         (num_processors): Add a 'query' argument. Test the value of the
9520         OMP_NUM_THREADS environment variable if requested. On Linux, NetBSD,
9521         mingw, count the number of CPUs available for the current process.
9522         * m4/nproc.m4 (gl_PREREQ_NPROC): Require AC_USE_SYSTEM_EXTENSIONS.
9523         Check for sched_getaffinity and sched_getaffinity_np.
9524         * modules/nproc (Depends-on): Add c-ctype, extensions.
9525         * NEWS: Mention the change.
9526
9527 2009-11-03  Bruno Haible  <bruno@clisp.org>
9528
9529         * NEWS: Document the new library dependencies of inet_ntop, inet_pton.
9530
9531 2009-11-03  Jim Meyering  <meyering@redhat.com>
9532
9533         test-getaddrinfo: avoid compilation failure on FreeBSD 7.2
9534         * tests/test-getaddrinfo.c (simple): Test for EAI_NODATA only
9535         if it is defined.
9536
9537 2009-11-02  Eric Blake  <ebb9@byu.net>
9538
9539         mktime, timegm: share common declaration
9540         * lib/mktime-internal.h: New file.
9541         * lib/mktime.c: Use it rather than open-coding a declaration.
9542         * lib/timegm.c: Likewise.
9543         * modules/mktime (Files): Ship it.
9544         * modules/timegm (Files): Likewise.
9545         Suggested by Bruno Haible.
9546
9547         test-update-copyright: update test to match script changes
9548         * tests/test-update-copyright.sh: Avoid hard-coding perl
9549         location.  Don't update *.bak created by earlier runs.
9550
9551 2009-11-02  Paul Eggert  <eggert@cs.ucla.edu>
9552             Simon Josefsson  <simon@josefsson.org>
9553             Bruno Haible  <bruno@clisp.org>
9554
9555         Fix link error on Solaris 8.
9556         * m4/inet_pton.m4 (gl_INET_PTON): Search for the function inet_pton
9557         also in libnsl. Define also INET_PTON_LIB.
9558         * modules/inet_pton (Link): New section.
9559
9560 2009-11-02  Simon Josefsson  <simon@josefsson.org>
9561             Bruno Haible  <bruno@clisp.org>
9562
9563         * m4/inet_ntop.m4 (gl_INET_NTOP): Define also INET_NTOP_LIB.
9564         * modules/inet_ntop (Link): New section.
9565         Reported by Boyan Kasarov <bkasarov@gmail.com>.
9566
9567 2009-11-02  Eric Blake  <ebb9@byu.net>
9568
9569         maint: avoid compiler warnings in m4 macros
9570         * m4/ungetc.m4 (gl_FUNC_UNGETC_WORKS): Avoid unused variable.
9571         * m4/rmdir.m4 (gl_FUNC_RMDIR): Include correct header.
9572
9573 2009-11-02  Simon Josefsson  <simon@josefsson.org>
9574
9575         * m4/pmccabe2html.m4: Remove file.
9576         * modules/pmccabe2html: Drop pmccabe2html.m4.  Don't call m4
9577         function.  Change maintainer.
9578         * build-aux/pmccabe2html: Use /bin/sh with magic instead of
9579         hard-coding path to awk.  Tiny patch from ludo@gnu.org (Ludovic
9580         Courtès).
9581
9582 2009-10-31  Eric Blake  <ebb9@byu.net>
9583
9584         fseeko: fix m4 regression
9585         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Use modern macro.  Fixes
9586         regression from 2009-10-27.
9587         Reported by Ralf Wildenhues.
9588
9589 2009-10-31  Jim Meyering  <meyering@redhat.com>
9590
9591         inttostr: aesthetics and improved (compile-time) safety
9592         Define inttype_is_signed rather than inttype_is_unsigned,
9593         since the sole use is via "#if inttype_is_signed".
9594         * lib/imaxtostr.c (inttype_is_signed): Define this, rather than
9595         inttype_is_unsigned.
9596         * lib/offtostr.c (inttype_is_signed): Likewise.
9597         * lib/uinttostr.c (inttype_is_signed): Likewise.
9598         * lib/umaxtostr.c (inttype_is_signed): Likewise.
9599         * lib/inttostr.c (inttostr): Use verify to cross-check the
9600         inttype_is_signed value and the signedness of the actual type.
9601         * modules/inttostr (Depends-on): Add verify.
9602
9603 2009-10-30  Eric Blake  <ebb9@byu.net>
9604
9605         build: avoid compiler warnings
9606         * lib/fchmodat.c (lchmod): Mark unused variables.
9607         * lib/getopt.c (_getopt_initialize): Likewise.
9608         * lib/mktime.c (__mktime_internal): Provide prototype.
9609         * lib/inttostr.c (inttostr): Avoid compiler warning even with
9610         older gcc that do not understand #pragma GCC diagnostic.
9611         * lib/uinttostr.c (inttype_is_unsigned): Define.
9612         * lib/umaxtostr.c (inttype_is_unsigned): Likewise.
9613
9614 2009-10-30  Michael Haubenwallner  <michael.haubenwallner@salomon.at>
9615
9616         stat: fix compilation on AIX
9617         * lib/sys_stat.in.h (stat): Work with fact that large files on AIX
9618         only see struct stat64.
9619
9620 2009-10-30  Eric Blake  <ebb9@byu.net>
9621
9622         exclude: make more robust
9623         * lib/exclude.c (excluded_file_name): Abort on unexpected value,
9624         rather than masking a coding bug.
9625         Suggested by Bruno Haible.
9626
9627 2009-10-30  Jim Meyering  <meyering@redhat.com>
9628
9629         perl scripts: remove #!/usr/bin/perl in favor of more portable...
9630         Rather than putting #!/usr/bin/perl on the first line,
9631         start with a variant of what's recommended by "man perlrun" that
9632         invokes the first "perl" program from your shell's search path.
9633         * build-aux/gitlog-to-changelog: Replace #!... as above.
9634         Add a "Local Variables" perl mode setting.
9635         Prompted by a patch from Ludovic Courtès.
9636         Improved by Eric Blake.
9637         * build-aux/useless-if-before-free: Likewise.
9638         * build-aux/announce-gen: Likewise.
9639         * build-aux/update-copyright: Likewise.
9640
9641 2009-10-29  Eric Blake  <ebb9@byu.net>
9642
9643         filenamecat-lgpl: adjust clients
9644         * modules/linkat (Depends-on): Use filenamecat-lgpl, not
9645         filenamecat.
9646         * modules/renameat (Depends-on): Likewise.
9647
9648         filenamecat: split into filenamecat-lgpl
9649         * modules/filenamecat-lgpl: New module.
9650         * modules/filenamecat (Files): Move library-safe files into
9651         filenamecat-lgpl.
9652         (Depends-on): Add filenamecat-lgpl.
9653         (configure.ac): Declare witness.
9654         * lib/filenamecat.h (file_name_concat): Only declare when using
9655         GPL module.
9656         * lib/filenamecat.c (longest_relative_suffix, mfile_name_concat):
9657         Move...
9658         * lib/filenamecat-lgpl.c: ...into new file.
9659         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT_LGPL): New macro.
9660         (gl_FILE_NAME_CONCAT): Use it.
9661         * MODULES.html.sh (File system functions): Mention new module.
9662
9663         argp: avoid memory leak
9664         * modules/argp (Depends-on): Use dirname-lgpl, not dirname.
9665         * lib/argp-namefrob.h (__argp_base_name): Use last_component, not
9666         base_name, since the latter malloc()s and can call exit().
9667         Leak introduced 2006-07-03.
9668
9669         dirname-lgpl: adjust clients that don't need full dirname
9670         * modules/backupfile (Depends-on): Use dirname-lgpl, not dirname.
9671         * modules/filenamecat (Depends-on): Likewise.
9672         * modules/linkat (Depends-on): Likewise.
9673         * modules/mkancesdirs (Depends-on): Likewise.
9674         * modules/mkdir (Depends-on): Likewise.
9675         * modules/openat (Depends-on): Likewise.
9676         * modules/savewd (Depends-on): Likewise.
9677         * modules/rename (Depends-on): Likewise.
9678         (License): Relax license.
9679         * modules/mkdir-tests (Depends-on): Drop progname.
9680         (Makefile.am): Delete unneeded LDADD.
9681         * modules/rename-tests (Depends-on, Makefile.am): Likewise.
9682
9683         dirname: split into dirname-lgpl
9684         * modules/dirname-lgpl: New module.
9685         * modules/dirname (Files): Move library-safe files into
9686         dirname-lgpl.
9687         (Depends-on): Add dirname-lgpl.
9688         (configure.ac): Declare witness.
9689         * modules/double-slash-root (License): Relax license.
9690         * lib/dirname.h (base_name, dir_name): Only declare when using GPL
9691         module.
9692         * lib/dirname.c (dir_len, mdir_name): Move...
9693         * lib/dirname-lgpl.c: ...into new file.
9694         * lib/basename.c (last_component, base_len): Move...
9695         * lib/basename-lgpl.c: ...into new file.
9696         * m4/dirname.m4 (gl_DIRNAME_LGPL): New macro.
9697         (gl_DIRNAME): Use it.
9698         * MODULES.html.sh (Enhancements for POSIX:2008 functions):
9699         Mention new module.
9700         * modules/dirname-tests (Depends-on): Add progname.
9701         * tests/test-dirname.c (program_name): Delete.
9702
9703         mkdir: make safe for libraries
9704         * modules/mkdir (Depends-on): Drop xalloc.
9705         * lib/mkdir.c (rpl_mkdir): Fail with ENOMEM rather than calling
9706         exit.
9707
9708         tests: avoid some compiler warnings
9709         * tests/test-getaddrinfo.c (simple): Mark static, and allow string
9710         literals.
9711         * tests/test-memchr.c (main): Avoid type mismatch.
9712         * tests/test-arpa_inet.c (main): Avoid unused parameters.
9713         * tests/test-base64.c (main): Likewise.
9714         * tests/test-getdelim.c (main): Likewise.
9715         * tests/test-gethostname.c (main): Likewise.
9716         * tests/test-getline.c (main): Likewise.
9717         * tests/test-netinet_in.c (main): Likewise.
9718         * tests/test-select.c (open_server_socket, main): Likewise.
9719         * tests/test-select-stdin.c (main): Likewise.
9720         * tests/test-sockets.c (main): Likewise.
9721         * tests/test-strsignal.c (main): Likewise.
9722         * tests/test-sys_select.c (main): Likewise.
9723         * tests/test-sys_socket.c (main): Likewise.
9724         * tests/test-u64.c (main): Likewise.
9725         * tests/test-xfprintf-posix.c (main): Likewise.
9726         * tests/test-xvasprintf.c (test_xvasprintf, main): Likewise.
9727
9728         sockets: avoid compiler warning
9729         * lib/sockets.c (gl_sockets_startup): Mark unused parameter.
9730
9731         maint: detect usage(1) and other suspicious exits
9732         * top/maint.mk (sc_prohibit_magic_number_exit): New rule.
9733
9734 2009-10-29  Jim Meyering  <meyering@redhat.com>
9735
9736         timespec: long-to-int truncation could make timespec_cmp malfunction
9737         * lib/timespec.h (timespec_cmp): Do not interpret a difference of
9738         a multiple of 2^32 nanoseconds as no difference.
9739
9740 2009-10-28  Jim Meyering  <meyering@redhat.com>
9741
9742         fprintftime: wrap macro code argument in "do {...} while(0)"
9743         * lib/strftime.c (cpy) [FPRINTFTIME]: The second argument to the
9744         cpy macro must be a statement that can be followed by a semicolon.
9745         Now that the else clause contains a comment and is hence longer
9746         than one line, I require curly braces.  That in turn requires
9747         that we wrap this code block in the standard do...while(0).
9748
9749         fprintftime: remove stray semicolon from previous change
9750         * lib/strftime.c (cpy) [FPRINTFTIME]: Remove trailing semicolon.
9751
9752         fprintftime: avoid a warning about ignored fwrite return value
9753         * lib/strftime.c [FPRINTFTIME]: Include "ignore-value.h".
9754         (cpy) [FPRINTFTIME]: Ignore fwrite failure, even though technically,
9755         that is unsafe.
9756         * modules/fprintftime (Depends-on): Add ignore-value.
9757
9758         exclude: avoid an unwarranted warning
9759         * lib/exclude.c (excluded_file_name): Initialize "rc" before switch.
9760
9761 2009-10-27  Eric Blake  <ebb9@byu.net>
9762
9763         fseek: avoid compilation failure when fflush is replaced
9764         * m4/fseek.m4 (gl_REPLACE_FSEEK): New macro.
9765         * m4/fseeko.m4 (gl_REPLACE_FSEEKO): Also replace fseek, if fseek
9766         module is in use.
9767         * lib/stdio.in.h (GNULIB_FSEEKO): Only poison fseek if fseek
9768         module is not in use; since REPLACE_FSEEK worked otherwise.
9769         (GNULIB_FTELLO): Likewise for ftell.
9770         Reported by Ian Beckwith and others.
9771
9772 2009-10-27  Bruno Haible  <bruno@clisp.org>
9773
9774         * lib/isnan.c (rpl_isnan[fdl]): Repeat the specification declaration.
9775         Reported by Jim Meyering.
9776
9777 2009-10-27  Jim Meyering  <jim@meyering.net>
9778             Bruno Haible  <bruno@clisp.org>
9779
9780         Avoid warning despite dropping the return value of fwrite.
9781         * lib/unicodeio.c: Include ignore-value.h.
9782         (fwrite_success_callback): Explicitly ignore fwrite's return value.
9783         * modules/unicodeio (Depends-on): Add ignore-value.
9784
9785 2009-10-26  Eric Blake  <ebb9@byu.net>
9786
9787         areadlinkat: fix fallback path
9788         * lib/at-func.c (AT_FUNC_NAME): Avoid signed comparison between
9789         pointer and zero.
9790
9791 2009-10-22  Pádraig Brady  <P@draigBrady.com>
9792
9793         Use a better IO block size for modern systems
9794         * lib/copy-file.c (copy_file_preserving): Used a 32KiB malloced buffer.
9795         * lib/md2.c: Likewise.
9796         * lib/md4.c: Likewise.
9797         * lib/md5.c: Likewise.
9798         * lib/sha1.c: Likewise.
9799         * lib/sha256.c: Likewise.
9800         * lib/sha512.c: Likewise.
9801
9802 2009-10-22  Eric Blake  <ebb9@byu.net>
9803
9804         tests: avoid several compiler warnings
9805         * tests/test-getcwd.c (main): Avoid buffer underflow.
9806         * tests/test-getdate.c (main): String literals are not safe with
9807         putenv, so use setenv.  Declare unused argument.
9808         * modules/getdate-tests (Depends-on): Add setenv.
9809         * tests/test-argv-iter.c (main): Declare unused argument.  Avoid
9810         problems with string literals in char *.
9811         * tests/test-hash.c (main): Avoid shadowing declaration.
9812         (insert_new): Treat string literals as char const *.
9813         * tests/test-getopt.h (test_getopt): Likewise.
9814         (getopt_loop): Alter types to minimize casting elsewhere.
9815         * tests/test-getopt_long.h (test_getopt_long, getopt_long_loop)
9816         (test_getopt_long_posix): Likewise.
9817         (do_getopt_long): Add wrapper to minimize casting.
9818         * tests/test-atexit.c (clear_temp_file): Use void.
9819         * tests/test-areadlink-with-size.c (main): Declare unused
9820         arguments.
9821         * tests/test-areadlink.c (main): Likewise.
9822         * tests/test-areadlinkat-with-size.c (main): Likewise.
9823         * tests/test-areadlinkat.c (main): Likewise.
9824         * tests/test-canonicalize-lgpl.c (main): Likewise.
9825         * tests/test-canonicalize.c (main): Likewise.
9826         * tests/test-dirent-safer.c (main): Likewise.
9827         * tests/test-dirname.c (main): Likewise.
9828         * tests/test-dup2.c (main): Likewise.
9829         * tests/test-fchdir.c (main): Likewise.
9830         * tests/test-fcntl-h.c (main): Likewise.
9831         * tests/test-fcntl-safer.c (main): Likewise.
9832         * tests/test-fdopendir.c (main): Likewise.
9833         * tests/test-fdutimensat.c (main): Likewise.
9834         * tests/test-fflush.c (main): Likewise.
9835         * tests/test-filenamecat.c (main): Likewise.
9836         * tests/test-filevercmp.c (main): Likewise.
9837         * tests/test-fopen-safer.c (main): Likewise.
9838         * tests/test-fopen.c (main): Likewise.
9839         * tests/test-fpending.c (main): Likewise.
9840         * tests/test-fpurge.c (main): Likewise.
9841         * tests/test-freading.c (main): Likewise.
9842         * tests/test-fstatat.c (main): Likewise.
9843         * tests/test-fsync.c (main): Likewise.
9844         * tests/test-futimens.c (main): Likewise.
9845         * tests/test-getndelim2.c (main): Likewise.
9846         * tests/test-gettimeofday.c (main): Likewise.
9847         * tests/test-getopt.c (main): Likewise.
9848         * tests/test-i-ring.c (main): Likewise.
9849         * tests/test-inttypes.c (main): Likewise.
9850         * tests/test-link.c (main): Likewise.
9851         * tests/test-lstat.c (main): Likewise.
9852         * tests/test-math.c (main): Likewise.
9853         * tests/test-md5.c (main): Likewise.
9854         * tests/test-memchr2.c (main): Likewise.
9855         * tests/test-memrchr.c (main): Likewise.
9856         * tests/test-mkdir.c (main): Likewise.
9857         * tests/test-mkdirat.c (main): Likewise.
9858         * tests/test-mkfifoat.c (main): Likewise.
9859         * tests/test-open.c (main): Likewise.
9860         * tests/test-openat-safer.c (main): Likewise.
9861         * tests/test-openat.c (main): Likewise.
9862         * tests/test-quotearg.c (main): Likewise.
9863         * tests/test-rawmemchr.c (main): Likewise.
9864         * tests/test-readlink.c (main): Likewise.
9865         * tests/test-remove.c (main): Likewise.
9866         * tests/test-rename.c (main): Likewise.
9867         * tests/test-renameat.c (main): Likewise.
9868         * tests/test-rmdir.c (main): Likewise.
9869         * tests/test-sha1.c (main): Likewise.
9870         * tests/test-signal.c (main): Likewise.
9871         * tests/test-sigaction.c (main): Likewise.
9872         * tests/test-stat.c (main): Likewise.
9873         * tests/test-stat-time.c (main): Likewise.
9874         * tests/test-stddef.c (main): Likewise.
9875         * tests/test-stdint.c (main): Likewise.
9876         * tests/test-stdio.c (main): Likewise.
9877         * tests/test-stdlib.c (main): Likewise.
9878         * tests/test-strchrnul.c (main): Likewise.
9879         * tests/test-strerror.c (main): Likewise.
9880         * tests/test-string.c (main): Likewise.
9881         * tests/test-strtod.c (main): Likewise.
9882         * tests/test-strverscmp.c (main): Likewise.
9883         * tests/test-symlink.c (main): Likewise.
9884         * tests/test-symlinkat.c (main): Likewise.
9885         * tests/test-sys_stat.c (main): Likewise.
9886         * tests/test-sys_time.c (main): Likewise.
9887         * tests/test-time.c (main): Likewise.
9888         * tests/test-unistd.c (main): Likewise.
9889         * tests/test-unlink.c (main): Likewise.
9890         * tests/test-unlinkat.c (main): Likewise.
9891         * tests/test-utimens.c (main): Likewise.
9892         * tests/test-utimensat.c (main): Likewise.
9893         * tests/test-version-etc.c (main): Likewise.
9894         * tests/test-wchar.c (main): Likewise.
9895         * tests/test-wctype.c (main): Likewise.
9896         * tests/test-xprintf-posix.c (main): Likewise.
9897         * tests/test-posixtm.c (main): Likewise.
9898         (STREQ): Delete unused macro.
9899         * tests/test-linkat.c (main): Declare unused arguments.  Avoid
9900         shadowed variables.
9901         * tests/test-memchr.c (main): Likewise.
9902
9903 2009-10-21  Eric Blake  <ebb9@byu.net>
9904
9905         areadlinkat: avoid failure on older glibc
9906         * lib/at-func.c (AT_FUNC_NAME): Check for explicit FUNC_FAIL,
9907         rather than mis-comparing 0 against FUNC_RESULT of char*.
9908
9909 2009-10-21  Bruno Haible  <bruno@clisp.org>
9910
9911         * modules/stpncpy (License): Relicense under LGPLv2+.
9912         Reported by David Lutterkort <lutter@redhat.com>.
9913
9914 2009-10-20  Eric Blake  <ebb9@byu.net>
9915
9916         utimensat: work around Solaris 9 bug
9917         * lib/utimens.c (fdutimens, lutimens): Force a stat if platform
9918         has trailing slash bugs.
9919         * tests/test-lutimens.h (test_lutimens): Enhance test.
9920         * tests/test-utimens.h (test_utimens): Likewise.
9921         * doc/posix-functions/utime.texi (utime): Enhance documentation.
9922         * doc/posix-functions/utimes.texi (utimes): Likewise.
9923         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
9924         * doc/glibc-functions/futimesat.texi (futimesat): Likewise.
9925         * doc/glibc-functions/lutimes.texi (lutimes): Likewise.
9926         * doc/posix-functions/futimens.texi (futimens): Likewise.
9927
9928         fdutimensat: new module
9929         * modules/fdutimensat: New file.
9930         * lib/fdutimensat.c (fdutimensat): Likewise.
9931         * lib/utimens.h (fdutimensat, lutimensat): Declare new functions.
9932         * MODULES.html.sh (File system functions): Mention module.
9933         * modules/fdutimensat-tests: New test.
9934         * tests/test-fdutimensat.c: Likewise.
9935
9936         doc: regenerate INSTALL
9937         * doc/INSTALL: Reflect recent autoconf update.
9938         * doc/INSTALL.ISO: Likewise.
9939         * doc/INSTALL.UTF-8: Likewise.
9940
9941 2009-10-20  Pádraig Brady  <P@draigBrady.com>
9942
9943         acl: warn if ACL support is not detected
9944         * m4/acl.m4 (gl_FUNC_ACL): Output a warning if ACL support is not found.
9945
9946 2009-10-19  Giuseppe Scrivano  <gscrivano@gnu.org>
9947
9948         * lib/nproc.h: Add extern "C" block for C++.
9949
9950 2009-10-18  Reuben Thomas  <rrt@sc3d.org>
9951             Bruno Haible  <bruno@clisp.org>
9952
9953         * doc/posix-functions/isascii.texi: Document the 2 alternative APIs.
9954         * doc/posix-functions/isalnum.texi: Document the 4 alternative APIs.
9955         * doc/posix-functions/isalpha.texi: Likewise.
9956         * doc/posix-functions/isblank.texi: Likewise.
9957         * doc/posix-functions/iscntrl.texi: Likewise.
9958         * doc/posix-functions/isdigit.texi: Likewise.
9959         * doc/posix-functions/isgraph.texi: Likewise.
9960         * doc/posix-functions/islower.texi: Likewise.
9961         * doc/posix-functions/isprint.texi: Likewise.
9962         * doc/posix-functions/ispunct.texi: Likewise.
9963         * doc/posix-functions/isspace.texi: Likewise.
9964         * doc/posix-functions/isupper.texi: Likewise.
9965         * doc/posix-functions/isxdigit.texi: Likewise.
9966
9967 2009-10-18  Bruno Haible  <bruno@clisp.org>
9968
9969         Tests for module 'isblank'.
9970         * modules/isblank-tests: New file.
9971         * tests/test-isblank.c: New file.
9972
9973         New module 'isblank'.
9974         * lib/isblank.c: New file.
9975         * m4/isblank.m4: New file.
9976         * modules/isblank: New file.
9977         * doc/posix-functions/isblank.texi: Mention the new module.
9978
9979 2009-10-18  Bruno Haible  <bruno@clisp.org>
9980
9981         New module 'ctype'.
9982         * lib/ctype.in.h: New file.
9983         * m4/ctype.m4: New file.
9984         * modules/ctype: New file.
9985         * doc/posix-headers/ctype.texi: Mention the new module.
9986
9987 2009-10-18  Jim Meyering  <meyering@redhat.com>
9988
9989         m4: stylistic-only: hoist AC_SUBST to be adjacent to initialization
9990         Declare a variable like LIB_CLOCK_GETTIME to be AC_SUBSTituted
9991         right after its initialization, rather than farther down.
9992         Keeping these in close proximity makes it easier to ensure
9993         that each such variable is initialized.  E.g.,
9994
9995             LIB_CLOCK_GETTIME=
9996             AC_SUBST([LIB_CLOCK_GETTIME])
9997
9998         This change also increments these serial numbers.
9999         * m4/clock_time.m4 (gl_CLOCK_TIME): Hoist AC_SUBST use.
10000         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
10001         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
10002
10003 2009-10-18  Bruno Haible  <bruno@clisp.org>
10004
10005         Don't let environment variables perturb build.
10006         * m4/gethrxtime.m4 (gl_GETHRXTIME): Initialize LIB_GETHRXTIME here...
10007         (gl_PREREQ_GETHRXTIME): ... not here.
10008
10009 2009-10-18  Bruno Haible  <bruno@clisp.org>
10010
10011         Avoid symlink attack in localcharset module.
10012         * lib/localcharset.c: Include <fcntl.h>, <unistd.h>.
10013         (O_NOFOLLOW): Define fallback.
10014         (get_charset_aliases): Don't open the file if it is a symbolic link.
10015         * m4/fcntl_h.m4 (gl_FCNTL_O_FLAGS): New macro, extracted from
10016         gl_FCNTL_H.
10017         (gl_FCNTL_H): Require it.
10018         * m4/localcharset.m4 (gl_LOCALCHARSET): Likewise.
10019         * modules/localcharset (Files): Add m4/fcntl_h.m4.
10020         Reported by Fergal Glynn <fglynn@veracode.com>.
10021
10022 2009-10-18  Bruno Haible  <bruno@clisp.org>
10023
10024         Implement nproc for mingw.
10025         * lib/nproc.c: Include <windows.h>
10026         (num_processors): On native Windows platforms, try GetSystemInfo.
10027
10028 2009-10-18  Bruno Haible  <bruno@clisp.org>
10029
10030         Implement nproc for IRIX.
10031         * lib/nproc.c: Include <sys/sysmp.h>.
10032         (num_processors): On IRIX systems, try sysmp.
10033         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/sysmp.h and sysmp.
10034
10035 2009-10-18  Bruno Haible  <bruno@clisp.org>
10036
10037         Implement nproc for HP-UX.
10038         * lib/nproc.c: Include <sys/pstat.h>
10039         (num_processors): On HP-UX systems, try pstat_getdynamic.
10040         * m4/nproc.m4 (gl_PREREQ_NPROC): Check for sys/pstat.h and
10041         pstat_getdynamic.
10042
10043 2009-10-18  Giuseppe Scrivano  <gscrivano@gnu.org>
10044             Bruno Haible  <bruno@clisp.org>
10045
10046         Implement nproc for NetBSD, OpenBSD.
10047         * lib/nproc.c: Include <sys/types.h>, <sys/param.h>, <sys/sysctl.h>.
10048         (ARRAY_SIZE): New macro.
10049         (num_processors): On BSD systems, try sysctl of HW_NCPU.
10050         * m4/nproc.m4: New file.
10051         * modules/nproc (Files): Add m4/nproc.m4.
10052         (configure.ac): Invoke gl_NPROC. Remove AC_LIBOBJ invocation.
10053         (Makefile.am): Instead, augment lib_SOURCES.
10054
10055 2009-10-18  Bruno Haible  <bruno@clisp.org>
10056
10057         Fix recognition of sys/sysctl.h on OpenBSD 4.0.
10058         * m4/physmem.m4 (gl_PHYSMEM): Before including sys/sysctl.h, include
10059         sys/param.h.
10060
10061 2009-10-16  Eric Blake  <ebb9@byu.net>
10062
10063         utimensat: new module
10064         * modules/utimensat: New file.
10065         * lib/utimensat.c (utimensat): Likewise.
10066         * m4/utimensat.m4 (gl_FUNC_UTIMENSAT): Likewise.
10067         * lib/utimens.c (utimensat): Avoid recursion into rpl_utimensat,
10068         so we can work around Linux bugs.
10069         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
10070         * modules/sys_stat (Makefile.am): Substitute them.
10071         * lib/sys_stat.in.h (utimensat): Declare it.
10072         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
10073         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
10074         * modules/utimensat-tests: New test.
10075         * tests/test-utimensat.c: Likewise.
10076
10077         utimens: let lutimens work on non-symlinks
10078         * lib/utimens.c (lutimens): Fall back to utimens rather than
10079         failing with ENOSYS, when file is not a symlink.
10080         (utimens): Reduce redirection.
10081         * tests/test-lutimens.h (test_lutimens): Update test to cover
10082         non-symlinks.
10083         * tests/test-utimens.h (test_utimens): Update test to cover
10084         symlinks.
10085         * tests/test-utimens.c (main): Update caller.
10086
10087         utimens: cache whether utimensat syscall works
10088         * lib/utimens.c (utimensat_works_really): New cache variable.
10089         (fdutimens, lutimens): Use it to avoid failing syscall.
10090
10091         test-stat-time, test-utimens: improve portability
10092         * tests/test-stat-time.c (nap): Lengthen delay to 20ms, for
10093         ext4 on alpha, and for cygwin.
10094         * tests/test-utimens-common.h: New file.
10095         (nap): Factor delays into single function.
10096         * tests/test-lutimens.h (test_lutimens): Use new header.
10097         * tests/test-futimens.h (test_futimens): Likewise.
10098         * tests/test-utimens.h (test_utimens): Likewise.  Also, force NFS
10099         timestamps to occur from same machine, as was done previously for
10100         test_utimens.
10101         * modules/utimens-tests (Files): Ship new file.
10102         * modules/futimens-tests (Files): Likewise.
10103         Reported in part by Jim Meyering.
10104
10105         sys_stat: sort replacement declarations
10106         * lib/sys_stat.in.h: Sort declarations.
10107         * lib/futimens.c (futimens): Fix typo.
10108
10109 2009-10-15  Jim Meyering  <meyering@redhat.com>
10110
10111         don't let environment settings perturb build
10112         Setting the envvars, LIB_CLOCK_GETTIME, LIB_EACCESS or LIB_NANOSLEEP
10113         could cause a configure-time and/or build-time malfunction.
10114         Typically, a configure-time function-in-library test is performed
10115         via code like this:
10116
10117           LIB_VAR=
10118           AC_SUBST([LIB_VAR])
10119           prefix_saved_LIBS=$LIBS
10120             AC_SEARCH_LIBS([FUNC], [LIB_NAME],
10121                        [test "$ac_cv_search_FUNC" = "none required" ||
10122                         LIB_VAR=$ac_cv_search_FUNC])
10123           LIBS=$prefix_saved_LIBS
10124
10125         However, in each of the files affected by this change, the LIB_VAR=
10126         initialization was omitted.  Thus, when set in the environment, its
10127         value would propagate into generated Makefiles when FUNC is not found
10128         in LIB_NAME.
10129         * m4/clock_time.m4 (gl_CLOCK_TIME): Initialize AC_SUBST'd var.
10130         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
10131         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
10132
10133 2009-10-14  Eric Blake  <ebb9@byu.net>
10134
10135         fchdir: avoid infinite recursion in mingw
10136         * lib/fchdir.c (rpl_fstat): Call system fstat, rather than
10137         recursing.
10138
10139         test-stat-time: port to mingw
10140         * tests/test-stat-time.c (force_unlink): Return a value.
10141         (test_ctime) [W32]: Fix compilation error.
10142         (nap): Don't call usleep with too large an argument.  Use
10143         force_unlink.
10144         * doc/pastposix-functions/usleep.texi (usleep): Document the
10145         portability issue.
10146
10147 2009-10-13  Jim Meyering  <meyering@redhat.com>
10148
10149         use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS in modules/*
10150         * modules/pipe-filter-gi: Use AC_CHECK_FUNCS_ONCE, not AC_CHECK_FUNCS.
10151         * modules/pipe-filter-ii: Likewise.
10152         * modules/sys_socket-tests: Likewise.
10153         * modules/tsearch-tests: Likewise.
10154         * Makefile (sc_prefer_ac_check_funcs_once): New rule.
10155         (check): Depend on it.
10156
10157 2009-10-12  Eric Blake  <ebb9@byu.net>
10158
10159         utimens-tests: port to NFS file systems
10160         * tests/test-utimens.h (test_utimens): Refactor utimecmp
10161         comparisons to avoid spurious failures from timestamp drift
10162         between NFS machines.
10163
10164 2009-10-12  Eric Blake  <ebb9@byu.net>
10165
10166         stat-time-tests: minor cleanups
10167         * modules/stat-time-tests (configure.ac): Use AC_CHECK_FUNCS_ONCE.
10168         * tests/test-stat-time.c (nap): Separate assignment from call.
10169         Suggested by Paolo Bonzini and Bruno Haible.
10170
10171         sys_stat: guarantee struct timespec
10172         * lib/sys_stat.in.h (includes): Always include <time.h>
10173         * modules/sys_stat (Depends-on): Add time.
10174         * tests/test-sys_stat.c: Guarantee struct timespec, as well as
10175         mode_t permission values.
10176         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document how to
10177         get at subsecond timestamps.
10178
10179 2009-10-10  Eric Blake  <ebb9@byu.net>
10180
10181         futimens: new module
10182         * modules/futimens: New file.
10183         * lib/futimens.c (futimens): Likewise.
10184         * m4/futimens.m4 (gl_FUNC_FUTIMENS): Likewise.
10185         * lib/utimens.c (futimens): Avoid recursion into rpl_futimens, so
10186         we can work around Linux bugs.
10187         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
10188         * modules/sys_stat (Makefile.am): Substitute them.
10189         * lib/sys_stat.in.h (futimens): Declare it.
10190         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
10191         * doc/posix-functions/futimens.texi (futimens): Likewise.
10192         * modules/futimens-tests: New test.
10193         * tests/test-futimens.c: Likewise.
10194
10195         utimens: introduce fdutimens
10196         * lib/utimens.h (fdutimens): New prototype.
10197         * lib/utimens.c (gl_futimens): Move guts...
10198         (fdutimens): ...to new interface.
10199         * tests/test-utimens.c (do_fdutimens): Use it.
10200
10201         utimens: add UTIME_NOW and UTIME_OMIT support
10202         * lib/utimens.c (validate_timespec, update_timespec): New helper
10203         functions.
10204         (gl_futimens, lutimens): Use them.
10205         * modules/utimens (Depends-on): Add gettime, lstat, stat-time,
10206         stdbool, sys_stat.
10207         (Link): Mention resulting library dependency.
10208         * modules/utimecmp (Link): Likewise.
10209         * modules/utimens-tests (Depends-on): Drop stat-time, stdbool.
10210         (Makefile.am): Pick up library dependency.
10211         * lib/sys_stat.in.h (UTIME_NOW, UTIME_OMIT): Guarantee a
10212         definition.
10213         * tests/test-sys_stat.c: Test the definitions.
10214         * doc/posix-headers/sys_stat.texi (sys/stat.h): Document this.
10215         * NEWS: Document library dependency.
10216
10217         utimecmp: support symlink timestamps
10218         * lib/utimecmp.c (utimecmp): Use new interface.  Skip effort of
10219         hashing when possible.  Use pathconf when available.
10220         (SYSCALL_RESOLUTION): Recognize tighter resolution.
10221         * modules/utimecmp (Depends-on): Add lstat.
10222
10223         utimens: add lutimens interface
10224         * lib/utimens.c (lutimens): New function.
10225         * m4/utimens.m4 (gl_UTIMENS): Check for lutimes.
10226         * lib/utimens.h (lutimens): Declare new interface.
10227         * tests/test-utimens.c (main): Enhance test.
10228         * tests/test-lutimens.h (test_lutimens): New file.
10229         * modules/utimens-tests (Files): Distribute it.
10230         (Depends-on): Add symlink.
10231         (configure.ac): Check for usleep.
10232
10233         utimens: validate futimens usage
10234         * lib/utimens.c (gl_futimens): Require valid fd up front, using
10235         fewer syscalls on failure later on.  Avoid compiler warning on
10236         mingw.
10237         * modules/utimens (Depends-on): Add dup2.
10238
10239         utimens: add test
10240         * modules/utimens-tests: New test.
10241         * tests/test-utimens.h: New file.
10242         * tests/test-futimens.h: Likewise.
10243         * tests/test-utimens.c: Likewise.
10244
10245         doc: mention timestamp portability issues
10246         * doc/glibc-functions/lutimes.texi (lutimes): Refer to utimensat
10247         instead.
10248         * doc/posix-functions/utime.texi (utime): Likewise.
10249         * doc/posix-functions/utimes.texi (utimes): Likewise.
10250         * doc/glibc-functions/futimes.texi (futimes): Refer to futimens
10251         instead.
10252         * doc/posix-functions/futimens.texi (futimens): Mention utimens
10253         module.
10254         * doc/posix-functions/utimensat.texi (utimensat): Likewise.
10255         Mention weakness with symlink timestamps.
10256         * doc/glibc-functions/futimesat.texi (futimesat): New file; refer
10257         to utimensat/futimens instead.
10258         * doc/gnulib.texi (Glibc sys/time.h): Include new file.
10259
10260         test-dup2: enhance test
10261         * tests/test-dup2.c (main): Also check AT_FDCWD.
10262
10263         test-stat-time: avoid more spurious failures
10264         * tests/test-stat-time.c (nap): Wait for 15ms rather than 2ms, for
10265         xfs; and avoid race if the two timestamps cross quantization edge.
10266
10267         relocatable: prefer 'file system' over 'filesystem'
10268         * m4/relocatable-lib.m4 (gl_RELOCATABLE_NOP): Use AS_HELP_STRING.
10269         (gl_RELOCATABLE_LIBRARY_BODY): Fix spelling.
10270         * doc/relocatable-maint.texi (Supporting Relocation): Likewise.
10271         * doc/relocatable.texi (Enabling Relocatability): Likewise.
10272         * lib/relocatable.c (compute_curr_prefix): Likewise.
10273
10274 2009-10-10  Jim Meyering  <meyering@redhat.com>
10275
10276         stat-time-tests: check for the usleep function
10277         * modules/stat-time-tests (configure.ac): Now that we test HAVE_USLEEP.
10278
10279 2009-10-10  Bruno Haible  <bruno@clisp.org>
10280
10281         * modules/xnanosleep: Put the Link section after the Include section.
10282
10283 2009-10-09  Eric Blake  <ebb9@byu.net>
10284
10285         dup2: work around FreeBSD 6.1 bug
10286         * m4/dup2.m4 (gl_FUNC_DUP2): Detect bug.
10287         * doc/posix-functions/dup2.texi (dup2): Document it.
10288         Reported by Nelson H. F. Beebe and Jim Meyering.
10289
10290         test-stat-time: port to buggy NFS clients
10291         * tests/test-stat-time.c (main) [W32]: Reduce ifdefs.
10292         (test_ctime): Also skip test if mtime and ctime are skewed.
10293
10294         maint: prefer 'file system' over 'filesystem'
10295         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
10296         * doc/posix-functions/lstat.texi (lstat): Likewise.
10297         * lib/file-has-acl.c (file_has_acl): Likewise.
10298         * lib/fwriteerror.c [TEST]: Likewise.
10299         * tests/test-areadlink.h (test_areadlink): Likewise.
10300         * tests/test-areadlinkat-with-size.c (main): Likewise.
10301         * tests/test-areadlinkat.c (main): Likewise.
10302         * tests/test-canonicalize-lgpl.c (main): Likewise.
10303         * tests/test-canonicalize.c (main): Likewise.
10304         * tests/test-fstatat.c (main): Likewise.
10305         * tests/test-linkat.c (main): Likewise.
10306         * tests/test-lstat.h (test_lstat_func): Likewise.
10307         * tests/test-mkdir.h (test_mkdir): Likewise.
10308         * tests/test-readlink.h (test_readlink): Likewise.
10309         * tests/test-remove.c (main): Likewise.
10310         * tests/test-rename.h (test_rename): Likewise.
10311         * tests/test-renameat.c (main): Likewise.
10312         * tests/test-rmdir.h (test_rmdir_func): Likewise.
10313         * tests/test-symlink.h (test_symlink): Likewise.
10314         * tests/test-symlinkat.c (main): Likewise.
10315         * tests/test-unlink.h (test_unlink_func): Likewise.
10316         * tests/test-unlinkat.c (main): Likewise.
10317
10318         maint: make realtime library usage explicit
10319         * modules/gethrxtime (Link): Mention LIB_GETHRXTIME.
10320         * modules/gettime (Link): Mention LIB_CLOCK_GETTIME.
10321         * modules/settime (Link): Likewise.
10322         * modules/xnanosleep (Link): Mention LIB_NANOSLEEP.
10323
10324         test-stat-time: speed up execution
10325         * tests/test-stat-time.c (test_ctime) [!W32]: Avoid compiler
10326         warning on mingw.
10327         (nap): New helper function.
10328         (prepare_test): Use it to reduce sleep time.
10329         (test_mtime, test_ctime, test_birthtime): Allow for subsecond
10330         execution.
10331         * modules/stat-time-tests (configure.ac): Check for usleep.
10332
10333 2009-10-09  Jim Meyering  <meyering@redhat.com>
10334
10335         selinux-h: always use getfilecon wrappers
10336         * lib/getfilecon.c: New file.
10337         * lib/se-selinux.in.h: Use a better inclusion guard symbol name.
10338         [HAVE_SELINUX_SELINUX_H]: Include-next <selinux/selinux.h>.
10339         [!HAVE_SELINUX_SELINUX_H]: Use better parameter names.
10340         (fgetfilecon): Provide a stub.
10341         * m4/selinux-selinux-h.m4 (gl_HEADERS_SELINUX_SELINUX_H): Don't
10342         AC_SUBST SELINUX_SELINUX_H, since now we're generating that
10343         file unconditionally.
10344         When <selinux/selinux.h> is found, arrange to use wrappers.
10345         * modules/selinux-h (Files): Add getfilecon.c.
10346         (Makefile.am): Substitute include-next-related bits
10347         into the now-always-generated selinux/selinux.h file.
10348         * doc/glibc-functions/lgetfilecon.texi: New file.
10349         * doc/glibc-functions/fgetfilecon.texi: New file.
10350         * doc/glibc-functions/getfilecon.texi: New file.
10351         * doc/glibc-functions/getfilecon-desc.texi: New file.
10352         * doc/gnulib.texi (Glibc selinux/selinux.h): New section, by
10353         which to pull in the new files.
10354         * MODULES.html.sh (Misc): Add selinux-h.
10355
10356 2009-10-08  Jim Meyering  <meyering@redhat.com>
10357
10358         unistd: fix comment typo
10359         * lib/unistd.in.h (euidaccess): Fix a comment typo.
10360
10361 2009-10-08  Eric Blake  <ebb9@byu.net>
10362
10363         areadlink: use SIZE_MAX consistently
10364         * modules/areadlink (Depends-on): Add stdint.
10365         * modules/areadlink-with-size (Depends-on): Likewise.
10366         * lib/areadlink-with-size.c (includes): Drop stdio, since stdlib
10367         gives NULL; drop sys/types, since unistd gives size_t; and add
10368         stdint for SIZE_MAX.
10369         (SIZE_MAX): Rely on headers.
10370         * lib/areadlinkat-with-size.c (includes): Drop stdio, sys/types,
10371         and add stdint.
10372         * lib/areadlink.c (includes): Drop sys/types, and add stdint.
10373         (SIZE_MAX): Likewise.
10374         (INITIAL_BUF_SIZE): Turn into enum.
10375         * lib/areadlinkat.c (INITIAL_BUF_SIZE): Likewise.
10376
10377 2009-10-08  Jim Meyering  <meyering@redhat.com>
10378
10379         areadlinkat: avoid compilation failure
10380         * lib/areadlinkat.c: Include <stdint.h> for use of SIZE_MAX.
10381         Fix typo in comment.
10382
10383 2009-10-07  Eric Blake  <ebb9@byu.net>
10384
10385         areadlinkat-with-size: new module
10386         * modules/areadlinkat-with-size: New module.
10387         * lib/areadlinkat-with-size.c (areadlinkat_with_size): New file.
10388         * lib/areadlink.h (areadlinkat): Declare it.
10389         * MODULES.html.sh (File system functions): Mention it.
10390         * modules/areadlinkat-with-size-tests: New test.
10391         * tests/test-areadlinkat-with-size.c: New file.
10392
10393         xreadlinkat: new module
10394         * modules/xreadlinkat: New module.
10395         * lib/xreadlinkat.c (xreadlinkat): New file.
10396         * lib/xreadlink.h (xreadlinkat): Declare it.
10397         * MODULES.html.sh (File system functions): Mention it.
10398
10399         areadlinkat: new module
10400         * lib/at-func.c (FUNC_FAIL): New define.
10401         (AT_FUNC_NAME, VALIDATE_FLAG): Use it rather than raw -1.
10402         * modules/areadlinkat: New module.
10403         * lib/linkat.c (areadlinkat): Move...
10404         * lib/areadlinkat.c (areadlinkat): ...to new file.
10405         * lib/areadlink.h (areadlinkat): Declare it.
10406         * modules/linkat (Depends-on): Add areadlinkat.
10407         * MODULES.html.sh (File system functions): Mention it.
10408         * modules/areadlinkat-tests: New test.
10409         * tests/test-areadlinkat.c: New file.
10410
10411         areadlink, areadlink-with-size: add tests
10412         * modules/areadlink-tests: New test.
10413         * modules/areadlink-with-size-tests: Likewise.
10414         * tests/test-areadlink.h: New file.
10415         * tests/test-areadlink.c: Likewise.
10416         * tests/test-areadlink-with-size.c: Likewise.
10417
10418         maint: minor cleanups
10419         * lib/fts.c (ATTRIBUTE_UNUSED): Delete; use gnulib-guaranteed
10420         _UNUSED_PARAMETER_ instead.
10421         * lib/getdate.y (ATTRIBUTE_UNUSED): Likewise.
10422         * lib/utimens.c (ATTRIBUTE_UNUSED): Likewise.
10423         * modules/linkat-tests (Files): Distribute test-link.h.
10424
10425         openat, utimens: whitespace cleanup
10426         * lib/openat.c: Prefer space throughout, rather than mix of 8
10427         spaces vs. tabs.
10428         * lib/at-func.c: Likewise.
10429         * lib/utimens.c: Likewise.
10430
10431         openat: avoid using wrong fd
10432         * lib/openat.c (openat_permissive): Reject user's fd if saving the
10433         working directory chooses same fd.
10434         * lib/at-func.c (AT_FUNC_NAME): Likewise.
10435
10436         mkdir, mkdirat: fix cygwin 1.5.x bug
10437         * lib/mkdir.c (rpl_mkdir) [FUNC_MKDIR_DOT_BUG]: Work around bug.
10438         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Move...
10439         * m4/mkdir.m4 (gl_FUNC_MKDIR): ...here, and add check for cygwin
10440         bug.
10441         (gl_PREREQ_MKDIR): Delete unused macro.
10442         * modules/mkdir (Files): Track file rename.
10443         (configure.ac): Update macro name.
10444         * modules/openat (Depends-on): Add mkdir.
10445         * doc/posix-functions/mkdir.texi (mkdir): Document the bug.
10446
10447         mkdir, mkdirat: add tests
10448         * modules/mkdir-tests: New test.
10449         * tests/test-mkdir.h: New file.
10450         * tests/test-mkdir.c: Likewise.
10451         * tests/test-mkdirat.c: Likewise.
10452         * modules/openat-tests (Files): Add new files.
10453         (Makefile.am): Run new test.
10454
10455 2009-10-06  Eric Blake  <ebb9@byu.net>
10456
10457         doc: tweak *at function documentation
10458         * doc/posix-functions/faccessat.texi (faccessat): Mention
10459         known issue with replacement.
10460         * doc/posix-functions/fchdir.texi (fchdir): Likewise.
10461         * doc/posix-functions/linkat.texi (linkat): Likewise.
10462         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
10463         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
10464         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
10465         * doc/posix-functions/renameat.texi (renameat): Likewise.
10466         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
10467
10468         openat: fix GNU/Hurd bug in unlinkat
10469         * m4/openat.m4 (gl_FUNC_OPENAT): Replace unlinkat if unlink is
10470         broken.
10471         * doc/posix-functions/unlink.texi (unlink): Document this.
10472         * doc/posix-functions/unlinkat.texi (unlinkat): Likewise.
10473
10474         fdopendir: fix GNU/Hurd bug
10475         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): Check for Hurd bug in
10476         allowing non-directory fds.
10477         * lib/fdopendir.c (rpl_fdopendir): Work around it.
10478         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): New witness.
10479         * modules/dirent (Makefile.am): Substitute it.
10480         * lib/dirent.in.h (fdopendir): Declare replacement.
10481         * doc/posix-functions/fdopendir.texi (fdopendir): Document this.
10482         * tests/test-fdopendir.c (main): Test something other than
10483         /dev/null, since on Hurd that behaves like a directory.
10484
10485         test-symlink: port to GNU/Hurd
10486         * tests/test-symlink.h (test_symlink): Relax expected errno.
10487
10488         doc: tweak more cygwin information
10489         * doc/glibc-headers/getopt.texi (getopt.h): Cygwin 1.7 getopt is
10490         now compatible with glibc.
10491         * doc/posix-functions/getopt.texi (getopt): Likewise.
10492
10493         getopt-gnu: add another test
10494         * tests/test-getopt_long.h (test_getopt_long_posix): New test, to
10495         guarantee behavior relied on by m4.
10496         * tests/test-getopt.c (main): Use it.
10497         * modules/getopt-posix-tests (Depends-on): Add setenv.
10498         See http://lists.gnu.org/archive/html/bug-m4/2006-09/msg00028.html.
10499
10500         getopt: fix compilation on darwin
10501         * lib/getopt.in.h (includes): Leave breadcrumbs during system
10502         include.
10503         * lib/unistd.in.h (getopt): Use them to avoid recursive include.
10504         Reported by Ludovic Courtès.
10505
10506 2009-10-06  Bruno Haible  <bruno@clisp.org>
10507
10508         * modules/size_max (Description): Discourage its use.
10509         Reported by Simon Josefsson.
10510
10511 2009-10-06  Jim Meyering  <meyering@redhat.com>
10512
10513         linkat: avoid compilation failure
10514         * lib/linkat.c: Include <stdint.h> for use of SIZE_MAX.
10515
10516 2009-10-05  Eric Blake  <ebb9@byu.net>
10517
10518         linkat: support Linux 2.6.17
10519         * m4/linkat.m4 (gl_FUNC_LINKAT): Default to always replacing
10520         linkat on Linux, but allow cache variable override.
10521         * lib/linkat.c (rpl_linkat): Define override.
10522         * modules/linkat (Depends-on): Add symlinkat.
10523         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add new default.
10524         * modules/unistd (Makefile.am): Substitute it.
10525         * lib/unistd.in.h (linkat): Declare replacement.
10526         Reported by Pádraig Brady.
10527
10528         quotearg: port test to systems with C.UTF-8 locale
10529         * tests/test-quotearg.c (struct result_strings): Add another
10530         member, differentiating between C.ASCII and C.UTF-8 handling.
10531         (compare_strings): Add parameter.
10532         (main): Adjust all callers.
10533
10534         getopt: avoid clash with FreeBSD _getopt_internal
10535         * lib/getopt.in.h (_getopt_internal): Override the name.
10536         * lib/getopt_int.h (includes): Pick up any overrides.
10537         Reported by Reuben Thomas.
10538
10539         hash: allow C89 compilation
10540         * lib/hash.c (check_tuning): Move declaration before statement.
10541         Reported by Reuben Thomas.
10542
10543 2009-10-05  Karl Berry  <karl@gnu.org>
10544
10545         * doc/gnulib.texi: @include execvpe.texi, missing for several days.
10546
10547 2009-10-04  Paolo Bonzini  <bonzini@gnu.org>
10548             Bruno Haible  <bruno@clisp.org>
10549
10550         * lib/uname.c (uname): Use a table-driven algorithm to compute
10551         Windows NT versions.
10552
10553 2009-10-04  Bruno Haible  <bruno@clisp.org>
10554
10555         * lib/progname.c (set_program_name): Also remove the "lt-" prefix from
10556         program_invocation_short_name.
10557         * modules/progname (configure.ac): Test for presence of
10558         program_invocation_short_name.
10559         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
10560
10561 2009-10-04  Bruno Haible  <bruno@clisp.org>
10562
10563         * lib/progname.c (set_program_name): Fix comment.
10564         Reported by Jim Meyering.
10565
10566 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
10567             Bruno Haible  <bruno@clisp.org>
10568
10569         * lib/uname.c: Include <string.h>.
10570         (uname): Do only one call to GetVersionEx in the common case.
10571
10572 2009-10-03  Paolo Bonzini  <bonzini@gnu.org>
10573             Bruno Haible  <bruno@clisp.org>
10574
10575         * lib/uname.c (VER_PLATFORM_WIN32_CE, PROCESSOR_ARCHITECTURE_AMD64,
10576         PROCESSOR_ARCHITECTURE_IA32_ON_WIN64): Define fallbacks.
10577         (uname): Add support for Windows CE and various non-x86 CPU types.
10578
10579 2009-10-03  Bruno Haible  <bruno@clisp.org>
10580
10581         * gnulib-tool (func_create_testdir): Conditionally emit AM_PROG_CC_C_O
10582         invocation to tests/configure.ac.
10583         Reported by Ian Beckwith <ianb@erislabs.net>.
10584
10585 2009-10-02  Eric Blake  <ebb9@byu.net>
10586
10587         fchdir: avoid compiler warning
10588         * lib/fchdir.c (canonicalize_file_name)
10589         [!HAVE_CANONICALIZE_FILE_NAME]: Avoid compiler warning on mingw.
10590
10591         test-open: support mingw errno values
10592         * tests/test-open.h (test_open): Relax test.
10593         * tests/test-fopen.h (test_fopen): Likewise.
10594         * tests/test-openat-safer.c (main): Likewise.
10595
10596         open: fix opening directory on mingw
10597         * lib/open.c (open) [REPLACE_OPEN_DIRECTORY]: Correct typo.
10598
10599         test-open: on GNU/Hurd, /dev/null is a directory
10600         * tests/test-fopen.h (main): Rename...
10601         (test_fopen): ...to this.  Use a guaranteed non-directory when
10602         confirming open behavior on trailing slash.
10603         * tests/test-openat-safer.c (main): Likewise.
10604         * tests/test-open.h (main): Likewise....
10605         (test_open): ...to this.
10606         * tests/test-fopen.c (main): Adjust caller.
10607         * tests/test-fopen-safer.c (main): Likewise.
10608         * tests/test-open.c (main): Likewise.
10609         * tests/test-fcntl-safer.c (main): Likewise.
10610         Reported by Samuel Thibault.
10611
10612         rename, fchdir: don't ignore chdir failure
10613         * lib/fchdir.c (get_name): Abort on unexpected chdir failure.
10614         * lib/rename.c (rpl_rename) [W32]: Likewise.
10615         (rpl_rename) [RENAME_DEST_EXISTS_BUG]: Avoid one case of losing
10616         an empty destination directory if source cannot be renamed,
10617         although there is still possibility for failure.
10618         * doc/posix-functions/rename.texi (rename): Document the race.
10619         Reported by Jim Meyering.
10620
10621         maint: cleanup whitespace in recent commits
10622         * lib/rename.c (rpl_rename): Remove tabs.
10623         * tests/test-link.h (test_link): Likewise.
10624         * lib/fchdir.c (get_name): Likewise.
10625         Reported by Jim Meyering.
10626
10627 2009-10-02  Ben Pfaff  <blp@gnu.org>
10628
10629         relocatable-prog-wrapper: Add missing dependency on
10630         double-slash-root.
10631         * modules/relocatable-prog-wrapper: Add dependency.
10632         Reported by Ian Beckwith <ianb@erislabs.net>.
10633
10634 2009-10-02  Eric Blake  <ebb9@byu.net>
10635
10636         renameat: fix Solaris bugs
10637         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Replace renameat if rename
10638         needed fixing.
10639         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): New witness.
10640         * modules/stdio (Makefile.am): Substitute it.
10641         * lib/stdio.in.h (renameat): Declare replacement.
10642         * lib/renameat.c (rpl_renameat): Implement fix.
10643
10644         renameat: new module
10645         * modules/renameat: New file.
10646         * lib/renameat.c (renameat): Likewise.
10647         * m4/renameat.m4 (gl_FUNC_RENAMEAT): Likewise.
10648         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
10649         * modules/stdio (Makefile.am): Substitute them.
10650         * lib/stdio.in.h (renameat): Declare it.
10651         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
10652         * doc/posix-functions/renameat.texi (renameat): Likewise.
10653         * modules/renameat-tests: New test.
10654         * tests/test-renameat.c: Likewise.
10655
10656         rename: fix mingw bugs
10657         * lib/rename.c (rpl_rename) [W32]: Fix trailing slash and
10658         directory overwrite bugs.
10659
10660         rename: fix another cygwin 1.5 bug
10661         * m4/rename.m4 (gl_FUNC_RENAME): Split cygwin bugs into two
10662         checks.
10663         * lib/rename.c (rpl_rename): Don't penalize NetBSD with
10664         unnecessary cygwin workarounds.  Also work around bug with moving
10665         full directory onto an empty one.
10666         * modules/rename (Depends-on): Add canonicalize-lgpl, rmdir.
10667
10668         rename-dest-slash: merge into rename module
10669         * modules/rename-dest-slash (Status): Mark obsolete.
10670         (Depends-on): Add rename.
10671         (Files): Let rename do it all.
10672         * m4/rename.m4 (gl_FUNC_RENAME): Also test for NetBSD bugs,
10673         subsuming the test from gl_FUNC_RENAME_TRAILING_DEST_SLASH...
10674         * m4/rename-dest-slash.m4: ...so this file can be deleted.
10675         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Delete.
10676         * lib/rename.c (rpl_rename): Update comments.
10677
10678         rename: fix cygwin 1.5.x bugs
10679         * m4/rename.m4 (gl_FUNC_RENAME): Detect cygwin bugs.
10680         * lib/rename.c (rpl_rename): Work around them.
10681         * modules/rename (Depends-on): Add same-inode.
10682
10683         rename: fix Solaris 10 bug
10684         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
10685         * lib/rename.c (rpl_rename): Don't cripple POSIX behavior if this
10686         was the only bug.
10687
10688         rename: fix Solaris 9 bug
10689         * lib/rename.c (rpl_rename): Rewrite to recognize trailing slash
10690         on non-directory.  Avoid calling exit.
10691         * modules/rename (Depends-on): Drop xalloc; add lstat, stdbool,
10692         strdup.
10693         * modules/rename-tests (Depends-on): Drop lstat.
10694         * m4/rename.m4 (gl_FUNC_RENAME): Detect Solaris bug.
10695         (gl_PREREQ_RENAME): Delete unused macro.
10696
10697         rename-dest-slash: fix NetBSD bug
10698         * lib/rename-dest-slash.c (rpl_rename_dest_slash): Detect hard
10699         links.
10700         * modules/rename-dest-slash (Depends-on): Add same-inode.
10701
10702         rename-tests: new test, exposes several platform bugs
10703         * modules/rename-tests: New file.
10704         * tests/test-rename.h: Likewise.
10705         * tests/test-rename.c: Likewise.
10706         * doc/posix-functions/rename.texi (rename): Improve documentation,
10707         including bugs that will eventually be fixed in gnulib.
10708
10709 2009-10-02  Paolo Bonzini  <bonzini@gnu.org>
10710
10711         * lib/uname.c: Include <stdlib.h>
10712         (uname): Assume version info is available.
10713
10714 2009-10-02  Jim Meyering  <meyering@redhat.com>
10715
10716         gnu-web-doc-update: correct --help output
10717         * build-aux/gnu-web-doc-update: Make --help output relevant.
10718
10719         gnu-web-doc-update: add standard options
10720         * build-aux/gnu-web-doc-update: Add --help, --version, etc.
10721
10722         gnu-web-doc-update: New module.
10723         Use this script to automatically update the on-line web documentation
10724         for your GNU project at http://www.gnu.org/software/$pkg/manual/
10725         * modules/gnu-web-doc-update: New file, from coreutils.
10726         * build-aux/gnu-web-doc-update: New script.
10727
10728 2009-10-01  Paolo Bonzini  <bonzini@gnu.org>
10729
10730         link: LoadLibrary is not needed.
10731         * lib/link.c: Use GetModuleHandle.
10732
10733 2009-10-01  Eric Blake  <ebb9@byu.net>
10734
10735         getopt: bump serial number
10736         * m4/getopt.m4: Increment serial number, to account for 2009-09-24
10737         change.
10738
10739         tests: tighten link, rmdir, and remove tests
10740         * tests/test-link.h (includes): No need to use <config.h> here.
10741         Clean up if directory hard link was created, otherwise test for
10742         trailing '.'.
10743         * tests/test-linkat.c (main): Simplify.
10744         * tests/test-remove.c (main): Enhance test for trailing '.'.
10745         * tests/test-rmdir.h (test_rmdir_func): Likewise.
10746
10747 2009-10-01  Jim Meyering  <meyering@redhat.com>
10748
10749         maint.mk: requiring "make major" was annoying, for a "minor" release.
10750         What is intended is "stable", to contrast with alpha and beta,
10751         so require "make stable", not "make major".
10752         * build-aux/announce-gen (%valid_release_types): s/major/stable/.
10753         (get_tool_versions): Likewise.
10754         * top/maint.mk (ALL_RECURSIVE_TARGETS): s/major/stable/
10755
10756 2009-09-30  Ben Pfaff  <blp@gnu.org>
10757
10758         Fix broken build of replacement for Windows tmpfile().
10759         * lib/tmpfile.c (tmpfile): Fix call to gen_tempname() to provide
10760         flags argument added along with the 'mkostemp' module.
10761
10762 2009-09-28  Bruno Haible  <bruno@clisp.org>
10763
10764         Avoid identifier clash with POSIX function 'remove' defined as a macro.
10765         * lib/gl_list.h (struct gl_list_implementation): Rename field 'remove'
10766         to 'remove_elt'.
10767         (gl_list_remove): Update.
10768         * lib/gl_list.c (gl_list_remove): Update.
10769         * lib/gl_oset.h (struct gl_oset_implementation): Rename field 'remove'
10770         to 'remove_elt'.
10771         (gl_oset_remove): Update.
10772         * lib/gl_list.c (gl_oset_remove): Update.
10773         Reported by Eric Blake.
10774
10775 2009-09-28  Eric Blake  <ebb9@byu.net>
10776
10777         doc: mention yet more cygwin 1.7 status
10778         * doc/posix-functions/fexecve.texi (fexecve): Now implemented in
10779         cygwin.
10780         * doc/glibc-functions/execvpe.texi (execvpe): New file.
10781         * doc/gnulib.texi (Glibc unistd.h): Mention it.
10782
10783         argp: fix test failure
10784         * lib/argp-help.c (hol_entry_cmp): Don't use _tolower on values
10785         that are not upper-case.  Pass correct range to tolower.
10786
10787 2009-09-27  Jim Meyering  <meyering@redhat.com>
10788
10789         test-yesno: work around sparc-dash here-document infelicity
10790         Without this change, the literal \177 byte in a here document
10791         would make dash 0.5.5.1-3 access uninitialized memory.
10792         * tests/test-yesno.sh: Don't put the \177 byte in the here document.
10793         Instead, use a marker, "@", and filter through tr to create the desired
10794         contents.  Reported as <http://bugs.debian.org/548493> by Kurt Roeckx.
10795
10796 2009-09-27  Bruno Haible  <bruno@clisp.org>
10797
10798         Disable untested support for new flavours of ACLs on AIX.
10799         * lib/file-has-acl.c (file_has_acl): Mark newer AIX code as work in
10800         progress.
10801         * lib/set-mode-acl.c (qset_acl): Likewise.
10802
10803 2008-12-07  Bruno Haible  <bruno@clisp.org>
10804
10805         Add support for new flavours of ACLs on AIX. (Untested.)
10806         * lib/file-has-acl.c [AIX] (acl_nfs4_nontrivial): New function.
10807         (file_has_acl): Add support for newer AIX.
10808         * lib/set-mode-acl.c (qset_acl): Likewise.
10809         * tests/test-sameacls.c (main): Fix use of aclx_get function. Hint by
10810         Rainer Tammer <tammer@tammer.net>.
10811
10812 2009-09-26  Eric Blake  <ebb9@byu.net>
10813
10814         argp: fix compilation of getopt
10815         * lib/getopt.in.h (includes): Use different guard than glibc.
10816         Reported by Sergey Poznyakoff.
10817
10818         doc: mention more cygwin 1.7 status
10819         * doc/posix-functions/access.texi (access): Mention cygwin 1.5
10820         bug.
10821         * doc/posix-functions/execl.texi (execl): Likewise.
10822         * doc/posix-functions/execle.texi (execle): Likewise.
10823         * doc/posix-functions/execlp.texi (execlp): Likewise.
10824         * doc/posix-functions/execv.texi (execv): Likewise.
10825         * doc/posix-functions/execve.texi (execve): Likewise.
10826         * doc/posix-functions/execvp.texi (execvp): Likewise.
10827         * doc/glibc-functions/canonicalize_file_name.texi
10828         (canonicalize_file_name): Cygwin 1.7 now provides this.
10829         * doc/glibc-functions/euidaccess.texi (euidaccess): Likewise.
10830         * doc/posix-functions/fchmodat.texi (fchmodat): Mention limitation
10831         on AT_SYMLINK_NOFOLLOW.
10832
10833 2009-09-24  Eric Blake  <ebb9@byu.net>
10834
10835         test-linkat: make test more robust
10836         * tests/test-linkat.c (main): Avoid collision with EEXIST.
10837
10838         getopt: fix inclusion guards for cygwin
10839         * modules/getopt-posix (Depends-on): Add include-next.
10840         (Makefile.am): Substitute more items in replacement header.
10841         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Also check for native
10842         <getopt.h>.
10843         * lib/getopt.in.h (includes): Use split inclusion guard, and
10844         prefer <getopt.h> over include <unistd.h> when one is present.
10845         (option): Also override name of 'struct option'.
10846
10847         same-inode: revert prior change; it is not yet ready
10848         * NEWS: Undo mention of this change.
10849         * lib/same-inode.h (same-inode.h): Undo tri-state change.
10850         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
10851         * lib/cycle-check.c (cycle_check): Likewise.
10852         * lib/same.c (same_name): Likewise.
10853         * lib/at-func2.c (at_func2): Likewise.
10854
10855 2009-09-23  Eric Blake  <ebb9@byu.net>
10856
10857         linkat: new module
10858         * modules/linkat: New file.
10859         * lib/at-func2.c (at_func2): Likewise.
10860         * lib/linkat.c (linkat): Likewise.
10861         * m4/linkat.m4 (gl_FUNC_LINKAT): Likewise.
10862         * lib/openat-priv.h (at_func2): Add declaration.
10863         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
10864         * modules/unistd (Makefile.am): Substitute them.
10865         * lib/unistd.in.h (linkat): Declare it.
10866         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
10867         * doc/posix-functions/linkat.texi (linkat): Likewise.
10868         * doc/posix-functions/link.texi (link): Tweak wording.
10869         * tests/test-link.c (main): Move guts...
10870         * tests/test-link.h (test_link): ...into new file.
10871         * modules/linkat-tests: New test.
10872         * tests/test-linkat.c: Likewise.
10873         * modules/link-tests (Files): Ship new file.
10874         (Depends-on): Add stdbool.
10875
10876         dirname: add library-safe mdir_name
10877         * lib/dirname.h (mdir_name): New prototype.
10878         * lib/dirname.c (dir_name): Move guts...
10879         (mdir_name): ...to new function that avoids xalloc_die.
10880
10881         fchdir: another mingw fix
10882         * modules/fchdir (Depends-on): Drop canonicalize-lgpl.
10883         * lib/fchdir.c (get_name): New helper method; skips canonicalize
10884         on mingw (where it has not yet been ported), and make it optional
10885         elsewhere.
10886         (_gl_register_fd): Use it.
10887
10888         same-inode: make SAME_INODE tri-state, to port to mingw
10889         * NEWS: Mention this change.
10890         * lib/same-inode.h (same-inode.h): Recognize mingw limitation of
10891         st_ino always being 0.
10892         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Update caller.
10893         * lib/cycle-check.c (cycle_check): Likewise.
10894         * lib/same.c (same_name): Likewise.
10895
10896         lstat: avoid mingw compilation error
10897         * m4/lstat.m4 (gl_FUNC_LSTAT): Avoid duplicate calls to
10898         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK, and deal with missing
10899         lstat ourselves.
10900         * lib/lstat.c [!HAVE_LSTAT]: Do nothing if <sys/stat.h> override
10901         was adequate.
10902         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Let lstat module handle
10903         the checks for lstat.
10904         (gl_SYS_STAT_H_DEFAULTS): Set default for HAVE_LSTAT.
10905
10906         link: fix test failure on Solaris 9
10907         * lib/link.c (rpl_link): Don't assume link will catch bogus
10908         trailing slash on source.
10909
10910         test-symlinkat: enhance test
10911         * tests/test-readlink.c (main): Move guts...
10912         * tests/test-readlink.h (test_readlink): ...into new file.
10913         * tests/test-symlink.c (main): Move guts...
10914         * tests/test-symlink.h (test_symlink): ...into new file.
10915         * tests/test-symlinkat.c (main): Use new files for further
10916         coverage.
10917         (do_symlink, do_readlink): New helper functions.
10918         * modules/symlink-tests (Files): Ship new file.
10919         (Depends-on): Add stdbool.
10920         * modules/readlink-tests (Files): Ship new file.
10921         (Depends-on): Add stdbool.
10922         * modules/symlinkat-tests (Files): Use new files.
10923
10924 2009-09-23  Eric Blake  <ebb9@byu.net>
10925
10926         readlink: document portability issue with symlink length
10927         * doc/posix-functions/lstat.texi (lstat): Mention that some file
10928         systems have bogus st_size on symlinks, and mention the
10929         areadlink-with-size module.
10930         * doc/posix-functions/fstatat.texi (fstatat): Likewise.
10931         * doc/posix-functions/readlink.texi (readlink): Mention the
10932         areadlink module, and ERANGE failure.
10933         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
10934         * tests/test-readlink.c (main): Relax test for AIX, HP-UX.
10935
10936         readlink: fix Solaris 9 bug with trailing slash
10937         * lib/readlink.c (rpl_readlink): Work around trailing slash bug.
10938         * m4/readlink.m4 (gl_FUNC_READLINK): Detect the bug.
10939         * doc/posix-functions/readlink.texi (readlink): Document this.
10940         * modules/readlink-tests: New test.
10941         * tests/test-readlink.c: Likewise.
10942
10943         readlink: fix cygwin 1.5.x bug with return type
10944         * m4/readlink.m4 (gl_FUNC_READLINK): Require correct signature.
10945         * lib/unistd.in.h (readlink): Use ssize_t.
10946         * lib/readlink.c (readlink): Likewise.
10947         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
10948         * modules/unistd (Makefile.am): Substitute it.
10949         * lib/unistd.in.h (readlink): Declare replacement.
10950         * doc/posix-functions/readlink.texi (readlink): Document this.
10951
10952         symlink: use throughout gnulib
10953         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Omit symlink check.
10954         * lib/symlinkat.c (symlinkat) [!HAVE_SYMLINK]: Document why
10955         symlink is not used.
10956         * modules/symlinkat (Depends-on): Add symlink.
10957         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
10958         * modules/canonicalize-tests (Depends-on): Likewise.
10959         * modules/lstat-tests (Depends-on): Likewise.
10960         * modules/openat-tests (Depends-on): Likewise.
10961         * modules/remove-tests (Depends-on): Likewise.
10962         * modules/rmdir-tests (Depends-on): Likewise.
10963         * modules/unlink-tests (Depends-on): Likewise.
10964         * tests/test-canonicalize-lgpl.c (symlink): Delete stub.
10965         * tests/test-canonicalize.c (symlink): Likewise.
10966         * tests/test-fstatat.c (symlink): Likewise.
10967         * tests/test-lstat.c (symlink): Likewise.
10968         * tests/test-remove.c (symlink): Likewise.
10969         * tests/test-rmdir.c (symlink): Likewise.
10970         * tests/test-unlink.c (symlink): Likewise.
10971         * tests/test-unlinkat.c (symlink): Likewise.
10972
10973         symlink: new module, for Solaris 9 bug
10974         * modules/symlink: New file.
10975         * m4/symlink.m4 (gl_FUNC_SYMLINK): Likewise.
10976         * lib/symlink.c: Likewise.
10977         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add defaults.
10978         * modules/unistd (Makefile.am): Substitute them.
10979         * lib/unistd.in.h (symlink): Declare replacement.
10980         * MODULES.html.sh (File system functions): Mention it.
10981         * doc/posix-functions/symlink.texi (symlink): Likewise.
10982         * modules/symlink-tests: New test.
10983         * tests/test-symlink.c: Likewise.
10984
10985 2009-09-23  Bruno Haible  <bruno@clisp.org>
10986
10987         * gnulib-tool (func_import): Add 'link-warning' to testsrelated_modules
10988         when needed.
10989         Test case: gnulib-tool --import --with-tests atexit inttypes.
10990         Reported by Pauli Miettinen <pauli.miettinen@cs.helsinki.fi>.
10991
10992 2009-09-23  Bruno Haible  <bruno@clisp.org>
10993
10994         * gnulib-tool (func_emit_tests_Makefile_am): Set uses_subdirs in a
10995         subcommand, not in a subshell.
10996
10997 2009-09-22  Eric Blake  <ebb9@byu.net>
10998
10999         unistd: sort replacement declarations
11000         * lib/unistd.in.h: Sort declarations.
11001
11002         open, openat: minor optimization
11003         * lib/open.c (open): If open succeeded, len is non-zero.
11004         * lib/openat.c (rpl_openat): Likewise.
11005
11006         link-follow: ensure correct result
11007         * m4/fcntl_h.m4 (gl_FCNTL_H): Clean up temporary file.
11008         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Likewise, and
11009         distinguish between possible failures.
11010
11011 2009-09-21  Eric Blake  <ebb9@byu.net>
11012
11013         fts: avoid compiler warning
11014         * lib/fts.c (dirent_inode_sort_may_be_useful)
11015         (leaf_optimization_applies) [!__linux__]: Mark unused parameters.
11016
11017 2009-09-19  Bruno Haible  <bruno@clisp.org>
11018
11019         * lib/progreloc.c (canonicalize_file_name): New declaration.
11020
11021 2009-09-19  Eric Blake  <ebb9@byu.net>
11022
11023         link: fix quoting
11024         * m4/link.m4 (gl_FUNC_LINK): Fix shell quoting.
11025
11026         openat: fix openat bugs on Solaris 9
11027         * lib/openat.c (rpl_openat): Work around Solaris 9 bug.
11028         * m4/openat.m4 (gl_FUNC_OPENAT): Also replace openat on Solaris.
11029         * modules/openat (Depends-on): Add open.
11030         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Provide new default.
11031         * modules/fcntl-h (Makefile.am): Substitute it.
11032         * lib/fcntl.in.h (openat): Declare replacement.
11033         * doc/posix-functions/openat.texi (openat): Document this.
11034
11035         openat: move fstatat and unlinkat into correct files
11036         * m4/openat.m4 (gl_FUNC_OPENAT): Adjust which files will be
11037         compiled.
11038         * lib/openat.c (fstatat, unlinkat): Move...
11039         * lib/fstatat.c (fstatat): ...into correct files.
11040         * lib/unlinkat.c (unlinkat): Likewise.
11041
11042         openat: fix unlinkat bugs on Solaris 9
11043         * lib/unlinkat.c (unlinkat): New file.
11044         * modules/openat (Depends-on): Add unlink.
11045         (Files): Distribute it.
11046         * m4/openat.m4 (gl_FUNC_OPENAT): Mark unlinkat for replacement if
11047         trailing slash behavior is broken.
11048         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
11049         * modules/unistd (Makefile.am): Substitute it.
11050         * lib/unistd.in.h (unlinkat): Declare replacement.
11051         * doc/posix-functions/unlinkat.texi (unlinkat): Document this.
11052
11053         openat: fix fstatat bugs on Solaris 9
11054         * lib/fstatat.c (rpl_fstatat): Copy recent fixes from lstat and
11055         stat.
11056         * doc/posix-functions/fstatat.texi (fstatat): Document this.
11057
11058         test-unlinkat: enhance test, to expose Solaris 9 bug
11059         * tests/test-unlink.c (main): Factor guts...
11060         * tests/test-unlink.h (test_rmdir_func): ...into new file.
11061         * tests/test-rmdir.h (test_rmdir_func): Add parameter.
11062         * tests/test-rmdir.c (main): Adjust caller.
11063         * tests/test-unlinkat.c (main): Likewise.  Add unlink tests.
11064         (unlinker): New helper function.
11065         (rmdirat): Enhance check.
11066         * modules/rmdir-tests (Depends-on): Add stdbool.
11067         * modules/unlink-tests (Depends-on): Likewise.
11068         (Files): Add test-unlink.h.
11069         * modules/openat-tests (Files): Likewise.
11070         (Depends-on): Add unlinkdir.
11071
11072         test-fstatat: new test, to expose Solaris 9 bugs
11073         * tests/test-stat.c (main): Factor guts...
11074         * tests/test-stat.h (test_stat_func): ...into new file.
11075         * tests/test-lstat.c (main): Factor guts...
11076         * tests/test-lstat.h (test_lstat_func): ...into new file.
11077         * tests/test-fstatat.c: New file.
11078         * modules/stat-tests (Files): Add test-stat.h.
11079         * modules/lstat-tests (Files): Add test-lstat.h.
11080         (Depends-on): Add stdbool.
11081         * modules/openat-tests (Depends-on): Add pathmax.
11082         (Files): Add test-lstat.h, test-stat.h, test-fstatat.c.
11083         (Makefile.am): Run new test.
11084
11085         remove: new module, for mingw and Solaris 9 bugs
11086         * modules/remove: New file.
11087         * lib/remove.c: Likewise.
11088         * m4/remove.m4 (gl_FUNC_REMOVE): Likewise.
11089         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add witnesses.
11090         * modules/stdio (Makefile.am): Use them.
11091         * lib/stdio.in.h (remove): Declare replacement.
11092         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
11093         * doc/posix-functions/remove.texi (remove): Likewise.
11094         * modules/remove-tests: New test.
11095         * tests/test-remove.c: Likewise.
11096
11097         unlink: new module, for Solaris 9 bug
11098         * modules/unlink: New file.
11099         * lib/unlink.c: Likewise.
11100         * m4/unlink.m4 (gl_FUNC_UNLINK): Likewise.
11101         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
11102         * modules/unistd (Makefile.am): Use them.
11103         * lib/unistd.in.h (stat): Declare replacement.
11104         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
11105         * doc/posix-functions/unlink.texi (unlink): Likewise.
11106         * modules/unlink-tests: New test.
11107         * tests/test-unlink.c: Likewise.
11108
11109         lstat: fix Solaris 9 bug
11110         * lib/lstat.c (lstat): Also check for trailing slash on
11111         non-symlink, non-directories.  Use stat module to simplify logic.
11112         * doc/posix-functions/lstat.texi (lstat): Document it.
11113         * modules/lstat-tests (Depends-on): Add errno, same-inode.
11114         (configure.ac): Check for symlink.
11115         * tests/test-lstat.c (main): Add more tests.
11116
11117         stat: add as dependency to other modules
11118         * modules/chown (Depends-on): Add stat.
11119         * modules/euidaccess (Depends-on): Likewise.
11120         * modules/fchdir (Depends-on): Likewise.
11121         * modules/isdir (Depends-on): Likewise.
11122         * modules/link (Depends-on): Likewise.
11123         * modules/lstat (Depends-on): Likewise.
11124         * modules/mkdir-p (Depends-on): Likewise.
11125         * modules/modechange (Depends-on): Likewise.
11126         * modules/open (Depends-on): Likewise.
11127         * modules/readlink (Depends-on): Likewise.
11128         * modules/same (Depends-on): Likewise.
11129
11130         stat: fix Solaris 9 bug
11131         * m4/stat.m4 (gl_FUNC_STAT): Detect Solaris 9 bug with trailing
11132         slash.
11133         * lib/stat.c (rpl_stat): Work around it.
11134         * doc/posix-functions/stat.texi (stat): Update documentation.
11135
11136         stat: new module, for mingw bug
11137         * modules/stat: New file.
11138         * lib/stat.c: Likewise.
11139         * m4/stat.m4 (gl_FUNC_STAT): Likewise.
11140         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
11141         * modules/sys_stat (Makefile.am): Use them.
11142         * lib/sys_stat.in.h (stat): Declare replacement.
11143         * lib/openat.c (fstatat): Deal with lstat and stat being function
11144         macros.
11145         * modules/openat (Depends-on): Add inline.
11146         * MODULES.html.sh (systems lacking POSIX:2008): Mention module.
11147         * doc/posix-functions/stat.texi (stat): Likewise.
11148         * modules/stat-tests: New test.
11149         * tests/test-stat.c: Likewise.
11150
11151 2009-09-19  Jim Meyering  <meyering@redhat.com>
11152
11153         syntax-check: detect unnecessary inclusion of canonicalize.h
11154         * top/maint.mk (sc_prohibit_canonicalize_without_use): New rule.
11155
11156 2009-09-19  Eric Blake  <ebb9@byu.net>
11157
11158         canonicalize-lgpl: adjust clients to use correct header
11159         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
11160         (gl_CANONICALIZE_LGPL): Use correct shell quoting.
11161         * modules/relocatable-prog-wrapper (Files): Drop canonicalize.h.
11162         * lib/fchdir.c (includes): Use <stdlib.h>, not "canonicalize.h".
11163         * lib/progreloc.c (includes): Likewise.
11164
11165 2009-09-19  Jim Meyering  <meyering@redhat.com>
11166
11167         test-posixtm.c: correct a comment
11168         * tests/test-posixtm.c: Correct first-line comment.
11169         Spotted by Eric Blake.
11170
11171 2009-09-16  Jim Meyering  <meyering@redhat.com>
11172
11173         posixtm-tests: make T const-correct; add a test case
11174         * tests/test-posixtm.c (T): Declare const.
11175         Add a test for -(2^31+1).
11176         Remove useless can-succeed-only-in-2002 test.
11177
11178         posixtm-tests: adjust the sole failing test
11179         * tests/test-posixtm.c: Correct 0000-01-01 00:00:00 test so that
11180         expected output matches what mktime now produces.  Cross-checked via
11181         erlang's calendar:datetime_to_gregorian_seconds({{1970,1,1},{0,0,0}})
11182
11183         posixtm: move #ifdef'd tests into a new module
11184         * lib/posixtm.c (posixtime): Remove #ifdef'd tests.  Move to...
11185         * tests/test-posixtm.c: ... this new file.
11186         * modules/posixtm-tests: New module.
11187
11188 2009-09-19  Eric Blake  <ebb9@byu.net>
11189
11190         openat: simplify use of at-func.c
11191         * lib/at-func.c (includes): Include prerequisites here, to
11192         simplify requirements on client files.
11193         * lib/openat-priv.h: Add double-inclusion guard.
11194         * lib/faccessat.c (includes): Simplify.
11195         * lib/fchmodat.c (includes): Likewise.
11196         * lib/fchownat.c (includes): Likewise.
11197         * lib/mkdirat.c (includes): Likewise.
11198         * lib/mkfifoat.c (includes): Likewise.
11199         * lib/symlinkat.c (includes): Likewise.
11200
11201         openat: allow return of fd 0
11202         * modules/chdir-long (Depends-on): Relax openat-safer to openat.
11203         * modules/save-cwd (Depends-on): Replace fcntl-safer with
11204         unistd-safer.
11205         * lib/chdir-long.c (includes): Replace "fcntl--.h" with
11206         <fcntl.h>; this module does not leak fds.
11207         * lib/openat.c (includes): Do not use "fcntl_safer"; plain openat
11208         must be allowed to return 0, leaving openat_safer to add the
11209         safety.
11210         (openat_permissive): Avoid writing to just-opened fd 2 if
11211         restoring the current directory fails.
11212         * lib/openat-die.c (openat_restore_fail): Add comment.
11213         * lib/save-cwd.c (includes): Make "fcntl--.h" conditional.
11214         (save_cwd): Guarantee safe fd, but without use of open_safer.
11215         * tests/test-openat.c: New test.
11216         * modules/openat-tests (Files, Makefile.am): Distribute and build
11217         new file.
11218
11219         relocatable-prog-wrapper: fix build
11220         * modules/relocatable-prog-wrapper (Files): Update name of
11221         canonicalize m4 file, broken on 2009-09-17.
11222         Reported by emad hajjar <aleppos@hotmail.com>.
11223
11224 2009-09-19  Bruno Haible  <bruno@clisp.org>
11225
11226         * lib/safe-alloc.h: Use the standard header with GPL copyright.
11227         * lib/safe-alloc.c: Likewise.
11228         Reported by Ian Beckwith <ianb@erislabs.net>.
11229
11230 2009-09-18  Bruno Haible  <bruno@clisp.org>
11231
11232         * gnulib-tool: Add advice to "cannot find configure.ac" error message.
11233         Reported by <erobles@sensacd.com.mx>.
11234
11235 2009-09-17  Eric Blake  <ebb9@byu.net>
11236
11237         canonicalize: in CAN_ALL_BUT_LAST, allow trailing slash
11238         * lib/canonicalize.c (canonicalize_filename_mode): Skip trailing
11239         slashes when checking if last component is missing.
11240         * tests/test-canonicalize.c (main): Test this.
11241
11242         canonicalize, canonicalize-lgpl: honor // if distinct from /
11243         * modules/canonicalize (Files): Add double-slash-root.m4.
11244         * modules/canonicalize-lgpl (Files): Likewise.
11245         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE)
11246         (gl_CANONICALIZE_LGPL_SEPARATE): Add dependency.
11247         * lib/canonicalize.c (DOUBLE_SLASH_IS_DISTINCT_ROOT): Provide
11248         fallback definition.
11249         (canonicalize_filename_mode): Use it to protect //.
11250         * lib/canonicalize-lgpl.c (DOUBLE_SLASH_IS_DISTINCT_ROOT)
11251         (__realpath): Likewise.
11252         * tests/test-canonicalize.c (main): Test this.
11253         * tests/test-canonicalize-lgpl.c (main): Likewise.
11254         * modules/canonicalize-tests (Depends-on): Add same-inode.
11255         * modules/canonicalize-lgpl-tests (Depends-on): Likewise.
11256
11257         canonicalize-lgpl: fix glibc bug with trailing slash
11258         * m4/canonicalize-lgpl.m4: Move contents...
11259         * m4/canonicalize.m4: ...here.
11260         (gl_CANONICALIZE_LGPL): Factor realpath check...
11261         (gl_FUNC_REALPATH_WORKS): ...into new macro.  Enhance to catch
11262         glibc 2.3.5 bug, fixed 2005-04-27.
11263         (gl_FUNC_CANONICALIZE_FILENAME_MODE): Use it.
11264         (gl_PREREQ_CANONICALIZE_LGPL): Inline...
11265         (gl_CANONICALIZE_LGPL_SEPARATE): ...into this macro.
11266         * modules/canonicalize-lgpl (Files): Manage file rename.
11267         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
11268         * modules/stdlib (Makefile.am): Substitute witness.
11269         * lib/stdlib.in.h (canonicalize_file_name): Declare if replacement
11270         is needed.
11271         * lib/canonicalize-lgpl.c: Also compile if canonicalize_file_name
11272         replacement is required.
11273         * lib/canonicalize.c (canonicalize_file_name): Likewise.
11274         * doc/glibc-functions/canonicalize_file_name.texi
11275         (canonicalize_file_name): Document this.
11276         * doc/posix-functions/realpath.texi (realpath): Likewise.
11277
11278         canonicalize-lgpl: reject non-directory with trailing slash
11279         * lib/canonicalize-lgpl.c (__realpath): Synchronize with glibc.
11280         * tests/test-canonicalize-lgpl.c (main): Enhance test.  This
11281         catches failures in glibc 2.3.5.
11282         * tests/test-canonicalize.c (main): Likewise.
11283
11284         canonicalize-lgpl: use native realpath if it works
11285         * lib/canonicalize-lgpl.c (realpath): Guard with
11286         FUNC_REALPATH_WORKS.
11287         * lib/stdlib.in.h (realpath): Make declaration optional based on
11288         HAVE_REALPATH.
11289         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Check whether
11290         native realpath works.
11291         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide default.
11292         * modules/stdlib (Makefile.am): Substitute witness.
11293
11294         canonicalize, canonicalize-lgpl: use <stdlib.h>
11295         * modules/canonicalize-lgpl (Files): Drop canonicalize.h.
11296         (Include): Mention <stdlib.h>.
11297         (configure.ac): Mention functions we provide.
11298         * modules/canonicalize (configure.ac): Likewise.
11299         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL): Always replace
11300         realpath if canonicalize_file_name is missing.
11301         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Provide defaults.
11302         * modules/stdlib (Makefile.am): Substitute witnesses.
11303         * lib/stdlib.in.h (canonicalize_file_name, realpath): Declare.
11304         * lib/canonicalize-lgpl.c (includes): Adjust accordingly.
11305         * lib/canonicalize.h (canonicalize_file_name): Drop declaration.
11306         * NEWS: Document this.
11307         * doc/glibc-functions/canonicalize_file_name.texi
11308         (canonicalize_file_name): Likewise.
11309         * doc/posix-functions/realpath.texi (realpath): Likewise.
11310         * tests/test-canonicalize-lgpl.c (includes): Use <stdlib.h>.
11311
11312         test-canonicalize: consolidate into single C program
11313         * tests/test-canonicalize.sh: Delete; move setup into...
11314         * tests/test-canonicalize.c (main): ...the program, making it
11315         easier to run in debugger.  Add some tests.
11316         * modules/canonicalize-tests (Files): Remove unused file.
11317         (Depends-on): Add progname.
11318         (configure.ac, Makefile.am): Simplify.
11319
11320         test-canonicalize-lgpl: consolidate into single C program
11321         * tests/test-canonicalize-lgpl.sh: Delete; move setup into...
11322         * tests/test-canonicalize-lgpl.c (main): ...the program, making it
11323         easier to run in debugger.  Add some tests.
11324         * modules/canonicalize-lgpl-tests (Files): Remove unused file.
11325         (configure.ac, Makefile.am): Simplify.
11326
11327         canonicalize: avoid resolvepath
11328         * m4/canonicalize.m4 (gl_FUNC_CANONICALIZE_FILENAME_MODE): Delete
11329         unnecessary checks.
11330         * lib/canonicalize.c (includes): Simplify.
11331         (canonicalize_file_name): Drop resolvepath implementation.
11332         * modules/canonicalize (Depends-on): Drop filenamecat.
11333
11334         canonicalize: don't lose errno
11335         * lib/canonicalize.c (canonicalize_filename_mode): Protect errno
11336         over calls to free.
11337
11338         canonicalize: simplify errno handling
11339         * lib/canonicalize.c (__set_errno): Delete macro, and use direct
11340         assignment.
11341
11342         canonicalize, canonicalize-lgpl: update module dependencies
11343         * modules/canonicalize (Depends-on): Add extensions, lstat,
11344         pathmax, stdlib.
11345         (Files): Drop pathmax.h.
11346         (configure.ac): Adjust macro name.
11347         * modules/canonicalize-lgpl (Depends-on): Add errno, extensions,
11348         lstat, stdlib, sys_stat.
11349         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Rename...
11350         (gl_FUNC_CANONICALIZE_FILENAME_MODE): ...to this, and require
11351         extensions.
11352         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL)
11353         (gl_CANONICALIZE_LGPL_SEPARATE): Require extensions.
11354         (gl_PREREQ_CANONICALIZE_LGPL): Assume unistd.h.
11355         * lib/canonicalize.h (canonicalize_file_name): Use <stdlib.h>
11356         declaration, if available.
11357         * lib/canonicalize-lgpl.c [HAVE_READLINK]: Delete this condition;
11358         we can rely on the readlink module.
11359         (MAXSYMLINKS): Also consult SYMLOOP_MAX.
11360         (includes): Use <unistd.h> unconditionally.
11361
11362 2009-09-17  Eric Blake  <ebb9@byu.net>
11363
11364         maint: make Include sections of modules consistent
11365         * modules/alloca: Use only header name; no need to list #include.
11366         * modules/alloca-opt: Likewise.
11367         * modules/arpa_inet: Likewise.
11368         * modules/canon-host: Likewise.
11369         * modules/configmake: Likewise.
11370         * modules/dirent: Likewise.
11371         * modules/eealloc: Likewise.
11372         * modules/environ: Likewise.
11373         * modules/fchdir: Likewise.
11374         * modules/fcntl: Likewise.
11375         * modules/fcntl-h: Likewise.
11376         * modules/gethrxtime: Likewise.
11377         * modules/gettime: Likewise.
11378         * modules/ignore-value: Likewise.
11379         * modules/inet_ntop: Likewise.
11380         * modules/inet_pton: Likewise.
11381         * modules/inttypes: Likewise.
11382         * modules/isnand-nolibm: Likewise.
11383         * modules/isnanf-nolibm: Likewise.
11384         * modules/mbchar: Likewise.
11385         * modules/mbfile: Likewise.
11386         * modules/mbiter: Likewise.
11387         * modules/mbuiter: Likewise.
11388         * modules/netdb: Likewise.
11389         * modules/netinet_in: Likewise.
11390         * modules/nproc: Likewise.
11391         * modules/pagealign_alloc: Likewise.
11392         * modules/poll: Likewise.
11393         * modules/printf-frexp: Likewise.
11394         * modules/pthread: Likewise.
11395         * modules/putenv: Likewise.
11396         * modules/random_r: Likewise.
11397         * modules/relocatable-prog: Likewise.
11398         * modules/search: Likewise.
11399         * modules/select: Likewise.
11400         * modules/selinux-h: Likewise.
11401         * modules/settime: Likewise.
11402         * modules/signal: Likewise.
11403         * modules/size_max: Likewise.
11404         * modules/socklen: Likewise.
11405         * modules/ssize_t: Likewise.
11406         * modules/stdarg: Likewise.
11407         * modules/stdbool: Likewise.
11408         * modules/stddef: Likewise.
11409         * modules/stdint: Likewise.
11410         * modules/stdio: Likewise.
11411         * modules/stdlib: Likewise.
11412         * modules/string: Likewise.
11413         * modules/strings: Likewise.
11414         * modules/sys_file: Likewise.
11415         * modules/sys_ioctl: Likewise.
11416         * modules/sys_select: Likewise.
11417         * modules/sys_socket: Likewise.
11418         * modules/sys_stat: Likewise.
11419         * modules/sys_time: Likewise.
11420         * modules/sys_times: Likewise.
11421         * modules/sys_utsname: Likewise.
11422         * modules/sys_wait: Likewise.
11423         * modules/sysexits: Likewise.
11424         * modules/time: Likewise.
11425         * modules/times: Likewise.
11426         * modules/tmpfile: Likewise.
11427         * modules/trim: Likewise.
11428         * modules/unistd: Likewise.
11429         * modules/wchar: Likewise.
11430         * modules/wctype: Likewise.
11431
11432 2009-09-17  Bruno Haible  <bruno@clisp.org>
11433
11434         Make getdate.y compile on QNX and NetBSD 5 / i386.
11435         * m4/getdate.m4 (gl_GETDATE): Conditionally define
11436         TIME_T_FITS_IN_LONG_INT.
11437         * lib/getdate.y (long_time_t): New type.
11438         (relative_time): Change type of 'seconds' field to long_time_t.
11439         (get_date): Update types of local variables. Check against overflow
11440         during conversion from long_time_t to time_t.
11441         Reported by Matt Kraai <kraai@ftbfs.org>
11442         and Hasso Tepper <hasso@netbsd.org>.
11443
11444 2009-09-17  Bruno Haible  <bruno@clisp.org>
11445
11446         * modules/COPYING: Update copyright years.
11447         * modules/README: Likeiwse.
11448         * doc/gnulib-intro.texi (Copyright): Use a wildcard year.
11449         Reported by Ian Beckwith <ianb@erislabs.net>.
11450
11451 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
11452
11453         * users.txt: Update references for gnuit package.
11454
11455 2009-09-17  Ian Beckwith  <ianb@erislabs.net>  (tiny change)
11456
11457         * m4/getdelim.m4: Fix typo in copyright line.
11458
11459 2009-09-17  Bruno Haible  <bruno@clisp.org>
11460
11461         * lib/atoll.c: Use the standard header with GPL copyright.
11462         * lib/argz.in.h: Likewise.
11463         * lib/glob.c: Likewise.
11464         * lib/glob-libc.h: Likewise.
11465         * lib/random_r.c: Likewise.
11466         * lib/siglist.h: Likewise.
11467         * lib/strsignal.c: Likewise.
11468         Reported by Ian Beckwith <ianb@erislabs.net>.
11469
11470 2009-09-17  Eric Blake  <ebb9@byu.net>
11471
11472         rmdir: ensure correct dependency order
11473         * m4/rmdir.m4 (gl_FUNC_RMDIR): Require unistd defaults.
11474
11475 2009-09-17  Bruno Haible  <bruno@clisp.org>
11476
11477         Disable assertion that fails on NetBSD 5 / i386.
11478         * lib/mktime.c (ydhms_diff): Disable assertion about time_t size.
11479         Reported by Sam Steingold <sds@gnu.org>
11480         and Hasso Tepper <hasso@netbsd.org>.
11481
11482 2009-09-16  Eric Blake  <ebb9@byu.net>
11483
11484         unlinkdir: port to mingw
11485         * m4/unlinkdir.m4 (gl_UNLINKDIR): Add mingw to list of platforms
11486         on which no one can unlink a directory.
11487
11488         stdlib: sort witness names
11489         * modules/stdlib (Makefile.am): Sort replacements.
11490         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
11491         * lib/stdlib.in.h: Likewise.
11492
11493         parse-duration-tests: avoid link failure
11494         * modules/parse-duration-tests (test_parse_duration_LDADD): Add
11495         LIBINTL.
11496         Reported by Tom G. Christensen.
11497
11498         openat-tests: ensure unlinkat behaves like rmdir
11499         * tests/test-rmdir.c (main): Factor guts...
11500         * tests/test-rmdir.h (test_rmdir_func): ...into new file.
11501         * modules/rmdir-tests (Files): Ship new file.
11502         * modules/openat-tests: New test.
11503         * tests/test-unlinkat.c: Likewise.
11504
11505         rmdir-errno: mark obsolete, it is unsafe for cross-compilation
11506         * modules/rmdir-errno (Status, Notice): Now obsolete.
11507
11508         rmdir: work around cygwin 1.5.x and mingw bugs
11509         * m4/rmdir.m4 (gl_FUNC_RMDIR): Detect the bugs.
11510         * lib/rmdir.c (rmdir): Work around it.
11511         * modules/rmdir (Status, Notice): No longer obsolete.
11512         (Files): Add dos.m4.
11513         (Depends-on): Add unistd.
11514         (configure.ac): Set witnesses.
11515         (License): Relax to LGPLv2+.
11516         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set defaults.
11517         * modules/unistd (Makefile.am): Substitute witnesses.
11518         * lib/unistd.in.h (rmdir): Declare replacement.
11519         * doc/posix-functions/rmdir.texi (rmdir): Document this.
11520         * modules/rmdir-tests: New tests.
11521         * tests/test-rmdir.c: Likewise.
11522
11523 2009-09-15  Eric Blake  <ebb9@byu.net>
11524
11525         fchdir: improve use of replacement functions
11526         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Set appropriate witnesses.
11527         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add REPLACE_FSTAT.
11528         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add REPLACE_OPENDIR,
11529         REPLACE_CLOSEDIR.
11530         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_DUP.
11531         * modules/sys_stat (Makefile.am): Substitute correct witness.
11532         * modules/dirent (Makefile.am): Likewise.
11533         * modules/unistd (Makefile.am): Likewise.
11534         * lib/dirent.in.h (opendir, closedir): Use better witnesses.
11535         * lib/unistd.in.h (dup): Likewise.
11536         * lib/sys_stat.in.h (fstat): Likewise.
11537
11538         maint: ignore gnulib-tool temp files
11539         * .gitignore: Ignore files created during gnulib-tool --test.
11540
11541 2009-09-13  Jim Meyering  <meyering@redhat.com>
11542
11543         posixtm: don't reject a time that specify "60" as the number of seconds
11544         * lib/posixtm.c (posixtime): The code to reject invalid dates
11545         would also reject a time specified with the .60 suffix.
11546         But POSIX allows that, in order to accommodate leap seconds.
11547         So don't reject it.
11548         (main): Adjust tests accordingly.
11549         * modules/posixtm (Depends-on): Add stpcpy.
11550
11551 2009-09-11  Jim Meyering  <meyering@redhat.com>
11552
11553         announce-gen: include [$release_type] in emitted Subject:
11554         * build-aux/announce-gen (get_tool_versions): Include [$release_type],
11555         e.g., [stable] in the emitted Subject: line.
11556
11557 2009-09-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11558
11559         Remove obsolete macros from several modules.
11560         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Replace
11561         obsolete Autoconf macros with their modern counterparts.
11562         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): Likewise.
11563         * m4/gc-camellia.m4 (gl_GC_CAMELLIA): Likewise.
11564         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Likewise.
11565         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
11566         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Likewise.
11567         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
11568         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
11569         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
11570         * m4/poll.m4 (gl_FUNC_POLL): Likewise.
11571         * m4/readline.m4 (gl_FUNC_READLINE): Likewise.
11572         * m4/round.m4 (gl_FUNC_ROUND): Likewise.
11573         * m4/roundf.m4 (gl_FUNC_ROUNDF): Likewise.
11574         * m4/select.m4 (gl_FUNC_SELECT): Likewise.
11575         * m4/sockets.m4 (gl_SOCKETS): Likewise.
11576         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Likewise.
11577         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Likewise.
11578         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
11579         * m4/time_r.m4 (gl_TIME_R): Likewise.
11580         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Likewise.
11581         * m4/vararrays.m4 (AC_C_VARARRAYS): Likewise.
11582         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
11583
11584         Fix copyright header in build-aux scripts.
11585         * build-aux/git-version-gen: Fix copyright header to match GPLv3
11586         recommendation.
11587         * build-aux/ncftpput-ftp: Likewise.
11588         * build-aux/update-copyright: Likewise.
11589
11590 2009-09-09  Eric Blake  <ebb9@byu.net>
11591
11592         test-link: allow Linux choice of errno
11593         * tests/test-link.c (main): Relax test for alternate error.
11594
11595         strndup: fix improper m4 caching
11596         * m4/strndup.m4 (gl_FUNC_STRNDUP): Rework to avoid side effects
11597         inside AC_CACHE_CHECK.  Use REPLACE_STRNDUP, not HAVE_STRNDUP.
11598         (gl_PREREQ_STRNDUP): Delete.
11599         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Update default.
11600         * modules/string (Makefile.am): Substitute it.
11601         * lib/string.in.h (strndup): Modernize prototype.
11602
11603         getcwd: port to mingw
11604         * m4/getcwd.m4 (gl_FUNC_GETCWD): Mingw directories are very
11605         different from the POSIX assumptions made throughout the getcwd
11606         module; fortunately, the mingw getcwd does not need replacement.
11607         (gl_FUNC_GETCWD_NULL): Skip test on mingw.
11608         * modules/getcwd-tests: New test.
11609         * tests/test-getcwd.c: Likewise.
11610
11611         link: fix platform bugs
11612         * m4/link.m4 (gl_FUNC_LINK): Detect Solaris and Cygwin bugs.
11613         * lib/link.c (link): Work around them.  Fix related mingw bug.
11614         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add REPLACE_LINK.
11615         * modules/unistd (Makefile.am): Substitute it.
11616         * lib/unistd.in.h (link): Declare replacement.
11617         * doc/posix-functions/link.texi (link): Document this.
11618         * modules/link (Depends-on): Add strdup-posix, sys_stat.
11619
11620         test-link: consolidate into single C program, test more cases
11621         * tests/test-link.sh: Delete.
11622         * tests/test-link.c: Test more error conditions.  Exposes bugs on
11623         at least Cygwin and Solaris.
11624         * modules/link-tests (Files): Remove unused file.
11625         (Depends-on): Add errno, sys_stat.
11626         (Makefile.am): Simplify.
11627
11628 2009-09-08  Bruno Haible  <bruno@clisp.org>
11629
11630         Work around towlower, towupper bug on mingw.
11631         * lib/wctype.in.h (towlower, towupper) [__MINGW32__]: New replacements.
11632         * m4/wctype.m4 (gl_WCTYPE_H): Replace <wctype.h> also on mingw.
11633         * doc/posix-functions/towlower.texi: Mention the mingw bug.
11634         * doc/posix-functions/towupper.texi: Likewise.
11635         Reported by Eric Blake.
11636
11637 2009-09-08  Jim Meyering  <meyering@redhat.com>
11638
11639         build: don't try to run autoheader if we don't use it
11640         * build-aux/bootstrap: Define AUTOHEADER=true when AC_CONFIG_HEADERS
11641         is not used in configure.ac.
11642
11643 2009-09-08  Eric Blake  <ebb9@byu.net>
11644
11645         euidaccess: fix compilation error
11646         * lib/euidaccess.c (includes): Add <fcntl.h>, for AT_EACCESS.
11647
11648         rawmemchr: relax license
11649         * modules/rawmemchr (License): Derived from glibc, so LGPLv2+ is
11650         okay.
11651         Reported by Jim Meyering.
11652
11653         mkfifoat: new module
11654         * modules/mkfifoat: New file.
11655         * lib/mkfifoat.c: Likewise.
11656         * m4/mkfifoat.m4 (gl_FUNC_MKFIFOAT): Likewise.
11657         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Add witnesses.
11658         * modules/sys_stat (Makefile.am): Use them.
11659         * lib/sys_stat.in.h (mkfifoat, mknodat): Declare them.
11660         * MODULES.html.sh (File system functions): Mention module.
11661         * doc/posix-functions/mkfifoat.texi (mkfifoat): Likewise.
11662         * doc/posix-functions/mknodat.texi (mknodat): Likewise.
11663         * modules/mkfifoat-tests: New test.
11664         * tests/test-mkfifoat.c: Likewise.
11665
11666         strchrnul: relax license
11667         * modules/strchrnul (License): Derived from glibc, so LGPLv2+ is
11668         okay.
11669         Reported by Jim Meyering.
11670
11671 2009-09-08  Eric Blake  <ebb9@byu.net>
11672
11673         fstatat: fix compilation on Solaris
11674         * lib/fstatat.c (includes): Add fcntl.h.
11675         Reported by Pádraig Brady.
11676
11677 2009-09-07  Eric Blake  <ebb9@byu.net>
11678
11679         rename: modernize replacement
11680         * modules/rename (Depends-on): Add stdio.
11681         (configure.ac): Declare witness.
11682         * m4/rename.m4 (gl_FUNC_RENAME): Ensure dependency order, and let
11683         stdio take care of replacement.
11684         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
11685         * modules/stdio (Makefile.am): Substitute them.
11686         * lib/stdio.in.h (rename): Declare replacement.
11687         * lib/rename.c (includes): Allow cross-compilation to non-windows
11688         machines.
11689         * doc/posix-functions/rename.texi (rename): Improve
11690         documentation.
11691
11692         stdio: sort witness names
11693         * modules/stdio (Makefile.am): Sort replacements.
11694         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
11695         * lib/stdio.in.h: Likewise.
11696
11697         getcwd: minor cleanups
11698         * lib/getcwd.c (AT_FDCWD): Delete; rely on <fcntl.h> instead.
11699         (is_ENAMETOOLONG): Delete; ENAMETOOLONG is portable.
11700
11701         openat: provide more convenience names
11702         * modules/faccessat (configure.ac): Add C witness.
11703         * lib/unistd.in.h (readlinkat): Fix typo.
11704         * lib/openat.h (statat, lstatat, accessat, euidaccessat): New
11705         convenience wrappers.
11706         * top/maint.mk (sc_prohibit_openat_without_use): Allow these
11707         wrappers in syntax checks.
11708
11709 2009-09-06  Eric Blake  <ebb9@byu.net>
11710
11711         doc: fix comments in recent patches
11712         * lib/faccessat.c: Mention correct function.
11713         * lib/fchmodat.c: Likewise.
11714         * lib/fchownat.c: Likewise.
11715         * lib/symlinkat.c: Likewise.
11716         * doc/posix-headers/fcntl.texi (fcntl.h): Cygwin 1.7 has AT_*
11717         constants.
11718
11719         faccessat, symlinkat: continue cleanup of previous patch
11720         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Ensure dependency order.
11721         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
11722         * modules/unistd (Makefile.am): Substitute GNULIB_READLINKAT.
11723         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Offer GNULIB_READLINKAT.
11724         * modules/symlinkat (configure.ac): Set GNULIB_READLINKAT.
11725         * lib/unistd.in.h (readlinkat): Declare if GNULIB_READLINKAT is
11726         set.
11727
11728 2009-09-06  Bruno Haible  <bruno@clisp.org>
11729
11730         * lib/sys_stat.in.h (fchmodat): Declare if GNULIB_FCHMODAT is set.
11731         (fstatat): Declare if GNULIB_FSTATAT is set.
11732         (mkdirat): Declare if GNULIB_MKDIRAT is set.
11733         * lib/unistd.in.h (fchownat): Declare if GNULIB_FCHOWNAT is set.
11734         (unlinkat): Declare if GNULIB_UNLINKAT is set.
11735         * modules/fcntl-h (Files): Remove m4/openat.m4.
11736         * modules/sys_stat (Files): Remove m4/openat.m4.
11737         (Makefile.am): Substitute GNULIB_FCHMODAT, GNULIB_FSTATAT,
11738         GNULIB_MKDIRAT instead of GNULIB_OPENAT.
11739         * modules/unistd (Files): Remove m4/openat.m4.
11740         (Makefile.am): Substitute GNULIB_FCHOWNAT, GNULIB_UNLINKAT instead of
11741         GNULIB_OPENAT.
11742         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize GNULIB_OPENAT,
11743         HAVE_OPENAT here. Don't require gl_OPENAT_DEFAULTS.
11744         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize
11745         GNULIB_FCHMODAT, GNULIB_FSTATAT, GNULIB_MKDIRAT, HAVE_FCHMODAT,
11746         HAVE_FSTATAT, HAVE_MKDIRAT, REPLACE_FSTATAT here. Don't require
11747         gl_OPENAT_DEFAULTS.
11748         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_FCHOWNAT,
11749         GNULIB_UNLINKAT, HAVE_FCHOWNAT, HAVE_UNLINKAT, REPLACE_FCHOWNAT here.
11750         Don't require gl_OPENAT_DEFAULTS.
11751         * m4/openat.m4 (gl_FUNC_OPENAT): Require gl_FCNTL_H_DEFAULTS,
11752         gl_SYS_STAT_H_DEFAULTS, gl_UNISTD_H_DEFAULTS. Set GNULIB_FCHMODAT,
11753         GNULIB_FSTATAT, GNULIB_MKDIRAT, GNULIB_FCHOWNAT, GNULIB_UNLINKAT.
11754         (gl_OPENAT_DEFAULTS): Remove macro.
11755
11756 2009-09-06  Bruno Haible  <bruno@clisp.org>
11757
11758         * modules/openat (configure.ac): Remove unneeded witness.
11759
11760 2009-09-06  Bruno Haible  <bruno@clisp.org>
11761
11762         Set errno to ENOSYS when a function is entirely unsupported.
11763         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Set errno to ENOSYS instead of
11764         EOPNOTSUPP.
11765         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
11766         * modules/chown (Depends-on): Remove errno.
11767
11768 2009-09-06  Bruno Haible  <bruno@clisp.org>
11769
11770         * doc/posix-headers/fcntl.texi (AT_*): Mention affected platforms.
11771
11772 2009-09-06  Bruno Haible  <bruno@clisp.org>
11773
11774         * lib/sys_stat.in.h: Fix preprocessor command indentation.
11775
11776 2009-09-06  Ben Pfaff  <blp@gnu.org>
11777             Bruno Haible  <bruno@clisp.org>
11778
11779         Work around a glibc bug in strtok_r.
11780         * lib/string.in.h (strtok_r): Replace if REPLACE_STRTOK_R is set.
11781         Undefine if UNDEFINE_STRTOK_R is set.
11782         * lib/strtok_r.c (strtok_r, __strtok_r) [!_LIBC]: Don't undefine.
11783         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
11784         REPLACE_STRTOK_R and UNDEFINE_STRTOK_R.
11785         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Check against the glibc bug.
11786         * modules/string (Makefile.am): Substitute REPLACE_STRTOK_R,
11787         UNDEFINE_STRTOK_R.
11788         * doc/posix-functions/strtok_r.texi: Mention the glibc 2.7 bug.
11789
11790 2009-09-06  Sergey Poznyakoff  <gray@gnu.org.ua>
11791
11792         exclude: minor fix
11793         * lib/exclude.c: Include wctype.h
11794
11795 2009-09-06  Akim Demaille  <demaille@gostai.com>
11796
11797         bootstrap: improve error message
11798         * build-aux/bootstrap (find_tool): Upon failure, report the list
11799         of candidates.
11800         Honor the initial value of the envvar.
11801
11802 2009-09-05  Eric Blake  <ebb9@byu.net>
11803
11804         symlinkat: new module
11805         * modules/symlinkat: New file.
11806         * lib/symlinkat.c: Likewise.
11807         * m4/symlinkat.m4 (gl_FUNC_SYMLINKAT): Likewise.
11808         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witnesses.
11809         * modules/unistd (Makefile.am): Use them.
11810         * lib/unistd.in.h (symlinkat, readlinkat): Declare them.
11811         (faccessat) [GNULIB_POSIXCHECK]: Fix typo.
11812         * lib/at-func.c (FUNC_RESULT): New macro, defaulting to int.
11813         * MODULES.html.sh (File system functions): Mention module.
11814         * doc/posix-functions/symlinkat.texi (symlinkat): Likewise.
11815         * doc/posix-functions/readlinkat.texi (readlinkat): Likewise.
11816         * modules/symlinkat-tests: New test.
11817         * tests/test-symlinkat.c: Likewise.
11818
11819         test-openat-safer: add more checks
11820         * tests/test-openat-safer.c (main): Check more code paths.
11821
11822 2009-09-05  Jim Meyering  <meyering@redhat.com>
11823
11824         syntax-check: detect unnecessary inclusion of openat.h
11825         * top/maint.mk (sc_prohibit_openat_without_use): New rule.
11826
11827 2009-09-05  Bruno Haible  <bruno@clisp.org>
11828
11829         Support towlower, towupper.
11830         * doc/posix-functions/towlower.texi: Mention module wctype.
11831         * doc/posix-functions/towupper.texi: Likewise.
11832         * lib/wctype.in.h (towlower, towupper): New functions.
11833         * tests/test-wctype.c: Include stdio.h, stdlib.h.
11834         (ASSERT): New macro.
11835         (e): New variable.
11836         (main): Test also towlower, towupper. Test WEOF argument.
11837         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
11838
11839 2009-09-05  Bruno Haible  <bruno@clisp.org>
11840
11841         Fix conversion behaviour when the input is invalid.
11842         * lib/striconveh.c (mem_cd_iconveh_internal): Fix storing of question
11843         mark occurring in first pass of indirect conversion.
11844         * tests/test-striconveh.c (main): Test conversion of invalid ASCII
11845         input.
11846         Found by clang's static analyzer.
11847
11848 2009-09-05  Bruno Haible  <bruno@clisp.org>
11849
11850         * tests/test-striconveh.c (main): Test indirect conversion on platforms
11851         where direct conversion is possible.
11852
11853 2009-09-04  Eric Blake  <ebb9@byu.net>
11854
11855         openat: fail with ENOENT on empty name
11856         * lib/openat-proc.c (openat_proc_name): Special-case the empty
11857         buffer.
11858
11859         link-follow: fix logic bug in prior patch
11860         * m4/link-follow.m4 (gl_FUNC_LINK_FOLLOWS_SYMLINK): Fix bug that
11861         reversed sense of yes and no in prior patch.  Avoid confusing
11862         compilation failure with desired semantics.
11863
11864         link-follow: accomodate mingw and cross-compilation
11865         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Rename...
11866         (gl_FUNC_LINK_FOLLOWS_SYMLINK): ...to this.  Change
11867         cross-compilation results to -1, to make linkat easier to
11868         implement when cross-compiling.  Trivially support mingw.
11869         * modules/link-follow (configure.ac): Call new name.
11870         * NEWS: Mention this.
11871
11872 2009-09-03  Eric Blake  <ebb9@byu.net>
11873
11874         faccessat: compile replacement
11875         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Build replacement when
11876         needed.
11877
11878         fts: fix compilation error
11879         * lib/fts.c (includes): Re-add "openat.h", for
11880         openat_needs_fchdir.
11881
11882         faccessat: new module
11883         * modules/faccessat: New file.
11884         * lib/faccessat.c: Likewise.
11885         * m4/faccessat.m4 (gl_FUNC_FACCESSAT): Likewise.
11886         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
11887         * modules/unistd (Makefile.am): Use it.
11888         * lib/unistd.in.h (faccessat): Declare it.
11889         (F_OK, X_OK, W_OK, R_OK): Provide definitions.
11890         * lib/fcntl.in.h (AT_SYMLINK_FOLLOW, AT_EACCESS): Likewise.
11891         * MODULES.html.sh (File system functions): Mention it.
11892         * doc/posix-functions/faccessat.texi (faccessat): Likewise.
11893         * doc/posix-headers/fcntl.texi (fcntl.h): Likewise.
11894
11895         euidaccess: prefer POSIX over non-standard implementation
11896         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Check for faccessat.
11897         * lib/euidaccess.c (euidaccess): Use it if available.
11898
11899         openat: make template easier to use
11900         * lib/at-func.c (CALL_FUNC): Allow AT_FUNC_USE_F1_COND and
11901         AT_FUNC_F2 to be undefined.
11902         (VALIDATE_FLAG): New macro; use it to reject bad flags.
11903         (AT_FUNC_USE_F1_COND): Change sense to just flag bit.
11904         * lib/fchmodat.c (AT_FUNC_USE_F1_COND): Adjust.
11905         * lib/fchownat.c (AT_FUNC_USE_F1_COND): Likewise.
11906         * lib/openat.c (AT_FUNC_USE_F1_COND) [fstatat, unlinkat]:
11907         Likewise.
11908         * lib/mkdirat.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND): Delete.
11909         * lib/selinux-at.c (AT_FUNC_F2, AT_FUNC_USE_F1_COND)
11910         [getfileconat, lgetfileconat, setfileconat, lsetfileconat]:
11911         Likewise.
11912
11913         openat: declare in POSIX headers
11914         * NEWS: Mention this.
11915         * modules/openat (configure.ac): Declare witnesses.
11916         (Depends-on): Add fcntl-h, sys_stat, unistd.
11917         (Include): Mention correct headers.
11918         * modules/fcntl-h (Depends-on): Add link-warning.
11919         (Files): Add openat.m4.
11920         (Makefile.am): Substitute witnesses.
11921         * modules/sys_stat (Files, Makefile.am): Likewise.
11922         * modules/unistd (Files, Makefile.am): Likewise.
11923         * m4/openat.m4 (gl_FUNC_OPENAT, gl_FUNC_FCHOWNAT): Set witnesses.
11924         (gl_OPENAT_DEFAULTS): New macro.
11925         * m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Use it.
11926         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
11927         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
11928         (SYS_STAT_H): Remove unused variable.
11929         * doc/posix-headers/fcntl.texi (fcntl.h): Update content.
11930         * lib/fcntl--.h (includes): Remove unneeded header.
11931         * lib/openat-safer.c (includes): Likewise.
11932         * lib/openat.h (AT_FDCWD, AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR)
11933         (openat, fstatat, unlinkat, mkdirat, fchmodat, fchownat): Move to
11934         appropriate headers.
11935         (__OPENAT_PREFIX): Delete.
11936         * lib/fcntl.in.h (openat): Provide declaration.
11937         (AT_FDCWD): Fix Solaris bug.
11938         (AT_SYMLINK_NOFOLLOW, AT_REMOVEDIR): Provide macros.
11939         * lib/sys_stat.in.h (fstatat, mkdirat): Provide declaration.
11940         * lib/fchmodat.c (includes):  Adjust to find declaration.
11941         * lib/fchownat.c (includes): Likewise.
11942         * lib/mkdirat.c (includes): Likewise.
11943         * lib/fstatat.c (includes): Likewise.  Ensure original fstatat is
11944         still visible.
11945
11946 2009-09-02  Eric Blake  <ebb9@byu.net>
11947
11948         errno: use consistently
11949         * lib/c-stack.c (ENOTSUP): <errno.h> guarantees a definition.
11950         * lib/canonicalize-lgpl.c (ENAMETOOLONG): Likewise.
11951         * lib/canonicalize.c (ELOOP): Likewise.
11952         * lib/inet_ntop.c (EAFNOSUPPORT): Likewise.
11953         * lib/inet_pton.c (EAFNOSUPPORT): Likewise.
11954         * lib/lchown.c (EOPNOTSUPP): Likewise.
11955         * lib/openat-priv.h (ENOSYS, EOPNOTSUPP): Likewise.
11956         * lib/savewd.c (ESTALE): Likewise.
11957         * lib/settime.c (ENOSYS): Likewise.
11958         * lib/utimens.c (ENOSYS): Likewise.
11959         * lib/xgethostname.c (ENAMETOOLONG): Likewise.
11960         * lib/chdir-safer.c (ELOOP): Likewise.
11961         (chdir_no_follow): Use HAVE_READLINK, not ELOOP, as witness.
11962         * modules/c-stack (Depends-on): Add errno.
11963         * modules/canonicalize (Depends-on): Likewise.
11964         * modules/chdir-safer (Depends-on): Likewise.
11965         * modules/fdopendir (Depends-on): Likewise.
11966         * modules/inet_ntop (Depends-on): Likewise.
11967         * modules/inet_pton (Depends-on): Likewise.
11968         * modules/lchown (Depends-on): Likewise.
11969         * modules/openat (Depends-on): Likewise.
11970         * modules/savewd (Depends-on): Likewise.
11971         * modules/settime (Depends-on): Likewise.
11972         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Check for readlink.
11973
11974         fts: avoid leaking fds
11975         * modules/fts (Depends-on): Add cloexec.
11976         * lib/fts.c (opendirat, diropen, fts_build): Set close-on-exec
11977         flag.
11978
11979         fts: make directory fds more robust
11980         * lib/fts.c (O_DIRECTORY): Let <fcntl.h> take care of this.
11981         (opendirat): Specify O_DIRECTORY, and add fallbacks for safety.
11982
11983         backupfile, chdir-long, fts, savedir: make safer
11984         * lib/backupfile.c (includes): Use "dirent--.h", since
11985         numbered_backup can write to stderr during readdir.
11986         * lib/savedir.c (includes): Likewise.
11987         * lib/chdir-long.c (includes): Use "fcntl--.h", since openat
11988         emulation can write to stderr on failure.
11989         * lib/fts.c (includes) [!_LIBC]: Likewise for opendir and openat.
11990         * lib/getcwd.c: Document why opendir_safer is unused.
11991         * lib/glob.c: Likewise.
11992         * lib/scandir.c: Likewise.
11993         * lib/openat-proc.c: Likewise, for open_safer.
11994         * modules/backupfile (Depends-on): Add dirent-safer.
11995         * modules/savedir (Depends-on): Likewise.
11996         * modules/fts (Depends-on): Add dirent-safer and openat-safer.
11997         * modules/chdir-long (Depends-on): Add openat-safer.
11998
11999         openat-safer: new module
12000         * modules/openat-safer: New file.
12001         * lib/openat-safer.c: Likewise.
12002         * m4/fcntl-safer.m4 (gl_OPENAT_SAFER): New macro.
12003         * lib/fcntl-safer.h (openat_safer): Declare.
12004         * lib/fcntl--.h (openat): Override.
12005         * MODULES.html.sh (File descriptor based I/O): Mention it.
12006         * lib/openat.h: Add double-inclusion guards.
12007         * lib/openat.c (includes): Only include "fcntl-safer.h", not
12008         "fcntl--.h", so we can implement openat.
12009         * modules/openat-safer-tests: New test.
12010         * tests/test-openat-safer.c: New file.
12011
12012         dirent-safer: new module
12013         * modules/dirent-safer: New file.
12014         * lib/dirent--.h: Likewise.
12015         * lib/dirent-safer.h: Likewise.
12016         * lib/opendir-safer.c: Likewise.
12017         * m4/dirent-safer.m4: Likewise.
12018         * MODULES.html.sh (Enhancements for POSIX:2008): Mention it.
12019         * modules/dirent-safer-tests: New test.
12020         * tests/test-dirent-safer.c: New file.
12021         * lib/fdopendir.c (includes): Ensure fdopendir is also safe.
12022
12023         fdopendir: optimize on mingw
12024         * lib/unistd.in.h (_gl_directory_name): New prototype.
12025         * lib/fchdir.c (_gl_directory_name): Implement it.
12026         (fchdir): Use it to simplify implementation.
12027         * lib/fdopendir.c (fdopendir) [REPLACE_FCHDIR]: Use metadata from
12028         fchdir, when available, to avoid calling [f]chdir().
12029
12030         fdopendir: split into its own module
12031         * lib/openat.c (fdopendir): Move...
12032         * lib/fdopendir.c: ...into new file.
12033         * modules/fdopendir: New module.
12034         * m4/fdopendir.m4 (gl_FUNC_FDOPENDIR): New file.
12035         * modules/openat (Depends-on): Add fdopendir.
12036         * m4/openat.m4 (gl_FUNC_OPENAT): No longer need to check for
12037         fdopendir here.
12038         * modules/savedir (Depends-on): Only need fdopendir, not full
12039         openat.
12040         * lib/savedir.c (include): Use <dirent.h>, not "openat.h".
12041         * lib/openat.h (fdopendir): Drop prototype.
12042         * lib/dirent.in.h (fdopendir): Provide prototype.
12043         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Add replacements.
12044         * modules/dirent (Makefile.am): Substitute them.
12045         * MODULES.html.sh (File system functions): Mention it.
12046         * doc/posix-functions/fdopendir.texi (fdopendir): Likewise.
12047         * modules/fdopendir-tests: New file.
12048         * tests/test-fdopendir.c: Likewise.
12049
12050         fchdir: use more consistent macro convention
12051         * lib/fcntl.in.h (_gl_register_fd): Move declaration to unistd.
12052         * lib/sys_stat.in.h (rpl_fstat): Declare via make-time
12053         REPLACE_FCHDIR, rather than relying on config.h macros.
12054         * lib/unistd.in.h (fchdir): Move all fchdir internal declarations
12055         inside a single make-time REPLACE_FCHDIR block, rather than using
12056         the config.h FCHDIR_REPLACEMENT.
12057         * m4/fchdir.m4 (gl_FUNC_FCHDIR): REPLACE_FCHDIR was already
12058         AC_SUBST'd, also AC_DEFINE it.  Don't define FCHDIR_REPLACEMENT.
12059         Manage fstat replacement.
12060         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Pick up
12061         REPLACE_FCHDIR.
12062         * modules/sys_stat (Files): Add m4/unistd_h.m4.
12063         (Makefile.am): Substitute REPLACE_FCHDIR.
12064         * lib/close.c (rpl_close): Use REPLACE_FCHDIR, not
12065         FCHDIR_REPLACEMENT.
12066         * lib/dup-safer.c (dup_safer): Likewise.
12067         * lib/dup2.c (rpl_dup2): Likewise.
12068         * lib/dup3.c (rpl_dup3): Likewise.
12069         * lib/open.c (rpl_open): Likewise.
12070
12071         fchdir: simplify error handling, and support dup3
12072         * modules/fchdir (Depends-on): Use strdup-posix, not strdup.  Add
12073         stdbool, malloc-posix, realloc-posix.
12074         * lib/fchdir.c (struct dir_info_t): Delete saved_errno.
12075         (ensure_dirs_slot): Return false on allocation failure.
12076         (rpl_dup2): Delete.
12077         (_gl_register_dup): New function.
12078         (_gl_unregister_fd, rpl_opendir, rpl_dup): Update callers.
12079         (_gl_register_fd): Close fd on allocation failure.
12080         * lib/fcntl.in.h (_gl_register_fd): Update signature.
12081         * lib/unistd.in.h (_gl_register_dup) [FCHDIR_REPLACEMENT]: New
12082         prototype.
12083         (rpl_dup2_fchdir): Delete prototype.
12084         * lib/open.c (open): Update caller.
12085         * lib/dup2.c (dup2): Track fchdir metadata.
12086         * lib/dup3.c (dup3): Likewise.
12087         * m4/dup2.m4 (gl_REPLACE_DUP2): New macro.
12088         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Use it.
12089
12090 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12091
12092         * gnulib-tool (func_create_testdir, func_create_megatestdir): Use
12093         AC_CONFIG_HEADERS instead of AM_CONFIG_HEADER. Use AC_CONFIG_FILES and
12094         don't pass arguments to AC_OUTPUT.
12095
12096 2009-09-02  Bruno Haible  <bruno@clisp.org>
12097
12098         * modules/mkdtemp (License): Relicense under LGPLv2+.
12099         Reported by Paolo Bonzini.
12100
12101 2009-09-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12102
12103         Replace uses of obsolete autoconf macros in Jim's modules.
12104         The Autoconf macros AC_TRY_CPP, AC_TRY_COMPILE, AC_TRY_LINK and
12105         AC_TRY_RUN have been obsolete since Autoconf 2.55, and each use
12106         can evoke a warning from autoconf when run with -Wobsolete
12107         enabled.  They were declared obsolete for good reasons (see
12108         the `AC_FOO_IFELSE vs AC_TRY_FOO' node in the Autoconf manual,
12109         recently renamed to `AC_ACT_IFELSE vs AC_TRY_ACT'), and we
12110         should not continue using the deprecated macros.
12111         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Replace
12112         obsolete Autoconf macros with modern counterparts.
12113         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
12114         * m4/dos.m4 (gl_AC_DOS): Likewise.
12115         * m4/fpending.m4 (gl_FUNC_FPENDING): Likewise.
12116         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Likewise.
12117         * m4/getloadavg.m4 (gl_PREREQ_GETLOADAVG): Likewise.
12118         * m4/jm-winsz1.m4 (gl_WINSIZE_IN_PTEM): Likewise.
12119         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Likewise.
12120         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Likewise.
12121         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Likewise.
12122         * m4/mode_t.m4 (gl_PROMOTED_TYPE_MODE_T): Likewise.
12123         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
12124         Likewise.
12125         * m4/rename.m4 (gl_FUNC_RENAME): Likewise.
12126         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
12127         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Likewise.
12128         * m4/st_dm_mode.m4 (AC_STRUCT_ST_DM_MODE): Likewise.
12129         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
12130         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
12131
12132 2009-09-01  Eric Blake  <ebb9@byu.net>
12133
12134         fchdir: fix off-by-one bug in previous patch
12135         * lib/fchdir.c (rpl_fstat): Use correct bounds.
12136         (_gl_unregister_fd): Delete useless if.
12137
12138 2009-09-01  Daniel P. Berrange  <berrange@redhat.com>
12139
12140         maint.mk: sort the list of syntax-check rules
12141         * top/maint.mk (syntax-check-rules): Sort syntax-check rules, so it's
12142         easier to get a sense of progress when the rules are run sequentially
12143         and take a long time.
12144
12145 2009-09-01  Simon Josefsson  <simon@josefsson.org>
12146
12147         * modules/arpa_inet: Use $(MKDIR_P) instead of @MKDIR_P@.
12148         * modules/netinet_in: Likewise.
12149         * modules/sys_file: Likewise.
12150         * modules/sys_ioctl: Likewise.
12151         * modules/sys_select: Likewise.
12152         * modules/sys_socket: Likewise.
12153         * modules/sys_stat: Likewise.
12154         * modules/sys_time: Likewise.
12155         * modules/sys_times: Likewise.
12156         * modules/sys_utsname: Likewise.
12157         * modules/sys_wait: Likewise.
12158
12159 2009-09-01  Jim Meyering  <meyering@redhat.com>
12160
12161         fts: help ensure that return values are not ignored
12162         * lib/fts_.h (__GNUC_PREREQ): Define.
12163         (__attribute_warn_unused_result__): Define.
12164         (fts_children, fts_close, fts_open, fts_read): Declare with
12165         __attribute_warn_unused_result__.
12166
12167         fts: fts_close now fails also when closing a dir file descriptor fails
12168         * lib/fts.c (fts_close): Detect close failure, not just fchdir failure,
12169         and propagate to caller, along with errno.
12170
12171         announce-gen: correct formatting in --help output
12172         * build-aux/announce-gen (usage): Move the one-line description in
12173         --help output "up", to where it belongs, just after Usage:.
12174
12175 2009-08-31  Eric Blake  <ebb9@byu.net>
12176
12177         fchdir: port to mingw
12178         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Check for mingw bug.
12179         * lib/open.c (open) [FCHDIR_REPLACEMENT]: If directories can't be
12180         opened, then use a substitute.
12181         * lib/sys_stat.in.h (fstat) [REPLACE_OPEN_DIRECTORY]: Declare
12182         replacement.
12183         * lib/fchdir.c (fstat) [REPLACE_OPEN_DIRECTORY]: Implement it.
12184         (_gl_register_fd): No need to check stat if open already filters
12185         all directories.
12186         (fchdir): Fix error condition to match POSIX.
12187         * modules/fchdir (Depends-on): Add sys_stat.
12188         * doc/posix-functions/open.texi (open): Document the limitation.
12189         * modules/fchdir-tests: New file.
12190         * tests/test-fchdir.c: Likewise.
12191
12192         canonicalize: allow cross-testing from cygwin to mingw
12193         * modules/canonicalize-tests (configure.ac): Define HAVE_SYMLINK.
12194         (Makefile.am): Pass it through TESTS_ENVIRONMENT.
12195         * modules/canonicalize-lgpl-tests (configure.ac, Makefile.am):
12196         Likewise.
12197         * tests/test-canonicalize.sh: Also skip test if 'ln -s' works, but
12198         target does not support symlinks.
12199         * tests/test-canonicalize-lgpl.sh: Likewise.
12200
12201         chown: avoid compilation warning on mingw
12202         * m4/chown.m4 (gl_FUNC_CHOWN): Recognize missing chown.
12203         * lib/chown.c (rpl_chown) [!HAVE_CHOWN]: Always return failure on
12204         mingw.
12205         * lib/lchown.c (lchown) [!HAVE_CHOWN]: Likewise.
12206         * modules/chown (Depends-on): Add errno.
12207
12208 2009-08-31  Stefano Lattarini  <stefano.lattarini@gmail.com>  (tiny change)
12209
12210         * gnulib-tool: Fix test whether $CONFIG_SHELL has a working 'echo'
12211         command.
12212
12213 2009-08-31  Jim Meyering  <meyering@redhat.com>
12214
12215         canonicalize: remove useless initialization
12216         * lib/canonicalize.c (canonicalize_filename_mode): Remove useless
12217         initialization of local, "end".
12218
12219 2009-08-30  Bruno Haible  <bruno@clisp.org>
12220
12221         Fix an unnecessary error on Solaris 10 on NFSv3 file systems.
12222         * lib/set-mode-acl.c (qset_acl) [Solaris 10 new]: Treat EOPNOTSUPP like
12223         ENOSYS.
12224
12225 2009-08-30  Bruno Haible  <bruno@clisp.org>
12226
12227         * tests/test-pipe-filter-ii1.sh: Prefer /usr/xpg6/bin/tr over
12228         /usr/xpg4/bin/tr when it exists.
12229         * tests/test-pipe-filter-gi1.sh: Likewise.
12230
12231 2009-08-30  Bruno Haible  <bruno@clisp.org>
12232
12233         Work around deficient /usr/bin/id program on Solaris.
12234         * tests/test-file-has-acl.sh (ID): New variable.
12235         * tests/test-set-mode-acl.sh (ID): Likewise.
12236         * tests/test-copy-acl.sh (ID): Likewise.
12237         * tests/test-copy-file.sh (ID): Likewise.
12238
12239 2009-08-30  Bruno Haible  <bruno@clisp.org>
12240
12241         New module 'xstriconveh'.
12242         * lib/xstriconveh.h: New file.
12243         * lib/xstriconveh.c: New file.
12244         * modules/xstriconveh: New file.
12245
12246 2009-08-30  Bruno Haible  <bruno@clisp.org>
12247
12248         Make it easier to use mem_cd_iconveh.
12249         * lib/striconveh.h (iconveh_t): New type.
12250         (iconveh_open, iconveh_close): New declarations.
12251         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
12252         with a single 'const iconveh_t *' argument.
12253         * lib/striconveh.c (iconveh_open, iconveh_close): New functions.
12254         (mem_cd_iconveh, str_cd_iconveh): Replace the three iconv_t arguments
12255         with a single 'const iconveh_t *' argument.
12256         (mem_iconveh, str_iconveh): Use iconveh_open, iconveh_close.
12257         * tests/test-striconveh.c (main): Update.
12258         * NEWS: Mention the change.
12259
12260 2009-08-30  Bruno Haible  <bruno@clisp.org>
12261
12262         * doc/posix-functions/iconv_open.texi: Mention indirect conversion
12263         problem.
12264
12265 2009-08-30  Bruno Haible  <bruno@clisp.org>
12266
12267         Work around iconv_open problem on Solaris.
12268         * lib/iconv_open-solaris.gperf: New file.
12269         * lib/iconv_open.c (ICONV_FLAVOR_SOLARIS): New macro.
12270         * m4/iconv_open.m4 (gl_FUNC_ICONV_OPEN): Also handle Solaris.
12271         * modules/iconv_open (Files): Add lib/iconv_open-solaris.gperf.
12272         (Makefile.am): Add rule for iconv_open-solaris.h. Augment
12273         BUILT_SOURCES, MOSTLYCLEANFILES, MAINTAINERCLEANFILES, EXTRA_DIST.
12274         * doc/posix-functions/iconv_open.texi: Mention the Solaris problem.
12275
12276 2009-08-29  Jim Meyering  <meyering@redhat.com>
12277
12278         maint.mk: remove more coreutils-specific targets; XZ_OPT=-9ev
12279         * top/maint.mk (cvs-check): Remove target; it was just an alias
12280         to the better-named vc-diff-check.
12281         (maintainer-distcheck): Remove rule.  It was used only from
12282         the (alpha/beta/major) target, and all of its commands but one
12283         were coreutils-specific.
12284         (vc-dist): Remove rule.
12285         (alpha beta major): Run "$(MAKE) distcheck" explicitly.
12286         Run vc-diff-check, not vc-dist.
12287         Run $(MAKE) dist with XZ_OPT=-9ev.  Note spelling, with "-".
12288
12289 2009-08-27  Bruno Haible  <bruno@clisp.org>
12290
12291         * tests/test-bitrotate.c (main): Remove test that uses a shift count
12292         of 0.
12293
12294 2009-08-27  Bruno Haible  <bruno@clisp.org>
12295
12296         * tests/test-func.c (main): Don't verify sizeof __func__ on SunPRO C
12297         compilers.
12298         * doc/func.texi: Document the SunPRO C bug.
12299
12300 2009-08-27  Bruno Haible  <bruno@clisp.org>
12301
12302         Fix link error on Solaris.
12303         * tests/test-parse-duration.c (xstrdup): Remove function.
12304
12305 2009-08-26  Pádraig Brady  <P@draigbrady.com>
12306
12307         ignore-value: handle pointer types, too
12308         * lib/ignore-value.h (__attribute__): Remove definition.
12309         (ignore_value): Remove use of "__attribute__ ((unused))" in favor
12310         of a more concise and more-often effective "(void) i" statement.
12311         (ignore_ptr): New function to suppress warnings from functions that
12312         return pointers, and to make it explicit that one function doesn't
12313         handle all cases.
12314
12315 2009-08-25  Bruno Haible  <bruno@clisp.org>
12316
12317         dup2: work around a Linux bug.
12318         * m4/dup2.m4 (gl_FUNC_DUP2): Test for the Linux bug.
12319         * lib/dup2.c (rpl_dup2): Correct the return value if it is -EBADF.
12320         * doc/posix-functions/dup2.texi: Mention the Linux bug.
12321         Reported by Simon Josefsson.
12322
12323 2009-08-25  Jim Meyering  <meyering@redhat.com>
12324
12325         libguestfs uses gnulib
12326         * users.txt: Add libguestfs.
12327
12328 2009-08-24  Eric Blake  <ebb9@byu.net>
12329
12330         dup2, pipe2: fix some recent test failures on cygwin 1.5.x
12331         * lib/pipe2.c (includes): Add binary-io.h.
12332         * lib/dup2.c (rpl_dup2): Correct buggy errno value.
12333
12334 2009-08-24  Bruno Haible  <bruno@clisp.org>
12335
12336         Tolerate declared but missing accept4 syscall.
12337         * lib/accept4.c (accept4): Invoke original accept4 function first, if
12338         available.
12339         * lib/sys_socket.in.h (accept4): If the function is already present,
12340         override it.
12341         * m4/accept4.m4 (gl_FUNC_ACCEPT4): Remove AC_LIBOBJ invocation.
12342         * modules/accept4 (Makefile.am): Compile accept4.c always.
12343         Reported by Paolo Bonzini and Eric Blake.
12344
12345 2009-08-23  Bruno Haible  <bruno@clisp.org>
12346
12347         New module 'accept4'.
12348         * lib/sys_socket.in.h (accept4): New declaration.
12349         * lib/accept4.c: New file.
12350         * m4/accept4.m4: New file.
12351         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
12352         GNULIB_ACCEPT4, HAVE_ACCEPT4.
12353         * modules/sys_socket (Makefile.am): Substitute GNULIB_ACCEPT4,
12354         HAVE_ACCEPT4.
12355         * modules/accept4: New file.
12356         * doc/glibc-functions/accept4.texi: Mention the new module.
12357
12358 2009-08-24  Jim Meyering  <meyering@redhat.com>
12359
12360         progname: also set global program_invocation_name, when possible
12361         Before this change, a libtool-enabled program that calls glibc's
12362         error function would report the program name as
12363         "/abs/dir/.libs/lt-program_name" rather than the desired program_name.
12364         * modules/progname (configure.ac): Check for a declaration of
12365         program_invocation_name.
12366         * lib/progname.c:  Include <errno.h>.
12367         (set_program_name) [HAVE_DECL_PROGRAM_INVOCATION_NAME]:
12368         Set program_invocation_name.
12369
12370 2009-08-23  Bruno Haible  <bruno@clisp.org>
12371
12372         * lib/dup3.c: Include <string.h>.
12373
12374 2009-08-23  Bruno Haible  <bruno@clisp.org>
12375
12376         * lib/dup3.c (dup3): Test only once whether the system actually exists.
12377         * lib/pipe2.c (pipe2): Likewise.
12378         Suggested by Eric Blake.
12379
12380 2009-08-23  Bruno Haible  <bruno@clisp.org>
12381
12382         Tolerate declared but missing dup3 syscall.
12383         * lib/dup3.c (dup3): Invoke original dup3 function first, if available.
12384         * lib/unistd.in.h (dup3): If the function is already present,
12385         override it.
12386         * m4/dup3.m4 (gl_FUNC_DUP3): Remove AC_LIBOBJ invocation.
12387         * modules/dup3 (Makefile.am): Compile dup3.c always.
12388         Reported by Paolo Bonzini.
12389
12390 2009-08-23  Bruno Haible  <bruno@clisp.org>
12391
12392         Tolerate declared but missing pipe2 syscall.
12393         * lib/pipe2.c (pipe2): Invoke original pipe2 function first, if
12394         available.
12395         * lib/unistd.in.h (pipe2): If the function is already present,
12396         override it.
12397         * m4/pipe2.m4 (gl_FUNC_PIPE2): Remove AC_LIBOBJ invocation.
12398         * modules/pipe2 (Makefile.am): Compile pipe2.c always.
12399         Reported by Paolo Bonzini.
12400
12401 2009-08-23  Bruno Haible  <bruno@clisp.org>
12402
12403         * lib/pipe2.c (pipe2): Move #ifs inside function.
12404
12405 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
12406
12407         quotearg: document limitations of quote_these_too
12408         * lib/quotearg.c (quotearg_buffer_restyled): Add comments where
12409         those limitations are created.
12410         * lib/quotearg.h (set_char_quoting): Document that digits and
12411         letters that are special after backslash are not permitted.
12412         (quotearg_char): Cross-reference set_char_quoting documentation.
12413
12414 2009-08-23  Joel E. Denny  <jdenny@clemson.edu>
12415
12416         quotearg: implement custom_quoting_style
12417         * lib/quotearg.c: (struct quoting_options): Add left_quote and
12418         right_quote fields.
12419         (set_custom_quoting): New public function.
12420         (quotearg_buffer_restyled): Add left_quote and right_quote
12421         arguments, handle them very much like locale quoting, and update
12422         all uses.
12423         (quotearg_n_custom): New public function.
12424         (quotearg_n_custom_mem): New public function.
12425         (quotearg_custom): New public function.
12426         (quotearg_custom_mem): New public function.
12427         * lib/quotearg.h: Prototype and document new public functions.
12428         (enum quoting_style): For escape_quoting_style and
12429         clocale_quoting_style, comment that QA_SPLIT_TRIGRAPHS is
12430         ignored even though they're otherwise like c_quoting_style.
12431         Add custom_quoting_style member and document with comparison to
12432         clocale_quoting_style.
12433         * tests/test-quotearg.c (custom_quotes): New array.
12434         (custom_results): New array.
12435         (main): Extend to test custom quoting.
12436
12437 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
12438
12439         quotearg: fix right quote escaping when it's in quote_these_too
12440         * lib/quotearg.c (quotearg_buffer_restyled): Upon seeing a right
12441         quote, be sure to prepend only one backslash.
12442         * tests/test-quotearg.c (use_quote_double_quotes): New function.
12443         (main): Test it.
12444
12445 2009-08-22  Joel E. Denny  <jdenny@clemson.edu>
12446
12447         quotearg-tests: test escaping of embedded locale quotes
12448         * tests/test-quotearg.c (struct result_strings): Add member for
12449         new input.
12450         (LQ_ENC, RQ_ENC, RQ_ESC): New macros.
12451         (inputs): Add new input.
12452         (results_g): Add expected results.
12453         (flag_results): Likewise.
12454         (locale_results): Likewise.
12455         (compare_strings): Check those.
12456
12457 2009-08-23  Bruno Haible  <bruno@clisp.org>
12458
12459         Tests for module 'dup3'.
12460         * modules/dup3-tests: New file.
12461         * tests/test-dup3.c: New file.
12462
12463         New module 'dup3'.
12464         * lib/unistd.in.h (dup3): New declaration.
12465         * lib/dup3.c: New file.
12466         * m4/dup3.m4: New file.
12467         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_DUP3 and
12468         HAVE_DUP3.
12469         * modules/unistd (Makefile.am): Substitute GNULIB_DUP3 and HAVE_DUP3.
12470         * modules/dup3: New file.
12471         * doc/glibc-functions/dup3.texi: Mention the new module.
12472
12473 2009-08-23  Bruno Haible  <bruno@clisp.org>
12474
12475         Tweak the dup2 test.
12476         * tests/test-dup2.c (main): Create the test file empty. Verify that an
12477         out-of-range fd yields EBADF. Verify that after writing to /dev/null,
12478         the test file is still empty. Fix argument order of lseek.
12479
12480 2009-08-23  Bruno Haible  <bruno@clisp.org>
12481
12482         Avoid test link errors when the modules getopt-gnu, gettext are used.
12483         * modules/getopt-posix-tests (Makefile.am): Define test_getopt_LDADD.
12484         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
12485
12486 2009-08-23  Bruno Haible  <bruno@clisp.org>
12487
12488         Fix getdtablesize() on mingw.
12489         * lib/getdtablesize.c (getdtablesize): Implement differently.
12490         * lib/unistd.in.h (getdtablesize): Improve comment.
12491
12492 2009-08-23  Bruno Haible  <bruno@clisp.org>
12493
12494         New module 'mkostemp'.
12495         Based on Ulrich Drepper's 2007-08-10 change in glibc.
12496         * lib/stdlib.in.h (mksotemp): New declaration.
12497         * lib/mkostemp.c: New file, from glibc with modifications.
12498         * lib/tempname.h (GT_FILE): Remove outdated comment.
12499         (gen_tempname): Add flags argument.
12500         * lib/tempname.c (__GT_BIGFILE): Remove macro.
12501         (__GT_FILE): Map to 1.
12502         (small_open, large_open): Remove macros.
12503         (__gen_tempname): Add flags argument. Remove code for __GT_BIGFILE.
12504         * lib/mkstemp.c (mkstemp): Update.
12505         * lib/mkdtemp.c (mkdtemp): Likewise.
12506         * m4/mkostemp.m4: New file.
12507         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_MKOSTEMP,
12508         HAVE_MKOSTEMP.
12509         * modules/stdlib (Makefile.am): Substitute GNULIB_MKOSTEMP,
12510         HAVE_MKOSTEMP.
12511         * modules/mkostemp: New file, based on modules/mkstemp.
12512         * doc/glibc-functions/mkostemp.texi: Mention the new module.
12513         * NEWS: Mention the change.
12514
12515 2009-08-23  Bruno Haible  <bruno@clisp.org>
12516
12517         * lib/pipe2.c (pipe2): Support O_TEXT, O_BINARY on all platforms.
12518         Reported by Eric Blake.
12519
12520 2009-08-23  Bruno Haible  <bruno@clisp.org>
12521
12522         * lib/pipe2.c (pipe2): Fix test of fcntl's return value.
12523         Reported by Eric Blake.
12524
12525 2009-08-23  Bruno Haible  <bruno@clisp.org>
12526
12527         * modules/fchdir (Depends-on): Use fcntl-h instead of fcntl.
12528         * modules/pipe2 (Depends-on): Likewise.
12529
12530 2009-08-23  Eric Blake  <ebb9@byu.net>
12531
12532         fcntl-h: add O_TTY_INIT support
12533         * lib/fcntl.in.h (O_TTY_INIT): Support another POSIX macro.
12534         * tests/test-fcntl-h.c (o): Test it.
12535         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
12536
12537         fcntl-h: rename from fcntl, in preparation for fcntl(2)
12538         * modules/fcntl: Move <fcntl.h> header replacement...
12539         * modules/fcntl-h: ...to new name, so as not to collide with
12540         like-named function.
12541         * tests/test-fcntl.c: Rename...
12542         * tests/test-fcntl-h.c: ...to this.  Test FD_CLOEXEC.
12543         * modules/fcntl-tests: Rename...
12544         * modules/fcntl-h-tests: ...to this.  Update test file name.
12545         * modules/chdir-long (Depends-on): Update clients.
12546         * modules/chdir-safer (Depends-on): Likewise.
12547         * modules/fcntl-safer (Depends-on): Likewise.
12548         * modules/fts (Depends-on): Likewise.
12549         * modules/mkancesdirs (Depends-on): Likewise.
12550         * modules/mkdir-p (Depends-on): Likewise.
12551         * modules/open (Depends-on): Likewise.
12552         * modules/savewd (Depends-on): Likewise.
12553         * MODULES.html.sh (systems lacking POSIX:2008): Update name.
12554         * doc/posix-headers/fcntl.texi (fcntl.h): Update documentation.
12555
12556 2009-08-22  Bruno Haible  <bruno@clisp.org>
12557
12558         * modules/binary-io (License): Relicense under LGPL.
12559         * modules/pipe2 (License): Likewise.
12560
12561 2009-08-22  Bruno Haible  <bruno@clisp.org>
12562
12563         * lib/pipe-filter-ii.c (pipe_filter_ii_execute): Fix test of fcntl's
12564         return value.
12565         * lib/pipe-filter-gi.c (filter_init): Likewise.
12566         Reported by Eric Blake.
12567
12568 2009-08-22  Bruno Haible  <bruno@clisp.org>
12569
12570         * lib/pipe.c (create_pipe): Use pipe2 instead of _pipe.
12571         * modules/pipe (Depends-on): Add pipe2.
12572
12573 2009-08-22  Bruno Haible  <bruno@clisp.org>
12574
12575         Tests for module 'pipe2'.
12576         * modules/pipe2-tests: New file.
12577         * tests/test-pipe2.c: New file.
12578
12579         New module 'pipe2'.
12580         * lib/unistd.in.h (pipe2): New declaration.
12581         * lib/pipe2.c: New file.
12582         * m4/pipe2.m4: New file.
12583         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_PIPE2 and
12584         HAVE_PIPE2.
12585         * modules/unistd (Makefile.am): Substitute GNULIB_PIPE2 and HAVE_PIPE2.
12586         * modules/pipe2: New file.
12587         * doc/glibc-functions/pipe2.texi: Mention the new module.
12588
12589 2009-08-22  Bruno Haible  <bruno@clisp.org>
12590
12591         Reference some new glibc functions.
12592         * doc/glibc-functions/accept4.texi: New file.
12593         * doc/glibc-functions/dup3.texi: New file.
12594         * doc/glibc-functions/mkostemp.texi: New file.
12595         * doc/glibc-functions/pipe2.texi: New file.
12596         * doc/gnulib.texi (Glibc stdlib.h): Refer to mkostemp.
12597         (Glibc sys/socket.h): Refer to accept4.
12598         (Glibc unistd.h): Refer to dup3, pipe2.
12599         Reported by Eric Blake.
12600
12601 2009-08-22  Jim Meyering  <meyering@redhat.com>
12602             Bruno Haible  <bruno@clisp.org>
12603
12604         annotate automake snippets with $(AM_V_GEN) and $(AM_V_at)
12605         This makes it so packages using automake-1.11's silent-rules option
12606         can print e.g., a single "GEN    configmake.h" line, rather than
12607         the 30+ statements that perform the job.  If you want to see the
12608         actual commands, you can still run "make V=1".
12609         * modules/alloca-opt: Add $(AM_V_GEN) and $(AM_V_at) prefixes
12610         so that make output is abbreviated when those variables are defined
12611         appropriately.
12612         * modules/argz: Likewise.
12613         * modules/arpa_inet: Likewise.
12614         * modules/byteswap: Likewise.
12615         * modules/configmake: Likewise.
12616         * modules/dirent: Likewise.
12617         * modules/errno: Likewise.
12618         * modules/fcntl: Likewise.
12619         * modules/float: Likewise.
12620         * modules/fnmatch: Likewise.
12621         * modules/getopt-posix: Likewise.
12622         * modules/glob: Likewise.
12623         * modules/iconv_open: Likewise.
12624         * modules/inttypes: Likewise.
12625         * modules/localcharset: Likewise.
12626         * modules/locale: Likewise.
12627         * modules/math: Likewise.
12628         * modules/netdb: Likewise.
12629         * modules/netinet_in: Likewise.
12630         * modules/poll: Likewise.
12631         * modules/posix_spawnp-tests: Likewise.
12632         * modules/sched: Likewise.
12633         * modules/search: Likewise.
12634         * modules/selinux-h: Likewise.
12635         * modules/signal: Likewise.
12636         * modules/spawn: Likewise.
12637         * modules/stdarg: Likewise.
12638         * modules/stdbool: Likewise.
12639         * modules/stddef: Likewise.
12640         * modules/stdint: Likewise.
12641         * modules/stdio: Likewise.
12642         * modules/stdlib: Likewise.
12643         * modules/string: Likewise.
12644         * modules/strings: Likewise.
12645         * modules/sys_file: Likewise.
12646         * modules/sys_ioctl: Likewise.
12647         * modules/sys_select: Likewise.
12648         * modules/sys_socket: Likewise.
12649         * modules/sys_stat: Likewise.
12650         * modules/sys_time: Likewise.
12651         * modules/sys_times: Likewise.
12652         * modules/sys_utsname: Likewise.
12653         * modules/sys_wait: Likewise.
12654         * modules/sysexits: Likewise.
12655         * modules/time: Likewise.
12656         * modules/unistd: Likewise.
12657         * modules/wchar: Likewise.
12658         * modules/wctype: Likewise.
12659
12660 2009-08-22  Jim Meyering  <meyering@redhat.com>
12661
12662         announce-gen: detect write failure
12663         * build-aux/announce-gen: Add Coda at end.
12664         Remove equivalent-but-more-verbose block at top.
12665
12666 2009-08-19  Akim Demaille  <demaille@gostai.com>
12667
12668         bootstrap: --help to stdout.
12669         * bootstrap (usage): Don't send --help to stderr.
12670         Use a here doc instead of a long string.
12671
12672 2009-08-21  Eric Blake  <ebb9@byu.net>
12673
12674         test-popen-safer: split from test-popen
12675         * tests/test-popen.c (main): Move...
12676         * tests/test-popen.h: ...into new file.
12677         * tests/test-popen-safer2.c: New file.
12678         * modules/popen-tests (Files): Add test-popen.h.
12679         * modules/popen-safer-tests (Files): Add test-popen-safer2.c.
12680         Suggested by Bruno Haible.
12681
12682         test-fcntl-safer: split from test-open
12683         * tests/test-open.c (main): Move...
12684         * tests/test-open.h: ...into new file.
12685         * tests/test-fcntl-safer.c: New file.
12686         * modules/open-tests (Files): Add test-open.h.
12687         * modules/fcntl-safer-tests: New file.
12688         Suggested by Bruno Haible.
12689
12690         test-fopen-safer: split from test-fopen
12691         * tests/test-fopen.c (main): Move...
12692         * tests/test-fopen.h: ...into new file.
12693         * tests/test-fopen-safer.c: New file.
12694         * modules/fopen-tests (Files): Add test-fopen.h.
12695         * modules/fopen-safer-tests: New file.
12696         Suggested by Bruno Haible.
12697
12698 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
12699
12700         popen-safer: test O_CLOEXEC at run-time.
12701         * lib/popen-safer.c: Test O_CLOEXEC at run-time.
12702
12703 2009-08-21  Paolo Bonzini  <bonzini@gnu.org>
12704
12705         fcntl: move more flags to the header
12706         * lib/cloexec.c: Do not define FD_CLOEXEC here.
12707         * lib/popen-safer.c: Do not alias O_NOINHERIT to O_CLOEXEC here.
12708         * lib/fcntl.in.h: Do both things here.
12709
12710 2009-08-21  Jim Meyering  <meyering@redhat.com>
12711
12712         consistently remove $@-t before redirecting to it
12713         * modules/argz: Remove $@-t and $@ before redirecting to the former.
12714         * modules/alloca-opt: Likewise.
12715         * modules/byteswap: Likewise.
12716         * modules/fnmatch: Likewise.
12717         * modules/getopt-posix: Likewise.
12718         * modules/glob: Likewise.
12719         * modules/poll: Likewise.
12720         * modules/posix_spawnp-tests: Likewise.
12721         * modules/sys_socket: Likewise.
12722         * modules/sysexits: Likewise.
12723
12724 2009-08-21  Eric Blake  <ebb9@byu.net>
12725
12726         popen: simplify access to original popen
12727         * lib/popen.c (rpl_popen): No need to worry about popen being a
12728         macro.
12729         Reported by Bruno Haible.
12730
12731 2009-08-20  Eric Blake  <ebb9@byu.net>
12732
12733         build: avoid some compiler warnings
12734         * lib/selinux-at.h: Use dir_fd, not dirfd, to avoid shadowing.
12735         * lib/exclude.c (fnmatch_pattern_has_wildcards): Use correct
12736         type.
12737         (new_exclude_segment, excluded_file_pattern_p)
12738         (excluded_file_name_p): Reduce scope.
12739         * lib/vasnprintf.c (decimal_point_char): Avoid warning on
12740         old-style declaration.
12741
12742 2009-08-20  Simon Josefsson  <simon@josefsson.org>
12743
12744         * tests/test-exclude1.sh: Handle Windows EOL.
12745         * tests/test-exclude2.sh: Likewise.
12746         * tests/test-exclude3.sh: Likewise.
12747         * tests/test-exclude4.sh: Likewise.
12748         * tests/test-exclude5.sh: Likewise.
12749         * tests/test-exclude6.sh: Likewise.
12750         * tests/test-exclude7.sh: Likewise.
12751
12752 2009-08-19  Akim Demaille  <demaille@gostai.com>
12753
12754         bootstrap: find sha1sum when named gsha1sum.
12755         * bootstrap (find_tool): New.
12756         ($SHA1SUM): New.
12757         Use it.
12758
12759 2009-08-20  Jim Meyering  <meyering@redhat.com>
12760
12761         maint.mk: _header_without_use: fix a quoting bug and remove a bash'ism
12762         * top/maint.mk (_header_without_use): Use "\\\\", not "\\" in the sed
12763         expression that converts "." in a file name to "\." in the resulting
12764         regexp.  Start with a dummy statement, so that prior shell variable
12765         definitions are expanded portably.  Reported by Simon Josefsson.
12766
12767 2009-08-20  Paolo Bonzini  <bonzini@gnu.org>
12768
12769         Fix polling for writeability of a screen buffer.
12770         * lib/poll.c: Distinguish input and screen buffers for the
12771         Win32 implementation.
12772         * lib/select.c: Likewise.
12773
12774 2009-08-19  Eric Blake  <ebb9@byu.net>
12775
12776         popen-safer: prevent popen from clobbering std descriptors
12777         * modules/popen-safer: New file.
12778         * lib/popen-safer.c: Likewise.
12779         * m4/stdio-safer.m4 (gl_POPEN_SAFER): New macro.
12780         * lib/stdio--.h (popen): Provide override.
12781         * lib/stdio-safer.h (popen_safer): Provide declaration.
12782         * tests/test-popen.c (includes): Partially test this.
12783         * modules/popen-safer-tests: New file, for more tests.
12784         * tests/test-popen-safer.c: Likewise.
12785         * MODULES.html.sh (file stream based Input/Output): Mention it.
12786
12787         tests: test some of the *-safer modules
12788         * modules/fopen-safer (Depends-on): Add fopen.
12789         * modules/fcntl-safer (Depends-on): Add fcntl.
12790         * modules/stdlib-safer (Depends-on): Add stdlib.
12791         (configure.ac): Set indicator.
12792         * modules/unistd-safer (configure.ac): Likewise.
12793         * modules/tmpfile-safer (configure.ac): Likewise.
12794         (Depends-on): Add tmpfile.
12795         * lib/stdio--.h (fopen, tmpfile): Don't override unless module is
12796         active.
12797         * tests/test-fopen.c (includes): Test safer versions when they are
12798         in use.
12799         * tests/test-open.c (includes): Likewise.
12800
12801         popen: fix cygwin 1.5 bug when stdin closed
12802         * doc/posix-functions/popen.texi (popen): Document cygwin bugs.
12803         * modules/popen: New file.
12804         * modules/popen-tests: Likewise.
12805         * tests/test-popen.c: Likewise.
12806         * m4/popen.m4: Likewise.
12807         * lib/popen.c: Likewise.
12808         * lib/stdio.in.h (popen): New declaration.
12809         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add popen.
12810         * modules/stdio (Makefile.am): Likewise.
12811         * MODULES.html.sh (systems lacking POSIX:2008): Mention it.
12812
12813 2009-08-17  Joel E. Denny  <jdenny@clemson.edu>
12814
12815         maint.mk: give full control over update-copyright exclusions
12816         * top/maint.mk (VC_LIST_EXCEPT): Instead of ChangeLog, use
12817         ${VC_LIST_EXCEPT_DEFAULT-ChangeLog} as the default exclusion.
12818         (update-copyright): Don't force inclusion of top-level
12819         ChangeLog.  Don't force exclusion of all COPYING files, but make
12820         them the default exclusion instead.
12821
12822 2009-08-16  Bruno Haible  <bruno@clisp.org>
12823
12824         Fix test failures on Solaris 10.
12825         * tests/uniconv/test-u8-conv-from-enc.c (main): Disable autodetect_jp
12826         tests when Solaris iconv() is used.
12827         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
12828         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
12829         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
12830         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
12831         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
12832
12833 2009-08-16  Bruno Haible  <bruno@clisp.org>
12834
12835         Fix test failures on Solaris 10.
12836         * tests/test-pipe-filter-ii1.sh: Determine the filename of a working
12837         'tr' program and pass it as first argument.
12838         * tests/test-pipe-filter-gi1.sh: Likewise.
12839         * tests/test-pipe-filter-ii1.c (main): Except the filename of a 'tr'
12840         program as first argument.
12841         * tests/test-pipe-filter-gi1.c (main): Likewise.
12842
12843 2009-08-16  Eric Blake  <ebb9@byu.net>
12844
12845         fpurge: fix previous commits
12846         * modules/fpurge (Makefile.am): Make replacement conditional,
12847         partially reverting 2007-04-29 change; missed in previous
12848         attempt.
12849         * m4/fpurge.m4 (gl_FUNC_FPURGE): Also compile fpurge.c when fpurge
12850         is missing.
12851
12852 2009-08-16  Bruno Haible  <bruno@clisp.org>
12853
12854         Clarify fpurge's effect on the file position.
12855         * lib/stdio.in.h (fpurge): Specify the file position after fpurge.
12856         * tests/test-fpurge.c (main): Make a second pass for checking the file
12857         position.
12858
12859 2009-08-16  Bruno Haible  <bruno@clisp.org>
12860
12861         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't compile fpurge.c if only the
12862         declaration of fpurge is missing.
12863         * tests/test-fpurge.c (main): Check that the file has not more contents
12864         than expected. Close the file before removing it.
12865
12866 2009-08-15  Eric Blake  <ebb9@byu.net>
12867
12868         fpurge: don't wrap working cygwin implementation
12869         * lib/fpurge.c (fpurge): Fix comment typo.
12870         * m4/fpurge.m4 (gl_FUNC_FPURGE): Detect BSD bug, allowing cygwin
12871         1.7 to avoid replacement.
12872         * tests/test-fpurge.c (main): Enhance test.
12873
12874 2009-08-15  Eric Blake  <ebb9@byu.net>
12875         and Jim Meyering  <meyering@redhat.com>
12876
12877         test-update-copyright: skip if perl is insufficient
12878         * tests/test-update-copyright.sh: Failure to run maintainer tool
12879         should not cause testsuite failure on cygwin 1.5.
12880
12881 2009-08-14  Eric Blake  <ebb9@byu.net>
12882
12883         doc: mention more functions added in cygwin 1.7.0
12884         * doc/posix-headers/limits.texi (limits.h): Update for recent
12885         cygwin additions.
12886         * doc/posix-headers/wordexp.texi (wordexp.h): Likewise.
12887         * doc/posix-functions/wordexp.texi (wordexp): Likewise.
12888         * doc/posix-functions/wordfree.texi (wordfree): Likewise.
12889         * doc/posix-functions/setlocale.texi (setlocale): Likewise.
12890         * doc/posix-functions/nl_langinfo.texi (nl_langinfo): Likewise.
12891
12892 2009-08-14  Eric Blake  <ebb9@byu.net>
12893
12894         maint.mk: simplify update-copyright rule
12895         * top/maint.mk (update-copyright-local): Delete, and document how
12896         to do it in cfg.mk instead.
12897         (update-copyright-exclude-regexp): Delete, and document how to do
12898         it in .x-update-copyright instead.
12899         (update-copyright): Simplify, thanks to VC_LIST_EXCEPT.  Don't
12900         exclude ChangeLog.
12901
12902 2009-08-14  Bruno Haible  <bruno@clisp.org>
12903
12904         * m4/wchar.m4 (gl_WCHAR_H): Undo invalid optimization in last commit.
12905
12906 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
12907
12908         maint.mk: support update-copyright-env
12909         * top/maint.mk (update-copyright-env): Define place-holder.
12910         (update-copyright): Expand $(update-copyright-env) before
12911         invoking update-copyright.
12912
12913 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
12914
12915         update-copyright: implement forced reformatting
12916         * build-aux/update-copyright: Implement and document
12917         UPDATE_COPYRIGHT_FORCE.
12918         * tests/test-update-copyright.sh: Test it.
12919
12920 2009-08-14  Eric Blake  <ebb9@byu.net>
12921         and Bruno Haible  <bruno@clisp.org>
12922
12923         stddef: fix NetBSD 5.0 NULL bug, rather than working around it
12924         * tests/test-locale.c: Revert previous patch related to NULL.
12925         * tests/test-stdio.c: Likewise.
12926         * tests/test-stdlib.c: Likewise.
12927         * tests/test-string.c: Likewise.
12928         * tests/test-unistd.c: Likewise.
12929         * modules/time-tests (Depends-on): Add verify.
12930         * modules/wchar-tests (Depends-on): Likewise.
12931         * tests/test-time.c: Test for NULL compliance.
12932         * tests/test-wchar.c: Likewise.
12933         * modules/locale (Depends-on): Add stddef.
12934         * modules/stdio (Depends-on): Likewise.
12935         * modules/stdlib (Depends-on): Likewise.
12936         * modules/string (Depends-on): Likewise.
12937         * modules/time (Depends-on): Likewise.
12938         * modules/unistd (Depends-on): Likewise.
12939         * modules/wchar (Depends-on): Likewise.
12940         * lib/locale.in.h (includes): Use <stddef.h> to fix NULL.
12941         * lib/stdlib.in.h (includes): Likewise.
12942         * lib/string.in.h (includes): Likewise.
12943         * lib/time.in.h (includes): Likewise.
12944         * lib/unistd.in.h (includes): Likewise.
12945         * m4/locale_h.m4 (gl_LOCALE_H): Replace locale.h if stddef.h was
12946         replaced.
12947         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
12948         * m4/stddef_h.m4: New file.
12949         * modules/stddef: Likewise.
12950         * lib/stddef.in.h: Likewise.
12951         * modules/stddef-tests: Likewise.
12952         * tests/test-stddef.c: Likewise.
12953         * MODULES.html.sh (Basic types <stddef.h>): Mention new module.
12954         * doc/posix-headers/stddef.texi (stddef.h): Document the bug.
12955         * doc/posix-headers/locale.texi (locale.h): Likewise.
12956         * doc/posix-headers/stdio.texi (stdio.h): Likewise.
12957         * doc/posix-headers/stdlib.texi (stdlib.h): Likewise.
12958         * doc/posix-headers/string.texi (string.h): Likewise.
12959         * doc/posix-headers/time.texi (time.h): Likewise.
12960         * doc/posix-headers/unistd.texi (unistd.h): Likewise.
12961         * doc/posix-headers/wchar.texi (wchar.h): Likewise.
12962
12963 2009-08-14  Eric Blake  <ebb9@byu.net>
12964
12965         doc: improve git diff of texinfo files
12966         * .gitattributes: Add rule for *.texi files, with hint on how to
12967         use it.
12968         Copied from m4, and based on a report by Bruno Haible.
12969
12970 2009-08-14  Bruno Haible  <bruno@clisp.org>
12971
12972         Disable multithread support by default on Cygwin 1.5.x for real.
12973         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): Fix last commit.
12974
12975 2009-08-14  Joel E. Denny  <jdenny@clemson.edu>
12976
12977         update-copyright: much ado about intervals
12978         * build-aux/update-copyright: Implement and document
12979         UPDATE_COPYRIGHT_USE_INTERVALS to control expansion and collapse
12980         of copyright year intervals.
12981         Also, document UPDATE_COPYRIGHT_YEAR.
12982         * tests/test-update-copyright.sh: Test it.
12983
12984         update-copyright: convert 2-digit to 4-digit years
12985         * build-aux/update-copyright: Implement and document.
12986         * tests/test-update-copyright.sh: Update.
12987
12988 2009-08-14  Jim Meyering  <meyering@redhat.com>
12989
12990         test-exclude: avoid coreutils "make check" failure
12991         * tests/test-exclude.c (ARGMATCH_DIE_DECL) [ARGMATCH_DIE_DECL]: Define,
12992         just as in test-argmatch.c.
12993
12994 2009-08-13  Eric Blake  <ebb9@byu.net>
12995
12996         test-dup2: fix bad assumption
12997         * tests/test-dup2.c (main): Tolerate leaked fds from environment.
12998         Reported by Peter Breitenlohner <peb@mppmu.mpg.de>.
12999
13000         test-version-etc: fix CRLF portability issue
13001         * tests/test-version-etc.sh: Use tr, not sed, as not all sed
13002         recognize \r.
13003         * tests/test-argp-version-etc-1.sh: Likewise.
13004
13005         getopt: update client modules
13006         * modules/argp (Depends-on): Use getopt-gnu.
13007         * modules/git-merge-changelog (Depends-on): Likewise.
13008         * modules/long-options (Depends-on): Likewise.
13009         * modules/xstrtol (Depends-on): Likewise.
13010
13011 2009-08-13  Simon Josefsson  <simon@josefsson.org>
13012
13013         * tests/test-version-etc.sh: Don't fail on different
13014         project/version.  Don't fail on CRLF differences.  Rewrite to use
13015         multiple -e instead of multiple sed forks, suggested by Eric Blake
13016         <ebb9@byu.net>.
13017         * tests/test-argp-version-etc-1.sh: Likewise.
13018
13019 2009-08-13  Simon Josefsson  <simon@josefsson.org>
13020
13021         * tests/test-version-etc.sh: Don't fail on different
13022         project/version.
13023
13024 2009-08-12  Bruno Haible  <bruno@clisp.org>
13025
13026         Tests for modules 'getopt-posix', 'getopt-gnu'.
13027         * modules/getopt-posix-tests: New file.
13028         * tests/test-getopt.c: New file.
13029         * tests/test-getopt.h: New file.
13030         * tests/test-getopt_long.h: New file.
13031
13032         New modules 'getopt-posix', 'getopt-gnu'.
13033         * modules/getopt-gnu: New file, renamed from modules/getopt.
13034         * modules/getopt-posix: New file.
13035         * modules/getopt: Turn into an obsolete alias for getopt-gnu.
13036         * m4/getopt.m4 (gl_FUNC_GETOPT_POSIX, gl_FUNC_GETOPT_GNU): New macros.
13037         (gl_GETOPT): Remove macro.
13038         (gl_GETOPT_CHECK_HEADERS): Do some checks only for gl_FUNC_GETOPT_GNU.
13039         Disable the test against BSD systems that declare optreset. Test
13040         against mingw bug. Test against lack of support of optional arguments
13041         on many platforms.
13042         * doc/glibc-headers/getopt.texi: Update module name and list of
13043         relevant platforms.
13044         * doc/posix-functions/getopt.texi: Mention modules 'getopt-posix' and
13045         'getopt-gnu' and more portability problems.
13046         * NEWS: Mention the changes.
13047
13048 2009-08-12  Bruno Haible  <bruno@clisp.org>
13049
13050         Ensure that optarg etc. get declared by <unistd.h>.
13051         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Require
13052         AC_USE_SYSTEM_EXTENSIONS.
13053         * modules/getopt (Depends-on): Add 'extensions'.
13054
13055 2009-08-12  Bruno Haible  <bruno@clisp.org>
13056
13057         Avoid test link errors.
13058         * modules/pipe-filter-ii-tests (Makefile.am): Define
13059         test_pipe_filter_ii1_LDADD and test_pipe_filter_ii2_main_LDADD.
13060         * modules/pipe-filter-gi-tests (Makefile.am): Define
13061         test_pipe_filter_gi1_LDADD and test_pipe_filter_gi2_main_LDADD.
13062         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
13063
13064 2009-08-12  Bruno Haible  <bruno@clisp.org>
13065
13066         * m4/getopt.m4 (gl_REPLACE_GETOPT): New macro, was called
13067         gl_GETOPT_SUBSTITUTE before.
13068         (gl_GETOPT): Use it.
13069         * m4/argp.m4 (gl_ARGP): Update.
13070         Reported by Sergey Poznyakoff.
13071
13072         * m4/getopt.m4: Reorder macros.
13073         (gl_GETOPT): Inline gl_GETOPT_SUBSTITUTE.
13074         (gl_GETOPT_SUBSTITUTE): Remove macro.
13075
13076 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
13077
13078         Minor improvement in gitlog-to-changelog
13079
13080         * build-aux/gitlog-to-changelog: New option `--format' makes
13081         output format string configurable.
13082
13083 2009-08-12  Sergey Poznyakoff  <gray@gnu.org.ua>
13084
13085         Optimize exclude: use hash tables for non-wildcard patterns.
13086
13087         * lib/exclude.c: Include hash.h and mbuiter.h
13088         (struct exclude_pattern, exclude_segment): New data types.
13089         (struct exclude): Rewrite.
13090         (fnmatch_pattern_has_wildcards): New function.
13091         (new_exclude_segment, free_exclude_segment): New functions.
13092         (excluded_file_pattern_p, excluded_file_name_p): New functions.
13093         (excluded_file_name, add_exclude): Rewrite using new struct exclude.
13094         * lib/exclude.h (is_fnmatch_pattern): New prototype.
13095         * modules/exclude: Depend on hash and mbuiter.
13096
13097         * modules/exclude-tests: New file.
13098         * tests/test-exclude.c: New file.
13099         * tests/test-exclude1.sh: New file.
13100         * tests/test-exclude2.sh: New file.
13101         * tests/test-exclude3.sh: New file.
13102         * tests/test-exclude4.sh: New file.
13103         * tests/test-exclude5.sh: New file.
13104         * tests/test-exclude6.sh: New file.
13105         * tests/test-exclude7.sh: New file.
13106
13107 2009-08-12  Bruno Haible  <bruno@clisp.org>
13108
13109         Ensure that getopt() gets declared by <unistd.h>.
13110         * lib/unistd.in.h: Conditionally include getopt.h.
13111         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Require gl_UNISTD_H_DEFAULTS.
13112         Set GNULIB_UNISTD_H_GETOPT.
13113         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
13114         GNULIB_UNISTD_H_GETOPT.
13115         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_GETOPT.
13116
13117 2009-08-12  Bruno Haible  <bruno@clisp.org>
13118
13119         Clarify logic.
13120         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS, gl_GETOPT_IFELSE): Use
13121         gl_replace_getopt instead of GETOPT_H.
13122
13123 2009-08-12  Bruno Haible  <bruno@clisp.org>
13124
13125         * m4/getopt.m4: Add comments.
13126
13127 2009-08-12  Bruno Haible  <bruno@clisp.org>
13128
13129         Disable multithread support by default on Cygwin 1.5.x.
13130         * m4/threadlib.m4 (gl_THREADLIB_EARLY_BODY): On Cygwin 1.5.x and older,
13131         set gl_use_threads=no if not specified otherwise.
13132
13133 2009-08-11  Bruno Haible  <bruno@clisp.org>
13134
13135         Avoid compilation error on NetBSD 5.0.
13136         * tests/test-locale.c: Write sizeof (NULL) instead of sizeof NULL.
13137         * tests/test-stdio.c: Likewise.
13138         * tests/test-stdlib.c: Likewise.
13139         * tests/test-string.c: Likewise.
13140         * tests/test-unistd.c: Likewise.
13141         Reported by Greg Troxel <gdt@ir.bbn.com>
13142         at <https://savannah.gnu.org/support/?106973>.
13143
13144 2009-08-11  Bruno Haible  <bruno@clisp.org>
13145
13146         * modules/dup2-tests (Depends-on): Remove close.
13147
13148         Undo 2009-07-19 commit.
13149         * modules/acl-tests (Depends-on): Remove close.
13150         * modules/binary-io-tests (Depends-on): Likewise.
13151         * modules/closein-tests (Depends-on): Likewise.
13152         * modules/flock-tests (Depends-on): Likewise.
13153         * modules/fsync-tests (Depends-on): Likewise.
13154         * modules/lseek-tests (Depends-on): Likewise.
13155         * modules/pipe-tests (Depends-on): Likewise.
13156         * modules/posix_spawn-tests (Depends-on): Likewise.
13157         * modules/posix_spawnp-tests (Depends-on): Likewise.
13158         * modules/stat-time-tests (Depends-on): Likewise.
13159         * modules/yesno-tests (Depends-on): Likewise.
13160
13161 2009-08-10  Bruno Haible  <bruno@clisp.org>
13162
13163         * lib/vasnprintf.c (DCHAR_SET): Undefine at the end.
13164
13165 2009-08-10  Bruno Haible  <bruno@clisp.org>
13166
13167         Fix a gcc warning.
13168         * lib/write.c (rpl_write): Cast result of _get_osfhandle.
13169
13170 2009-08-10  Bruno Haible  <bruno@clisp.org>
13171
13172         Don't optimize AC_LIBOBJs, as they may appear in different contexts.
13173         * m4/close.m4 (gl_REPLACE_CLOSE): Execute AC_LIBOBJ unconditionally,
13174         not only the first time.
13175         * m4/fclose.m4 (gl_REPLACE_FCLOSE): Likewise.
13176         * m4/open.m4 (gl_REPLACE_OPEN): Likewise.
13177         * m4/strstr.m4 (gl_FUNC_STRSTR): Execute AC_LIBOBJ when REPLACE_STRSTR
13178         is 1, not only the the first time.
13179
13180 2009-08-10  Bruno Haible  <bruno@clisp.org>
13181
13182         Make it possible to use module 'gethostname' without module 'close'.
13183         * lib/unistd.in.h (close): Evoke a link error only if
13184         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
13185         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
13186         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
13187         * modules/unistd (Makefile.am): Substitute
13188         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
13189         * lib/sys_ioctl.in.h (ioctl): Evoke a link error only if
13190         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS is set.
13191         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Initialize
13192         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
13193         * modules/sys_ioctl (Makefile.am): Substitute
13194         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
13195         * modules/socket (configure.ac): On native Windows, set
13196         UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS and
13197         SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS.
13198         Reported by Sam Steingold <sds@gnu.org>.
13199
13200 2009-08-10  Bruno Haible  <bruno@clisp.org>
13201
13202         * m4/close.m4 (gl_FUNC_CLOSE): Add comment.
13203         * modules/ioctl (configure.ac): Likewise.
13204
13205 2009-08-10  Bruno Haible  <bruno@clisp.org>
13206
13207         Avoid collision between gnulib wrapper and libintl wrapper.
13208         * lib/stdio-write.c (printf): Don't define if a printf wrapper is
13209         already defined in intl/printf.c.
13210         (vprintf): Test REPLACE_VPRINTF_POSIX, not REPLACE_VFPRINTF_POSIX.
13211         (vfprintf): Test REPLACE_VFPRINTF_POSIX, not REPLACE_VPRINTF_POSIX.
13212
13213 2009-08-09  Bruno Haible  <bruno@clisp.org>
13214
13215         Make <sys/select.h> really self-contained, also on Solaris 10.
13216         * lib/sys_select.in.h: Include <string.h>.
13217         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Test also against
13218         Solaris 10 problem.
13219         * tests/test-sys_select.c (main): Add check that FD_ZERO can be used.
13220         * doc/posix-headers/sys_select.texi: Mention the Solaris 10 problem.
13221         Reported by Jim Meyering.
13222
13223 2009-08-09  Bruno Haible  <bruno@clisp.org>
13224
13225         Avoid warnings from 'aclocal' that are due to a use of macro name
13226         AM_XGETTEXT_OPTION that is not defined in automake.
13227         * modules/argp (configure.ac): Hide use of AM_XGETTEXT_OPTION from
13228         automake.
13229         * modules/error (configure.ac): Likewise.
13230         * modules/propername (configure.ac): Likewise.
13231         * modules/vasprintf (configure.ac): Likewise.
13232         * modules/verror (configure.ac): Likewise.
13233         * modules/xprintf (configure.ac): Likewise.
13234         * modules/xvasprintf (configure.ac): Likewise.
13235
13236 2009-08-08  Bruno Haible  <bruno@clisp.org>
13237
13238         Avoid compilation error in C++ mode.
13239         * lib/gettimeofday.c (rpl_gettimeofday): Cast timezone argument.
13240         Reported by Sam Steingold <sds@gnu.org>.
13241
13242 2009-08-08  Bruno Haible  <bruno@clisp.org>
13243
13244         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Define HOST_NAME_MAX also
13245         for the various Unix platforms.
13246         * doc/posix-headers/limits.texi: Update platforms list regarding
13247         HOST_NAME_MAX.
13248         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
13249
13250 2009-08-07  Jim Meyering  <meyering@redhat.com>
13251
13252         selinux-at: fix typo in a comment
13253         * lib/selinux-at.h: s/getfileconat/getfilecon/ in a comment.
13254         Spotted by Paolo Bonzini.
13255
13256         selinux-at: remove redundant m4 code, add documentation
13257         * modules/selinux-at (configure.ac): Remove redundant code.
13258         LIB_SELINUX is already set via the dependent module, selinux-h.
13259         (Include): Add quotes around selinux-at.h.
13260         * lib/selinux-at.h: Add documentation.
13261         Reported by Bruno Haible in
13262         http://marc.info/?l=gnulib-bug&m=124958988300749
13263
13264 2009-08-07  Bruno Haible  <bruno@clisp.org>
13265
13266         Avoid link error on MacOS X 10.3 and 10.4.
13267         * lib/argp-ba.c (argp_program_bug_address): Explicitly zero-initialize
13268         on non-ELF systems.
13269         * lib/argp-pv.c (argp_program_version): Likewise.
13270         Reported by Simon Josefsson.
13271
13272 2009-08-07  Simon Josefsson  <simon@josefsson.org>
13273
13274         * tests/test-version-etc.sh: Use $EXEEXT.
13275
13276 2009-08-06  Joel E. Denny  <jdenny@clemson.edu>
13277
13278         update-copyright: update documentation to point to maint.mk
13279         * build-aux/update-copyright: Here.
13280
13281 2009-08-06  Jim Meyering  <meyering@redhat.com>
13282
13283         maint.mk: support update-copyright-local
13284         * top/maint.mk (update-copyright-local): Define place-holder.
13285         (update-copyright): Depend on $(update-copyright-local).
13286
13287 2009-08-06  Jim Meyering  <meyering@redhat.com>
13288
13289         selinux-at: new module
13290         Initially written for coreutils, this module will soon be
13291         used by findutils, too.
13292         * MODULES.html.sh [Misc]: Add selinux-at.
13293         * lib/selinux-at.h: New file, from coreutils.
13294         * lib/selinux-at.c: Likewise.
13295         * modules/selinux-at: Likewise.
13296         (License): Change from LGPL to GPL, since it depends
13297         on the GPL'd openat module.
13298
13299         doc: update README
13300         * README: Remove references to cogito.
13301         Remove cvs-repo-updating instructions from 2007.
13302         Don't imply that CVS is better if you have limited disk space.
13303
13304 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
13305
13306         update-copyright: support C-style comments
13307         * build-aux/update-copyright: Implement and document.
13308         * tests/test-update-copyright.sh: Test.
13309
13310 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
13311
13312         update-copyright: support omitted "(C)"
13313         * build-aux/update-copyright: Implement and document.  Also,
13314         allow variable whitespace before "(C)".
13315         * tests/test-update-copyright.sh: Test.
13316
13317 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
13318
13319         update-copyright: don't trip on non-FSF copyright statements
13320         * build-aux/update-copyright: Fix so that the first correctly
13321         formatted FSF copyright statement is recognized no matter what
13322         appears before it.  Update documentation.
13323         * tests/test-update-copyright.sh: Test that.
13324
13325 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
13326
13327         update-copyright: clean up code a little
13328         * build-aux/update-copyright: Append "_re" to the name of any
13329         variable holding a regular expression.
13330         Replace "old" and "new" with "stmt" in variable names.
13331         Do not accept 2-digit UPDATE_COPYRIGHT_YEAR, which was not
13332         handled correctly.
13333         Format code more consistently.
13334
13335 2009-08-05  Joel E. Denny  <jdenny@clemson.edu>
13336
13337         update-copyright-tests: improve portability
13338         * tests/test-update-copyright.sh: Use cmp if diff cannot handle
13339         -u or /dev/null.  Suggested by Jim Meyering and Eric Blake.
13340
13341 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
13342
13343         update-copyright: support @copyright{} and &copy;
13344         * build-aux/update-copyright: Implement and document.
13345         * tests/test-update-copyright.sh: Test.
13346
13347 2009-08-04  Jim Meyering  <meyering@redhat.com>
13348
13349         update-copyright-tests: correctly test EOL=\r\n handling
13350         * tests/test-update-copyright.sh: Put \r at the end of some lines
13351         for the dos-eol tests.  Based on a patch by Joel E. Denny.
13352
13353         maint.mk: make update-copyright exclusion list more configurable
13354         * top/maint.mk (update-copyright): Default to excluding COPYING,
13355         but allow an override, in case someone does want to update that file.
13356
13357         maint.mk: don't update copyright date in COPYING
13358         * top/maint.mk (update-copyright): Exclude COPYING.
13359
13360         maint.mk: add a copyright-updating rule
13361         * top/maint.mk (update-copyright): New rule.
13362         Derived from coreutils/Makefile.am.
13363
13364         update-copyright: rename some variables
13365         * build-aux/update-copyright: Rename a few variables for clarity.
13366         Tweak syntax.  List Joel E. Denny as coauthor.
13367
13368 2009-08-03  Joel E. Denny  <jdenny@clemson.edu>
13369
13370         update-copyright: fix bug for 2-digit last year and add tests
13371         * build-aux/update-copyright: Fix bug.
13372         Use UPDATE_COPYRIGHT_YEAR from environment as current year if
13373         specified.
13374         * modules/update-copyright-tests: New
13375         * tests/test-update-copyright.sh: New.
13376
13377 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
13378
13379         update-copyright: handle leading tabs in line prefix
13380         * build-aux/update-copyright: Count leading tabs as 8 spaces
13381         when computing margin.  This helps with the formatting of
13382         ChangeLogs, for example.
13383         Fix documentation a little.
13384
13385 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
13386
13387         update-copyright: support EOL=\r\n
13388         * build-aux/update-copyright: Implement that.
13389
13390 2009-07-31  Joel E. Denny  <jdenny@clemson.edu>
13391
13392         update-copyright: automatically format copyright statements
13393         * build-aux/update-copyright: Implement that.
13394         Also, be a little more predictable and safer by always failing
13395         when the full copyright format is not perfectly recognized as an
13396         unbroken whole.  Discussed at
13397         <http://lists.gnu.org/archive/html/bug-gnulib/2009-07/msg00131.html>.
13398         Rewrite documentation.
13399
13400 2009-08-03  Bruno Haible  <bruno@clisp.org>
13401
13402         * m4/iconv.m4 (AM_ICONV): Fix displayed message with autoconf-2.64.
13403
13404 2009-08-02  Bruno Haible  <bruno@clisp.org>
13405
13406         Tests for module 'uname'.
13407         * modules/uname-tests: New file.
13408         * tests/test-uname.c: New file.
13409
13410         New module 'uname'.
13411         * lib/uname.c: New file.
13412         * m4/uname.m4: New file.
13413         * modules/uname: New file.
13414         * doc/posix-functions/uname.texi: Mention the new module.
13415
13416 2009-08-02  Bruno Haible  <bruno@clisp.org>
13417
13418         Tests for module 'sys_utsname'.
13419         * modules/sys_utsname-tests: New file.
13420         * tests/test-sys_utsname.c: New file.
13421
13422         New module 'sys_utsname'.
13423         * lib/sys_utsname.in.h: New file, based on glibc's <sys/utsname.h>.
13424         * m4/sys_utsname_h.m4: New file.
13425         * modules/sys_utsname: New file.
13426         * doc/posix-headers/sys_utsname.texi: Mention the new module.
13427
13428 2009-08-02  Bruno Haible  <bruno@clisp.org>
13429
13430         Implicitly initialize the sockets library.
13431         * lib/gethostname.c: Include sockets.h.
13432         (rpl_gethostname): Invoke gl_sockets_startup.
13433         * lib/socket.c: Include sockets.h.
13434         (rpl_socket): Invoke gl_sockets_startup.
13435         * modules/gethostname (Depends-on): Add sockets.
13436         * modules/socket (Depends-on): Likewise.
13437         * tests/test-poll.c: Don't include sockets.h.
13438         (main): Don't invoke gl_sockets_startup.
13439         * tests/test-select.c: Don't include sockets.h.
13440         (main): Don't invoke gl_sockets_startup.
13441
13442 2009-08-02  Bruno Haible  <bruno@clisp.org>
13443
13444         Allow multiple calls to gl_sockets_startup.
13445         * lib/sockets.c (initialized_sockets_version): New variable.
13446         (gl_sockets_startup): Do nothing if already called for this or a higher
13447         version.
13448         (gl_sockets_cleanup): Reset initialized_sockets_version.
13449
13450 2009-08-03  Simon Josefsson  <simon@josefsson.org>
13451
13452         * tests/test-argp-version-etc-1.sh: Use EXEEXT.  Don't fail on
13453         different project/version.
13454
13455 2009-08-02  Paolo Bonzini  <bonzini@gnu.org>
13456             Bruno Haible  <bruno@clisp.org>
13457
13458         Tests for module 'pipe-filter-gi'.
13459         * modules/pipe-filter-gi-tests: New file.
13460         * tests/test-pipe-filter-gi1.sh: New file.
13461         * tests/test-pipe-filter-gi1.c: New file.
13462         * tests/test-pipe-filter-gi2.sh: New file.
13463         * tests/test-pipe-filter-gi2-main.c: New file.
13464         * tests/test-pipe-filter-gi2-child.c: New file.
13465
13466         New module 'pipe-filter-gi'.
13467         * lib/pipe-filter-gi.c: New file.
13468         * modules/pipe-filter-gi: New file.
13469
13470 2009-08-02  Bruno Haible  <bruno@clisp.org>
13471             Paolo Bonzini  <bonzini@gnu.org>
13472
13473         Tests for module 'pipe-filter-ii'.
13474         * modules/pipe-filter-ii-tests: New file.
13475         * tests/test-pipe-filter-ii1.sh: New file.
13476         * tests/test-pipe-filter-ii1.c: New file.
13477         * tests/test-pipe-filter-ii2.sh: New file.
13478         * tests/test-pipe-filter-ii2-main.c: New file.
13479         * tests/test-pipe-filter-ii2-child.c: New file.
13480
13481         New module 'pipe-filter-ii'.
13482         * lib/pipe-filter.h: New file.
13483         * lib/pipe-filter-ii.c: New file.
13484         * lib/pipe-filter-aux.h: New file.
13485         * modules/pipe-filter-ii: New file.
13486
13487 2009-08-02  Simon Josefsson  <simon@josefsson.org>
13488
13489         * lib/gc-libgcrypt.c: Change copyright to FSF.
13490         * lib/gc-gnulib.c: Likewise.
13491
13492 2009-08-02  Martin Lambers  <marlam@marlam.de>  (tiny change)
13493
13494         * lib/gethostname.c: Include limits.h.
13495
13496 2009-08-02  Simon Josefsson  <simon@josefsson.org>
13497             Bruno Haible  <bruno@clisp.org>
13498
13499         Ensure HOST_NAME_MAX as part of the gethostname module.
13500         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): On native Windows platforms,
13501         define also HOST_NAME_MAX.
13502         * tests/test-gethostname.c: Include <limits.h>.
13503         (main): Check also HOST_NAME_MAX.
13504         * doc/posix-headers/limits.texi: Document the mingw problem.
13505
13506 2009-08-02  Bruno Haible  <bruno@clisp.org>
13507
13508         * lib/gethostname.c (gethostname): Fix handling of large len argument.
13509         Add comments.
13510
13511 2009-03-31  Simon Josefsson  <simon@josefsson.org>
13512
13513         * lib/gethostname.c: Add Windows wrapper.
13514         * m4/gethostname.m4: Look for gethostname in -lws2_32.
13515         * modules/gethostname: Depend on sys_socket & errno, for also
13516         added lib/w32sock.h.  Add GETHOSTNAME_LIB link directive.
13517         * modules/gethostname-tests: Link to @GETHOSTNAME_LIB@.
13518
13519 2009-07-31  Jim Meyering  <meyering@redhat.com>
13520
13521         getloadavg: fix symbol name in comment
13522         * lib/getloadavg.c: Correct a typo I introduced when adding
13523         comments to Matt's change: s/NLIST_POINTER/N_NAME_POINTER/.
13524         Matt Kraai spotted the problem.
13525
13526 2009-07-29  Matt Kraai  <mkraai@beckman.com>
13527
13528         getloadavg: check whether n_name is a pointer, for QNX 6.4.1
13529         * lib/getloadavg.c (getloadavg): Use the strcpy-into-nlist.n_name
13530         code also if ! defined N_NAME_POINTER.
13531         * m4/getloadavg.m4 (gl_GETLOADAVG): Add a link-test for N_NAME_POINTER.
13532         This is required on QNX 6.4.1, where /usr/include/nlist.h exists,
13533         but the n_name member is a 12-byte array.
13534
13535 2009-07-29  Joel E. Denny  <jdenny@clemson.edu>
13536
13537         update-copyright: generalize comment handling
13538         * build-aux/update-copyright: Handle copyright statements
13539         within more comment styles.
13540         Document usage.
13541         Report any file with an external copyright holder or parse failure.
13542
13543 2009-07-29  Jim Meyering  <meyering@redhat.com>
13544
13545         mktime: correct setting of REPLACE_MKTIME
13546         * m4/mktime.m4 (gl_FUNC_MKTIME): Set REPLACE_MKTIME=0, when required.
13547
13548         update-copyright: new module
13549         * modules/update-copyright: New file.
13550         * build-aux/update-copyright: New file.
13551         * MODULES.html.sh (maint+release support): Add update-copyright.
13552
13553 2009-07-27  Bruno Haible  <bruno@clisp.org>
13554
13555         Fix compilation error when <ctime> is used and mktime is replaced.
13556         * lib/time.in.h (mktime): New declaration.
13557         * m4/mktime.m4 (gl_FUNC_MKTIME): Require gl_HEADER_TIME_H_DEFAULTS. Set
13558         REPLACE_MKTIME instead of defining mktime in config.h.
13559         * m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Initialize REPLACE_MKTIME.
13560         * modules/time (Makefile.am): Substitute REPLACE_MKTIME.
13561         Reported by Ross McFarland <rwmcfa1@neces.com>.
13562
13563 2009-07-27  Bruno Haible  <bruno@clisp.org>
13564
13565         * lib/math.in.h (cosl, logl, sinl): Undefine before declaring it.
13566         Reported by Matt Kraai <mkraai@beckman.com>.
13567
13568 2009-07-25  Jim Meyering  <meyering@redhat.com>
13569
13570         maint.mk: avoid warnings about missing files
13571         * top/maint.mk (PREV_VERSION): Suppress stderr, to hide a
13572         diagnostic when .prev-version does not exist.
13573         (_cfg_mk): Define, so it can be empty when cfg.mk does not exist.
13574         (syntax-check-rules): Use $(_cfg_mk) to avoid a diagnostic about
13575         nonexistent cfg.mk.
13576         Suggestions from Simon Josefsson.
13577
13578 2009-07-25  Bruno Haible  <bruno@clisp.org>
13579
13580         * lib/math.in.h (cosl, logl, sinl): Don't declare if they are already
13581         defined as macros. Needed on QNX 6.4.1.
13582         Reported by Matt Kraai <mkraai@beckman.com>.
13583
13584 2009-07-23  Jim Meyering  <meyering@redhat.com>
13585
13586         maint.mk: invoke "make dist" with a working value of XZ_OPT
13587         * top/maint.mk (vc-dist): Use no "-" in the value of XZ_OPT.
13588
13589 2009-07-22  Matt Kraai  <mkraai@beckman.com>  (tiny change)
13590
13591         Make fseeko.c compile on QNX.
13592         * lib/fseeko.c (rpl_fseeko): Use the numerical value of _MWRITE.
13593
13594 2009-07-22  Peter Simons  <simons@cryp.to>
13595
13596         C++: wrap md2,md5,sha1,etc. function declarations in extern "C" scope
13597         * lib/md2.h [__cplusplus]: Wrap declarations in extern "C" scope.
13598         * lib/md4.h: Likewise.
13599         * lib/md5.h: Likewise.
13600         * lib/sha1.h: Likewise.
13601         * lib/sha256.h: Likewise.
13602         * lib/sha512.h: Likewise.
13603
13604         tests-sha1: don't assign literal string to 'char *' variable
13605         * tests/test-sha1.c (main): Declare locals with "const" to match
13606         attributes of the right hand side.
13607
13608 2009-07-21  Eric Blake  <ebb9@byu.net>
13609
13610         dup2: fix more mingw problems
13611         * lib/dup2.c (rpl_dup2) [_WIN32]: Avoid hanging when duplicating
13612         fd to itself.
13613         * doc/posix-functions/dup2.texi (dup2): Document the bug.
13614         * lib/unistd.in.h (dup2) [REPLACE_FCHDIR]: Avoid name collision.
13615         * lib/fchdir.c (dup2): Manage preprocessor macros correctly.
13616         (rpl_dup2_fchdir): Rename from rpl_dup2, and let dup2 module take
13617         care of mingw bugs.
13618
13619 2009-07-21  Jim Meyering  <meyering@redhat.com>
13620
13621         vc-list-files: avoid failure when /bin/sh is dash
13622         * build-aux/vc-list-files: Avoid a shell portability problem with dash.
13623         On some Debian based systems, /bin/sh is a symlink to dash, and running
13624         this command would omit the "/" following each 'tests' prefix:
13625           dash -x build-aux/vc-list-files -C . tests
13626         That is because bash and dash work differently:
13627           $ for i in bash dash; do $i -c 'a=odd; a=ok b=$a; echo '$i' $b'; done
13628           bash ok
13629           dash odd
13630
13631 2009-07-21  Eric Blake  <ebb9@byu.net>
13632
13633         dup2-tests: test previous patch
13634         * modules/dup2-tests: New file.
13635         * tests/test-dup2.c: Likewise.
13636         * tests/test-open.c (main): Avoid unspecified behavior.
13637         * tests/test-pipe.c (child_main): Use dup2 semantics to simplify
13638         test.
13639
13640         dup2: work around mingw and cygwin 1.5 bug
13641         * m4/dup2.m4 (gl_FUNC_DUP2): Detect mingw bug.
13642         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add witness.
13643         * modules/unistd (Makefile.am): Substitute it.
13644         * lib/unistd.in.h (dup2): Declare the replacement.
13645         * lib/dup2.c (dup2) [REPLACE_DUP2]: Implement it.
13646         * doc/posix-functions/dup2.texi (dup2): Document the bugs.
13647         * lib/fchdir.c (rpl_dup2): Don't collide with mingw replacement.
13648         * modules/execute (Depends-on): Add dup2.
13649         * modules/fseterr (Depends-on): Likewise.
13650         * modules/pipe (Depends-on): Likewise.
13651         * modules/posix_spawn-internal (Depends-on): Likewise.
13652
13653 2009-07-21  Bruno Haible  <bruno@clisp.org>
13654
13655         * modules/.gitattributes: New file.
13656
13657 2009-07-20  Bruno Haible  <bruno@clisp.org>
13658
13659         * tests/test-pipe.c (BACKUP_STDERR_FILENO): New macro.
13660         (main): Use it.
13661
13662 2009-07-20  Eric Blake  <ebb9@byu.net>
13663
13664         test-pipe: make a bit more robust.
13665         * tests/test-pipe.c (myerr): Allow error messages regardless of
13666         what we do to stderr.
13667         (test_pipe): Rearrange to avoid deadlock.
13668         (child_main): Try a larger read, to ensure we avoided deadlock.
13669         * lib/pipe.c (create_pipe) [_WIN32]: Fix comment.
13670         * lib/pipe.h (create_pipe_bidi): Document potential for deadlock
13671         if misused.
13672
13673 2009-07-19  Jim Meyering  <meyering@redhat.com>
13674
13675         fts: avoid false-positive cycle-detection
13676         * lib/fts.c (fts_read): Reinitialize cycle-detection data structures
13677         for each new command line argument.
13678
13679 2009-07-19  Bruno Haible  <bruno@clisp.org>
13680
13681         Fix build error on mingw with the modules sys_select and unistd.
13682         * modules/acl-tests (Depends-on): Add close.
13683         * modules/binary-io-tests (Depends-on): Likewise.
13684         * modules/closein-tests (Depends-on): Likewise.
13685         * modules/flock-tests (Depends-on): Likewise.
13686         * modules/fsync-tests (Depends-on): Likewise.
13687         * modules/lseek-tests (Depends-on): Likewise.
13688         * modules/pipe-tests (Depends-on): Likewise.
13689         * modules/posix_spawn-tests (Depends-on): Likewise.
13690         * modules/posix_spawnp-tests (Depends-on): Likewise.
13691         * modules/stat-time-tests (Depends-on): Likewise.
13692         * modules/yesno-tests (Depends-on): Likewise.
13693
13694 2009-07-19  Bruno Haible  <bruno@clisp.org>
13695
13696         Unify conditionals.
13697         * lib/pipe.h: Detect native Win32 by looking at _WIN32 and __WIN32__
13698         macros, not at the compiler macros.
13699         * lib/pipe.c: Likewise.
13700         * lib/execute.c: Likewise.
13701         * lib/spawni.c: Likewise.
13702
13703 2009-07-19  Bruno Haible  <bruno@clisp.org>
13704
13705         Fix handling of closed stdin/stdout/stderr on mingw.
13706         * lib/w32spawn.h: Include unistd.h.
13707         (dup_noinherit): Return -1 if the old handle is invalid. Allocate new
13708         file descriptor with O_NOINHERIT flag.
13709         (fd_safer_noinherit): New function, based on fd-safer.c.
13710         (dup_safer_noinherit): New function, based on dup-safer.c.
13711         (undup_safer_noinherit): New function.
13712         * lib/execute.c (execute) [WIN32]: Use dup_safer_noinherit instead of
13713         dup_noinherit. Use undup_safer_noinherit instead of dup2 and close.
13714         * lib/pipe.c (create_pipe) [WIN32]: Likewise. Use fd_safer_noinherit
13715         instead of fd_safer.
13716         * tests/test-pipe.c: Include <windows.h>.
13717         (child_main) [WIN32]: Test the handle of STDERR_FILENO, not its close() result.
13718
13719         * tests/test-pipe.c (child_main, parent_main): New functions, extracted
13720         from main.
13721         (test_pipe): Pass an extra argument for disambiguation.
13722         (main): Invoke parent_main or child_main.
13723
13724         * tests/test-pipe.c (test_pipe): Pass slave_process = true argument
13725         consistently.
13726
13727 2009-07-18  Eric Blake  <ebb9@byu.net>
13728
13729         test-pipe: fix mingw build
13730         * tests/test-pipe.c (main): Avoid fcntl on mingw.
13731
13732 2009-07-18  Bruno Haible  <bruno@clisp.org>
13733
13734         * modules/pipe-tests (Makefile.am): Fix typo.
13735
13736 2009-07-18  Eric Blake  <ebb9@byu.net>
13737
13738         error: fix mingw build
13739         * lib/error.c (error, error_at_line): Avoid fcntl on mingw.
13740         Reported by Bruno Haible.
13741
13742         error: avoid undefined use of stdout
13743         * lib/error.c (error, error_at_line): Check that fd 1 is open
13744         before flushing stdout.  Avoids a crash on cygwin when libsigsegv
13745         is handling faults and the close_stdout module wants to report the
13746         detection of closed stdout as an error.
13747
13748 2009-07-17  Eric Blake  <ebb9@byu.net>
13749
13750         pipe: be robust in face of closed fds
13751         * lib/pipe.c (create_pipe): Closed standard descriptors in parent
13752         should cause child to misbehave.
13753         * modules/pipe-tests: New module.
13754         * tests/test-pipe.c: New file.
13755         * tests/test-pipe.sh: New file.
13756         Reported by Akim Demaille.
13757
13758 2009-07-14  Bruno Haible  <bruno@clisp.org>
13759
13760         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Guess it works on glibc systems.
13761         Reported by anonymous kc.
13762
13763 2009-07-07  Jim Meyering  <meyering@redhat.com>
13764
13765         maint.mk: don't look for translatable strings in *.m4 or *.mk
13766         * top/maint.mk (sc_po_check): Skip *.m4 and *.mk files,
13767         when searching for translatable strings.
13768
13769 2009-07-05  Jim Meyering  <meyering@redhat.com>
13770
13771         remove superfluous parentheses in STREQ definition
13772         * tests/test-argv-iter.c (STREQ): Remove redundant parentheses.
13773         * lib/getugroups.c (STREQ): Likewise.
13774         * lib/fnmatch.c (STREQ): Likewise.
13775         Spotted by Bruno Haible.
13776
13777 2009-07-04  Jim Meyering  <meyering@redhat.com>
13778
13779         argv-iter: new module
13780         * MODULES.html.sh: Add argv-iter.
13781         * lib/argv-iter.c, lib/argv-iter.h: New files.
13782         * modules/argv-iter: New file.
13783         * modules/argv-iter-tests: New file.
13784         * tests/test-argv-iter.c: Test it.
13785
13786 2009-07-04  Bruno Haible  <bruno@clisp.org>
13787
13788         Fix assertion.
13789         * lib/git-merge-changelog.c (compute_mapping): In the case where file1
13790         contains more exact copies of a given entry than file2, leave the extra
13791         copies unpaired rather than aborting.
13792         Reported by Eric Blake.
13793
13794 2009-07-02  Bruno Haible  <bruno@clisp.org>
13795
13796         Speedup git-merge-changelog for git cherry-pick.
13797         * lib/git-merge-changelog.c (struct entries_mapping): New type.
13798         (entries_mapping_get): New function, extracted from compute_mapping.
13799         (entries_mapping_reverse_get): New function.
13800         (compute_mapping): Add a 'full' argument. Return the result in a
13801         'struct entries_mapping'.
13802         (main): Update. Access the mappings through entries_mapping_get.
13803         Reported by Eric Blake.
13804
13805 2009-07-02  Bruno Haible  <bruno@clisp.org>
13806
13807         * lib/git-merge-changelog.c (compute_mapping): Fix determination of
13808         best_i.
13809
13810 2009-07-02  Bruno Haible  <bruno@clisp.org>
13811
13812         Speed up approximate search for matching ChangeLog entries.
13813         * lib/git-merge-changelog.c (entry_fstrcmp): Add a lower_bound
13814         argument. Call fstrcmp_bounded instead of fstrcmp.
13815         (compute_mapping, try_split_merged_entry, main): Update callers.
13816
13817 2009-07-02  Bruno Haible  <bruno@clisp.org>
13818
13819         * lib/git-merge-changelog.c (main): Add comment about git cherry-pick.
13820
13821 2009-06-30  Bruno Haible  <bruno@clisp.org>
13822
13823         Reduce the number of uc_is_cased calls.
13824         * lib/unicase.h (casing_suffix_context_t): Add
13825         'first_char_except_ignorable' field.
13826         * lib/unicase/context.h (SCC_FINAL_SIGMA_MASK): Remove macro.
13827         (SCC_MORE_ABOVE_MASK, SCC_BEFORE_DOT_MASK): Update.
13828         * lib/unicase/empty-suffix-context.c (unicase_empty_suffix_context):
13829         Update initializer.
13830         * lib/unicase/u-casemap.h (FUNC): Don't invoke uc_is_cased on
13831         case-ignorable characters.
13832         * lib/unicase/u-ct-totitle.h (FUNC): Likewise.
13833         * lib/unicase/u-suffix-context.h (FUNC2): Don't call uc_is_cased here.
13834         * modules/unicase/u8-suffix-context (Depends-on): Remove unicase/cased.
13835         * modules/unicase/u16-suffix-context (Depends-on): Likewise.
13836         * modules/unicase/u32-suffix-context (Depends-on): Likewise.
13837
13838 2009-06-30  Bruno Haible  <bruno@clisp.org>
13839
13840         Tests for module 'unicase/ignorable'.
13841         * modules/unicase/ignorable-tests: New file.
13842         * tests/unicase/test-ignorable.c: New file, generated by
13843         gen-uni-tables.
13844
13845         Tests for module 'unicase/cased'.
13846         * modules/unicase/cased-tests: New file.
13847         * tests/unicase/test-cased.c: New file, generated by gen-uni-tables.
13848         * tests/unicase/test-predicate-part1.h: New file, derived from
13849         tests/unictype/test-predicate-part1.h.
13850         * tests/unicase/test-predicate-part2.h: New file, same as
13851         tests/unictype/test-predicate-part2.h.
13852
13853         Fix evaluation of "Before C" condition of FINAL_SIGMA.
13854         * lib/gen-uni-tables.c (is_cased, is_case_ignorable): New functions.
13855         (output_casing_properties): New function.
13856         (main): Call it.
13857         * lib/unicase/cased.h: New file, generated by gen-uni-tables.
13858         * lib/unicase/cased.c: Include unictype/bitmap.h.
13859         (uc_is_cased): Define through a bitmap lookup.
13860         * lib/unicase/ignorable.h: New file, generated by gen-uni-tables.
13861         * lib/unicase/ignorable.c: Include unictype/bitmap.h.
13862         (uc_is_case_ignorable): Define through a bitmap lookup.
13863         * modules/unicase/cased (Files): Add lib/unicase/cased.h,
13864         lib/unictype/bitmap.h.
13865         (Depends-on): Add inline. Clean up.
13866         * modules/unicase/ignorable (Files): Add lib/unicase/ignorable.h,
13867         lib/unictype/bitmap.h.
13868         (Depends-on): Add inline. Clean up.
13869         * tests/unicase/test-u8-tolower.c (main): Add more tests of FINAL_SIGMA
13870         recognition.
13871         * tests/unicase/test-u16-tolower.c (main): Likewise.
13872         * tests/unicase/test-u32-tolower.c (main): Likewise.
13873
13874 2009-06-30  Bruno Haible  <bruno@clisp.org>
13875
13876         * lib/unicase/u8-casemap.c: Don't include uniwbrk.h.
13877         * lib/unicase/u16-casemap.c: Likewise.
13878         * lib/unicase/u32-casemap.c: Likewise.
13879
13880 2009-06-29  Bruno Haible  <bruno@clisp.org>
13881
13882         Define u32_casefold as a wrapper around u32_ct_casefold.
13883         * lib/unicase/u32-casefold.c: Update.
13884         * modules/unicase/u32-casefold (Depends-on): Add
13885         unicase/u32-ct-casefold, unicase/empty-prefix-context,
13886         unicase/empty-suffix-context. Clean up.
13887
13888         Define u16_casefold as a wrapper around u16_ct_casefold.
13889         * lib/unicase/u16-casefold.c: Update.
13890         * modules/unicase/u16-casefold (Depends-on): Add
13891         unicase/u16-ct-casefold, unicase/empty-prefix-context,
13892         unicase/empty-suffix-context. Clean up.
13893
13894         Define u8_casefold as a wrapper around u8_ct_casefold.
13895         * lib/unicase/u-casefold.h (FUNC): Delegate to U_CT_CASEFOLD.
13896         * lib/unicase/u8-casefold.c: Update.
13897         * modules/unicase/u8-casefold (Depends-on): Add unicase/u8-ct-casefold,
13898         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
13899
13900         Define u32_totitle as a wrapper around u32_ct_totitle.
13901         * lib/unicase/u32-totitle.c: Update.
13902         * modules/unicase/u32-totitle (Depends-on): Add unicase/u32-ct-totitle,
13903         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
13904
13905         Define u16_totitle as a wrapper around u16_ct_totitle.
13906         * lib/unicase/u16-totitle.c: Update.
13907         * modules/unicase/u16-totitle (Depends-on): Add unicase/u16-ct-totitle,
13908         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
13909
13910         Define u8_totitle as a wrapper around u8_ct_totitle.
13911         * lib/unicase/u-totitle.h (is_cased, is_case_ignorable): Remove
13912         functions.
13913         (FUNC): Delegate to U_CT_TOTITLE.
13914         * lib/unicase/u8-totitle.c: Update.
13915         * modules/unicase/u8-totitle (Depends-on): Add unicase/u8-ct-totitle,
13916         unicase/empty-prefix-context, unicase/empty-suffix-context. Clean up.
13917
13918         * lib/unicase/u32-tolower.c (u32_tolower): Update u32_casemap
13919         invocation.
13920         * modules/unicase/u32-tolower (Depends-on): Add
13921         unicase/empty-prefix-context, unicase/empty-suffix-context.
13922
13923         * lib/unicase/u16-tolower.c (u16_tolower): Update u16_casemap
13924         invocation.
13925         * modules/unicase/u16-tolower (Depends-on): Add
13926         unicase/empty-prefix-context, unicase/empty-suffix-context.
13927
13928         * lib/unicase/u8-tolower.c (u8_tolower): Update u8_casemap invocation.
13929         * modules/unicase/u8-tolower (Depends-on): Add
13930         unicase/empty-prefix-context, unicase/empty-suffix-context.
13931
13932         * lib/unicase/u32-toupper.c (u32_toupper): Update u32_casemap
13933         invocation.
13934         * modules/unicase/u32-toupper (Depends-on): Add
13935         unicase/empty-prefix-context, unicase/empty-suffix-context.
13936
13937         * lib/unicase/u16-toupper.c (u16_toupper): Update u16_casemap
13938         invocation.
13939         * modules/unicase/u16-toupper (Depends-on): Add
13940         unicase/empty-prefix-context, unicase/empty-suffix-context.
13941
13942         * lib/unicase/u8-toupper.c (u8_toupper): Update u8_casemap invocation.
13943         * modules/unicase/u8-toupper (Depends-on): Add
13944         unicase/empty-prefix-context, unicase/empty-suffix-context.
13945
13946         New module 'unicase/u32-ct-casefold'.
13947         * lib/unicase/u32-ct-casefold.c: New file.
13948         * modules/unicase/u32-ct-casefold: New file.
13949
13950         New module 'unicase/u16-ct-casefold'.
13951         * lib/unicase/u16-ct-casefold.c: New file.
13952         * modules/unicase/u16-ct-casefold: New file.
13953
13954         New module 'unicase/u8-ct-casefold'.
13955         * lib/unicase/u8-ct-casefold.c: New file.
13956         * lib/unicase/u-ct-casefold.h: New file, derived from
13957         lib/unicase/u-casefold.h.
13958         * modules/unicase/u8-ct-casefold: New file.
13959
13960         New module 'unicase/u32-ct-totitle'.
13961         * lib/unicase/u32-ct-totitle.c: New file.
13962         * modules/unicase/u32-ct-totitle: New file.
13963
13964         New module 'unicase/u16-ct-totitle'.
13965         * lib/unicase/u16-ct-totitle.c: New file.
13966         * modules/unicase/u16-ct-totitle: New file.
13967
13968         New module 'unicase/u8-ct-totitle'.
13969         * lib/unicase/u8-ct-totitle.c: New file.
13970         * lib/unicase/u-ct-totitle.h: New file, derived from
13971         lib/unicase/u-totitle.h.
13972         * modules/unicase/u8-ct-totitle: New file.
13973
13974         New module 'unicase/u32-ct-tolower'.
13975         * lib/unicase/u32-ct-tolower.c: New file.
13976         * modules/unicase/u32-ct-tolower: New file.
13977
13978         New module 'unicase/u16-ct-tolower'.
13979         * lib/unicase/u16-ct-tolower.c: New file.
13980         * modules/unicase/u16-ct-tolower: New file.
13981
13982         New module 'unicase/u8-ct-tolower'.
13983         * lib/unicase/u8-ct-tolower.c: New file.
13984         * modules/unicase/u8-ct-tolower: New file.
13985
13986         New module 'unicase/u32-ct-toupper'.
13987         * lib/unicase/u32-ct-toupper.c: New file.
13988         * modules/unicase/u32-ct-toupper: New file.
13989
13990         New module 'unicase/u16-ct-toupper'.
13991         * lib/unicase/u16-ct-toupper.c: New file.
13992         * modules/unicase/u16-ct-toupper: New file.
13993
13994         New module 'unicase/u8-ct-toupper'.
13995         * lib/unicase/u8-ct-toupper.c: New file.
13996         * modules/unicase/u8-ct-toupper: New file.
13997
13998         Add context arguments to u*_casemap functions.
13999         * lib/unicase/unicasemap.h: Include unicase.h.
14000         (u8_casemap, u16_casemap, u32_casemap): Add prefix_context and
14001         suffix_context arguments.
14002         * lib/unicase/u-casemap.h (is_cased, is_case_ignorable): Remove
14003         functions.
14004         (FUNC): Add prefix_context and suffix_context arguments. Use
14005         uc_is_cased and uc_is_case_ignorable.
14006         * lib/unicase/u8-casemap.c: Include caseprop.h and context.h.
14007         * lib/unicase/u16-casemap.c: Likewise.
14008         * lib/unicase/u32-casemap.c: Likewise.
14009         * modules/unicase/u8-casemap (Files): Add lib/unicase/context.h.
14010         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
14011         * modules/unicase/u16-casemap (Files): Add lib/unicase/context.h.
14012         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
14013         * modules/unicase/u32-casemap (Files): Add lib/unicase/context.h.
14014         (Depends-on): Add unicase/cased, unicase/ignorable. Clean up.
14015
14016         New module 'unicase/u32-suffix-context'.
14017         * lib/unicase/u32-suffix-context.c: New file.
14018         * modules/unicase/u32-suffix-context: New file.
14019
14020         New module 'unicase/u16-suffix-context'.
14021         * lib/unicase/u16-suffix-context.c: New file.
14022         * modules/unicase/u16-suffix-context: New file.
14023
14024         New module 'unicase/u8-suffix-context'.
14025         * lib/unicase/u8-suffix-context.c: New file.
14026         * lib/unicase/u-suffix-context.h: New file.
14027         * modules/unicase/u8-suffix-context: New file.
14028
14029         New module 'unicase/empty-suffix-context'.
14030         * lib/unicase/empty-suffix-context.c: New file.
14031         * modules/unicase/empty-suffix-context: New file.
14032
14033         New module 'unicase/u32-prefix-context'.
14034         * lib/unicase/u32-prefix-context.c: New file.
14035         * modules/unicase/u32-prefix-context: New file.
14036
14037         New module 'unicase/u16-prefix-context'.
14038         * lib/unicase/u16-prefix-context.c: New file.
14039         * modules/unicase/u16-prefix-context: New file.
14040
14041         New module 'unicase/u8-prefix-context'.
14042         * lib/unicase/u8-prefix-context.c: New file.
14043         * lib/unicase/u-prefix-context.h: New file.
14044         * lib/unicase/context.h: New file.
14045         * modules/unicase/u8-prefix-context: New file.
14046
14047         New module 'unicase/empty-prefix-context'.
14048         * lib/unicase/empty-prefix-context.c: New file.
14049         * modules/unicase/empty-prefix-context: New file.
14050
14051         New module 'unicase/ignorable'.
14052         * lib/unicase/ignorable.c: New file.
14053         * modules/unicase/ignorable: New file.
14054
14055         New module 'unicase/cased'.
14056         * lib/unicase/caseprop.h: New file.
14057         * lib/unicase/cased.c: New file.
14058         * modules/unicase/cased: New file.
14059
14060         New functions for case mapping of substrings.
14061         * lib/unicase.h (casing_prefix_context_t): New type.
14062         (unicase_empty_prefix_context): New variable.
14063         (u8_casing_prefix_context, u16_casing_prefix_context,
14064         u32_casing_prefix_context, u8_casing_prefixes_context,
14065         u16_casing_prefixes_context, u32_casing_prefixes_context): New
14066         declarations.
14067         (casing_suffix_context_t): New type.
14068         (unicase_empty_suffix_context): New variable.
14069         (u8_casing_suffix_context, u16_casing_suffix_context,
14070         u32_casing_suffix_context, u8_casing_suffixes_context,
14071         u16_casing_suffixes_context, u32_casing_suffixes_context,
14072         u8_ct_toupper, u16_ct_toupper, u32_ct_toupper, u8_ct_tolower,
14073         u16_ct_tolower, u32_ct_tolower, u8_ct_totitle, u16_ct_totitle,
14074         u32_ct_totitle, u8_ct_casefold, u16_ct_casefold, u32_ct_casefold): New
14075         declarations.
14076
14077 2009-06-28  Jim Meyering  <meyering@redhat.com>
14078
14079         boostrap: indent only with spaces
14080         * build-aux/bootstrap: Indent only with spaces, never TABs.
14081
14082         bootstrap: split long lines
14083         * build-aux/bootstrap: Keep line length < 80.
14084
14085         bootstrap: sync from coreutils
14086         * build-aux/bootstrap: Honor variables like $ACLOCAL, etc.,
14087         just as autoreconf does.  Verify a list of prerequisite
14088         package-name,version-number pairs if defined in bootstrap.conf.
14089         Refer to README-prereq, if prerequisites are not satisfied.
14090
14091 2009-06-27  Eric Blake  <ebb9@byu.net>
14092
14093         tests: add test for bogus NULL definition
14094         * tests/test-stdio.c: Ensure POSIX 2008 requirement on NULL.
14095         * tests/test-stdlib.c: Likewise.
14096         * tests/test-string.c: Likewise.
14097         * tests/test-locale.c: Likewise.
14098         * tests/test-unistd.c: Likewise.
14099         * modules/stdio-tests (Depends-on): Add verify.
14100         * modules/stdlib-tests (Depends-on): Likewise.
14101         * modules/string-tests (Depends-on): Likewise.
14102         * modules/locale-tests (Depends-on): Likewise.
14103         * modules/unistd-tests (Depends-on): Likewise.
14104
14105 2009-06-27  Paolo Bonzini  <bonzini@gnu.org>
14106
14107         * m4/selinux-context-h (gl_HEADERS_SELINUX_CONTEXT_H): Remove
14108         self-explaining comment.
14109         * m4/selinux-selinux-h: Update serial.
14110         (gl_LIBSELINUX): New macro, adding a warning for missing development
14111         packages to code extracted from...
14112         (gl_HEADERS_SELINUX_SELINUX_H): ... this one.  Require gl_LIBSELINUX.
14113         Add warning for missing development packages here, too.
14114
14115 2009-06-26  Paolo Bonzini  <bonzini@gnu.org>
14116
14117         * build-aux/bootstrap: Do not use GIT_CONFIG_LOCAL.
14118
14119 2009-06-25  Eric Blake  <ebb9@byu.net>
14120
14121         version-etc: fix regression
14122         * lib/version-etc.h (ATTRIBUTE_SENTINEL): Define for new enough
14123         gcc.
14124         (version_etc): Use it, to catch bugs with trailing NULL.
14125         * lib/version-etc.c (version_etc_arn): Delete unused argument.
14126         (version_etc_va): Fix logic bug.
14127         * modules/version-etc-tests: Add test.
14128         * tests/test-version-etc.c: New file.
14129         * tests/test-version-etc.sh: Likewise.
14130
14131 2009-06-25  Sam Steingold  <sds@gnu.org>
14132
14133         * mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): Include <stdlib.h>, for the
14134         mbtowc declaration.
14135
14136 2009-06-25  Eric Blake  <ebb9@byu.net>
14137
14138         fpurge: migrate into <stdio.h>
14139         * lib/fpurge.h: Delete...
14140         * lib/stdio.in.h (fpurge): ...and declare here, instead.
14141         * lib/fpurge.c (fpurge): Change declaring header.
14142         * modules/fpurge (Files): Drop deleted file.
14143         (Depends-on): Add stdio.
14144         (configure.ac): Set witness.
14145         * modules/stdio (Makefile.am): Support fpurge macros.
14146         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
14147         * m4/fpurge.m4 (gl_FUNC_FPURGE): Set appropriate variables.
14148         * lib/fflush.c: Update client.
14149         * tests/test-fpurge.c: Likewise.
14150         * NEWS: Mention the change.
14151
14152 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14153
14154         * lib/argp-version-etc.c (program_authors): Add const
14155         qualifier.
14156         * lib/version-etc.c: Fix typos in the comments.
14157         * modules/argp-version-etc: Depends on version-etc.
14158
14159 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14160
14161         argp-version-etc: new module.
14162
14163         * lib/argp-version-etc.c: New file.
14164         * lib/argp-version-etc.h: New file.
14165         * modules/argp-version-etc: New file.
14166         * modules/argp-version-etc-tests: New file.
14167         * tests/test-argp-version-etc.c: New test.
14168         * tests/test-argp-version-etc-1.sh: New test.
14169
14170 2009-06-25  Sergey Poznyakoff  <gray@gnu.org.ua>
14171
14172         Provide additional interfaces and documentation for version-etc
14173         module.
14174
14175         * lib/version-etc.c (version_etc_arn, version_etc_ar): New
14176         interfaces.
14177         * lib/version-etc.h (version_etc_arn, version_etc_ar): New
14178         prototypes.
14179
14180 2009-06-24  Bruno Haible  <bruno@clisp.org>
14181
14182         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Fix description of
14183         HAVE_LIB${NAME} macro.
14184         Reported by Sam Steingold <sds@gnu.org>.
14185
14186 2009-06-23  Simon Josefsson  <simon@josefsson.org>
14187
14188         * modules/hash-tests (test_hash_LDADD): Link to libintl when
14189         needed.
14190
14191 2009-06-21  Bruno Haible  <bruno@clisp.org>
14192
14193         Make two consecutive identical invocations of AC_LIB_HAVE_LINKFLAGS
14194         work.
14195         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Reset HAVE_LIB${NAME}
14196         together with LIB${NAME}, LTLIB${NAME}.
14197         Reported by Sam Steingold <sds@gnu.org>.
14198
14199 2009-06-20  Jim Meyering  <meyering@redhat.com>
14200
14201         tests: make sc_require_test_exit_idiom more generic
14202         * top/maint.mk (Exit_witness_file): New overridable variable.
14203         (sc_require_test_exit_idiom): Don't hard-code tests/test-lib.sh.
14204         Relax test for /^Exit \$fail$$/ to just /^Exit ./.
14205
14206 2009-06-19  Jim Meyering  <meyering@redhat.com>
14207
14208         hash: reverse order of src/dst parameters in an internal interface
14209         * lib/hash.c (transfer_entries): Reverse order of parameters to
14210         put DST before SRC.  Adjust callers.
14211
14212         tests: test-hash: avoid wholesale duplication
14213         * tests/test-hash.c (main): Don't copy/paste a 60-line loop.
14214         Instead, use a loop and add a single conditional.
14215
14216         tests: test-hash: allow seed selection via a command line argument
14217         * tests/test-hash.c (get_seed): New function.
14218         (main): Use it.
14219
14220 2009-06-19  Eric Blake  <ebb9@byu.net>
14221
14222         hash: avoid memory leak on allocation failure
14223         * lib/hash.c: (hash_rehash): Avoid memory leak on allocation
14224         failure.  Factor repeated algorithm...
14225         (transfer_entries): ...into new helper routine.
14226         (hash_delete): React to hash_rehash return value.
14227
14228         hash: reduce memory pressure in hash_rehash no-op case
14229         * lib/hash.c (next_prime): Avoid overflow.
14230         (hash_initialize): Factor bucket size computation...
14231         (compute_bucket_size): ...into new helper function.
14232         (hash_rehash): Use new function and open coding to reduce memory
14233         pressure, and avoid a memory leak in USE_OBSTACK code.
14234         Reported by Jim Meyering.
14235
14236 2009-06-18  Eric Blake  <ebb9@byu.net>
14237
14238         hash: make rotation more obvious
14239         * modules/hash (Depends-on): Add bitrotate and stdint.
14240         * lib/bitrotate.h (rotl_sz, rotr_sz): New functions.
14241         * lib/hash.c (headers): Drop limits.h.  Add stdint.h.
14242         (SIZE_MAX): Rely on headers for definition.
14243         (hash_string) [USE_DIFF_HASH]: Use rotl_sz.
14244         (raw_hasher): Use rotr_sz.
14245         Suggested by Jim Meyering.
14246
14247         hash: fix memory leak in last patch
14248         * lib/hash.c (hash_rehash): Avoid memory leak.
14249
14250         hash: avoid no-op rehashing
14251         * lib/hash.c (hash_rehash): Recognize useless rehash attempts.
14252
14253         hash: provide default callback functions
14254         * lib/hash.c (raw_hasher, raw_comparator): New functions.
14255         (hash_initialize): Use them as defaults.
14256         * tests/test-hash.c (main): Test this.
14257
14258         hash: minor optimization
14259         * lib/hash.c (hash_lookup, hash_find_entry): Avoid function call
14260         when possible.
14261         (hash_initialize): Document this promise.
14262         (hash_do_for_each, hash_clear, hash_free): Use C89 syntax.
14263         * tests/test-hash.c (hash_compare_strings): Test this.
14264
14265 2009-06-18  Bruno Haible  <bruno@clisp.org>
14266
14267         * m4/strstr.m4 (gl_FUNC_STRSTR): Skip linear time test if strstr is
14268         going to be replaced anyway.
14269
14270 2009-06-18  Bruno Haible  <bruno@clisp.org>
14271
14272         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Invoke AC_LIBOBJ only
14273         in one place.
14274         (gl_FUNC_STRCASESTR): Skip linear time test if strcasestr is going to
14275         be replaced anyway.
14276
14277 2009-06-18  Eric Blake  <ebb9@byu.net>
14278
14279         hash: check for resize before insertion
14280         * lib/hash.c (hash_insert): Check whether bucket usage exceeds
14281         threshold before insertion, so that a pathological hash_rehash
14282         that fills every bucket can still trigger another rehash.
14283
14284 2009-06-18  Jim Meyering  <meyering@redhat.com>
14285
14286         hash-tests: add a loop around the small tests
14287         * tests/test-hash.c (main): Repeat small tests with selected
14288         small initial table sizes.
14289
14290 2009-06-17  Eric Blake  <ebb9@byu.net>
14291
14292         hash: minor cleanups
14293         * lib/hash.h (hash_entry): Make opaque, by moving...
14294         * lib/hash.c (hash_entry): ...here.
14295         (hash_insert): Clarify restrictions on what can be inserted.
14296         (hash_get_next): Clarify when it is safe to remove an element
14297         during traversal.
14298         (check_tuning): Skip verification when tuning is known safe.
14299         (hash_initialize): Clarify restrictions on tuning.
14300
14301 2009-06-17  Jim Meyering  <jim@meyering.net>
14302         and Eric Blake  <ebb9@byu.net>
14303
14304         hash-tests: new module
14305         * modules/hash-tests: New file.
14306         * tests/test-hash.c: New file.
14307
14308 2009-06-17  Eric Blake  <ebb9@byu.net>
14309
14310         strstr-simple: document new module
14311         * MODULES.html.sh: Document new module.
14312
14313         strstr, strcasestr: replace on platforms with broken memchr
14314         * modules/strstr: Split into...
14315         * modules/strstr-simple: ...new module that does not care about
14316         performance, but does care about glibc bug.
14317         * m4/strstr.m4 (gl_FUNC_STRSTR): Split...
14318         (gl_FUNC_STRSTR_SIMPLE): ...into new macro, which replaces strstr
14319         if platform memchr is broken, per Debian bug 521737.
14320         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): React to broken
14321         memchr.
14322         * m4/memchr.m4 (gl_FUNC_MEMCHR): Only expand once.
14323         * doc/posix-functions/strstr.texi (strstr): Document the fix.
14324         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
14325         * modules/mountlist (Depends-on): Add strstr-simple.
14326         * modules/gen-uni-tables (Depends-on): Likewise.
14327         * modules/argz (Depends-on): Add strstr.
14328
14329 2009-06-17  Bruno Haible  <bruno@clisp.org>
14330
14331         * modules/posix_spawn-internal (Depends-on): Add errno.
14332
14333 2009-06-17  Bruno Haible  <bruno@clisp.org>
14334
14335         Define missing ESTALE on Interix 3.5.
14336         * lib/errno.in.h (ESTALE): Assign a value if missing.
14337         * lib/strerror.c (rpl_strerror): Handle missing ESTALE and ECANCELED.
14338         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Also test whether ESTALE is
14339         missing.
14340         * doc/posix-headers/errno.texi: Mention the Interix bug.
14341         Reported by Jay Krell <jay.krell@cornell.edu> via Eric Blake.
14342
14343 2009-06-15  Eric Blake  <ebb9@byu.net>
14344
14345         memchr, memchr2: add valgrind exception
14346         * lib/memchr.valgrind: New file.
14347         * lib/memchr2.valgrind: New file.
14348         * modules/memchr (Files): Distribute valgrind file.
14349         * modules/memchr2 (Files): Likewise.
14350
14351         docs: memchr is no longer obsolete
14352         * MODULES.html.sh: Move memchr from obsolete to string.h section.
14353         * lib/string.in.h (memchr): Simplify logic.
14354
14355 2009-06-14  Jim Meyering  <meyering@redhat.com>
14356
14357         link-follow: fix the "checking..." message to not mention trailing slash
14358         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): This test has
14359         never considered trailing slashes.
14360
14361 2009-06-14  Bruno Haible  <bruno@clisp.org>
14362
14363         * m4/memchr.m4: Mention also the bug on IA-64.
14364         * doc/posix-functions/memchr.texi: Likewise.
14365
14366 2009-06-12  Eric Blake  <ebb9@byu.net>
14367
14368         memchr: detect broken x86_64 and alpha implementations
14369         * modules/memchr-tests (Depends-on): Move mmap detection...
14370         * modules/memchr (Depends-on): ...here.
14371         (configure.ac): Set indicator.
14372         * lib/string.in.h (memchr): Declare replacement.
14373         * modules/string (Makefile.am): Trigger replacement.
14374         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
14375         * m4/memchr.m4 (gl_FUNC_MEMCHR): Use mmap to detect platform
14376         bugs.
14377         * doc/posix-functions/memchr.texi (memchr): Document the bug.
14378         * modules/getpagesize (License): Relax license.
14379
14380 2009-06-11  Bruno Haible  <bruno@clisp.org>
14381
14382         * lib/idpriv.h: Add more references.
14383
14384 2009-06-08  Bruno Haible  <bruno@clisp.org>
14385
14386         Tests for module 'idpriv-droptemp'.
14387         * modules/idpriv-droptemp-tests: New file.
14388         * tests/test-idpriv-droptemp.sh: New file.
14389         * tests/test-idpriv-droptemp.su.sh: New file.
14390         * tests/test-idpriv-droptemp.c: New file.
14391
14392         New module 'idpriv-droptemp'.
14393         * lib/idpriv-droptemp.c: New file.
14394         * modules/idpriv-droptemp: New file.
14395
14396 2009-06-08  Bruno Haible  <bruno@clisp.org>
14397
14398         Tests for module 'idpriv-drop'.
14399         * modules/idpriv-drop-tests: New file.
14400         * tests/test-idpriv-drop.sh: New file.
14401         * tests/test-idpriv-drop.su.sh: New file.
14402         * tests/test-idpriv-drop.c: New file.
14403
14404         New module 'idpriv-drop'.
14405         * lib/idpriv.h: New file.
14406         * lib-idpriv-drop.c: New file.
14407         * m4/idpriv.m4: New file.
14408         * modules/idpriv-drop: New file.
14409
14410 2009-06-08  Bruno Haible  <bruno@clisp.org>
14411
14412         * modules/unistdio/u8-vasnprintf (Depends-on): Add memchr.
14413         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
14414         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
14415         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
14416         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
14417         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
14418         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
14419
14420 2009-06-08  Eric Blake  <ebb9@byu.net>
14421
14422         test-strstr: use memory fence, when possible
14423         * tests/test-strstr.c (main): Use memory fence, in order to be
14424         more likely to trigger Debian bug 521737.
14425         * modules/strstr-tests (Files): Pull in additional files.
14426
14427         memchr: no longer obsolete, for wider field testing
14428         * modules/memchr (Status, Notice): Delete, this module is no
14429         longer obsolete.
14430         * modules/vasnprintf (Depends-on): Add memchr.
14431
14432 2009-06-07  Jim Meyering  <meyering@redhat.com>
14433
14434         hash: declare some functions with the warn_unused_result attribute
14435         * lib/hash.h (__attribute__, ATTRIBUTE_WUR): Define.
14436
14437 2009-06-07  Bruno Haible  <bruno@clisp.org>
14438
14439         * tests/test-alignof.c: Don't test int64_t if it does not exist.
14440         Reported by Eric Blake.
14441
14442 2009-06-06  Eric Blake  <ebb9@byu.net>
14443
14444         test-alignof: fix typo with long double
14445         * tests/test-alignof.c (CHECK): Use longdouble typedef to avoid
14446         compiler error.
14447
14448 2009-06-06  Neil Jerram  <neil@ossau.uklinux.net>  (tiny change)
14449
14450         Escape non-texinfo { and }s.
14451         * doc/ld-output-def.texi (Visual Studio Compatibility): Fix
14452         markup error.
14453
14454 2009-06-04  Jim Meyering  <meyering@redhat.com>
14455
14456         gitlog-to-changelog: don't infloop on an empty commit log
14457         * build-aux/gitlog-to-changelog: Warn about an empty log message.
14458         Reported by Boris Petersen <transacid@centerim.org>.
14459
14460 2009-06-03  Mike Frysinger  <vapier@gentoo.org>
14461
14462         version-etc: extend for packagers
14463         Add three new configure options, intended for packagers:
14464           --with-packager="packager name"
14465           --with-packager-version="packager-specific version"
14466           --with-packager-bug-reports="packager bug reporting"
14467         An example with coreutils:
14468           $ ./configure \
14469             --with-packager=Gentoo \
14470             --with-packager-bug-report=http://bugs.gentoo.org/ \
14471             --with-packager-version="patchset 1.6"
14472           $ ./src/ls --version | head -n2
14473           ls (GNU coreutils) 7.1-dirty
14474           Packaged by Gentoo (patchset 1.6)
14475         Note that the bug reporting info via --help doesn't show up because
14476         coreutils uses its own custom emit_bug_reporting_address() implementation
14477         in src/system.h.  If it didn't, it'd look like:
14478           $ ./src/ls --help | tail -n4
14479           Report bugs to <bug-coreutils@gnu.org>.
14480           Report Gentoo bugs to <http://bugs.gentoo.org/>.
14481           GNU coreutils home page: <http://www.gnu.org/software/coreutils/>.
14482           General help using GNU software: <http://www.gnu.org/gethelp/>.
14483         * lib/version-etc.c: Print new information, if provided.
14484         * m4/version-etc.m4: New file.
14485         * modules/version-etc (Files): Add m4/version-etc.m4.
14486         (configure.ac): Add gl_VERSION_ETC.
14487
14488 2009-05-31  Bruno Haible  <bruno@clisp.org>
14489
14490         * tests/test-alignof.c: Include <stdint.h>. Check also 'long double'
14491         and 'int64_t'.
14492         * modules/alignof-tests (Dependencies): Add stdint.
14493         Reported by Eric Blake.
14494
14495 2009-05-31  Bruno Haible  <bruno@clisp.org>
14496
14497         * lib/alignof.h (alignof_slot, alignof_type, alignof): Document
14498         restriction due to compiler bugs.
14499         Reported by Eric Blake.
14500
14501 2009-05-31  Simon Josefsson  <simon@josefsson.org>
14502             Bruno Haible  <bruno@clisp.org>
14503
14504         Fix test-alignof failure.
14505         * lib/alignof.h (alignof_slot): New macro.
14506         (alignof_type): New macro, with the same semantics as the previous
14507         'alignof'.
14508         (alignof): Alias to alignof_slot.
14509         * tests/test-alignof.c (CHECK): Check alignof_slot, not alignof. Also
14510         check that the results are usable as constant expressions.
14511
14512 2009-05-31  Bruno Haible  <bruno@clisp.org>
14513
14514         * tests/zerosize-ptr.h (zerosize_ptr): Specify more details.
14515         * tests/test-memchr.c (main): Check that memchr does not read past the
14516         first occurrence of the byte.
14517         * tests/test-strstr.c (main): Update comment.
14518         Suggested by Eric Blake.
14519
14520 2009-05-30  Bruno Haible  <bruno@clisp.org>
14521
14522         * doc/ld-output-def.texi (Visual Studio Compatibility): Explain in more
14523         detail how to use dumpbin.
14524         Reported by David Byron <dbyron@dbyron.com>.
14525
14526 2009-06-02  Simon Josefsson  <simon@josefsson.org>
14527
14528         * tests/test-parse-duration.sh: Don't use non-portable 'read -u3'.
14529
14530 2009-06-02  Simon Josefsson  <simon@josefsson.org>
14531
14532         * m4/manywarnings.m4: Add GCC 4.4 warnings.
14533
14534 2009-05-28  Bruno Haible  <bruno@clisp.org>
14535
14536         * gnulib-tool (func_import): Don't do HAVE_CONFIG_H replacements on
14537         build-aux/ files.
14538
14539 2009-05-28  Simon Josefsson  <simon@josefsson.org>
14540
14541         * gnulib-tool (func_import): Transform license on build-aux/ files too.
14542
14543 2009-05-27  Simon Josefsson  <simon@josefsson.org>
14544
14545         * gnulib-tool (sed_transform_main_lib_file)
14546         (sed_transform_testsrelated_lib_file): : Don't use non-POSIX
14547         regexps.
14548
14549 2009-05-26  Simon Josefsson  <simon@josefsson.org>
14550
14551         * tests/test-strstr.c: Add another self-test.
14552         * tests/test-strstr.c: Rewrite to use malloc/strcpy instead of
14553         strdup.  Suggested by Eric Blake  <ebb9@byu.net>.
14554
14555 2009-05-23  Bruno Haible  <bruno@clisp.org>
14556
14557         * doc/havelib.texi (AC_LIB_HAVE_LINKFLAGS): Update for 2009-04-26
14558         change.
14559
14560 2009-05-21  Bruno Haible  <bruno@clisp.org>
14561
14562         Simplify use of mode_t varargs.
14563         * lib/open.c (open): Use PROMOTED_MODE_T instead of a conditional that
14564         uses 'mode_t' or 'int'.
14565         * lib/openat.c (openat): Likewise.
14566         * lib/open-safer.c (open_safer): Likewise.
14567         * m4/mode_t.m4: New file.
14568         * m4/open.m4 (gl_PREREQ_OPEN): Require gl_PROMOTED_TYPE_MODE_T.
14569         * m4/openat.m4 (gl_PREREQ_OPENAT): Likewise.
14570         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Likewise.
14571         * modules/open (Files): Add m4/mode_t.m4.
14572         * modules/openat (Files): Likewise.
14573         * modules/fcntl-safer (Files): Likewise.
14574         Suggested by Eric Blake.
14575
14576 2009-05-21  Pádraig Brady  <P@draigbrady.com>
14577
14578         * doc/glibc-functions/fallocate.texi: New file.
14579         * doc/gnulib.texi: Include it.
14580
14581 2009-05-21  Eric Blake  <ebb9@byu.net>
14582             Bruno Haible  <bruno@clisp.org>
14583
14584         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Remove redundant m4_quote
14585         invocations.
14586         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
14587
14588 2009-05-21  Eric Blake  <ebb9@byu.net>
14589             Bruno Haible  <bruno@clisp.org>
14590
14591         Second attempt to work around an AIX 5.3, 6.1 compiler bug with
14592         include_next. Fix of 2008-11-20 commit.
14593         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Also set
14594         NEXT_AS_FIRST_DIRECTIVE_FOO_H.
14595         * lib/math.in.h: Use NEXT_AS_FIRST_DIRECTIVE_MATH_H instead of
14596         NEXT_MATH_H.
14597         * modules/math (Makefile.am): Substitute NEXT_AS_FIRST_DIRECTIVE_MATH_H
14598         instead of NEXT_MATH_H.
14599
14600 2009-05-21  Bruno Haible  <bruno@clisp.org>
14601
14602         Avoid redefinition warnings for SIZE_MAX.
14603         * m4/size_max.m4 (gl_SIZE_MAX): Avoid redefining SIZE_MAX in config.h.
14604         Reported by Simon Josefsson.
14605
14606 2009-05-21  Bruno Haible  <bruno@clisp.org>
14607
14608         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_CACHE_CHECK instead of
14609         AC_CACHE_VAL.
14610
14611 2009-05-20  Bruno Haible  <bruno@clisp.org>
14612
14613         Make zeroptr.h work on mingw.
14614         * tests/zerosize-ptr.h: Test for the presence of <sys/mman.h> and
14615         mprotect.
14616         * modules/memchr-tests (configure.ac): Also test for sys/mman.h.
14617         * modules/memchr2-tests (configure.ac): Likewise.
14618         * modules/memcmp-tests (configure.ac): Likewise.
14619         * modules/memmem-tests (configure.ac): Likewise.
14620         * modules/memrchr-tests (configure.ac): Likewise.
14621         Reported by Simon Josefsson.
14622
14623 2009-05-20  Simon Josefsson  <simon@josefsson.org>
14624
14625         * tests/test-glob.c: Include string.h for strcmp prototype.
14626
14627 2009-05-20  Simon Josefsson  <simon@josefsson.org>
14628
14629         * modules/getdelim (Depends-on): Add explicit stdint, although it
14630         was implicitly already pulled in via realloc-posix.
14631         * lib/getdelim.c: Get SIZE_MAX from stdint.h.
14632
14633 2009-05-20  Simon Josefsson  <simon@josefsson.org>
14634
14635         MinGW and IRIX does not have sa_family_t type.  Reported by "Tom
14636         G. Christensen" <tgc@jupiterrise.com>.
14637         * m4/sys_socket_h.m4: Check for sa_family_t.
14638         * lib/sys_socket.in.h: Typedef sa_family_t when needed.
14639         * modules/sys_socket: Substitute HAVE_SA_FAMILY_T.
14640         * tests/test-sys_socket.c: Check that sa_family_t works.
14641
14642 2009-05-18  Eric Blake  <ebb9@byu.net>
14643
14644         maint.mk: allow gnulib_dir in VPATH build
14645         * top/maint.mk (gnulib_dir): Make relative to $(srcdir).
14646
14647 2009-05-15  Jim Meyering  <meyering@redhat.com>
14648
14649         maint.mk: Give gnulib_dir a default definition.
14650         * top/maint.mk (gnulib_dir): Define to 'gnulib', by default.
14651         Thus, most packages no longer need to specify this variable in cfg.mk
14652
14653 2009-05-14  Tom Prince  <tom.prince@ualberta.net>  (tiny change)
14654
14655         rename.m4: fix typos that would make non-mingw cross-configure fail
14656         * m4/rename.m4 (gl_FUNC_RENAME): Fix typos.
14657
14658 2009-05-13  Eric Blake  <ebb9@byu.net>
14659
14660         mmap-anon: avoid out-of-order autoconf expansion
14661         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Use correct
14662         SYSTEM_EXTENSIONS macro to silence warnings from autoconf 2.63b.
14663         * modules/memchr-tests (Depends-on): Add extensions.
14664         * modules/memchr2-tests (Depends-on): Add extensions.
14665         * modules/memcmp-tests (Depends-on): Add extensions.
14666         * modules/memmem-tests (Depends-on): Add extensions.
14667         * modules/memrchr-tests (Depends-on): Add extensions.
14668
14669 2009-05-13  Bruno Haible  <bruno@clisp.org>
14670
14671         Make some tests ISO C 99 compliant.
14672         * tests/zerosize-ptr.h: New file.
14673         * tests/test-memchr.c: Include zerosize-ptr.h.
14674         (main): Use a zero-size object pointer instead of NULL.
14675         * tests/test-memchr2.c: Include zerosize-ptr.h.
14676         (main): Use a zero-size object pointer instead of NULL.
14677         * tests/test-memcmp.c: Include zerosize-ptr.h.
14678         (main): Use a zero-size object pointer instead of NULL.
14679         * tests/test-memmem.c: Include zerosize-ptr.h.
14680         (main): Use a zero-size object pointer instead of NULL.
14681         * tests/test-memrchr.c: Include zerosize-ptr.h.
14682         (main): Use a zero-size object pointer instead of NULL.
14683         * modules/memchr-tests (Files): Add tests/zerosize-ptr.h,
14684         m4/mmap-anon.m4.
14685         (Depends-on): Add getpagesize.
14686         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
14687         * modules/memchr2-tests (Files): Add tests/zerosize-ptr.h,
14688         m4/mmap-anon.m4.
14689         (Depends-on): Add getpagesize.
14690         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
14691         * modules/memcmp-tests (Files): Add tests/zerosize-ptr.h,
14692         m4/mmap-anon.m4.
14693         (Depends-on): Add getpagesize.
14694         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
14695         * modules/memmem-tests (Files): Add tests/zerosize-ptr.h,
14696         m4/mmap-anon.m4.
14697         (Depends-on): Add getpagesize.
14698         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
14699         * modules/memrchr-tests (Files): Add tests/zerosize-ptr.h,
14700         m4/mmap-anon.m4.
14701         (Depends-on): Add getpagesize.
14702         (configure.ac): Invoke gl_FUNC_MMAP_ANON. Check for mprotect.
14703
14704 2009-05-12  Bruno Haible  <bruno@clisp.org>
14705
14706         Tests for module 'alignof'.
14707         * modules/alignof-tests: New file.
14708         * tests/test-alignof.c: New file.
14709
14710 2009-05-12  Bruno Haible  <bruno@clisp.org>
14711
14712         Fix alignof macro.
14713         * lib/alignof.h (alignof): Remove special cases for AIX and HP-UX
14714         vendor compilers that are always correct.
14715
14716 2009-05-12  Bruno Haible  <bruno@clisp.org>
14717
14718         Make the MAP_ANONYMOUS detection work on HP-UX 11.
14719         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check whether mmap exists, but
14720         not whether its fully works.
14721
14722 2009-05-12  Bruno Haible  <bruno@clisp.org>
14723
14724         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Add comments.
14725
14726 2009-05-12  Jim Meyering  <meyering@redhat.com>
14727
14728         * top/maint.mk: Adjust backslash alignment.
14729
14730 2009-05-11  Simon Josefsson  <simon@josefsson.org>
14731
14732         * top/maint.mk: Make $(srcdir)/build-aux configurable.
14733
14734 2009-05-11  Eric Blake  <ebb9@byu.net>
14735
14736         argp: avoid undefined behavior
14737         * lib/argp-fmtstream.c (weak_alias): Pass correct types to ctype
14738         macros.
14739
14740 2009-05-08  Simon Josefsson  <simon@josefsson.org>
14741
14742         * tests/test-vc-list-files-git.sh: Do git config of user.email and
14743         user.name to prevent git commit from complaining.
14744
14745 2009-05-10  Bruno Haible  <bruno@clisp.org>
14746
14747         * gnulib-tool (func_import, func_create_testdir, copy-file): Change
14748         sed_rewrite_old_files, sed_rewrite_new_files, sed_rewrite_files so that
14749         it rewrites every file name only once.
14750         Reported by Simon Josefsson. Helped by Ralf Wildenhues.
14751
14752 2009-05-08  Bruno Haible  <bruno@clisp.org>
14753
14754         * lib/sys_socket.in.h (_SS_PADSIZE): Use a conditional expression
14755         instead of 'max'.
14756
14757 2009-05-08  Simon Josefsson  <simon@josefsson.org>
14758
14759         * m4/sys_socket_h.m4: Test for ws2tcpip.h earlier, needed for
14760         sockaddr_storage test.
14761
14762 2009-05-07  Simon Josefsson  <simon@josefsson.org>
14763
14764         * modules/sys_socket (Makefile.am): Substitute
14765         HAVE_STRUCT_SOCKADDR_STORAGE.  Depend on alignof.
14766         * m4/sys_socket_h.m4: Check for sockaddr_storage.
14767         * lib/sys_socket.in.h (sockaddr_storage): Define when needed.
14768         * tests/test-sys_socket.c: Check sockaddr_storage.
14769
14770 2009-05-08  Bruno Haible  <bruno@clisp.org>
14771
14772         New module 'alignof'.
14773         * lib/alignof.h: New file.
14774         * modules/alignof: New file.
14775
14776 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
14777             Bruno Haible  <bruno@clisp.org>
14778
14779         Fix test-file-has-acl on FreeBSD.
14780         * tests/test-file-has-acl.sh: Also test a directory. On FreeBSD, the
14781         mask is implicitly added.
14782         * tests/test-file-has-acl.c: Include <signal.h>.
14783         (main): Terminate the test after 5 seconds.
14784         * modules/acl-tests (configure.ac): Check for alarm function.
14785
14786 2009-05-04  Bruno Haible  <bruno@clisp.org>
14787
14788         Exploit new semantics of AC_DEFUN_ONCE available since 2009-01-26.
14789         * m4/errno_h.m4 (gl_HEADER_ERRNO_H): Remove outdated comment.
14790         * modules/errno (configure.ac): Drop AC_REQUIRE.
14791         * m4/multiarch.m4 (gl_MULTIARCH): Remove outdated comment.
14792         * modules/multiarch (configure.ac): Drop AC_REQUIRE.
14793
14794 2009-05-04  Simon Josefsson  <simon@josefsson.org>
14795
14796         * modules/glob-tests: New module.
14797         * tests/test-glob.c: Add.
14798
14799 2009-05-04  Simon Josefsson  <simon@josefsson.org>
14800
14801         * modules/fnmatch-tests: New module.
14802         * tests/test-fnmatch.c: Add.
14803
14804 2009-05-04  Eric Blake  <ebb9@byu.net>
14805
14806         maint: make the new no-submodule-changes rule VPATH-safe
14807         * top/maint.mk (no-submodule-changes): Don't assume a srcdir build.
14808
14809 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
14810             Bruno Haible  <bruno@clisp.org>
14811
14812         acl: Fix infinite loop on FreeBSD.
14813         * lib/acl_entries.c (acl_entries) [Linux, FreeBSD]: Fix interpretation
14814         of return value from acl_get_entry.
14815         * lib/file-has-acl.c (acl_access_nontrivial) [Linux, FreeBSD]:
14816         Likewise.
14817
14818 2009-05-03  Bruno Haible  <bruno@clisp.org>
14819
14820         * lib/acl-internal.h (acl_entries): Clarify return value.
14821         * lib/acl_entries.c (acl_entries): Likewise.
14822
14823 2009-05-04  David Bartley  <dtbartle@csclub.uwaterloo.ca>
14824
14825         Bug fix in acl module.
14826         * lib/set-mode-acl.c: Use correct struct with ACL_SETACL.
14827
14828 2009-05-03  Bruno Haible  <bruno@clisp.org>
14829
14830         Create gperf-generated file in the source dir, not in the build dir.
14831         * modules/iconv_open (iconv_open-aix.h, iconv_open-hpux.h,
14832         iconv_open-irix.h, iconv_open-osf.h): Create file in the source tree.
14833         * modules/unicase/locale-language (unicase/locale-languages.h):
14834         Likewise.
14835         * modules/unicase/special-casing (unicase/special-casing-table.h):
14836         Likewise.
14837         * modules/unictype/property-byname (unictype/pr_byname.h): Likewise.
14838         * modules/unictype/scripts (unictype/scripts_byname.h): Likewise.
14839         * modules/uninorm/composition (uninorm/composition-table.h): Likewise.
14840         Reported by Ralf Wildenhues.
14841
14842 2009-05-03  Bruno Haible  <bruno@clisp.org>
14843
14844         * modules/fnmatch (Description, configure.ac): Taken from
14845         fnmatch-posix.
14846         * modules/fnmatch-posix: Turn into a symbolic reference to the
14847         'fnmatch' module, and deprecate.
14848         * doc/posix-functions/fnmatch.texi: Mention the fnmatch module.
14849
14850 2009-05-03  Bruno Haible  <bruno@clisp.org>
14851
14852         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF,
14853         gl_PREREQ_VASNPRINTF_LONG_DOUBLE): Define through AC_DEFUN_ONCE.
14854         Reported by Ralf Wildenhues.
14855
14856 2009-05-04  Simon Josefsson  <simon@josefsson.org>
14857
14858         * m4/fnmatch.m4: Fix fnmatch re-define.
14859
14860 2009-04-27  David Bartley  <dtbartle@csclub.uwaterloo.ca>
14861
14862         priv-set: new module and tests; adapt write-any-file
14863         * lib/priv-set.c: New file.
14864         * lib/priv-set.h: New file.
14865         * lib/unlinkdir.c: Make cannot_unlink_dir thread-safe.
14866         * lib/write-any-file.c: Simplify by using priv-set module.
14867         * m4/priv-set.m4: New file.
14868         * modules/priv-set: New file.
14869         * modules/unlinkdir: Add dependency on priv-set module.
14870         * modules/write-any-file: Likewise.
14871
14872         Tests for module 'priv-set'.
14873         * modules/priv-set-tests: New file.
14874         * tests/test-priv-set.c: New file.
14875
14876 2009-05-03  Jim Meyering  <meyering@redhat.com>
14877             Bruno Haible  <bruno@clisp.org>
14878
14879         * lib/propername.c (proper_name_utf8): Ignore no-op translations;
14880         use the converted UTF-8 variant of the name instead.
14881
14882 2009-05-03  Jim Meyering  <meyering@redhat.com>
14883
14884         tests: tighten some getdate tests
14885         * tests/test-getdate.c (main): Tighten tests: require equality,
14886         not just greater than.  Set TZ envvar to UTC0.
14887
14888 2009-05-03  Giuseppe Scrivano  <gscrivano@gnu.org>
14889
14890         getdate: correctly interpret "next monday" when run on a Monday
14891         * lib/getdate.y (get_date): Correct the calculation of tm_mday so
14892         that e.g., "next tues" (when run on a tuesday) results in a date
14893         that is one week in the future, and not today's date.
14894         I.e., add a week when the wday is the same as the current one.
14895         Reported by Tom Broadhurst in http://savannah.gnu.org/bugs/?25406,
14896         and earlier by Martin Bernreuther and Jan Minář.
14897         * tests/test-getdate.c (main): Check that "next DAY" is always in
14898         the future and that "last DAY" is always in the past.
14899
14900 2009-05-02  Jim Meyering  <meyering@redhat.com>
14901
14902         build: ensure that a release build fails when a submodule is unclean
14903         * top/maint.mk (no-submodule-changes): New rule.
14904         (alpha beta major): Depend on it.
14905
14906 2009-05-02  Bruno Haible  <bruno@clisp.org>
14907
14908         Remove incompatibility between modules fnmatch-posix and fnmatch-gnu.
14909         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Use a
14910         shell variable gl_fnmatch_required to detect which variant is
14911         requested.
14912         (_AC_FUNC_FNMATCH_IF, _AC_LIBOBJ_FNMATCH): Remove macros. Inlined into
14913         gl_FUNC_FNMATCH_POSIX.
14914         * gnulib-tool (func_create_testdir, func_create_megatestdir): Don't
14915         exclude fnmatch-posix.
14916
14917 2009-05-02  Bruno Haible  <bruno@clisp.org>
14918
14919         Relicense mbsrtowcs and strnlen1 under LGPLv2+.
14920         * modules/mbsrtowcs (License): Change to LGPLv2+.
14921         * modules/strnlen1 (License): Likewise.
14922         Reported by Simon Josefsson.
14923
14924 2009-05-02  Bruno Haible  <bruno@clisp.org>
14925
14926         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Say "guessing no" instead of
14927         "cross".
14928         (gl_FUNC_FNMATCH_POSIX, gl_FUNC_FNMATCH_GNU): Update. Don't assume that
14929         gnulib-tool was called with option --source-base=lib.
14930
14931 2009-05-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14932
14933         Use automake *-local hooks without commands, for extensibility.
14934         * modules/localcharset (Makefile.am): Rename install-exec-local
14935         rule to install-exec-localcharset, and make it a prerequisite of
14936         install-exec-local.  Likewise, rename the uninstall-local rule to
14937         uninstall-localcharset, and make it a prerequisite of the former.
14938
14939 2009-05-01  Bruno Haible  <bruno@clisp.org>
14940
14941         * lib/wchar.in.h (wcsnrtombs): Define if REPLACE_WCSNRTOMBS is 1.
14942         * m4/wcsnrtombs.m4 (gl_FUNC_WCSRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
14943         set REPLACE_WCSNRTOMBS if mbstate_t must be replaced.
14944         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCSNRTOMBS.
14945         * modules/wchar (Makefile.am): Substitute REPLACE_WCSNRTOMBS.
14946         * modules/wcsnrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
14947         m4/locale-zh.m4, m4/codeset.m4.
14948
14949         * m4/wcsrtombs.m4 (gl_FUNC_WCSNRTOMBS): Invoke gl_MBSTATE_T_BROKEN, and
14950         set REPLACE_WCSRTOMBS if mbstate_t must be replaced.
14951         * modules/wcsrtombs (Files): Add m4/mbrtowc.m4, m4/locale-ja.m4,
14952         m4/locale-zh.m4.
14953
14954         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Invoke gl_MBSTATE_T_BROKEN, and set
14955         REPLACE_WCRTOMB if mbstate_t must be replaced.
14956         * modules/wcrtomb (Files): Add m4/mbrtowc.m4.
14957         Reported by Jens Rehsack <rehsack@googlemail.com> via Eric Blake.
14958
14959 2009-05-01  Bruno Haible  <bruno@clisp.org>
14960
14961         Avoid compiler warnings when redefining macros defined by <libintl.h>.
14962         * lib/gettext.h [!ENABLE_NLS] (gettext, dgettext, dcgettext, ngettext,
14963         dngettext, dcngettext, textdomain, bindtextdomain,
14964         bind_textdomain_codeset): Undefine before redefining.
14965
14966 2009-04-30  Bruno Haible  <bruno@clisp.org>
14967
14968         Fix bug introduced on 2009-04-25.
14969         * lib/math.in.h (gl_signbitf_OPTIMIZED_MACRO,
14970         gl_signbitd_OPTIMIZED_MACRO, gl_signbitl_OPTIMIZED_MACRO): New macros.
14971         * lib/signbitf.c (gl_signbitd): Undefine if gl_signbitf_OPTIMIZED_MACRO
14972         is defined.
14973         * lib/signbitd.c (gl_signbitd): Undefine if gl_signbitd_OPTIMIZED_MACRO
14974         is defined.
14975         * lib/signbitl.c (gl_signbitd): Undefine if gl_signbitl_OPTIMIZED_MACRO
14976         is defined.
14977         Reported by Elbert_Pol <elbert.pol@gmail.com>.
14978
14979 2009-04-28  Bruno Haible  <bruno@clisp.org>
14980
14981         Comment tweaks.
14982         * lib/unistr.h (u*_cmp2): Clarify what memcmp2 is.
14983         * lib/uninorm.h (u*_normxfrm): Fix description of return value.
14984         * lib/unicase.h (u*_casexfrm): Likewise.
14985         Reported by Paolo Bonzini.
14986
14987 2009-04-28  Bruno Haible  <bruno@clisp.org>
14988
14989         Fix a compilation error.
14990         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Fix initializer.
14991         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
14992         Reported by Jim Meyering.
14993
14994 2009-04-27  Bruno Haible  <bruno@clisp.org>
14995
14996         New module 'libunistring'.
14997         * modules/libunistring: New file.
14998         * m4/libunistring.m4: New file.
14999         * MODULES.html.sh (Unicode string functions): Add it.
15000
15001 2009-04-27  Eric Blake  <ebb9@byu.net>
15002
15003         maint.mk: allow package-specific header to provide <config.h>
15004         * top/maint.mk (sc_require_config_h): New variable.
15005         (sc_require_config_h, sc_require_config_h_first): Use it.
15006
15007 2009-04-27  Simon Josefsson  <simon@josefsson.org>
15008
15009         * top/maint.mk (sc_avoid_if_before_free): Except
15010         useless-if-before-free script.
15011
15012 2009-04-27  Eric Blake  <ebb9@byu.net>
15013
15014         maintainer-makefile: depend on all required helper scripts
15015         * modules/maintainer-makefile (Depends-on): Add vc-list-files and
15016         useless-if-before-free.
15017         * top/maint.mk (VC_LIST, sc_avoid_if_before_free): Use local
15018         version, rather than assuming gnulib checkout is available.
15019         Reported by Simen Josefsson.
15020
15021 2009-04-26  Bruno Haible  <bruno@clisp.org>
15022
15023         Make the lib vs. lib64 recognition work on openSUSE 11 with "gcc -m32".
15024         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): Ignore paths that end in
15025         "../" or "..".
15026
15027 2009-04-26  Bruno Haible  <bruno@clisp.org>
15028
15029         * m4/lib-link.m4 (AC_LIB_HAVE_LINKFLAGS): Accept a fifth argument.
15030         * m4/libsigsegv.m4 (gl_LIBSIGSEGV): Simplify by using
15031         AC_LIB_HAVE_LINKFLAGS.
15032
15033 2009-04-26  Bruno Haible  <bruno@clisp.org>
15034
15035         Simplify calling convention of u*_conv_from_encoding.
15036         * lib/uniconv.h (u8_conv_from_encoding, u16_conv_from_encoding,
15037         u32_conv_from_encoding): Expect a resultbuf argument and return the
15038         result directly as a pointer.
15039         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
15040         * lib/uniconv/u-conv-from-enc.h (FUNC): Likewise.
15041         * lib/uniconv/u-strconv-from-enc.h (FUNC): Update.
15042         * lib/unicase/ulc-casecmp.c (ulc_u8_casefold): Update.
15043         * lib/unicase/ulc-casexfrm.c (ulc_casexfrm): Update.
15044         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
15045         Update.
15046         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Update.
15047         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Update.
15048         * lib/vasnprintf.c (VASNPRINTF): Update.
15049         * tests/uniconv/test-u8-conv-from-enc.c (main): Update.
15050         * tests/uniconv/test-u16-conv-from-enc.c (main): Update.
15051         * tests/uniconv/test-u32-conv-from-enc.c (main): Update.
15052         * NEWS: Mention the change.
15053
15054 2009-04-26  Bruno Haible  <bruno@clisp.org>
15055
15056         Simplify calling convention of u*_conv_to_encoding.
15057         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
15058         u32_conv_to_encoding): Expect a resultbuf argument and return the
15059         result directly as a pointer.
15060         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
15061         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Preserve errno while
15062         freeing scaled_offsets if mem_iconveha failed.
15063         * lib/unicase/u-casexfrm.h (FUNC): Update.
15064         * lib/uninorm/u-normxfrm.h (FUNC): Update.
15065         * lib/vasnprintf.c (VASNPRINTF): Update.
15066         * tests/uniconv/test-u8-conv-to-enc.c (main): Update.
15067         * tests/uniconv/test-u16-conv-to-enc.c (main): Update.
15068         * tests/uniconv/test-u32-conv-to-enc.c (main): Update.
15069         * NEWS: Mention the change.
15070
15071 2009-04-26  Bruno Haible  <bruno@clisp.org>
15072
15073         Avoid test failures on AIX and OSF/1.
15074         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Avoid calling
15075         malloc(0).
15076         * lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
15077         * lib/unilbrk/ulc-possible-linebreaks.c (ulc_possible_linebreaks):
15078         Likewise.
15079         * lib/unilbrk/ulc-width-linebreaks.c (ulc_width_linebreaks): Likewise.
15080         * lib/uniwbrk/ulc-wordbreaks.c (ulc_wordbreaks): Likewise.
15081         * lib/uniconv/u-conv-to-enc.h (FUNC): Likewise. Fix memory leak.
15082         * lib/unistr/u-cpy-alloc.h (FUNC): Call malloc(1) instead of malloc(0).
15083         * doc/posix-functions/malloc.texi: Document the portability problem
15084         related to malloc(0).
15085
15086 2009-04-26  Bruno Haible  <bruno@clisp.org>
15087
15088         * modules/unistr/u8-cpy-alloc (Depends-on): Add malloc-posix.
15089         * modules/unistr/u16-cpy-alloc (Depends-on): Likewise.
15090         * modules/unistr/u32-cpy-alloc (Depends-on): Likewise.
15091
15092 2009-04-25  Bruno Haible  <bruno@clisp.org>
15093
15094         Avoid link error when creating a namespace clean library.
15095         * lib/math.in.h (gl_signbitf, gl_signbitd, gl_signbitl): Don't define
15096         as macro with arguments if already defined as an alias.
15097         * lib/signbitf.c (gl_signbitf): Don't undefine.
15098         * lib/signbitd.c (gl_signbitd): Don't undefine.
15099         * lib/signbitl.c (gl_signbitl): Don't undefine.
15100
15101 2009-04-25  Jim Meyering  <meyering@redhat.com>
15102
15103         vc-list-files: fix another quoting bug
15104         * build-aux/vc-list-files: Avoid sed backslash expansion
15105         of pathological directory names.
15106
15107 2009-04-25  Eric Blake  <ebb9@byu.net>
15108
15109         vc-list-files: fix shell quoting error
15110         * build-aux/vc-list-files: Protect against $ in $dir.  Normalize
15111         timestamp.
15112
15113 2009-04-25  Jim Meyering  <meyering@redhat.com>
15114
15115         vc-list-files: restore lost functionality with subdir argument
15116         * build-aux/vc-list-files: When given a non-"." sub-directory
15117         argument, substitute the $dir/ prefix back onto each resulting name.
15118         Otherwise, coreutils' root_tests check would fail.
15119
15120 2009-04-24  Eric Blake  <ebb9@byu.net>
15121
15122         vc-list-files: ignore git symlinks
15123         * build-aux/vc-list-files (.git): Use ls-tree and a filter, rather
15124         than ls-files, to ignore git symlinks.
15125
15126         maint.mk: import improvements from m4
15127         * top/maint.mk (VC-tag): Use signing key from cfg.mk.
15128         (move_if_change): Delete unused macro.
15129         (news-date-check, vc-diff-check): Support VPATH builds.
15130         (announcement): Likewise.  Split --bootstrap-tools list...
15131         (boostrap-tools): ...into separate list, which can be overridden
15132         in cfg.mk.
15133         (sc_avoid_if_before_free): Point to $(gnulib_dir), rather than
15134         requiring dependency on useless-if-before-free module.
15135         (VC_LIST, VC_LIST_EXCEPT): Likewise for vc-list-files module.
15136         Support VPATH builds.
15137
15138 2009-04-24  Jim Meyering  <meyering@redhat.com>
15139
15140         maint.mk: remove coreutils-specific rules and variables
15141         * top/maint.mk (bin, taint-distcheck, coreutils-path-check, t): Remove.
15142         (fake_home, install-transform-check, my-instcheck, pfx, TMPDIR): Remove.
15143         (t_prefix, t_taint, tp, warn_cflags, write_loser, my-distcheck): Remove.
15144
15145         maint.mk: remove obsolete rule
15146         * top/maint.mk (rel-check): Remove rule.
15147         (WGET, WGETFLAGS): Remove now-unused variables.
15148
15149 2009-04-24  Simon Josefsson  <simon@josefsson.org>
15150
15151         * top/maint.mk (makefile-check): Renamed to sc_makefile_check for
15152         consistency.
15153
15154         * modules/vc-list-files-tests (TESTS_ENVIRONMENT): Use
15155         '$(PATH_SEPARATOR)' instead of ':'.
15156
15157 2009-04-24  Simon Josefsson  <simon@josefsson.org>
15158
15159         * lib/getopt1.c (main): Use 'const' for static array.
15160
15161 2009-04-24  Simon Josefsson  <simon@josefsson.org>
15162
15163         * top/maint.mk: Sync with coreutils.
15164         * NEWS: Explain incompatibilities.
15165
15166 2009-04-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
15167             Bruno Haible  <bruno@clisp.org>
15168
15169         Fix cross-compilation results.
15170         * m4/btowc.m4 (gl_FUNC_BTOWC): Use no-op statement, rather than empty
15171         statement, as third argument of AC_TRY_RUN.
15172         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE, gl_MBRTOWC_SANITYCHECK,
15173         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL):
15174         Likewise.
15175         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): Likewise.
15176         * m4/wcsrtombs.m4 (gl_WCSRTOMBS_TERMINATION, gl_WCSRTOMBS_NULL):
15177         Likewise.
15178         * m4/wctob.m4 (gl_FUNC_WCTOB): Likewise.
15179         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Likewise. Update for AIX 4.3.
15180         * doc/posix-functions/wcrtomb.texi: Mention the bug on AIX 4.3.
15181
15182 2009-04-20  Bruno Haible  <bruno@clisp.org>
15183
15184         Avoid test failure on mingw.
15185         * tests/uniwidth/test-uc_width2.sh: Convert newlines in output.
15186
15187 2009-04-20  Bruno Haible  <bruno@clisp.org>
15188
15189         Avoid compilation error on mingw.
15190         * modules/localename-tests (Depends-on): Add locale.
15191
15192 2009-04-19  Bruno Haible  <bruno@clisp.org>
15193
15194         Support for building a shared library on Windows platforms.
15195         * tests/uninorm/test-nfc.c (n): Don't define if WOE32DLL.
15196         (main): Test the presence of UNINORM_NFC here.
15197         * tests/uninorm/test-nfd.c (n): Don't define if WOE32DLL.
15198         (main): Test the presence of UNINORM_NFD here.
15199         * tests/uninorm/test-nfkc.c (n): Don't define if WOE32DLL.
15200         (main): Test the presence of UNINORM_NFKC here.
15201         * tests/uninorm/test-nfkd.c (n): Don't define if WOE32DLL.
15202         (main): Test the presence of UNINORM_NFKD here.
15203
15204 2009-04-19  Bruno Haible  <bruno@clisp.org>
15205
15206         Avoid a compiler warning.
15207         * tests/uninorm/test-u32-normalize-big.c (read_normalization_test_file):
15208         Change type of variable 'sequence'.
15209
15210 2009-04-19  Bruno Haible  <bruno@clisp.org>
15211
15212         * modules/configmake (Makefile.am): When the contents of configmake.h
15213         does not change, arrange to preserve its modification time.
15214
15215 2009-04-17  Simon Josefsson  <simon@josefsson.org>
15216
15217         * top/maint.mk (PO_DOMAIN): New variable, allows overriding of
15218         gettext domain.
15219
15220 2009-04-16  Jim Meyering  <meyering@redhat.com>
15221
15222         useless-if-before-free: improve conversion code
15223         * build-aux/useless-if-before-free: Adjust code-in-comment to match
15224         "...!= 0" as well as "...!= NULL".  emacs has one of the former.
15225
15226 2009-04-14  Bruno Haible  <bruno@clisp.org>
15227
15228         * modules/fcntl (Depends-on): Add extensions.
15229         * m4/fcntl_h.m4 (gl_FCNTL_H): Add a comment.
15230
15231 2009-04-12  Ben Pfaff  <blp@gnu.org>
15232
15233         Make fcntl module detect O_NOATIME, O_NOFOLLOW on GNU/Linux.
15234         * m4/fcntl_h.m4 (gl_FCNTL_H): Require AC_USE_SYSTEM_EXTENSIONS.
15235
15236 2009-03-20  Ben Pfaff  <blp@gnu.org>
15237
15238         Make rename replace existing destinations on Windows.
15239         * m4/rename.m4: Add test for Mingw.
15240         * lib/rename.c: Add rename replacement that uses MoveFileEx with
15241         MOVEFILE_REPLACE_EXISTING to replace existing destination files.
15242         * doc/posix-functions/rename.texi: Document.
15243
15244 2009-04-10  Bruno Haible  <bruno@clisp.org>
15245
15246         New include file "iconveh.h".
15247         * lib/iconveh.h: New file, extracted from lib/striconveh.h.
15248         * lib/striconveh.h: Include it.
15249         (enum iconv_ilseq_handler): Remove definition.
15250         * lib/striconveha.h: Include <stddef.h> and iconveh.h instead of
15251         striconveh.h.
15252         * lib/striconveha.c: Include striconveh.h.
15253         * lib/uniconv.h: Include iconveh.h instead of striconveh.h.
15254         * modules/striconveh (Files): Add lib/iconveh.h.
15255         * modules/uniconv/base (Files): Add lib/iconveh.h. Remove
15256         lib/striconveh.h.
15257
15258 2009-04-10  Bruno Haible  <bruno@clisp.org>
15259
15260         * lib/uniconv.h: Update comment.
15261
15262 2009-04-10  Bruno Haible  <bruno@clisp.org>
15263
15264         * lib/unistr/u8-mbtouc-aux.c: Inside libunistring, define the function
15265         always.
15266         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
15267         * lib/unistr/u16-mbtouc-aux.c: Likewise.
15268         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
15269         * lib/unistr/u8-mbtouc.c: Inside libunistring, include
15270         "unistring-notinline.h", so that the function gets defined always.
15271         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
15272         * lib/unistr/u8-uctomb.c: Likewise.
15273         * lib/unistr/u16-mbtouc.c: Likewise.
15274         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
15275         * lib/unistr/u16-uctomb.c: Likewise.
15276         * lib/unistr/u32-mbtouc.c: Likewise.
15277         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
15278         * lib/unistr/u32-uctomb.c: Likewise.
15279
15280 2009-04-10  Bruno Haible  <bruno@clisp.org>
15281
15282         Mark 'utime' obsolete.
15283         * modules/utime (Status, Notice): New sections.
15284         Suggested by Jim Meyering.
15285
15286         Fix cross-compile guess for utime test.
15287         * m4/utime.m4 (AC_FUNC_UTIME_NULL): Add definition from newest unstable
15288         autoconf.
15289         * doc/posix-functions/utime.texi: Give more precisions.
15290         Reported by Jan <ipif@ymail.com>.
15291
15292 2009-04-09  Kamil Dudka  <kdudka@redhat.com>
15293
15294         filevercmp: correct today's change
15295         * lib/filevercmp.c: Also handle coreutils' test inputs.
15296         * tests/test-filevercmp.c: Add inputs from one of coreutils' test scripts.
15297
15298         Fix regression in 'filevercmp' module. Thanks Sven Joachim
15299         for reporting it.
15300         * lib/filevercmp.c: Special handle for "", "." and "..".
15301         * tests/test-filevercmp.c: Enlarge the set suite.
15302
15303 2009-04-07  Jim Meyering  <meyering@redhat.com>
15304
15305         useless-if-before-free: show how to remove braced useless free, too
15306         * build-aux/useless-if-before-free: still only in a comment, though.
15307
15308 2009-04-07  Reuben Thomas  <rrt@sc3d.org>
15309
15310         maint.mk: import changes to syntax-check macros from coreutils
15311         * top/maint.mk (_prohibit_regexp, _header_without_use): Define.
15312         Use them in the relevant macros.
15313
15314 2009-04-06  Bruno Haible  <bruno@clisp.org>
15315
15316         Fix unportable use of bit-fields.
15317         * lib/unicase/special-casing.h (struct special_casing_rule): Change the
15318         bit-field type from 'int' to 'signed int'. Otherwise Solaris cc,
15319         AIX xlc, and OSF/1 cc interpret it as 'unsigned int'.
15320
15321 2009-04-06  Bruno Haible  <bruno@clisp.org>
15322
15323         Avoid test failures on AIX and OSF/1.
15324         * tests/unicase/test-u8-casefold.c (check): Account for the possibility
15325         that malloc(0) = NULL.
15326         * tests/unicase/test-u8-tolower.c (check): Likewise.
15327         * tests/unicase/test-u8-totitle.c (check): Likewise.
15328         * tests/unicase/test-u8-toupper.c (check): Likewise.
15329         * tests/unicase/test-u16-casefold.c (check): Likewise.
15330         * tests/unicase/test-u16-tolower.c (check): Likewise.
15331         * tests/unicase/test-u16-totitle.c (check): Likewise.
15332         * tests/unicase/test-u16-toupper.c (check): Likewise.
15333         * tests/unicase/test-u32-casefold.c (check): Likewise.
15334         * tests/unicase/test-u32-tolower.c (check): Likewise.
15335         * tests/unicase/test-u32-totitle.c (check): Likewise.
15336         * tests/unicase/test-u32-toupper.c (check): Likewise.
15337         * tests/uninorm/test-u8-nfc.c (check): Likewise.
15338         * tests/uninorm/test-u8-nfd.c (check): Likewise.
15339         * tests/uninorm/test-u8-nfkc.c (check): Likewise.
15340         * tests/uninorm/test-u8-nfkd.c (check): Likewise.
15341         * tests/uninorm/test-u16-nfc.c (check): Likewise.
15342         * tests/uninorm/test-u16-nfd.c (check): Likewise.
15343         * tests/uninorm/test-u16-nfkc.c (check): Likewise.
15344         * tests/uninorm/test-u16-nfkd.c (check): Likewise.
15345         * tests/uninorm/test-u32-nfc.c (check): Likewise.
15346         * tests/uninorm/test-u32-nfd.c (check): Likewise.
15347         * tests/uninorm/test-u32-nfkc.c (check): Likewise.
15348         * tests/uninorm/test-u32-nfkd.c (check): Likewise.
15349
15350 2009-04-05  Bruno Haible  <bruno@clisp.org>
15351
15352         Work around an autoconf limitation.
15353         * gnulib-tool (func_emit_lib_Makefile_am): Omit the "Reproduce by"
15354         comment line if it would be longer than 3 KB.
15355
15356 2009-04-05  Bruno Haible  <bruno@clisp.org>
15357
15358         Avoid test failure with libiconv-1.13.
15359         * tests/test-striconveh.c (main): Allow result of libiconv 1.13 as one
15360         of the expected test results.
15361
15362 2009-04-05  Bruno Haible  <bruno@clisp.org>
15363
15364         * gnulib-tool (func_emit_lib_Makefile_am): Don't add the library to
15365         noinst_LTLIBRARIES if the Makefile.am in the same directory specifies
15366         that it should be installed.
15367
15368 2009-04-05  Bruno Haible  <bruno@clisp.org>
15369
15370         * gnulib-tool: New option --copy-file.
15371         (func_usage): Document it.
15372         (func_dest_tmpfilename): Moved out of func_import.
15373         (func_add_file, func_update_file): New functions, extracted from
15374         func_import.
15375         (func_import): Update.
15376
15377 2009-04-05  Karl Berry  <karl@gnu.org>
15378
15379         * README: prominently mention gnulib-tool.
15380         Rearrange sections so getting the code is near the top.
15381
15382 2009-04-05  Bruno Haible  <bruno@clisp.org>
15383
15384         * lib/unicase.h: Mention u*_cmp2.
15385         * lib/unicase/u-casecmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
15386         * lib/unicase/u8-casecmp.c: Use u8_cmp2 instead of u8_cmp.
15387         * lib/unicase/ulc-casecmp.c: Likewise.
15388         * lib/unicase/u16-casecmp.c: Use u16_cmp2 instead of u16_cmp.
15389         * lib/unicase/u32-casecmp.c: Use u32_cmp2 instead of u32_cmp.
15390         * modules/unicase/u8-casecmp (Depends-on): Add unistr/u8-cmp2, remove
15391         unistr/u8-cmp.
15392         * modules/unicase/ulc-casecmp (Depends-on): Likewise.
15393         * modules/unicase/u16-casecmp (Depends-on): Add unistr/u16-cmp2, remove
15394         unistr/u16-cmp.
15395         * modules/unicase/u32-casecmp (Depends-on): Add unistr/u32-cmp2, remove
15396         unistr/u32-cmp.
15397
15398         * lib/uninorm.h: Mention u*_cmp2.
15399         * lib/uninorm/u-normcmp.h (FUNC): Invoke U_CMP2 instead of U_CMP.
15400         * lib/uninorm/u8-normcmp.c: Use u8_cmp2 instead of u8_cmp.
15401         * lib/uninorm/u16-normcmp.c: Use u16_cmp2 instead of u16_cmp.
15402         * lib/uninorm/u32-normcmp.c: Use u32_cmp2 instead of u32_cmp.
15403         * modules/uninorm/u8-normcmp (Depends-on): Add unistr/u8-cmp2, remove
15404         unistr/u8-cmp.
15405         * modules/uninorm/u16-normcmp (Depends-on): Add unistr/u16-cmp2, remove
15406         unistr/u16-cmp.
15407         * modules/uninorm/u32-normcmp (Depends-on): Add unistr/u32-cmp2, remove
15408         unistr/u32-cmp.
15409
15410         New module 'unistr/u32-cmp2'.
15411         * lib/unistr/u32-cmp2.c: New file.
15412         * modules/unistr/u32-cmp2: New file.
15413
15414         New module 'unistr/u16-cmp2'.
15415         * lib/unistr/u16-cmp2.c: New file.
15416         * modules/unistr/u16-cmp2: New file.
15417
15418         New module 'unistr/u8-cmp2'.
15419         * lib/unistr.h (u8_cmp2, u16_cmp2, u32_cmp2): New declarations.
15420         * lib/unistr/u8-cmp2.c: New file.
15421         * lib/unistr/u-cmp2.h: New file.
15422         * modules/unistr/u8-cmp2: New file.
15423
15424 2009-04-05  Bruno Haible  <bruno@clisp.org>
15425
15426         * lib/unictype.h (uc_property_is_valid): New macro.
15427         * tests/unictype/test-pr_byname.c (main): Use it.
15428
15429         * lib/unistr.h: Doc fixes.
15430         * lib/uniconv.h: Doc fixes.
15431         * lib/unictype.h: Doc fixes.
15432
15433 2009-04-03  Paul Eggert  <eggert@cs.ucla.edu>
15434
15435         Port coreutils 7.2 to Solaris 8.
15436
15437         * modules/arpa_inet (arpa/inet.h): Depend on arpa_inet.in.h.
15438         * m4/inet_ntop.m4 (gl_INET_NTOP): Search for inet_ntop in -lnsl,
15439         for Solaris 8.  This is a bit of a hack, as it means it's the
15440         caller's responsibility to add -lnsl if needed, but most likely it
15441         won't be needed since only getaddrinfo uses this and getaddrinfo
15442         isn't needed on Solaris 8.
15443
15444         * modules/fnmatch (Depends-on): Add mbsrtowcs, to fix a porting
15445         problem to Solaris 8 encountered with coreutils 7.2, which
15446         resulted in a message "fnmatch.c:292: warning: passing argument 4
15447         of 'mbsrtowcs' from incompatible pointer type".  Also, add mbsinit
15448         at the suggestion of Bruno Haible, since fnmatch uses mbsinit.
15449
15450 2009-04-03  Simon Josefsson  <simon@josefsson.org>
15451
15452         * m4/ld-version-script.m4: Add FIXME comment.
15453
15454 2009-04-02  Simon Josefsson  <simon@josefsson.org>
15455
15456         * doc/ld-output-def.texi: Use DLL_VERSION instead of confusing
15457         SOVERSION variable.
15458
15459 2009-04-02  Bruno Haible  <bruno@clisp.org>
15460
15461         * Makefile (info, html, dvi, pdf): Combine the rules.
15462         Suggested by Jim Meyering.
15463
15464 2009-04-01  Bruno Haible  <bruno@clisp.org>
15465
15466         * Makefile (info, html, dvi, pdf): New targets.
15467         Reported by Reuben Thomas <rrt@sc3d.org>.
15468
15469 2009-04-01  Bruno Haible  <bruno@clisp.org>
15470
15471         * doc/gnulib-tool.texi (Invoking gnulib-tool): Document how gnulib-tool
15472         can be put into PATH.
15473         Reported by Reuben Thomas <rrt@sc3d.org>. Suggested by Karl Berry.
15474
15475 2009-04-01  Bruno Haible  <bruno@clisp.org>
15476
15477         * doc/lib-symbol-visibility.texi: Follow texinfo style conventions.
15478
15479 2009-04-01  Bruno Haible  <bruno@clisp.org>
15480
15481         Rename module 'visibility'.
15482         * modules/lib-symbol-visibility: Renamed from modules/visibility.
15483         * doc/lib-symbol-visibility.texi: Renamed from visibility.texi.
15484         * doc/gnulib.texi: Update.
15485         * MODULES.html.sh (Misc): Update.
15486         * NEWS: Mention the change.
15487
15488 2009-04-01  Simon Josefsson  <simon@josefsson.org>
15489
15490         * modules/lib-msvc-compat: New module.  Thanks to Bruno Haible
15491         <bruno@clisp.org>, Ralf Wildenhues <Ralf.Wildenhues@gmx.de>, and
15492         Eric Blake <ebb9@byu.net> for review.
15493         * MODULES.html.sh: Add lib-msvc-compat.
15494         * doc/gnulib.texi: Link to new section.
15495         * m4/ld-output-def.m4: New file.
15496         * doc/ld-output-def.texi: New file.
15497
15498 2009-04-01  Simon Josefsson  <simon@josefsson.org>
15499
15500         Rename ld-version-script to lib-symbol-versions.  Suggested by
15501         Bruno Haible <bruno@clisp.org>.
15502         * modules/ld-version-script: Renamed to lib-symbol-versions.
15503         * doc/ld-version-script.texi: Fix module name.
15504         * MODULES.html.sh: Add lib-symbol-versions.
15505
15506 2009-03-31  Simon Josefsson  <simon@josefsson.org>
15507
15508         * modules/u64-tests: New file.
15509         * tests/test-u64.c: New file.
15510
15511 2009-03-04  Simon Josefsson  <simon@josefsson.org>
15512
15513         * MODULES.html.sh: Mention u64.
15514         * modules/u64: New module.
15515         * modules/crypto/sha512: Depend on u64 module instead of providing
15516         u64.h.
15517
15518 2009-03-27  Eric Blake  <ebb9@byu.net>
15519
15520         test-strerror: make debugging EAI_SYSTEM easier
15521         * modules/getaddrinfo-tests (Depends-on): Add strerror.
15522         * test-getaddrinfo.c (simple) [ENABLE_DEBUGGING]: Report errno if
15523         failure was EAI_SYSTEM.
15524
15525 2009-03-25  Bruno Haible  <bruno@clisp.org>
15526
15527         Fix a problem with --enable-relocatable on Solaris 7.
15528         * modules/relocatable-prog-wrapper (Depends-on): Add environ. Needed
15529         since 2008-02-24.
15530
15531 2009-03-25  Eric Blake  <ebb9@byu.net>
15532
15533         test-sockets: avoid gcc warning
15534         * tests/test-sockets.c (main): Silence compiler warning.
15535
15536 2009-03-25  Paul Eggert  <eggert@cs.ucla.edu>
15537
15538         New modules nproc, pthread, contributed by Glen Lenker.
15539
15540         * MODULES.html.sh: Add pthread, nproc.
15541         * lib/nproc.c: New file.
15542         * lib/nproc.h: New file.
15543         * lib/pthread.in.h: New file.
15544         * m4/pthread.m4: New file.
15545         * modules/nproc: New file.
15546         * modules/pthread: New file.
15547
15548 2009-03-24  Simon Josefsson  <simon@josefsson.org>
15549
15550         * modules/unicase/locale-language-tests (test_locale_language_LDADD):
15551         New variable.
15552
15553 2009-03-24  Kamil Dudka  <kdudka@redhat.com>
15554
15555         filevercmp: handle simple~ and numbered.~3~ backup suffixes
15556         * lib/filevercmp.c: Handle simple~ and numbered.~3~ backup suffixes.
15557         * tests/test-filevercmp.c: Add tests for backup suffixes.
15558
15559 2009-03-24  Simon Josefsson  <simon@josefsson.org>
15560
15561         * modules/stdlib (Depends-on): Add stdint, needed when defining
15562         struct random_data on, for example, HP-UX 10.20.  Reported by
15563         Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
15564
15565 2009-03-24  Simon Josefsson  <simon@josefsson.org>
15566
15567         * lib/readline.c (readline): Call fflush on stdout after printing
15568         prompt.
15569
15570 2009-03-20  Bruno Haible  <bruno@clisp.org>
15571
15572         Remove dependency from 'close' module to -lws2_32 on native Windows.
15573         * lib/close-hook.h: New file.
15574         * lib/close-hook.c: New file.
15575         * lib/close.c: Include close-hook.h. Don't include <sys/socket.h>,
15576         w32sock.h.
15577         (_gl_close_fd_maybe_socket): Remove function.
15578         (rpl_close): Invoke execute_all_close_hooks instead of
15579         _gl_close_fd_maybe_socket.
15580         * lib/sockets.c: Include close-hook.h, w32sock.h.
15581         (close_fd_maybe_socket): New function, essentially from lib/close.c.
15582         (close_sockets_hook): New variable.
15583         (gl_sockets_startup): Register close_fd_maybe_socket as a hook.
15584         (gl_sockets_cleanup): Unregister it.
15585         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): Remove macro.
15586         * m4/close.m4 (gl_REPLACE_CLOSE): Undo 2009-02-05 change.
15587         * modules/close-hook: New file.
15588         * modules/close (Files): Remove lib/w32sock.h.
15589         (Depends-on): Add close-hook.
15590         (Link): Remove section.
15591         * modules/sockets (Files): Add lib/w32sock.h.
15592         (Depends-on): Add close-hook.
15593         * modules/sys_socket (configure.ac): Remove gl_MODULE_INDICATOR
15594         invocation.
15595         * NEWS: Mention that LIB_CLOSE is gone.
15596
15597 2009-03-23  Eric Blake  <ebb9@byu.net>
15598
15599         signal-tests: test previous patch
15600         * tests/test-signal.c: New file.
15601         * modules/signal-tests: Likewise.
15602
15603         signal.h: always support 'volatile sig_atomic_t'
15604         * m4/signal_h.m4 (gl_SIGNAL_H): Check for AIX limitation.
15605         (gl_SIGNAL_H_DEFAULTS): Add a default.
15606         * modules/signal (Makefile.am): Substitute if needed.
15607         * lib/signal.in.h (sig_atomic_t): Redefine if needed, so that
15608         users can blindly add volatile.
15609         * doc/posix-headers/signal.texi (signal.h): Document it.
15610         Reported by Matthew Woehlke.
15611
15612 2009-03-23  Jim Meyering  <meyering@redhat.com>
15613
15614         pathmax: PATH_MAX: use pathconf only when available
15615         * lib/pathmax.h (PATH_MAX): Select the pathconf-using definition
15616         only if HAVE_PATHCONF is defined.  Patch by Sylvain Beucler.
15617         * m4/pathmax.m4 (gl_PATHMAX): Check for pathconf.
15618         This avoids a link failure in a PSP cross-compilation environment
15619         described in http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/17048
15620
15621         * lib/vasnprintf.c (divide): Fix typo in comment.
15622
15623 2009-03-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15624
15625         * gnulib-tool (func_filter_filelist): Fix comment.
15626
15627 2009-03-20  Bruno Haible  <bruno@clisp.org>
15628
15629         Make sockets.h self-contained.
15630         * lib/sockets.c: Include sockets.h first.
15631         * lib/sockets.h: Include <sys/socket.h> before using the SOCKET type.
15632
15633 2009-03-19  Eric Blake  <ebb9@byu.net>
15634
15635         doc: mention more functions added in cygwin 1.7.0
15636         * doc/posix-functions/log2.texi: Mention recent cygwin 1.7.0
15637         addition.
15638         * doc/posix-functions/log2f.texi: Likewise.
15639
15640 2009-03-19  Jim Meyering  <meyering@redhat.com>
15641
15642         fsusage: avoid syntax error due to statement-before-declaration
15643         * lib/fsusage.c (get_fs_usage): Put warning-avoidance statement
15644         after all declarations.  Reported by Matthew Woehlke in
15645         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/16231
15646
15647 2009-03-18  Eric Blake  <ebb9@byu.net>
15648
15649         build-aux/compile: sync from automake
15650         * build-aux/compile: New file, from automake.
15651         * config/srclist.txt: Mention build-aux/compile.
15652
15653 2009-03-17  Bruno Haible  <bruno@clisp.org>
15654
15655         * lib/git-merge-changelog.c: Fix typo in comment.
15656         Reported by Reuben Thomas <rrt@sc3d.org>.
15657
15658 2009-03-17  Reuben Thomas  <rrt@sc3d.org>
15659
15660         * m4/regex.m4: update and improve help for
15661         --without-included-regex.
15662
15663 2009-03-17  Simon Josefsson  <simon@josefsson.org>
15664
15665         * modules/isnanl-nolibm-tests (Files): Add tests/nan.h to avoid
15666         failure on missing include files.
15667
15668 2009-03-17  Eric Blake  <ebb9@byu.net>
15669
15670         doc: mention more functions added in cygwin 1.7.0
15671         * doc/posix-functions/fwprintf.texi: Mention recent cygwin 1.7.0
15672         addition.
15673         * doc/posix-functions/fwscanf.texi: Likewise.
15674         * doc/posix-functions/swprintf.texi: Likewise.
15675         * doc/posix-functions/swscanf.texi: Likewise.
15676         * doc/posix-functions/vfwprintf.texi: Likewise.
15677         * doc/posix-functions/vfwscanf.texi: Likewise.
15678         * doc/posix-functions/vswprintf.texi: Likewise.
15679         * doc/posix-functions/vswscanf.texi: Likewise.
15680         * doc/posix-functions/vwprintf.texi: Likewise.
15681         * doc/posix-functions/vwscanf.texi: Likewise.
15682         * doc/posix-functions/wcscasecmp.texi: Likewise.
15683         * doc/posix-functions/wcsdup.texi: Likewise.
15684         * doc/posix-functions/wcsftime.texi: Likewise.
15685         * doc/posix-functions/wcsncasecmp.texi: Likewise.
15686         * doc/posix-functions/wprintf.texi: Likewise.
15687         * doc/posix-functions/wscanf.texi: Likewise.
15688         * doc/glibc-functions/gethostbyname2.texi: Likewise.
15689
15690 2009-03-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15691
15692         maint.mk: really add $(AM_MAKEFLAGS)
15693         * top/maint.mk (init-coverage, build-coverage): `$(AM_MAKEFLAGS)'
15694         was inadvertently omitted in the last commit.
15695         Spotted by Bruno Haible.
15696
15697         maint.mk: use $(MAKE) $(AM_MAKEFLAGS) not make
15698         * top/maint.mk (init-coverage, build-coverage): Use `$(MAKE)
15699         $(AM_MAKEFLAGS)' rather than plain `make'.
15700
15701         gnulib-tool: execute $MAKE not make
15702         * gnulib-tool: Default $MAKE to 'make'.
15703         (func_create_testdir, func_create_megatestdir): Use $MAKE rather
15704         than make.  Initialize $MAKE in the do-autobuild script.
15705
15706         gnulib-tool: use $MAKE not make in generated files
15707         * gnulib-tool (func_create_megatestdir): Use $MAKE rather than
15708         make, in generated files.  Initialize $MAKE in the do-autobuild
15709         script.
15710
15711         * top/GNUmakefile (_have-git-version-gen): Fix typo.
15712
15713         GNUmakefile: disable parallelism only for multiple, recursive targets
15714         * top/GNUmakefile (ALL_RECURSIVE_TARGETS): New macro; allow user
15715         additions in the Makefile.
15716         (AM_RECURSIVE_TARGETS): New macro, override only if not provided
15717         by Automake.
15718         (.NOTPARALLEL): Only disable parallel builds if multiple targets
15719         are listed on the command line and at least one of them is
15720         listed in $(ALL_RECURSIVE_TARGETS).
15721
15722 2009-03-14  Bruno Haible  <bruno@clisp.org>
15723
15724         * modules/unilbrk/u8-possible-linebreaks (Depends-on): Replace
15725         utf8-ucs4-unsafe with unistr/u8-mbtouc-unsafe.
15726         * modules/unilbrk/u8-width-linebreaks (Depends-on): Likewise.
15727         * modules/unilbrk/u16-possible-linebreaks (Depends-on): Replace
15728         utf16-ucs4-unsafe with unistr/u16-mbtouc-unsafe.
15729         * modules/unilbrk/u16-width-linebreaks (Depends-on): Likewise.
15730         * modules/unistr/u8-chr (Depends-on): Replace ucs4-utf8 with
15731         unistr/u8-uctomb.
15732         * modules/unistr/u8-strchr (Depends-on): Likewise.
15733         * modules/unistr/u8-strrchr (Depends-on): Likewise.
15734         * modules/unistr/u16-chr (Depends-on): Replace ucs4-utf16 with
15735         unistr/u16-uctomb.
15736         * modules/unistr/u16-strchr (Depends-on): Likewise.
15737         * modules/unistr/u16-strrchr (Depends-on): Likewise.
15738
15739 2009-03-12  Bruno Haible  <bruno@clisp.org>
15740
15741         Work around select() bug on Interix 3.5.
15742         * lib/sys_select.in.h (select): Also replace if REPLACE_SELECT is 1.
15743         * lib/select.c (rpl_select): Add an implementation for Unix platforms.
15744         * m4/select.m4: New file.
15745         * m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Initialize REPLACE_SELECT.
15746         * modules/sys_select (Makefile.am): Substitute REPLACE_SELECT.
15747         * modules/select (Files): Add m4/select.m4.
15748         (configure.ac): Move conditional to m4/select.m4. Invoke gl_FUNC_SELECT.
15749         * modules/nanosleep (Depends-on): Add select.
15750         * modules/poll (Depends-on): Likewise.
15751         * doc/posix-functions/select.texi: Mention the Interix bug.
15752         Reported by Markus Duft <mduft@gentoo.org>.
15753
15754         * lib/select.c: Renamed from lib/winsock-select.c.
15755         * modules/select (Files): Add lib/select.c, remove
15756         lib/winsock-select.c.
15757         (configure.ac): Update.
15758
15759 2009-03-12  Jim Meyering  <meyering@redhat.com>
15760
15761         avoid gcc warnings about unused macro definitions
15762         * lib/readtokens.c (STREQ): Remove unused definition.
15763         * lib/xmalloc.c (SIZE_MAX): Likewise.
15764         * lib/openat-die.c (N_): Likewise.
15765         * lib/mountlist.c (SIZE_MAX): Remove definition.
15766         Instead, include <stdint.h>.
15767         * lib/readutmp.c: Likewise.
15768         * modules/readutmp (Depends-on): Add stdint.
15769         * modules/mountlist (Depends-on): Add stdint.
15770         * lib/userspec.c (ISDIGIT): Move definition into #if block where used.
15771
15772 2009-03-10  Bruno Haible  <bruno@clisp.org>
15773
15774         Tests for module 'mbmemcasecoll'.
15775         * modules/mbmemcasecoll-tests: New file.
15776         * tests/test-mbmemcasecoll1.sh: New file.
15777         * tests/test-mbmemcasecoll2.sh: New file.
15778         * tests/test-mbmemcasecoll3.sh: New file.
15779         * tests/test-mbmemcasecoll.c: New file.
15780
15781         New module 'mbmemcasecoll'.
15782         * lib/mbmemcasecoll.h: New file.
15783         * lib/mbmemcasecoll.c: New file.
15784         * modules/mbmemcasecoll: New file.
15785
15786         * tests/test-mbmemcasecmp.h: New file, extracted from
15787         tests/test-mbmemcasecmp.c.
15788         * tests/test-mbmemcasecmp.c: Include test-mbmemcasecmp.h.
15789         (test_ascii, test_iso_8859_1, test_utf_8): Remove functions.
15790         (main): Update.
15791         * modules/mbmemcasecmp-tests (Files): Add tests/test-mbmemcasecmp.h.
15792
15793 2009-03-09  Bruno Haible  <bruno@clisp.org>
15794
15795         Tests for module 'mbmemcasecmp'.
15796         * modules/mbmemcasecmp-tests: New file.
15797         * tests/test-mbmemcasecmp1.sh: New file.
15798         * tests/test-mbmemcasecmp2.sh: New file.
15799         * tests/test-mbmemcasecmp3.sh: New file.
15800         * tests/test-mbmemcasecmp.c: New file.
15801
15802         New module 'mbmemcasecmp'.
15803         * lib/mbmemcasecmp.h: New file.
15804         * lib/mbmemcasecmp.c: New file.
15805         * modules/mbmemcasecmp: New file.
15806
15807 2009-03-09  Bruno Haible  <bruno@clisp.org>
15808
15809         Tests for module 'unicase/ulc-casecoll'.
15810         * modules/unicase/ulc-casecoll-tests: New file.
15811         * tests/unicase/test-ulc-casecoll1.sh: New file.
15812         * tests/unicase/test-ulc-casecoll2.sh: New file.
15813         * tests/unicase/test-ulc-casecoll.c: New file.
15814
15815         New module 'unicase/ulc-casecoll'.
15816         * lib/unicase.h (ulc_casecoll): New declaration.
15817         * lib/unicase/ulc-casecoll.c: New file.
15818         * modules/unicase/ulc-casecoll: New file.
15819
15820         New module 'unicase/ulc-casexfrm'.
15821         * lib/unicase.h (ulc_casexfrm): New declaration.
15822         * lib/unicase/ulc-casexfrm.c: New file.
15823         * modules/unicase/ulc-casexfrm: New file.
15824
15825 2009-03-09  Bruno Haible  <bruno@clisp.org>
15826
15827         Followup to 2008-12-22 commit: Remove unnecessary AC_FUNC_MBRTOWC
15828         invocations.
15829
15830         * m4/mbscasecmp.m4: Remove file.
15831         * modules/mbscasecmp (Files): Remove it and m4/mbrtowc.m4
15832         (configure.ac): Remove gl_FUNC_MBSCASECMP invocation.
15833
15834         * m4/mbscasestr.m4: Remove file.
15835         * modules/mbscasestr (Files): Remove it and m4/mbrtowc.m4
15836         (configure.ac): Remove gl_FUNC_MBSCASESTR invocation.
15837
15838         * m4/mbschr.m4: Remove file.
15839         * modules/mbschr (Files): Remove it and m4/mbrtowc.m4
15840         (configure.ac): Remove gl_FUNC_MBSCHR invocation.
15841
15842         * m4/mbscspn.m4: Remove file.
15843         * modules/mbscspn (Files): Remove it and m4/mbrtowc.m4
15844         (configure.ac): Remove gl_FUNC_MBSCSPN invocation.
15845
15846         * m4/mbslen.m4: Remove file.
15847         * modules/mbslen (Files): Remove it and m4/mbrtowc.m4
15848         (configure.ac): Remove gl_FUNC_MBSLEN invocation.
15849
15850         * m4/mbsncasecmp.m4: Remove file.
15851         * modules/mbsncasecmp (Files): Remove it and m4/mbrtowc.m4
15852         (configure.ac): Remove gl_FUNC_MBSNCASECMP invocation.
15853
15854         * m4/mbsnlen.m4: Remove file.
15855         * modules/mbsnlen (Files): Remove it and m4/mbrtowc.m4
15856         (configure.ac): Remove gl_FUNC_MBSNLEN invocation.
15857
15858         * m4/mbspbrk.m4: Remove file.
15859         * modules/mbspbrk (Files): Remove it and m4/mbrtowc.m4
15860         (configure.ac): Remove gl_FUNC_MBSPBRK invocation.
15861
15862         * m4/mbspcasecmp.m4: Remove file.
15863         * modules/mbspcasecmp (Files): Remove it and m4/mbrtowc.m4
15864         (configure.ac): Remove gl_FUNC_MBSPCASECMP invocation.
15865
15866         * m4/mbsrchr.m4: Remove file.
15867         * modules/mbsrchr (Files): Remove it and m4/mbrtowc.m4
15868         (configure.ac): Remove gl_FUNC_MBSRCHR invocation.
15869
15870         * m4/mbssep.m4: Remove file.
15871         * modules/mbssep (Files): Remove it and m4/mbrtowc.m4
15872         (configure.ac): Remove gl_FUNC_MBSSEP invocation.
15873
15874         * m4/mbsspn.m4: Remove file.
15875         * modules/mbsspn (Files): Remove it and m4/mbrtowc.m4
15876         (configure.ac): Remove gl_FUNC_MBSSPN invocation.
15877
15878         * m4/mbsstr.m4: Remove file.
15879         * modules/mbsstr (Files): Remove it and m4/mbrtowc.m4
15880         (configure.ac): Remove gl_FUNC_MBSSTR invocation.
15881
15882         * m4/mbstok_r.m4: Remove file.
15883         * modules/mbstok_r (Files): Remove it and m4/mbrtowc.m4
15884         (configure.ac): Remove gl_FUNC_MBSTOK_R invocation.
15885
15886         * m4/mbswidth.m4 (gl_MBSWIDTH): Remove AC_FUNC_MBRTOWC invocation.
15887
15888         * m4/quotearg.m4 (gl_QUOTEARG): Remove mbsinit test and
15889         AC_TYPE_MBSTATE_T, AC_FUNC_MBRTOWC invocations.
15890
15891         * modules/trim (configure.ac): Remove AC_FUNC_MBRTOWC invocation.
15892
15893 2009-03-08  Bruno Haible  <bruno@clisp.org>
15894
15895         Tests for module 'unicase/ulc-casecmp'.
15896         * modules/unicase/ulc-casecmp-tests: New file.
15897         * tests/unicase/test-ulc-casecmp1.sh: New file.
15898         * tests/unicase/test-ulc-casecmp2.sh: New file.
15899         * tests/unicase/test-ulc-casecmp.c: New file.
15900
15901         New module 'unicase/ulc-casecmp'.
15902         * lib/unicase.h (ulc_casecmp): New declaration.
15903         * lib/unicase/ulc-casecmp.c: New file.
15904         * lib/unicase/u-casecmp.h (FUNC): Change argument types to
15905         'const SRC_UNIT *'.
15906         * lib/unicase/u8-casecmp.c (SRC_UNIT): Define like UNIT.
15907         * lib/unicase/u16-casecmp.c (SRC_UNIT): Likewise.
15908         * lib/unicase/u32-casecmp.c (SRC_UNIT): Likewise.
15909         * modules/unicase/ulc-casecmp: New file.
15910
15911         Tests for module 'unicase/u32-is-cased'.
15912         * modules/unicase/u32-is-cased-tests: New file.
15913         * tests/unicase/test-u32-is-cased.c: New file.
15914
15915         Tests for module 'unicase/u16-is-cased'.
15916         * modules/unicase/u16-is-cased-tests: New file.
15917         * tests/unicase/test-u16-is-cased.c: New file.
15918
15919         Tests for module 'unicase/u8-is-cased'.
15920         * modules/unicase/u8-is-cased-tests: New file.
15921         * tests/unicase/test-u8-is-cased.c: New file.
15922         * tests/unicase/test-is-cased.h: New file.
15923
15924         New module 'unicase/u32-is-cased'.
15925         * lib/unicase/u32-is-cased.c: New file.
15926         * modules/unicase/u32-is-cased: New file.
15927
15928         New module 'unicase/u16-is-cased'.
15929         * lib/unicase/u16-is-cased.c: New file.
15930         * modules/unicase/u16-is-cased: New file.
15931
15932         New module 'unicase/u8-is-cased'.
15933         * lib/unicase/u8-is-cased.c: New file.
15934         * lib/unicase/u-is-cased.h: New file.
15935         * modules/unicase/u8-is-cased: New file.
15936
15937         Tests for module 'unicase/u32-is-casefolded'.
15938         * modules/unicase/u32-is-casefolded-tests: New file.
15939         * tests/unicase/test-u32-is-casefolded.c: New file.
15940
15941         Tests for module 'unicase/u16-is-casefolded'.
15942         * modules/unicase/u16-is-casefolded-tests: New file.
15943         * tests/unicase/test-u16-is-casefolded.c: New file.
15944
15945         Tests for module 'unicase/u8-is-casefolded'.
15946         * modules/unicase/u8-is-casefolded-tests: New file.
15947         * tests/unicase/test-u8-is-casefolded.c: New file.
15948         * tests/unicase/test-is-casefolded.h: New file.
15949
15950         New module 'unicase/u32-is-casefolded'.
15951         * lib/unicase/u32-is-casefolded.c: New file.
15952         * modules/unicase/u32-is-casefolded: New file.
15953
15954         New module 'unicase/u16-is-casefolded'.
15955         * lib/unicase/u16-is-casefolded.c: New file.
15956         * modules/unicase/u16-is-casefolded: New file.
15957
15958         New module 'unicase/u8-is-casefolded'.
15959         * lib/unicase/u8-is-casefolded.c: New file.
15960         * modules/unicase/u8-is-casefolded: New file.
15961
15962         Tests for module 'unicase/u32-is-titlecase'.
15963         * modules/unicase/u32-is-titlecase-tests: New file.
15964         * tests/unicase/test-u32-is-titlecase.c: New file.
15965
15966         Tests for module 'unicase/u16-is-titlecase'.
15967         * modules/unicase/u16-is-titlecase-tests: New file.
15968         * tests/unicase/test-u16-is-titlecase.c: New file.
15969
15970         Tests for module 'unicase/u8-is-titlecase'.
15971         * modules/unicase/u8-is-titlecase-tests: New file.
15972         * tests/unicase/test-u8-is-titlecase.c: New file.
15973         * tests/unicase/test-is-titlecase.h: New file.
15974
15975         New module 'unicase/u32-is-titlecase'.
15976         * lib/unicase/u32-is-titlecase.c: New file.
15977         * modules/unicase/u32-is-titlecase: New file.
15978
15979         New module 'unicase/u16-is-titlecase'.
15980         * lib/unicase/u16-is-titlecase.c: New file.
15981         * modules/unicase/u16-is-titlecase: New file.
15982
15983         New module 'unicase/u8-is-titlecase'.
15984         * lib/unicase/u8-is-titlecase.c: New file.
15985         * modules/unicase/u8-is-titlecase: New file.
15986
15987         Tests for module 'unicase/u32-is-lowercase'.
15988         * modules/unicase/u32-is-lowercase-tests: New file.
15989         * tests/unicase/test-u32-is-lowercase.c: New file.
15990
15991         Tests for module 'unicase/u16-is-lowercase'.
15992         * modules/unicase/u16-is-lowercase-tests: New file.
15993         * tests/unicase/test-u16-is-lowercase.c: New file.
15994
15995         Tests for module 'unicase/u8-is-lowercase'.
15996         * modules/unicase/u8-is-lowercase-tests: New file.
15997         * tests/unicase/test-u8-is-lowercase.c: New file.
15998         * tests/unicase/test-is-lowercase.h: New file.
15999
16000         New module 'unicase/u32-is-lowercase'.
16001         * lib/unicase/u32-is-lowercase.c: New file.
16002         * modules/unicase/u32-is-lowercase: New file.
16003
16004         New module 'unicase/u16-is-lowercase'.
16005         * lib/unicase/u16-is-lowercase.c: New file.
16006         * modules/unicase/u16-is-lowercase: New file.
16007
16008         New module 'unicase/u8-is-lowercase'.
16009         * lib/unicase/u8-is-lowercase.c: New file.
16010         * modules/unicase/u8-is-lowercase: New file.
16011
16012         Tests for module 'unicase/u32-is-uppercase'.
16013         * modules/unicase/u32-is-uppercase-tests: New file.
16014         * tests/unicase/test-u32-is-uppercase.c: New file.
16015
16016         Tests for module 'unicase/u16-is-uppercase'.
16017         * modules/unicase/u16-is-uppercase-tests: New file.
16018         * tests/unicase/test-u16-is-uppercase.c: New file.
16019
16020         Tests for module 'unicase/u8-is-uppercase'.
16021         * modules/unicase/u8-is-uppercase-tests: New file.
16022         * tests/unicase/test-u8-is-uppercase.c: New file.
16023         * tests/unicase/test-is-uppercase.h: New file.
16024
16025         New module 'unicase/u32-is-uppercase'.
16026         * lib/unicase/u32-is-uppercase.c: New file.
16027         * modules/unicase/u32-is-uppercase: New file.
16028
16029         New module 'unicase/u16-is-uppercase'.
16030         * lib/unicase/u16-is-uppercase.c: New file.
16031         * modules/unicase/u16-is-uppercase: New file.
16032
16033         New module 'unicase/u8-is-uppercase'.
16034         * lib/unicase/u8-is-uppercase.c: New file.
16035         * modules/unicase/u8-is-uppercase: New file.
16036
16037         New module 'unicase/u32-is-invariant'.
16038         * lib/unicase/u32-is-invariant.c: New file.
16039         * modules/unicase/u32-is-invariant: New file.
16040
16041         New module 'unicase/u16-is-invariant'.
16042         * lib/unicase/u16-is-invariant.c: New file.
16043         * modules/unicase/u16-is-invariant: New file.
16044
16045         New module 'unicase/u8-is-invariant'.
16046         * lib/unicase/u8-is-invariant.c: New file.
16047         * lib/unicase/invariant.h: New file.
16048         * lib/unicase/u-is-invariant.h: New file.
16049         * modules/unicase/u8-is-invariant: New file.
16050
16051         Tests for module 'unicase/u32-casecoll'.
16052         * modules/unicase/u32-casecoll-tests: New file.
16053         * tests/unicase/test-u32-casecoll.c: New file.
16054
16055         Tests for module 'unicase/u16-casecoll'.
16056         * modules/unicase/u16-casecoll-tests: New file.
16057         * tests/unicase/test-u16-casecoll.c: New file.
16058
16059         Tests for module 'unicase/u8-casecoll'.
16060         * modules/unicase/u8-casecoll-tests: New file.
16061         * tests/unicase/test-u8-casecoll.c: New file.
16062
16063         New module 'unicase/u32-casecoll'.
16064         * lib/unicase/u32-casecoll.c: New file.
16065         * modules/unicase/u32-casecoll: New file.
16066
16067         New module 'unicase/u16-casecoll'.
16068         * lib/unicase/u16-casecoll.c: New file.
16069         * modules/unicase/u16-casecoll: New file.
16070
16071         New module 'unicase/u8-casecoll'.
16072         * lib/unicase/u8-casecoll.c: New file.
16073         * lib/unicase/u-casecoll.h: New file.
16074         * modules/unicase/u8-casecoll: New file.
16075
16076         New module 'unicase/u32-casexfrm'.
16077         * lib/unicase/u32-casexfrm.c: New file.
16078         * modules/unicase/u32-casexfrm: New file.
16079
16080         New module 'unicase/u16-casexfrm'.
16081         * lib/unicase/u16-casexfrm.c: New file.
16082         * modules/unicase/u16-casexfrm: New file.
16083
16084         New module 'unicase/u8-casexfrm'.
16085         * lib/unicase/u8-casexfrm.c: New file.
16086         * lib/unicase/u-casexfrm.h: New file.
16087         * modules/unicase/u8-casexfrm: New file.
16088
16089         Tests for module 'unicase/u32-casecmp'.
16090         * modules/unicase/u32-casecmp-tests: New file.
16091         * tests/unicase/test-u32-casecmp.c: New file.
16092
16093         Tests for module 'unicase/u16-casecmp'.
16094         * modules/unicase/u16-casecmp-tests: New file.
16095         * tests/unicase/test-u16-casecmp.c: New file.
16096
16097         Tests for module 'unicase/u8-casecmp'.
16098         * modules/unicase/u8-casecmp-tests: New file.
16099         * tests/unicase/test-u8-casecmp.c: New file.
16100         * tests/unicase/test-casecmp.h: New file.
16101
16102         New module 'unicase/u32-casecmp'.
16103         * lib/unicase/u32-casecmp.c: New file.
16104         * modules/unicase/u32-casecmp: New file.
16105
16106         New module 'unicase/u16-casecmp'.
16107         * lib/unicase/u16-casecmp.c: New file.
16108         * modules/unicase/u16-casecmp: New file.
16109
16110         New module 'unicase/u8-casecmp'.
16111         * lib/unicase/u8-casecmp.c: New file.
16112         * lib/unicase/u-casecmp.h: New file.
16113         * modules/unicase/u8-casecmp: New file.
16114
16115         Tests for module 'unicase/u32-casefold'.
16116         * modules/unicase/u32-casefold-tests: New file.
16117         * tests/unicase/test-u32-casefold.c: New file.
16118
16119         Tests for module 'unicase/u16-casefold'.
16120         * modules/unicase/u16-casefold-tests: New file.
16121         * tests/unicase/test-u16-casefold.c: New file.
16122
16123         Tests for module 'unicase/u8-casefold'.
16124         * modules/unicase/u8-casefold-tests: New file.
16125         * tests/unicase/test-u8-casefold.c: New file.
16126
16127         New module 'unicase/u32-casefold'.
16128         * lib/unicase/u32-casefold.c: New file.
16129         * modules/unicase/u32-casefold: New file.
16130
16131         New module 'unicase/u16-casefold'.
16132         * lib/unicase/u16-casefold.c: New file.
16133         * modules/unicase/u16-casefold: New file.
16134
16135         New module 'unicase/u8-casefold'.
16136         * lib/unicase/u8-casefold.c: New file.
16137         * lib/unicase/u-casefold.h: New file.
16138         * modules/unicase/u8-casefold: New file.
16139
16140         New module 'unicase/tocasefold'.
16141         * lib/unicase/casefold.h: New file.
16142         * lib/unicase/tocasefold.c: New file.
16143         * lib/unicase/tocasefold.h: New file, generated by gen-uni-tables.c.
16144         * modules/unicase/tocasefold: New file.
16145
16146         Tests for module 'unicase/u32-totitle'.
16147         * modules/unicase/u32-totitle-tests: New file.
16148         * tests/unicase/test-u32-totitle.c: New file.
16149
16150         Tests for module 'unicase/u16-totitle'.
16151         * modules/unicase/u16-totitle-tests: New file.
16152         * tests/unicase/test-u16-totitle.c: New file.
16153
16154         Tests for module 'unicase/u8-totitle'.
16155         * modules/unicase/u8-totitle-tests: New file.
16156         * tests/unicase/test-u8-totitle.c: New file.
16157
16158         New module 'unicase/u32-totitle'.
16159         * lib/unicase/u32-totitle.c: New file.
16160         * modules/unicase/u32-totitle: New file.
16161
16162         New module 'unicase/u16-totitle'.
16163         * lib/unicase/u16-totitle.c: New file.
16164         * modules/unicase/u16-totitle: New file.
16165
16166         New module 'unicase/u8-totitle'.
16167         * lib/unicase/u8-totitle.c: New file.
16168         * lib/unicase/u-totitle.h: New file.
16169         * modules/unicase/u8-totitle: New file.
16170
16171         Tests for module 'unicase/u32-tolower'.
16172         * modules/unicase/u32-tolower-tests: New file.
16173         * tests/unicase/test-u32-tolower.c: New file.
16174
16175         Tests for module 'unicase/u16-tolower'.
16176         * modules/unicase/u16-tolower-tests: New file.
16177         * tests/unicase/test-u16-tolower.c: New file.
16178
16179         Tests for module 'unicase/u8-tolower'.
16180         * modules/unicase/u8-tolower-tests: New file.
16181         * tests/unicase/test-u8-tolower.c: New file.
16182
16183         New module 'unicase/u32-tolower'.
16184         * lib/unicase/u32-tolower.c: New file.
16185         * modules/unicase/u32-tolower: New file.
16186
16187         New module 'unicase/u16-tolower'.
16188         * lib/unicase/u16-tolower.c: New file.
16189         * modules/unicase/u16-tolower: New file.
16190
16191         New module 'unicase/u8-tolower'.
16192         * lib/unicase/u8-tolower.c: New file.
16193         * modules/unicase/u8-tolower: New file.
16194
16195         Tests for module 'unicase/u32-toupper'.
16196         * modules/unicase/u32-toupper-tests: New file.
16197         * tests/unicase/test-u32-toupper.c: New file.
16198
16199         Tests for module 'unicase/u16-toupper'.
16200         * modules/unicase/u16-toupper-tests: New file.
16201         * tests/unicase/test-u16-toupper.c: New file.
16202
16203         Tests for module 'unicase/u8-toupper'.
16204         * modules/unicase/u8-toupper-tests: New file.
16205         * tests/unicase/test-u8-toupper.c: New file.
16206
16207         New module 'unicase/u32-toupper'.
16208         * lib/unicase/u32-toupper.c: New file.
16209         * modules/unicase/u32-toupper: New file.
16210
16211         New module 'unicase/u16-toupper'.
16212         * lib/unicase/u16-toupper.c: New file.
16213         * modules/unicase/u16-toupper: New file.
16214
16215         New module 'unicase/u8-toupper'.
16216         * lib/unicase/u8-toupper.c: New file.
16217         * modules/unicase/u8-toupper: New file.
16218
16219         New module 'unicase/u32-casemap'.
16220         * lib/unicase/u32-casemap.c: New file.
16221         * modules/unicase/u32-casemap: New file.
16222
16223         New module 'unicase/u16-casemap'.
16224         * lib/unicase/u16-casemap.c: New file.
16225         * modules/unicase/u16-casemap: New file.
16226
16227         New module 'unicase/u8-casemap'.
16228         * lib/unicase/unicasemap.h: New file.
16229         * lib/unicase/u8-casemap.c: New file.
16230         * lib/unicase/u-casemap.h: New file.
16231         * modules/unicase/u8-casemap: New file.
16232
16233         New module 'unicase/special-casing'.
16234         * lib/unicase/special-casing.h: New file.
16235         * lib/unicase/special-casing.c: New file.
16236         * lib/unicase/special-casing-table.gperf: New file, generated by
16237         gen-uni-tables.c.
16238         * modules/unicase/special-casing: New file.
16239
16240         Tests for module 'unicase/locale-language'.
16241         * modules/unicase/locale-language-tests: New file.
16242         * tests/unicase/test-locale-language.sh: New file.
16243         * tests/unicase/test-locale-language.c: New file.
16244
16245         New module 'unicase/locale-language'.
16246         * lib/unicase/locale-language.c: New file.
16247         * lib/unicase/locale-languages.gperf: New file.
16248         * modules/unicase/locale-language: New file.
16249
16250         Generate more tables for case conversion and case folding.
16251         * lib/gen-uni-tables.c (SCC_*): New enum items.
16252         (struct special_casing_rule): New type.
16253         (casing_rules, num_casing_rules, allocated_casing_rules): New
16254         variables.
16255         (add_casing_rule, fill_casing_rules): New functions.
16256         (struct casefold_rule): New type.
16257         (casefolding_rules, num_casefolding_rules,
16258         allocated_casefolding_rules): New variables.
16259         (fill_casefolding_rules): New function.
16260         (unicode_casefold): New variable.
16261         (to_casefold, redistribute_casefolding_rules, compare_casing_rules,
16262         sort_casing_rules, output_casing_rules): New functions.
16263         (main): Accept to more arguments: SpecialCasing.txt and
16264         CaseFolding.txt. Invoke fill_casing_rules, fill_casefolding_rules,
16265         redistribute_casefolding_rules, sort_casing_rules, output_casing_rules.
16266         Output mapping for casefolding.
16267
16268         * lib/unicase.h: Include stdbool.h, uninorm.h.
16269         (u8_toupper, u16_toupper, u32_toupper, u8_tolower, u16_tolower,
16270         u32_tolower, u8_totitle, u16_totitle, u32_totitle): Add nf argument.
16271         (u8_casefold, u16_casefold, u32_casefold): Add iso639_language and nf
16272         arguments.
16273         (u8_casecmp, u16_casecmp, u32_casecmp): Add iso639_language, nf,
16274         resultp arguments.
16275         (u8_casexfrm, u16_casexfrm, u32_casexfrm): New declarations.
16276         (u8_casecoll, u16_casecoll, u32_casecoll): Add iso639_language, nf,
16277         resultp arguments.
16278         (u8_is_uppercase, u16_is_uppercase, u32_is_uppercase, u8_is_lowercase,
16279         u16_is_lowercase, u32_is_lowercase, u8_is_titlecase, u16_is_titlecase,
16280         u32_is_titlecase, u8_is_casefolded, u16_is_casefolded,
16281         u32_is_casefolded, u8_is_cased, u16_is_cased, u32_is_cased): New
16282         declarations.
16283         * modules/unicase/base (Depends-on): Add uninorm/base, stdbool.
16284
16285 2009-03-08  Bruno Haible  <bruno@clisp.org>
16286
16287         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
16288         u16_normcoll, u32_normcoll): Rename argument 'result' to 'resultp'.
16289         * lib/uninorm/u-normcmp.h (FUNC): Likewise.
16290         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
16291
16292 2009-03-07  Bruno Haible  <bruno@clisp.org>
16293
16294         Adjust u*_normcmp, u*_normcoll API.
16295         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp, u8_normcoll,
16296         u16_normcoll, u32_normcoll): Change failure conventions.
16297         * lib/uninorm/u-normcmp.h (FUNC): Upon failure, store the error code in
16298         errno and return -1.
16299         * lib/uninorm/u-normcoll.h (FUNC): Likewise.
16300
16301 2009-03-07  Bruno Haible  <bruno@clisp.org>
16302
16303         Tests for module 'uninorm/u32-normcoll'.
16304         * modules/uninorm/u32-normcoll-tests: New file.
16305         * tests/uninorm/test-u32-normcoll.c: New file.
16306
16307         Tests for module 'uninorm/u16-normcoll'.
16308         * modules/uninorm/u16-normcoll-tests: New file.
16309         * tests/uninorm/test-u16-normcoll.c: New file.
16310
16311         Tests for module 'uninorm/u8-normcoll'.
16312         * modules/uninorm/u8-normcoll-tests: New file.
16313         * tests/uninorm/test-u8-normcoll.c: New file.
16314
16315 2009-03-07  Bruno Haible  <bruno@clisp.org>
16316
16317         * tests/uninorm/test-u32-normcmp.h: New file, extracted from
16318         tests/uninorm/test-u32-normcmp.c.
16319         * tests/uninorm/test-u32-normcmp.c: Include it.
16320         (test_nonascii): New function, extracted from main. Add some more
16321         tests.
16322         (main): Invoke test_ascii and test_nonascii.
16323         * modules/uninorm/u32-normcmp-tests (Files): Add
16324         tests/uninorm/test-u32-normcmp.h.
16325         (Depends-on): Remove uninorm/u32-normcmp.
16326
16327         * tests/uninorm/test-u16-normcmp.h: New file, extracted from
16328         tests/uninorm/test-u16-normcmp.c.
16329         * tests/uninorm/test-u16-normcmp.c: Include it.
16330         (test_nonascii): New function, extracted from main. Add some more
16331         tests.
16332         (main): Invoke test_ascii and test_nonascii.
16333         * modules/uninorm/u16-normcmp-tests (Files): Add
16334         tests/uninorm/test-u16-normcmp.h.
16335         (Depends-on): Remove uninorm/u16-normcmp.
16336
16337         * tests/uninorm/test-u8-normcmp.h: New file, extracted from
16338         tests/uninorm/test-u8-normcmp.c.
16339         * tests/uninorm/test-u8-normcmp.c: Include it.
16340         (test_nonascii): New function, extracted from main. Add some more
16341         tests.
16342         (main): Invoke test_ascii and test_nonascii.
16343         * modules/uninorm/u8-normcmp-tests (Files): Add
16344         tests/uninorm/test-u8-normcmp.h.
16345         (Depends-on): Remove uninorm/u8-normcmp.
16346
16347 2009-03-07  Bruno Haible  <bruno@clisp.org>
16348
16349         New module 'uninorm/u32-normcoll'.
16350         * lib/uninorm/u32-normcoll.c: New file.
16351         * modules/uninorm/u32-normcoll: New file.
16352
16353         New module 'uninorm/u16-normcoll'.
16354         * lib/uninorm/u16-normcoll.c: New file.
16355         * modules/uninorm/u16-normcoll: New file.
16356
16357         New module 'uninorm/u8-normcoll'.
16358         * lib/uninorm.h (u8_normcoll, u16_normcoll, u32_normcoll): New
16359         declarations.
16360         * lib/uninorm/u8-normcoll.c: New file.
16361         * lib/uninorm/u-normcoll.h: New file.
16362         * modules/uninorm/u8-normcoll: New file.
16363
16364         New module 'uninorm/u32-normxfrm'.
16365         * lib/uninorm/u32-normxfrm.c: New file.
16366         * modules/uninorm/u32-normxfrm: New file.
16367
16368         New module 'uninorm/u16-normxfrm'.
16369         * lib/uninorm/u16-normxfrm.c: New file.
16370         * modules/uninorm/u16-normxfrm: New file.
16371
16372         New module 'uninorm/u8-normxfrm'.
16373         * lib/uninorm.h (u8_normxfrm, u16_normxfrm, u32_normxfrm): New
16374         declarations.
16375         * lib/uninorm/u8-normxfrm.c: New file.
16376         * lib/uninorm/u-normxfrm.h: New file.
16377         * modules/uninorm/u8-normxfrm: New file.
16378
16379 2009-03-07  Bruno Haible  <bruno@clisp.org>
16380
16381         * modules/uninorm/u8-normcmp (Depends-on): Add uninorm/base.
16382         * modules/uninorm/u16-normcmp (Depends-on): Likewise.
16383         * modules/uninorm/u32-normcmp (Depends-on): Likewise.
16384
16385 2009-03-07  Bruno Haible  <bruno@clisp.org>
16386
16387         New module 'memxfrm'.
16388         * lib/memxfrm.h: New file.
16389         * lib/memxfrm.c: New file.
16390         * modules/memxfrm: New file.
16391
16392 2009-03-07  Bruno Haible  <bruno@clisp.org>
16393
16394         New module 'memcmp2'.
16395         * lib/memcmp2.h: New file.
16396         * lib/memcmp2.c: New file.
16397         * modules/memcmp2: New file.
16398
16399 2009-03-07  Bruno Haible  <bruno@clisp.org>
16400
16401         Tests for module 'uninorm/decomposing-form'.
16402         * modules/uninorm/decomposing-form-tests: New file.
16403         * tests/uninorm/test-decomposing-form.c: New file.
16404
16405         New module 'uninorm/decomposing-form'.
16406         * lib/uninorm.h (uninorm_decomposing_form): New declaration.
16407         * lib/uninorm/normalize-internal.h (struct unicode_normalization_form):
16408         Add 'decomposing_variant' field.
16409         * lib/uninorm/decomposing-form.c: New file.
16410         * lib/uninorm/nfc.c (uninorm_nfc): Update.
16411         * lib/uninorm/nfd.c (uninorm_nfd): Update.
16412         * lib/uninorm/nfkc.c (uninorm_nfkc): Update.
16413         * lib/uninorm/nfkd.c (uninorm_nfkd): Update.
16414         * modules/uninorm/decomposing-form: New file.
16415         * modules/uninorm/nfc (Depends-on): Add uninorm/nfd.
16416         * modules/uninorm/nfkc (Depends-on): Add uninorm/nfkd.
16417
16418 2009-03-07  Bruno Haible  <bruno@clisp.org>
16419
16420         * lib/uninorm/u-normcmp.h (FUNC): Use stack=allocated buffers for small
16421         strings.
16422
16423 2009-03-06  Bruno Haible  <bruno@clisp.org>
16424
16425         Tests for module 'uninorm/u32-normcmp'.
16426         * tests/uninorm/test-u32-normcmp.c: New file.
16427         * modules/uninorm/u32-normcmp-tests: New file.
16428
16429         Tests for module 'uninorm/u16-normcmp'.
16430         * tests/uninorm/test-u16-normcmp.c: New file.
16431         * modules/uninorm/u16-normcmp-tests: New file.
16432
16433         Tests for module 'uninorm/u8-normcmp'.
16434         * tests/uninorm/test-u8-normcmp.c: New file.
16435         * modules/uninorm/u8-normcmp-tests: New file.
16436
16437         New module 'uninorm/u32-normcmp'.
16438         * lib/uninorm/u32-normcmp.c: New file.
16439         * modules/uninorm/u32-normcmp: New file.
16440
16441         New module 'uninorm/u16-normcmp'.
16442         * lib/uninorm/u16-normcmp.c: New file.
16443         * modules/uninorm/u16-normcmp: New file.
16444
16445         New module 'uninorm/u8-normcmp'.
16446         * lib/uninorm.h (u8_normcmp, u16_normcmp, u32_normcmp): New
16447         declarations.
16448         * lib/uninorm/u8-normcmp.c: New file.
16449         * lib/uninorm/u-normcmp.h: New file.
16450         * modules/uninorm/u8-normcmp: New file.
16451
16452 2009-03-06  Bruno Haible  <bruno@clisp.org>
16453
16454         * lib/w32spawn.h (dup_noinherit): Add cast, to avoid gcc warning.
16455         Reported by Eric Blake.
16456
16457 2009-03-06  Eric Blake  <ebb9@byu.net>
16458             Bruno Haible  <bruno@clisp.org>
16459
16460         * lib/spawni.c (__spawni) [WIN32_NATIVE]: Define as a stub.
16461         * modules/posix_spawn-tests (configure.ac): Define POSIX_SPAWN_PORTED
16462         condition.
16463         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
16464         * modules/posix_spawnp-tests (configure.ac): Define POSIX_SPAWN_PORTED
16465         condition.
16466         (Makefile.am): Do nothing if POSIX_SPAWN_PORTED is false.
16467
16468 2009-03-06  Eric Blake  <ebb9@byu.net>
16469
16470         * lib/execute.c (execute) [WIN32_NATIVE]: Cast arguments of spawnvpe,
16471         to avoid compiler warnings.
16472         * lib/pipe.c (create_pipe) [WIN32_NATIVE]: Likewise.
16473
16474 2009-03-05  Bruno Haible  <bruno@clisp.org>
16475
16476         * tests/test-ftell.c (main): Disable test beyond end of file on
16477         FreeMiNT.
16478         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
16479
16480 2009-03-05  Kamil Dudka  <kdudka@redhat.com>
16481
16482         * lib/filevercmp.c: Move hidden files up in ordering.
16483         * tests/test-filevercmp.c: Add tests for hidden files.
16484
16485 2009-03-04  Bruno Haible  <bruno@clisp.org>
16486
16487         * modules/visibility (Makefile.am): Augment AM_CFLAGS.
16488         * gnulib-tool (func_emit_lib_Makefile_am): Emit initialization of
16489         AM_CFLAGS.
16490         Reported by Simon Josefsson.
16491
16492 2009-03-03  Bruno Haible  <bruno@clisp.org>
16493
16494         * doc/visibility.texi: Recommend to use HAVE_VISIBILITY as a C macro.
16495         Reported by Simon Josefsson.
16496
16497         * doc/ld-version-script.texi: Update node reference.
16498
16499 2009-03-03  Bruno Haible  <bruno@clisp.org>
16500
16501         * modules/visibility (License): Change to 'unlimited'.
16502         Suggested by Simon Josefsson.
16503
16504 2009-03-03  Jim Meyering  <meyering@redhat.com>
16505
16506         unlinkdir: cannot_unlink_dir may modify process state
16507         * lib/unlinkdir.c (cannot_unlink_dir): Add a comment warning that
16508         it's neither thread-safe nor appropriate for use in a library.
16509
16510 2009-03-03  Eric Blake  <ebb9@byu.net>
16511
16512         test-closein: silence test under Darwin
16513         * tests/test-closein.sh: Ignore stderr from cat, since we don't
16514         care if it dies from EPIPE or EBADF.
16515
16516 2009-03-03  Bruno Haible  <bruno@clisp.org>
16517
16518         * doc/gnulib.texi: Include visibility.texi and ld-version-script.texi
16519         earlier.
16520         * doc/visibility.texi: Fix @node and @section.
16521
16522 2009-03-03  Simon Josefsson  <simon@josefsson.org>
16523
16524         * doc/gnulib.texi: Link to sections for ld version script and
16525         visibility.
16526         * doc/visibility.texi: Add @node and @section.
16527         * modules/ld-version-script: New module.
16528         * m4/ld-version-script.m4: New file.
16529         * doc/ld-version-script.texi: New file.
16530
16531 2009-03-02  David Lutterkort  <lutter@redhat.com>
16532
16533         * lib/safe-alloc.h (__GNUC_PREREQ): New macro.
16534         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
16535
16536 2009-03-02  Bruno Haible  <bruno@clisp.org>
16537
16538         * doc/visibility.texi: Mention libtool's -export-symbols option.
16539
16540 2009-03-02  Jim Meyering  <meyering@redhat.com>
16541
16542         announce-gen: new option: --no-print-checksums
16543         * build-aux/announce-gen (usage): Describe it.
16544         (print_checksums): Print a newline here, not in the [*] footnote.
16545         (main): Honor it.
16546
16547 2009-03-01  Bruno Haible  <bruno@clisp.org>
16548
16549         Use socklen_t in the native Windows replacements prototypes.
16550         * lib/sys_socket.in.h (rpl_getsockopt, rpl_setsockopt): Use socklen_t
16551         instead of 'int'.
16552         * lib/getsockopt.c (rpl_getsockopt): Likewise.
16553         * lib/setsockopt.c (rpl_setsockopt): Likewise.
16554         * modules/getsockopt (Depends-on): Add socklen.
16555         * modules/setsockopt (Depends-on): Add socklen.
16556
16557 2009-03-01  Bruno Haible  <bruno@clisp.org>
16558
16559         * gnulib-tool (sed): Do alias as "sed --posix" if sed's version is at
16560         least 4.2.
16561
16562 2009-03-01  Eric Blake  <ebb9@byu.net>
16563             Bruno Haible  <bruno@clisp.org>
16564
16565         * lib/wait-process.h (wait_subprocess): Describe effect of termsigp on
16566         error messages.
16567         * lib/wait-process.c (wait_subprocess): Omit error message about
16568         deadly signal sent to the child of termsigp != NULL.
16569
16570 2009-03-01  Eric Blake  <ebb9@byu.net>
16571
16572         * lib/wait-process.c (wait_subprocess): Remove unnecessary cast.
16573
16574 2009-03-01  Bruno Haible  <bruno@clisp.org>
16575
16576         Avoid a gcc warning.
16577         * tests/test-sched.c (b): Make global.
16578         Reported by Eric Blake.
16579
16580 2009-01-19  Martin Lambers  <marlam@marlam.de>
16581
16582         Provide POSIX semantics for socket timeout options on W32.
16583         * lib/setsockopt.c: Convert struct timeval to milliseconds on W32.
16584         * lib/getsockopt.c: Convert milliseconds to struct timeval on W32.
16585         * modules/setsockopt: Depend on sys_time module for struct timeval.
16586         * modules/getsockopt: Depend on sys_time module for struct timeval.
16587
16588 2009-03-01  Simon Josefsson  <simon@josefsson.org>
16589
16590         * lib/gai_strerror.c (values): Use EAI_INPROGRESS instead of
16591         __USE_GNU, for consistency with netdb.in.h.
16592         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
16593
16594 2009-03-01  Bruno Haible  <bruno@clisp.org>
16595
16596         More support for FreeMiNT.
16597         * lib/fseeko.c (rpl_fseeko): Complete last commit.
16598         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
16599
16600 2009-03-01  Bruno Haible  <bruno@clisp.org>
16601
16602         More support for FreeMiNT.
16603         * lib/fpurge.c (fpurge): Correct last commit.
16604         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
16605
16606 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
16607
16608         Fix unportable awk script in vc-list-files.
16609         * build-aux/vc-list-files: In the replacement awk script, use
16610         substr with a second argument of 1, not zero.
16611         Report by Simon Josefsson.
16612
16613 2009-02-28  Bruno Haible  <bruno@clisp.org>
16614
16615         More support for FreeMiNT.
16616         * lib/freading.c (freading) [__MINT__]: Use new macros that were added
16617         to FreeMiNT today.
16618         * lib/fwriting.c (fwriting): Likewise.
16619         Based on patch by Alan Hourihane <alanh@fairlite.co.uk>.
16620
16621 2009-02-28  Bruno Haible  <bruno@clisp.org>
16622
16623         * tests/test-freadseek.c (main): Disable test beyond end of file on
16624         FreeMiNT.
16625         * tests/test-ftello.c (main): Likewise.
16626         Patch by Alan Hourihane <alanh@fairlite.co.uk>.
16627
16628 2009-02-28  Bruno Haible  <bruno@clisp.org>
16629
16630         Add tentative support for FreeMiNT.
16631         * lib/fbufmode.c (fbufmode) [__MINT__]: Add conditional code.
16632         * lib/fpurge.c (fpurge): Likewise.
16633         * lib/freadable.c (freadable): Likewise.
16634         * lib/freading.c (freading): Likewise.
16635         * lib/freadptr.c (freadptr): Likewise.
16636         * lib/freadseek.c (freadptrinc): Likewise.
16637         * lib/fseeko.c (rpl_fseeko): Likewise.
16638         * lib/fseterr.c (fseterr): Likewise.
16639         * lib/fwritable.c (fwritable): Likewise.
16640         * lib/fwriting.c (fwriting): Likewise.
16641         * lib/freadahead.c (freadahead): Likewise, based on code by Alan
16642         Hourihane.
16643         Reported by Alan Hourihane <alanh@fairlite.co.uk>.
16644
16645 2009-02-28  Bruno Haible  <bruno@clisp.org>
16646
16647         * lib/wait-process.h (wait_subprocess): Clarify restriction regarding
16648         SIGCHLD.
16649         Reported by Jim Meyering.
16650
16651 2009-02-28  Bruno Haible  <bruno@clisp.org>
16652
16653         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Separate the two first tests.
16654         Mention the results of these tests on various platforms.
16655         * doc/posix-functions/fprintf.texi: Mention platforms in canonical
16656         order.
16657         * doc/posix-functions/printf.texi: Likewise.
16658         * doc/posix-functions/snprintf.texi: Likewise.
16659         * doc/posix-functions/sprintf.texi: Likewise.
16660         * doc/posix-functions/vfprintf.texi: Likewise.
16661         * doc/posix-functions/vprintf.texi: Likewise.
16662         * doc/posix-functions/vsnprintf.texi: Likewise.
16663         * doc/posix-functions/vsprintf.texi: Likewise.
16664         * doc/glibc-functions/obstack_printf.texi: Likewise.
16665         * doc/glibc-functions/obstack_vprintf.texi: Likewise.
16666
16667 2009-02-28  Bruno Haible  <bruno@clisp.org>
16668
16669         * build-aux/po/Makefile.in.in: Update from GNU gettext 0.17.
16670         Reported by Loïc Minier <lool@dooz.org>.
16671
16672 2009-02-27  Bruno Haible  <bruno@clisp.org>
16673
16674         * gnulib-tool (func_import): Make the sed expression used to create the
16675         sed script for updating the .gitignore file POSIX compliant.
16676         Reported by Eric Blake.
16677
16678 2009-02-27  Bruno Haible  <bruno@clisp.org>
16679
16680         * gnulib-tool (sed): Don't alias as "sed --posix".
16681         Reported by Eric Blake.
16682
16683 2009-02-27  Bruno Haible  <bruno@clisp.org>
16684
16685         Avoid test link errors.
16686         * modules/uninorm/nfc-tests (test_u32_nfc_big_LDADD): New variable.
16687         * modules/uninorm/nfd-tests (test_u32_nfd_big_LDADD): New variable.
16688         * modules/uninorm/nfkc-tests (test_u32_nfkc_big_LDADD): New variable.
16689         * modules/uninorm/nfkd-tests (test_u32_nfkd_big_LDADD): New variable.
16690         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
16691
16692 2009-02-27  Bruno Haible  <bruno@clisp.org>
16693
16694         Avoid spurious "(cached)" in configure output.
16695         * m4/gnulib-common.m4 (gl_CACHE_VAL_SILENT): New macro.
16696         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Use it instead of AC_CACHE_VAL.
16697         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
16698         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
16699         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
16700         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Likewise.
16701         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
16702         * m4/stdarg.m4 (gl_STDARG_H): Likewise.
16703         Reported by Eric Blake.
16704
16705 2009-02-27  Eric Blake  <ebb9@byu.net>
16706
16707         printf: fix regression in previous patch
16708         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Fix compilation error.
16709
16710 2009-02-27  Bruno Haible  <bruno@clisp.org>
16711
16712         * lib/inttypes.in.h: Test merely whether _LP64 is defined, not its
16713         value.
16714         * lib/stdint.in.h: Likewise.
16715         Suggested by Eric Blake. Reported by Peter Bray <pdb_ml@yahoo.com.au>.
16716
16717 2009-02-27  Eric Blake  <ebb9@byu.net>
16718
16719         doc: mention more functions added in cygwin 1.7.0
16720         * doc/posix-functions/mbsnrtowcs.texi: Mention recent cygwin 1.7.0
16721         addition.
16722         * doc/posix-functions/open_wmemstream.texi: Likewise.
16723         * doc/posix-functions/wcsnlen.texi: Likewise.
16724         * doc/posix-functions/wcsnrtombs.texi: Likewise.
16725         * doc/posix-functions/wcstod.texi: Likewise.
16726         * doc/posix-functions/wcstof.texi: Likewise.
16727         * doc/posix-functions/wcstoimax.texi: Likewise.
16728         * doc/posix-functions/wcstok.texi: Likewise.
16729         * doc/posix-functions/wcstoumax.texi: Likewise.
16730
16731         Detect bug in cygwin 1.5.x *printf on 1-character %ls.
16732         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Enhance filter.
16733         * doc/posix-functions/fprintf.texi: Update.
16734         * doc/posix-functions/printf.texi: Update.
16735         * doc/posix-functions/snprintf.texi: Update.
16736         * doc/posix-functions/sprintf.texi: Update.
16737         * doc/posix-functions/vfprintf.texi: Update.
16738         * doc/posix-functions/vprintf.texi: Update.
16739         * doc/posix-functions/vsnprintf.texi: Update.
16740         * doc/posix-functions/vsprintf.texi: Update.
16741         * doc/glibc-functions/obstack_printf.texi: Update.
16742         * doc/glibc-functions/obstack_vprintf.texi: Update.
16743
16744 2009-02-26  Eric Blake  <ebb9@byu.net>
16745
16746         avoid gcc 3.4.3 bug on long double NaN on Irix 6.5
16747         * tests/nan.h (NaNl): Rewrite as function on Irix, to avoid
16748         compilation bug by using runtime conversion.
16749         * m4/isfinite.m4 (gl_ISFINITE): Likewise.
16750         * m4/isnanl.m4 (gl_FUNC_ISNANL): Likewise.
16751         * modules/ceill-tests (Files): Use nan.h.
16752         * modules/floorl-tests (Files): Likewise.
16753         * modules/frexpl-tests (Files): Likewise.
16754         * modules/isnanl-tests (Files): Likewise.
16755         * modules/ldexpl-tests (Files): Likewise.
16756         * modules/roundl-tests (Files): Likewise.
16757         * modules/truncl-tests (Files): Likewise.
16758         * tests/test-ceill.c (main): Use a working NaN.
16759         * tests/test-floorl.c (main): Likewise.
16760         * tests/test-frexpl.c (main): Likewise.
16761         * tests/test-isnan.c (test_long_double): Likewise.
16762         * tests/test-isnanl.h (main): Likewise.
16763         * tests/test-ldexpl.h (main): Likewise.
16764         * tests/test-roundl.h (main): Likewise.
16765         * tests/test-truncl.h (main): Likewise.
16766         See http://lists.gnu.org/archive/html/bug-gnulib/2009-02/msg00190.html.
16767
16768 2009-02-26  Eric Blake  <ebb9@byu.net>
16769             Bruno Haible  <bruno@clisp.org>
16770
16771         Work around a *printf bug with %ls on Solaris.
16772         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): Also test whether, when a
16773         precision is specified, sprintf stops converting the wide string
16774         argument when the number of bytes that have been produced by this
16775         conversion equals or exceeds the precision.
16776         * doc/posix-functions/fprintf.texi: Update.
16777         * doc/posix-functions/printf.texi: Update.
16778         * doc/posix-functions/snprintf.texi: Update.
16779         * doc/posix-functions/sprintf.texi: Update.
16780         * doc/posix-functions/vfprintf.texi: Update.
16781         * doc/posix-functions/vprintf.texi: Update.
16782         * doc/posix-functions/vsnprintf.texi: Update.
16783         * doc/posix-functions/vsprintf.texi: Update.
16784         * doc/glibc-functions/obstack_printf.texi: Update.
16785         * doc/glibc-functions/obstack_vprintf.texi: Update.
16786
16787 2009-02-26  Eric Blake  <ebb9@byu.net>
16788
16789         stdlib: favor compiler check of random.h
16790         * m4/stdlib_h.m4 (gl_STDLIB_H): Skip preprocessor check.  Needed
16791         to avoid an ObjC random.h installed by Swarm.
16792
16793 2009-02-26  Bruno Haible  <bruno@clisp.org>
16794
16795         Work around *printf bug with %g directive and 0.0 on HP-UX 10.20.
16796         * m4/printf.m4 (gl_PRINTF_INFINITE): Also test for %g output of -0.0.
16797         Reported by Gary V. Vaughan <gary@gnu.org>.
16798
16799 2009-02-26  Bruno Haible  <bruno@clisp.org>
16800
16801         Fix *printf behaviour regarding the %ls directive.
16802         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_LS): New macro.
16803         * lib/vasnprintf.c (local_wcslen, VASNPRINTF): Handle
16804         NEED_PRINTF_DIRECTIVE_LS.
16805         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_LS): New macro.
16806         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
16807         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
16808         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS and test its result. Invoke
16809         gl_PREREQ_VASNPRINTF_DIRECTIVE_LS.
16810         * m4/dprintf-posix.m4 (gl_FUNC_DPRINTF_POSIX): Likewise.
16811         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
16812         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
16813         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
16814         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
16815         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
16816         * m4/vdprintf-posix.m4 (gl_FUNC_VDPRINTF_POSIX): Likewise.
16817         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
16818         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
16819         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
16820         * doc/posix-functions/fprintf.texi: Update.
16821         * doc/posix-functions/printf.texi: Update.
16822         * doc/posix-functions/snprintf.texi: Update.
16823         * doc/posix-functions/sprintf.texi: Update.
16824         * doc/posix-functions/vfprintf.texi: Update.
16825         * doc/posix-functions/vprintf.texi: Update.
16826         * doc/posix-functions/vsnprintf.texi: Update.
16827         * doc/posix-functions/vsprintf.texi: Update.
16828         * doc/glibc-functions/obstack_printf.texi: Update.
16829         * doc/glibc-functions/obstack_vprintf.texi: Update.
16830         Reported by Eric Blake.
16831
16832 2009-02-25  Bruno Haible  <bruno@clisp.org>
16833
16834         * m4/mbrtowc.m4 (gl_MBRTOWC_NUL_RETVAL): Update guess for Solaris 8
16835         with known value.
16836         Reported by Gary V. Vaughan <gary@gnu.org>.
16837
16838 2009-02-25  Bruno Haible  <bruno@clisp.org>
16839
16840         Work around mbrtowc bug in zh_CN.GB18030 locale on Solaris 8.
16841         * m4/mbrtowc.m4 (gl_MBRTOWC_SANITYCHECK): New macro.
16842         (gl_MBSTATE_T_BROKEN): Invoke it. Replace mbstate_t when it says "no".
16843         * doc/posix-functions/mbrtowc.texi: Document the Solaris 8 bug.
16844         Reported by Gary V. Vaughan <gary@gnu.org>.
16845
16846 2009-02-25  Bruno Haible  <bruno@clisp.org>
16847
16848         Work around broken INT8_MAX, UINT8_MAX etc. values on HP-UX 11.23.
16849         * m4/stdint.m4 (gl_STDINT_H): Also check whether the expansions of
16850         INT8_MAX, UINT8_MAX etc. contain casts to elementary types.
16851         * doc/posix-headers/stdint.texi: Mention the HP-UX bug.
16852         Reported by Gary V. Vaughan <gary@gnu.org>.
16853
16854 2009-02-25  Eric Blake  <ebb9@byu.net>
16855
16856         tests: skip fseek/ftell tests if ungetc is broken
16857         * m4/ungetc.m4: New file.
16858         * modules/fseek-tests: Split test, so ungetc dependency is
16859         separate from rest of test.
16860         * modules/fseeko-tests: Likewise.
16861         * modules/ftell-tests: Likewise.
16862         * modules/ftello-tests: Likewise.
16863         * tests/test-fseek.c (main): Isolate ungetc dependency.
16864         * tests/test-fseeko.c (main): Likewise.
16865         * tests/test-ftell.c (main): Likewise.
16866         * tests/test-ftello.c (main): Likewise.
16867         * tests/test-fseek2.sh: New file.
16868         * tests/test-fseeko2.sh: Likewise.
16869         * tests/test-ftell2.sh: Likewise.
16870         * tests/test-ftello2.sh: Likewise.
16871
16872 2009-02-25  Ondřej Vašík  <ovasik@redhat.com>
16873
16874         test-getaddrinfo: fix usage of skip return code 77
16875         * tests/test-gettaddrinfo.c: Return skip code 77 only
16876         for first occurance of skip (4x77 is not 77)
16877
16878 2009-02-25  Gary V. Vaughan  <gary@gnu.org>
16879
16880         strtod: avoid C99 decl-after-statement
16881         * m4/strtod.m4 (gl_FUNC_STRTOD): Rearrange declaration.
16882
16883 2009-02-24  Eric Blake  <ebb9@byu.net>
16884
16885         strtod: detect HP-UX 11.31 bug
16886         * m4/strtod.m4 (gl_FUNC_STRTOD): Detect errno handling bug.
16887         Reported by Gary V. Vaughan.
16888
16889 2009-02-23  Bruno Haible  <bruno@clisp.org>
16890
16891         Fix invalid read past end of memory block.
16892         * lib/vasnprintf.c (DCHAR_SET): Define.
16893         (local_wcslen): Define only when needed.
16894         (local_strnlen, local_wcsnlen): New functions.
16895         (VASNPRINTF) [!USE_SNPRINTF && HAVE_WCHAR_T]: Implement the %s and %ls
16896         directives that involve a conversion ourselves.
16897         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for strnlen,
16898         wcsnlen, mbrtowc, wcrtomb.
16899         * tests/test-vasnprintf-posix.c (test_function): Add tests for %.*s.
16900         * tests/test-vasprintf-posix.c (test_function): Likewise.
16901         * tests/test-snprintf-posix.h (test_function): Likewise.
16902         * tests/test-sprintf-posix.h (test_function): Likewise.
16903         Reported by Ben Pfaff <blp@cs.stanford.edu>.
16904
16905 2009-02-22  Bruno Haible  <bruno@clisp.org>
16906
16907         Implement new clarified decomposition of Hangul syllables.
16908         * lib/uninorm/decomposition.c (uc_decomposition): For Hangul syllables
16909         of type LTV, return only a pairwise decomposition.
16910         * lib/uninorm/canonical-decomposition.c (uc_canonical_decomposition):
16911         Likewise.
16912         * tests/uninorm/test-decomposition.c (main): Updated expected result.
16913         * tests/uninorm/test-canonical-decomposition.c (main): Likewise.
16914         * tests/uninorm/test-compat-decomposition.c (main): Likewise.
16915
16916 2009-02-22  Bruno Haible  <bruno@clisp.org>
16917
16918         * lib/uninorm/u-normalize-internal.h (FUNC): At the end, handle
16919         zero-length results and shrink excess allocated memory.
16920         * tests/uninorm/test-u8-nfc.c (test_u8_nfc): Check empty string result.
16921         * tests/uninorm/test-u8-nfd.c (test_u8_nfd): Likewise.
16922         * tests/uninorm/test-u8-nfkc.c (test_u8_nfkc): Likewise.
16923         * tests/uninorm/test-u8-nfkd.c (test_u8_nfkd): Likewise.
16924         * tests/uninorm/test-u16-nfc.c (test_u16_nfc): Likewise.
16925         * tests/uninorm/test-u16-nfd.c (test_u16_nfd): Likewise.
16926         * tests/uninorm/test-u16-nfkc.c (test_u16_nfkc): Likewise.
16927         * tests/uninorm/test-u16-nfkd.c (test_u16_nfkd): Likewise.
16928         * tests/uninorm/test-u32-nfc.c (test_u32_nfc): Likewise.
16929         * tests/uninorm/test-u32-nfd.c (test_u32_nfd): Likewise.
16930         * tests/uninorm/test-u32-nfkc.c (test_u32_nfkc): Likewise.
16931         * tests/uninorm/test-u32-nfkd.c (test_u32_nfkd): Likewise.
16932
16933 2009-02-21  Bruno Haible  <bruno@clisp.org>
16934
16935         * doc/gnulib.texi: Include safe-alloc.texi earlier.
16936         * doc/safe-alloc.texi: Terminate sentences with a period. Use two
16937         spaces after a period. Put a space between a macro name and its
16938         argument list. Trivial rewordings.
16939         * lib/safe-alloc.c: Include safe-alloc.h right after config.h.
16940         * tests/test-safe-alloc.c: Likewise. Include stdlib.h.
16941         (main): Return 0 explicitly.
16942
16943 2009-02-21  Bruno Haible  <bruno@clisp.org>
16944
16945         Tests for module 'uninorm/filter'.
16946         * tests/uninorm/test-uninorm-filter-nfc.c: New file.
16947         * modules/uninorm/filter-tests: New file.
16948
16949         New module 'uninorm/filter'.
16950         * lib/uninorm.h (uninorm_filter_create, uninorm_filter_write,
16951         uninorm_filter_flush, uninorm_filter_free): New declarations.
16952         * lib/uninorm/uninorm-filter.c: New file.
16953         * modules/uninorm/filter: New file.
16954
16955 2009-02-21  Bruno Haible  <bruno@clisp.org>
16956
16957         Tests for module 'uninorm/nfkc'.
16958         * tests/uninorm/test-nfkc.c: New file.
16959         * tests/uninorm/test-u8-nfkc.c: New file.
16960         * tests/uninorm/test-u16-nfkc.c: New file.
16961         * tests/uninorm/test-u32-nfkc.c: New file.
16962         * tests/uninorm/test-u32-nfkc-big.sh: New file.
16963         * tests/uninorm/test-u32-nfkc-big.c: New file.
16964         * modules/uninorm/nfkc-tests: New file.
16965
16966         New module 'uninorm/nfkc'.
16967         * lib/uninorm/nfkc.c: New file.
16968         * modules/uninorm/nfkc: New file.
16969
16970         Tests for module 'uninorm/nfkd'.
16971         * tests/uninorm/test-nfkd.c: New file.
16972         * tests/uninorm/test-u8-nfkd.c: New file.
16973         * tests/uninorm/test-u16-nfkd.c: New file.
16974         * tests/uninorm/test-u32-nfkd.c: New file.
16975         * tests/uninorm/test-u32-nfkd-big.sh: New file.
16976         * tests/uninorm/test-u32-nfkd-big.c: New file.
16977         * modules/uninorm/nfkd-tests: New file.
16978
16979         New module 'uninorm/nfkd'.
16980         * lib/uninorm/nfkd.c: New file.
16981         * modules/uninorm/nfkd: New file.
16982
16983         Tests for module 'uninorm/nfc'.
16984         * tests/uninorm/test-nfc.c: New file.
16985         * tests/uninorm/test-u8-nfc.c: New file.
16986         * tests/uninorm/test-u16-nfc.c: New file.
16987         * tests/uninorm/test-u32-nfc.c: New file.
16988         * tests/uninorm/test-u32-nfc-big.sh: New file.
16989         * tests/uninorm/test-u32-nfc-big.c: New file.
16990         * modules/uninorm/nfc-tests: New file.
16991
16992         New module 'uninorm/nfc'.
16993         * lib/uninorm/nfc.c: New file.
16994         * modules/uninorm/nfc: New file.
16995
16996         Tests for module 'uninorm/nfd'.
16997         * tests/uninorm/test-nfd.c: New file.
16998         * tests/uninorm/test-u8-nfd.c: New file.
16999         * tests/uninorm/test-u16-nfd.c: New file.
17000         * tests/uninorm/test-u32-nfd.c: New file.
17001         * tests/uninorm/test-u32-nfd-big.sh: New file.
17002         * tests/uninorm/test-u32-nfd-big.c: New file.
17003         * tests/uninorm/test-u32-normalize-big.h: New file.
17004         * tests/uninorm/test-u32-normalize-big.c: New file.
17005         * tests/uninorm/NormalizationTest.txt: New file, created from
17006         Unicode 5.1.0 NormalizationTest.txt.
17007         * modules/uninorm/nfd-tests: New file.
17008
17009         New module 'uninorm/nfd'.
17010         * lib/uninorm/nfd.c: New file.
17011         * modules/uninorm/nfd: New file.
17012
17013         New module 'uninorm/u32-normalize'.
17014         * lib/uninorm/u32-normalize.c: New file.
17015         * modules/uninorm/u32-normalize: New file.
17016
17017         New module 'uninorm/u16-normalize'.
17018         * lib/uninorm/u16-normalize.c: New file.
17019         * modules/uninorm/u16-normalize: New file.
17020
17021         New module 'uninorm/u8-normalize'.
17022         * lib/uninorm/u8-normalize.c: New file.
17023         * lib/uninorm/normalize-internal.h: New file.
17024         * lib/uninorm/u-normalize-internal.h: New file.
17025         * modules/uninorm/u8-normalize: New file.
17026
17027         New module 'uninorm/decompose-internal'.
17028         * lib/uninorm/decompose-internal.c: New file.
17029         * modules/uninorm/decompose-internal: New file.
17030
17031         Tests for module 'uninorm/composition'.
17032         * tests/uninorm/test-composition.c: New file.
17033         * modules/uninorm/composition-tests: New file.
17034
17035         New module 'uninorm/composition'.
17036         * lib/uninorm/composition.c: New file.
17037         * lib/uninorm/composition-table.gperf: New file, generated by
17038         gen-uni-tables.
17039         * modules/uninorm/composition: New file.
17040
17041         Tests for module 'uninorm/compat-decomposition'.
17042         * tests/uninorm/test-compat-decomposition.c: New file.
17043         * modules/uninorm/compat-decomposition-tests: New file.
17044
17045         New module 'uninorm/compat-decomposition'.
17046         * lib/uninorm/decompose-internal.h: New file.
17047         * lib/uninorm/compat-decomposition.c: New file.
17048         * modules/uninorm/compat-decomposition: New file.
17049
17050         Tests for module 'uninorm/canonical-decomposition'.
17051         * tests/uninorm/test-canonical-decomposition.c: New file.
17052         * modules/uninorm/canonical-decomposition-tests: New file.
17053
17054         New module 'uninorm/canonical-decomposition'.
17055         * lib/uninorm/canonical-decomposition.c: New file.
17056         * modules/uninorm/canonical-decomposition: New file.
17057
17058         Tests for module 'uninorm/decomposition'.
17059         * tests/uninorm/test-decomposition.c: New file.
17060         * modules/uninorm/decomposition-tests: New file.
17061
17062         New module 'uninorm/decomposition'.
17063         * lib/uninorm/decomposition.c: New file.
17064         * modules/uninorm/decomposition: New file.
17065
17066         New module 'uninorm/decomposition-table'.
17067         * lib/uninorm/decomposition-table.h: New file.
17068         * lib/uninorm/decomposition-table.c: New file.
17069         * lib/uninorm/decomposition-table1.h: New file, generated by
17070         gen-uni-tables.
17071         * lib/uninorm/decomposition-table2.h: New file, generated by
17072         gen-uni-tables.
17073         * modules/uninorm/decomposition-table: New file.
17074
17075         * lib/gen-uni-tables.c (MAX_DECOMP_LENGTH): New macro.
17076         (UC_DECOMP_*): New enumeration items.
17077         (get_decomposition): New function.
17078         (struct decomp_table): New type.
17079         (output_decomposition, output_decomposition_tables): New functions.
17080         (unicode_composition_exclusions): New variable.
17081         (fill_composition_exclusions, debug_output_composition_tables): New
17082         functions.
17083         (main): Accept one more argument. Invoke fill_composition_exclusions.
17084         Output decomposition and composition tables.
17085
17086         New module 'uninorm/base'.
17087         * lib/uninorm.h: New file.
17088         * lib/unictype.h: Update comment.
17089         * modules/uninorm/base: New file.
17090
17091 2009-02-21  David Lutterkort  <lutter@redhat.com>
17092
17093         Tests for module 'safe-alloc'.
17094         * tests/test-safe-alloc.c: New file.
17095         * modules/safe-alloc-tests: New file.
17096
17097         New module 'safe-alloc'.
17098         * lib/safe-alloc.h: New file.
17099         * lib/safe-alloc.c: New file.
17100         * m4/safe-alloc.m4: New file.
17101         * modules/safe-alloc: New file.
17102         * doc/safe-alloc.texi: New file.
17103         * doc/gnulib.texi: Include it.
17104         * MODULES.html.sh (Memory management functions <stdlib.h>): Add
17105         safe-alloc.
17106
17107 2009-02-18  Bruno Haible  <bruno@clisp.org>
17108
17109         Fix link error on non-glibc systems.
17110         * modules/uniwbrk/ulc-wordbreaks-tests (test_ulc_wordbreaks_LDADD): New
17111         variable.
17112         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
17113
17114 2009-02-18  Jim Meyering  <meyering@redhat.com>
17115
17116         fts: avoid used-uninitialized error due to recent change
17117         * lib/fts.c (fts_read): Guard uses of the new member,
17118         parent->fts_n_dirs_remaining, since it's not relevant for
17119         the parent of a directory specified on the command-line.
17120
17121 2009-02-17  James Youngman  <jay@gnu.org>
17122             Bruno Haible  <bruno@clisp.org>
17123
17124         * m4/include_next.m4: Reformulate comment.
17125
17126 2009-02-16  Jim Meyering  <meyering@redhat.com>
17127
17128         fts: add #if guards so that the fts_lgpl module still builds
17129         * lib/fts.c: Guard just-added hash-table-using parts with
17130         #if GNULIB_FTS, so as not to break builds of the fts_lgpl module.
17131         Reported by Simon Josefsson.
17132
17133 2009-02-15  Bruno Haible  <bruno@clisp.org>
17134
17135         * modules/array-mergesort-tests: New file.
17136         * tests/test-array-mergesort.c: New file.
17137
17138         New module 'array-mergesort'.
17139         * modules/array-mergesort: New file.
17140         * lib/array-mergesort.h: New file.
17141
17142 2009-02-15  Bruno Haible  <bruno@clisp.org>
17143
17144         Fix 2009-02-07 commit.
17145         * lib/gen-uni-tables.c (output_predicate, output_category,
17146         output_combclass, output_bidi_category, output_decimal_digit,
17147         output_digit, output_numeric, output_mirror, output_scripts,
17148         output_ident_category, output_simple_mapping): Fix format directives.
17149         (output_lbp, output_wbp): Don't convert -1 to a size_t implicitly.
17150
17151 2009-02-15  Albert Chin-A-Young  <china@thewrittenword.com>
17152
17153         * m4/include_next.m4: Update comment about IBM C 9.0/10.1 bug, now that
17154         fixes are available from IBM.
17155
17156 2009-02-13  Jim Meyering  <meyering@redhat.com>
17157
17158         fts: arrange not to stat non-directories in more cases
17159         This makes GNU find (when it doesn't need to stat each file)
17160         *much* more efficient at traversing reiserfs file systems.
17161         * lib/fts_.h (struct ftsent) [fts_n_dirs_remaining]: New member.
17162         (struct FTS) [fts_leaf_optimization_works_ht]: Add member.
17163         * lib/fts.c (fts_close): Free ->fts_leaf_optimization_works_ht.
17164         (S_MAGIC_REISERFS, S_MAGIC_PROC): Define.
17165         (leaf_optimization_applies): New function.
17166         (LCO_hash, LCO_compare): New helper functions.
17167         (link_count_optimize_ok): New function.
17168         (fts_stat): Initialize new member (if dir).
17169         (fts_read): Decrement parent's fts_n_dirs_remaining count if
17170         we've just stat'ed a directory.  Skip the stat call when possible.
17171         ---
17172         Note this AFS-related exchange:
17173         http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=143111
17174         and note find's pioctl call in find/fstype.c.
17175         But that is necessary only if you want to enable the
17176         optimization for AFS, and for now, I don't.
17177
17178         fts: move a function definition "up" (no semantic change)
17179         * lib/fts.c (dirent_inode_sort_may_be_useful): Move definition
17180         "up" to precede upcoming use of a related function.
17181
17182 2009-02-11  Jim Meyering  <meyering@redhat.com>
17183
17184         fts: correct internal computation of nlinks (optimization-related)
17185         * lib/fts.c (fts_build): ISSET(FTS_NOSTAT) has no bearing on
17186         whether the current entry is a directory, so don't test it.
17187
17188 2009-02-10  Bruno Haible  <bruno@clisp.org>
17189
17190         Tests for module 'uniwbrk/ulc-wordbreaks'.
17191         * modules/uniwbrk/ulc-wordbreaks-tests: New file.
17192         * tests/uniwbrk/test-ulc-wordbreaks.sh: New file.
17193         * tests/uniwbrk/test-ulc-wordbreaks.c: New file.
17194
17195         Tests for module 'uniwbrk/u32-wordbreaks'.
17196         * modules/uniwbrk/u32-wordbreaks-tests: New file.
17197         * tests/uniwbrk/test-u32-wordbreaks.c: New file.
17198
17199         Tests for module 'uniwbrk/u16-wordbreaks'.
17200         * modules/uniwbrk/u16-wordbreaks-tests: New file.
17201         * tests/uniwbrk/test-u16-wordbreaks.c: New file.
17202
17203         Tests for module 'uniwbrk/u8-wordbreaks'.
17204         * modules/uniwbrk/u8-wordbreaks-tests: New file.
17205         * tests/uniwbrk/test-u8-wordbreaks.c: New file.
17206
17207 2009-02-10  Bruno Haible  <bruno@clisp.org>
17208
17209         * modules/uniwbrk/u8-wordbreaks (Depends-on): Add uniwbrk/wordbreak
17210         property.
17211         * modules/uniwbrk/u16-wordbreaks (Depends-on): Likewise.
17212         * modules/uniwbrk/u32-wordbreaks (Depends-on): Likewise.
17213         * modules/uniwbrk/ulc-wordbreaks (Depends-on): Add localcharset.
17214
17215 2009-02-10  Simon Josefsson  <simon@josefsson.org>
17216
17217         * m4/sockets.m4: Call AC_C_INLINE since sockets.h now can use
17218         inline keywords.  Reported by Bruno Haible <bruno@clisp.org>.
17219
17220 2009-02-10  Bruno Haible  <bruno@clisp.org>
17221
17222         * lib/unilbrk/lbrktables.h: Renamed from lib/unilbrk/tables.h.
17223         * lib/unilbrk/lbrktables.c: Renamed from lib/unilbrk/tables.c.
17224         * modules/unilbrk/tables (Files, Makefile.am, Include): Update.
17225         * lib/unilbrk/u8-possible-linebreaks.c: Update.
17226         * lib/unilbrk/u16-possible-linebreaks.c: Likewise.
17227         * lib/unilbrk/u32-possible-linebreaks.c: Likewise.
17228
17229 2009-02-09  Simon Josefsson  <simon@josefsson.org>
17230
17231         * lib/sockets.h (gl_fd_to_handle): New function.
17232
17233         * tests/test-sockets.c: Call gl_fd_to_handle.
17234
17235 2009-02-09  Bruno Haible  <bruno@clisp.org>
17236
17237         * doc/havelib.texi: Document the conventions on bi-arch systems.
17238
17239 2009-02-08  Bruno Haible  <bruno@clisp.org>
17240
17241         Document the AC_LIB_LINKFLAGS macro.
17242         * doc/havelib.texi: New file, mostly written on 2005-05-24.
17243         * doc/gnulib.texi: Include it.
17244
17245 2009-02-08  Bruno Haible  <bruno@clisp.org>
17246
17247         Fix wrong order of sections, compared to TOC.
17248         * doc/gnulib.texi: Include relocatable-maint.texi after the
17249         "Regular expressions" node, not before.
17250
17251 2009-02-08  Bruno Haible  <bruno@clisp.org>
17252
17253         Tests for module 'unicase/totitle'.
17254         * modules/unicase/totitle-tests: New file.
17255
17256         Tests for module 'unicase/tolower'.
17257         * modules/unicase/tolower-tests: New file.
17258
17259         Tests for module 'unicase/toupper'.
17260         * modules/unicase/toupper-tests: New file.
17261         * tests/unicase/test-mapping-part1.h: New file.
17262         * tests/unicase/test-mapping-part2.h: New file.
17263
17264         New module 'unicase/totitle'.
17265         * modules/unicase/totitle: New file.
17266         * lib/unicase/totitle.c: New file.
17267
17268         New module 'unicase/tolower'.
17269         * modules/unicase/tolower: New file.
17270         * lib/unicase/tolower.c: New file.
17271
17272         New module 'unicase/toupper'.
17273         * modules/unicase/toupper: New file.
17274         * lib/unicase/toupper.c: New file.
17275         * lib/unicase/simple-mapping.h: New file.
17276
17277         * lib/gen-uni-tables.c (output_simple_mapping_test): New function.
17278         (mapping_table): New structure.
17279         (output_simple_mapping): New function.
17280         (main): Invoke output_simple_mapping_test and output_simple_mapping.
17281         * modules/gen-uni-tables (Description): Update.
17282         * lib/unicase/toupper.h: New file, automatically generated by
17283         gen-uni-tables.
17284         * lib/unicase/tolower.h: New file, automatically generated by
17285         gen-uni-tables.
17286         * lib/unicase/totitle.h: New file, automatically generated by
17287         gen-uni-tables.
17288         * tests/unicase/test-uc_toupper.c: New file, automatically generated by
17289         gen-uni-tables.
17290         * tests/unicase/test-uc_tolower.c: New file, automatically generated by
17291         gen-uni-tables.
17292         * tests/unicase/test-uc_totitle.c: New file, automatically generated by
17293         gen-uni-tables.
17294
17295         New module 'unicase/base'.
17296         * modules/unicase/base: New file.
17297         * lib/unicase.h: New file.
17298
17299 2009-02-08  Bruno Haible  <bruno@clisp.org>
17300
17301         New module 'uniwbrk/ulc-wordbreaks'.
17302         * modules/uniwbrk/ulc-wordbreaks: New file.
17303         * lib/uniwbrk/ulc-wordbreaks.c: New file.
17304
17305         New module 'uniwbrk/u32-wordbreaks'.
17306         * modules/uniwbrk/u32-wordbreaks: New file.
17307         * lib/uniwbrk/u32-wordbreaks.c: New file.
17308
17309         New module 'uniwbrk/u16-wordbreaks'.
17310         * modules/uniwbrk/u16-wordbreaks: New file.
17311         * lib/uniwbrk/u16-wordbreaks.c: New file.
17312
17313         New module 'uniwbrk/u8-wordbreaks'.
17314         * modules/uniwbrk/u8-wordbreaks: New file.
17315         * lib/uniwbrk/u8-wordbreaks.c: New file.
17316         * lib/uniwbrk/u-wordbreaks.h: New file.
17317
17318         New module 'uniwbrk/table'.
17319         * modules/uniwbrk/table: New file.
17320         * lib/uniwbrk/wbrktable.h: New file.
17321         * lib/uniwbrk/wbrktable.c: New file.
17322
17323         New module 'uniwbrk/wordbreak-property'.
17324         * modules/uniwbrk/wordbreak-property: New file.
17325         * lib/uniwbrk/wordbreak-property.c: New file.
17326
17327         * lib/gen-uni-tables.c (WBP_*): New enum items.
17328         (get_wbp, debug_output_wbp, debug_output_wbrk_tables): New functions.
17329         (unicode_org_wbp): New variable.
17330         (fill_org_wbp, debug_output_org_wbp, debug_output_org_wbrk_tables):
17331         New functions.
17332         (wbp_table): New structure.
17333         (output_wbp, output_wbrk_tables): New functions.
17334         (main): Accept additional argument. Invoke fill_org_wbp,
17335         debug_output_wbrk_tables, debug_output_org_wbrk_tables,
17336         output_wbrk_tables.
17337         * modules/gen-uni-tables (Description): Update.
17338         * lib/uniwbrk/wbrkprop.h: New file, automatically generated by
17339         gen-uni-tables.
17340
17341         New module 'uniwbrk/base'.
17342         * modules/uniwbrk/base: New file.
17343         * lib/uniwbrk.h: New file.
17344
17345 2009-02-08  Bruno Haible  <bruno@clisp.org>
17346
17347         Update to Unicode 5.1.0.
17348         * lib/gen-uni-tables.c (is_property_alphabetic): Include
17349         U+2185..U+2188.
17350         (is_property_default_ignorable_code_point): Don't include characters
17351         of category Cc or Cs and not-a-characters.
17352         (get_lbp): Assume REVISION_22. Special handling of U+0609, U+060A,
17353         U+0D79, U+109E, U+109F, U+A60C.
17354         * lib/unictype/bidi_of.h: Regenerated.
17355         * lib/unictype/blocks.h: Regenerated.
17356         * lib/unictype/categ_C.h: Regenerated.
17357         * lib/unictype/categ_Cf.h: Regenerated.
17358         * lib/unictype/categ_Cn.h: Regenerated.
17359         * lib/unictype/categ_L.h: Regenerated.
17360         * lib/unictype/categ_Ll.h: Regenerated.
17361         * lib/unictype/categ_Lm.h: Regenerated.
17362         * lib/unictype/categ_Lo.h: Regenerated.
17363         * lib/unictype/categ_Lu.h: Regenerated.
17364         * lib/unictype/categ_M.h: Regenerated.
17365         * lib/unictype/categ_Mc.h: Regenerated.
17366         * lib/unictype/categ_Me.h: Regenerated.
17367         * lib/unictype/categ_Mn.h: Regenerated.
17368         * lib/unictype/categ_N.h: Regenerated.
17369         * lib/unictype/categ_Nd.h: Regenerated.
17370         * lib/unictype/categ_Nl.h: Regenerated.
17371         * lib/unictype/categ_No.h: Regenerated.
17372         * lib/unictype/categ_P.h: Regenerated.
17373         * lib/unictype/categ_Pd.h: Regenerated.
17374         * lib/unictype/categ_Pe.h: Regenerated.
17375         * lib/unictype/categ_Pf.h: Regenerated.
17376         * lib/unictype/categ_Pi.h: Regenerated.
17377         * lib/unictype/categ_Po.h: Regenerated.
17378         * lib/unictype/categ_Ps.h: Regenerated.
17379         * lib/unictype/categ_S.h: Regenerated.
17380         * lib/unictype/categ_Sk.h: Regenerated.
17381         * lib/unictype/categ_Sm.h: Regenerated.
17382         * lib/unictype/categ_So.h: Regenerated.
17383         * lib/unictype/categ_of.h: Regenerated.
17384         * lib/unictype/combining.h: Regenerated.
17385         * lib/unictype/ctype_alnum.h: Regenerated.
17386         * lib/unictype/ctype_alpha.h: Regenerated.
17387         * lib/unictype/ctype_graph.h: Regenerated.
17388         * lib/unictype/ctype_lower.h: Regenerated.
17389         * lib/unictype/ctype_print.h: Regenerated.
17390         * lib/unictype/ctype_punct.h: Regenerated.
17391         * lib/unictype/ctype_upper.h: Regenerated.
17392         * lib/unictype/decdigit.h: Regenerated.
17393         * lib/unictype/digit.h: Regenerated.
17394         * lib/unictype/mirror.h: Regenerated.
17395         * lib/unictype/numeric.h: Regenerated.
17396         * lib/unictype/pr_alphabetic.h: Regenerated.
17397         * lib/unictype/pr_bidi_arabic_digit.h: Regenerated.
17398         * lib/unictype/pr_bidi_arabic_right_to_left.h: Regenerated.
17399         * lib/unictype/pr_bidi_boundary_neutral.h: Regenerated.
17400         * lib/unictype/pr_bidi_eur_num_terminator.h: Regenerated.
17401         * lib/unictype/pr_bidi_left_to_right.h: Regenerated.
17402         * lib/unictype/pr_bidi_non_spacing_mark.h: Regenerated.
17403         * lib/unictype/pr_bidi_other_neutral.h: Regenerated.
17404         * lib/unictype/pr_combining.h: Regenerated.
17405         * lib/unictype/pr_dash.h: Regenerated.
17406         * lib/unictype/pr_decimal_digit.h: Regenerated.
17407         * lib/unictype/pr_default_ignorable_code_point.h: Regenerated.
17408         * lib/unictype/pr_deprecated.h: Regenerated.
17409         * lib/unictype/pr_diacritic.h: Regenerated.
17410         * lib/unictype/pr_extender.h: Regenerated.
17411         * lib/unictype/pr_format_control.h: Regenerated.
17412         * lib/unictype/pr_grapheme_base.h: Regenerated.
17413         * lib/unictype/pr_grapheme_extend.h: Regenerated.
17414         * lib/unictype/pr_grapheme_link.h: Regenerated.
17415         * lib/unictype/pr_id_continue.h: Regenerated.
17416         * lib/unictype/pr_id_start.h: Regenerated.
17417         * lib/unictype/pr_ideographic.h: Regenerated.
17418         * lib/unictype/pr_ignorable_control.h: Regenerated.
17419         * lib/unictype/pr_lowercase.h: Regenerated.
17420         * lib/unictype/pr_math.h: Regenerated.
17421         * lib/unictype/pr_numeric.h: Regenerated.
17422         * lib/unictype/pr_other_alphabetic.h: Regenerated.
17423         * lib/unictype/pr_other_default_ignorable_code_point.h: Regenerated.
17424         * lib/unictype/pr_other_grapheme_extend.h: Regenerated.
17425         * lib/unictype/pr_other_id_continue.h: Regenerated.
17426         * lib/unictype/pr_other_lowercase.h: Regenerated.
17427         * lib/unictype/pr_other_math.h: Regenerated.
17428         * lib/unictype/pr_punctuation.h: Regenerated.
17429         * lib/unictype/pr_sentence_terminal.h: Regenerated.
17430         * lib/unictype/pr_soft_dotted.h: Regenerated.
17431         * lib/unictype/pr_terminal_punctuation.h: Regenerated.
17432         * lib/unictype/pr_unassigned_code_value.h: Regenerated.
17433         * lib/unictype/pr_unified_ideograph.h: Regenerated.
17434         * lib/unictype/pr_uppercase.h: Regenerated.
17435         * lib/unictype/pr_xid_continue.h: Regenerated.
17436         * lib/unictype/pr_xid_start.h: Regenerated.
17437         * lib/unictype/pr_zero_width.h: Regenerated.
17438         * lib/unictype/scripts.h: Regenerated.
17439         * lib/unictype/scripts_byname.gperf: Regenerated.
17440         * lib/unictype/sy_java_ident.h: Regenerated.
17441         * lib/unilbrk/lbrkprop1.h: Regenerated.
17442         * lib/unilbrk/lbrkprop2.h: Regenerated.
17443         * tests/unictype/test-categ_C.c: Regenerated.
17444         * tests/unictype/test-categ_Cf.c: Regenerated.
17445         * tests/unictype/test-categ_Cn.c: Regenerated.
17446         * tests/unictype/test-categ_L.c: Regenerated.
17447         * tests/unictype/test-categ_Ll.c: Regenerated.
17448         * tests/unictype/test-categ_Lm.c: Regenerated.
17449         * tests/unictype/test-categ_Lo.c: Regenerated.
17450         * tests/unictype/test-categ_Lu.c: Regenerated.
17451         * tests/unictype/test-categ_M.c: Regenerated.
17452         * tests/unictype/test-categ_Mc.c: Regenerated.
17453         * tests/unictype/test-categ_Me.c: Regenerated.
17454         * tests/unictype/test-categ_Mn.c: Regenerated.
17455         * tests/unictype/test-categ_N.c: Regenerated.
17456         * tests/unictype/test-categ_Nd.c: Regenerated.
17457         * tests/unictype/test-categ_Nl.c: Regenerated.
17458         * tests/unictype/test-categ_No.c: Regenerated.
17459         * tests/unictype/test-categ_P.c: Regenerated.
17460         * tests/unictype/test-categ_Pd.c: Regenerated.
17461         * tests/unictype/test-categ_Pe.c: Regenerated.
17462         * tests/unictype/test-categ_Pf.c: Regenerated.
17463         * tests/unictype/test-categ_Pi.c: Regenerated.
17464         * tests/unictype/test-categ_Po.c: Regenerated.
17465         * tests/unictype/test-categ_Ps.c: Regenerated.
17466         * tests/unictype/test-categ_S.c: Regenerated.
17467         * tests/unictype/test-categ_Sk.c: Regenerated.
17468         * tests/unictype/test-categ_Sm.c: Regenerated.
17469         * tests/unictype/test-categ_So.c: Regenerated.
17470         * tests/unictype/test-ctype_alnum.c: Regenerated.
17471         * tests/unictype/test-ctype_alpha.c: Regenerated.
17472         * tests/unictype/test-ctype_graph.c: Regenerated.
17473         * tests/unictype/test-ctype_lower.c: Regenerated.
17474         * tests/unictype/test-ctype_print.c: Regenerated.
17475         * tests/unictype/test-ctype_punct.c: Regenerated.
17476         * tests/unictype/test-ctype_upper.c: Regenerated.
17477         * tests/unictype/test-decdigit.h: Regenerated.
17478         * tests/unictype/test-digit.h: Regenerated.
17479         * tests/unictype/test-numeric.h: Regenerated.
17480         * tests/unictype/test-pr_alphabetic.c: Regenerated.
17481         * tests/unictype/test-pr_bidi_arabic_digit.c: Regenerated.
17482         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Regenerated.
17483         * tests/unictype/test-pr_bidi_boundary_neutral.c: Regenerated.
17484         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Regenerated.
17485         * tests/unictype/test-pr_bidi_left_to_right.c: Regenerated.
17486         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Regenerated.
17487         * tests/unictype/test-pr_bidi_other_neutral.c: Regenerated.
17488         * tests/unictype/test-pr_combining.c: Regenerated.
17489         * tests/unictype/test-pr_dash.c: Regenerated.
17490         * tests/unictype/test-pr_decimal_digit.c: Regenerated.
17491         * tests/unictype/test-pr_default_ignorable_code_point.c: Regenerated.
17492         * tests/unictype/test-pr_deprecated.c: Regenerated.
17493         * tests/unictype/test-pr_diacritic.c: Regenerated.
17494         * tests/unictype/test-pr_extender.c: Regenerated.
17495         * tests/unictype/test-pr_format_control.c: Regenerated.
17496         * tests/unictype/test-pr_grapheme_base.c: Regenerated.
17497         * tests/unictype/test-pr_grapheme_extend.c: Regenerated.
17498         * tests/unictype/test-pr_grapheme_link.c: Regenerated.
17499         * tests/unictype/test-pr_id_continue.c: Regenerated.
17500         * tests/unictype/test-pr_id_start.c: Regenerated.
17501         * tests/unictype/test-pr_ideographic.c: Regenerated.
17502         * tests/unictype/test-pr_ignorable_control.c: Regenerated.
17503         * tests/unictype/test-pr_lowercase.c: Regenerated.
17504         * tests/unictype/test-pr_math.c: Regenerated.
17505         * tests/unictype/test-pr_numeric.c: Regenerated.
17506         * tests/unictype/test-pr_other_alphabetic.c: Regenerated.
17507         * tests/unictype/test-pr_other_default_ignorable_code_point.c:
17508         Regenerated.
17509         * tests/unictype/test-pr_other_grapheme_extend.c: Regenerated.
17510         * tests/unictype/test-pr_other_id_continue.c: Regenerated.
17511         * tests/unictype/test-pr_other_lowercase.c: Regenerated.
17512         * tests/unictype/test-pr_other_math.c: Regenerated.
17513         * tests/unictype/test-pr_punctuation.c: Regenerated.
17514         * tests/unictype/test-pr_sentence_terminal.c: Regenerated.
17515         * tests/unictype/test-pr_soft_dotted.c: Regenerated.
17516         * tests/unictype/test-pr_terminal_punctuation.c: Regenerated.
17517         * tests/unictype/test-pr_unassigned_code_value.c: Regenerated.
17518         * tests/unictype/test-pr_unified_ideograph.c: Regenerated.
17519         * tests/unictype/test-pr_uppercase.c: Regenerated.
17520         * tests/unictype/test-pr_xid_continue.c: Regenerated.
17521         * tests/unictype/test-pr_xid_start.c: Regenerated.
17522         * tests/unictype/test-pr_zero_width.c: Regenerated.
17523
17524         Update to Unicode 5.1.0.
17525         * lib/uniwidth/width.c (nonspacing_table_data): Add U+0487,
17526         U+0616..U+061A, U+0A51, U+0A75, U+0B44, U+0B62..U+0B63, U+0C62..U+0C63,
17527         U+0D44, U+0D62..U+0D63, U+1033..U+1035, U+103A, U+103D..U+103E,
17528         U+105E..U+1060, U+1071..U+1074, U+1082, U+1085..U+1086, U+108D,
17529         U+1B80..U+1B81, U+1BA2..U+1BA5, U+1BA8..U+1BA9, U+1C2C..U+1C33,
17530         U+1C36..U+1C37, U+1DCB..U+1DE6, U+2064, U+20F0, U+2DE0..U+2DFF,
17531         U+A66F..U+A672, U+A67C..U+A67D, U+A8C4, U+A926..U+A92D, U+A947..U+A951,
17532         U+AA29..U+AA2E, U+AA31..U+AA32, U+AA35..U+AA36, U+AA43, U+AA4C,
17533         U+FE24..U+FE26, U+101FD. Remove U+1929..U+192B.
17534         (nonspacing_table_ind): Update.
17535         * tests/uniwidth/test-uc_width2.sh: Update expected result.
17536
17537         Update to Unicode 5.1.0.
17538         * lib/uniname/gen-uninames.lisp (main): Add the range 0x1Fxxx to the
17539         code transform.
17540         * lib/uniname/uniname.c (unicode_character_name,
17541         unicode_name_character): Add the range 0x1Fxxx to the code transform.
17542         * lib/uniname/uninames.h: Regenerated.
17543         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.1.0.
17544
17545 2009-02-07  Bruno Haible  <bruno@clisp.org>
17546
17547         Merge gen-ctype and gen-lbrk into a single program.
17548         * lib/gen-uni-tables.c: New file, incorporating
17549         lib/unictype/gen-ctype.c and lib/unilbrk/gen-lbrk.c.
17550         Add directory prefixes to the names of the generated files.
17551         * lib/unictype/gen-ctype.c: Remove file.
17552         * lib/unilbrk/gen-lbrk.c: Remove file.
17553         * modules/gen-uni-tables: New file.
17554         * modules/unictype/gen-ctype: Remove file.
17555         * modules/unilbrk/gen-lbrk: Remove file.
17556
17557 2009-02-07  Bruno Haible  <bruno@clisp.org>
17558
17559         * lib/unistr.h (u8_strcoll, u16_strcoll, u32_strcoll): New declations.
17560
17561         New module 'unistr/u32-strcoll'.
17562         * modules/unistr/u32-strcoll: New file.
17563         * lib/unistr/u32-strcoll.c: New file.
17564
17565         New module 'unistr/u16-strcoll'.
17566         * modules/unistr/u16-strcoll: New file.
17567         * lib/unistr/u16-strcoll.c: New file.
17568
17569         New module 'unistr/u8-strcoll'.
17570         * modules/unistr/u8-strcoll: New file.
17571         * lib/unistr/u8-strcoll.c: New file.
17572         * lib/unistr/u-strcoll.h: New file.
17573
17574 2009-02-07  Bruno Haible  <bruno@clisp.org>
17575
17576         * test-mbrtowc4.sh (LOCALE_ZH_CN): Fix default value.
17577         * test-mbsnrtowcs4.sh (LOCALE_ZH_CN): Likewise.
17578         * test-mbsrtowcs4.sh (LOCALE_ZH_CN): Likewise.
17579         * test-wcrtomb.sh (LOCALE_ZH_CN): Likewise.
17580         * test-wcsnrtombs4.sh (LOCALE_ZH_CN): Likewise.
17581         * test-wcsrtombs4.sh (LOCALE_ZH_CN): Likewise.
17582
17583 2009-02-07  Bruno Haible  <bruno@clisp.org>
17584
17585         Make 64-bit clean.
17586         * lib/unictype/gen-ctype.c (output_predicate, output_category,
17587         output_combclass, output_bidi_category, output_decimal_digit,
17588         output_digit, output_numeric, output_mirror, output_scripts,
17589         output_ident_category): Use proper width specifier in format strings.
17590
17591 2009-02-07  Bruno Haible  <bruno@clisp.org>
17592
17593         * doc/posix-functions/dirfd.texi: Clarify situation on mingw. Document
17594         failure behaviour.
17595
17596 2009-02-07  Jim Meyering  <meyering@redhat.com>
17597
17598         regex: avoid compilation failure with upcoming gcc-4.4
17599         * lib/regex_internal.h: Revert e48d8b47fb3eee81d341b71c3e006efe9e3433a7
17600         [workaround for PGC prior to 6.1-2].  Otherwise, we'd get this:
17601         "... error: integer overflow in preprocessor expression".
17602
17603 2009-02-05  Ben Pfaff  <blp@gnu.org>
17604
17605         Fix link errors on Windows when close module is used.
17606         * modules/close: Add $(LIB_CLOSE) to Link section.
17607         * m4/close.m4 (gl_REPLACE_CLOSE): Substitute -lws2_32 into
17608         $(LIB_CLOSE) on Windows.
17609
17610 2009-02-05  Jim Meyering  <meyering@redhat.com>
17611
17612         still avoid unused-parameter warnings, but do it cleanly
17613         * lib/fsusage.c (UNUSED_PARAM): Remove definition.
17614         (get_fs_usage): Cast to void instead.
17615         * lib/mountlist.c (UNUSED_PARAM): Remove definition.
17616         (dev_from_mount_options, read_file_system_list): Cast to void.
17617         Prompted by Bruno Haible.
17618
17619 2009-02-04  Jim Meyering  <meyering@redhat.com>
17620
17621         fsusage.c: correct copyright year
17622         * lib/fsusage.c: Reflect year in which the change is pushed into
17623
17624         avoid misc. warnings
17625         * lib/fsusage.c (UNUSED_PARAM): Define.
17626         (get_fs_usage): Mark parameter "disk" as unused.
17627         * lib/getugroups.c (getgrent): Use "void" in prototype.
17628         * lib/mountlist.c: Mark unused parameters.
17629         (read_file_system_list): Declare a local with "const".
17630         * lib/nanosleep.c (getnow): Declare static.
17631         * lib/strftime.c: Include strftime.h, for declaration of nstrftime.
17632
17633         dirfd: set errno upon failure
17634         * lib/dirfd.c: Include <errno.h>.
17635         Set errno to ENOTSUP when returning -1.
17636         * modules/dirfd (Depends-on): Add errno.
17637         Suggested by John Kodis <kodis@comcast.net>.
17638
17639 2009-02-01  Bruno Haible  <bruno@clisp.org>
17640
17641         Don't assume sizeof (long) >= sizeof (void *).
17642         * lib/memcmp.c: Include stdint.h.
17643         (memcmp_bytes): Change argument types to op_t. Change type of srcp1,
17644         srcp2 to 'const byte *'.
17645         (memcmp_common_alignment, memcmp_not_common_alignment): Change argument
17646         types to uintptr_t.
17647         (rpl_memcmp): Change type of srcp1, srcp2 to 'uintptr_t'.
17648         * modules/memcmp (Depends-on): Add stdint.
17649         Reported by Ozkan Sezer <sezeroz@gmail.com>.
17650
17651 2009-01-30  Eric Blake  <ebb9@byu.net>
17652
17653         fix more require-before-expand issues
17654         * m4/pmccabe2html.m4 (gl_PMCCABE2HTML): Require, rather than
17655         expand, AC_PROG_AWK.
17656         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): Use AC_DEFUN_ONCE.
17657
17658 2009-01-28  Eric Blake  <ebb9@byu.net>
17659
17660         version-etc: use consistent URL formatting
17661         * lib/version-etc.c (emit_bug_reporting_address, version_etc_va):
17662         Improve formatting.  Use fputs for string without %.
17663
17664 2009-01-28  Jim Meyering  <meyering@redhat.com>
17665
17666         00gnulib.m4: add m4 quotes in shell comment to avoid autoconf warning
17667         * m4/00gnulib.m4 (AC_DEFUN_ONCE): Add quotes to avoid an
17668         "underquoted definition of NAME" from autoconf-2.59.
17669
17670 2009-01-28  Bruno Haible  <bruno@clisp.org>
17671
17672         * doc/gnulib.texi: Add "Obsolete modules" to index.
17673
17674 2009-01-28  Jim Meyering  <meyering@redhat.com>
17675
17676         useless-if-before-free: recognize more variants
17677         * build-aux/useless-if-before-free: Also recognize e.g.,
17678         if (NULL != p) free (p);
17679
17680 2009-01-27  Mark McLoughlin  <markmc@redhat.com>
17681
17682         test-getaddrinfo: skip (don't fail) this test when there's no network
17683         * tests/test-getaddrinfo.c: Skip test upon failure with EAI_AGAIN,
17684         on the presumption that it means you lack network access.
17685
17686 2009-01-26  Jim Meyering  <meyering@redhat.com>
17687
17688         fflush: avoid warnings on modern systems
17689         * lib/fflush.c (rpl_fflush): Move declarations of locals,
17690         pos and result, into scopes where they're used.
17691
17692 2009-01-26  Eric Blake  <ebb9@byu.net>
17693
17694         Silence warning reintroduced by recent extensions patch.
17695         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS)
17696         (gl_USE_SYSTEM_EXTENSIONS): Use AC_DEFUN_ONCE to silence newer
17697         autoconf.
17698
17699         Backport improved autoconf semantics of AC_DEFUN_ONCE.
17700         * m4/00gnulib.m4: New file.
17701         * gnulib-tool (func_get_filelist): Always use it.
17702         * m4/gnulib-common.m4 (gl_COMMON): Force the file to be used.
17703         Reported by Bruno Haible, with suggestions from Paolo Bonzini.
17704
17705 2009-01-25  Bruno Haible  <bruno@clisp.org>
17706
17707         Make test-quotearg work on MacOS X and AIX.
17708         * tests/test-quotearg.sh: New file.
17709         * tests/locale/fr/LC_MESSAGES/test-quotearg.po: New file.
17710         * tests/locale/fr/LC_MESSAGES/test-quotearg.mo: New file.
17711         * tests/test-quotearg.c: Include <locale.h> and gettext.h. Don't
17712         include <libintl.h>.
17713         (fake_locale): Remove variable.
17714         (gettext, dgettext, dcgettext): Remove functions.
17715         (main): Instead of setting a fake locale, set a real locale. Call
17716         textdomain and bindtextdomain.
17717         * modules/quotearg-tests (Files): Add the new files.
17718         (Depends-on): Add gettext, setenv, unsetenv.
17719         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
17720         (Makefile.am): Add test-quotearg.sh to TESTS, remove test-quotearg.
17721         Augment TESTS_ENVIRONMENT.
17722
17723 2009-01-25  Bruno Haible  <bruno@clisp.org>
17724
17725         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove special code that hid the
17726         fr_FR.ISO8859-1 locale on MacOS X.
17727         * m4/locale-ja.m4 (gt_LOCALE_JA): Remove special code that hid the
17728         ja_JP.eucJP locale on MacOS X.
17729         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Remove special code that hid the
17730         zh_CN.GB18030 locale on MacOS X.
17731
17732 2009-01-25  Bruno Haible  <bruno@clisp.org>
17733
17734         Avoid link errors on MacOS X 10.3.
17735         * lib/mbsrtowcs-state.c (_gl_mbsrtowcs_state): Add initializer.
17736         * lib/wcsrtombs-state.c (_gl_wcsrtombs_state): Likewise.
17737
17738 2009-01-25  Bruno Haible  <bruno@clisp.org>
17739
17740         * lib/pipe.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
17741         * m4/pipe.m4 (gl_PIPE): Remove tests for vfork() based code.
17742         * modules/pipe (Files): Remove m4/posix_spawn.m4.
17743         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
17744         posix_spawn_file_actions_addclose, posix_spawn_file_actions_adddup2,
17745         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
17746         posix_spawnattr_init, posix_spawnattr_setsigmask,
17747         posix_spawnattr_setflags, posix_spawnattr_destroy.
17748
17749         * lib/execute.c: On Unix, assume HAVE_POSIX_SPAWN and use posix_spawnp.
17750         * m4/execute.m4 (gl_EXECUTE): Remove tests for vfork() based code.
17751         * modules/execute (Files): Remove m4/posix_spawn.m4.
17752         (Depends-on): Add spawn, posix_spawnp, posix_spawn_file_actions_init,
17753         posix_spawn_file_actions_addopen, posix_spawn_file_actions_destroy,
17754         posix_spawnattr_init, posix_spawnattr_setsigmask,
17755         posix_spawnattr_setflags, posix_spawnattr_destroy.
17756
17757 2009-01-25  Bruno Haible  <bruno@clisp.org>
17758
17759         * lib/glthread/threadlib.c: Include <stdlib.h>.
17760
17761 2009-01-25  Bruno Haible  <bruno@clisp.org>
17762
17763         * lib/glthread/threadlib.c (dummy): New declaration.
17764
17765 2009-01-25  Bruno Haible  <bruno@clisp.org>
17766
17767         * lib/mbrtowc.c (mbrtowc): Distinguish invalid and incomplete
17768         multibyte characters also for the GB18030 encoding. Don't crash when
17769         the encoding is unknown and nstate = 0. Needed on OSF/1 5.1.
17770
17771 2009-01-25  Bruno Haible  <bruno@clisp.org>
17772
17773         Avoid redefining 'struct random_data' on OSF/1 5.1.
17774         * lib/stdlib.in.h: Include <random.h> if it exists.
17775         * m4/stdlib_h.m4 (gl_STDLIB_H): Test whether <random.h> exists. Set
17776         HAVE_RANDOM_H. Include <random.h> when testing whether
17777         'struct random_data' exists.
17778         * modules/stdlib (Makefile.am): Substitute HAVE_RANDOM_H.
17779
17780 2009-01-25  Bruno Haible  <bruno@clisp.org>
17781
17782         Don't install charset.alias on MacOS X >= 10.3.
17783         * lib/localcharset.c (DARWIN7): New macro.
17784         (get_charset_aliases): Hardcode the result for Darwin7.
17785         * modules/localcharset (install-exec-local): Don't install
17786         charset.alias on MacOS X >= 10.3, if the file does not yet exist.
17787
17788 2009-01-25  Bruno Haible  <bruno@clisp.org>
17789
17790         Don't install charset.alias on mingw and Cygwin.
17791         * modules/localcharset (install-exec-local): Don't install
17792         charset.alias on mingw and Cygwin, if the file does not yet exist.
17793         The result for these platforms is hardcoded in localcharset.c.
17794
17795 2009-01-25  Bruno Haible  <bruno@clisp.org>
17796
17797         Make it possible again to use AC_GNU_SOURCE together with gnulib.
17798         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_GNU_SOURCE
17799         before requiring AC_USE_SYSTEM_EXTENSIONS.
17800
17801 2009-01-25  Jim Meyering  <meyering@redhat.com>
17802
17803         c-strtod: avoid warnings
17804         * lib/c-strtod.c (C_STRTOD): Cast nptr to (char *) to avoid
17805         "assignment discards qualifiers from pointer target type" warnings.
17806
17807 2009-01-24  Bruno Haible  <bruno@clisp.org>
17808
17809         Add support for non-UTF-8 locales on MacOS X.
17810         * lib/config.charset: Add CP1131, ARMSCII-8, PT154 to the list of
17811         canonical encodings. For Darwin 7 and newer, don't map traditional
17812         encodings to UTF-8.
17813         Reported by Vincent Lefevre <vincent@vinc17.org>
17814         at <http://savannah.gnu.org/bugs/?25235>.
17815
17816 2009-01-24  Bruno Haible  <bruno@clisp.org>
17817
17818         * doc/gnulib.texi (Obsolete modules): New section.
17819         Reported by Mike Frysinger <vapier@gentoo.org>.
17820
17821 2009-01-24  Bruno Haible  <bruno@clisp.org>
17822
17823         * doc/Makefile (%.pdf): Clarify where to find texmf.cnf.
17824         (%.dvi): New rule.
17825
17826 2009-01-24  Bruno Haible  <bruno@clisp.org>
17827
17828         * lib/c-strtod.h (c_strtod, c_strtold): Adjust specification.
17829         Reported by Eric Blake.
17830
17831 2009-01-24  Bruno Haible  <bruno@clisp.org>
17832
17833         * lib/c-stack.c (segv_handler): If !HAVE_XSI_STACK_OVERFLOW_HEURISTIC,
17834         set signo = 0 also if info->si_code <= 0. Needed on HP-UX 11.11.
17835         Reported by Gary V. Vaughan <gary@gnu.org>.
17836
17837 2009-01-24  Bruno Haible  <bruno@clisp.org>
17838
17839         * lib/c-strtod.h (c_strtod, c_strtold): Add specification.
17840
17841 2009-01-23  Bruno Haible  <bruno@clisp.org>
17842
17843         Make c-strtod, c-strtold usable in libraries.
17844         * lib/c-strtod.c: Include string.h instead of xalloc.h.
17845         (C_STRTOD): Call strdup instead of xstrdup.
17846         * modules/c-strtod (Depends-on): Add strdup-posix, remove xalloc.
17847         * modules/c-strtold (Depends-on): Likewise.
17848         * doc/c-strtod.texi: Remove the sentence mentioning xalloc_die.
17849         * NEWS: Mention the change.
17850         Reported by Michael Gold <mgold@ncf.ca>.
17851
17852 2009-01-23  Jim Meyering  <meyering@redhat.com>
17853
17854         c-strtod: when ENDPTR is non-NULL, set *ENDPTR in new failure path
17855         * lib/c-strtod.c (C_STRTOD) [LC_ALL_MASKC]: Ensure that when
17856         ENDPTR is non-NULL, *ENDPTR is set to NPTR upon failure.
17857
17858 2009-01-23  Simon Josefsson  <simon@josefsson.org>
17859
17860         * lib/version-etc.c: Add emit_bug_reporting_address, inspired by
17861         GNU CoreUtils.
17862         * lib/version-etc.h: Add prototype for emit_bug_reporting_address.
17863         * modules/version-etc (Description): Update.
17864
17865 2009-01-22  Bruno Haible  <bruno@clisp.org>
17866
17867         Cache the C locale object.
17868         * lib/c-strtod.c (c_locale_cache): New variable.
17869         (c_locale): New function.
17870         (C_STRTOD): Use it, and don't call freelocale.
17871         * m4/c-strtod.m4 (gl_C_STRTOD, gl_C_STRTOLD): Require AC_C_INLINE.
17872         Suggested by Paolo Bonzini.
17873
17874 2009-01-21  Bruno Haible  <bruno@clisp.org>
17875
17876         * lib/getloadavg.c (getloadavg): Check c_strtod result against error
17877         conditions other than overflow.
17878
17879 2009-01-21  Bruno Haible  <bruno@clisp.org>
17880
17881         * lib/c-strtod.c: Include errno.h.
17882         (C_STRTOD): Check against NULL return from newlocale. Preserve errno
17883         value from STRTOD_L and STRTOD.
17884
17885 2009-01-21  Bruno Haible  <bruno@clisp.org>
17886         and Jim Meyering  <meyering@redhat.com>
17887
17888         nanosleep: skip configure test (fail it) for apple universal builds
17889         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_MULTIARCH. In Apple
17890         universal builds, assume that nanosleep does not work.
17891         * modules/nanosleep (Depends-on): Add multiarch.
17892
17893         mktime: skip configure test (fail it) for apple universal builds
17894         * m4/mktime.m4 (AC_FUNC_MKTIME): Require gl_MULTIARCH. In Apple
17895         universal builds, assume that mktime does not work.
17896         * modules/mktime (Depends-on): Add multiarch.
17897
17898 2009-01-21  Eric Blake  <ebb9@byu.net>
17899
17900         multiarch: avoid expand-before-require warning
17901         * modules/multiarch (configure.ac): Require, rather than expand,
17902         gl_MULTIARCH.
17903         * m4/multiarch.m4 (gl_MULTIARCH_BODY): Merge...
17904         (gl_MULTIARCH): ...into this macro, and use AC_DEFUN_ONCE to
17905         enforce that all clients require it.  Partial reversion of
17906         2008-12-29 patch.
17907
17908         error: avoid expand-before-require warning
17909         * modules/errno (configure.ac): Require, rather than expand,
17910         gl_HEADER_ERRNO_H.
17911         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Merge...
17912         (gl_HEADER_ERRNO_H): ...into this macro, and use AC_DEFUN_ONCE to
17913         enforce that all clients require it.
17914
17915         gnulib-tool: avoid warnings from using obsolete AC_GNU_SOURCE
17916         * gnulib-tool (func_dest_tmpfilename, func_create_testdir): Using
17917         obsolete AC_GNU_SOURCE causes out-of-order expansion; avoid it,
17918         and rely solely on gl_USE_SYSTEM_EXTENSIONS.
17919
17920 2009-01-21  Paolo Bonzini  <bonzini@gnu.org>
17921
17922         Revert:
17923         2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
17924
17925         regex: do not depend on obsolete modules.
17926         * modules/regex: Remove memcmp and memmove.
17927
17928 2009-01-20  Bruno Haible  <bruno@clisp.org>
17929
17930         Make the 'link' module link on Windows NT 4.
17931         * lib/link.c (_WIN32_WINNT): Don't define.
17932         (CreateHardLinkFuncType): New type.
17933         (CreateHardLinkFunc, initialized): New variables.
17934         (initialize): New function.
17935         (link): Invoke CreateHardLink indirectly through the function pointer.
17936
17937 2009-01-20  Bruno Haible  <bruno@clisp.org>
17938
17939         Fix compilation failure on mingw.
17940         * tests/test-link.c (main): Don't assume that EOPNOTSUPP exists.
17941
17942 2009-01-20  Michael Gold  <mgold@ncf.ca>  (tiny change)
17943
17944         * doc/c-strtod.texi: Mention a couple of restrictions.
17945
17946 2009-01-20  Jim Meyering  <meyering@redhat.com>
17947
17948         gettimeofday: move more declarations out of functions
17949         * lib/gettimeofday.c: Move extern declarations of tzset and
17950         gmtime out of containing functions.  Prompted by Bruno Haible.
17951
17952 2009-01-20  Paolo Bonzini  <bonzini@gnu.org>
17953
17954         regex: do not depend on obsolete modules.
17955         * modules/regex: Remove memcmp and memmove.
17956
17957 2009-01-19  Bruno Haible  <bruno@clisp.org>
17958
17959         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
17960         * modules/uniconv/u16-conv-from-enc (configure.ac): Require
17961         gl_BIGENDIAN, not AC_C_BIGENDIAN.
17962         * modules/uniconv/u16-conv-to-enc (configure.ac): Likewise.
17963         * modules/uniconv/u16-strconv-to-enc (configure.ac): Likewise.
17964
17965 2009-01-19  Bruno Haible  <bruno@clisp.org>
17966
17967         * tests/test-link.c: Include <errno.h>.
17968         (main): Exit with code 77 when a hard link cannot be created due to
17969         the file system.
17970         * tests/test-link.sh: Skip test when a hard link cannot be created due
17971         to the file system.
17972         Suggested by Eric Blake.
17973
17974 2009-01-19  Martin Lambers  <marlam@marlam.de>
17975
17976         * modules/link-tests: New file.
17977         * tests/test-link.sh: New file.
17978         * tests/test-link.c: New file.
17979
17980 2009-01-19  Eric Blake  <ebb9@byu.net>
17981
17982         doc: mention another function added in cygwin 1.7.0
17983         * doc/glibc-functions/glob_pattern_p.texi (glob_pattern_p):
17984         Another new function in cygwin 1.7.
17985
17986 2009-01-19  Bruno Haible  <bruno@clisp.org>
17987
17988         Don't use AC_REQUIRE([AC_C_BIGENDIAN]).
17989         * m4/gnulib-common.m4 (gl_BIGENDIAN): New macro.
17990         * m4/exponentl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require
17991         gl_BIGENDIAN, not AC_C_BIGENDIAN.
17992         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): Likewise.
17993         * m4/isinf.m4 (gl_ISINFL_WORKS): Likewise.
17994         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Likewise.
17995         * m4/md4.m4 (gl_MD4): Likewise.
17996         * m4/md5.m4 (gl_MD5): Likewise.
17997         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Likewise.
17998         * m4/sha1.m4 (gl_SHA1): Likewise.
17999         * m4/sha256.m4 (gl_SHA256): Likewise.
18000         * m4/sha512.m4 (gl_SHA512): Likewise.
18001
18002 2009-01-19  Bruno Haible  <bruno@clisp.org>
18003
18004         * modules/uniname/uniname-tests (Depends-on): Add progname.
18005         * tests/uniname/test-uninames.c: Include progname.h.
18006         (main): Call set_program_name.
18007
18008         * modules/unistdio/u8-vsprintf-tests (Depends-on): Add progname.
18009         * tests/unistdio/test-u8-vsprintf1.c: Include progname.h.
18010         (main): Call set_program_name.
18011
18012         * modules/unistdio/u8-vsnprintf-tests (Depends-on): Add progname.
18013         * tests/unistdio/test-u8-vsnprintf1.c: Include progname.h.
18014         (main): Call set_program_name.
18015
18016         * modules/unistdio/u16-vsprintf-tests (Depends-on): Add progname.
18017         * tests/unistdio/test-u16-vsprintf1.c: Include progname.h.
18018         (main): Call set_program_name.
18019
18020         * modules/unistdio/u16-vsnprintf-tests (Depends-on): Add progname.
18021         * tests/unistdio/test-u16-vsnprintf1.c: Include progname.h.
18022         (main): Call set_program_name.
18023
18024         * modules/unistdio/u32-vsprintf-tests (Depends-on): Add progname.
18025         * tests/unistdio/test-u32-vsprintf1.c: Include progname.h.
18026         (main): Call set_program_name.
18027
18028         * modules/unistdio/u32-vsnprintf-tests (Depends-on): Add progname.
18029         * tests/unistdio/test-u32-vsnprintf1.c: Include progname.h.
18030         (main): Call set_program_name.
18031
18032         * modules/unistdio/ulc-vsprintf-tests (Depends-on): Add progname.
18033         * tests/unistdio/test-ulc-vsprintf1.c: Include progname.h.
18034         (main): Call set_program_name.
18035
18036         * modules/unistdio/ulc-vsnprintf-tests (Depends-on): Add progname.
18037         * tests/unistdio/test-ulc-vsnprintf1.c: Include progname.h.
18038         (main): Call set_program_name.
18039
18040 2009-01-19  Eric Blake  <ebb9@byu.net>
18041
18042         test-unistd: test previous patch
18043         * tests/test-unistd.c: Test *_FILENO macros.
18044
18045         unistd: guarantee STDIN_FILENO here, for OS/2 EMX
18046         * lib/unistd.in.h (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
18047         Guarantee a definition.
18048         * doc/posix-headers/unistd.texi (unistd.h): Document the bug.
18049         * modules/unistd-safer (Depends-on): Add dependency on unistd.
18050         * lib/c-stack.c (STDERR_FILENO): Rely on <unistd.h>.
18051         * lib/dup-safer.c (STDERR_FILENO): Likewise.
18052         * lib/execute.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
18053         Likewise.
18054         * lib/fd-safer.c (STDIN_FILENO, STDERR_FILENO): Likewise.
18055         * lib/fopen-safer.c (STDERR_FILENO): Likewise.
18056         * lib/pipe.c (STDIN_FILENO, STDOUT_FILENO, STDERR_FILENO):
18057         Likewise.
18058         * lib/tmpfile-safer.c (STDERR_FILENO): Likewise.
18059         * tests/test-posix_spawn1.c (STDIN_FILENO, STDOUT_FILENO)
18060         (STDERR_FILENO): Likewise.
18061         * tests/test-posix_spawn2.c (STDIN_FILENO, STDOUT_FILENO)
18062         (STDERR_FILENO): Likewise.
18063         * tests/test-posix_spawn3.c (STDIN_FILENO, STDOUT_FILENO)
18064         (STDERR_FILENO): Likewise.
18065         Reported by Elbert Pol.
18066
18067 2009-01-19  Eric Blake  <ebb9@byu.net>
18068
18069         doc: mention more functions added in cygwin 1.7.0
18070         * doc/posix-functions/abort.texi (abort): Update wording related
18071         to cygwin.
18072         * doc/posix-functions/daylight.texi (daylight): Likewise.
18073         * doc/posix-functions/optarg.texi (optarg): Likewise.
18074         * doc/posix-functions/optarg.texi (opterr): Likewise.
18075         * doc/posix-functions/optarg.texi (optind): Likewise.
18076         * doc/posix-functions/optarg.texi (optopt): Likewise.
18077         * doc/posix-functions/wprintf.texi (wprintf): Cygwin wprintf never
18078         worked in 1.5.x, and was withdrawn in 1.7.
18079         * doc/posix-functions/vwprintf.texi (vwprintf): Likewise.
18080         * doc/posix-functions/fprintf.texi (fprintf): Tighten mention of
18081         cygwin versions.
18082         * doc/posix-functions/perror.texi (perror): Likewise.
18083         * doc/posix-functions/printf.texi (printf): Likewise.
18084         * doc/posix-functions/snprintf.texi (snprintf): Likewise.
18085         * doc/posix-functions/sprintf.texi (sprintf): Likewise.
18086         * doc/posix-functions/vfprintf.texi (vfprintf): Likewise.
18087         * doc/posix-functions/vprintf.texi (vprintf): Likewise.
18088         * doc/posix-functions/vsnprintf.texi (vsnprintf): Likewise.
18089         * doc/posix-functions/vsprintf.texi (vsprintf): Likewise.
18090         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
18091         Likewise.
18092         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
18093         Likewise.
18094         * doc/glibc-functions/cfmakeraw.texi (cfmakeraw): Cygwin 1.7 adds
18095         this function.
18096         * doc/glibc-functions/in6addr_any.texi (in6addr_any): Likewise.
18097         * doc/glibc-functions/in6addr_loopback.texi (in6addr_loopback):
18098         Likewise.
18099         * doc/glibc-functions/updwtmpx.texi (updwtmpx): Likewise.
18100         * doc/posix-functions/_Exit_C99.texi (_Exit): Likewise.
18101         * doc/posix-functions/confstr.texi (confstr): Likewise.
18102         * doc/posix-functions/dprintf.texi (dprintf): Likewise.
18103         * doc/posix-functions/fgetwc.texi (fgetwc): Likewise.
18104         * doc/posix-functions/fgetws.texi (fgetws): Likewise.
18105         * doc/posix-functions/fputwc.texi (fputwc): Likewise.
18106         * doc/posix-functions/fputws.texi (fputws): Likewise.
18107         * doc/posix-functions/fwide.texi (fwide): Likewise.
18108         * doc/posix-functions/getwc.texi (getwc): Likewise.
18109         * doc/posix-functions/getwchar.texi (getwchar): Likewise.
18110         * doc/posix-functions/putwc.texi (putwc): Likewise.
18111         * doc/posix-functions/putwchar.texi (putwchar): Likewise.
18112         * doc/posix-functions/sigignore.texi (sigignore): Likewise.
18113         * doc/posix-functions/ungetwc.texi (ungetwc): Likewise.
18114         * doc/posix-functions/vdprintf.texi (vdprintf): Likewise.
18115         * doc/posix-functions/wcpcpy.texi (wcpcpy): Likewise.
18116         * doc/posix-functions/wcpncpy.texi (wcpncpy): Likewise.
18117         * doc/posix-functions/wcstol.texi (wcstol): Likewise.
18118         * doc/posix-functions/wcstoll.texi (wcstoll): Likewise.
18119         * doc/posix-functions/wcstoul.texi (wcstoul): Likewise.
18120         * doc/posix-functions/wcstoull.texi (wcstoull): Likewise.
18121         * doc/posix-functions/wcsxfrm.texi (wcsxfrm): Likewise.
18122
18123 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
18124
18125         ioctl: avoid warning: no previous prototype for 'rpl_ioctl'
18126         * lib/ioctl.c: Include <sys/ioctl.h>.
18127
18128 2009-01-19  Simon Josefsson  <simon@josefsson.org>
18129
18130         * modules/getdate-tests (Depends-on): Add progname.
18131         * tests/test-getdate.c: Use progname module, to avoid link errors
18132         on non-glibc systems.
18133
18134 2009-01-18  Simon Josefsson  <simon@josefsson.org>
18135
18136         * modules/filenamecat-tests (Depends-on): Add progname.
18137         * modules/fstrcmp-tests (Depends-on): Likewise.
18138
18139         * tests/test-filenamecat.c: Use progname module, to avoid link
18140         errors on non-glibc systems.
18141         * tests/test-fstrcmp.c: Likewise.
18142
18143 2009-01-19  Daniel P. Berrange  <berrange@redhat.com>
18144
18145         gettimeofday: avoid warning: nested extern declaration of 'localtime'
18146         * lib/gettimeofday.c: Move extern declaration out of function.
18147
18148 2009-01-18  Bruno Haible  <bruno@clisp.org>
18149
18150         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mblen and mbrlen.
18151         * lib/strftime.c (HAVE_MBLEN, HAVE_MBRLEN): Remove macros.
18152         (MULTIBYTE_IS_FORMAT_SAFE): Define to 1 on all platforms except OSF/1.
18153
18154 2009-01-18  Bruno Haible  <bruno@clisp.org>
18155
18156         * lib/strftime.c (MEMPCPY): Remove unused macro.
18157         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't test for mempcpy.
18158
18159 2009-01-18  Martin Lambers  <marlam@marlam.de>
18160
18161         New module 'link'.
18162         * lib/unistd.in.h (link): New declaration.
18163         * lib/link.c: New file.
18164         * m4/link.m4: New file.
18165         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_LINK,
18166         HAVE_LINK.
18167         * modules/unistd (Makefile.am): Substitute GNULIB_LINK, HAVE_LINK.
18168         * modules/link: New file.
18169         * doc/posix-functions/link.texi: Mention the new module.
18170
18171 2009-01-18  Bruno Haible  <bruno@clisp.org>
18172
18173         * tests/test-avltree_list.c (main): Call set_program_name.
18174         * tests/test-avltree_oset.c (main): Likewise.
18175         * tests/test-obstack-printf.c: Include progname.h.
18176         (main): Call set_program_name.
18177         * tests/test-quotearg.c: Include progname.h.
18178         (main): Call set_program_name.
18179         * tests/test-xmemdup0.c: Include progname.h.
18180         (main): Call set_program_name.
18181
18182 2009-01-18  Bruno Haible  <bruno@clisp.org>
18183
18184         New module 'alphasort'.
18185         * lib/dirent.in.h (alphasort): New declaration.
18186         * lib/alphasort.c: New file, from glibc with modifications.
18187         * m4/alphasort.m4: New file.
18188         * modules/alphasort: New file.
18189         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_ALPHASORT,
18190         HAVE_ALPHASORT.
18191         * modules/dirent (Makefile.am): Substitute GNULIB_ALPHASORT,
18192         HAVE_ALPHASORT.
18193         * doc/posix-functions/alphasort.texi: Mention the new module and the
18194         portability problems.
18195
18196 2009-01-18  Bruno Haible  <bruno@clisp.org>
18197
18198         New module 'scandir'.
18199         * lib/dirent.in.h (scandir): New declaration.
18200         * lib/scandir.c: New file, from glibc with modifications.
18201         * m4/scandir.m4: New file.
18202         * modules/scandir: New file.
18203         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_SCANDIR,
18204         HAVE_SCANDIR.
18205         * modules/dirent (Makefile.am): Substitute GNULIB_SCANDIR,
18206         HAVE_SCANDIR.
18207         * doc/posix-functions/scandir.texi: Mention the new module and the
18208         portability problems.
18209
18210 2009-01-17  Bruno Haible  <bruno@clisp.org>
18211
18212         * gnulib-tool (func_remove_prefix): Escape all dots in the prefix.
18213         Update documentation.
18214         (func_remove_suffix): Escape all dots in the suffix. Update
18215         documentation.
18216         (func_filter_filelist): Update documentation.
18217         Reported by Ralf Wildenhues.
18218
18219 2009-01-17  Bruno Haible  <bruno@clisp.org>
18220
18221         * modules/dprintf-posix-tests: New file.
18222         * tests/test-dprintf-posix.sh: New file.
18223         * tests/test-dprintf-posix.c: New file.
18224
18225         New modules 'dprintf', 'dprintf-posix'.
18226         * lib/stdio.in.h (dprintf): New declaration.
18227         * lib/dprintf.c: New file.
18228         * m4/dprintf.m4: New file.
18229         * m4/dprintf-posix.m4: New file.
18230         * modules/dprintf: New file.
18231         * modules/dprintf-posix: New file.
18232         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_DPRINTF,
18233         HAVE_DPRINTF, REPLACE_DPRINTF.
18234         * modules/stdio (Makefile.am): Substitute also GNULIB_DPRINTF,
18235         HAVE_DPRINTF, REPLACE_DPRINTF.
18236         * doc/posix-functions/dprintf.texi: Mention the new modules.
18237
18238 2009-01-17  Bruno Haible  <bruno@clisp.org>
18239
18240         * modules/vdprintf-posix-tests: New file.
18241         * tests/test-vdprintf-posix.sh: New file.
18242         * tests/test-vdprintf-posix.c: New file.
18243
18244         New modules 'vdprintf', 'vdprintf-posix'.
18245         * lib/stdio.in.h (vdprintf): New declaration.
18246         * lib/vdprintf.c: New file.
18247         * m4/vdprintf.m4: New file.
18248         * m4/vdprintf-posix.m4: New file.
18249         * modules/vdprintf: New file.
18250         * modules/vdprintf-posix: New file.
18251         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_VDPRINTF,
18252         HAVE_VDPRINTF, REPLACE_VDPRINTF.
18253         * modules/stdio (Makefile.am): Substitute also GNULIB_VDPRINTF,
18254         HAVE_VDPRINTF, REPLACE_VDPRINTF.
18255         * doc/posix-functions/vdprintf.texi: Mention the new modules.
18256
18257 2009-01-17  Bruno Haible  <bruno@clisp.org>
18258
18259         Fix replacement of fopen on mingw.
18260         * m4/fopen.m4 (gl_FUNC_FOPEN): Define FOPEN_TRAILING_SLASH_BUG also on
18261         mingw.
18262
18263 2009-01-17  Bruno Haible  <bruno@clisp.org>
18264
18265         Fix compilation error on HP-UX 11.00, present since 2008-09-24.
18266         * lib/fopen.c: Include <sys/types.h> and <sys/types.h>.
18267
18268 2009-01-17  Bruno Haible  <bruno@clisp.org>
18269
18270         Avoid test-fflush2.sh failure on mingw.
18271         * tests/test-fflush2.c: Include binary-io.h.
18272         (main): Put standard input into binary mode.
18273         * modules/fflush-tests (Depends-on): Add binary-io.
18274
18275 2009-01-17  Bruno Haible  <bruno@clisp.org>
18276
18277         * lib/wchar.in.h: In another particular situation, include only the
18278         system's <wchar.h> file.
18279         (_GL_ALREADY_INCLUDING_WCHAR_H): New macro.
18280         Reported by Albert Chin-A-Young <china@thewrittenword.com>
18281         and Thomas Guyot-Sionnest <dermoth@aei.ca>.
18282
18283 2009-01-17  Bruno Haible  <bruno@clisp.org>
18284
18285         Support for stripping executables in --enable-relocatable.
18286         * build-aux/install-reloc: Expect one more argument, or an environment
18287         variable RELOC_STRIP_PROG. If set, strip the destination program and
18288         its wrapper.
18289         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV, set
18290         RELOC_STRIP_PROG.
18291         * doc/relocatable-maint.texi (Supporting Relocation): Mention the need
18292         to set RELOCATABLE_STRIP.
18293         * NEWS: Mention the new Makefile requirement.
18294
18295 2009-01-17  Bruno Haible  <bruno@clisp.org>
18296
18297         * build-aux/install-reloc: Remove debugging information left over by
18298         C compiler on MacOS X.
18299
18300 2009-01-17  Bruno Haible  <bruno@clisp.org>
18301
18302         Update use of _NSGetExecutablePath after API change in MacOS X 10.4.
18303         * lib/progreloc.c (find_executable): Fix type of pointer passed to
18304         _NSGetExecutablePath.
18305
18306 2009-01-16  Jim Meyering  <meyering@redhat.com>
18307
18308         strerror: avoid warnings about discarding "const"
18309         * lib/strerror.c (rpl_strerror): Instead of returning a const
18310         string from each and every "case", use a variable, and add a single
18311         cast after the switch.
18312
18313 2009-01-16  Albert Chin-A-Young <china@thewrittenword.com>
18314
18315         * lib/arpa_inet.in.h: Add extern "C" block for C++.
18316
18317 2009-01-16  Bruno Haible  <bruno@clisp.org>
18318
18319         * m4/printf.m4 (gl_SNPRINTF_SIZE1, gl_VSNPRINTF_ZEROSIZE_C99): Use an
18320         array initializer syntax that also works in C++ mode.
18321         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
18322
18323 2009-01-16  Jim Meyering  <meyering@redhat.com>
18324
18325         poll: suppress a warning
18326         * lib/poll.c: Use #pragma GCC diagnostic ignored "-Wtype-limits"
18327         to ignore "...unsigned expression < 0 is always false" warnings.
18328
18329 2009-01-16  Daniel P. Berrange  <berrange@redhat.com>
18330
18331         poll: remove declarations of unused variables
18332         * lib/poll.c (poll) [WIN32_NATIVE]: Remove declarations of unused
18333         sockbuf and optlen.
18334
18335 2009-01-15  Bruno Haible  <bruno@clisp.org>
18336
18337         Make fflush-after-ungetc POSIX compliant on BSD systems.
18338         * lib/fflush.c (clear_ungetc_buffer_preserving_position): New function.
18339         (clear_ungetc_buffer): Implement also for other systems.
18340         (rpl_fflush): On glibc systems, invoke
18341         clear_ungetc_buffer_preserving_position. Otherwise, invoke
18342         clear_ungetc_buffer after fetching the stream's position, not before.
18343
18344 2009-01-15  Bruno Haible  <bruno@clisp.org>
18345
18346         Make fflush-after-ungetc POSIX compliant on glibc systems.
18347         * m4/fflush.m4 (gl_FUNC_FFLUSH): Test also the behaviour of fflush
18348         after ungetc.
18349         * lib/fflush.c (clear_ungetc_buffer): Implement for glibc systems.
18350         (rpl_fflush): On glibc systems, simply call the system's fflush
18351         function after clearing the ungetc buffer.
18352         * lib/fseeko.c (rpl_fseeko): Don't try to lseek past the end of file.
18353         Instead, lseek only to the end of file, then use the system's fseeko
18354         for the rest. On glibc systems, reset the EOF indicator bit.
18355
18356 2009-01-15  Jim Meyering  <meyering@redhat.com>
18357
18358         openmp.m4: revert quote-adding change, for portability to older autoconf
18359         * m4/openmp.m4: Remove the quotes added on 2009-01-14.
18360         This reverts part of 42d1eda5dcce2d68deab7a642e7f29bcd7144a0d.
18361         Simon Josefsson noticed the problem when using autoconf-2.61.
18362
18363 2009-01-15  Bruno Haible  <bruno@clisp.org>
18364
18365         * tests/test-fflush2.sh: Invoke test-fflush2 twice.
18366         * tests/test-fflush2.c (ASSERT): Always fail.
18367         (main): Add two tests for fflush() after ungetc(), taking into account
18368         the Austin Group's clarification.
18369         Suggested by Eric Blake.
18370
18371 2009-01-15  Albert Chin-A-Young  <china@thewrittenword.com>
18372
18373         mktime.m4: remove K&R-style function prototypes
18374         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove K&R-style function prototypes
18375         for the Sun C++ compiler.
18376
18377 2009-01-14  Bruno Haible  <bruno@clisp.org>
18378
18379         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_WCHAR_H): New macro, defined
18380         while including <wchar.h>.
18381         * lib/wchar.in.h: In two particular situations on HP-UX, include only
18382         the system's <wchar.h> file.
18383         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
18384
18385 2009-01-14  Bruno Haible  <bruno@clisp.org>
18386
18387         * m4/csharp.m4: Don't mention gettext on the serial number line.
18388         * m4/csharpexec.m4: Likewise.
18389         * m4/eaccess.m4: Likewise.
18390         * m4/javaexec.m4: Likewise.
18391         * m4/sig_atomic_t.m4: Likewise.
18392         * m4/tmpdir.m4: Likewise.
18393         * m4/intldir.m4: Bump gettext version.
18394         * m4/lib-ld.m4: Likewise.
18395
18396 2009-01-14  Bruno Haible  <bruno@clisp.org>
18397
18398         * lib/progname.c (set_program_name): Add more comments.
18399         Reported by Sergey Poznyakoff <gray@gnu.org.ua>.
18400
18401 2009-01-14  Simon Josefsson  <simon@josefsson.org>
18402
18403         * lib/sys_stat.in.h: Include sys/types.h for nlink_t on systems
18404         were sys/stat.h does not define it.
18405
18406 2009-01-14  Jim Meyering  <meyering@redhat.com>
18407
18408         many *.m4 files: improve m4 quoting
18409         99% of this change was performed by running the following commands:
18410         git ls-files | grep '\.m4$' | xargs perl -pi \
18411           -e 's/(AC_\w+\()([^[()]+?)([,)])/$1\[$2]$3/g;' \
18412           -e 's/(AC_\w+\((?:\[[^,]+?\], ){1})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
18413           -e 's/(AC_\w+\((?:\[[^,]+?\], ){2})([^,[()]+?)([,)])/$1\[$2]$3/g;' \
18414           -e 's/(AC_\w+\((?:\[[^,]+?\], ){3})([^,[()]+?)([,)])/$1\[$2]$3/g'
18415         perl -pi -e 's/\[\.\.\.\]/.../' m4/onceonly.m4
18416         The remainder were to add Copyright dates, increment serial numbers,
18417         undo some changes in comments, exclude m4/intl.m4, and add quotes
18418         around the "1" in ",1" where the unusual spacing prohibited the
18419         above regexps from doing the job.  For more details, see
18420         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16175>.
18421         * m4/acl.m4: Modified.
18422         * m4/afs.m4: Likewise.
18423         * m4/alloca.m4: Likewise.
18424         * m4/argp.m4: Likewise.
18425         * m4/argz.m4: Likewise.
18426         * m4/atexit.m4: Likewise.
18427         * m4/bison-i18n.m4: Likewise.
18428         * m4/bison.m4: Likewise.
18429         * m4/byteswap.m4: Likewise.
18430         * m4/c-stack.m4: Likewise.
18431         * m4/c-strtod.m4: Likewise.
18432         * m4/calloc.m4: Likewise.
18433         * m4/canonicalize-lgpl.m4: Likewise.
18434         * m4/chown.m4: Likewise.
18435         * m4/clock_time.m4: Likewise.
18436         * m4/codeset.m4: Likewise.
18437         * m4/copy-file.m4: Likewise.
18438         * m4/csharp.m4: Likewise.
18439         * m4/csharpcomp.m4: Likewise.
18440         * m4/csharpexec.m4: Likewise.
18441         * m4/d-ino.m4: Likewise.
18442         * m4/d-type.m4: Likewise.
18443         * m4/dirfd.m4: Likewise.
18444         * m4/double-slash-root.m4: Likewise.
18445         * m4/eaccess.m4: Likewise.
18446         * m4/eealloc.m4: Likewise.
18447         * m4/environ.m4: Likewise.
18448         * m4/errno_h.m4: Likewise.
18449         * m4/euidaccess.m4: Likewise.
18450         * m4/execute.m4: Likewise.
18451         * m4/fatal-signal.m4: Likewise.
18452         * m4/fchdir.m4: Likewise.
18453         * m4/fcntl_h.m4: Likewise.
18454         * m4/fileblocks.m4: Likewise.
18455         * m4/filenamecat.m4: Likewise.
18456         * m4/findprog.m4: Likewise.
18457         * m4/flexmember.m4: Likewise.
18458         * m4/fnmatch.m4: Likewise.
18459         * m4/fopen.m4: Likewise.
18460         * m4/fpending.m4: Likewise.
18461         * m4/fprintf-posix.m4: Likewise.
18462         * m4/free.m4: Likewise.
18463         * m4/frexp.m4: Likewise.
18464         * m4/frexpl.m4: Likewise.
18465         * m4/fsusage.m4: Likewise.
18466         * m4/ftruncate.m4: Likewise.
18467         * m4/gc-camellia.m4: Likewise.
18468         * m4/gc-random.m4: Likewise.
18469         * m4/gc.m4: Likewise.
18470         * m4/getaddrinfo.m4: Likewise.
18471         * m4/getcwd-abort-bug.m4: Likewise.
18472         * m4/getcwd-path-max.m4: Likewise.
18473         * m4/getdate.m4: Likewise.
18474         * m4/getdomainname.m4: Likewise.
18475         * m4/getgroups.m4: Likewise.
18476         * m4/gethostname.m4: Likewise.
18477         * m4/gethrxtime.m4: Likewise.
18478         * m4/getline.m4: Likewise.
18479         * m4/getloadavg.m4: Likewise.
18480         * m4/getndelim2.m4: Likewise.
18481         * m4/getpass.m4: Likewise.
18482         * m4/gettext.m4: Likewise.
18483         * m4/gettime.m4: Likewise.
18484         * m4/gettimeofday.m4: Likewise.
18485         * m4/gnulib-common.m4: Likewise.
18486         * m4/group-member.m4: Likewise.
18487         * m4/host-os.m4: Likewise.
18488         * m4/iconv.m4: Likewise.
18489         * m4/iconv_open.m4: Likewise.
18490         * m4/inet_ntop.m4: Likewise.
18491         * m4/inet_pton.m4: Likewise.
18492         * m4/inline.m4: Likewise.
18493         * m4/intldir.m4: Likewise.
18494         * m4/intlmacosx.m4: Likewise.
18495         * m4/intmax.m4: Likewise.
18496         * m4/intmax_t.m4: Likewise.
18497         * m4/inttypes.m4: Likewise.
18498         * m4/inttypes_h.m4: Likewise.
18499         * m4/inttypes-pri.m4: Likewise.
18500         * m4/isapipe.m4: Likewise.
18501         * m4/isnand.m4: Likewise.
18502         * m4/isnanf.m4: Likewise.
18503         * m4/isnanl.m4: Likewise.
18504         * m4/javacomp.m4: Likewise.
18505         * m4/javaexec.m4: Likewise.
18506         * m4/jm-winsz1.m4: Likewise.
18507         * m4/jm-winsz2.m4: Likewise.
18508         * m4/lchown.m4: Likewise.
18509         * m4/lcmessage.m4: Likewise.
18510         * m4/ldexpl.m4: Likewise.
18511         * m4/lib-ld.m4: Likewise.
18512         * m4/lib-link.m4: Likewise.
18513         * m4/libsigsegv.m4: Likewise.
18514         * m4/link-follow.m4: Likewise.
18515         * m4/localcharset.m4: Likewise.
18516         * m4/locale-fr.m4: Likewise.
18517         * m4/locale-ja.m4: Likewise.
18518         * m4/locale-tr.m4: Likewise.
18519         * m4/locale-zh.m4: Likewise.
18520         * m4/lock.m4: Likewise.
18521         * m4/longlong.m4: Likewise.
18522         * m4/ls-mntd-fs.m4: Likewise.
18523         * m4/lstat.m4: Likewise.
18524         * m4/malloc.m4: Likewise.
18525         * m4/mathl.m4: Likewise.
18526         * m4/mbrtowc.m4: Likewise.
18527         * m4/mbstate_t.m4: Likewise.
18528         * m4/mbswidth.m4: Likewise.
18529         * m4/memchr.m4: Likewise.
18530         * m4/memcmp.m4: Likewise.
18531         * m4/memcpy.m4: Likewise.
18532         * m4/memmem.m4: Likewise.
18533         * m4/memmove.m4: Likewise.
18534         * m4/mempcpy.m4: Likewise.
18535         * m4/memrchr.m4: Likewise.
18536         * m4/memset.m4: Likewise.
18537         * m4/minmax.m4: Likewise.
18538         * m4/mkdir-slash.m4: Likewise.
18539         * m4/mkdtemp.m4: Likewise.
18540         * m4/mktime.m4: Likewise.
18541         * m4/mmap-anon.m4: Likewise.
18542         * m4/mountlist.m4: Likewise.
18543         * m4/nanosleep.m4: Likewise.
18544         * m4/nls.m4: Likewise.
18545         * m4/nocrash.m4: Likewise.
18546         * m4/open.m4: Likewise.
18547         * m4/openat.m4: Likewise.
18548         * m4/openmp.m4: Likewise.
18549         * m4/pathmax.m4: Likewise.
18550         * m4/perl.m4: Likewise.
18551         * m4/physmem.m4: Likewise.
18552         * m4/pipe.m4: Likewise.
18553         * m4/po.m4: Likewise.
18554         * m4/poll.m4: Likewise.
18555         * m4/posixtm.m4: Likewise.
18556         * m4/posixver.m4: Likewise.
18557         * m4/printf-frexp.m4: Likewise.
18558         * m4/printf-frexpl.m4: Likewise.
18559         * m4/printf-posix.m4: Likewise.
18560         * m4/printf-posix-rpl.m4: Likewise.
18561         * m4/printf.m4: Likewise.
18562         * m4/progtest.m4: Likewise.
18563         * m4/putenv.m4: Likewise.
18564         * m4/readline.m4: Likewise.
18565         * m4/readlink.m4: Likewise.
18566         * m4/readutmp.m4: Likewise.
18567         * m4/realloc.m4: Likewise.
18568         * m4/regex.m4: Likewise.
18569         * m4/relocatable.m4: Likewise.
18570         * m4/relocatable-lib.m4: Likewise.
18571         * m4/rename-dest-slash.m4: Likewise.
18572         * m4/rename.m4: Likewise.
18573         * m4/rmdir-errno.m4: Likewise.
18574         * m4/rmdir.m4: Likewise.
18575         * m4/roundf.m4: Likewise.
18576         * m4/roundl.m4: Likewise.
18577         * m4/rpmatch.m4: Likewise.
18578         * m4/save-cwd.m4: Likewise.
18579         * m4/selinux-selinux-h.m4: Likewise.
18580         * m4/setenv.m4: Likewise.
18581         * m4/settime.m4: Likewise.
18582         * m4/sig2str.m4: Likewise.
18583         * m4/sig_atomic_t.m4: Likewise.
18584         * m4/signalblocking.m4: Likewise.
18585         * m4/signbit.m4: Likewise.
18586         * m4/sigpipe.m4: Likewise.
18587         * m4/sockets.m4: Likewise.
18588         * m4/sockpfaf.m4: Likewise.
18589         * m4/st_dm_mode.m4: Likewise.
18590         * m4/stat-time.m4: Likewise.
18591         * m4/stdbool.m4: Likewise.
18592         * m4/stdint.m4: Likewise.
18593         * m4/stdint_h.m4: Likewise.
18594         * m4/stpcpy.m4: Likewise.
18595         * m4/stpncpy.m4: Likewise.
18596         * m4/strcase.m4: Likewise.
18597         * m4/strchrnul.m4: Likewise.
18598         * m4/strcspn.m4: Likewise.
18599         * m4/strdup.m4: Likewise.
18600         * m4/strftime.m4: Likewise.
18601         * m4/strndup.m4: Likewise.
18602         * m4/strnlen.m4: Likewise.
18603         * m4/strpbrk.m4: Likewise.
18604         * m4/strptime.m4: Likewise.
18605         * m4/strsep.m4: Likewise.
18606         * m4/strtod.m4: Likewise.
18607         * m4/strtoimax.m4: Likewise.
18608         * m4/strtok_r.m4: Likewise.
18609         * m4/strtol.m4: Likewise.
18610         * m4/strtoll.m4: Likewise.
18611         * m4/strtoul.m4: Likewise.
18612         * m4/strtoull.m4: Likewise.
18613         * m4/strtoumax.m4: Likewise.
18614         * m4/strverscmp.m4: Likewise.
18615         * m4/threadlib.m4: Likewise.
18616         * m4/timegm.m4: Likewise.
18617         * m4/tm_gmtoff.m4: Likewise.
18618         * m4/tmpdir.m4: Likewise.
18619         * m4/tmpfile.m4: Likewise.
18620         * m4/tzset.m4: Likewise.
18621         * m4/uintmax_t.m4: Likewise.
18622         * m4/unlinkdir.m4: Likewise.
18623         * m4/unlocked-io.m4: Likewise.
18624         * m4/uptime.m4: Likewise.
18625         * m4/userspec.m4: Likewise.
18626         * m4/utimbuf.m4: Likewise.
18627         * m4/utime.m4: Likewise.
18628         * m4/utimes-null.m4: Likewise.
18629         * m4/utimes.m4: Likewise.
18630         * m4/vararrays.m4: Likewise.
18631         * m4/vasnprintf.m4: Likewise.
18632         * m4/vfprintf-posix.m4: Likewise.
18633         * m4/vprintf-posix.m4: Likewise.
18634         * m4/wait-process.m4: Likewise.
18635         * m4/wchar_t.m4: Likewise.
18636         * m4/wint_t.m4: Likewise.
18637         * m4/write-any-file.m4: Likewise.
18638         * m4/yield.m4: Likewise.
18639
18640 2009-01-13  Bruno Haible  <bruno@clisp.org>
18641
18642         Avoid test-copy-file.sh failures when ACL support insufficient.
18643         * modules/copy-file-tests (Makefile.am): Pass USE_ACL in
18644         TESTS_ENVIRONMENT.
18645         * tests/test-copy-file.sh: Skip the ACL comparisons if USE_ACL is 0.
18646         Reported by Jim Meyering.
18647
18648 2009-01-13  Bruno Haible  <bruno@clisp.org>
18649
18650         * modules/unistdio/u-printf-args (Files): Add m4/stdint_h.m4 and
18651         m4/inttypes_h.m4, needed by m4/intmax_t.m4.
18652         * modules/unistdio/u8-printf-parse (Files): Likewise.
18653         * modules/unistdio/u32-printf-parse (Files): Likewise.
18654         * modules/unistdio/ulc-printf-parse (Files): Likewise.
18655
18656 2009-01-13  Simon Josefsson  <simon@josefsson.org>
18657
18658         * modules/unistdio/u16-printf-parse (Files): Add m4/stdint_h.m4
18659         and m4/inttypes_h.m4 too.
18660
18661 2009-01-12  Eric Blake  <ebb9@byu.net>
18662
18663         tests: IRIX 6.2 cc can't compile -0.0 into .data
18664         * tests/test-ceill.c (minus_zero): Compute -0.0L at runtime,
18665         rather than at compile-time.
18666         * tests/test-floorl.c (minus_zero): Likewise.
18667         * tests/test-frexpl.c (minus_zero): Likewise.
18668         * tests/test-isnan.c (minus_zerol): Likewise.
18669         * tests/test-isnanl.h (minus_zero): Likewise.
18670         * tests/test-ldexpl.c (minus_zero): Likewise.
18671         * tests/test-roundl.c (minus_zero): Likewise.
18672         * tests/test-signbit.c (minus_zerol): Likewise.
18673         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
18674         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
18675         * tests/test-truncl.c (minus_zero): Likewise.
18676         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
18677         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
18678         Reported by Tom G. Christensen and Nelson H. F. Beebe.
18679
18680 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
18681
18682         regex: fix glibc bug 9697
18683         * lib/regcomp.c (re_compile_fastmap_iter): Rewrite COMPLEX_BRACKET
18684         handling.
18685
18686 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
18687
18688         regex: fix glibc bug 697
18689         * lib/regexec.c (prune_impossible_nodes): Handle sifted_states[0]
18690         being NULL also if there are no backreferences.
18691
18692 2009-01-09  Paolo Bonzini  <bonzini@gnu.org>
18693
18694         regex: merge glibc changes
18695         * lib/regcomp.c (re_compile_fastmap_iter): Use __mbrtowc.
18696         * lib/regex_internal.c (build_wcs_buffer, build_wcs_upper_buffer,
18697         re_string_skip_chars, re_string_reconstruct): Likewise.
18698         * lib/regex_internal.h [!_LIBC] (__mbrtowc): New #define.
18699
18700 2009-01-07  Jim Meyering  <meyering@redhat.com>
18701
18702         poll: filter through cppi
18703         * lib/poll.c: Indent cpp directives to reflect nesting.
18704
18705 2009-01-07  Daniel P. Berrange  <berrange@redhat.com>
18706
18707         poll: don't return uninitialized
18708         * lib/poll.c (poll) [WIN32_NATIVE]: Initialize "rc".
18709
18710 2009-01-06  Jeremy Olexa <darkside@gentoo.org>  (tiny change)
18711
18712         avoid compile failure on AIX 6.1
18713         * lib/getloadavg.c [HAVE_LIBPERFSTAT]: Include <sys/protosw.h>.
18714         Details in http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/15465
18715
18716 2009-01-04  Jim Meyering  <meyering@redhat.com>
18717
18718         remove duplicate inclusion of <stdio.h>
18719         * tests/test-fprintf-posix.c: Likewise.
18720         * tests/test-printf-posix.c: Likewise.
18721         * tests/test-snprintf-posix.c: Likewise.
18722         * tests/test-sprintf-posix.c: Likewise.
18723         * tests/test-vasprintf-posix.c: Likewise.
18724         * tests/test-vfprintf-posix.c: Likewise.
18725         * tests/test-vprintf-posix.c: Likewise.
18726         * tests/test-vsnprintf-posix.c: Likewise.
18727         * tests/test-vsprintf-posix.c: Likewise.
18728
18729 2009-01-03  Jim Meyering  <meyering@redhat.com>
18730
18731         gnulib-tool: fix sed-based filtering
18732         * gnulib-tool (func_filter_filelist): Remove extra backslash
18733         in sed_fff_filter definition.
18734
18735 2009-01-02  Jim Meyering  <meyering@redhat.com>
18736
18737         strftime: avoid compilation failure on Solaris 2.6
18738         * modules/strftime (Depends-on): Add mbrlen and mbsinit.
18739         * lib/strftime.c [DO_MULTIBYTE]: Include <wchar.h> unconditionally.
18740         Don't #define mbrlen or mbsinit, since now they're guaranteed to
18741         be available.  Reported by Tom G. Christensen.  Details in
18742         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/16180>.
18743
18744 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18745             Bruno Haible  <bruno@clisp.org>
18746
18747         Speed up gnulib-tool by doing more string processing through shell
18748         built-ins.
18749         * gnulib-tool (fast_func_append): New variable.
18750         (func_remove_prefix, func_remove_suffix): New functions.
18751         (fast_func_remove_prefix, fast_func_remove_suffix): New variables.
18752         (func_filter_filelist): New function.
18753         (func_get_dependencies): Use func_remove_suffix instead of sed.
18754         (func_get_automake_snippet): Use func_filter_filelist instead of a
18755         subshell and sed invocation.
18756
18757 2009-01-01  Bruno Haible  <bruno@clisp.org>
18758
18759         Fix a security bug.
18760         * gnulib-tool (func_import, import, update): Don't allow the characters
18761         '"', '$', '`', '\' in macro arguments that become part of commands that
18762         are evaluated.
18763
18764 2009-01-01  Bruno Haible  <bruno@clisp.org>
18765
18766         * gnulib-tool (func_reset_sigpipe): Add more comments.
18767
18768 2009-01-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18769
18770         * gnulib-tool (func_modules_add_dummy, func_emit_lib_Makefile_am,
18771         func_emit_tests_Makefile_am, func_import): Abort loops early if we
18772         already know the answer.
18773
18774 2009-01-01  Jim Meyering  <meyering@redhat.com>
18775
18776         * lib/version-etc.c (version_etc_va): Update copyright year.
18777
18778 2008-12-30  Bruno Haible  <bruno@clisp.org>
18779
18780         * m4/lib-prefix.m4 (AC_LIB_LINKFLAGS_BODY): Don't overwrite
18781         LIB${NAME}_PREFIX when considering the dependencies of lib${name}.
18782         Reported by Charles Wilson <cygwin@cwilson.fastmail.fm>.
18783
18784 2008-12-29  Eric Blake  <ebb9@byu.net>
18785
18786         multiarch: avoid autoconf AC_REQUIRE bug
18787         * m4/multiarch.m4 (gl_MULTIARCH): Split body...
18788         (gl_MULTIARCH_BODY): ...into new macro, to work around bug in Autoconf
18789         2.63 and older.
18790         Reported by Bruno Haible, and analyzed in
18791         http://lists.gnu.org/archive/html/bug-autoconf/2008-12/msg00039.html
18792
18793 2008-12-29  Bruno Haible  <bruno@clisp.org>
18794
18795         * gnulib-tool (func_import): When generating sed-ignore-removed, handle
18796         files in subdirectories correctly.
18797         Reported by Ralf Wildenhues.
18798
18799 2008-12-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
18800
18801         * gnulib-tool (func_update_ignorelist): Use 'join - FILE'
18802         rather than 'join FILE -', for Solaris join.
18803
18804 2008-12-29  Bruno Haible  <bruno@clisp.org>
18805
18806         * m4/codeset.m4 (AM_LANGINFO_CODESET): More systematic m4 argument
18807         quoting.
18808         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
18809         * m4/glibc2.m4 (gt_GLIBC2): Likewise.
18810         * m4/glibc21.m4 (gl_GLIBC21): Likewise.
18811         * m4/iconv.m4 (AM_ICONV_LINK, AM_ICONV): Likewise.
18812         * m4/intdiv0.m4 (gt_INTDIV0): Likewise.
18813         * m4/intlmacosx.m4 (gt_INTL_MACOSX): Likewise.
18814         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Likewise.
18815         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Likewise.
18816         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
18817         * m4/lcmessage.m4 (gt_LC_MESSAGES): Likewise.
18818         * m4/nls.m4 (AM_NLS): Likewise.
18819         * m4/po.m4 (AM_PO_SUBDIRS): Likewise.
18820         * m4/printf-posix.m4 (gt_PRINTF_POSIX): Likewise.
18821         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
18822         * m4/size_max.m4 (gl_SIZE_MAX): Likewise.
18823         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Likewise.
18824         * m4/threadlib.m4 (gl_THREADLIB_BODY): Likewise.
18825         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Likewise.
18826         * m4/visibility.m4 (gl_VISIBILITY): Likewise.
18827         * m4/wchar_t.m4 (gt_TYPE_WCHAR_T): Likewise.
18828         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
18829         * m4/xsize.m4 (gl_XSIZE): Likewise.
18830         Suggested by Jim Meyering.
18831
18832 2008-11-17  Bruce Korb  <bkorb@gnu.org>
18833
18834         * lib/parse-duration.h: non-iso form accepts years, months weeks, too
18835         * lib/parse-duration.c: use a switch instead of cascading if's.
18836
18837 2008-12-29  Eric Blake  <ebb9@byu.net>
18838
18839         wchar.h: supply WEOF on Irix 5.3
18840         * lib/wchar.in.h (wint_t): Also supply WEOF.
18841         * lib/wctype.in.h (wint_t): Likewise.
18842         * doc/posix-headers/wchar.texi (wchar.h): Document the bug.
18843         * doc/posix-headers/wctype.texi (wctype.h): Likewise.
18844         Reported by Tom G. Christensen.
18845
18846 2008-12-26  Bruno Haible  <bruno@clisp.org>
18847
18848         * m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names
18849         i486, i586, i686.
18850
18851 2008-12-26  Bruno Haible  <bruno@clisp.org>
18852
18853         * lib/stdlib.in.h (struct random_data): Fix indentation of comments.
18854
18855 2008-12-26  Bruno Haible  <bruno@clisp.org>
18856
18857         * lib/stdint.in.h: Move the include of <wchar.h> down until after all
18858         the types are defined. Also conditionalize it on __STDC_LIMIT_MACROS,
18859         not __STDC_CONSTANT_MACROS.
18860         Reported by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
18861
18862 2008-12-25  Bruno Haible  <bruno@clisp.org>
18863
18864         Add support for universal builds to vasnprintf.
18865         * m4/printf.m4 (gl_PRINTF_ENOMEM): Require gl_MULTIARCH. In Apple
18866         universal builds, guess no.
18867         * modules/vasnprintf-posix (Depends-on): Add multiarch.
18868         * modules/vasprintf-posix (Depends-on): Likewise.
18869         * modules/fprintf-posix (Depends-on): Likewise.
18870         * modules/vfprintf-posix (Depends-on): Likewise.
18871         * modules/snprintf-posix (Depends-on): Likewise.
18872         * modules/vsnprintf-posix (Depends-on): Likewise.
18873         * modules/sprintf-posix (Depends-on): Likewise.
18874         * modules/vsprintf-posix (Depends-on): Likewise.
18875         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
18876         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
18877         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
18878         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
18879         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
18880         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
18881         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
18882
18883         Add support for universal builds to <inttypes.h>.
18884         * lib/inttypes.in.h (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX,
18885         _SCNu64_PREFIX): In Apple
18886         universal builds, define directly, using _LP64.
18887         * m4/inttypes.m4 (gl_INTTYPES_H): In Apple universal builds, set
18888         INT64_MAX_EQ_LONG_MAX and UINT64_MAX_EQ_ULONG_MAX to -1.
18889         * modules/inttypes (Depends-on): Add multiarch.
18890         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
18891
18892         Add support for universal builds to <stdint.h>.
18893         * lib/stdint.in.h (PDFDIFF_MIN, PTRDIFF_MAX, SIZE_MAX): In Apple
18894         universal builds, define directly, using _LP64.
18895         * m4/stdint.m4 (gl_STDINT_TYPE_PROPERTIES): Require gl_MULTIARCH. In
18896         Apple universal builds, don't test for the size and suffix of ptrdiff_t
18897         and size_t.
18898         * modules/stdint (Depends-on): Add multiarch.
18899         (Makefile.am): Substitute APPLE_UNIVERSAL_BUILD.
18900
18901         New module 'multiarch'.
18902         * modules/multiarch: New file.
18903         * m4/multiarch.m4: New file.
18904
18905 2008-12-25  Bruno Haible  <bruno@clisp.org>
18906
18907         * gnulib-tool (func_create_testdir): Avoid failure of mv command.
18908
18909 2008-12-25  Bruno Haible  <bruno@clisp.org>
18910
18911         * modules/btowc (License): Relicense under LGPLv2+.
18912         * modules/mbsinit (License): Likewise.
18913         * modules/mbrtowc (License): Likewise.
18914         * modules/wcrtomb (License): Likewise.
18915         * modules/streq (License): Likewise.
18916         Reported by David Lutterkort <lutter@redhat.com>.
18917
18918 2008-12-23  Bruno Haible  <bruno@clisp.org>
18919
18920         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Fix conditional and comment.
18921
18922 2008-12-23  Bruno Haible  <bruno@clisp.org>
18923
18924         Module getaddrinfo requires linking with $(GETADDRINFO_LIB).
18925         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Put link options into
18926         GETADDRINFO_LIB, not in LIBS.
18927         * modules/getaddrinfo (Link): Set to $(GETADDRINFO_LIB).
18928         * modules/canon-host (Link): Likewise.
18929         * NEWS: Mention the change.
18930         * modules/getaddrinfo-tests (test_getaddrinfo_LDADD): Add the
18931         GETADDRINFO_LIB.
18932
18933 2008-12-22  Bruno Haible  <bruno@clisp.org>
18934
18935         * doc/posix-functions/iswalnum_l.texi: Mention limitation of wchar_t.
18936         * doc/posix-functions/iswalpha_l.texi: Likewise.
18937         * doc/posix-functions/iswblank_l.texi: Likewise.
18938         * doc/posix-functions/iswcntrl_l.texi: Likewise.
18939         * doc/posix-functions/iswctype_l.texi: Likewise.
18940         * doc/posix-functions/iswdigit_l.texi: Likewise.
18941         * doc/posix-functions/iswgraph_l.texi: Likewise.
18942         * doc/posix-functions/iswlower_l.texi: Likewise.
18943         * doc/posix-functions/iswprint_l.texi: Likewise.
18944         * doc/posix-functions/iswpunct_l.texi: Likewise.
18945         * doc/posix-functions/iswspace_l.texi: Likewise.
18946         * doc/posix-functions/iswupper_l.texi: Likewise.
18947         * doc/posix-functions/iswxdigit_l.texi: Likewise.
18948         * doc/posix-functions/mbsnrtowcs.texi: Likewise.
18949         * doc/posix-functions/open_wmemstream.texi: Likewise.
18950         * doc/posix-functions/swscanf.texi: Likewise.
18951         * doc/posix-functions/towctrans_l.texi: Likewise.
18952         * doc/posix-functions/towlower.texi: Likewise.
18953         * doc/posix-functions/towlower_l.texi: Likewise.
18954         * doc/posix-functions/towupper.texi: Likewise.
18955         * doc/posix-functions/towupper_l.texi: Likewise.
18956         * doc/posix-functions/vfwprintf.texi: Likewise.
18957         * doc/posix-functions/vfwscanf.texi: Likewise.
18958         * doc/posix-functions/vswscanf.texi: Likewise.
18959         * doc/posix-functions/vwprintf.texi: Likewise.
18960         * doc/posix-functions/vwscanf.texi: Likewise.
18961         * doc/posix-functions/wcpcpy.texi: Likewise.
18962         * doc/posix-functions/wcpncpy.texi: Likewise.
18963         * doc/posix-functions/wcscasecmp.texi: Likewise.
18964         * doc/posix-functions/wcscasecmp_l.texi: Likewise.
18965         * doc/posix-functions/wcscoll_l.texi: Likewise.
18966         * doc/posix-functions/wcsdup.texi: Likewise.
18967         * doc/posix-functions/wcsncasecmp.texi: Likewise.
18968         * doc/posix-functions/wcsncasecmp_l.texi: Likewise.
18969         * doc/posix-functions/wcsnlen.texi: Likewise.
18970         * doc/posix-functions/wcsnrtombs.texi: Likewise.
18971         * doc/posix-functions/wcsxfrm_l.texi: Likewise.
18972         * doc/posix-functions/wctrans_l.texi: Likewise.
18973         * doc/posix-functions/wctype_l.texi: Likewise.
18974         * doc/glibc-functions/fgetwc_unlocked.texi: Likewise.
18975         * doc/glibc-functions/fgetws_unlocked.texi: Likewise.
18976         * doc/glibc-functions/fputwc_unlocked.texi: Likewise.
18977         * doc/glibc-functions/fputws_unlocked.texi: Likewise.
18978         * doc/glibc-functions/getwc_unlocked.texi: Likewise.
18979         * doc/glibc-functions/getwchar_unlocked.texi: Likewise.
18980         * doc/glibc-functions/putwc_unlocked.texi: Likewise.
18981         * doc/glibc-functions/putwchar_unlocked.texi: Likewise.
18982         * doc/glibc-functions/wcschrnul.texi: Likewise.
18983         * doc/glibc-functions/wcsftime_l.texi: Likewise.
18984         * doc/glibc-functions/wcstod_l.texi: Likewise.
18985         * doc/glibc-functions/wcstof_l.texi: Likewise.
18986         * doc/glibc-functions/wcstol_l.texi: Likewise.
18987         * doc/glibc-functions/wcstold_l.texi: Likewise.
18988         * doc/glibc-functions/wcstoll_l.texi: Likewise.
18989         * doc/glibc-functions/wcstoq.texi: Likewise.
18990         * doc/glibc-functions/wcstoul_l.texi: Likewise.
18991         * doc/glibc-functions/wcstoull_l.texi: Likewise.
18992         * doc/glibc-functions/wcstouq.texi: Likewise.
18993         * doc/glibc-functions/wmempcpy.texi: Likewise.
18994
18995 2008-12-22  Ingo Weinhold  <ingo_weinhold@gmx.de>  (tiny change)
18996             Eric Blake  <ebb9@byu.net>
18997             Paolo Bonzini  <bonzini@gnu.org>
18998             Bruno Haible  <bruno@clisp.org>
18999
19000         Make c-stack work on Haiku.
19001         * lib/c-stack.c (SA_ONSTACK): Define fallback.
19002         (c_stack_action): Use SA_ONSTACK flag.
19003
19004 2008-12-22  Bruno Haible  <bruno@clisp.org>
19005
19006         * m4/locale-fr.m4 (gt_LOCALE_FR_UTF8): Treat Haiku like BeOS.
19007
19008 2008-12-22  Bruno Haible  <bruno@clisp.org>
19009
19010         Work around mbrlen() bugs on AIX, HP-UX, OSF/1, Solaris.
19011         * m4/mbrlen.m4 (gl_FUNC_MBRLEN): Set REPLACE_MBRLEN if mbrtowc is
19012         being overridden.
19013         (gl_MBRLEN_INCOMPLETE_STATE, gl_MBRLEN_RETVAL, gl_MBRLEN_NUL_RETVAL):
19014         New macros.
19015         * lib/wchar.in.h (mbrlen): Override if REPLACE_MBRLEN is set.
19016         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBRLEN.
19017         * modules/wchar (Makefile.am): Substitute REPLACE_MBRLEN.
19018         * doc/posix-functions/mbrlen.texi: Mention the various platform bugs.
19019
19020 2008-12-22  Bruno Haible  <bruno@clisp.org>
19021
19022         * m4/mbrtowc.m4 (gl_MBRTOWC_INCOMPLETE_STATE): Remove unused variable
19023         from test code.
19024
19025 2008-12-22  Eric Blake  <ebb9@byu.net>
19026
19027         Avoid gcc warnings on cygwin.
19028         * lib/regex_internal.c (re_string_reconstruct) [!RE_ENABLE_I18N]:
19029         Avoid unused variable.
19030         * lib/regexec.c (check_arrival_add_next_nodes) [!RE_ENABLE_I18N]:
19031         Likewise.
19032
19033 2008-12-22  Bruno Haible  <bruno@clisp.org>
19034
19035         Remove HAVE_MBRTOWC conditionals.
19036         * lib/mbscasecmp.c: Include mbuiter.h unconditionally.
19037         (mbscasecmp): Assume mbrtowc function.
19038         * lib/mbscasestr.c: Include mbuiter.h unconditionally.
19039         (knuth_morris_pratt_multibyte, mbscasestr): Assume mbrtowc function.
19040         * lib/mbschr.c: Include mbuiter.h unconditionally.
19041         (mbschr): Assume mbrtowc function.
19042         * lib/mbscspn.c: Include mbuiter.h unconditionally.
19043         (mbscspn): Assume mbrtowc function.
19044         * lib/mbslen.c: Include mbuiter.h unconditionally.
19045         (mbslen): Assume mbrtowc function.
19046         * lib/mbsncasecmp.c: Include mbuiter.h unconditionally.
19047         (mbsncasecmp): Assume mbrtowc function.
19048         * lib/mbsnlen.c: Include mbiter.h unconditionally.
19049         (mbsnlen): Assume mbrtowc function.
19050         * lib/mbspbrk.c: Include mbuiter.h unconditionally.
19051         (mbspbrk): Assume mbrtowc function.
19052         * lib/mbspcasecmp.c: Include mbuiter.h unconditionally.
19053         (mbspcasecmp): Assume mbrtowc function.
19054         * lib/mbsrchr.c: Include mbuiter.h unconditionally.
19055         (mbsrchr): Assume mbrtowc function.
19056         * lib/mbssep.c: Include mbuiter.h unconditionally.
19057         (mbssep): Assume mbrtowc function.
19058         * lib/mbsspn.c: Include mbuiter.h unconditionally.
19059         (mbsspn): Assume mbrtowc function.
19060         * lib/mbsstr.c: Include mbuiter.h unconditionally.
19061         (knuth_morris_pratt_multibyte, mbsstr): Assume mbrtowc function.
19062         * lib/mbstok_r.c: Include mbuiter.h unconditionally.
19063         (mbstok_r): Assume mbrtowc function.
19064         * lib/propername.c: Include mbuiter.h unconditionally.
19065         (mbsstr_trimmed_wordbounded): Assume mbrtowc function.
19066         * lib/trim.c: Include mbchar.h, mbiter.h uncondtionally.
19067         (trim2): Assume mbrtowc function.
19068         * lib/mbswidth.c (mbsinit): Remove fallback definition.
19069         (mbsnwidth): Assume mbrtowc function.
19070         * modules/mbswidth (Depends-on): Add mbrtowc, mbsinit.
19071         * lib/quotearg.c (MB_CUR_MAX, mbstate_t, mbrtowc, iswprint): Remove
19072         fallback definitions.
19073         * modules/quotearg (Depends-on): Add mbrtowc, mbsinit.
19074
19075 2008-12-22  Bruno Haible  <bruno@clisp.org>
19076
19077         * doc/posix-functions/mbtowc.texi: Mention a glibc bug.
19078
19079 2008-12-22  Paolo Bonzini  <bonzini@gnu.org>
19080
19081         * modules/regex: Request emulations for the mb*/wc* functions we need.
19082         * m4/regex.m4: Don't look for those functions here.
19083         * lib/regex_internal.h: Do not check HAVE_WCRTOMB and HAVE_MBRTOWC.
19084
19085 2008-12-22  Bruno Haible  <bruno@clisp.org>
19086
19087         * modules/fnmatch (Depends-on): Remove duplicated dependency.
19088
19089 2008-12-21  Bruno Haible  <bruno@clisp.org>
19090
19091         Make mbiter.h, mbuiter.h, mbfile.h usable unconditionally.
19092         * modules/mbiter (Depends-on): Add mbrtowc, mbsinit.
19093         (Include): Remove conditionalization.
19094         * modules/mbuiter (Depends-on): Add mbrtowc, mbsinit.
19095         (Include): Remove conditionalization.
19096         * modules/mbfile (Depends-on): Add mbrtowc, mbsinit.
19097         (Include): Remove conditionalization.
19098         * m4/mbiter.m4 (gl_MBITER): Deprecate the use of AC_FUNC_MBRTOWC.
19099         * m4/mbfile.m4 (gl_MBFILE): Likewise.
19100         * NEWS: Mention the change.
19101         Reported by Alan Hourihane <alanh@fairlite.co.uk>
19102         via Sergey Poznyakoff <gray@gnu.org.ua>.
19103
19104 2008-12-21  Bruno Haible  <bruno@clisp.org>
19105
19106         * MODULES.html.sh (Extended multibyte and wide character utilities
19107         <wchar.h>): Add btowc, wctob, mbsinit, mbrlen, mbrtowc, mbsrtowcs,
19108         wcrtomb, wcsrtombs.
19109         (Support for systems lacking POSIX:2008): Add accept, bind, close,
19110         connect, fclose, getpeername, getsockname, getsockopt, hostent, listen,
19111         mbsnrtowcs, posix_spawn*, recv, recvfrom, sched, select, send, sendto,
19112         setsockopt, shutdown, socket, spawn, sys_wait, wcsnrtombs, write.
19113
19114 2008-12-21  Bruno Haible  <bruno@clisp.org>
19115
19116         * MODULES.html.sh: Change section titles to refer to POSIX:2008.
19117
19118 2008-12-21  Bruno Haible  <bruno@clisp.org>
19119
19120         * modules/wcsnrtombs-tests: New file.
19121         * tests/test-wcsnrtombs1.sh: New file.
19122         * tests/test-wcsnrtombs2.sh: New file.
19123         * tests/test-wcsnrtombs3.sh: New file.
19124         * tests/test-wcsnrtombs4.sh: New file.
19125         * tests/test-wcsnrtombs.c: New file.
19126
19127         New module 'wcsnrtombs'.
19128         * lib/wchar.in.h (wcsnrtombs): New declaration.
19129         * lib/wcsnrtombs.c: New file.
19130         * lib/wcsrtombs-state.c: New file.
19131         * lib/wcsrtombs.c: Refer to _gl_wcsrtombs_state.
19132         (internal_state): Remove variable.
19133         * m4/wcsnrtombs.m4: New file.
19134         * m4/wcsrtombs.m4 (gl_FUNC_WCSRTOMBS): Add wcsrtombs-state.c to the
19135         compilation units.
19136         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSNRTOMBS,
19137         HAVE_WCSNRTOMBS.
19138         * modules/wchar (Makefile.am): Substitute GNULIB_WCSNRTOMBS,
19139         HAVE_WCSNRTOMBS.
19140         * modules/wcsnrtombs: New file.
19141         * modules/wcsrtombs (Files): Add lib/wcsrtombs-state.c.
19142         * doc/posix-functions/wcsnrtombs.texi: Mention the new module.
19143
19144 2008-12-21  Bruno Haible  <bruno@clisp.org>
19145
19146         * modules/wcsrtombs-tests: New file.
19147         * tests/test-wcsrtombs1.sh: New file.
19148         * tests/test-wcsrtombs2.sh: New file.
19149         * tests/test-wcsrtombs3.sh: New file.
19150         * tests/test-wcsrtombs4.sh: New file.
19151         * tests/test-wcsrtombs.c: New file.
19152
19153         New module 'wcsrtombs'.
19154         * lib/wchar.in.h (wcsrtombs): New declaration.
19155         * lib/wcsrtombs.c: New file.
19156         * m4/wcsrtombs.m4: New file.
19157         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCSRTOMBS,
19158         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
19159         * modules/wchar (Makefile.am): Substitute GNULIB_WCSRTOMBS,
19160         HAVE_WCSRTOMBS, REPLACE_WCSRTOMBS.
19161         * modules/wcsrtombs: New file.
19162         * doc/posix-functions/wcsrtombs.texi: Mention the new module and the
19163         bugs.
19164
19165 2008-12-21  Bruno Haible  <bruno@clisp.org>
19166
19167         Work around a wcrtomb() bug on Solaris 10 and OSF/1 5.1.
19168         * lib/wchar.in.h (wcrtomb): Override if REPLACE_WCRTOMB is set.
19169         * m4/wcrtomb.m4 (gl_FUNC_WCRTOMB): Test the return value of wcrtomb
19170         with NULL destination argument in various locales. Set REPLACE_WCRTOMB
19171         if not correct.
19172         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCRTOMB.
19173         * modules/wchar (Makefile.am): Substitute REPLACE_WCRTOMB.
19174         * modules/wcrtomb (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
19175         m4/locale-zh.m4, m4/codeset.m4.
19176         * doc/posix-functions/wcrtomb.texi: Document the bug.
19177
19178 2008-12-21  Bruno Haible  <bruno@clisp.org>
19179
19180         Work around a btowc() bug on IRIX 6.5.
19181         * lib/wchar.in.h (btowc): Override if REPLACE_BTOWC is set.
19182         * m4/btowc.m4 (gl_FUNC_BTOWC): Test whether btowc(EOF) is correct. Set
19183         REPLACE_WTOBC if not.
19184         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_BTOWC.
19185         * modules/wchar (Makefile.am): Substitute REPLACE_BTOWC.
19186         * doc/posix-functions/btowc.texi: Mention the IRIX bug.
19187
19188 2008-12-21  Bruno Haible  <bruno@clisp.org>
19189
19190         * modules/wcrtomb-tests: New file.
19191         * tests/test-wcrtomb.sh: New file.
19192         * tests/test-wcrtomb.c: New file.
19193
19194         New module 'wcrtomb'.
19195         * lib/wchar.in.h (wcrtomb): New declaration.
19196         * lib/wcrtomb.c: New file.
19197         * m4/wcrtomb.m4: New file.
19198         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCRTOMB,
19199         HAVE_WCRTOMB.
19200         * modules/wchar (Makefile.am): Substitute GNULIB_WCRTOMB,
19201         HAVE_WCRTOMB.
19202         * modules/wcrtomb: New file.
19203         * doc/posix-functions/wcrtomb.texi: Mention the new module.
19204
19205 2008-12-21  Bruno Haible  <bruno@clisp.org>
19206
19207         * modules/mbrtowc (Files): Add m4/codeset.m4, needed by m4/locale-fr.m4.
19208         * modules/mbsrtowcs (Files): Likewise.
19209         * modules/wctob (Files): Likewise.
19210         * modules/c-strcase-tests (Files): Likewise.
19211         * modules/unistdio/u8-vasnprintf-tests (Files): Likewise.
19212         * modules/unistdio/u16-vasnprintf-tests (Files): Likewise.
19213         * modules/unistdio/u32-vasnprintf-tests (Files): Likewise.
19214         * modules/unistdio/ulc-vasnprintf-tests (Files): Likewise.
19215         * modules/vasnprintf-posix-tests (Files): Likewise.
19216
19217 2008-12-21  William Pursell  <bill.pursell@gmail.com>
19218
19219         gitlog-to-changelog: pass all command-line arguments to git-log
19220         * build-aux/gitlog-to-changelog: When producing a ChangeLog,
19221         it is sometimes convenient to filter the commits in various ways.
19222         gitlog-to-changelog only allows --since to specify a start date,
19223         but git-log itself supports many other filtering mechanisms.
19224         At the moment, I want to filter by branch name.  Rather than
19225         adding a --branch option to gitlog-to-changelog, it seems more
19226         flexible to simply pass all options directly to git-log and let
19227         git do the work.  Notice that this effectively makes --since a
19228         redundant option for gitlog-to-changelog, but removing it would
19229         require current usage to change since calls would then require
19230         an additional '--'.
19231
19232 2008-12-21  Bruno Haible  <bruno@clisp.org>
19233
19234         * modules/mbsnrtowcs-tests: New file.
19235         * tests/test-mbsnrtowcs1.sh: New file.
19236         * tests/test-mbsnrtowcs2.sh: New file.
19237         * tests/test-mbsnrtowcs3.sh: New file.
19238         * tests/test-mbsnrtowcs4.sh: New file.
19239         * tests/test-mbsnrtowcs.c: New file.
19240
19241         New module 'mbsnrtowcs'.
19242         * lib/wchar.in.h (mbsnrtowcs): New declaration.
19243         * lib/mbsnrtowcs.c: New file.
19244         * lib/mbsrtowcs-state.c: New file.
19245         * lib/mbsrtowcs.c: Refer to _gl_mbsrtowcs_state.
19246         (internal_state): Remove variable.
19247         * m4/mbsnrtowcs.m4: New file.
19248         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Add mbsrtowcs-state.c to the
19249         compilation units.
19250         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSNRTOWCS,
19251         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
19252         * modules/wchar (Makefile.am): Substitute GNULIB_MBSNRTOWCS,
19253         HAVE_MBSNRTOWCS, REPLACE_MBSNRTOWCS.
19254         * modules/mbsnrtowcs: New file.
19255         * modules/mbsrtowcs (Files): Add lib/mbsrtowcs-state.c.
19256         * doc/posix-functions/mbsnrtowcs.texi: Mention the new module and a
19257         portability problem.
19258
19259 2008-12-21  Bruno Haible  <bruno@clisp.org>
19260
19261         Work around mbsrtowcs bug.
19262         * m4/mbsrtowcs.m4 (gl_MBSRTOWCS_WORKS): New macro.
19263         (gl_FUNC_MBSRTOWCS): Invoke it.
19264         * modules/mbsrtowcs (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
19265         m4/locale-zh.m4.
19266         * doc/posix-functions/mbsrtowcs.texi: Document the bug.
19267
19268 2008-12-21  Bruno Haible  <bruno@clisp.org>
19269
19270         * tests/test-mbsrtowcs.c (main): Execute the loop also for unlimited=1.
19271
19272 2008-12-21  Bruno Haible  <bruno@clisp.org>
19273
19274         Update doc for AIX.
19275         * doc/pastposix-functions/wcswcs.texi: Mention that AIX has only a
19276         16-bit wchar_t type.
19277         * doc/posix-functions/btowc.texi: Likewise.
19278         * doc/posix-functions/fgetwc.texi: Likewise.
19279         * doc/posix-functions/fgetws.texi: Likewise.
19280         * doc/posix-functions/fputwc.texi: Likewise.
19281         * doc/posix-functions/fputws.texi: Likewise.
19282         * doc/posix-functions/fwide.texi: Likewise.
19283         * doc/posix-functions/fwprintf.texi: Likewise.
19284         * doc/posix-functions/fwscanf.texi: Likewise.
19285         * doc/posix-functions/getwchar.texi: Likewise.
19286         * doc/posix-functions/getwc.texi: Likewise.
19287         * doc/posix-functions/iswalnum.texi: Likewise.
19288         * doc/posix-functions/iswalpha.texi: Likewise.
19289         * doc/posix-functions/iswblank.texi: Likewise.
19290         * doc/posix-functions/iswcntrl.texi: Likewise.
19291         * doc/posix-functions/iswctype.texi: Likewise.
19292         * doc/posix-functions/iswdigit.texi: Likewise.
19293         * doc/posix-functions/iswgraph.texi: Likewise.
19294         * doc/posix-functions/iswlower.texi: Likewise.
19295         * doc/posix-functions/iswprint.texi: Likewise.
19296         * doc/posix-functions/iswpunct.texi: Likewise.
19297         * doc/posix-functions/iswspace.texi: Likewise.
19298         * doc/posix-functions/iswupper.texi: Likewise.
19299         * doc/posix-functions/iswxdigit.texi: Likewise.
19300         * doc/posix-functions/mbrtowc.texi: Likewise.
19301         * doc/posix-functions/mbsrtowcs.texi: Likewise.
19302         * doc/posix-functions/mbstowcs.texi: Likewise.
19303         * doc/posix-functions/mbtowc.texi: Likewise.
19304         * doc/posix-functions/putwchar.texi: Likewise.
19305         * doc/posix-functions/putwc.texi: Likewise.
19306         * doc/posix-functions/swprintf.texi: Likewise.
19307         * doc/posix-functions/tolower.texi: Likewise.
19308         * doc/posix-functions/toupper.texi: Likewise.
19309         * doc/posix-functions/towctrans.texi: Likewise.
19310         * doc/posix-functions/ungetwc.texi: Likewise.
19311         * doc/posix-functions/vswprintf.texi: Likewise.
19312         * doc/posix-functions/wcrtomb.texi: Likewise.
19313         * doc/posix-functions/wcscat.texi: Likewise.
19314         * doc/posix-functions/wcschr.texi: Likewise.
19315         * doc/posix-functions/wcscmp.texi: Likewise.
19316         * doc/posix-functions/wcscoll.texi: Likewise.
19317         * doc/posix-functions/wcscpy.texi: Likewise.
19318         * doc/posix-functions/wcscspn.texi: Likewise.
19319         * doc/posix-functions/wcsftime.texi: Likewise.
19320         * doc/posix-functions/wcslen.texi: Likewise.
19321         * doc/posix-functions/wcsncat.texi: Likewise.
19322         * doc/posix-functions/wcsncmp.texi: Likewise.
19323         * doc/posix-functions/wcsncpy.texi: Likewise.
19324         * doc/posix-functions/wcspbrk.texi: Likewise.
19325         * doc/posix-functions/wcsrchr.texi: Likewise.
19326         * doc/posix-functions/wcsrtombs.texi: Likewise.
19327         * doc/posix-functions/wcsspn.texi: Likewise.
19328         * doc/posix-functions/wcsstr.texi: Likewise.
19329         * doc/posix-functions/wcstod.texi: Likewise.
19330         * doc/posix-functions/wcstof.texi: Likewise.
19331         * doc/posix-functions/wcstoimax.texi: Likewise.
19332         * doc/posix-functions/wcstok.texi: Likewise.
19333         * doc/posix-functions/wcstold.texi: Likewise.
19334         * doc/posix-functions/wcstoll.texi: Likewise.
19335         * doc/posix-functions/wcstol.texi: Likewise.
19336         * doc/posix-functions/wcstombs.texi: Likewise.
19337         * doc/posix-functions/wcstoull.texi: Likewise.
19338         * doc/posix-functions/wcstoul.texi: Likewise.
19339         * doc/posix-functions/wcstoumax.texi: Likewise.
19340         * doc/posix-functions/wcswidth.texi: Likewise.
19341         * doc/posix-functions/wcsxfrm.texi: Likewise.
19342         * doc/posix-functions/wctob.texi: Likewise.
19343         * doc/posix-functions/wctomb.texi: Likewise.
19344         * doc/posix-functions/wctrans.texi: Likewise.
19345         * doc/posix-functions/wctype.texi: Likewise.
19346         * doc/posix-functions/wcwidth.texi: Likewise.
19347         * doc/posix-functions/wmemchr.texi: Likewise.
19348         * doc/posix-functions/wmemcmp.texi: Likewise.
19349         * doc/posix-functions/wmemcpy.texi: Likewise.
19350         * doc/posix-functions/wmemmove.texi: Likewise.
19351         * doc/posix-functions/wmemset.texi: Likewise.
19352         * doc/posix-functions/wprintf.texi: Likewise.
19353         * doc/posix-functions/wscanf.texi: Likewise.
19354
19355 2008-12-21  Bruno Haible  <bruno@clisp.org>
19356
19357         Update doc for HP-UX 11.11.
19358         * doc/posix-functions/btowc.texi: Clarify that the function is missing
19359         in HP-UX version 11.00, not in all versions of HP-UX 11.
19360         * doc/posix-functions/fwide.texi: Likewise.
19361         * doc/posix-functions/fwprintf.texi: Likewise.
19362         * doc/posix-functions/fwscanf.texi: Likewise.
19363         * doc/posix-functions/inet_ntop.texi: Likewise.
19364         * doc/posix-functions/inet_pton.texi: Likewise.
19365         * doc/posix-functions/mbrlen.texi: Likewise.
19366         * doc/posix-functions/mbrtowc.texi: Likewise.
19367         * doc/posix-functions/mbsinit.texi: Likewise.
19368         * doc/posix-functions/mbsrtowcs.texi: Likewise.
19369         * doc/posix-functions/swprintf.texi: Likewise.
19370         * doc/posix-functions/swscanf.texi: Likewise.
19371         * doc/posix-functions/towctrans.texi: Likewise.
19372         * doc/posix-functions/vfwprintf.texi: Likewise.
19373         * doc/posix-functions/vswprintf.texi: Likewise.
19374         * doc/posix-functions/vwprintf.texi: Likewise.
19375         * doc/posix-functions/wcrtomb.texi: Likewise.
19376         * doc/posix-functions/wcsrtombs.texi: Likewise.
19377         * doc/posix-functions/wcsstr.texi: Likewise.
19378         * doc/posix-functions/wctob.texi: Likewise.
19379         * doc/posix-functions/wctrans.texi: Likewise.
19380         * doc/posix-functions/wmemchr.texi: Likewise.
19381         * doc/posix-functions/wmemcmp.texi: Likewise.
19382         * doc/posix-functions/wmemcpy.texi: Likewise.
19383         * doc/posix-functions/wmemmove.texi: Likewise.
19384         * doc/posix-functions/wmemset.texi: Likewise.
19385         * doc/posix-functions/wprintf.texi: Likewise.
19386         * doc/posix-functions/wscanf.texi: Likewise.
19387
19388 2008-12-21  Bruno Haible  <bruno@clisp.org>
19389
19390         Work around a portability problem.
19391         * tests/test-mbsrtowcs.c (main): Use a temporary conversion state.
19392         * doc/posix-functions/mbsrtowcs.texi: Document the portability problem.
19393
19394 2008-12-20  Bruno Haible  <bruno@clisp.org>
19395
19396         * lib/wchar.in.h (mbsrtowcs): Redefine if REPLACE_MBSRTOWCS is set.
19397         * m4/mbsrtowcs.m4 (gl_FUNC_MBSRTOWCS): Invoke gl_MBSTATE_T_BROKEN. Set
19398         REPLACE_MBSRTOWCS if mbsrtowcs needs to be overridden.
19399         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSRTOWCS.
19400         * modules/wchar (Makefile.am): Substitute REPLACE_MBSRTOWCS.
19401
19402         Work around mbrtowc bugs on AIX, HP-UX, OSF/1, Solaris.
19403         * lib/wchar.in.h (mbstate_t): Redefine also if REPLACE_MBSTATE_T is
19404         set.
19405         (GNULIB_defined_mbstate_t): New macro.
19406         (mbsinit): Redefine if REPLACE_MBSINIT is set.
19407         (mbrtowc): Redefine if REPLACE_MBRTOWC is set.
19408         * lib/mbrtowc.c (rpl_mbrtowc): Add an alternative implementation that
19409         reuses the system's mbrtowc function but works around the bugs.
19410         * m4/mbrtowc.m4 (gl_MBSTATE_T_BROKEN, gl_MBRTOWC_INCOMPLETE_STATE,
19411         gl_MBRTOWC_NULL_ARG, gl_MBRTOWC_RETVAL, gl_MBRTOWC_NUL_RETVAL): New
19412         macros.
19413         (gl_FUNC_MBRTOWC): Invoke them. Set REPLACE_MBRTOWC if mbrtowc needs to
19414         be overridden. Optionally define MBRTOWC_NULL_ARG_BUG,
19415         MBRTOWC_RETVAL_BUG, MBRTOWC_NUL_RETVAL_BUG.
19416         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_MBSTATE_T_BROKEN. Set
19417         REPLACE_MBSINIT if mbsinit needs to be overridden.
19418         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_MBSTATE_T,
19419         REPLACE_MBSINIT, REPLACE_MBRTOWC.
19420         * modules/wchar (Makefile.am): Substitute REPLACE_MBSTATE_T,
19421         REPLACE_MBSINIT, REPLACE_MBRTOWC.
19422         * modules/mbrtowc (Files): Add m4/locale-fr.m4, m4/locale-ja.m4,
19423         m4/locale-zh.m4.
19424         (Depends): Add mbsinit.
19425         * modules/mbsinit (Depends): Add mbrtowc.
19426         * doc/posix-functions/mbrtowc.texi: Mention the various bugs.
19427
19428 2008-12-20  Bruno Haible  <bruno@clisp.org>
19429
19430         * tests/test-mbrtowc.c (main): Change sample string in EUC-JP encoding
19431         so that there are no conversion errors on AIX.
19432         * tests/test-mbsrtowcs.c (main): LIkewise.
19433
19434 2008-12-20  Bruno Haible  <bruno@clisp.org>
19435
19436         Work around wctob bug on Solaris <= 9.
19437         * lib/wchar.in.h (wctob): Redefine if REPLACE_WCTOB is set.
19438         * m4/wctob.m4 (gl_FUNC_WCTOB): Test whether wctob works.
19439         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize REPLACE_WCTOB.
19440         * modules/wchar (Makefile.am): Substitute REPLACE_WCTOB.
19441         * modules/wctob (Files): Add m4/locale-fr.m4.
19442         * doc/posix-functions/wctob.texi: Mention the Solaris bug.
19443
19444 2008-12-20  Bruno Haible  <bruno@clisp.org>
19445
19446         * doc/posix-functions/select.texi: Mention Solaris 2.6 bug with
19447         /dev/null.
19448         * tests/test-select-in.sh: Likewise.
19449         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
19450
19451 2008-12-20  Bruno Haible  <bruno@clisp.org>
19452
19453         Don't pretend that Cygwin has a ja_JP.EUC-JP locale.
19454         * m4/locale-ja.m4 (gt_LOCALE_JA): Add test for MB_CUR_MAX. Needed on
19455         Cygwin 1.5.x.
19456
19457 2008-12-20  Bruno Haible  <bruno@clisp.org>
19458
19459         Ensure mbstate_t is defined on HP-UX 11.11.
19460         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Require
19461         AC_CANONICAL_HOST. On HP-UX, define _XOPEN_SOURCE to 500.
19462         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Require
19463         AC_USE_SYSTEM_EXTENSIONS.
19464         * modules/fnmatch (Depends-on): Add extensions.
19465         * modules/mbrlen (Depends-on): Likewise.
19466         * modules/mbrtowc (Depends-on): Likewise.
19467         * modules/mbsinit (Depends-on): Likewise.
19468         * modules/mbsrtowcs (Depends-on): Likewise.
19469         * modules/mbswidth (Depends-on): Likewise.
19470         * modules/quotearg (Depends-on): Likewise.
19471         * modules/strftime (Depends-on): Likewise.
19472
19473 2008-12-20  Bruno Haible  <bruno@clisp.org>
19474
19475         Ensure wctob is declared on IRIX 6.5.
19476         * lib/wchar.in.h (wctob): Declare also when HAVE_DECL_WCTOB is 0.
19477         * m4/wctob.m4 (gl_FUNC_WCTOB): Set HAVE_DECL_WCTOB instead of
19478         HAVE_WCTOB. Also test whether <wchar.h> declares wctob.
19479         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCTOB instead
19480         of HAVE_WCTOB.
19481         * modules/wchar (Makefile.am): Substitute HAVE_DECL_WCTOB instead of
19482         HAVE_WCTOB.
19483         * doc/posix-functions/wctob.texi: Mention missing declaration on IRIX.
19484
19485 2008-12-19  Bruno Haible  <bruno@clisp.org>
19486
19487         * modules/mbsrtowcs-tests: New file.
19488         * tests/test-mbsrtowcs1.sh: New file.
19489         * tests/test-mbsrtowcs2.sh: New file.
19490         * tests/test-mbsrtowcs3.sh: New file.
19491         * tests/test-mbsrtowcs4.sh: New file.
19492         * tests/test-mbsrtowcs.c: New file.
19493
19494         New module 'mbsrtowcs'.
19495         * lib/wchar.in.h (mbsrtowcs): New declaration.
19496         * lib/mbsrtowcs.c: New file.
19497         * m4/mbsrtowcs.m4: New file.
19498         * modules/mbsrtowcs: New file.
19499         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSRTOWCS and
19500         HAVE_MBSRTOWCS.
19501         * modules/wchar (Makefile.am): Substitute GNULIB_MBSRTOWCS and
19502         HAVE_MBSRTOWCS.
19503         * doc/posix-functions/mbsrtowcs.texi: Document the new module.
19504
19505 2008-12-19  Bruno Haible  <bruno@clisp.org>
19506
19507         New module 'mbrlen'.
19508         * lib/wchar.in.h (mbrlen): New declaration.
19509         * lib/mbrlen.c: New file.
19510         * m4/mbrlen.m4: New file.
19511         * modules/mbrlen: New file.
19512         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRLEN and
19513         HAVE_MBRLEN.
19514         * modules/wchar (Makefile.am): Substitute GNULIB_MBRLEN and
19515         HAVE_MBRLEN.
19516         * doc/posix-functions/mbrlen.texi: Document the new module.
19517
19518 2008-12-19  Bruno Haible  <bruno@clisp.org>
19519
19520         * lib/mbrtowc.c: Include verify.h. Verify an assumption.
19521         * modules/mbrtowc (Depends-on): Add verify.
19522         Suggested by Paul Eggert.
19523
19524 2008-12-18  Bruno Haible  <bruno@clisp.org>
19525
19526         * modules/mbsinit-tests: New file.
19527         * tests/test-mbsinit.sh: New file.
19528         * tests/test-mbsinit.c: New file.
19529
19530 2008-12-18  Bruno Haible  <bruno@clisp.org>
19531
19532         * modules/mbrtowc-tests: New file.
19533         * tests/test-mbrtowc1.sh: New file.
19534         * tests/test-mbrtowc2.sh: New file.
19535         * tests/test-mbrtowc3.sh: New file.
19536         * tests/test-mbrtowc4.sh: New file.
19537         * tests/test-mbrtowc.c: New file.
19538
19539         New module 'mbrtowc'.
19540         * lib/wchar.in.h (mbstate_t): Override when the system does not have
19541         mbsinit and mbrtowc.
19542         (mbrtowc): New declaration.
19543         * lib/mbrtowc.c: New file.
19544         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC, gl_PREREQ_MBRTOWC): New macros.
19545         * modules/mbrtowc: New file.
19546         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBRTOWC and
19547         HAVE_MBRTOWC.
19548         * modules/wchar (Makefile.am): Substitute GNULIB_MBRTOWC and
19549         HAVE_MBRTOWC.
19550         * doc/posix-functions/mbrtowc.texi: Document the new module.
19551
19552 2008-12-18  Bruno Haible  <bruno@clisp.org>
19553
19554         New module 'wctob'.
19555         * lib/wchar.in.h (wctob): New declaration.
19556         * lib/wctob.c: New file.
19557         * m4/wctob.m4: New file.
19558         * modules/wctob: New file.
19559         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_WCTOB and
19560         HAVE_WCTOB.
19561         * modules/wchar (Makefile.am): Substitute GNULIB_WCTOB and HAVE_WCTOB.
19562         * doc/posix-functions/wctob.texi: Document the new module.
19563
19564 2008-12-18  Bruno Haible  <bruno@clisp.org>
19565
19566         * m4/mbsinit.m4 (gl_FUNC_MBSINIT): Invoke gl_REPLACE_WCHAR_H.
19567         * m4/btowc.m4 (gl_FUNC_BTOWC): Likewise.
19568
19569 2008-12-18  Simon Josefsson  <simon@josefsson.org>
19570
19571         * lib/flock.c: Use proper #if symbol in check.  Reported by "Tom
19572         G. Christensen" <tgc@jupiterrise.com>.
19573
19574         * lib/flock.c: Need to include errno.h.  Reported by "Tom
19575         G. Christensen" <tgc@jupiterrise.com>.
19576
19577         * lib/flock.c: Need to include string.h.  Reported by "Tom
19578         G. Christensen" <tgc@jupiterrise.com> and Eric Blake
19579         <ebb9@byu.net>.
19580
19581 2008-12-18  Bruno Haible  <bruno@clisp.org>
19582
19583         * m4/locale-ja.m4: New file, from GNU gettext.
19584
19585 2008-12-17  Bruno Haible  <bruno@clisp.org>
19586
19587         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Don't override in autoconf >= 2.60.
19588         Suggested by Eric Blake.
19589
19590 2008-12-17  Bruno Haible  <bruno@clisp.org>
19591
19592         * m4/errno_h.m4 (AC_COMPUTE_INT): Provide fallback definition.
19593
19594 2008-12-17  Bruno Haible  <bruno@clisp.org>
19595
19596         * lib/mbsinit.c: Include verify.h. Verify an assumption.
19597         * modules/mbsinit (Depends-on): Add verify.
19598         Suggested by Paul Eggert.
19599
19600 2008-12-17  Bruno Haible  <bruno@clisp.org>
19601
19602         * m4/mbrtowc.m4 (AC_FUNC_MBRTOWC): Renamed from gl_FUNC_MBRTOWC.
19603         * m4/mbfile.m4 (gl_MBFILE): Use AC_FUNC_MBRTOWC instead of
19604         gl_FUNC_MBRTOWC.
19605         * m4/mbiter.m4 (gl_MBITER): LIkewise.
19606         * m4/mbscasecmp.m4 (gl_PREREQ_MBSCASECMP): Likewise.
19607         * m4/mbscasestr.m4 (gl_PREREQ_MBSCASESTR): Likewise.
19608         * m4/mbschr.m4 (gl_PREREQ_MBSCHR): Likewise.
19609         * m4/mbscspn.m4 (gl_PREREQ_MBSCSPN): Likewise.
19610         * m4/mbslen.m4 (gl_PREREQ_MBSLEN): Likewise.
19611         * m4/mbsncasecmp.m4 (gl_PREREQ_MBSNCASECMP): Likewise.
19612         * m4/mbsnlen.m4 (gl_PREREQ_MBSNLEN): Likewise.
19613         * m4/mbspbrk.m4 (gl_PREREQ_MBSPBRK): Likewise.
19614         * m4/mbspcasecmp.m4 (gl_PREREQ_MBSPCASECMP): Likewise.
19615         * m4/mbsrchr.m4 (gl_PREREQ_MBSRCHR): Likewise.
19616         * m4/mbssep.m4 (gl_PREREQ_MBSSEP): Likewise.
19617         * m4/mbsspn.m4 (gl_PREREQ_MBSSPN): Likewise.
19618         * m4/mbsstr.m4 (gl_PREREQ_MBSSTR): Likewise.
19619         * m4/mbstok_r.m4 (gl_PREREQ_MBSTOK_R): Likewise.
19620         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
19621         * m4/quotearg.m4 (gl_QUOTEARG): Likewise.
19622         * modules/trim (configure.ac): Likewise.
19623
19624 2008-12-17  Bruno Haible  <bruno@clisp.org>
19625
19626         * modules/btowc-tests: New file.
19627         * tests/test-btowc1.sh: New file.
19628         * tests/test-btowc2.sh: New file.
19629         * tests/test-btowc.c: New file.
19630
19631         New module 'btowc'.
19632         * lib/wchar.in.h (btowc): New declaration.
19633         * lib/btowc.c: New file.
19634         * m4/btowc.m4: New file.
19635         * modules/btowc: New file.
19636         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_BTOWC and
19637         HAVE_BTOWC.
19638         * modules/wchar (Makefile.am): Substitute GNULIB_BTOWC and HAVE_BTOWC.
19639         * doc/posix-functions/btowc.texi: Document the new module.
19640
19641 2008-12-17  Bruno Haible  <bruno@clisp.org>
19642
19643         New module 'mbsinit'.
19644         * lib/wchar.in.h (mbsinit): New declaration.
19645         * lib/mbsinit.c: New file.
19646         * m4/mbsinit.m4: New file.
19647         * modules/mbsinit: New file.
19648         * m4/wchar.m4 (gl_WCHAR_H_DEFAULTS): Initialize GNULIB_MBSINIT and
19649         HAVE_MBSINIT.
19650         * modules/wchar (Makefile.am): Substitute GNULIB_MBSINIT and
19651         HAVE_MBSINIT.
19652         * doc/posix-functions/mbsinit.texi: Document the new module.
19653
19654 2008-12-16  Bruno Haible  <bruno@clisp.org>
19655
19656         * lib/unistd.in.h: Add comment.
19657         * tests/test-environ.c: Don't include <stdlib.h>.
19658
19659 2008-12-16  Bruno Haible  <bruno@clisp.org>
19660
19661         * lib/parse-duration.h (parse_duration): Document return value
19662         convention.
19663         * lib/parse-duration.c: Include specification header first. Add
19664         comments.
19665         (_): Remove macro.
19666         (parse_year_month_day, parse_hour_minute_second): Move side effects
19667         outside of strchr call.
19668         (parse_non_iso8601): Move side effects outside of isspace call.
19669         (parse_duration): Don't test errno is res != BAD_TIME. Remove fprintf
19670         call.
19671
19672 2008-12-16  Bruno Haible  <bruno@clisp.org>
19673
19674         * tests/test-parse-duration.sh: Produce no output when the test
19675         succeeds.
19676
19677 2008-12-16  Bruno Haible  <bruno@clisp.org>
19678
19679         * tests/test-parse-duration.sh: Fix quoting of $tmp and $tmpf
19680         expressions.
19681
19682 2008-12-15  Bruno Haible  <bruno@clisp.org>
19683
19684         * doc/glibc-functions/fgetxattr.texi: Tweak wording.
19685         * doc/glibc-functions/flistxattr.texi: Likewise.
19686         * doc/glibc-functions/fopencookie.texi: Likewise.
19687         * doc/glibc-functions/fremovexattr.texi: Likewise.
19688         * doc/glibc-functions/fsetxattr.texi: Likewise.
19689         * doc/glibc-functions/getxattr.texi: Likewise.
19690         * doc/glibc-functions/lgetxattr.texi: Likewise.
19691         * doc/glibc-functions/listxattr.texi: Likewise.
19692         * doc/glibc-functions/llistxattr.texi: Likewise.
19693         * doc/glibc-functions/lremovexattr.texi: Likewise.
19694         * doc/glibc-functions/lsetxattr.texi: Likewise.
19695         * doc/glibc-functions/removexattr.texi: Likewise.
19696         * doc/glibc-functions/setxattr.texi: Likewise.
19697         * doc/posix-functions/open_memstream.texi: Likewise.
19698
19699 2008-12-15  Eric Blake  <ebb9@byu.net>
19700
19701         Update doc for cygwin 1.7.
19702         * doc/posix-functions/faccessat.texi: Cygwin 1.7 added several new
19703         functions.
19704         * doc/posix-functions/fchmodat.texi: Likewise.
19705         * doc/posix-functions/fchownat.texi: Likewise.
19706         * doc/posix-functions/fdopendir.texi: Likewise.
19707         * doc/posix-functions/fmemopen.texi: Likewise.
19708         * doc/posix-functions/freeaddrinfo.texi: Likewise.
19709         * doc/posix-functions/fstatat.texi: Likewise.
19710         * doc/posix-functions/futimens.texi: Likewise.
19711         * doc/posix-functions/gai_strerror.texi: Likewise.
19712         * doc/posix-functions/getaddrinfo.texi: Likewise.
19713         * doc/posix-functions/getnameinfo.texi: Likewise.
19714         * doc/posix-functions/if_freenameindex.texi: Likewise.
19715         * doc/posix-functions/if_indextoname.texi: Likewise.
19716         * doc/posix-functions/if_nameindex.texi: Likewise.
19717         * doc/posix-functions/if_nametoindex.texi: Likewise.
19718         * doc/posix-functions/insque.texi: Likewise.
19719         * doc/posix-functions/linkat.texi: Likewise.
19720         * doc/posix-functions/llrint.texi: Likewise.
19721         * doc/posix-functions/llrintf.texi: Likewise.
19722         * doc/posix-functions/llrintl.texi: Likewise.
19723         * doc/posix-functions/lockf.texi: Likewise.
19724         * doc/posix-functions/lrintl.texi: Likewise.
19725         * doc/posix-functions/mkdirat.texi: Likewise.
19726         * doc/posix-functions/mkfifoat.texi: Likewise.
19727         * doc/posix-functions/mknodat.texi: Likewise.
19728         * doc/posix-functions/mq_close.texi: Likewise.
19729         * doc/posix-functions/mq_getattr.texi: Likewise.
19730         * doc/posix-functions/mq_notify.texi: Likewise.
19731         * doc/posix-functions/mq_open.texi: Likewise.
19732         * doc/posix-functions/mq_receive.texi: Likewise.
19733         * doc/posix-functions/mq_send.texi: Likewise.
19734         * doc/posix-functions/mq_setattr.texi: Likewise.
19735         * doc/posix-functions/mq_timedreceive.texi: Likewise.
19736         * doc/posix-functions/mq_timedsend.texi: Likewise.
19737         * doc/posix-functions/mq_unlink.texi: Likewise.
19738         * doc/posix-functions/open_memstream.texi: Likewise.
19739         * doc/posix-functions/openat.texi: Likewise.
19740         * doc/posix-functions/posix_fadvise.texi: Likewise.
19741         * doc/posix-functions/posix_fallocate.texi: Likewise.
19742         * doc/posix-functions/posix_madvise.texi: Likewise.
19743         * doc/posix-functions/posix_memalign.texi: Likewise.
19744         * doc/posix-functions/posix_openpt.texi: Likewise.
19745         * doc/posix-functions/readlinkat.texi: Likewise.
19746         * doc/posix-functions/remque.texi: Likewise.
19747         * doc/posix-functions/renameat.texi: Likewise.
19748         * doc/posix-functions/rintl.texi: Likewise.
19749         * doc/posix-functions/sem_unlink.texi: Likewise.
19750         * doc/posix-functions/shm_open.texi: Likewise.
19751         * doc/posix-functions/shm_unlink.texi: Likewise.
19752         * doc/posix-functions/signgam.texi: Likewise.
19753         * doc/posix-functions/sigset.texi: Likewise.
19754         * doc/posix-functions/stpcpy.texi: Likewise.
19755         * doc/posix-functions/stpncpy.texi: Likewise.
19756         * doc/posix-functions/strerror.texi: Likewise.
19757         * doc/posix-functions/strtod.texi: Likewise.
19758         * doc/posix-functions/symlinkat.texi: Likewise.
19759         * doc/posix-functions/unlinkat.texi: Likewise.
19760         * doc/posix-functions/utimensat.texi: Likewise.
19761         * doc/glibc-functions/bindresvport.texi: Likewise.
19762         * doc/glibc-functions/dn_expand.texi: Likewise.
19763         * doc/glibc-functions/exp10.texi: Likewise.
19764         * doc/glibc-functions/exp10f.texi: Likewise.
19765         * doc/glibc-functions/fgetxattr.texi: Likewise.
19766         * doc/glibc-functions/flistxattr.texi: Likewise.
19767         * doc/glibc-functions/fopencookie.texi: Likewise.
19768         * doc/glibc-functions/freeifaddrs.texi: Likewise.
19769         * doc/glibc-functions/fremovexattr.texi: Likewise.
19770         * doc/glibc-functions/fsetxattr.texi: Likewise.
19771         * doc/glibc-functions/getifaddrs.texi: Likewise.
19772         * doc/glibc-functions/getxattr.texi: Likewise.
19773         * doc/glibc-functions/lgetxattr.texi: Likewise.
19774         * doc/glibc-functions/listxattr.texi: Likewise.
19775         * doc/glibc-functions/llistxattr.texi: Likewise.
19776         * doc/glibc-functions/lremovexattr.texi: Likewise.
19777         * doc/glibc-functions/lsetxattr.texi: Likewise.
19778         * doc/glibc-functions/pow10.texi: Likewise.
19779         * doc/glibc-functions/pow10f.texi: Likewise.
19780         * doc/glibc-functions/rcmd_af.texi: Likewise.
19781         * doc/glibc-functions/removexattr.texi: Likewise.
19782         * doc/glibc-functions/res_init.texi: Likewise.
19783         * doc/glibc-functions/res_mkquery.texi: Likewise.
19784         * doc/glibc-functions/res_query.texi: Likewise.
19785         * doc/glibc-functions/res_querydomain.texi: Likewise.
19786         * doc/glibc-functions/res_send.texi: Likewise.
19787         * doc/glibc-functions/rresvport_af.texi: Likewise.
19788         * doc/glibc-functions/setxattr.texi: Likewise.
19789         * doc/glibc-functions/strcasestr.texi: Likewise.
19790
19791 2008-12-15  Bruno Haible  <bruno@clisp.org>
19792
19793         Fix compilation error on OSF/1 4.0.
19794         * lib/sys_select.in.h: When invoked from OSF/1 <sys/types.h> or
19795         <sys/time.h>, simply delegate to the system header.
19796         Reported by Daniel Richard G. <oss@teragram.com>.
19797
19798 2008-12-15  Bruno Haible  <bruno@clisp.org>
19799
19800         * doc/posix-functions/openat.texi: Mention the 'openat' module.
19801         * doc/posix-functions/fchmodat.texi: Likewise.
19802         * doc/posix-functions/fchownat.texi: Likewise.
19803         * doc/posix-functions/fdopendir.texi: Likewise.
19804         * doc/posix-functions/fstatat.texi: Likewise.
19805         * doc/posix-functions/mkdirat.texi: Likewise.
19806         * doc/posix-functions/unlinkat.texi: Likewise.
19807
19808 2008-12-14  Bruno Haible  <bruno@clisp.org>
19809
19810         Update doc for POSIX:2008.
19811         * doc/posix-functions/faccessat.texi: New file.
19812         * doc/posix-functions/fchmodat.texi: New file.
19813         * doc/posix-functions/fchownat.texi: New file.
19814         * doc/posix-functions/fdopendir.texi: New file.
19815         * doc/posix-functions/fstatat.texi: New file.
19816         * doc/posix-functions/futimens.texi: New file.
19817         * doc/posix-functions/linkat.texi: New file.
19818         * doc/posix-functions/mkdirat.texi: New file.
19819         * doc/posix-functions/mkfifoat.texi: New file.
19820         * doc/posix-functions/mknodat.texi: New file.
19821         * doc/posix-functions/open_wmemstream.texi: New file.
19822         * doc/posix-functions/openat.texi: New file.
19823         * doc/posix-functions/psiginfo.texi: New file.
19824         * doc/posix-functions/pthread_mutex_consistent.texi: New file.
19825         * doc/posix-functions/pthread_mutexattr_getrobust.texi: New file.
19826         * doc/posix-functions/pthread_mutexattr_setrobust.texi: New file.
19827         * doc/posix-functions/readlinkat.texi: New file.
19828         * doc/posix-functions/renameat.texi: New file.
19829         * doc/posix-functions/strerror_l.texi: New file.
19830         * doc/posix-functions/symlinkat.texi: New file.
19831         * doc/posix-functions/unlinkat.texi: New file.
19832         * doc/posix-functions/utimensat.texi: New file.
19833         * doc/gnulib.texi (Function Substitutes): Add these subsections.
19834
19835 2008-12-14  Bruno Haible  <bruno@clisp.org>
19836
19837         Update doc for POSIX:2008.
19838         * doc/posix-functions/alphasort.texi: Renamed from
19839         doc/glibc-functions/alphasort.texi.
19840         * doc/posix-functions/dirfd.texi: Renamed from
19841         doc/glibc-functions/dirfd.texi.
19842         * doc/posix-functions/dprintf.texi: Renamed from
19843         doc/glibc-functions/dprintf.texi.
19844         * doc/posix-functions/duplocale.texi: Renamed from
19845         doc/glibc-functions/duplocale.texi.
19846         * doc/posix-functions/fexecve.texi: Renamed from
19847         doc/glibc-functions/fexecve.texi.
19848         * doc/posix-functions/fmemopen.texi: Renamed from
19849         doc/glibc-functions/fmemopen.texi.
19850         * doc/posix-functions/freelocale.texi: Renamed from
19851         doc/glibc-functions/freelocale.texi.
19852         * doc/posix-functions/getdate_err.texi: Renamed from
19853         doc/glibc-functions/getdate_err.texi.
19854         * doc/posix-functions/isalnum_l.texi: Renamed from
19855         doc/glibc-functions/isalnum_l.texi.
19856         * doc/posix-functions/isalpha_l.texi: Renamed from
19857         doc/glibc-functions/isalpha_l.texi.
19858         * doc/posix-functions/isblank_l.texi: Renamed from
19859         doc/glibc-functions/isblank_l.texi.
19860         * doc/posix-functions/iscntrl_l.texi: Renamed from
19861         doc/glibc-functions/iscntrl_l.texi.
19862         * doc/posix-functions/isdigit_l.texi: Renamed from
19863         doc/glibc-functions/isdigit_l.texi.
19864         * doc/posix-functions/isgraph_l.texi: Renamed from
19865         doc/glibc-functions/isgraph_l.texi.
19866         * doc/posix-functions/islower_l.texi: Renamed from
19867         doc/glibc-functions/islower_l.texi.
19868         * doc/posix-functions/isprint_l.texi: Renamed from
19869         doc/glibc-functions/isprint_l.texi.
19870         * doc/posix-functions/ispunct_l.texi: Renamed from
19871         doc/glibc-functions/ispunct_l.texi.
19872         * doc/posix-functions/isspace_l.texi: Renamed from
19873         doc/glibc-functions/isspace_l.texi.
19874         * doc/posix-functions/isupper_l.texi: Renamed from
19875         doc/glibc-functions/isupper_l.texi.
19876         * doc/posix-functions/iswalnum_l.texi: Renamed from
19877         doc/glibc-functions/iswalnum_l.texi.
19878         * doc/posix-functions/iswalpha_l.texi: Renamed from
19879         doc/glibc-functions/iswalpha_l.texi.
19880         * doc/posix-functions/iswblank_l.texi: Renamed from
19881         doc/glibc-functions/iswblank_l.texi.
19882         * doc/posix-functions/iswcntrl_l.texi: Renamed from
19883         doc/glibc-functions/iswcntrl_l.texi.
19884         * doc/posix-functions/iswctype_l.texi: Renamed from
19885         doc/glibc-functions/iswctype_l.texi.
19886         * doc/posix-functions/iswdigit_l.texi: Renamed from
19887         doc/glibc-functions/iswdigit_l.texi.
19888         * doc/posix-functions/iswgraph_l.texi: Renamed from
19889         doc/glibc-functions/iswgraph_l.texi.
19890         * doc/posix-functions/iswlower_l.texi: Renamed from
19891         doc/glibc-functions/iswlower_l.texi.
19892         * doc/posix-functions/iswprint_l.texi: Renamed from
19893         doc/glibc-functions/iswprint_l.texi.
19894         * doc/posix-functions/iswpunct_l.texi: Renamed from
19895         doc/glibc-functions/iswpunct_l.texi.
19896         * doc/posix-functions/iswspace_l.texi: Renamed from
19897         doc/glibc-functions/iswspace_l.texi.
19898         * doc/posix-functions/iswupper_l.texi: Renamed from
19899         doc/glibc-functions/iswupper_l.texi.
19900         * doc/posix-functions/iswxdigit_l.texi: Renamed from
19901         doc/glibc-functions/iswxdigit_l.texi.
19902         * doc/posix-functions/isxdigit_l.texi: Renamed from
19903         doc/glibc-functions/isxdigit_l.texi.
19904         * doc/posix-functions/mbsnrtowcs.texi: Renamed from
19905         doc/glibc-functions/mbsnrtowcs.texi.
19906         * doc/posix-functions/mkdtemp.texi: Renamed from
19907         doc/glibc-functions/mkdtemp.texi.
19908         * doc/posix-functions/newlocale.texi: Renamed from
19909         doc/glibc-functions/newlocale.texi.
19910         * doc/posix-functions/nl_langinfo_l.texi: Renamed from
19911         doc/glibc-functions/nl_langinfo_l.texi.
19912         * doc/posix-functions/open_memstream.texi: Renamed from
19913         doc/glibc-functions/open_memstream.texi.
19914         * doc/posix-functions/opterr.texi: Renamed from
19915         doc/glibc-functions/opterr.texi.
19916         * doc/posix-functions/optind.texi: Renamed from
19917         doc/glibc-functions/optind.texi.
19918         * doc/posix-functions/optopt.texi: Renamed from
19919         doc/glibc-functions/optopt.texi.
19920         * doc/posix-functions/psignal.texi: Renamed from
19921         doc/glibc-functions/psignal.texi.
19922         * doc/posix-functions/scandir.texi: Renamed from
19923         doc/glibc-functions/scandir.texi.
19924         * doc/posix-functions/sched_get_priority_min.texi: Renamed from
19925         doc/glibc-functions/sched_get_priority_min.texi.
19926         * doc/posix-functions/signgam.texi: Renamed from
19927         doc/glibc-functions/signgam.texi.
19928         * doc/posix-functions/stpcpy.texi: Renamed from
19929         doc/glibc-functions/stpcpy.texi.
19930         * doc/posix-functions/stpncpy.texi: Renamed from
19931         doc/glibc-functions/stpncpy.texi.
19932         * doc/posix-functions/strcasecmp_l.texi: Renamed from
19933         doc/glibc-functions/strcasecmp_l.texi.
19934         * doc/posix-functions/strcoll_l.texi: Renamed from
19935         doc/glibc-functions/strcoll_l.texi.
19936         * doc/posix-functions/strfmon_l.texi: Renamed from
19937         doc/glibc-functions/strfmon_l.texi.
19938         * doc/posix-functions/strftime_l.texi: Renamed from
19939         doc/glibc-functions/strftime_l.texi.
19940         * doc/posix-functions/strncasecmp_l.texi: Renamed from
19941         doc/glibc-functions/strncasecmp_l.texi.
19942         * doc/posix-functions/strndup.texi: Renamed from
19943         doc/glibc-functions/strndup.texi.
19944         * doc/posix-functions/strnlen.texi: Renamed from
19945         doc/glibc-functions/strnlen.texi.
19946         * doc/posix-functions/strsignal.texi: Renamed from
19947         doc/glibc-functions/strsignal.texi.
19948         * doc/posix-functions/strxfrm_l.texi: Renamed from
19949         doc/glibc-functions/strxfrm_l.texi.
19950         * doc/posix-functions/timer_gettime.texi: Renamed from
19951         doc/glibc-functions/timer_gettime.texi.
19952         * doc/posix-functions/tolower_l.texi: Renamed from
19953         doc/glibc-functions/tolower_l.texi.
19954         * doc/posix-functions/toupper_l.texi: Renamed from
19955         doc/glibc-functions/toupper_l.texi.
19956         * doc/posix-functions/towctrans_l.texi: Renamed from
19957         doc/glibc-functions/towctrans_l.texi.
19958         * doc/posix-functions/towlower_l.texi: Renamed from
19959         doc/glibc-functions/towlower_l.texi.
19960         * doc/posix-functions/towupper_l.texi: Renamed from
19961         doc/glibc-functions/towupper_l.texi.
19962         * doc/posix-functions/uselocale.texi: Renamed from
19963         doc/glibc-functions/uselocale.texi.
19964         * doc/posix-functions/vdprintf.texi: Renamed from
19965         doc/glibc-functions/vdprintf.texi.
19966         * doc/posix-functions/wcpcpy.texi:
19967         Renamed from doc/glibc-functions/wcpcpy.texi.
19968         * doc/posix-functions/wcpncpy.texi: Renamed from
19969         doc/glibc-functions/wcpncpy.texi.
19970         * doc/posix-functions/wcscasecmp.texi: Renamed from
19971         doc/glibc-functions/wcscasecmp.texi.
19972         * doc/posix-functions/wcscasecmp_l.texi: Renamed from
19973         doc/glibc-functions/wcscasecmp_l.texi.
19974         * doc/posix-functions/wcscoll_l.texi: Renamed from
19975         doc/glibc-functions/wcscoll_l.texi.
19976         * doc/posix-functions/wcsdup.texi: Renamed from
19977         doc/glibc-functions/wcsdup.texi.
19978         * doc/posix-functions/wcsncasecmp.texi: Renamed from
19979         doc/glibc-functions/wcsncasecmp.texi.
19980         * doc/posix-functions/wcsncasecmp_l.texi: Renamed from
19981         doc/glibc-functions/wcsncasecmp_l.texi.
19982         * doc/posix-functions/wcsnlen.texi: Renamed from
19983         doc/glibc-functions/wcsnlen.texi.
19984         * doc/posix-functions/wcsnrtombs.texi: Renamed from
19985         doc/glibc-functions/wcsnrtombs.texi.
19986         * doc/posix-functions/wcsxfrm_l.texi: Renamed from
19987         doc/glibc-functions/wcsxfrm_l.texi.
19988         * doc/posix-functions/wctrans_l.texi: Renamed from
19989         doc/glibc-functions/wctrans_l.texi.
19990         * doc/posix-functions/wctype_l.texi: Renamed from
19991         doc/glibc-functions/wctype_l.texi.
19992         * doc/gnulib.texi (Function Substitutes): Add these subsections.
19993         (Glibc ctype.h, Glibc dirent.h, Glibc getopt.h, Glibc math.h,
19994         Glibc sched.h, Glibc signal.h, Glibc stdio.h, Glibc stdlib.h,
19995         Glibc string.h, Glibc time.h, Glibc unistd.h, Glibc wchar.h): Remove
19996         these subsections.
19997         (Glibc langinfo.h, Glibc locale.h, Glibc monetary.h, Glibc wctype.h):
19998         Remove sections.
19999
20000 2008-12-14  Bruno Haible  <bruno@clisp.org>
20001
20002         Update doc for POSIX:2008.
20003         * doc/posix-functions/*.texi: Update URL of POSIX specification.
20004
20005 2008-12-14  Bruno Haible  <bruno@clisp.org>
20006
20007         Update doc for POSIX:2008.
20008         * doc/pastposix-functions/bcmp.texi: Renamed from
20009         doc/posix-functions/bcmp.texi.
20010         * doc/pastposix-functions/bcopy.texi: Renamed from
20011         doc/posix-functions/bcopy.texi.
20012         * doc/pastposix-functions/bsd_signal.texi: Renamed from
20013         doc/posix-functions/bsd_signal.texi.
20014         * doc/pastposix-functions/bzero.texi: Renamed from
20015         doc/posix-functions/bzero.texi.
20016         * doc/pastposix-functions/ecvt.texi: Renamed from
20017         doc/posix-functions/ecvt.texi.
20018         * doc/pastposix-functions/fcvt.texi: Renamed from
20019         doc/posix-functions/fcvt.texi.
20020         * doc/pastposix-functions/ftime.texi: Renamed from
20021         doc/posix-functions/ftime.texi.
20022         * doc/pastposix-functions/gcvt.texi: Renamed from
20023         doc/posix-functions/gcvt.texi.
20024         * doc/pastposix-functions/getcontext.texi: Renamed from
20025         doc/posix-functions/getcontext.texi.
20026         * doc/pastposix-functions/gethostbyaddr.texi: Renamed from
20027         doc/posix-functions/gethostbyaddr.texi.
20028         * doc/pastposix-functions/gethostbyname.texi: Renamed from
20029         doc/posix-functions/gethostbyname.texi.
20030         * doc/pastposix-functions/getwd.texi: Renamed from
20031         doc/posix-functions/getwd.texi.
20032         * doc/pastposix-functions/h_errno.texi: Renamed from
20033         doc/posix-functions/h_errno.texi.
20034         * doc/pastposix-functions/index.texi: Renamed from
20035         doc/posix-functions/index.texi.
20036         * doc/pastposix-functions/makecontext.texi: Renamed from
20037         doc/posix-functions/makecontext.texi.
20038         * doc/pastposix-functions/mktemp.texi: Renamed from
20039         doc/posix-functions/mktemp.texi.
20040         * doc/pastposix-functions/pthread_attr_getstackaddr.texi: Renamed from
20041         doc/posix-functions/pthread_attr_getstackaddr.texi.
20042         * doc/pastposix-functions/pthread_attr_setstackaddr.texi: Renamed from
20043         doc/posix-functions/pthread_attr_setstackaddr.texi.
20044         * doc/pastposix-functions/rindex.texi: Renamed from
20045         doc/posix-functions/rindex.texi.
20046         * doc/pastposix-functions/scalb.texi: Renamed from
20047         doc/posix-functions/scalb.texi.
20048         * doc/pastposix-functions/setcontext.texi: Renamed from
20049         doc/posix-functions/setcontext.texi.
20050         * doc/pastposix-functions/swapcontext.texi: Renamed from
20051         doc/posix-functions/swapcontext.texi.
20052         * doc/pastposix-functions/ualarm.texi: Renamed from
20053         doc/posix-functions/ualarm.texi.
20054         * doc/pastposix-functions/usleep.texi: Renamed from
20055         doc/posix-functions/usleep.texi.
20056         * doc/pastposix-functions/vfork.texi: Renamed from
20057         doc/posix-functions/vfork.texi.
20058         * doc/pastposix-functions/wcswcs.texi: Renamed from
20059         doc/posix-functions/wcswcs.texi.
20060         * doc/gnulib.texi (Legacy Function Substitutes): New chapter.
20061         (Function Substitutes): Update.
20062
20063 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20064
20065         * modules/relocatable-prog-wrapper (Depends-on): Add errno, needed by
20066         m4/strerror.m4.
20067
20068 2008-12-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20069             Bruno Haible  <bruno@clisp.org>
20070
20071         * modules/unilbrk/tables (Depends-on): Add unilbrk/base.
20072
20073 2008-12-13  Bruno Haible  <bruno@clisp.org>
20074
20075         * modules/strtoull (Depends-on): Remove unistd.
20076
20077 2008-12-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20078
20079         * modules/strtoull (Depends-on): Add stdlib.
20080
20081 2008-12-11  Simon Josefsson  <simon@josefsson.org>
20082
20083         * m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC): Add more warnings.
20084
20085 2008-12-10  Jim Meyering  <meyering@redhat.com>
20086
20087         gl_ASSERT: don't say assertions are disabled when they're not
20088         * m4/assert.m4 (gl_ASSERT): Do not make configure report
20089         "checking whether to enable assertions... no", when they are in
20090         fact enabled.  This is solely a bug in the output of configure.
20091         In spite of saying "no", NDEBUG was not defined in that case.
20092         Also, as noted by Eric Blake, leave assertions enabled upon
20093         --enable-assert=INVALID.
20094
20095 2008-12-10  Bruno Haible  <bruno@clisp.org>
20096
20097         Change MODULES.html to refer to POSIX:2008 where possible.
20098         * MODULES.html.sh (POSIX2008_URL): New variable.
20099         (posix_headers): Remove sys/timeb, ucontext.
20100         (posix2001_headers): New variable.
20101         (posix_functions): Remove bcmp, bcopy, bsd_signal, bzero, ecvt, fcvt,
20102         ftime, gcvt, getcontext, gethostbyaddr, gethostbyname, getwd, h_errno,
20103         index, makecontext, mktemp, pthread_attr_getstackaddr,
20104         pthread_attr_setstackaddr, rindex, scalb, setcontext, swapcontext,
20105         ualarm, usleep, vfork, wcswcs. Add the new POSIX:2008 functions.
20106         (posix2001_functions): New variable.
20107         (func_module): Use URLs to POSIX:2008 where possible and to POSIX:2001
20108         otherwise.
20109
20110 2008-12-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20111
20112         add missing include to parse-duration.c
20113         * lib/parse-duration.c: #include "xalloc.h", for xstrdup.
20114         * modules/parse-duration (Depends-on): Add xalloc.
20115
20116         fix sed script reading maint.mk
20117         * top/maint.mk (MYSELF): New macro, define as $(srcdir)/$(ME).
20118         (syntax-check-rules): Use it.
20119
20120 2008-12-09  Bruno Haible  <bruno@clisp.org>
20121
20122         * m4/ldexpl.m4 (gl_FUNC_LDEXPL_WORKS): Add another check, that fails on
20123         MacOS X 10.4/PowerPC.
20124         Reported by Simon Josefsson.
20125
20126 2008-12-08  Jim Meyering  <meyering@redhat.com>
20127
20128         work around mingw's lack of some S_IF definitions
20129         * lib/fts.c (S_IFLNK, S_IFSOCK): Define if not already defined.
20130         Reported by Simon Josefsson.
20131
20132 2008-12-08  Bruno Haible  <bruno@clisp.org>
20133
20134         * m4/signbitl.m4 (gl_SIGNBIT_TEST_PROGRAM): Add a link check of signbit
20135         applied to variables. Needed on MacOS X 10.4/PowerPC.
20136         Reported by Simon Josefsson.
20137
20138 2008-12-08  William Pursell  <bill.pursell@gmail.com>  (tiny change)
20139         and Eric Blake  <ebb9@byu.net>
20140
20141         assert: honor --enable-assert
20142         * m4/assert.m4 (gl_ASSERT): Synchronize with autoconf 2.64, in
20143         order to honor --enable-assert, rather than treating it as a
20144         synonym for --disable-assert.
20145
20146 2008-12-08  Jim Meyering  <meyering@redhat.com>
20147
20148         * lib/posixtm.c: Remove now-useless declaration of mktime.
20149
20150         * build-aux/announce-gen (get_tool_versions): Accept .xz tarballs.
20151
20152 2008-12-07  Bruno Haible  <bruno@clisp.org>
20153
20154         * tests/test-lock.c (test_lock, test_rwlock, test_recursive_lock,
20155         test_once): Mark functions as static.
20156         * tests/test-tls.c (test_tls): Likewise.
20157
20158 2008-12-07  Bruno Haible  <bruno@clisp.org>
20159
20160         * lib/striconveha.h (uniconv_register_autodetect): Renamed from
20161         iconv_register_autodetect.
20162
20163 2008-12-07  Jim Meyering  <meyering@redhat.com>
20164
20165         posixtm.c: avoid a warning
20166         * lib/posixtm.c (posixtime): Don't initialize tm0.
20167         It's no longer needed to placate gcc4's -Wuninitialized,
20168         and the attempt to placate would elicit a new warning.
20169
20170         unicodeio.c: mark unused parameters
20171         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
20172         (fallback_failure_callback): Likewise.
20173
20174 2008-12-07  Bruno Haible  <bruno@clisp.org>
20175
20176         * gnulib-tool (func_create_testdir): When building the tests
20177         subdirectory, ignore the modules gnumakefile and maintainer-makefile.
20178         Reported by Simon Josefsson.
20179
20180 2008-12-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20181
20182         * doc/manywarnings.texi, doc/gnulib-intro.texi: Fix typos.
20183
20184 2008-12-06  Bruno Haible  <bruno@clisp.org>
20185
20186         * lib/c-stack.h (c_stack_action): Clarify possible side effects.
20187         Suggested by Eric Blake.
20188
20189 2008-12-06  Bruno Haible  <bruno@clisp.org>
20190
20191         Fix a c-stack test failure on MacOS X.
20192         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Require
20193         AC_CANONICAL_HOST. Define FAULT_YIELDS_SIGBUS. If set, install a signal
20194         handler for SIGBUS as well.
20195         * lib/c-stack.c (c_stack_action): If FAULT_YIELDS_SIGBUS is set,
20196         install a signal handler for SIGBUS as well.
20197         Reported by Bruce Dugan <bld0401@gmail.com> via Eric Blake.
20198
20199 2008-12-06  Bruno Haible  <bruno@clisp.org>
20200
20201         Advocacy documentation.
20202         * doc/gnulib-intro.texi (Benefits): New section.
20203         * doc/gnulib.texi: Update.
20204
20205 2008-12-06  Bruno Haible  <bruno@clisp.org>
20206
20207         Document the 'manywarnings' module.
20208         * doc/manywarnings.texi: New file.
20209         * doc/gnulib.texi: Include it.
20210
20211 2008-12-05  Eric Blake  <ebb9@byu.net>
20212
20213         tests: silence some gcc warnings
20214         * tests/test-getdate.c (LOG) [!DEBUG]: Mark no-op void.
20215         * tests/uniwidth/test-uc_width2.c (finish_interval): Avoid printf
20216         type mismatches.
20217
20218 2008-12-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
20219             Bruno Haible  <bruno@clisp.org>
20220
20221         * m4/openmp.m4 (AC_OPENMP): Do not define with Autoconf 2.62 or newer.
20222
20223 2008-11-29  Jim Meyering  <meyering@redhat.com>
20224
20225         unicodeio.c: mark unused parameters
20226         * lib/unicodeio.c (exit_failure_callback): Mark unused parameter.
20227         (fallback_failure_callback): Likewise.
20228
20229         fts: fix a thinko
20230         * lib/fts.c (s_ifmt_shift_bits): Remove function.  Not needed after all.
20231         (set_stat_type): Return S_IF*-valued "type" directly.
20232         Prompted by James Youngman's spotting a related bug.
20233         Confirmed by further testing through find.
20234
20235         fts: provide dirent.d_type via FTSENT.fts_statp, when possible
20236         * lib/fts.c (D_TYPE): Define.
20237         (DT_UNKNOWN, DT_BLK, DT_CHR) [HAVE_STRUCT_DIRENT_D_TYPE]: Define.
20238         (DT_DIR, DT_FIFO, DT_LNK, DT_REG, DT_SOCK): Likewise.
20239         (s_ifmt_shift_bits): New function.
20240         (set_stat_type): New function.
20241         (fts_build): When not calling fts_stat, call set_stat_type
20242         to propagate dirent.d_type info to fts_read caller.
20243         * lib/fts_.h (FTSENT) [FTS_DEFER_STAT]: Mention that
20244         fts_statp->st_mode type information may be valid.
20245
20246 2008-11-28  Simon Josefsson  <simon@josefsson.org>
20247
20248         * lib/sys_time.in.h: Add extern "C" block for C++.  Suggested by
20249         Brian Dessent <brian@dessent.net>.  Reported by Sam Steingold
20250         <sds@gnu.org>.
20251
20252 2008-11-20  Bruno Haible  <bruno@clisp.org>
20253
20254         Attempt to work around an AIX 5.3, 6.1 compiler bug with include_next.
20255         * lib/math.in.h: Use INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of
20256         INCLUDE_NEXT.
20257         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also
20258         INCLUDE_NEXT_AS_FIRST_DIRECTIVE.
20259         * modules/math (Makefile.am): Substitute
20260         INCLUDE_NEXT_AS_FIRST_DIRECTIVE instead of INCLUDE_NEXT.
20261         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
20262
20263 2008-11-18  Alexandre Duret-Lutz  <adl@lrde.epita.fr>
20264             Bruno Haible  <bruno@clisp.org>
20265
20266         * lib/stdint.in.h: Define all type macros so that their expansion is
20267         a single typedef'ed token. Fixes a compilation failure in Boost which
20268         does "using ::int8_t;".
20269
20270 2008-11-18  Simon Josefsson  <simon@josefsson.org>
20271
20272         * m4/manywarnings.m4: New file with gl_MANYWARN_COMPLEMENT and
20273         gl_MANYWARN_ALL_GCC.
20274         * m4/warnings.m4: Removed gl_WARN_SUPPORTED and
20275         gl_WARN_COMPLEMENT.  Suggested by Bruno Haible <bruno@clisp.org>.
20276         * modules/manywarnings: New file.
20277         * MODULES.html.sh: Mention manywarnings module.
20278
20279 2008-11-18  Bruno Haible  <bruno@clisp.org>
20280
20281         * doc/gnulib-tool.texi (Unit tests): New section.
20282
20283 2008-11-18  Simon Josefsson  <simon@josefsson.org>
20284
20285         * top/maint.mk (refresh-po): Fix sed regexp to avoid problems with
20286         paths like 'lib/po/foo.po'.
20287
20288 2008-11-17  Simon Josefsson  <simon@josefsson.org>
20289
20290         * m4/warnings.m4: Improve code.  Reported by Ralf Wildenhues
20291         <Ralf.Wildenhues@gmx.de> and Paolo Bonzini <bonzini@gnu.org>.
20292
20293 2008-11-17  Simon Josefsson  <simon@josefsson.org>
20294
20295         * m4/warnings.m4: Use CPPFLAGS to really check whether the
20296         parameter works.
20297
20298 2008-11-17  Simon Josefsson  <simon@josefsson.org>
20299
20300         * m4/warnings.m4: Add gl_WARN_COMPLEMENT and gl_WARN_SUPPORTED.
20301
20302 2008-11-17  Bruce Korb  <bkorb@gnu.org>
20303
20304         * modules/parse-duration-tests: New file.
20305         * tests/test-parse-duration.sh: New file.
20306         * tests/test-parse-duration.c: New file.
20307
20308         New module 'parse-duration'.
20309         * lib/parse-duration.h: New file.
20310         * lib/parse-duration.c: New file.
20311         * modules/parse-duration: New file.
20312
20313 2008-11-17  Bruno Haible  <bruno@clisp.org>
20314
20315         * tests/test-select-out.sh: Comment out the first pipe test.
20316         Reported by Simon Josefsson.
20317
20318 2008-11-17  Bruno Haible  <bruno@clisp.org>
20319
20320         * modules/getaddrinfo (Depends-on): Add servent, hostent.
20321         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_SERVENT and
20322         gl_HOSTENT.
20323
20324 2008-11-17  Bruno Haible  <bruno@clisp.org>
20325
20326         * m4/sockets.m4 (gl_SOCKETS): After trying -lsocket, try also
20327         -lnetwork and -lnet. Needed for Haiku and BeOS.
20328
20329 2008-11-16  Bruno Haible  <bruno@clisp.org>
20330
20331         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix indentation.
20332
20333 2008-11-16  Bruno Haible  <bruno@clisp.org>
20334
20335         Avoid test failure on Haiku.
20336         * tests/test-fsync.c: Include <errno.h>.
20337         (main): Don't require that fsync (0) fails.
20338
20339 2008-11-15  Bruno Haible  <bruno@clisp.org>
20340
20341         New module 'hostent'.
20342         * modules/hostent: New file.
20343         * m4/hostent.m4: New file, based on code in m4/getaddrinfo.m4.
20344
20345 2008-11-15  Bruno Haible  <bruno@clisp.org>
20346
20347         New module 'servent'.
20348         * modules/servent: New file.
20349         * m4/servent.m4: New file, based on code in m4/getaddrinfo.m4.
20350
20351 2008-11-15  Bruno Haible  <bruno@clisp.org>
20352
20353         Avoid generating same test program with two different rules.
20354         * modules/frexp-nolibm-tests (Makefile.am): Rename test program from
20355         test-frexp to test-frexp-nolibm.
20356         * modules/frexpl-nolibm-tests (Makefile.am): Rename test program from
20357         test-frexpl to test-frexpl-nolibm.
20358
20359 2008-11-15  Bruno Haible  <bruno@clisp.org>
20360
20361         * modules/frexpl-tests (Makefile.am): Link test-frexpl with
20362         $(FREXPL_LIBM).
20363
20364 2008-11-15  Bruno Haible  <bruno@clisp.org>
20365
20366         * lib/netdb.in.h: Activate the definitions also when the system's
20367         <netdb.h> has 'struct addrinfo'.
20368         * m4/netdb_h.m4 (gl_HEADER_NETDB): Replace netdb.h also when it lacks
20369         EAI_OVERFLOW or AI_NUMERICSERV.
20370         * doc/posix-headers/netdb.texi: Document the problem.
20371
20372 2008-11-15  Bruno Haible  <bruno@clisp.org>
20373
20374         * tests/test-sched.c: Test also the existence of the SCHED_* macros.
20375
20376         Make the 'sched' module work on platforms where <sched.h> exists but
20377         is incomplete (such as Haiku).
20378         * lib/sched.in.h; Include the system's <sched.h> if it exists.
20379         (SCHED_FIFO, SCHED_RR, SCHED_OTHER): New macros.
20380         * m4/sched_h.m4 (gl_SCHED_H): Test whether <sched.h> exists and also
20381         defines SCHED_FIFO, SCHED_RR, SCHED_OTHER. Set HAVE_SCHED_H,
20382         HAVE_STRUCT_SCHED_PARAM.
20383         * modules/sched (Depends-on): Add include_next.
20384         (Makefile.am): Substitute HAVE_SCHED_H, INCLUDE_NEXT,
20385         PRAGMA_SYSTEM_HEADER, NEXT_SCHED_H, HAVE_STRUCT_SCHED_PARAM.
20386         * doc/posix-headers/sched.texi: Document the issue.
20387
20388 2008-11-13  Jim Meyering  <meyering@redhat.com>
20389
20390         test-argp-2: avoid test failure when PACKAGE_BUGREPORT is defined
20391         * tests/test-argp-2.sh: When PACKAGE_BUGREPORT was defined, this
20392         test would fail due to the difference in the Report bugs to ...
20393         line.  The expected address is empty, "<>", while the actual
20394         would contain e.g., "<bug-tar@gnu.org>".  Filter out any address.
20395
20396 2008-11-12  Bruno Haible  <bruno@clisp.org>
20397
20398         lstat: don't compile lstat.c on systems lacking lstat
20399         * m4/lstat.m4 (gl_FUNC_LSTAT): Don't compile lstat.c on systems
20400         which don't have lstat; this is handled by lib/sys_stat.in.h already.
20401         Reported by Daniel P. Berrange via Jim Meyering.
20402
20403 2008-11-12  Jim Meyering  <meyering@redhat.com>
20404
20405         * lib/unicodeio.c (unicode_to_mb): Correct spelling of u8_uctomb.
20406
20407 2008-11-12  Simon Josefsson  <simon@josefsson.org>
20408
20409         * modules/warnings (configure.ac): Do AC_SUBST([WARN_CFLAGS]) here
20410         instead.
20411
20412 2008-11-12  Bruno Haible  <bruno@clisp.org>
20413
20414         * lib/unicodeio.c: Include unistr.h.
20415         (utf8_wctomb): Remove function.
20416         (unicode_to_mb): Use utf8_uctomb instead of utf8_wctomb.
20417
20418 2008-11-12  Simon Josefsson  <simon@josefsson.org>
20419
20420         * m4/warnings.m4 (gl_WARN_INIT): Remove, suggested by Ralf
20421         Wildenhues <Ralf.Wildenhues@gmx.de> and Bruno Haible
20422         <bruno@clisp.org>.
20423         * modules/warnings (configure.ac): Don't call gl_WARN_INIT.
20424
20425 2008-11-12  Simon Josefsson  <simon@josefsson.org>
20426
20427         * doc/warnings.texi: New file, from Bruno Haible <bruno@clisp.org>.
20428         * doc/gnulib.texi: Add section for warnings.
20429
20430 2008-11-11  Bruno Haible  <bruno@clisp.org>
20431
20432         * lib/sockets.h: Add a comment.
20433
20434 2008-11-11  Karl Berry  <karl@gnu.org>
20435
20436         * config/srclist.txt (fdl.texi): add, syncing from gnustandards.
20437
20438 2008-11-11  Eric Blake  <ebb9@byu.net>
20439
20440         fdl.texi: avoid git symlinks
20441         * doc/fdl.texi: Copy, rather than link, fdl-1.3.texi.
20442
20443 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
20444
20445         * m4/warnings.m4 (gl_WARN_ADD): Don't AC_SUBST the empty string.
20446
20447 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
20448
20449         * m4/warnings.m4 (gl_WARN_INIT): Substitute WARN_CFLAGS.
20450         (gl_WARN_ADD): Substitute $2 if literal.
20451
20452 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
20453
20454         * m4/warning.m4: Remove.
20455
20456 2008-11-11  Paolo Bonzini  <bonzini@gnu.org>
20457
20458         * m4/warnings.m4: Almost complete rewrite. :-)
20459
20460 2008-11-10  Simon Josefsson  <simon@josefsson.org>
20461
20462         * modules/warnings: New module.
20463         * m4/warnings.m4: New file.
20464         * MODULES.html.sh: Mention warnings module.
20465         With review improvements from Paolo Bonzini <bonzini@gnu.org> and
20466         Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
20467
20468 2008-11-10  Eric Blake  <ebb9@byu.net>
20469
20470         fdl.texi: make a symlink to the latest version
20471         * doc/standards.texi: Revert today's earlier change.
20472         * doc/fdl-1.2.texi: Rename from old fdl.texi...
20473         * doc/fdl.texi: ...and replace this with a symlink to the newer
20474         fdl-1.3.texi.
20475
20476 2008-11-10  Bruno Haible  <bruno@clisp.org>
20477
20478         * tests/test-select-fd.c (main): Accept the result file name as fourth
20479         argument.
20480         * tests/test-select-in.sh: Pass t-select-in.tmp as fourth argument.
20481         * tests/test-select-out.sh: Pass t-select-out.tmp as fourth argument.
20482
20483 2008-11-10  Bruno Haible  <bruno@clisp.org>
20484
20485         * lib/netdb.in.h: Use HAVE_STRUCT_ADDRINFO, HAVE_DECL_GETADDRINFO,
20486         HAVE_DECL_FREEADDRINFO, HAVE_DECL_GAI_STRERROR, HAVE_DECL_GETNAMEINFO
20487         as autoconf-substituted macros.
20488         * m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Initialize these variables to 1.
20489         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require
20490         gl_NETDB_H_DEFAULTS. Set these variables.
20491         * modules/netdb (Makefile.am): Substitute these variables.
20492
20493 2008-11-10  Eric Blake  <ebb9@byu.net>
20494
20495         standards.texi: include correct file for FDL 1.3
20496         * doc/standards.texi (GNU Free Documentation License): Change
20497         include file to pull in FDL 1.3, not 1.2.
20498
20499         fdl.texi: revert accidental change to license
20500         * doc/fdl.texi: This is FDL 1.2, not 1.3.
20501
20502 2008-11-10  Bruno Haible  <bruno@clisp.org>
20503
20504         * m4/printf.m4 (gl_PRINTF_ENOMEM): Guess yes on Haiku. Use the
20505         cross-compiling guesses also when the native compile gives no result.
20506
20507 2008-11-10  Bruno Haible  <bruno@clisp.org>
20508
20509         * lib/spawni.c (__spawni): Force variable into the stack.
20510
20511 2008-11-10  Bruno Haible  <bruno@clisp.org>
20512
20513         Add support for Haiku.
20514         * lib/fbufmode.c (fbufmode): Test a symbol that is not only defined on
20515         glibc and BeOS, but also on Haiku.
20516         * lib/fpurge.c (fpurge): Likewise.
20517         * lib/freadable.c (freadable): Likewise.
20518         * lib/freadahead.c (freadahead): Likewise.
20519         * lib/freading.c (freading): Likewise.
20520         * lib/freadptr.c (freadptr): Likewise.
20521         * lib/freadseek.c (freadptrinc): Likewise.
20522         * lib/fseeko.c (rpl_fseeko): Likewise.
20523         * lib/fseterr.c (fseterr): Likewise.
20524         * lib/fwritable.c (fwritable): Likewise.
20525         * lib/fwriting.c (fwriting): Likewise.
20526         Reported by Ingo Weinhold <ingo_weinhold@gmx.de>.
20527
20528 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
20529
20530         * lib/config.charset: Treat Haiku like BeOS.
20531
20532 2008-11-10  Ingo Weinhold  <ingo_weinhold@gmx.de>
20533
20534         * lib/binary-io.h (O_BINARY, O_TEXT): Treat Haiku like BeOS.
20535         * lib/fcntl.in.h (O_BINARY, O_TEXT): Likewise.
20536
20537 2008-11-08  Bruno Haible  <bruno@clisp.org>
20538
20539         * m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H): Avoid using AC_CHECK_DECL inside
20540         AC_CACHE_CHECK.
20541
20542 2008-11-08  Bruno Haible  <bruno@clisp.org>
20543
20544         * modules/select-tests (configure.ac): Check for unistd.h, sys/wait.h.
20545
20546 2008-11-08  Bruno Haible  <bruno@clisp.org>
20547
20548         * tests/test-select-fd.c: New file.
20549         * tests/test-select-in.sh: New file.
20550         * tests/test-select-out.sh: New file.
20551         * tests/test-select-stdin.c: New file.
20552         * modules/select-tests (Files): Add the new files.
20553         (Depends-on): Add gettimeofday.
20554         (Makefile.am): Add test-select-in.sh, test-select-out.sh to TESTS.
20555         Set TESTS_ENVIRONMENT. Add test-select-fd, test-select-stdin to
20556         check_PROGRAMS. Define test_select_fd_LDADD, test_select_stdin_LDADD.
20557
20558 2008-11-06  Alexander V. Lukyanov  <lav@netis.ru>
20559             Bruno Haible  <bruno@clisp.org>
20560
20561         * lib/sys_stat.in.h: Enclose function definitions in extern "C".
20562
20563 2008-10-12  Giuseppe Scrivano  <gscrivano@gnu.org>
20564
20565         * build-aux/pmccabe2html: Added support for C++ source files.
20566
20567 2008-11-05  Ben Pfaff  <blp@gnu.org>
20568
20569         Fix lib/close.c build on Windows.
20570         * modules/close (Files): Add lib/w32sock.h.
20571
20572 2008-11-05  Joel E. Denny  <jdenny@ces.clemson.edu>
20573
20574         Accept Bison's NEWS format.
20575         * build-aux/announce-gen (print_news_deltas): Tweak
20576         $re_prefix.
20577
20578 2008-11-04  Bruno Haible  <bruno@clisp.org>
20579
20580         * modules/random_r (Maintainer): Add glibc.
20581
20582 2008-11-04  Simon Josefsson  <simon@josefsson.org>
20583
20584         * doc/alloca-opt.texi: Change license to GFDLv1.3+, as suggested
20585         by karl@freefriends.org (Karl Berry).
20586         * doc/alloca.texi: Likewise.
20587         * doc/c-ctype.texi: Likewise.
20588         * doc/c-strcase.texi: Likewise.
20589         * doc/c-strcaseeq.texi: Likewise.
20590         * doc/c-strcasestr.texi: Likewise.
20591         * doc/c-strstr.texi: Likewise.
20592         * doc/c-strtod.texi: Likewise.
20593         * doc/c-strtold.texi: Likewise.
20594         * doc/ctime.texi: Likewise.
20595         * doc/error.texi: Likewise.
20596         * doc/fdl.texi: Likewise.
20597         * doc/gcd.texi: Likewise.
20598         * doc/getdate.texi: Likewise.
20599         * doc/gnulib-intro.texi: Likewise.
20600         * doc/gnulib-tool.texi: Likewise.
20601         * doc/gnulib.texi: Likewise.
20602         * doc/inet_ntoa.texi: Likewise.
20603         * doc/maintain.texi: Likewise.
20604         * doc/make-stds.texi: Likewise.
20605         * doc/quote.texi: Likewise.
20606         * doc/regexprops-generic.texi: Likewise.
20607         * doc/standards.texi: Likewise.
20608         * doc/verify.texi: Likewise.
20609         * doc/visibility.texi: Likewise.
20610         * doc/gnulib.texi (GNU Free Documentation License): Include
20611         fdl-1.3.texi instead of fdl.texi.
20612
20613 2008-11-04  Simon Josefsson  <simon@josefsson.org>
20614
20615         * doc/fdl-1.3.texi: New file, from
20616         <http://www.gnu.org/licenses/fdl-1.3.texi>.
20617         * modules/fdl-1.3: Add.
20618         * MODULES.html.sh: Add fdl-1.3.
20619
20620 2008-11-03  Bruno Haible  <bruno@clisp.org>
20621
20622         Make determination of absolute name of header file work with AIX xlc.
20623         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Require
20624         AC_CANONICAL_HOST. On AIX, use "$CPP -C" rather than "$CPP" for
20625         preprocessing.
20626         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
20627         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
20628
20629 2008-11-03  Simon Josefsson  <simon@josefsson.org>
20630
20631         * top/maint.mk (COVERAGE_CCOPTS): Use --coverage instead of
20632         -fprofile-arcs -ftest-coverage.  Suggested by Ludovic Courtès
20633         <ludo@gnu.org>.
20634
20635 2008-11-02  Bruno Haible  <bruno@clisp.org>
20636
20637         Mark 'strpbrk' obsolete.
20638         * modules/strpbrk (Status, Notice): New sections.
20639         * modules/strtok_r (Depends-on): Add strpbrk.
20640
20641 2008-11-02  Bruno Haible  <bruno@clisp.org>
20642
20643         Mark 'strdup' obsolete.
20644         * modules/strdup (Status, Notice): New sections.
20645         * modules/findprog (Depends-on): Add strdup.
20646         * modules/getaddrinfo (Depends-on): Likewise.
20647         * modules/localename (Depends-on): Likewise.
20648         * modules/relocatable-lib (Depends-on): Likewise.
20649         * modules/relocatable-lib-lgpl (Depends-on): Likewise.
20650         * modules/relocatable-prog (Depends-on): Likewise.
20651         * modules/trim (Depends-on): Likewise.
20652         * modules/unictype/gen-ctype (Depends-on): Likewise.
20653         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
20654
20655 2008-11-02  Bruno Haible  <bruno@clisp.org>
20656
20657         Mark 'strcspn' obsolete.
20658         * modules/strcspn (Status, Notice): New sections.
20659
20660 2008-11-02  Bruno Haible  <bruno@clisp.org>
20661
20662         Mark 'rmdir' obsolete.
20663         * modules/rmdir (Status, Notice): New sections.
20664         * modules/clean-temp (Depends-on): Add rmdir.
20665         * modules/openat (Depends-on): Likewise.
20666
20667 2008-11-02  Bruno Haible  <bruno@clisp.org>
20668
20669         Mark 'raise' obsolete.
20670         * modules/raise (Status, Notice): New sections.
20671         (Include): Specify <signal.h>.
20672         * modules/stdio (Depends-on): Add raise.
20673         * modules/write (Depends-on): Likewise.
20674
20675 2008-11-02  Bruno Haible  <bruno@clisp.org>
20676
20677         Mark 'memset' obsolete.
20678         * modules/memset (Status, Notice): New sections.
20679
20680 2008-11-02  Bruno Haible  <bruno@clisp.org>
20681
20682         Mark 'memmove' obsolete.
20683         * modules/memmove (Status, Notice): New sections.
20684         * modules/argp (Depends-on): Add memmove.
20685         * modules/argz (Depends-on): Likewise.
20686         * modules/canonicalize (Depends-on): Likewise.
20687         * modules/canonicalize-lgpl (Depends-on): Likewise.
20688         * modules/fts (Depends-on): Likewise.
20689         * modules/getcwd (Depends-on): Likewise.
20690         * modules/human (Depends-on): Likewise.
20691         * modules/regex (Depends-on): Likewise.
20692         * modules/striconveh (Depends-on): Likewise.
20693         * modules/trim (Depends-on): Likewise.
20694         * modules/unistr/u8-move (Depends-on): Likewise.
20695         * modules/unistr/u16-move (Depends-on): Likewise.
20696         * modules/unistr/u32-move (Depends-on): Likewise.
20697
20698 2008-11-02  Bruno Haible  <bruno@clisp.org>
20699
20700         Mark 'memcpy' obsolete.
20701         * modules/memcpy (Status, Notice): New sections.
20702
20703 2008-11-02  Bruno Haible  <bruno@clisp.org>
20704
20705         Mark 'memcmp' obsolete.
20706         * modules/memcmp (Status, Notice): New sections.
20707         * modules/argmatch (Depends-on): Add memchr.
20708         * modules/backupfile (Depends-on): Likewise.
20709         * modules/c-strcasestr (Depends-on): Likewise.
20710         * modules/crypto/des (Depends-on): Likewise.
20711         * modules/csharpcomp (Depends-on): Likewise.
20712         * modules/fnmatch (Depends-on): Likewise.
20713         * modules/git-merge-changelog (Depends-on): Likewise.
20714         * modules/isnand (Depends-on): Likewise.
20715         * modules/isnand-nolibm (Depends-on): Likewise.
20716         * modules/isnanf (Depends-on): Likewise.
20717         * modules/isnanf-nolibm (Depends-on): Likewise.
20718         * modules/isnanl (Depends-on): Likewise.
20719         * modules/isnanl-nolibm (Depends-on): Likewise.
20720         * modules/mbchar (Depends-on): Likewise.
20721         * modules/memcoll (Depends-on): Likewise.
20722         * modules/quotearg (Depends-on): Likewise.
20723         * modules/regex (Depends-on): Likewise.
20724         * modules/relocatable-prog (Depends-on): Likewise.
20725         * modules/same (Depends-on): Likewise.
20726         * modules/signbit (Depends-on): Likewise.
20727         * modules/strcasestr-simple (Depends-on): Likewise.
20728         * modules/unictype/gen-ctype (Depends-on): Likewise.
20729         * modules/unilbrk/gen-lbrk (Depends-on): Likewise.
20730         * modules/uniname/uniname (Depends-on): Likewise.
20731         * modules/unistr/u8-cmp (Depends-on): Likewise.
20732
20733 2008-11-02  Bruno Haible  <bruno@clisp.org>
20734
20735         Mark 'memchr' obsolete.
20736         * modules/memchr (Status, Notice): New sections.
20737         * modules/argp (Depends-on): Add memchr.
20738         * modules/base64 (Depends-on): Likewise.
20739         * modules/c-strcasestr (Depends-on): Likewise.
20740         * modules/chdir-long (Depends-on): Likewise.
20741         * modules/fnmatch (Depends-on): Likewise.
20742         * modules/getsubopt (Depends-on): Likewise.
20743         * modules/git-merge-changelog (Depends-on): Likewise.
20744         * modules/glob (Depends-on): Likewise.
20745         * modules/strcasestr-simple (Depends-on): Likewise.
20746         * modules/strnlen (Depends-on): Likewise.
20747
20748 2008-11-02  Bruno Haible  <bruno@clisp.org>
20749
20750         Mark 'atexit' obsolete.
20751         * modules/atexit (Status, Notice): New sections.
20752         * modules/chdir-long (Depends-on): Add atexit.
20753         * modules/wait-process (Depends-on): Likewise.
20754
20755 2008-11-02  Bruno Haible  <bruno@clisp.org>
20756
20757         * gnulib-tool: New option --with-obsolete.
20758         (func_usage): Document it.
20759         (func_modules_transitive_closure): Drop obsolete dependencies if
20760         incobsolete is not true.
20761         (func_import): Read and save the incobsolete variable to the cache.
20762
20763 2008-11-02  Bruno Haible  <bruno@clisp.org>
20764
20765         * modules/TEMPLATE-EXTENDED: New field 'Status'.
20766         * gnulib-tool: New option --extract-status.
20767         (func_usage): Document it.
20768         (sed_extract_prog): Recognize it.
20769         (func_get_status): New function.
20770
20771 2008-10-30  Simon Josefsson  <simon@josefsson.org>
20772
20773         * modules/sockets (License): Change from LGPL to LGPLv2+.
20774
20775 2008-10-28  Simon Josefsson  <simon@josefsson.org>
20776
20777         * top/maint.mk: Add coverage rules, inspired by scripts in gnupdf.
20778
20779 2008-10-28  Simon Josefsson  <simon@josefsson.org>
20780
20781         * MODULES.html.sh (Support for systems lacking POSIX:2001):
20782         Mention times and sys_times.
20783         * modules/sys_times, modules/sys_times-tests: New modules.
20784         * modules/times, modules/times-tests: Likewise
20785         * m4/sys_times_h.m4: New file.
20786         * lib/sys_times.in.h: Likewise
20787         * lib/times.c: Likewise.
20788         * tests/test-sys_times.c: Likewise.
20789         * tests/test-times.c: Likewise.
20790         * doc/posix-headers/sys_times.texi: Update.
20791         * doc/posix-functions/times.texi: Update.
20792
20793 2008-10-28  Jim Meyering  <meyering@redhat.com>
20794
20795         * modules/tempname (Depends-on): Add lstat.
20796
20797         * modules/lstat (License): Relicense: LGPL -> LGPLv2+.
20798
20799 2008-10-28  Simon Josefsson  <simon@josefsson.org>
20800
20801         * gnulib-tool (func_emit_tests_Makefile_am): Revert last commit.
20802         * modules/argp-tests (test_argp_LDADD): Set EXEEXT here instead,
20803         using idiom used elsewhere in gnulib.
20804
20805 2008-10-27  Jim Meyering  <meyering@redhat.com>
20806
20807         * modules/gethostname (License): Relicense: LGPL -> LGPLv2+.
20808
20809 2008-10-27  Simon Josefsson  <simon@josefsson.org>
20810
20811         * gnulib-tool (func_emit_tests_Makefile_am): Set EXEEXT in
20812         TESTS_ENVIRONMENT, for shell scripts that needs to call built
20813         programs.
20814         * tests/test-argp-2.sh: Use $EXEEXT when needed.
20815
20816 2008-10-27  Simon Josefsson  <simon@josefsson.org>
20817
20818         * lib/sys_stat.in.h (lstat): Fix declaration for mingw.
20819
20820 2008-10-27  Bruno Haible  <bruno@clisp.org>
20821
20822         * tests/test-lstat.c: Include <stdio.h>.
20823
20824 2008-10-27  Simon Josefsson  <simon@josefsson.org>
20825
20826         * modules/lstat-tests: New module.
20827         * tests/test-lstat.c: New file.
20828
20829 2008-10-26  Jim Meyering  <meyering@redhat.com>
20830
20831         * lib/mkdir.c (rpl_mkdir) [_WIN32...]: Mark mode as an unused parameter.
20832
20833 2008-10-26  Simon Josefsson  <simon@josefsson.org>
20834             Bruno Haible  <bruno@clisp.org>
20835
20836         Fix a clash between the type DATADIR on Windows and the macro DATADIR.
20837         * modules/configmake (Include): Add a note that the include must come
20838         after all system headers.
20839         * lib/javaversion.c: Include configmake.h after all other includes.
20840
20841 2008-10-26  Bruno Haible  <bruno@clisp.org>
20842
20843         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set default of
20844         HAVE_STRUCT_RANDOM_DATA to 1.
20845         (gl_STDLIB_H): Simplify.
20846
20847 2008-10-26  Simon Josefsson  <simon@josefsson.org>
20848
20849         * m4/stdlib_h.m4: Check for struct random_data.  Initialize and
20850         substitute HAVE_STRUCT_RANDOM_DATA.
20851         * lib/stdlib.in.h [!HAVE_STRUCT_RANDOM_DATA]: Provide struct
20852         random_data.
20853         * modules/stdlib (Makefile.am): Substitute
20854         HAVE_STRUCT_RANDOM_DATA.
20855
20856 2008-10-26  Simon Josefsson  <simon@josefsson.org>
20857
20858         * doc/gnulib.texi (@copying): Use GFDLv1.2+.
20859         * doc/gnulib-intro.texi (Copyright): Likewise.
20860
20861 2008-10-26  Simon Josefsson  <simon@josefsson.org>
20862
20863         * doc/gnulib.texi (Header files): C++ fixes, based on Bruno's
20864         findings.
20865
20866 2008-10-25  Ben Pfaff  <blp@cs.stanford.edu>
20867             Bruno Haible  <bruno@clisp.org>
20868
20869         * lib/unistd.in.h: Include <winsock2.h>.
20870         (socket, connect,accept, bind, getpeername, getsockname, getsockopt,
20871         listen, recv, send, recvfrom, sendto, setsockopt, shutdown, select):
20872         Provide dummy declarations.
20873         (gethostname): Override.
20874         * lib/sys_socket.in.h (gethostname): Provide dummy declaration.
20875         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Invoke
20876         gl_PREREQ_SYS_H_WINSOCK2.
20877         * modules/gethostname (Files): Add m4/sys_socket_h.m4.
20878         * doc/posix-functions/gethostname.texi: More details.
20879
20880 2008-10-25  Bruno Haible  <bruno@clisp.org>
20881
20882         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
20883         gl_UNISTD_H_DEFAULTS, gl_SYS_IOCTL_H_DEFAULTS only if they exist.
20884         * modules/sys_socket (Files): Remove m4/unistd_h.m4, m4/sys_ioctl_h.m4.
20885
20886         * lib/sys_socket.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); Move macro from
20887         here ...
20888         * lib/unistd.in.h (HAVE__GL_CLOSE_FD_MAYBE_SOCKET); ... to here.
20889         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Remove invocation of
20890         gl_UNISTD_H_DEFAULTS.
20891
20892 2008-10-25  Eric Blake  <ebb9@byu.net>
20893
20894         signbit: avoid spurious compiler failure
20895         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Move non-constant
20896         declarations inside function.
20897
20898 2008-10-24  Simon Josefsson  <simon@josefsson.org>
20899             Bruno Haible  <bruno@clisp.org>
20900
20901         * lib/stdlib.in.h (@GNULIB_RANDOM_R@): Include stdint.h.
20902         * modules/random_r (Depends-on): Add stdint.
20903
20904 2008-10-24  Bruno Haible  <bruno@clisp.org>
20905
20906         * modules/intprops (License): Change to LGPLv2+, with approval by Paul
20907         Eggert.
20908         * modules/strerror (License): Likewise.
20909
20910 2008-10-24  Jim Meyering  <meyering@redhat.com>
20911
20912         sys_socket: fix typo that inhibited expansion of @GNULIB_SEND@
20913         * modules/sys_socket (Depends-on) [Depends-on]: Fix typo.
20914
20915 2008-10-24  Eric Blake  <ebb9@byu.net>
20916
20917         getgroups: fix compilation when getgroups is available
20918         * lib/getgroups.c (includes): Include <unistd.h> for getgroups,
20919         but with <config.h> override of getgroups disabled.
20920
20921 2008-10-24  Simon Josefsson  <simon@josefsson.org>
20922
20923         * doc/gnulib.texi (Header files): Add note about C++ problems.
20924         Explained by Bruno Haible <bruno@clisp.org>.
20925
20926 2008-10-23  Bruno Haible  <bruno@clisp.org>
20927
20928         Define a dummy SA_NODEFER macro on Interix.
20929         * lib/signal.in.h (SA_NODEFER): Define fallback.
20930         Reported by Aleksey Cheusov <cheusov@tut.by> via
20931         Thomas Klausner <wiz@netbsd.org> and Eric Blake.
20932
20933 2008-10-23  Bruno Haible  <bruno@clisp.org>
20934
20935         * modules/freadahead (License): Change to LGPLv2+.
20936         Suggested by Simon Josefsson.
20937
20938 2008-10-23  Jim Meyering  <meyering@redhat.com>
20939
20940         random_r: new module
20941         * modules/random_r: New file.
20942         * m4/random_r.m4: New file.
20943         * lib/random_r.c: New file, from glibc.
20944         * modules/random_r-tests: New file.
20945         * tests/test-random_r.c: New file.
20946         * lib/stdlib.in.h (srandom_r, initstate_r, setstate_r, random_r):
20947          Declare.
20948         (RAND_MAX): Define.
20949         * m4/stdlib_h.m4: Define and AC_SUBST GNULIB_RANDOM_R and HAVE_RANDOM_R.
20950         * modules/stdlib: Substitute them, too.
20951         * MODULES.html.sh (Extra functions based on POSIX:2001) [Misc]: Add it.
20952         * doc/glibc-functions/initstate_r.texi: Mention the new module.
20953         * doc/glibc-functions/random_r.texi: Likewise.
20954         * doc/glibc-functions/setstate_r.texi: Likewise.
20955         * doc/glibc-functions/srandom_r.texi: Likewise.
20956         * config/srclist.txt: Mention it.
20957
20958 2008-10-23  David Lutterkort  <lutter@redhat.com>
20959
20960         * modules/selinux-h: Search for LIB_SELINUX and mark it as a
20961         link requirement
20962
20963 2008-10-23  Jim Meyering  <meyering@redhat.com>
20964
20965         selinux-h: mark parameters of stub functions as intentionally unused
20966         * lib/se-selinux.in.h: Mark parameters as _UNUSED_PARAMETER_.
20967         * lib/se-context.in.h: Likewise.
20968
20969 2008-10-22  Simon Josefsson  <simon@josefsson.org>
20970
20971         * lib/sys_socket.in.h (FD_ISSET): Fix warnings under mingw.
20972
20973 2008-10-22  Simon Josefsson  <simon@josefsson.org>
20974
20975         * m4/getgroups.m4: Avoid invoking test with wrong parameters.
20976
20977 2008-10-22  Eric Blake  <ebb9@byu.net>
20978
20979         glthread/thread: avoid compiler warning
20980         * lib/glthread/thread.c (gl_thread_exit_func) [USE_WIN32_THREADS]:
20981         Add unreachable abort to silence compiler.
20982
20983 2008-10-22  Eric Blake  <ebb9@byu.net>
20984
20985         netdb: also supply struct addrinfo for cygwin 1.5.x
20986         * m4/netdb_h.m4 (gl_HEADER_NETDB): Check for incomplete header on
20987         older cygwin.
20988         * lib/netdb.in.h [!HAVE_STRUCT_ADDRINFO]: Also supply contents for
20989         cygwin.
20990         * doc/posix-headers/netdb.texi (netdb.h): Document this.
20991
20992 2008-10-22  Bruno Haible  <bruno@clisp.org>
20993
20994         * users.txt: Update entry about pspp.
20995
20996 2008-10-21  Bruno Haible  <bruno@clisp.org>
20997
20998         Simplification.
20999         * lib/sys_socket.in.h (_gl_close_fd_maybe_socket): Remove declaration.
21000         * lib/close.c (_gl_close_fd_maybe_socket): Make static.
21001
21002         Simplification.
21003         * lib/ioctl.c (ioctl): Don't undefine.
21004         * lib/socket.c (socket): Don't undefine.
21005
21006         Remove unused module indicator macros.
21007         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR): Don't define
21008         GNULIB_$1 as a C macro.
21009
21010         * doc/posix-functions/close.texi: Undo last change.
21011         * doc/posix-functions/ioctl.texi: Merge the two paragraphs about
21012         Windows platforms.
21013
21014 2008-10-21  Bruno Haible  <bruno@clisp.org>
21015
21016         Add gethostname() declaration to <unistd.h>.
21017         * lib/unistd.in.h (gethostname): New declaration.
21018         * lib/gethostname.c: Include <unistd.h>.
21019         * m4/gethostname.m4 (gl_FUNC_GETHOSTNAME): Require
21020         gl_UNISTD_H_DEFAULTS. Set HAVE_GETHOSTNAME.
21021         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETHOSTNAME
21022         and HAVE_GETHOSTNAME.
21023         * modules/gethostname (Depends-on): Add unistd.
21024         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
21025         (Include): Specify <unistd.h>.
21026         * modules/unistd (Makefile.am): Substitute GNULIB_GETHOSTNAME and
21027         HAVE_GETHOSTNAME.
21028         * tests/test-gethostname.c: Include <unistd.h> first.
21029
21030 2008-10-21  Bruno Haible  <bruno@clisp.org>
21031
21032         * modules/poll-tests (Depends-on): Add sys_ioctl, ioctl.
21033         * modules/select-tests (Depends-on): Likewise.
21034         Reported by Simon Josefsson.
21035
21036 2008-10-21  Simon Josefsson  <simon@josefsson.org>
21037
21038         * lib/close.c: Add _gl_close_fd_maybe_socket from winsock.c.
21039         * lib/accept.c: New file, based on winsock.c.
21040         * lib/bind.c: New file, based on winsock.c.
21041         * lib/connect.c: New file, based on winsock.c.
21042         * lib/getpeername.c: New file, based on winsock.c.
21043         * lib/getsockname.c: New file, based on winsock.c.
21044         * lib/getsockopt.c: New file, based on winsock.c.
21045         * lib/ioctl.c: New file, based on winsock.c.
21046         * lib/listen.c: New file, based on winsock.c.
21047         * lib/recv.c: New file, based on winsock.c.
21048         * lib/recvfrom.c: New file, based on winsock.c.
21049         * lib/send.c: New file, based on winsock.c.
21050         * lib/sendto.c: New file, based on winsock.c.
21051         * lib/setsockopt.c: New file, based on winsock.c.
21052         * lib/shutdown.c: New file, based on winsock.c.
21053         * lib/socket.c: New file, based on winsock.c.
21054         * lib/w32sock.h: New file, based on winsock.c.
21055         * lib/winsock.c: Remove file.
21056         * modules/accept: Likewise.
21057         * modules/bind: Likewise.
21058         * modules/connect: Likewise.
21059         * modules/getpeername: Likewise.
21060         * modules/getsockname: Likewise.
21061         * modules/getsockopt: Likewise.
21062         * modules/ioctl: Likewise.
21063         * modules/listen: Likewise.
21064         * modules/recv: Likewise.
21065         * modules/recvfrom: Likewise.
21066         * modules/send: Likewise.
21067         * modules/sendto: Likewise.
21068         * modules/setsockopt: Likewise.
21069         * modules/shutdown: Likewise.
21070         * modules/socket: Use socket.c instead of winsock.c.
21071         * modules/sys_socket: Remove (unneeded?) dependency on winsock.c.
21072         * doc/posix-functions/accept.texi: Doc fix.
21073         * doc/posix-functions/bind.texi: Doc fix.
21074         * doc/posix-functions/close.texi: Doc fix.
21075         * doc/posix-functions/connect.texi: Doc fix.
21076         * doc/posix-functions/getpeername.texi: Doc fix.
21077         * doc/posix-functions/getsockname.texi: Doc fix.
21078         * doc/posix-functions/getsockopt.texi: Doc fix.
21079         * doc/posix-functions/ioctl.texi: Doc fix.
21080         * doc/posix-functions/listen.texi: Doc fix.
21081         * doc/posix-functions/recv.texi: Doc fix.
21082         * doc/posix-functions/recvfrom.texi: Doc fix.
21083         * doc/posix-functions/send.texi: Doc fix.
21084         * doc/posix-functions/sendto.texi: Doc fix.
21085         * doc/posix-functions/setsockopt.texi: Doc fix.
21086         * doc/posix-functions/shutdown.texi: Doc fix.
21087         * doc/posix-functions/socket.texi: Doc fix.
21088
21089 2008-10-20  Bruno Haible  <bruno@clisp.org>
21090
21091         Take into account the role of SIGABRT_COMPAT on Windows 2008.
21092         * lib/sigprocmask.c (SIGABRT_COMPAT, SIGABRT_COMPAT_MASK): New macros.
21093         (sigismember, sigaddset, sigdelset, sigfillset, rpl_signal): Handle it
21094         as an alias for SIGABRT.
21095         * lib/sigaction.c (SIGABRT_COMPAT): New macro.
21096         (sigaction): Map it to SIGABRT.
21097         Reported by Ramiro Polla <ramiro.polla@gmail.com> via Eric Blake.
21098
21099 2008-10-20  Bruno Haible  <bruno@clisp.org>
21100
21101         * lib/fts.c: Don't include lstat.h.
21102         * lib/openat.c: Include <sys/stat.h> instead of lstat.h.
21103
21104         Move the lstat() declaration to <sys/stat.h>.
21105         * lib/lstat.h: Remove file.
21106         * lib/sys_stat.in.h: Add special invocation convention.
21107         (lstat): New declaration.
21108         * lib/lstat.c (orig_lstat): New function.
21109         (rpl_lstat): Use orig_lstat instead of lstat.
21110         * m4/lstat.m4 (gl_FUNC_LSTAT): Require gl_SYS_STAT_H_DEFAULTS and
21111         AC_C_INLINE. Set REPLACE_LSTAT.
21112         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LSTAT
21113         and REPLACE_LSTAT.
21114         * modules/lstat (Files): Remove lib/lstat.h.
21115         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
21116         (Include): Specify <sys/stat.h> instead of lstat.h.
21117         * modules/sys_stat (Makefile.am): Substitute GNULIB_LSTAT and
21118         REPLACE_LSTAT.
21119         * NEWS: Mention the change.
21120
21121 2008-10-20  Bruno Haible  <bruno@clisp.org>
21122
21123         * modules/posix_spawn-tests: New file.
21124         * tests/test-posix_spawn3.c: New file.
21125
21126 2008-10-20  Bruno Haible  <bruno@clisp.org>
21127
21128         * modules/posix_spawnp-tests (Depends-on): Add sys_wait.
21129         * tests/test-posix_spawn1.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
21130         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Remove fallback definitions.
21131         * tests/test-posix_spawn2.c (WTERMSIG, WCOREDUMP, WEXITSTATUS,
21132         WIFSIGNALED, WIFEXITED, WIFSTOPPED): Likewise.
21133
21134 2008-10-20  Bruno Haible  <bruno@clisp.org>
21135
21136         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Test against another bug
21137         of posix_spawn on AIX 5.3.
21138
21139 2008-10-20  Bruno Haible  <bruno@clisp.org>
21140
21141         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Make the check on MacOS X.
21142
21143 2008-10-20  Bruno Haible  <bruno@clisp.org>
21144
21145         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Use AC_LANG_SOURCE instead
21146         of AC_LANG_PROGRAM.
21147
21148 2008-10-20  Simon Josefsson  <simon@josefsson.org>
21149
21150         * lib/netdb.in.h: Don't define GNU specific constants until they
21151         are supported or needed.  Reported by Bruno Haible
21152         <bruno@clisp.org>.
21153
21154 2008-10-20  Simon Josefsson  <simon@josefsson.org>
21155
21156         * lib/canon-host.c: Include netdb.h instead of getaddrinfo.h.
21157
21158 2008-10-20  Simon Josefsson  <simon@josefsson.org>
21159
21160         * lib/getaddrinfo.h: Remove file.
21161         * modules/getaddrinfo: Reflect move from getaddrinfo.h to netdb.h.
21162         * m4/getaddrinfo.m4: Call gl_HEADER_NETDB.  Don't check for netdb.h.
21163         * lib/netdb.in.h: Add declarations from getaddrinfo.h.
21164         * m4/netdb_h.m4: Initialize GNULIB_GETADDRINFO to 0.
21165         * modules/netdb: Substitute GNULIB_GETADDRINFO.
21166         * lib/getaddrinfo.c: Include netdb.h instead of getaddrinfo.h.
21167         * tests/test-getaddrinfo.c: Likewise.
21168         * lib/gai_strerror.c: Likewise.  Also drop HAVE_NETDB_H check.
21169         * NEWS: Mention change.
21170
21171 2008-10-19  Bruno Haible  <bruno@clisp.org>
21172
21173         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): Remove unneeded code.
21174
21175 2008-10-19  Bruno Haible  <bruno@clisp.org>
21176
21177         * lib/wait-process.c: Include simply <sys/wait.h>.
21178         (waitpid, WTERMSIG, WCOREDUMP, WEXITSTATUS, WIFSIGNALED, WIFEXITED,
21179         WIFSTOPPED): Remove fallback definitions.
21180         * modules/wait-process (Depends-on): Add sys_wait.
21181
21182         New module 'sys_wait'.
21183         * modules/sys_wait: New file.
21184         * lib/sys_wait.in.h: New file, partially copied from
21185         lib/wait-process.c.
21186         * m4/sys_wait_h.m4: New file.
21187         * doc/posix-headers/sys_wait.texi: Mention the new module.
21188
21189 2008-10-19  Bruno Haible  <bruno@clisp.org>
21190
21191         * m4/wait-process.m4 (gl_WAIT_PROCESS): Remove test for unistd.h.
21192
21193 2008-10-19  Bruno Haible  <bruno@clisp.org>
21194
21195         Assume that waitpid() fills an 'int' status, not a 'union wait'.
21196         * lib/wait-process.c (WAIT_T): Remove type.
21197         (WTERMSIG, WCOREDUMP, WEXITSTATUS): Define fallbacks using bit masks.
21198         (wait_subprocess): Update.
21199
21200 2008-10-19  Bruno Haible  <bruno@clisp.org>
21201
21202         New module 'atoll'.
21203         * modules/atoll: New file.
21204         * lib/stdlib.in.h (atoll): New declaration.
21205         * lib/atoll.c: New file, from glibc with modifications.
21206         * m4/atoll.m4: New file.
21207         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ATOLL,
21208         HAVE_ATOLL.
21209         * modules/stdlib (Makefile.am): Substitute GNULIB_ATOLL, HAVE_ATOLL.
21210         * doc/posix-functions/atoll.texi: Mention the new module.
21211
21212 2008-10-19  Bruno Haible  <bruno@clisp.org>
21213
21214         Add strtoull() declaration to <stdlib.h>.
21215         * lib/stdlib.in.h (strtoull): New declaration.
21216         * m4/strtoull.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
21217         Set HAVE_STRTOULL.
21218         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOULL,
21219         HAVE_STRTOULL.
21220         * modules/strtoull (Depends-on): Add stdlib.
21221         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
21222         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOULL,
21223         HAVE_STRTOULL.
21224
21225 2008-10-19  Bruno Haible  <bruno@clisp.org>
21226
21227         Add strtoll() declaration to <stdlib.h>.
21228         * lib/stdlib.in.h (strtoll): New declaration.
21229         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Require gl_STDLIB_H_DEFAULTS.
21230         Set HAVE_STRTOLL.
21231         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLL,
21232         HAVE_STRTOLL.
21233         * modules/strtoll (Depends-on): Add stdlib.
21234         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
21235         * modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLL, HAVE_STRTOLL.
21236
21237 2008-10-19  Bruno Haible  <bruno@clisp.org>
21238
21239         * modules/bcopy (Depends-on): Add strings.
21240         (Include): Specify <strings.h>.
21241
21242 2008-10-19  Bruno Haible  <bruno@clisp.org>
21243
21244         * doc/posix-functions/atexit.texi: Update doc regarding mingw.
21245
21246 2008-10-19  Bruno Haible  <bruno@clisp.org>
21247
21248         * lib/openat-die.c (openat_save_fail, openat_restore_fail): Rename
21249         the parameter from 'errno' to 'errnum'. Fixes a compilation error on
21250         mingw.
21251
21252 2008-10-19  Bruno Haible  <bruno@clisp.org>
21253
21254         * lib/atanl.c: Don't include isnanl.h.
21255         * lib/cosl.c: Likewise.
21256         * lib/ldexpl.c: Likewise.
21257         * lib/logl.c: Likewise.
21258         * lib/sinl.c: Likewise.
21259         * lib/sqrtl.c: Likewise.
21260         * lib/tanl.c: Likewise.
21261
21262         Move the isnanf(), isnand(), isnanl() declarations to <math.h>.
21263         * lib/isnanf.h: Remove file.
21264         * lib/isnand.h: Remove file.
21265         * lib/isnanl.h: Remove file.
21266         * lib/math.in.h: Include the contents of lib/isnanf.h, lib/isnand.h,
21267         lib/isnanl.h. Use HAVE_ISNANF, HAVE_ISNAND, HAVE_ISNANL as substituted
21268         macros.
21269         * m4/isnanf.m4 (gl_FUNC_ISNANF): Require gl_MATH_H_DEFAULTS. Set
21270         HAVE_ISNANF, don't define it as a C macro.
21271         * m4/isnand.m4 (gl_FUNC_ISNAND): Require gl_MATH_H_DEFAULTS. Set
21272         HAVE_ISNAND, don't define it as a C macro.
21273         * m4/isnanl.m4 (gl_FUNC_ISNANL): Require gl_MATH_H_DEFAULTS. Set
21274         HAVE_ISNANL, don't define it as a C macro.
21275         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_ISNAN[FDL] and
21276         HAVE_ISNAN[FDL].
21277         * modules/isnanf (Files): Remove lib/isnanf.h.
21278         (Depends-on): Add math.
21279         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
21280         (Include): Specify <math.h> instead of isnanf.h.
21281         * modules/isnand (Files): Remove lib/isnand.h.
21282         (Depends-on): Add math.
21283         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
21284         (Include): Specify <math.h> instead of isnand.h.
21285         * modules/isnanl (Files): Remove lib/isnanl.h.
21286         (Depends-on): Add math.
21287         (configure.ac): Invoke gl_MATH_MODULE_INDICATOR.
21288         (Include): Specify <math.h> instead of isnanl.h.
21289         * modules/math (Makefile.am): Substitute GNULIB_ISNAN[FDL] and
21290         HAVE_ISNAN[FDL].
21291         * tests/test-isnanf.c: Include <math.h> instead of isnanf.h.
21292         * tests/test-isnand.c: Include <math.h> instead of isnand.h.
21293         * tests/test-isnanl.c: Include <math.h> instead of isnanl.h.
21294         * NEWS: Mention the change.
21295
21296 2008-10-18  Bruno Haible  <bruno@clisp.org>
21297
21298         Add getusershell(), setusershell(), endusershell() declarations to
21299         <unistd.h>.
21300         * lib/unistd.in.h (getusershell, setusershell, endusershell): New
21301         declarations.
21302         * lib/getusershell.c: Include unistd.h.
21303         * m4/getusershell.m4 (gl_FUNC_GETUSERSHELL): Require
21304         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
21305         HAVE_GETUSERSHELL.
21306         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETUSERSHELL
21307         and HAVE_GETUSERSHELL.
21308         * modules/getusershell (Depends-on): Add unistd, extensions.
21309         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
21310         (Include): Specify <unistd.h>.
21311         * modules/unistd (Makefile.am): Substitute GNULIB_GETUSERSHELL and
21312         HAVE_GETUSERSHELL.
21313
21314 2008-10-18  Bruno Haible  <bruno@clisp.org>
21315
21316         Add a getloadavg() declaration to <stdlib.h>.
21317         * lib/stdlib.in.h; Include <sys/loadavg.h> when needed for the
21318         getloadavg declaration.
21319         (getloadavg): New declaration.
21320         * lib/getloadavg.c: Include <stdlib.h> first.
21321         * m4/getloadavg.m4 (gl_GETLOADAVG): Require gl_STDLIB_H_DEFAULTS and
21322         AC_USE_SYSTEM_EXTENSIONS. Test whether sys/loadavg.h exists. Set
21323         HAVE_SYS_LOADAVG_H and HAVE_DECL_GETLOADAVG.
21324         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_GETLOADAVG,
21325         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
21326         * modules/getloadavg (Depends-on): Add stdlib, extensions.
21327         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
21328         (Include): Specify <stdlib.h>.
21329         * modules/stdlib (Makefile.am): Substitute GNULIB_GETLOADAVG,
21330         HAVE_SYS_LOADAVG_H, HAVE_DECL_GETLOADAVG.
21331
21332 2008-10-18  Bruno Haible  <bruno@clisp.org>
21333
21334         * lib/dirchownmod.c: Don't include lchmod.h.
21335
21336         Move the lchmod() declaration to <sys/stat.h>.
21337         * lib/lchmod.h: Remove file.
21338         * lib/sys_stat.in.h: Add placeholder for GL_LINK_WARNING.
21339         (lchmod): New declaration, moved here from lib/lchown.h.
21340         * m4/lchmod.m4 (gl_FUNC_LCHMOD): Require gl_SYS_STAT_H_DEFAULTS and
21341         AC_USE_SYSTEM_EXTENSIONS. Set HAVE_LCHMOD.
21342         * m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Initialize GNULIB_LCHMOD
21343         and HAVE_LCHMOD.
21344         * modules/lchmod (Files): Remove lib/lchmod.h.
21345         (Depends-on): Add sys_stat, extensions.
21346         (configure.ac): Invoke gl_SYS_STAT_MODULE_INDICATOR.
21347         (Include): Specify <sys/stat.h> instead of lchmod.h.
21348         * modules/sys_stat (Depends-on): Add link-warning.
21349         (Makefile.am): Substitute GNULIB_LCHMOD, HAVE_LCHMOD, and the
21350         definition of GL_LINK_WARNING.
21351         * NEWS: Mention the change.
21352
21353 2008-10-18  Bruno Haible  <bruno@clisp.org>
21354
21355         * lib/fchdir.c: Don't include dirfd.h.
21356         * lib/fts.c: Likewise.
21357         * lib/getcwd.c: Likewise.
21358         * lib/glob.c: Likewise.
21359
21360         Move the dirfd() declaration to <dirent.h>.
21361         * lib/dirfd.h: Remove file.
21362         * lib/dirent.in.h: Add placeholder for GL_LINK_WARNING.
21363         (dirfd): New declaration.
21364         * lib/dirfd.c: Include <dirent.h> instead of dirfd.h.
21365         * m4/dirfd.m4 (gl_FUNC_DIRFD): Require gl_DIRENT_H_DEFAULTS and
21366         AC_USE_SYSTEM_EXTENSIONS. Invoke gl_REPLACE_DIRENT_H. Set
21367         HAVE_DECL_DIRFD.
21368         * m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Initialize GNULIB_DIRFD and
21369         HAVE_DECL_DIRFD.
21370         * modules/dirfd (Files): Remove lib/dirfd.h.
21371         (Depends-on): Add dirent, extensions.
21372         (configure.ac): Invoke gl_DIRENT_MODULE_INDICATOR.
21373         (Include): Specify <dirent.h> instead of dirfd.h.
21374         * modules/dirent (Depends-on): Add link-warning.
21375         (Makefile.am): Substitute GNULIB_DIRFD, HAVE_DECL_DIRFD, and
21376         definition of GL_LINK_WARNING.
21377         * NEWS: Mention the change.
21378
21379 2008-10-18  Bruno Haible  <bruno@clisp.org>
21380
21381         Move the euidaccess() declaration to <unistd.h>.
21382         * lib/euidaccess.h: Remove file.
21383         * lib/unistd.in.h (euidaccess): New declaration.
21384         * lib/euidaccess.c: Don't include euidaccess.h.
21385         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Require gl_UNISTD_H_DEFAULTS.
21386         Don't check whether euidaccess is declared. Set HAVE_EUIDACCESS.
21387         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_EUIDACCESS
21388         and HAVE_EUIDACCESS.
21389         * modules/euidaccess (Files): Remove lib/euidaccess.h.
21390         (Depends-on): Add unistd.
21391         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
21392         (Include): Specify <unistd.h> instead of euidaccess.h.
21393         * modules/unistd (Makefile.am): Substitute GNULIB_EUIDACCESS and
21394         HAVE_EUIDACCESS.
21395         * NEWS: Mention the change.
21396
21397 2008-10-18  Bruno Haible  <bruno@clisp.org>
21398
21399         * lib/xgetdomainname.c: Include <unistd.h> instead of getdomainname.h.
21400
21401         Move the getdomainname() declaration to <unistd.h>.
21402         * lib/getdomainname.h: Remove file.
21403         * lib/unistd.in.h (getdomainname): New declaration.
21404         * lib/getdomainname.c: Include <unistd.h> instead of getdomainname.h.
21405         * m4/getdomainname.m4 (gl_FUNC_GETDOMAINNAME): Require
21406         gl_UNISTD_H_DEFAULTS and AC_USE_SYSTEM_EXTENSIONS. Set
21407         HAVE_GETDOMAINNAME.
21408         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
21409         GNULIB_GETDOMAINNAME and HAVE_GETDOMAINNAME.
21410         * modules/getdomainname (Files): Remove lib/getdomainname.h.
21411         (Depends-on): Add unistd, extensions.
21412         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
21413         (Includes): Specify <unistd.h> instead of getdomainname.h.
21414         * modules/unistd (Makefile.am): Substitute GNULIB_GETDOMAINNAME and
21415         HAVE_GETDOMAINNAME.
21416         * NEWS: Mention the change.
21417
21418 2008-10-18  Bruno Haible  <bruno@clisp.org>
21419
21420         * modules/dirent: New file.
21421         * m4/dirent_h.m4: New file.
21422         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_DIRENT_H_DEFAULTS.
21423         Invoke gl_REPLACE_DIRENT_H. Don't assign DIRENT_H directly.
21424         * modules/fchdir (Files): Remove lib/dirent.in.h.
21425         (Depends-on): Add dirent.
21426         (Makefile.am): Move rules to modules/dirent.
21427         * doc/posix-headers/dirent.texi: Mention the new module.
21428
21429 2008-10-18  Bruno Haible  <bruno@clisp.org>
21430
21431         Avoid -Wunused-parameter warnings in public gnulib header files.
21432         * m4/gnulib-common.m4 (gl_COMMON_BODY): Define _UNUSED_PARAMETER_ as a
21433         macro.
21434         * lib/unistr.h (u32_mbtouc_unsafe, u32_mbtouc): Use it.
21435
21436 2008-10-18  Bruno Haible  <bruno@clisp.org>
21437
21438         * doc/glibc-functions/dirfd.texi: Mention the module 'dirfd'.
21439         * doc/glibc-functions/error.texi: Mention the module 'error'.
21440         * doc/glibc-functions/euidaccess.texi: Mention the module 'euidaccess'.
21441         * doc/glibc-functions/getdomainname.texi: Mention the module
21442         'getdomainname'.
21443         * doc/glibc-functions/getloadavg.texi: Mention the module 'getloadavg'.
21444         * doc/glibc-functions/getpagesize.texi: Mention the module
21445         'getpagesize'.
21446         * doc/glibc-functions/getusershell.texi: Mention the module
21447         'getusershell'.
21448         * doc/glibc-functions/isnanl.texi: Mention the module 'isnanl'.
21449         * doc/glibc-functions/lchmod.texi: Mention the module 'lchmod'.
21450         * doc/glibc-functions/mempcpy.texi: Mention the module 'mempcpy'.
21451         * doc/glibc-functions/memrchr.texi: Mention the module 'memrchr'.
21452         * doc/glibc-functions/mkdtemp.texi: Mention the module 'mkdtemp'.
21453         * doc/glibc-functions/rpmatch.texi: Mention the module 'rpmatch'.
21454         * doc/glibc-functions/stpcpy.texi: Mention the module 'stpcpy'.
21455         * doc/glibc-functions/stpncpy.texi: Mention the module 'stpncpy'.
21456         * doc/glibc-functions/strchrnul.texi: Mention the module 'strchrnul'.
21457         * doc/glibc-functions/strndup.texi: Mention the module 'strndup'.
21458         * doc/glibc-functions/strnlen.texi: Mention the module 'strnlen'.
21459         * doc/glibc-functions/strsep.texi: Mention the module 'strsep'.
21460         * doc/glibc-functions/timegm.texi: Mention the module 'timegm'.
21461         * doc/glibc-functions/vasprintf.texi: Mention the module 'vasprintf'.
21462
21463 2008-10-17  Bruno Haible  <bruno@clisp.org>
21464
21465         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): On platforms other than
21466         HP-UX and IRIX, use -0.0L.
21467         * tests/test-ceill.c (minus_zero): Likewise.
21468         * tests/test-floorl.c (minus_zero): Likewise.
21469         * tests/test-frexpl.c (minus_zero): Likewise.
21470         * tests/test-isnan.c (minus_zerol): Likewise.
21471         * tests/test-isnanl.h (minus_zero): Likewise.
21472         * tests/test-ldexpl.c (minus_zero): Likewise.
21473         * tests/test-roundl.c (minus_zero): Likewise.
21474         * tests/test-signbit.c (minus_zerol): Likewise.
21475         * tests/test-snprintf-posix.h (minus_zerol): Likewise.
21476         * tests/test-sprintf-posix.h (minus_zerol): Likewise.
21477         * tests/test-truncl.c (minus_zero): Likewise.
21478         * tests/test-vasnprintf-posix.c (minus_zerol): Likewise.
21479         * tests/test-vasprintf-posix.c (minus_zerol): Likewise.
21480         Reported by Markus Armbruster <armbru@redhat.com> via Jim Meyering
21481         and by Nelson H. F. Beebe <beebe@math.utah.edu> via Eric Blake.
21482
21483 2008-10-17  Bruno Haible  <bruno@clisp.org>
21484
21485         Avoid gcc warnings because of #pragma GCC system_header on older gcc.
21486         * lib/arpa_inet.in.h: Encloses reference to PRAGMA_SYSTEM_HEADER so
21487         that it gets activated only for gcc >= 3.0.
21488         * lib/dirent.in.h: Likewise.
21489         * lib/errno.in.h: Likewise.
21490         * lib/fcntl.in.h: Likewise.
21491         * lib/float.in.h: Likewise.
21492         * lib/iconv.in.h: Likewise.
21493         * lib/inttypes.in.h: Likewise.
21494         * lib/locale.in.h: Likewise.
21495         * lib/math.in.h: Likewise.
21496         * lib/netdb.in.h: Likewise.
21497         * lib/netinet_in.in.h: Likewise.
21498         * lib/search.in.h: Likewise.
21499         * lib/signal.in.h: Likewise.
21500         * lib/spawn.in.h: Likewise.
21501         * lib/stdarg.in.h: Likewise.
21502         * lib/stdint.in.h: Likewise.
21503         * lib/stdio.in.h: Likewise.
21504         * lib/stdlib.in.h: Likewise.
21505         * lib/string.in.h: Likewise.
21506         * lib/strings.in.h: Likewise.
21507         * lib/sys_file.in.h: Likewise.
21508         * lib/sys_ioctl.in.h: Likewise.
21509         * lib/sys_select.in.h: Likewise.
21510         * lib/sys_socket.in.h: Likewise.
21511         * lib/sys_stat.in.h: Likewise.
21512         * lib/sys_time.in.h: Likewise.
21513         * lib/sysexits.in.h: Likewise.
21514         * lib/time.in.h: Likewise.
21515         * lib/unistd.in.h: Likewise.
21516         * lib/wchar.in.h: Likewise.
21517         * lib/wctype.in.h: Likewise.
21518         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
21519
21520 2008-10-17  Jim Meyering  <meyering@redhat.com>
21521
21522         ignore-value: don't depend on inline module
21523         * modules/ignore-value (Depends-on): Remove 'inline'.
21524         (configure.ac): Instead, add AC_REQUIRE([AC_C_INLINE]) here.
21525         Suggestion from Bruno Haible.
21526
21527 2008-10-17  Bruno Haible  <bruno@clisp.org>
21528
21529         New implementation of condition variables for Win32.
21530         * lib/glthread/cond.h (struct gl_waitqueue_link): New type.
21531         (gl_linked_waitqueue_t): New type.
21532         (gl_cond_t): Use it.
21533         * lib/glthread/cond.c (struct gl_waitqueue_element): New type.
21534         (gl_waitqueue_init, gl_waitqueue_add, gl_waitqueue_remove,
21535         gl_waitqueue_notify_first, gl_waitqueue_notify_all): New functions.
21536         (glthread_cond_init_func, glthread_cond_wait_func,
21537         glthread_cond_timedwait_func, glthread_cond_signal_func,
21538         glthread_cond_broadcast_func, glthread_cond_destroy_func):
21539         Reimplemented on the basis of gl_linked_waitqueue_t.
21540         * lib/glthread/lock.h (gl_carray_waitqueue_t): Renamed from
21541         gl_waitqueue_t.
21542         (gl_rwlock_t): Update.
21543         * lib/glthread/lock.c (gl_waitqueue_t): Alias to gl_carray_waitqueue_t.
21544
21545 2008-10-17  Simon Josefsson  <simon@josefsson.org>
21546
21547         * modules/recvfrom (Depends-on): Add dependency on getpeername.
21548         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
21549
21550 2008-10-17  Jim Meyering  <meyering@redhat.com>
21551
21552         ignore-value: new module
21553         * modules/ignore-value: New file.
21554         * lib/ignore-value.h: New file.
21555         * MODULES.html.sh (Compiler warning management): New section,
21556         just for this module.  More to come.
21557
21558 2008-10-16  Paul Eggert  <eggert@cs.ucla.edu>
21559
21560         open-safer.c: avoid 'signed and unsigned in conditional...' warning
21561         * lib/open-safer.c (open_safer): Use an "if/else" statement in place
21562         of the ternary operator.  Reported by Reuben Thomas <rrt@sc3d.org>.
21563
21564 2008-10-16  Jim Meyering  <meyering@redhat.com>
21565
21566         openat-die.c: avoid 'no previous prototype' warning
21567         * lib/openat-die.c: Include "openat.h".
21568         Reported by Reuben Thomas <rrt@sc3d.org>.
21569
21570 2008-10-16  Simon Josefsson  <simon@josefsson.org>
21571
21572         * m4/netdb_h.m4: Assume that if netdb.h exists, it works.
21573         * lib/netdb.in.h: Fix typo.
21574         Reported by Bruno Haible  <bruno@clisp.org>
21575
21576         * lib/netdb.in.h: Include sys/socket.h for platforms without
21577         netdb.h, to get structures like hostent on MinGW.
21578         * modules/netdb (Depends-on): Add sys_socket.
21579
21580 2008-10-15  Simon Josefsson  <simon@josefsson.org>
21581
21582         * modules/netdb, modules/netdb-tests: New file.
21583         * m4/netdb_h.m4: New file.
21584         * lib/netdb.in.h: Add, currently just an empty file pending
21585         definitions.
21586         * tests/test-netdb.c: New file.
21587         * doc/posix-headers/netdb.texi: Mention that we replace it if
21588         needed.
21589         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
21590         netdb.
21591
21592 2008-10-15  Simon Josefsson  <simon@josefsson.org>
21593
21594         * doc/gnulib.texi (Getaddrinfo and WINVER): Sync documentation
21595         with code.
21596
21597 2008-10-13  Bruno Haible  <bruno@clisp.org>
21598
21599         * lib/glthread/cond.c (glthread_cond_wait_func,
21600         glthread_cond_timedwait_func): Add a comment.
21601
21602 2008-10-13  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21603
21604         * tests/test-poll.c: Include <sys/ioctl.h>, for ioctl().
21605         * tests/test-select.c: Likewise,
21606
21607 2008-10-13  Bruno Haible  <bruno@clisp.org>
21608
21609         * lib/glthread/cond.c (glthread_cond_wait_func,
21610         glthread_cond_timedwait_func): Fix variable name.
21611         Reported by Yoann Vandoorselaere <yoann@prelude-ids.org>.
21612
21613 2008-10-13  Paolo Bonzini  <bonzini@gnu.org>
21614
21615         fix getaddrinfo emulation for systems with struct sockaddr.sa_len
21616         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Detect
21617         struct sockaddr.sa_len.
21618         * lib/getaddrinfo.c (getaddrinfo): Set it if appropriate.
21619
21620 2008-10-13  Simon Josefsson  <simon@josefsson.org>
21621
21622         * build-aux/pmccabe2html: Add css and css_url parameters.
21623
21624 2008-10-12  Bruno Haible  <bruno@clisp.org>
21625
21626         * tests/test-sameacls.c (main) [AIX]: Clear type argument before
21627         calling aclx_get.
21628         Reported by Rainer Tammer <tammer@tammer.net>.
21629
21630 2008-10-12  Bruno Haible  <bruno@clisp.org>
21631
21632         Use msvcrt aware primitives for creation/termination of Win32 threads.
21633         * lib/glthread/thread.c: Include <process.h>.
21634         (glthread_create_func): Use _beginthreadex instead of CreateThread.
21635         (wrapper_func): Update signature.
21636         (gl_thread_exit_func): Use _endthreadex instead of EndThread.
21637
21638 2008-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
21639             Bruno Haible  <bruno@clisp.org>
21640
21641         Provide a Win32 implementation of the 'cond' module.
21642         * lib/glthread/cond.h [USE_WIN32]: New implementation.
21643         * lib/glthread/cond.c (glthread_cond_init_func,
21644         glthread_cond_wait_func, glthread_cond_timedwait_func,
21645         glthread_cond_signal_func, glthread_cond_broadcast_func,
21646         glthread_cond_destroy_func) [USE_WIN32]: New functions.
21647         * modules/cond (Dependencies): Add gettimeofday.
21648
21649 2008-10-11  Bruno Haible  <bruno@clisp.org>
21650
21651         Make sleep work on older versions of mingw.
21652         * m4/sleep.m4 (gl_FUNC_SLEEP): Test whether 'sleep' is declared, not
21653         only whether it exists.
21654         * doc/posix-functions/sleep.texi: Mention the problem with older
21655         versions of mingw.
21656
21657 2008-10-11  Bruno Haible  <bruno@clisp.org>
21658
21659         New module 'shutdown'.
21660         * modules/shutdown: New file.
21661         * lib/sys_socket.in.h (shutdown): New declaration.
21662         * lib/winsock.c (shutdown): New function.
21663         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Initialize
21664         GNULIB_SHUTDOWN.
21665         * modules/sys_socket (Makefile.am): Substitute GNULIB_SHUTDOWN.
21666         * doc/posix-functions/shutdown.texi: Document the new module.
21667
21668 2008-10-11  Jim Meyering  <meyering@redhat.com>
21669
21670         * lib/fclose.c: Fix typo in comment: s/close/fclose/.
21671
21672 2008-10-11  Bruno Haible  <bruno@clisp.org>
21673
21674         New module 'fclose'.
21675         * modules/fclose: New file.
21676         * lib/stdio.in.h (fclose): New declaration.
21677         * lib/fclose.c: New file.
21678         * m4/fclose.m4: New file.
21679         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FCLOSE,
21680         REPLACE_FCLOSE.
21681         * m4/close.m4 (gl_REPLACE_CLOSE): Invoke gl_REPLACE_FCLOSE.
21682         * modules/stdio (Makefile.am): Substitute GNULIB_FCLOSE,
21683         REPLACE_FCLOSE.
21684         * modules/close (Depends-on): fclose.
21685         * doc/posix-functions/fclose.texi: Mention the problem on Windows.
21686
21687 2008-10-11  Bruno Haible  <bruno@clisp.org>
21688
21689         * lib/winsock.c (_gl_close_fd_maybe_socket): If closesocket fails,
21690         set errno and don't call _close.
21691
21692 2008-10-10  Bruno Haible  <bruno@clisp.org>
21693
21694         * lib/copy-acl.c (qcopy_acl) [CYGWIN]: Call chmod before setting the
21695         ACL, not afterwards. Fixes test failure on Cygwin.
21696
21697 2008-10-09  Ben Pfaff  <blp@gnu.org>
21698
21699         * build-aux/announce-gen: Fix gnulib version related part of usage
21700         message.  Die with a useful error message if no tarballs are
21701         found.
21702
21703 2008-10-10  Jim Meyering  <meyering@redhat.com>
21704
21705         bootstrap: use git's --depth=N option only if it's supported
21706         * build-aux/bootstrap: Work with git-1.4.4.4, which does not
21707         recognize the --depth option.  Reported by Pádraig Brady.
21708
21709 2008-10-09  Bruno Haible  <bruno@clisp.org>
21710
21711         New module 'ioctl'.
21712         * modules/ioctl: New file.
21713         * lib/sys_socket.in.h (ioctl): Remove declaration.
21714         * lib/winsock.c: Include <sys/ioctl.h>.
21715         (rpl_ioctl): Define only of the gnulib module 'ioctl' is present.
21716         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Require
21717         gl_SYS_IOCTL_H_DEFAULTS. Set also SYS_IOCTL_H_HAVE_WINSOCK2_H.
21718         * modules/sys_socket (Files): Add m4/sys_ioctl_h.m4.
21719         * doc/posix-functions/ioctl.texi: Mention the new module.
21720
21721 2008-10-09  Bruno Haible  <bruno@clisp.org>
21722
21723         New module 'sys_ioctl'.
21724         * lib/sys_ioctl.in.h: New file.
21725         * m4/sys_ioctl_h.m4: New file.
21726         * modules/sys_ioctl: New file.
21727         * doc/glibc-headers/sys_ioctl.texi: Mention the new module.
21728
21729 2008-10-09  Bruno Haible  <bruno@clisp.org>
21730
21731         * lib/sys_socket.in.h (ioctl): Make signature POSIX compliant.
21732         * lib/winsock.c: Include <stdarg.h>.
21733         (rpl_ioctl): Change to second argument 'int' and then varargs.
21734
21735 2008-10-09  Bruno Haible  <bruno@clisp.org>
21736
21737         * m4/close.m4 (gl_FUNC_CLOSE): Arrange to replace the close() function
21738         when the sys_socket module is present and the system has <winsock2.h>.
21739
21740 2008-10-09  Bruno Haible  <bruno@clisp.org>
21741
21742         * doc/posix-functions/close.texi: Mention module 'close' instead of
21743         module 'sys_socket'.
21744
21745 2008-10-09  Bruno Haible  <bruno@clisp.org>
21746
21747         * doc/glibc-headers/sys_ioctl.texi: New file.
21748         * doc/gnulib.texi: Include it.
21749
21750 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
21751             Bruno Haible  <bruno@clisp.org>
21752
21753         Combine the two replacements of 'close'.
21754         * lib/sys_socket.in.h (close): Define to a reminder to include
21755         <unistd.h>.
21756         (_gl_close_fd_maybe_socket): New declaration.
21757         (HAVE__GL_CLOSE_FD_MAYBE_SOCKET): New macro.
21758         * lib/winsock.c (close): Remove undefinition.
21759         (_gl_close_fd_maybe_socket): Renamed from rpl_close. Define only when
21760         needed for the gnulib module 'close'.
21761         * lib/unistd.in.h (close): If the gnulib module 'close' is not used,
21762         define to an error symbol or to a warning, if suitable.
21763         * lib/close.c: Include <sys/socket.h>.
21764         (rpl_close): Invoke _gl_close_fd_maybe_socket when gnulib defines it.
21765         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): Set also
21766         UNISTD_H_HAVE_WINSOCK2_H.
21767         (gl_SYS_SOCKET_H_DEFAULTS): Require gl_UNISTD_H_DEFAULTS.
21768         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
21769         UNISTD_H_HAVE_WINSOCK2_H.
21770         * modules/sys_socket (Files): Add m4/unistd_h.m4.
21771         (configure.ac): Set a module indicator.
21772         (Makefile.am): Substitute GNULIB_CLOSE.
21773         * modules/unistd (Makefile.am): Substitute UNISTD_H_HAVE_WINSOCK2_H.
21774         * modules/poll-tests (Depends-on): Add close.
21775         * modules/select-tests (Depends-on): Likewise.
21776
21777 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
21778             Bruno Haible  <bruno@clisp.org>
21779
21780         New module 'close'.
21781         * modules/close: New file.
21782         * lib/unistd.in.h (close): Move declaration out of the
21783         FCHDIR_REPLACEMENT scope.
21784         (_gl_unregister_fd): New declaration.
21785         * lib/close.c: New file.
21786         * lib/fchdir.c (rpl_close): Remove function.
21787         * m4/close.m4: New file.
21788         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
21789         close.
21790         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_CLOSE and
21791         REPLACE_CLOSE.
21792         * modules/unistd (Makefile.am): Substitute GNULIB_CLOSE and
21793         REPLACE_CLOSE.
21794         * modules/fchdir (Depends-on): Add close.
21795
21796 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
21797             Bruno Haible  <bruno@clisp.org>
21798
21799         * lib/fcntl.in.h (open): Simplify conditionals.
21800         (_gl_register_fd): New declaration.
21801         * lib/fchdir.c (rpl_open): Remove function.
21802         * lib/open.c: When FCHDIR_REPLACEMENT is defined, compile the file
21803         also.
21804         (open): When FCHDIR_REPLACEMENT is defined, invoke _gl_register_fd.
21805         * m4/fchdir.m4 (gl_FUNC_FCHDIR): When replacing fchdir, also replace
21806         open.
21807
21808 2008-10-09  Jim Meyering  <meyering@redhat.com>
21809
21810         GNUmakefile: use the more name-space-friendly "_version"
21811         * top/GNUmakefile (_dummy): Update.
21812         (_version): Rename from "version".
21813
21814 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
21815             Bruno Haible  <bruno@clisp.org>
21816
21817         * lib/fchdir.c (_gl_unregister_fd): New functions, extracted from
21818         rpl_close.
21819         (_gl_register_fd): New function, extracted from rpl_open.
21820         (rpl_close, rpl_closedir): Use _gl_unregister_fd.
21821         (rpl_open, rpl_opendir): Use _gl_register_fd.
21822
21823 2008-10-09  Paolo Bonzini  <bonzini@gnu.org>
21824
21825         Fix organization of 'open' replacement.
21826         * m4/open.m4 (gl_REPLACE_OPEN): New macro.
21827         (gl_FUNC_OPEN): Use it.
21828         (gl_PREREQ_OPEN): Add a : to make the body non-empty.
21829
21830 2008-10-08  Bruno Haible  <bruno@clisp.org>
21831
21832         * modules/getdate-tests (test_getdata_LDADD): Add LIBINTL.
21833
21834 2008-10-08  Simon Josefsson  <simon@josefsson.org>
21835
21836         * m4/sys_socket_h.m4: Don't AC_LIBOBJ(winsock).  The file is
21837         AC_LIBOBJ'ed by each gnulib module that needs it (e.g., socket,
21838         listen).
21839
21840 2008-10-08  Eric Blake  <ebb9@byu.net>
21841
21842         GNUmakefile: add 'make version' target
21843         * top/GNUmakefile (_curr-ver): Split version update rules...
21844         (version): ...into a target.
21845
21846 2008-10-07  Bruno Haible  <bruno@clisp.org>
21847
21848         Use a more portable replacement expression for -0.0L.
21849         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Use -LDBL_MIN * LDBL_MIN
21850         instead of -0.0L. Fix m4 quotation.
21851
21852         * tests/test-signbit.c: Include <float.h>.
21853         (minus_zero): New variable.
21854         (test_signbitl): Use minus_zero instead of -zero.
21855         * modules/signbit-tests (Depends-on): Add float.
21856
21857         * tests/test-ceill.c: Include <float.h>.
21858         (zero): Remove variable.
21859         (minus_zero): New variable.
21860         (main): Use minus_zero instead of -zero.
21861         * modules/ceill-tests (Depends-on): Add float.
21862
21863         * tests/test-floorl.c: Include <float.h>.
21864         (zero): Remove variable.
21865         (minus_zero): New variable.
21866         (main): Use minus_zero instead of -zero.
21867         * modules/floorl-tests (Depends-on): Add float.
21868
21869         * tests/test-roundl.c: Include <float.h>.
21870         (zero): Remove variable.
21871         (minus_zero): New variable.
21872         (main): Use minus_zero instead of -zero.
21873         * modules/roundl-tests (Depends-on): Add float.
21874
21875         * tests/test-truncl.c: Include <float.h>.
21876         (zero): Remove variable.
21877         (minus_zero): New variable.
21878         (main): Use minus_zero instead of -zero.
21879         * modules/truncl-tests (Depends-on): Add float.
21880
21881         * tests/test-frexpl.c (zero): Remove variable.
21882         (minus_zero): New variable.
21883         (main): Use minus_zero instead of -zero.
21884         * modules/frexpl-tests (Depends-on): Add float.
21885
21886         * tests/test-isnan.c (zerol): Remove variable.
21887         (minus_zerol): New variable.
21888         (test_long_double): Use minus_zerol instead of -zerol.
21889         * modules/isnan-tests (Depends-on): Add float.
21890
21891         * tests/test-isnanl.h (zero): Remove variable.
21892         (minus_zero): New variable.
21893         (main): Use minus_zero instead of -zero.
21894         * modules/isnanl-nolibm-tests (Depends-on): Add float.
21895         * modules/isnanl-tests (Depends-on): Add float.
21896
21897         * tests/test-ldexpl.c (zero): Remove variable.
21898         (minus_zero): New variable.
21899         (main): Use minus_zero instead of -zero.
21900         * modules/ldexpl-tests (Depends-on): Add float.
21901
21902         * tests/test-snprintf-posix.h (zerol): Remove variable.
21903         (minus_zerol): New variable.
21904         (test_function): Use minus_zerol instead of -zerol.
21905         * modules/snprintf-posix-tests (Depends-on): Add float.
21906         * modules/vsnprintf-posix-tests (Depends-on): Add float.
21907
21908         * tests/test-sprintf-posix.h (zerol): Remove variable.
21909         (minus_zerol): New variable.
21910         (test_function): Use minus_zerol instead of -zerol.
21911         * modules/sprintf-posix-tests (Depends-on): Add float.
21912         * modules/vsprintf-posix-tests (Depends-on): Add float.
21913
21914         * tests/test-vasnprintf-posix.c (zerol): Remove variable.
21915         (minus_zerol): New variable.
21916         (test_function): Use minus_zerol instead of -zerol.
21917         * modules/vasnprintf-posix-tests (Depends-on): Add float.
21918
21919         * tests/test-vasprintf-posix.c (zerol): Remove variable.
21920         (minus_zerol): New variable.
21921         (test_function): Use minus_zerol instead of -zerol.
21922         * modules/vasprintf-posix-tests (Depends-on): Add float.
21923
21924 2008-10-07  Simon Josefsson  <simon@josefsson.org>
21925
21926         * MODULES.html.sh (Support for building documentation): Mention
21927         pmccabe2html.  Sort entries.
21928
21929         Add pmccabe2html module, from gnupdf.
21930         * build-aux/pmccabe.css: New file.
21931         * build-aux/pmccabe2html: New file.
21932         * m4/pmccabe2html.m4: New file.
21933         * modules/pmccabe2html: New file.
21934
21935 2008-10-07  Richard W.M. Jones <rjones@redhat.com>
21936
21937         flock: new module
21938         * MODULES.html.sh: Add to list of modules.
21939         * lib/flock.c: flock implementation for Windows and Unix systems
21940         which have fcntl.
21941         * doc/glibc-functions/flock.texi: Update documentation.
21942         * lib/sys_file.in.h: <sys/file.h> header file.
21943         * m4/flock.m4: M4 macros.
21944         * m4/sys_file_h.m4: M4 macros for replacement sys/file.h.
21945         * modules/flock: flock module.
21946         * modules/flock-tests: flock tests module.
21947         * modules/sys_file: sys/file.h module.
21948         * tests/test-flock.c: test suite for flock.
21949
21950 2008-10-06  Jim Meyering  <meyering@redhat.com>
21951
21952         bootstrap: check for LT_INIT more portably still ;-)
21953         * build-aux/bootstrap: Don't rely on \>, since it's not portable.
21954         Spotted by Bruno Haible.
21955
21956 2008-10-06  Eric Blake  <ebb9@byu.net>
21957
21958         test-signbit: avoid tripping Irix cc bug on -0.0L
21959         * tests/test-signbit.c (minus_zerol): Delete, and replace with
21960         '-zerol'.  This may break on HP-UX/hppa, but at least makes the
21961         entire testsuite consistent and avoids an Irix 6.2 bug.
21962
21963 2008-10-05  Bruno Haible  <bruno@clisp.org>
21964             Jim Meyering  <jim@meyering.net>
21965
21966         Add an option for ignoring EPIPE during close_stdout.
21967         * lib/closeout.h: Include <stdbool.h>.
21968         (close_stdout_set_ignore_EPIPE): New declaration.
21969         * lib/closeout.c: Include <stdbool.h>.
21970         (ignore_EPIPE): New variable.
21971         (close_stdout_set_ignore_EPIPE): New function.
21972         (close_stdout): Ignore EPIPE error if ignore_EPIPE is set.
21973         * lib/close-stream.c (close_stream): Mention the possible EPIPE
21974         failure.
21975         * modules/closeout (Depends-on): Add stdbool.
21976
21977 2008-10-05  Bruno Haible  <bruno@clisp.org>
21978
21979         * modules/accept: New file.
21980         * modules/bind: New file.
21981         * modules/connect: New file.
21982         * modules/getpeername: New file.
21983         * modules/getsockname: New file.
21984         * modules/getsockopt: New file.
21985         * modules/listen: New file.
21986         * modules/recv: New file.
21987         * modules/recvfrom: New file.
21988         * modules/send: New file.
21989         * modules/sendto: New file.
21990         * modules/setsockopt: New file.
21991         * modules/socket: New file.
21992         * lib/sys_socket.in.h: Include the GL_LINK_WARNING definition.
21993         (socket, connect, accept, bind, getpeername, getsockname, getsockopt,
21994         listen, recv, send, recvfrom, sendto, setsockopt): Declare only when
21995         the particular module is requested. Add a link warning when the
21996         particular module is not requested.
21997         * lib/winsock.c (rpl_socket, rpl_connect, rpl_accept, rpl_bind,
21998         rpl_getpeername, rpl_getsockname, rpl_getsockopt, rpl_listen, rpl_recv,
21999         rpl_send, rpl_recvfrom, rpl_sendto, rpl_setsockopt): Define only when
22000         the particular module is requested.
22001         * m4/sys_socket_h.m4 (gl_SYS_SOCKET_MODULE_INDICATOR,
22002         gl_SYS_SOCKET_H_DEFAULTS): New macros.
22003         (gl_HEADER_SYS_SOCKET): Require gl_SYS_SOCKET_H_DEFAULTS.
22004         * modules/sys_socket (Depends-on): Add link-warning.
22005         (Makeifle.am): Substitute GNULIB_SOCKET, GNULIB_CONNECT, GNULIB_ACCEPT,
22006         GNULIB_BIND, GNULIB_GETPEERNAME, GNULIB_GETSOCKNAME, GNULIB_GETSOCKOPT,
22007         GNULIB_LISTEN, GNULIB_RECV, GNULIB_SEND, GNULIB_RECVFROM,
22008         GNULIB_SENDTO, GNULIB_SETSOCKOPT, and the definition of
22009         GL_LINK_WARNING.
22010         * doc/posix-functions/accept.texi: Mention the new module 'accept'.
22011         * doc/posix-functions/bind.texi: Mention the new module 'bind'.
22012         * doc/posix-functions/connect.texi: Mention the new module 'connect'.
22013         * doc/posix-functions/getpeername.texi: Mention the new module
22014         'getpeername'.
22015         * doc/posix-functions/getsockname.texi: Mention the new module
22016         'getsockname'.
22017         * doc/posix-functions/getsockopt.texi: Mention the new module
22018         'getsockopt'.
22019         * doc/posix-functions/listen.texi: Mention the new module 'listen'.
22020         * doc/posix-functions/recv.texi: Mention the new module 'recv'.
22021         * doc/posix-functions/recvfrom.texi: Mention the new module 'recvfrom'.
22022         * doc/posix-functions/send.texi: Mention the new module 'send'.
22023         * doc/posix-functions/sendto.texi: Mention the new module 'sendto'.
22024         * doc/posix-functions/setsockopt.texi: Mention the new module
22025         'setsockopt'.
22026         * doc/posix-functions/socket.texi: Mention the new module 'socket'.
22027         * modules/poll-tests (Depends-on): Add socket, bind, getsockopt,
22028         listen, connect, accept.
22029         * modules/select-tests (Depends-on): Likewise.
22030
22031 2008-10-05  Bruno Haible  <bruno@clisp.org>
22032
22033         * lib/winsock.c (strerror): Remove unused #undef.
22034         (rpl_close): Remove unused local variable.
22035
22036         * modules/sys_socket (Depends-on); Add errno.
22037
22038 2008-10-05  Bruno Haible  <bruno@clisp.org>
22039
22040         * lib/sys_select.in.h: Include the GL_LINK_WARNING definition.
22041         (select): Add a link warning when the 'select' module is not used.
22042         * modules/sys_select (Depends-on): Add link-warning.
22043         (Makefile.am): Substitute the definition of GL_LINK_WARNING.
22044         Suggested by Paolo Bonzini.
22045
22046 2008-10-05  Jim Meyering  <meyering@redhat.com>
22047
22048         bootstrap: check for LT_INIT more portably
22049         * build-aux/bootstrap: Avoid using grep -E, since it's not
22050         portable enough.  Suggestion from Bruno Haible.
22051
22052 2008-10-05  Bruno Haible  <bruno@clisp.org>
22053
22054         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem
22055         as being fixed by gnulib.
22056
22057 2008-10-05  Bruno Haible  <bruno@clisp.org>
22058
22059         * modules/select-tests: New file, mostly copied from
22060         modules/sys_select-tests.
22061         * tests/test-select.c: New file, mostly copied from
22062         tests/test-sys_select.c.
22063         * tests/test-sys_select.c: Move most of the code to tests/test-select.c.
22064         * modules/sys_select-tests (Depends-on): Remove all dependencies.
22065         (Makefile.am): Remove test_sys_select_LDADD.
22066
22067         * lib/sys_select.in.h (select): If GNULIB_SELECT is not set, define it
22068         to an undefined symbol, for an error message.
22069         * m4/sys_select_h.m4 (gl_SYS_SELECT_MODULE_INDICATOR): New macro.
22070         (gl_SYS_SELECT_H_DEFAULTS): New macro.
22071         (gl_HEADER_SYS_SELECT): Require it. Don't require compilation of
22072         winsock-select.c here.
22073         * modules/sys_select (Files): Remove lib/winsock-select.c.
22074         (Depends-on): Remove alloca.
22075         (Makefile.am): Substitute GNULIB_SELECT.
22076         * modules/select: New file.
22077         * doc/posix-functions/select.texi: Update.
22078
22079 2008-10-05  Bruno Haible  <bruno@clisp.org>
22080
22081         * lib/spawn_faction_addclose.c (__sysconf): Use getdtablesize always.
22082         * lib/spawn_faction_adddup2.c (__sysconf): Likewise.
22083         * lib/spawn_faction_addopen.c (__sysconf): Likewise.
22084         * modules/posix_spawn_file_actions_addclose (Depends-on): Add
22085         getdtablesize.
22086         * modules/posix_spawn_file_actions_adddup2 (Depends-on): Likewise.
22087         * modules/posix_spawn_file_actions_addopen (Depends-on): Likewise.
22088
22089 2008-10-05  Bruno Haible  <bruno@clisp.org>
22090
22091         * modules/getdtablesize-tests: New file.
22092         * tests/test-getdtablesize.c: New file.
22093
22094         New module 'getdtablesize'.
22095         * lib/unistd.in.h (getdtablesize): New declaration.
22096         * lib/getdtablesize.c: New file.
22097         * m4/getdtablesize.m4: New file.
22098         * modules/getdtablesize: New file.
22099         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
22100         GNULIB_GETDTABLESIZE, HAVE_GETDTABLESIZE.
22101         * modules/unistd (Makefile.am): Substitute GNULIB_GETDTABLESIZE,
22102         HAVE_GETDTABLESIZE.
22103         * doc/glibc-functions/getdtablesize.texi: Mention the new module.
22104
22105 2008-10-05  Bruno Haible  <bruno@clisp.org>
22106
22107         * modules/sched (Makefile.am): Fix typo.
22108         Reported by Simon Josefsson.
22109
22110 2008-10-05  Jim Meyering  <meyering@redhat.com>
22111
22112         bootstrap: check for LT_INIT, too
22113         * build-aux/bootstrap: Both AC_PROG_LIBTOOL and AM_PROG_LIBTOOL
22114         are deprecated.  Suggestion from Ralf Wildenhues.
22115
22116 2008-10-05  Bruno Haible  <bruno@clisp.org>
22117
22118         * lib/spawn.in.h (POSIX_SPAWN_*): Use the system's values, rather than
22119         overriding them by ours.
22120         (POSIX_SPAWN_USEVFORK): Use the next free bit position.
22121
22122 2008-10-05  Jim Meyering  <meyering@redhat.com>
22123
22124         bootstrap: check for AC_PROG_LIBTOOL as well as AM_PROG_LIBTOOL
22125         * build-aux/bootstrap: Check for AC_PROG_LIBTOOL, as well as the
22126         obsolete AM_PROG_LIBTOOL.  Spotted by Debarshi Ray <rishi@gnu.org>.
22127
22128 2008-10-04  Bruno Haible  <bruno@clisp.org>
22129
22130         * modules/dup2 (License): Change to LGPLv2+.
22131         * modules/sleep (License): Likewise.
22132         * modules/perror (License): Likewise.
22133         * modules/fopen (License): Change to LGPLv2+, with approval by Eric
22134         Blake.
22135         * modules/signal (License): Likewise.
22136         * modules/sigprocmask (License): Likewise.
22137         * modules/raise (License): Change to LGPLv2+, with approval by Jim
22138         Meyering.
22139
22140 2008-10-04  Bruno Haible  <bruno@clisp.org>
22141
22142         * lib/spawn.in.h (POSIX_SPAWN_*): Undefine before redefining.
22143         Reported by Rainer Tammer <tammer@tammer.net>.
22144
22145 2008-10-03  Paolo Bonzini  <bonzini@gnu.org>
22146             Bruno Haible  <bruno@clisp.org>
22147
22148         * lib/errno.in.h (EWOULDBLOCK) [win32]: Define to EAGAIN.
22149         * lib/winsock.c (set_winsock_errno): Map WSAEWOULDBLOCK to EWOULDBLOCK.
22150         * lib/strerror.c (rpl_strerror): Remove error string for EWOULDBLOCK.
22151
22152 2008-10-03  Kamil Dudka  <kdudka@redhat.com>
22153
22154         filevercmp: new module
22155         * lib/filevercmp.h: New function filevercmp comparing version strings.
22156         * lib/filevercmp.c: Implementation of filevercmp function.
22157         * modules/filevercmp: Module metadata.
22158         * tests/test-filevercmp.c: Unit test for new module.
22159         * modules/filevercmp-tests: Unit test metadata.
22160         * MODULES.html.sh: Add filevercmp module.
22161
22162 2008-10-03  Bruno Haible  <bruno@clisp.org>
22163
22164         * lib/c-ctype.h: Add comment.
22165         Reported by Jim Meyering.
22166
22167 2008-10-02  Bruno Haible  <bruno@clisp.org>
22168
22169         * modules/posix_spawn-internal (Depends-on): Add 'open'.
22170
22171 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
22172
22173         * build-aux/bootstrap: Allow renaming bootstrap, and change the
22174         name of bootstrap.conf accordingly.
22175
22176 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
22177
22178         * build-aux/bootstrap: Install git-merge-changelog configuration
22179         items into .gitconfig if needed.
22180
22181 2008-10-02  Paolo Bonzini  <bonzini@gnu.org>
22182
22183         * build-aux/bootstrap: Recognize `gnulib' being a submodule in a
22184         git repository, and initialize/update it accordingly.
22185
22186 2008-10-02  Richard W.M. Jones  <rjones@redhat.com>
22187
22188         * modules/fsync-tests: New file.
22189         * tests/test-fsync.c: New file.
22190
22191         New module 'fsync'.
22192         * lib/fsync.c: New file.
22193         * m4/fsync.m4: New file.
22194         * modules/fsync: New file.
22195         * lib/unistd.in.h (fsync): New declaration.
22196         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Define and AC_SUBST both
22197         GNULIB_FSYNC and HAVE_FSYNC.
22198         * modules/unistd: Substitute GNULIB_FSYNC and HAVE_FSYNC.
22199         * MODULES.html.sh (posix_functions): Add fsync.
22200         * doc/posix-functions/fsync.texi: Mention the new module.
22201
22202 2008-10-02  Jim Meyering  <meyering@redhat.com>
22203
22204         fts.c: sync with similar code from coreutils' remove.c
22205         * lib/fts.c (dirent_inode_sort_may_be_useful): Merge from coreutils.
22206         Guard also with "#if defined __linux__", since for now at least,
22207         this code is Linux-kernel-specific.
22208
22209 2008-10-02  Jim Meyering  <meyering@redhat.com>
22210
22211         fts: bug fixes
22212         * lib/fts.c: Remove unnecessary "defined" in cpp directive.
22213         Include <sys/vfs.h>, not <sys/statfs.h>.
22214
22215         * m4/fts.m4 (gl_FUNC_FTS_CORE): Fix typo s/vfs/vfs.h/.
22216         Include <sys/vfs.h>, not <sys/statfs.h>.
22217
22218 2008-10-01  Bruno Haible  <bruno@clisp.org>
22219
22220         Avoid the broken posix_spawn function on AIX 5.3 and 6.1.
22221         * m4/posix_spawn.m4 (gl_POSIX_SPAWN_WORKS): New macro.
22222         (gl_POSIX_SPAWN_BODY): Invoke it. Set REPLACE_POSIX_SPAWN if needed.
22223         * doc/posix-functions/posix_spawn.texi: Mention the AIX bugs.
22224         * doc/posix-functions/posix_spawnp.texi: Likewise.
22225         * m4/execute.m4 (gl_EXECUTE): Invoke gl_POSIX_SPAWN_WORKS, to check
22226         whether posix_spawn actually works.
22227         * m4/pipe.m4 (gl_PIPE): Likewise.
22228         * modules/execute (Files): Add m4/posix_spawn.m4.
22229         * modules/pipe (Files): Add m4/posix_spawn.m4.
22230         Reported and analyzed by Rainer Tammer <tammer@tammer.net>.
22231
22232 2008-10-01  Jim Meyering  <meyering@redhat.com>
22233
22234         remove trailing spaces
22235         * NEWS: Likewise.
22236         * lib/poll.c (poll): Likewise.
22237         * lib/sys_socket.in.h (SHUT_RDWR): Likewise.
22238         * lib/winsock.c (rpl_close): Likewise.
22239         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Likewise.
22240         * modules/yield: Likewise.
22241         * tests/test-poll.c (connect_to_socket, poll1): Likewise.
22242         * tests/test-sys_select.c (connect_to_socket): Likewise.
22243
22244         fts.c: adjust a new interface to be more generally useful
22245         * lib/fts.c (dirent_inode_sort_may_be_useful): Take an FD parameter.
22246         (fts_build): Adjust caller.
22247
22248 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22249
22250         * modules/cond-tests: New file.
22251         * tests/test-cond.c: New file.
22252
22253 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22254             Bruno Haible  <bruno@clisp.org>
22255
22256         * modules/cond (Dependencies): Add errno, time.
22257         * lib/glthread/cond.h: Include <time.h>.
22258         (gl_cond_define, gl_cond_define_initialized): Use the same definition
22259         across platforms.
22260
22261 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22262             Bruno Haible  <bruno@clisp.org>
22263
22264         * m4/thread.m4 (gl_THREAD): Fix detection of pthread_atfork function.
22265
22266 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22267             Bruno Haible  <bruno@clisp.org>
22268
22269         * modules/tls-tests (Depends-on): Add thread, yield.
22270         (configure.ac): Remove all checks.
22271         (test_tls_LDADD): Use YIELD_LIB instead of LIBSCHED.
22272         * tests/test-tls.c (gl_thread_t, gl_thread_join, gl_thread_yield,
22273         gl_thread_self): Remove definitions. Include glthread/thread.h and
22274         glthread/yield.h instead.
22275         (test_tls): Pass an additional NULL argument to gl_thread_join.
22276
22277 2008-09-30  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22278             Bruno Haible  <bruno@clisp.org>
22279
22280         * modules/lock-tests (Depends-on): Add thread, yield.
22281         (configure.ac): Remove all checks.
22282         (test_lock_LDADD): Use YIELD_LIB instead of LIBSCHED.
22283         * tests/test-lock.c (gl_thread_t, gl_thread_join, gl_thread_yield,
22284         gl_thread_self): Remove definitions. Include glthread/thread.h and
22285         glthread/yield.h instead.
22286         (test_lock, test_rwlock, test_recursive_lock, test_once): Pass an
22287         additional NULL argument to gl_thread_join.
22288
22289 2008-09-30  Bruno Haible  <bruno@clisp.org>
22290
22291         Fix the Win32 implementation of the 'thread' module.
22292         * lib/glthread/thread.h [USE_WIN32_THREADS] (gl_thread_t): Change to a
22293         pointer type.
22294         (gl_thread_self): Invoke gl_thread_self_func.
22295         (gl_thread_self_func): New declaration.
22296         * lib/glthread/thread.c [USE_WIN32_THREADS] (self_key): New variable.
22297         (do_init_self_key, init_self_key): New functions.
22298         (struct gl_thread_struct): Renamed from 'struct thread_extra'.
22299         Remove some fields.
22300         (running_threads, running_lock): Remove variables.
22301         (get_current_thread_handle): New function.
22302         (gl_thread_self_func, wrapper_func, glthread_create_func,
22303         glthread_join_func, gl_thread_exit_func): Largely rewritten and
22304         simplified.
22305
22306 2008-09-30  Bruno Haible  <bruno@clisp.org>
22307
22308         * lib/winsock-select.c (win32_poll_handle): Add shortcut for regular
22309         files.
22310
22311 2008-09-30  Jim Meyering  <meyering@redhat.com>
22312
22313         fts.m4: correct the test for statfs.f_type
22314         * m4/fts.m4 (gl_FUNC_FTS_CORE): Include <sys/statfs.h>
22315         when checking for statfs.f_type.
22316
22317 2008-09-15  Simon Josefsson  <simon@josefsson.org>
22318
22319         tests: avoid some compiler warnings
22320         * tests/test-memchr.c (main): Pass NULL indirectly.
22321         * tests/test-getdate.c (main): Remove unused variable 'ret'.
22322
22323 2008-09-29  Ondřej Vašík  <ovasik@redhat.com>
22324
22325         getdate.y: disallow countable dayshifts like "4 yesterday ago"
22326         * lib/getdate.y (relative_time_table) [tDAY_SHIFT]: New type for
22327         exactly specified dayshifts.
22328         (dayshift): New rule.
22329         (rel): Add dayshift.
22330         (relative_time_table) [tomorrow, yesterday, today, now]:
22331         Use tDAY_SHIFT in place of tDAY_UNIT.
22332         * tests/test-getdate.c: Add tests for now-disallowed countable
22333         dayshifts, e.g., "4 yesterday ago".
22334
22335 2008-09-29  Bruno Haible  <bruno@clisp.org>
22336
22337         * tests/test-posix_spawn1.c: Renamed from tests/test-posix_spawn.c.
22338         * tests/test-posix_spawn1.in.sh: Renamed from
22339         tests/test-posix_spawn.in.sh.
22340         * tests/test-posix_spawn2.c: New file.
22341         * tests/test-posix_spawn2.in.sh: New file.
22342         * modules/posix_spawnp-tests (Files): Update.
22343         (Makefile.am): Update. Add test-posix_spawn2 to the tests.
22344
22345 2008-09-29  Bruno Haible  <bruno@clisp.org>
22346
22347         Propagate effects of putenv/setenv/unsetenv to child processes.
22348         * lib/execute.c (execute): Use spawnvpe instead of spawnvp.
22349         * lib/pipe.c (create_pipe): Likewise.
22350
22351 2008-09-29  Bruno Haible  <bruno@clisp.org>
22352
22353         Enable use of shell scripts as executables in mingw.
22354         * lib/execute.c (execute): When spawnv fails with error ENOEXEC,
22355         run the program as a shell script.
22356         * lib/pipe.c (create_pipe): Likewise.
22357         * lib/w32spawn.h (prepare_spawn): Add a hidden element in front of the
22358         resulting array.
22359
22360 2008-09-29  Eric Blake  <ebb9@byu.net>
22361
22362         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): Fix typo.
22363
22364 2008-08-24  Paolo Bonzini  <bonzini@gnu.org>
22365
22366         * doc/posix-functions/accept.texi: Update mingw problems.
22367         * doc/posix-functions/bind.texi: Update mingw problems.
22368         * doc/posix-functions/close.texi: Update mingw problems.
22369         * doc/posix-functions/connect.texi: Update mingw problems.
22370         * doc/posix-functions/getpeername.texi: Update mingw problems.
22371         * doc/posix-functions/getsockname.texi: Update mingw problems.
22372         * doc/posix-functions/getsockopt.texi: Update mingw problems.
22373         * doc/posix-functions/ioctl.texi: Update mingw problems.
22374         * doc/posix-functions/listen.texi: Update mingw problems.
22375         * doc/posix-functions/recv.texi: Update mingw problems.
22376         * doc/posix-functions/recvfrom.texi: Update mingw problems.
22377         * doc/posix-functions/select.texi: Update mingw problems.
22378         * doc/posix-functions/send.texi: Update mingw problems.
22379         * doc/posix-functions/sendto.texi: Update mingw problems.
22380         * doc/posix-functions/setsockopt.texi: Update mingw problems.
22381         * doc/posix-functions/socket.texi: Update mingw problems.
22382
22383 2008-09-29  Paolo Bonzini  <bonzini@gnu.org>
22384             Bruno Haible  <bruno@clisp.org>
22385
22386         * lib/sys_select.in.h: Include sys/time.h.
22387         * m4/sys_select.h.m4: Test that struct timeval is fully defined.
22388         * modules/sys_select: Depend on sys_time.
22389         * tests/test-sys_select.c: Test that sys/select.h defines struct
22390         timeval fully.
22391
22392 2008-09-29  Bruno Haible  <bruno@clisp.org>
22393
22394         * lib/sys_socket.in.h: Wrap the definitions in 'extern "C"'.
22395         * lib/sys_select.in.h: Likewise.
22396
22397 2008-09-29  Bruno Haible  <bruno@clisp.org>
22398
22399         * lib/winsock.c (rpl_close, rpl_socket): Remove unused variables.
22400
22401 2008-09-29  Bruno Haible  <bruno@clisp.org>
22402
22403         * m4/sockets.m4 (gl_SOCKETS): Check also for the need to use -lsocket.
22404         Set LIBSOCKET instead of augmenting LIBS.
22405         * modules/sockets (Link): New section.
22406         * modules/sockets-tests (test_sockets_LDADD): New variable.
22407         * modules/sys_select-tests (test_sys_select_LDADD): New variable.
22408         * modules/poll-tests (test_poll_LDADD): New variable.
22409         * NEWS: Document the change.
22410
22411 2008-09-29  Bruno Haible  <bruno@clisp.org>
22412
22413         * m4/arpa_inet_h.m4 (gl_REPLACE_ARPA_INET_H): New macro.
22414         * m4/inet_ntop.m4 (gl_INET_NTOP): Invoke it instead of assigning
22415         ARPA_INET_H directly.
22416         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
22417
22418 2008-09-28  Bruno Haible  <bruno@clisp.org>
22419
22420         * m4/sys_socket_h.m4 (gl_PREREQ_SYS_H_WINSOCK2): New macro, extracted
22421         from gl_HEADER_SYS_SOCKET.
22422         (gl_HEADER_SYS_SOCKET): Invoke it.
22423         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
22424
22425 2008-09-28  Bruno Haible  <bruno@clisp.org>
22426
22427         * doc/posix-headers/sys_select.texi: Mention 'struct timeval' problem.
22428         * tests/test-sys_select.c: Include <sys/time.h>, for struct timeval.
22429         Needed on OSF/1 4.0.
22430
22431 2008-09-28  Bruno Haible  <bruno@clisp.org>
22432
22433         Override open more carefully.
22434         * lib/open.c (orig_open): New function.
22435         (rpl_open): Use orig_open instead of open.
22436         * lib/fcntl.in.h: Add special invocation convention.
22437         * m4/open.m4 (gl_PREREQ_OPEN): New macro.
22438         (gl_FUNC_OPEN): Invoke it.
22439
22440         Override freopen more carefully.
22441         * lib/freopen.c (orig_freopen): New function.
22442         (rpl_freopen): Use orig_freopen instead of freopen.
22443         * m4/freopen.m4 (gl_PREREQ_FREOPEN): New macro.
22444         (gl_FUNC_FREOPEN): Invoke it.
22445
22446         Override fopen more carefully.
22447         * lib/fopen.c (orig_fopen): New function.
22448         (rpl_fopen): Use orig_fopen instead of fopen.
22449         * m4/fopen.m4 (gl_PREREQ_FOPEN): New macro.
22450         (gl_FUNC_FOPEN): Invoke it.
22451         Needed on AIX. Reported by Rainer Tammer <tammer@tammer.net>.
22452
22453 2008-09-28  Bruno Haible  <bruno@clisp.org>
22454
22455         * lib/pipe.h (create_pipe_out, create_pipe_bidi): Add comment about
22456         SIGPIPE.
22457
22458 2008-09-28  Bruno Haible  <bruno@clisp.org>
22459
22460         * tests/test-sigaction.c (handler, main): Disable the check whether
22461         SA_RESETHAND has reverted the installed handler to SIG_DFL. Needed on
22462         glibc systems with LinuxThreads.
22463
22464 2008-09-28  Bruno Haible  <bruno@clisp.org>
22465
22466         * doc/posix-functions/freopen.texi: Mention the trailing slash problem.
22467
22468         * lib/stdio.in.h (fopen, freopen): Undefine before redefining. Needed
22469         with AIX xlc.
22470         * lib/fcntl.in.h (open): Likewise.
22471         Reported by Rainer Tammer <tammer@tammer.net>.
22472
22473 2008-09-28  Bruno Haible  <bruno@clisp.org>
22474
22475         * modules/posix_spawnp-tests: New file.
22476         * tests/test-posix_spawn.c: New file.
22477         * tests/test-posix_spawn.in.sh: New file.
22478
22479         New module 'posix_spawnp'.
22480         * modules/posix_spawnp: New file.
22481         * lib/spawnp.c: New file, from GNU libc with modifications.
22482         * doc/posix-functions/posix_spawnp.texi: Mention the new module.
22483
22484         New module 'posix_spawn'.
22485         * modules/posix_spawn: New file.
22486         * lib/spawn.c: New file, from GNU libc with modifications.
22487         * doc/posix-functions/posix_spawn.texi: Mention the new module.
22488
22489         New module 'posix_spawnattr_destroy'.
22490         * modules/posix_spawnattr_destroy: New file.
22491         * lib/spawnattr_destroy.c: New file, from GNU libc with modifications.
22492         * doc/posix-functions/posix_spawnattr_destroy.texi: Mention the new
22493         module.
22494
22495         New module 'posix_spawnattr_setsigmask'.
22496         * modules/posix_spawnattr_setsigmask: New file.
22497         * lib/spawnattr_setsigmask.c: New file, from GNU libc with
22498         modifications.
22499         * doc/posix-functions/posix_spawnattr_setsigmask.texi: Mention the
22500         new module.
22501
22502         New module 'posix_spawnattr_getsigmask'.
22503         * modules/posix_spawnattr_getsigmask: New file.
22504         * lib/spawnattr_getsigmask.c: New file, from GNU libc with
22505         modifications.
22506         * doc/posix-functions/posix_spawnattr_getsigmask.texi: Mention the
22507         new module.
22508
22509         New module 'posix_spawnattr_setsigdefault'.
22510         * modules/posix_spawnattr_setsigdefault: New file.
22511         * lib/spawnattr_setdefault.c: New file, from GNU libc with
22512         modifications.
22513         * doc/posix-functions/posix_spawnattr_setsigdefault.texi: Mention the
22514         new module.
22515
22516         New module 'posix_spawnattr_getsigdefault'.
22517         * modules/posix_spawnattr_getsigdefault: New file.
22518         * lib/spawnattr_getdefault.c: New file, from GNU libc with
22519         modifications.
22520         * doc/posix-functions/posix_spawnattr_getsigdefault.texi: Mention the
22521         new module.
22522
22523         New module 'posix_spawnattr_setschedpolicy'.
22524         * modules/posix_spawnattr_setschedpolicy: New file.
22525         * lib/spawnattr_setschedpolicy.c: New file, from GNU libc with
22526         modifications.
22527         * doc/posix-functions/posix_spawnattr_setschedpolicy.texi: Mention the
22528         new module.
22529
22530         New module 'posix_spawnattr_getschedpolicy'.
22531         * modules/posix_spawnattr_getschedpolicy: New file.
22532         * lib/spawnattr_getschedpolicy.c: New file, from GNU libc with
22533         modifications.
22534         * doc/posix-functions/posix_spawnattr_getschedpolicy.texi: Mention the
22535         new module.
22536
22537         New module 'posix_spawnattr_setschedparam'.
22538         * modules/posix_spawnattr_setschedparam: New file.
22539         * lib/spawnattr_setschedparam.c: New file, from GNU libc with
22540         modifications.
22541         * doc/posix-functions/posix_spawnattr_setschedparam.texi: Mention the
22542         new module.
22543
22544         New module 'posix_spawnattr_getschedparam'.
22545         * modules/posix_spawnattr_getschedparam: New file.
22546         * lib/spawnattr_getschedparam.c: New file, from GNU libc with
22547         modifications.
22548         * doc/posix-functions/posix_spawnattr_getschedparam.texi: Mention the
22549         new module.
22550
22551         New module 'posix_spawnattr_setpgroup'.
22552         * modules/posix_spawnattr_setpgroup: New file.
22553         * lib/spawnattr_setpgroup.c: New file, from GNU libc with
22554         modifications.
22555         * doc/posix-functions/posix_spawnattr_setpgroup.texi: Mention the new
22556         module.
22557
22558         New module 'posix_spawnattr_getpgroup'.
22559         * modules/posix_spawnattr_getpgroup: New file.
22560         * lib/spawnattr_getpgroup.c: New file, from GNU libc with
22561         modifications.
22562         * doc/posix-functions/posix_spawnattr_getpgroup.texi: Mention the new
22563         module.
22564
22565         New module 'posix_spawnattr_setflags'.
22566         * modules/posix_spawnattr_setflags: New file.
22567         * lib/spawnattr_setflags.c: New file, from GNU libc with modifications.
22568         * doc/posix-functions/posix_spawnattr_setflags.texi: Mention the new
22569         module.
22570
22571         New module 'posix_spawnattr_getflags'.
22572         * modules/posix_spawnattr_getflags: New file.
22573         * lib/spawnattr_getflags.c: New file, from GNU libc with modifications.
22574         * doc/posix-functions/posix_spawnattr_getflags.texi: Mention the new
22575         module.
22576
22577         New module 'posix_spawnattr_init'.
22578         * modules/posix_spawnattr_init: New file.
22579         * lib/spawnattr_init.c: New file, from GNU libc with modifications.
22580         * doc/posix-functions/posix_spawnattr_init.texi: Mention the new
22581         module.
22582
22583         New module 'posix_spawn_file_actions_destroy'.
22584         * modules/posix_spawn_file_actions_destroy: New file.
22585         * lib/spawn_faction_destroy.c: New file, from GNU libc with
22586         modifications.
22587         * doc/posix-functions/posix_spawn_file_actions_destroy.texi: Mention
22588         the new module.
22589
22590         New module 'posix_spawn_file_actions_addopen'.
22591         * modules/posix_spawn_file_actions_addopen: New file.
22592         * lib/spawn_faction_addopen.c: New file, from GNU libc with
22593         modifications.
22594         * doc/posix-functions/posix_spawn_file_actions_addopen.texi: Mention
22595         the new module.
22596
22597         New module 'posix_spawn_file_actions_adddup2'.
22598         * modules/posix_spawn_file_actions_adddup2: New file.
22599         * lib/spawn_faction_adddup2.c: New file, from GNU libc with
22600         modifications.
22601         * doc/posix-functions/posix_spawn_file_actions_adddup2.texi: Mention
22602         the new module.
22603
22604         New module 'posix_spawn_file_actions_addclose'.
22605         * modules/posix_spawn_file_actions_addclose: New file.
22606         * lib/spawn_faction_addclose.c: New file, from GNU libc with
22607         modifications.
22608         * doc/posix-functions/posix_spawn_file_actions_addclose.texi: Mention
22609         the new module.
22610
22611         New module 'posix_spawn_file_actions_init'.
22612         * modules/posix_spawn_file_actions_init: New file.
22613         * lib/spawn_faction_init.c: New file, from GNU libc with modifications.
22614         * doc/posix-functions/posix_spawn_file_actions_init.texi: Mention the
22615         new module.
22616
22617         New module 'posix_spawn-internal'.
22618         * modules/posix_spawn-internal: New file.
22619         * lib/spawn_int.h: New file, from GNU libc with modifications.
22620         * lib/spawni.c: New file, from GNU libc with modifications.
22621         * m4/posix_spawn.m4: New file.
22622
22623         New module 'spawn'.
22624         * modules/spawn: New file.
22625         * lib/spawn.in.h: New file, from GNU libc with modifications.
22626         * m4/spawn_h.m4: New file.
22627         * doc/posix-headers/spawn.texi: Mention the new module.
22628
22629 2008-09-28  Bruno Haible  <bruno@clisp.org>
22630
22631         * modules/sched-tests: New file.
22632         * tests/test-sched.c: New file.
22633
22634         New module 'sched'.
22635         * modules/sched: New file.
22636         * lib/sched.in.h: New file.
22637         * m4/sched_h.m4: New file.
22638         * doc/posix-headers/sched.texi: Mention the new module.
22639
22640 2008-09-27  Eric Blake  <ebb9@byu.net>
22641
22642         Fix previous patch, and tweak references to $0.
22643         * posix-modules: Call func_gnulib_dir before using $gnulib_dir.
22644         (func_version, func_gnulib_dir): Don't call this program
22645         gnulib-tool.
22646         (func_gnulib_dir, func_tmpdir, func_fatal_error): Avoid shell bugs
22647         with using $0 in function.
22648         * gnulib-tool (func_gnulib_dir, func_tmpdir): Likewise.
22649         (func_fatal_error): Reuse the name the user invoked us with.
22650
22651 2008-09-27  Bruno Haible  <bruno@clisp.org>
22652
22653         * m4/iconv_h.m4 (gl_REPLACE_ICONV_H): New macro.
22654         (gl_ICONV_H_DEFAULTS): Initialize ICONV_H here...
22655         (gl_ICONV_H): Not here.
22656         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): Invoke gl_REPLACE_ICONV_H
22657         instead of assigning ICONV_H directly.
22658
22659         * m4/wchar.m4 (gl_REPLACE_WCHAR_H): New macro.
22660         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Invoke it instead of assigning
22661         WCHAR_H directly.
22662
22663 2008-09-27  Bruno Haible  <bruno@clisp.org>
22664
22665         * lib/arpa_inet.in.h: Include the GL_LINK_WARNING anchor.
22666         * modules/arpa_inet (Depends-on): Add link-warning.
22667         (Makefile.am): Insert the definition of GL_LINK-WARNING.
22668         * modules/unistd (Makefile.am): Likewise.
22669
22670 2008-09-26  Bruno Haible  <bruno@clisp.org>
22671
22672         * posix-modules (cvsdatestamp, last_checkin_date, version): Remove
22673         variables.
22674         (func_version): Essentially copied from gnulib-tool.
22675         (func_exit, func_gnulib_dir, func_tmpdir, func_fatal_error,
22676         func_readlink): Copied from gnulib-tool.
22677
22678 2008-09-26  Bruno Haible  <bruno@clisp.org>
22679
22680         * gnulib-tool (func_version): Change directory to $gnulib_dir before
22681         invoking git-version-gen.
22682
22683 2008-09-26  Bruno Haible  <bruno@clisp.org>
22684
22685         * posix-modules: Update to directory names changed on 2008-01-19.
22686         Remove commas in output before splitting into words. No more need to
22687         avoid 'ftruncate' since 2007-02-19.
22688
22689 2008-09-26  Bruno Haible  <bruno@clisp.org>
22690
22691         * doc/posix-headers/errno.texi: Remove mention of module 'EOVERFLOW'.
22692
22693 2008-09-26  Bruno Haible  <bruno@clisp.org>
22694
22695         * lib/fwriteerror.c (do_fwriteerror): Ignore error EPIPE.
22696         * modules/fwriteerror (Depends-on): Add errno.
22697
22698 2008-09-26  Bruno Haible  <bruno@clisp.org>
22699
22700         * tests/test-vc-list-files-git.sh: Explain reason for skipping test.
22701         * tests/test-vc-list-files-cvs.sh: Likewise.
22702
22703 2008-09-26  Bruno Haible  <bruno@clisp.org>
22704
22705         * doc/posix-headers/sys_resource.texi: Reorder items.
22706
22707 2008-09-26  Jim Meyering  <meyering@redhat.com>
22708
22709         fts: tweak inode comparison function
22710         * lib/fts.c (fts_compare_ino): Sort on increasing, not decreasing
22711         inode numbers, as documented.
22712
22713         fts: sort dirent entries on inode number before traversing
22714         This avoids a quadratic, seek-related performance penalty when
22715         operating on a directory containing many entries (measurable at 10k;
22716         3.5 hours at 2 million entries with a cold cache) on certain types
22717         of file systems, including ext3 and ext4, but not tmpfs.
22718         * lib/fts.c (DT_MUST_BE, NOT_AN_INODE_NUMBER, D_INO): Define.
22719         (FTS_INODE_SORT_DIR_ENTRIES_THRESHOLD): Define if not defined.
22720         (S_MAGIC_TMPFS, S_MAGIC_NFS): Define.
22721         (fs_handles_readdir_ordered_dirents_efficiently): New function.
22722         (dirent_inode_sort_may_be_useful, fts_compare_ino): Likewise.
22723         (fts_build): Set the stat.st_ino member from D_INO.
22724         If it is likely to be useful, sort dirent entries on inode number.
22725
22726         * m4/fts.m4 (gl_FUNC_FTS_CORE): Check for fstatfs, sys/vfs.h,
22727         and the struct statfs.f_type member.
22728         * modules/fts (Depends-on): Add d-ino.
22729
22730 2008-09-26  Bruno Haible  <bruno@clisp.org>
22731
22732         * modules/sigpipe-die (Depends-on): Add sigpipe.
22733
22734         * lib/stdio.in.h (fprintf, vfprintf, printf, vprintf, fputc, putc,
22735         putchar, fputs, puts, fwrite): Replace when REPLACE_STDIO_WRITE_FUNCS
22736         and GNULIB_STDIO_H_SIGPIPE are set.
22737         * lib/stdio-write.c: New file.
22738         * m4/stdio_h.m4 (gl_STDIO_H): Set GNULIB_FPRINTF, GNULIB_PRINTF,
22739         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
22740         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
22741         REPLACE_STDIO_WRITE_FUNCS.
22742         (gl_STDIO_H_DEFAULTS): Initialize GNULIB_FPRINTF, GNULIB_PRINTF,
22743         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
22744         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
22745         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
22746         * modules/stdio (Files): Add lib/stdio-write.c.
22747         (Makefile.am): Substitute GNULIB_FPRINTF, GNULIB_PRINTF,
22748         GNULIB_VFPRINTF, GNULIB_VPRINTF, GNULIB_FPUTC, GNULIB_PUTC,
22749         GNULIB_PUTCHAR, GNULIB_FPUTS, GNULIB_PUTS, GNULIB_FWRITE,
22750         GNULIB_STDIO_H_SIGPIPE, REPLACE_STDIO_WRITE_FUNCS.
22751         * m4/fprintf-posix.m4 (gl_REPLACE_FPRINTF): Define
22752         REPLACE_FPRINTF_POSIX.
22753         * m4/printf-posix-rpl.m4 (gl_REPLACE_PRINTF): Define
22754         REPLACE_PRINTF_POSIX.
22755         * m4/vfprintf-posix.m4 (gl_REPLACE_VFPRINTF): Define
22756         REPLACE_VFPRINTF_POSIX.
22757         * m4/vprintf-posix.m4 (gl_REPLACE_VPRINTF): Define
22758         REPLACE_VPRINTF_POSIX.
22759         * doc/posix-functions/fprintf.texi: Mention the sigpipe module and the
22760         SIGPIPE issue.
22761         * doc/posix-functions/fputc.texi: Likewise.
22762         * doc/posix-functions/fputs.texi: Likewise.
22763         * doc/posix-functions/fwrite.texi: Likewise.
22764         * doc/posix-functions/printf.texi: Likewise.
22765         * doc/posix-functions/putc.texi: Likewise.
22766         * doc/posix-functions/putchar.texi: Likewise.
22767         * doc/posix-functions/puts.texi: Likewise.
22768         * doc/posix-functions/vfprintf.texi: Likewise.
22769         * doc/posix-functions/vprintf.texi: Likewise.
22770
22771         * modules/safe-write (Depends-on): Add write.
22772
22773         * modules/sigpipe-tests: New file.
22774         * tests/test-sigpipe.c: New file.
22775         * tests/test-sigpipe.sh: New file.
22776
22777         * modules/write: New file.
22778         * lib/unistd.in.h: Include <sys/types.h>.
22779         (write): New declaration.
22780         * lib/write.c: New file.
22781         * m4/write.m4: New file.
22782         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
22783         GNULIB_UNISTD_H_SIGPIPE, GNULIB_WRITE, REPLACE_WRITE.
22784         * modules/unistd (Makefile.am): Substitute GNULIB_UNISTD_H_SIGPIPE,
22785         GNULIB_WRITE, REPLACE_WRITE.
22786         * doc/posix-functions/write.texi: Mention the write, sigpipe modules
22787         and the SIGPIPE issue.
22788
22789         * lib/signal.in.h (SIGPIPE): Define to a replacement value.
22790         (raise): New declaration.
22791         * lib/sigprocmask.c (SIGPIPE_handler): New variable.
22792         (ext_signal): New function.
22793         (rpl_raise): New function.
22794         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Initialize
22795         GNULIB_SIGNAL_H_SIGPIPE.
22796         * modules/signal (Makefile.am): Substitute GNULIB_SIGNAL_H_SIGPIPE.
22797         * doc/posix-headers/signal.texi: Mention the SIGPIPE issue.
22798
22799         * modules/sigpipe: New file.
22800         * m4/sigpipe.m4: New file.
22801
22802 2008-09-25  Derek Price  <derek@ximbiot.com>
22803             Bruno Haible  <bruno@clisp.org>
22804
22805         * gnulib-tool (func_import): Report all license incompatibilities, not
22806         just the first one.
22807
22808 2008-09-25  Bruno Haible  <bruno@clisp.org>
22809
22810         * gnulib-tool (func_import): When computing the edits, consider not
22811         only the Makefile.ams that exist but also those that will be generated.
22812
22813 2008-09-25  Simon Josefsson  <simon@josefsson.org>
22814
22815         * modules/sys_select-tests (Depends-on): Remove sys_select itself,
22816         fixes gnulib-tool --test warning about duplicate dependency.
22817
22818 2008-09-25  Bruno Haible  <bruno@clisp.org>
22819
22820         * gnulib-tool: Don't ask the user to perform edits in the generated
22821         Makefile.ams.
22822         (func_emit_lib_Makefile_am): Emit empty SUBDIRS. Execute edits that
22823         apply to the Makefile.am being generated.
22824         (func_emit_tests_Makefile_am): Execute edits that apply to the
22825         Makefile.am being generated.
22826         (func_import): Setup list of Makefile.am edits before emitting the
22827         Makefile.ams, not at the end.
22828         (func_create_testdir): Update.
22829         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
22830
22831 2008-09-25  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
22832
22833         * gnulib-tool (func_import): Store the --tests-base option in the
22834         comment in gnulib-cache.m4.
22835
22836 2008-09-24  Paolo Bonzini  <bonzini@gnu.org>
22837
22838         * NEWS: Document increased portability that sys_select now provides.
22839
22840         * lib/sys_select.in.h: Install select wrapper.
22841         * lib/sys_socket.in.h: Use more descriptive name when there is no
22842         select wrapper.
22843         * lib/winsock-select.c: New.
22844         * m4/sys_select_h.m4: Compile lib/winsock-select.c if WinSock is used.
22845         Require gl_HEADER_SYS_SOCKET.
22846         * modules/sys_select: Depend on alloca, add lib/winsock-select.c.
22847         * modules/sys_select-tests: Copy dependencies from modules/poll-tests.
22848         * tests/test-sys_select.c: Add functional tests.
22849
22850 2008-09-24  Eric Blake  <ebb9@byu.net>
22851
22852         open, fopen: close fd leak in last patch
22853         * lib/open.c (rpl_open): Close fd before returning error.
22854         * lib/fopen.c (rpl_fopen): Close fd before returning error.
22855         * doc/posix-functions/open.texi (open): Document that Irix also
22856         has the bug.
22857         * doc/posix-functions/fopen.texi (fopen): Likewise.
22858         Reported by Paolo Bonzini.
22859
22860 2008-09-24  Bruno Haible  <bruno@clisp.org>
22861
22862         Ensure that a filename ending in a slash cannot be used to access a
22863         non-directory.
22864         * lib/open.c (rpl_open): When the filename ends in a slash, use fstat()
22865         to check whether it's really a directory.
22866         * lib/fopen.c: Include fcntl.h, unistd.h.
22867         (rpl_fopen): When the filename ends in a slash, use open(), fstat(),
22868         and fdopen().
22869         * modules/fopen (Depends-on): Add unistd.
22870         * tests/test-open.c (main): Try to open "/dev/null/" as a directory.
22871         * tests/test-fopen.c (main): Likewise.
22872         * doc/posix-functions/open.texi: Mention the HP-UX, Solaris bug.
22873         * doc/posix-functions/fopen.texi: Likewise.
22874         Reported by Eric Blake.
22875
22876 2008-09-23  Eric Blake  <ebb9@byu.net>
22877
22878         c-stack: avoid compiler optimizations when provoking overflow
22879         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Make
22880         recursion harder to optimize, to ensure a stack overflow occurs.
22881         * tests/test-c-stack.c (recurse): Likewise.
22882         Borrowed from libsigsegv.
22883
22884         c-stack: work around Irix sigaltstack bug
22885         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check
22886         whether sigaltstack uses wrong end of stack_t (copied in part from
22887         libsigsegv).
22888         * lib/c-stack.c (c_stack_action) [!HAVE_LIBSIGSEGV]: Work around
22889         Irix bug, without requiring an over-allocation.
22890         * doc/posix-functions/sigaltstack.texi (sigaltstack): Document the
22891         bug.
22892
22893         fopen: document mingw bug on directories
22894         * doc/posix-functions/fopen.texi (fopen): Mention mingw bug for
22895         not allowing a stream visiting a directory, even though reading
22896         from such a stream is not portable.
22897
22898 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
22899
22900         * lib/poll.c: Rewrite.
22901         * modules/poll: Depend on alloca.
22902
22903 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
22904
22905         * lib/sys_socket.in.h: Do not implement rpl_setsockopt here,
22906         instead define prototypes for a full set of wrappers.  Ensure
22907         that Cygwin does not use the compatibility code, which is only
22908         for MinGW.
22909         * lib/winsock.c: New.
22910         * m4/sys_socket_h.m4: Compile lib/winsock.c if WinSock is being used.
22911         * modules/sys_socket: Add lib/winsock.c.
22912
22913         * modules/poll-tests: Add errno and perror.
22914         * tests/test-poll.c: Use ioctl, not ioctlsocket.
22915
22916 2008-09-23  Paolo Bonzini  <bonzini@gnu.org>
22917
22918         * tests/test-poll.c: Downgrade minimum needed Winsock version.
22919
22920 2008-09-23  Bruno Haible  <bruno@clisp.org>
22921
22922         * doc/posix-functions/*: Add info about functions missing on IRIX 5.3.
22923         * doc/glibc-functions/*: Likewise.
22924
22925 2008-09-23  Simon Josefsson  <simon@josefsson.org>
22926
22927         * tests/test-perror.sh (tmpfiles): Cleanup temporary files on
22928         success.
22929
22930 2008-09-22  Eric Blake  <ebb9@byu.net>
22931             Bruno Haible  <bruno@clisp.org>
22932
22933         vasnprintf: fix x86/glibc regression on printf("%La", 0.0L)
22934         * lib/vasnprintf.c (VASNPRINTF): Support 0.0 on platforms that
22935         supply %A but mishandle pseudo-NaN.
22936         Reported by Simon Josefsson.
22937
22938 2008-09-21  Bruno Haible  <bruno@clisp.org>
22939
22940         * tests/test-lock.c (main): Tweak skip message.
22941         * tests/test-tls.c (main): Likewise.
22942
22943 2008-09-21  Bruno Haible  <bruno@clisp.org>
22944
22945         * m4/sigaction.m4 (gl_SIGACTION): Remove unnecessary AC_SUBST. Check
22946         whether 'struct sigaction' has sa_sigaction here...
22947         (gl_PREREQ_SIG_HANDLER_H): ... not here.
22948         (gl_PREREQ_SIGACTION): Remove unnecessary AC_SUBST.
22949
22950 2008-09-21  Bruno Haible  <bruno@clisp.org>
22951
22952         * MODULES.html.sh (Support for obsolete systems lacking ANSI C 89): New
22953         section.
22954         (Support for systems lacking ANSI C 89): Move stdlib, exit, strtol,
22955         strtoul, memchr, memcmp, memcpy, memmove, memset, strcspn, strpbrk to
22956         the new section.
22957         (Support for obsolete systems lacking POSIX:2001): New section.
22958         (String handling <string.h>): Move strdup to the new section.
22959         Suggested by Simon Josefsson and Paolo Bonzini.
22960
22961 2008-09-21  Bruno Haible  <bruno@clisp.org>
22962
22963         * tests/test-vasnprintf-posix.c (test_function): Allow 3-digit
22964         exponents in %e and %g results on 'long double'. Needed for mingw's
22965         improved *printf functions.
22966         * tests/test-vasprintf-posix.c (test_function): Likewise.
22967         * tests/test-snprintf-posix.h (test_function): Likewise.
22968         * tests/test-sprintf-posix.h (test_function): Likewise.
22969         Reported by Eric Blake.
22970
22971 2008-09-21  Bruno Haible  <bruno@clisp.org>
22972
22973         * tests/test-snprintf-posix.h (test_function): Remove useless ASSERTs.
22974         * tests/test-sprintf-posix.h (test_function): Likewise.
22975
22976 2008-09-21  Bruno Haible  <bruno@clisp.org>
22977
22978         * modules/getpass (Depends-on): Add strdup-posix.
22979
22980         New module 'strdup-posix'.
22981         * modules/strdup-posix: New file.
22982         * m4/strdup.m4 (gl_FUNC_STRDUP_POSIX): New macro.
22983         * lib/string.in.h (strdup): Replace if REPLACE_STRDUP is 1.
22984         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
22985         REPLACE_STRDUP.
22986         * modules/string (Makefile.am): Substitute REPLACE_STRDUP.
22987         * doc/posix-functions/strdup.texi: Mention module strdup-posix.
22988         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
22989         strdup-posix.
22990
22991         * modules/strdup (Depends-on): Remove malloc-posix.
22992
22993 2008-09-20  Bruno Haible  <bruno@clisp.org>
22994
22995         * lib/fstrcmp.c: Add data about branch probabilities, from Ralf
22996         Wildenhues.
22997
22998 2008-09-20  Bruno Haible  <bruno@clisp.org>
22999
23000         Ensure that wint_t gets defined on IRIX 5.3.
23001         * lib/wchar.in.h (wint_t): Define if not defined by the system.
23002         * lib/wctype.in.h (wint_t): Likewise.
23003         (__wctype_wint_t): Remove type.
23004         (isw*): Use wint_t instead of __wctype_wint_t.
23005         * m4/wchar.m4 (gl_WCHAR_H): Invoke gt_TYPE_WINT_T and set HAVE_WINT_T.
23006         * modules/wchar (Files): Add m4/wint_t.m4.
23007         (Makefile.am): Substitute HAVE_WINT_T.
23008         * tests/test-wchar.c: Check that wchar_t and wint_t are defined.
23009         * tests/test-wctype.c: Check that wint_t is defined.
23010         * doc/posix-headers/wchar.texi: Mention the IRIX 5 problem.
23011         * doc/posix-headers/wctype.texi: Likewise.
23012         Reported by Tom G. Christensen <tgc@jupiterrise.com>.
23013
23014 2008-09-18  Bruno Haible  <bruno@clisp.org>
23015
23016         * gnulib-tool (func_exit): Update comment.
23017
23018 2008-09-18  Simon Josefsson  <simon@josefsson.org>
23019
23020         * modules/getaddrinfo (Depends-on): Remove strdup, this module
23021         assumes strdup exists and does not depend on strdup to return
23022         ENOMEM on out of memory conditions.
23023
23024 2008-09-18  Bruno Haible  <bruno@clisp.org>
23025
23026         * lib/vasnprintf.c (VASNPRINTF): When printing ±0.0L in
23027         NEED_PRINTF_INFINITE_LONG_DOUBLE case with 'e' format, always use two
23028         digits for the exponent.
23029
23030 2008-09-18  Jim Meyering  <meyering@redhat.com>
23031             Bruno Haible  <bruno@clisp.org>
23032
23033         * lib/vasnprintf.c (decimal_point_char): Define also if
23034         NEED_PRINTF_INFINITE_LONG_DOUBLE.
23035
23036 2008-09-16  Bruno Haible  <bruno@clisp.org>
23037         and Eric Blake  <ebb9@byu.net>
23038
23039         vasnprintf: support Irix 5.3
23040         * lib/vasnprintf.c (VASNPRINTF): Also handle -0.0L on platforms
23041         that mishandle long double infinity.
23042         Reported by Tom G. Christensen.
23043
23044 2008-09-16  Bruno Haible  <bruno@clisp.org>
23045
23046         * doc/glibc-functions/scandir.texi: Mention the function is missing on
23047         Solaris 9.
23048         * doc/glibc-functions/alphasort.texi: Likewise.
23049         Reported by Michael Haubenwallner <michael.haubenwallner@salomon.at>.
23050
23051 2008-09-16  Jim Meyering  <meyering@redhat.com>
23052
23053         posix-shell.m4: reject opensolaris's "sh (AT&T Research) 1993-12-28 s+"
23054         * m4/posix-shell.m4 (gl_POSIX_SHELL): Reject a shell that lets
23055         a umask modification leak out of a subshell.  Otherwise, the
23056         opensolaris /bin/sh would be accepted and thus cause unwarranted
23057         failures in the coreutils test suite.
23058
23059 2008-09-16  Paolo Bonzini  <bonzini@gnu.org>
23060
23061         * tests/test-poll.c (connect_to_socket): Allow non-blocking connect
23062         to succeed.
23063
23064 2008-09-16  Jim Meyering  <meyering@redhat.com>
23065
23066         avoid spurious test failure when library is built without ACL support
23067         * m4/acl.m4 (USE_ACL): Define as a shell variable, too, for...
23068         * modules/acl-tests (Makefile.am) [TESTS_ENVIRONMENT]: Add USE_ACL.
23069         * tests/test-file-has-acl.sh: Skip if USE_ACL == 0.
23070         * tests/test-copy-acl.sh: Likewise.
23071
23072 2008-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23073
23074         * lib/fstrcmp.c (fstrcmp_bounded): Use a second, less quick upper bound
23075         based on character occurrence counts.
23076
23077 2008-09-15  Eric Blake  <ebb9@byu.net>
23078
23079         tests: avoid some compiler warnings
23080         * tests/test-memchr.c (main): Pass NULL indirectly.
23081         * tests/test-closein.c (main): Avoid unused variable.
23082
23083 2008-09-15  Bruno Haible  <bruno@clisp.org>
23084
23085         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test for all the macros that
23086         are missing on OpenBSD 4.0 individually.
23087         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
23088
23089 2008-09-15  Bruno Haible  <bruno@clisp.org>
23090
23091         * doc/posix-headers/errno.texi: Mention the Cygwin problem.
23092         * doc/posix-functions/strerror.texi: Mention also Cygwin.
23093         * doc/posix-functions/perror.texi: Likewise.
23094         * m4/errno_h.m4 (gl_HEADER_ERRNO_H_BODY): Test also whether ECANCELED
23095         is missing.
23096         Reported by Eric Blake.
23097
23098         * lib/errno.in.h: Use replacement values >= 2000.
23099         Reported by Eric Blake.
23100
23101 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23102
23103         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Add field 'edit_count_limit'.
23104         (EARLY_ABORT): Return true when the edit_count has grown too beyond the
23105         limit.
23106         (fstrcmp_bounded): Initialize the edit_count_limit. Return 0 when
23107         compareseq was aborted.
23108
23109 2008-09-14  Bruno Haible  <bruno@clisp.org>
23110
23111         * lib/fstrcmp.c (EXTRA_CONTEXT_FIELDS): Combine xvec_edit_count and
23112         yvec_edit_count.
23113         (NOTE_DELETE, NOTE_INSERT): Increment the combined edit count.
23114         (fstrcmp_bounded): Simplify result computation accordingly.
23115
23116 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23117
23118         * lib/fstrcmp.h (fstrcmp_bounded): New declaration.
23119         (fstrcmp): Define in terms of fstrcmp_bounded.
23120         * lib/fstrcmp.c (fstrcmp_bounded): Renamed from fstrcmp. Add
23121         lower_bound argument.
23122         Return quickly if the result is certainly < lower_bound.
23123         * tests/test-fstrcmp.c (check_fstrcmp): Test also fstrcmp_bounded.
23124
23125 2008-09-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23126
23127         * lib/diffseq.h (EARLY_ABORT): New macro.
23128         (compareseq): Change return type to bool. Return true when EARLY_ABORT
23129         evaluates to true.
23130
23131 2008-09-14  Bruno Haible  <bruno@clisp.org>
23132
23133         * modules/perror-tests: New file.
23134         * tests/test-perror.sh: New file.
23135         * tests/test-perror.c: New file.
23136
23137         New module 'perror'.
23138         * lib/stdio.in.h (perror): New declaration.
23139         * lib/perror.c: New file.
23140         * m4/perror.m4: New file.
23141         * modules/perror: New file.
23142         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add perror.
23143         * doc/posix-functions/perror.texi: Mention the perror module.
23144         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize GNULIB_PERROR,
23145         REPLACE_PERROR.
23146         * modules/stdio (Makefile.am): Substitute GNULIB_PERROR,
23147         REPLACE_PERROR.
23148
23149 2008-09-14  Bruno Haible  <bruno@clisp.org>
23150
23151         * modules/stdio (Makefile.am): Reorder to match the order in
23152         lib/stdio.in.h.
23153         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
23154
23155 2008-09-13  Bruno Haible  <bruno@clisp.org>
23156
23157         * lib/sys_socket.in.h (EINPROGRESS, ...): Remove definitions.
23158
23159 2008-09-13  Bruno Haible  <bruno@clisp.org>
23160
23161         Extend strerror to cover the added errno values.
23162         * lib/strerror.c: Include errno.h and winsock2.h if it exists.
23163         (rpl_strerror): Provide error messages for the added errno values and
23164         for the WSA* values.
23165         * m4/strerror.m4 (gl_FUNC_STRERROR): Test REPLACE_STRERROR.
23166         (gl_FUNC_STRERROR_SEPARATE): If errno.h is replaced, always replace
23167         strerror.
23168         (gl_PREREQ_STRERROR): Test whether winsock2.h exists.
23169         * modules/strerror (Depends-on): Add errno.
23170         * doc/posix-functions/strerror.texi: Document the change.
23171         * tests/test-strerror.c (main): Check also the string for ETIMEDOUT
23172         and EOVERFLOW.
23173
23174 2008-09-13  Bruno Haible  <bruno@clisp.org>
23175
23176         * modules/EOVERFLOW: Remove file.
23177         * m4/eoverflow.m4: Remove file.
23178         * modules/EOVERFLOW-tests: Remove file.
23179         * tests/test-EOVERFLOW.c: Remove file.
23180         * modules/fprintf-posix (Depends-on): Replace EOVERFLOW with errno.
23181         * modules/ftell (Depends-on): Likewise.
23182         * modules/getdelim (Depends-on): Likewise.
23183         * modules/getugroups (Depends-on): Likewise.
23184         * modules/poll (Depends-on): Likewise.
23185         * modules/snprintf (Depends-on): Likewise.
23186         * modules/sprintf-posix (Depends-on): Likewise.
23187         * modules/vasnprintf (Depends-on): Likewise.
23188         * modules/vasprintf (Depends-on): Likewise.
23189         * modules/vfprintf-posix (Depends-on): Likewise.
23190         * modules/vsnprintf (Depends-on): Likewise.
23191         * modules/vsprintf-posix (Depends-on): Likewise.
23192         * modules/xvasprintf (Depends-on): Likewise.
23193         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
23194         * modules/unistdio/u8-vasprintf (Depends-on): Likewise.
23195         * modules/unistdio/u8-vsnprintf (Depends-on): Likewise.
23196         * modules/unistdio/u8-vsprintf (Depends-on): Likewise.
23197         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
23198         * modules/unistdio/u8-u8-vasprintf (Depends-on): Likewise.
23199         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Likewise.
23200         * modules/unistdio/u8-u8-vsprintf (Depends-on): Likewise.
23201         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
23202         * modules/unistdio/u16-u16-vasprintf (Depends-on): Likewise.
23203         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Likewise.
23204         * modules/unistdio/u16-u16-vsprintf (Depends-on): Likewise.
23205         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
23206         * modules/unistdio/u16-vasprintf (Depends-on): Likewise.
23207         * modules/unistdio/u16-vsnprintf (Depends-on): Likewise.
23208         * modules/unistdio/u16-vsprintf (Depends-on): Likewise.
23209         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
23210         * modules/unistdio/u32-vasprintf (Depends-on): Likewise.
23211         * modules/unistdio/u32-vsnprintf (Depends-on): Likewise.
23212         * modules/unistdio/u32-vsprintf (Depends-on): Likewise.
23213         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
23214         * modules/unistdio/u32-u32-vasprintf (Depends-on): Likewise.
23215         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Likewise.
23216         * modules/unistdio/u32-u32-vsprintf (Depends-on): Likewise.
23217         * modules/unistdio/ulc-fprintf (Depends-on): Likewise.
23218         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
23219         * modules/unistdio/ulc-vasprintf (Depends-on): Likewise.
23220         * modules/unistdio/ulc-vfprintf (Depends-on): Likewise.
23221         * modules/unistdio/ulc-vsnprintf (Depends-on): Likewise.
23222         * modules/unistdio/ulc-vsprintf (Depends-on): Likewise.
23223         * MODULES.html.sh: Remove EOVERFLOW.
23224         * NEWS: Mention the change.
23225
23226 2008-09-13  Bruno Haible  <bruno@clisp.org>
23227
23228         * modules/errno-tests: New file.
23229         * tests/test-errno.c: New file, incorporating tests/test-EOVERFLOW.c.
23230
23231         * lib/errno.in.h: New file.
23232         * m4/errno_h.m4: New file, borrowing from m4/eoverflow.m4.
23233         * modules/errno: New file.
23234         * doc/posix-headers/errno.texi: Update documentation.
23235         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add errno.
23236
23237 2008-09-13  Bruno Haible  <bruno@clisp.org>
23238
23239         * tests/test-poll.c: Use #if for native Windows, rather than testing
23240         __MSVCRT__.
23241
23242 2008-09-13  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23243             Bruno Haible  <bruno@clisp.org>
23244
23245         * lib/glob.c: Don't include <pwd.h> on native Windows.
23246         (WINDOWS32): New macro.
23247         (glob) [WINDOW32]: Provide a reasonable replacement for getenv("HOME").
23248
23249 2008-09-13  Bruno Haible  <bruno@clisp.org>
23250
23251         * lib/glthread/cond.h [USE_SOLARIS_THREADS]
23252         (ETIMEDOUT): Remove macro.
23253         (glthread_cond_timedwait_multithreaded): New declaration.
23254         (glthread_cond_timedwait): Use it.
23255         * lib/glthread/cond.c [USE_SOLARIS_THREADS]
23256         (glthread_cond_timedwait_multithreaded): New function.
23257
23258 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
23259
23260         * modules/poll-tests: Do not check for io.h.
23261         * tests/test-poll.c: Check for __MSVCRT__ instead.
23262
23263 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
23264
23265         * lib/sys_socket.in.h (EINPROGRESS): Define for Winsock case.
23266         * modules/poll-tests: Add inet_pton, stdbool, sockets.
23267         * tests/test-poll.c: Use them.  Use _pipe on Windows.
23268
23269 2008-09-12  Paolo Bonzini  <bonzini@gnu.org>
23270
23271         * modules/poll-tests: New.
23272         * tests/test-poll.c: New.
23273
23274 2008-09-12  Eric Blake  <ebb9@byu.net>
23275
23276         frexp: test for NetBSD failure on -0.0
23277         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Enhance test, since some, but
23278         not all, bugs from NetBSD 3.0 have been fixed.
23279         * doc/posix-functions/frexp.texi (frexp): Document bug.
23280         Reported by Thomas Klausner.
23281
23282         signbit: work around bug of HP-UX 10.20 cc with -0.0 literal
23283         * m4/signbit.m4 (gl_SIGNBIT_TEST_PROGRAM): Rewrite test to avoid
23284         literal -0.0.
23285         Reported by Jonathan C. Patschke <jp@centtech.com>.
23286
23287 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23288
23289         * lib/glthread/cond.h: Use dummy implementation also if
23290         USE_WIN32_THREADS.
23291
23292 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23293
23294         * modules/fnmatch-posix (License): Change to LGPLv2+.
23295         * modules/fnmatch-gnu (License): Likewise.
23296
23297 2008-09-11  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23298
23299         * lib/poll.c (poll): Fix polling unconnected server sockets on WIN32.
23300
23301 2008-09-11  Jim Meyering  <meyering@redhat.com>
23302
23303         * users.txt: Add gtk-vnc.
23304
23305 2008-09-08  Simon Josefsson  <simon@josefsson.org>
23306
23307         * tests/test-bitrotate.c: Test 8/16-bit rotates with 0 and maximum
23308         rotate amounts.
23309
23310         * lib/bitrotate.h: Doc fix, mention that N can be wider than minimally
23311         required for 16-bit and 8-bit rotates.
23312         * lib/bitrotate.h (rotl64, rotr64, rotl32, rotl32, rotl16, rotr16,
23313         rotl8, rotr8): Use UINT64_MAX, UINT32_MAX, UINT16_MAX, and
23314         UINT8_MAX instead of hard-coded constants.
23315         Suggested by Paul Eggert.
23316
23317 2008-09-07  Bruno Haible  <bruno@clisp.org>
23318
23319         * tests/test-striconveh.c (main): Check behaviour when converting from
23320         UTF-7.
23321
23322         Make striconveh work better with stateful encodings.
23323         * lib/striconveh.c (iconv_carefully, iconv_carefully_1): Don't assume
23324         that iconv does not increment the inptr when returning -1/EINVAL.
23325
23326 2008-09-07  Bruno Haible  <bruno@clisp.org>
23327
23328         * build-aux/config.rpath: Update according to libtool-2.2.6.
23329         * build-aux/config.libpath: Likewise.
23330
23331 2008-09-06  Bruno Haible  <bruno@clisp.org>
23332
23333         * lib/freadahead.c (freadahead): Add conditional for SLOW_BUT_NO_HACKS.
23334         * lib/freadptr.c (freadptr): Likewise.
23335         * lib/freadseek.c (freadptrinc): Likewise.
23336         Reported by Simon Josefsson.
23337
23338 2008-09-06  Bruno Haible  <bruno@clisp.org>
23339
23340         * modules/freadptr (License): Change to LGPLv2+.
23341         * modules/freadseek (License): Likewise.
23342         Suggested by Eric Blake.
23343
23344         * modules/memchr2 (License): Change to LGPLv2+.
23345         Approved by Eric Blake.
23346
23347 2008-09-04  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
23348             Bruno Haible  <bruno@clisp.org>
23349
23350         Make gnulib-tool work with native 'sed' on AIX.
23351         * gnulib-tool (sed_noop): New variable.
23352         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am, func_import,
23353         func_add_or_update, func_create_testdir): Use it to initialize sed
23354         script variables.
23355         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
23356
23357 2008-09-04  Albert Chin  <bug-gnulib@mlists.thewrittenword.com>
23358             Bruno Haible  <bruno@clisp.org>
23359
23360         * m4/include_next.m4 (gl_INCLUDE_NEXT): Add check whether #include_next
23361         also works after #include directives.
23362
23363 2008-09-04  Ondřej Vašík  <ovasik@redhat.com>
23364
23365         getdate.y: reject an out-of-range timezone value
23366         * lib/getdate.y (time_zone_hhmm): Reject any TZ offset that is outside
23367         the range [-24...+24].  When specified with only one or two digits,
23368         * tests/test-getdate.c: Tests for the fix.
23369         * doc/getdate.texi: Document this change.
23370
23371 2008-09-03  Bruno Haible  <bruno@clisp.org>
23372
23373         * doc/glibc-functions/strverscmp.texi: Mention the strverscmp module.
23374
23375 2008-09-02  Simon Josefsson  <simon@josefsson.org>
23376
23377         * lib/bitrotate.h (rotl64, rotr64): Add.  Suggested by Bruce Korb
23378         <bruce.korb@gmail.com> with ideas from Ben Pfaff
23379         <blp@cs.stanford.edu>, Bruno Haible <bruno@clisp.org> and Eric
23380         Blake <ebb9@byu.net>.
23381
23382         * tests/test-bitrotate.c: Add more test vectors.
23383
23384 2008-09-02  Eric Blake  <ebb9@byu.net>
23385
23386         vasnprintf-posix: handle large precision via %.*d
23387         * lib/vasnprintf.c (VASNPRINTF): Don't pass precision to snprintf
23388         when handling it ourselves.
23389         * tests/test-vasnprintf-posix.c (test_function): Add test.
23390         * tests/test-snprintf-posix.h (test_function): Likewise.
23391         * tests/test-sprintf-posix.h (test_function): Likewise.
23392         * tests/test-vasprintf-posix.c (test_function): Likewise.
23393         Reported by Alain Guibert.
23394
23395 2008-09-01  Eric Blake  <ebb9@byu.net>
23396
23397         c-stack: make configure-time check more robust
23398         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Check for
23399         successful sigaction call.
23400         Reported by Tom G. Christensen.
23401
23402 2008-09-01  Bruno Haible  <bruno@clisp.org>
23403
23404         New module 'findprog-lgpl'.
23405         * modules/findprog-lgpl: New file.
23406         * lib/findprog-lgpl.c: New file.
23407         * lib/findprog.c: Compile nothing in findprog.c if findprog-lgpl.c is
23408         also compiled. Consider the possibly defined symbol IN_FINDPROG_LGPL
23409         to decide whether to use strdup or xstrdup, concatenated_filename or
23410         xconcatenated_filename.
23411
23412 2008-09-01  Bruno Haible  <bruno@clisp.org>
23413
23414         Split module 'concat-filename' into 'concat-filename' (LGPL) and
23415         'xconcat-filename' (GPL).
23416         * modules/concat-filename (Depends-on): Add malloc-posix, remove xalloc.
23417         (License): Change to LGPLv2+.
23418         * modules/xconcat-filename: New file.
23419         * lib/concat-filename.h (concatenated_filename): Change specification.
23420         (xconcatenated_filename): New declaration.
23421         * lib/concat-filename.c: Include errno.h, stdlib.h, not xalloc.h.
23422         (concatenated_filename): Use malloc instead of xalloc. Handle out-of-
23423         memory situations.
23424         * lib/xconcat-filename.c: New file.
23425         * NEWS: Mention the change.
23426         * lib/findprog.c: Include concat-filename.h, not filename.h.
23427         (find_in_path): Use xconcatenated_filename instead of
23428         concatenated_filename.
23429         * lib/javacomp.c: Include concat-filename.h, not filename.h.
23430         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
23431         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
23432         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
23433         is_oldgcj_14_13_usable, is_javac_usable): Use xconcatenated_filename
23434         instead of concatenated_filename.
23435         * lib/javaexec.c: Include concat-filename.h, not filename.h.
23436         (execute_java_class): Use xconcatenated_filename instead of
23437         concatenated_filename.
23438         * modules/findprog (Depends-on): Add xconcat-filename, remove filename.
23439         * modules/javacomp (Depends-on): Likewise.
23440         * modules/javaexec (Depends-on): Likewise.
23441
23442 2008-09-01  Bruno Haible  <bruno@clisp.org>
23443
23444         Split module 'filename' into 'filename' and 'concat-filename'.
23445         * modules/filename: Keep only lib/filename.h.
23446         (License): Change to LGPLv2+.
23447         * modules/concat-filename: New file, extracted from modules/filename.
23448         * lib/filename.h (concatenated_filename): Remove declaration.
23449         * lib/concat-filename.h: New file, extracted from lib/filename.h.
23450         * lib/concat-filename.c: Include concat-filename.h.
23451         * NEWS: Mention the change.
23452
23453 2008-09-01  Simon Josefsson  <simon@josefsson.org>
23454
23455         * lib/bitrotate.h (rotl8, rotr8): Add.
23456
23457         * modules/bitrotate (configure.ac): Need
23458         AC_REQUIRE([AC_C_INLINE]).
23459         (Description): Mention stdint.h.  Reported by Bruno Haible
23460         <bruno@clisp.org>.
23461
23462         * lib/bitrotate.h (rotr16, rotl16): Fix mask value.  Reported by
23463         Paolo Bonzini <bonzini@gnu.org>.
23464
23465 2008-08-31  Bruno Haible  <bruno@clisp.org>
23466
23467         Assume Solaris specific bi-arch conventions on Solaris systems.
23468         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): On Solaris in 64-bit
23469         mode, set acl_libdirstem to lib/64. Also set acl_libdirstem2.
23470         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): If acl_libdirstem does not
23471         work, try acl_libdirstem2 as fallback. Otherwise treat acl_libdirstem2
23472         like acl_libdirstem.
23473         (AC_LIB_LINKFLAGS_FROM_LIBS): Treat acl_libdirstem2 like
23474         acl_libdirstem.
23475         * NEWS: Mention the change.
23476         Reported by Ben Taylor <bentaylor.solx86@gmail.com>.
23477
23478 2008-08-31  Jim Meyering  <meyering@redhat.com>
23479
23480         * lib/strftime.h: Add comments describing the two added arguments.
23481
23482         remove duplicate #include directives
23483         * lib/chdir-long.c [TEST_CHDIR]: Remove duplicate #include <stdio.h>.
23484         * lib/putenv.c: Remove duplicate #include <stdlib.h>.
23485
23486 2008-08-31  Bruno Haible  <bruno@clisp.org>
23487
23488         New module 'sigpipe-die'.
23489         * modules/sigpipe-die: New file.
23490         * lib/sigpipe-die.h: New file.
23491         * lib/sigpipe-die.c: New file.
23492         * MODULES.html.sh (Signal handling): Add sigpipe-die.
23493
23494 2008-08-31  Bruno Haible  <bruno@clisp.org>
23495
23496         Don't override previously installed signal handlers.
23497         * lib/fatal-signal.c (saved_sigactions): New variable.
23498         (uninstall_handlers): Reset the signal to the saved handler, not
23499         to SIG_DFL (except when ignored).
23500         (install_handlers): Save the previous handlers.
23501
23502 2008-08-30  Bruno Haible  <bruno@clisp.org>
23503
23504         * gnulib-tool (func_reset_sigpipe): New function.
23505         (func_get_automake_snippet, func_modules_transitive_closure,
23506         func_import): Invoke it before a join command that reads from stdin,
23507         to avoid "echo: write error: Broken pipe" error messages on stderr.
23508         Reported by Sam Steingold <sds@gnu.org>.
23509
23510 2008-08-30  Bruno Haible  <bruno@clisp.org>
23511
23512         * m4/fopen.m4 (gl_FUNC_FOPEN): Test against bug with trailing slash.
23513         Code copied from m4/open.m4.
23514         * lib/fopen.c (rpl_fopen): Return NULL if the mode specifies write
23515         access and the filename ends in a slash. Code copied from lib/open.c.
23516         * doc/posix-functions/fopen.texi: Document bug with trailing slash.
23517         * tests/test-fopen.c (main): Check against bug with trailing slash.
23518
23519 2008-08-29  Bruno Haible  <bruno@clisp.org>
23520
23521         Avoid some "gcc -pedantic" warnings.
23522         * m4/include_next.m4 (gl_INCLUDE_NEXT): Set also PRAGMA_SYSTEM_HEADER.
23523         * lib/arpa_inet.in.h: Use PRAGMA_SYSTEM_HEADER.
23524         * lib/dirent.in.h: Likewise.
23525         * lib/fcntl.in.h: Likewise.
23526         * lib/float.in.h: Likewise.
23527         * lib/iconv.in.h: Likewise.
23528         * lib/inttypes.in.h: Likewise.
23529         * lib/locale.in.h: Likewise.
23530         * lib/math.in.h: Likewise.
23531         * lib/netinet_in.in.h: Likewise.
23532         * lib/search.in.h: Likewise.
23533         * lib/signal.in.h: Likewise.
23534         * lib/stdarg.in.h: Likewise.
23535         * lib/stdint.in.h: Likewise.
23536         * lib/stdio.in.h: Likewise.
23537         * lib/stdlib.in.h: Likewise.
23538         * lib/string.in.h: Likewise.
23539         * lib/strings.in.h: Likewise.
23540         * lib/sys_select.in.h: Likewise.
23541         * lib/sys_socket.in.h: Likewise.
23542         * lib/sys_stat.in.h: Likewise.
23543         * lib/sys_time.in.h: Likewise.
23544         * lib/sysexits.in.h: Likewise.
23545         * lib/time.in.h: Likewise.
23546         * lib/unistd.in.h: Likewise.
23547         * lib/wchar.in.h: Likewise.
23548         * lib/wctype.in.h: Likewise.
23549         * modules/arpa_inet (Makefile.am): Also substitute PRAGMA_SYSTEM_HEADER.
23550         * modules/fchdir (Makefile.am): Likewise.
23551         * modules/fcntl (Makefile.am): Likewise.
23552         * modules/float (Makefile.am): Likewise.
23553         * modules/iconv_open (Makefile.am): Likewise.
23554         * modules/inttypes (Makefile.am): Likewise.
23555         * modules/locale (Makefile.am): Likewise.
23556         * modules/math (Makefile.am): Likewise.
23557         * modules/netinet_in (Makefile.am): Likewise.
23558         * modules/search (Makefile.am): Likewise.
23559         * modules/signal (Makefile.am): Likewise.
23560         * modules/stdarg (Makefile.am): Likewise.
23561         * modules/stdint (Makefile.am): Likewise.
23562         * modules/stdio (Makefile.am): Likewise.
23563         * modules/stdlib (Makefile.am): Likewise.
23564         * modules/string (Makefile.am): Likewise.
23565         * modules/strings (Makefile.am): Likewise.
23566         * modules/sys_select (Makefile.am): Likewise.
23567         * modules/sys_socket (Makefile.am): Likewise.
23568         * modules/sys_stat (Makefile.am): Likewise.
23569         * modules/sys_time (Makefile.am): Likewise.
23570         * modules/sysexits (Makefile.am): Likewise.
23571         * modules/time (Makefile.am): Likewise.
23572         * modules/unistd (Makefile.am): Likewise.
23573         * modules/wchar (Makefile.am): Likewise.
23574         * modules/wctype (Makefile.am): Likewise.
23575         Reported by Reuben Thomas <rrt@sc3d.org>.
23576
23577 2008-08-29  Bruno Haible  <bruno@clisp.org>
23578
23579         * m4/include_next.m4 (gl_INCLUDE_NEXT): Don't define HAVE_INCLUDE_NEXT
23580         any more.
23581
23582 2008-08-29  Simon Josefsson  <simon@josefsson.org>
23583
23584         * MODULES.html.sh (Misc): Add bitrotate.
23585
23586         * modules/bitrotate: New file.
23587
23588         * lib/bitrotate.h: New file.
23589
23590         * modules/bitrotate-tests: New file.
23591
23592         * tests/test-bitrotate.c: New file.
23593
23594         * modules/crypto/gc-arctwo, modules/crypto/arctwo: Add dependency
23595         on the bitrotate module.
23596
23597         * lib/arctwo.c: Use new bitrotate module.
23598
23599 2008-08-29  Jim Meyering  <meyering@redhat.com>
23600
23601         bootstrap: merge changes from coreutils
23602         * build-aux/bootstrap (cp_mark_as_generated): Preserve perms
23603         of copied files.  Remove a kludge, now that this is fixed.
23604         * build-aux/bootstrap: Fix unportable expr usage. (by Ralf Wildenhues)
23605         * build-aux/bootstrap: Remove $bt and $bt2 also when not using gettext.
23606         * build-aux/bootstrap: Remove coreutils-specific SUBDIRS-related code.
23607
23608 2008-08-29  Bruno Haible  <bruno@clisp.org>
23609
23610         * MODULES.html.sh: Remove --cvs-urls option.
23611
23612 2008-08-28  Jose E. Marchesi  <jemarch@gnu.org>  (tiny change)
23613
23614         maint.mk: adjust to file name change
23615         * top/maint.mk: s/Makefile.cfg/cfg.mk/.
23616
23617 2008-08-28  Jim Meyering  <meyering@redhat.com>
23618
23619         * modules/getndelim2 (License): Relicense to LGPLv2+.
23620         Approved by Richard Stallman for the version of 1995, and by
23621         Paul Eggert, Bruno Haible, Eric Blake for their contributions.
23622
23623 2008-08-27  Paolo Bonzini  <bonzini@gnu.org>
23624
23625         * lib/getdelim.c (flockfile, funlockfile): Make all of them
23626         dummy if one is not available.  Do not touch them if
23627         USE_UNLOCKED_IO, instead letting unlocked-io.h do that.
23628         (getc_maybe_unlocked): New.
23629         * m4/getdelim.m4 (gl_PREREQ_GETDELIM): Check for getc_unlocked.
23630
23631 2008-08-26  Eric Blake  <ebb9@byu.net>
23632
23633         doc/INSTALL: resync from autoconf
23634         * doc/Makefile (INSTALL, INSTALL.ISO, INSTALL.UTF-8): Simplify.
23635         (INSTALL_PRELUDE): Delete; this is done more efficiently by
23636         moving...
23637         * install.texi [!autoconf]: ...here.  Resync from autoconf.
23638         * INSTALL: Regenerate.
23639         * INSTALL.ISO: New file.
23640         * INSTALL.UTF-8: Likewise.
23641
23642 2008-08-26  Jim Meyering  <meyering@redhat.com>
23643
23644         GNUmakefile: cfg.mk definitions override default autoreconf-rerun policy
23645         * top/GNUmakefile (_is-dist-target, _is-install-target): Make
23646         these definitions conditional, so that they may be overridden, too.
23647
23648 2008-08-26  Bruno Haible  <bruno@clisp.org>
23649
23650         Generate INSTALL file variants with prettier quotes.
23651         * doc/Makefile (INSTALL_PRELUDE): New macro.
23652         (INSTALL): Use it.
23653         (INSTALL.ISO, INSTALL.UTF-8): New rules.
23654
23655 2008-08-26  Bruno Haible  <bruno@clisp.org>
23656
23657         Run makeinfo in an English locale.
23658         * doc/Makefile (MAKEINFO): New variable.
23659
23660 2008-08-26  Bruno Haible  <bruno@clisp.org>
23661
23662         * doc/Makefile (INSTALL): Use --no-validate instead of --no-warn.
23663         Suggested by Eric Blake.
23664
23665 2008-08-25  Bruno Haible  <bruno@clisp.org>
23666
23667         * doc/Makefile (INSTALL): Generate with @firstparagraphindent set.
23668
23669 2008-08-25  Eric Blake  <ebb9@byu.net>
23670
23671         c-stack: test that stack overflow can be caught
23672         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Also check
23673         that platform allows handling stack overflow; at least OS/2 EMX
23674         has sigaltstack, but crashes before transferring control to
23675         handler on stack overflow.
23676         * lib/c-stack.c [HAVE_SIGALTSTACK]: Adjust conditions to also
23677         check for HAVE_STACK_OVERFLOW_HANDLING.
23678         Reported by Elbert Pol.
23679
23680 2008-08-25  Bruno Haible  <bruno@clisp.org>
23681
23682         * doc/posix-functions/strftime.texi: Fix description of strftime
23683         module.
23684
23685 2008-08-24  Bruno Haible  <bruno@clisp.org>
23686
23687         * tests/uniwidth/test-uc_width2.c: New file.
23688         * tests/uniwidth/test-uc_width2.sh: New file.
23689         * modules/uniwidth/width-tests (Files): Add the new files.
23690         (TESTS): Add uniwidth/test-uc_width2.sh.
23691         (TESTS_ENVIRONMENT): New variable.
23692         (check_PROGRAMS): Add test-uc_width2.
23693         (test_uc_width2_SOURCES): New variable.
23694
23695         Fix uc_width(0x00AB) bug, introduced on 2007-07-08.
23696         * lib/uniwidth/width.c (nonspacing_table_data): Set bit for 0x00AD,
23697         not 0x00AB.
23698         Reported by Alexander V. Lukyanov <lav@netis.ru>.
23699
23700 2008-08-22  Eric Blake  <ebb9@byu.net>
23701
23702         test-lock, test-tls: mention why a test is skipped
23703         * tests/test-lock.c (main) [!USE_*_THREADS]: Print why test is
23704         skipped.
23705         * tests/test-tls.c (main) [!USE_*_THREADS]: Likewise.
23706
23707         count-one-bits: relax license
23708         * modules/count-one-bits (License): Relicense to LGPLv2+.
23709         Suggested by Ludovic Courtès, approved by Ben Pfaff.
23710
23711 2008-08-22  Andreas Schwab  <schwab@suse.de>
23712
23713         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX):
23714         Remove spurious space in assignment.
23715
23716 2008-08-21  Simon Josefsson  <simon@josefsson.org>
23717
23718         * m4/autobuild.m4: Use TZ=UTC0 instead of TZ=UTC.  Reported by
23719         Paul Eggert <eggert@CS.UCLA.EDU>.
23720
23721 2008-08-20  Paolo Bonzini  <bonzini@gnu.org>
23722
23723         * modules/gettext: Add m4/threadlib.m4.
23724
23725 2008-08-19  Eric Blake  <ebb9@byu.net>
23726
23727         test-c-stack: fix compilation failure on FreeBSD 5.0
23728         * tests/test-c-stack.c [HAVE_SETRLIMIT]: Include prerequisite
23729         headers before <sys/resource.h>.
23730         * doc/posix-headers/sys_resource.texi (sys/resource.h): Document
23731         the bug.
23732         Reported by Nelson H. F. Beebe.
23733
23734         strverscmp: migrate from "strverscmp.h" to <string.h>
23735         * modules/string (Makefile.am): Add new hooks.
23736         * modules/strverscmp (Files): Remove strverscmp.h.
23737         (Depends-on): Add string.
23738         (configure.ac): Add indicator.
23739         (Include): Mention new header.
23740         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Provide new
23741         defaults.
23742         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Inform string module of
23743         results.
23744         * lib/strverscmp.h: Delete.
23745         * lib/string.in.h (strverscmp): Provide declaration, when needed.
23746         * tests/test-strverscmp.c (includes): Adjust client.
23747         * lib/check-version.c (includes): Likewise.
23748         * NEWS: Document the change.
23749
23750         strverscmp: add unit test
23751         * modules/strverscmp-tests: New file.
23752         * tests/test-strverscmp.c: Likewise.
23753
23754 2008-08-19  Simon Josefsson  <simon@josefsson.org>
23755
23756         * lib/gc-gnulib.c: Indentation cleanup.  Add some comments
23757         regarding Windows crypto stuff, from Mono.
23758
23759 2008-08-19  Adam Strzelecki <ono@java.pl>  (tiny change)
23760
23761         * lib/gc-gnulib.c: Use CRYPT_VERIFY_CONTEXT.  Try to use Intel CSP
23762         if present, for intel RND.  Return error on failures.
23763
23764 2008-08-18  Ben Pfaff  <blp@gnu.org>
23765
23766         gitlog-to-changelog: give better diagnostic for failed pipe-open
23767         * build-aux/gitlog-to-changelog: Improve error message: suggest
23768         that the version of Git may be too old.
23769
23770 2008-08-18  Simon Josefsson  <simon@josefsson.org>
23771
23772         * m4/autobuild.m4: Use TZ=UTC to avoid time zone complexity.  Use
23773         ISO 8601 format.  Suggested by Greg Troxel <gdt@ir.bbn.com>.
23774
23775 2008-08-18  Bruno Haible  <bruno@clisp.org>
23776
23777         * lib/glthread/thread.h [USE_SOLARIS_THREADS]: Use thread_in_use(), not
23778         pthread_in_use().
23779
23780 2008-08-18  Bruno Haible  <bruno@clisp.org>
23781
23782         * lib/glthread/threadlib.c: Include <pthread.h>.
23783
23784 2008-08-18  Bruno Haible  <bruno@clisp.org>
23785
23786         * lib/glthread/lock.h [USE_SOLARIS_THREADS]: Fix
23787         glthread_recursive_lock_* macros.
23788         * lib/glthread/lock.c (glthread_recursive_lock_destroy_multithreaded):
23789         Fix syntax error.
23790
23791 2008-08-18  Bruno Haible  <bruno@clisp.org>
23792
23793         * lib/glthread/thread.c: Avoid forcing a context switch right after
23794         thread creation.
23795
23796 2008-08-17  Bruno Haible  <bruno@clisp.org>
23797
23798         * lib/glthread/thread.c: New file, based on code from tests/test-lock.c.
23799         * lib/glthread/thread.h: Provide Win32 specific implementation.
23800         * modules/thread (Files): Add lib/glthread/thread.c.
23801         (Depends-on): Add lock.
23802         (Makefile.am): Add glthread/thread.c to lib_SOURCES.
23803
23804 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23805
23806         New module 'yield'.
23807         * modules/yield: New file.
23808         * lib/glthread/yield.h: New file.
23809         * m4/yield.m4: New file.
23810         * MODULES.html.sh (Multithreading): Add yield.
23811
23812 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23813
23814         New module 'thread'.
23815         * modules/thread: New file.
23816         * lib/glthread/thread.h: New file.
23817         * m4/thread.m4: New file.
23818         * MODULES.html.sh (Multithreading): Add thread.
23819
23820 2008-08-17  Bruno Haible  <bruno@clisp.org>
23821
23822         * lib/glthread/lock.h: Include <stdlib.h> always.
23823         * lib/glthread/tls.h: Likewise.
23824         * lib/glthread/cond.h: Likewise.
23825
23826 2008-08-17  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
23827
23828         New module 'cond'.
23829         * modules/cond: New file.
23830         * lib/glthread/cond.h: New file.
23831         * lib/glthread/cond.c: New file.
23832         * m4/cond.m4: New file.
23833         * MODULES.html.sh (Multithreading): Add cond.
23834
23835 2008-08-16  Eric Blake  <ebb9@byu.net>
23836
23837         c-stack: fix regression on Irix 5.3 from 2008-06-21
23838         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Move check for
23839         sa_sigaction...
23840         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): ...here.
23841         (gl_PREREQ_SIGACTION): Depend on sig-handler.h prereq's.
23842         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Set the default.
23843         * modules/signal (Makefile.am): Use the value.
23844         * lib/signal.in.h (sa_sigaction) [HAVE_SIGACTION
23845         && !HAVE_STRUCT_SIGACTION_SA_SIGACTION]: Define.
23846         * doc/posix-headers/signal.texi (signal.h): Document this
23847         portability issue.
23848         * doc/posix-functions/sigaction.texi (sigaction): Likewise.
23849         Reported by Tom G. Christensen.
23850
23851 2008-08-17  Bruno Haible  <bruno@clisp.org>
23852
23853         New module 'threadlib'.
23854         * modules/threadlib: New file.
23855         * lib/glthread/threadlib.c: New file, extracted from
23856         lib/glthread/lock.c.
23857         * lib/glthread/lock.c (dummy_thread_func, glthread_in_use): Remove
23858         functions.
23859         * m4/threadlib.m4: New file, from m4/lock.m4, renaming gl_LOCK to
23860         gl_THREADLIB and gl_LOCK_EARLY to gl_THREADLIB_EARLY.
23861         * m4/lock.m4 (gl_LOCK_EARLY, gl_LOCK_EARLY_BODY, gl_LOCK_BODY): Remove
23862         macros.
23863         (gl_LOCK): Just require gl_THREADLIB and perform checks for lock.h.
23864         (gl_DISABLE_THREADS): Remove macro.
23865         * modules/lock (Files): Remove build-aux/config.rpath.
23866         (Depends-on): Remove havelib. Add threadlib.
23867         (configure.ac-early): Remove section.
23868         * m4/tls.m4 (gl_TLS): Require gl_THREADLIB instead of gl_LOCK.
23869         * modules/tls (Depends-on): Remove lock. Add threadlib.
23870         (Link): New section, copied from threadlib.
23871         * MODULES.html.sh (Multithreading): Add threadlib.
23872
23873 2008-08-14  Bruno Haible  <bruno@clisp.org>
23874
23875         * lib/glthread/lock.h (glthread_lock_lock, glthread_lock_unlock,
23876         glthread_lock_destroy, glthread_rwlock_rdlock, glthread_rwlock_wrlock,
23877         glthread_rwlock_unlock, glthread_rwlock_destroy,
23878         glthread_recursive_lock_lock, glthread_recursive_lock_unlock,
23879         glthread_recursive_lock_destroy): Define as macros always.
23880         * lib/glthread/lock.c (glthread_lock_lock_func): Renamed from
23881         glthread_lock_lock.
23882         (glthread_lock_unlock_func): Renamed from glthread_lock_unlock.
23883         (glthread_lock_destroy_func): Renamed from glthread_lock_destroy.
23884         (glthread_rwlock_rdlock_func): Renamed from glthread_rwlock_rdlock.
23885         (glthread_rwlock_wrlock_func): Renamed from glthread_rwlock_wrlock.
23886         (glthread_rwlock_unlock_func): Renamed from glthread_rwlock_unlock.
23887         (glthread_rwlock_destroy_func): Renamed from glthread_rwlock_destroy.
23888         (glthread_recursive_lock_lock_func): Renamed from
23889         glthread_recursive_lock_lock.
23890         (glthread_recursive_lock_unlock_func): Renamed from
23891         glthread_recursive_lock_unlock.
23892         (glthread_recursive_lock_destroy_func): Renamed from
23893         glthread_recursive_lock_destroy.
23894
23895 2008-08-14  Bruno Haible  <bruno@clisp.org>
23896
23897         * lib/glthread/lock.h: Renamed from lib/lock.h.
23898         * lib/glthread/lock.c: Renamed from lib/lock.c. Update includes.
23899         * lib/glthread/tls.h: Renamed from lib/tls.h.
23900         * lib/glthread/tls.c: Renamed from lib/tls.c. Update includes.
23901         * lib/fstrcmp.c: Update includes.
23902         * lib/strsignal.c: Update includes.
23903         * modules/lock (Files, Makefile.am): Update.
23904         (Include): Change to "glthread/lock.h".
23905         * modules/tls (Files, Makefile.am): Update.
23906         (Include): Change to "glthread/tls.h".
23907         * tests/test-lock.c: Update includes.
23908         * tests/test-tls.c: Update includes.
23909         * NEWS: Mention the renamed header files.
23910
23911 2008-08-11  Jim Meyering  <meyering@redhat.com>
23912
23913         * lib/fts_.h: Fix grammar (insert a missing "is") in a comment.
23914
23915 2008-08-11  Eric Blake  <ebb9@byu.net>
23916
23917         test-c-stack: avoid C99-ism
23918         * tests/test-c-stack.c (main): Fix whitespace, move declaration
23919         before statement.
23920         Reported by Alain Guibert.
23921
23922 2008-08-10  Jim Meyering  <meyering@redhat.com>
23923
23924         ensure that return value of uinttostr et al are not ignored
23925         * lib/inttostr.h (__GNUC_PREREQ): Define.
23926         (__attribute_warn_unused_result__): Define.
23927         (offtostr, imaxtostr, umaxtostr, uinttostr): Apply the attribute.
23928
23929 2008-08-07  Paolo Bonzini  <bonzini@gnu.org>
23930
23931         * lib/lock.c (glthread_recursive_lock_init_multithreaded)
23932         [!PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Fix typo.
23933
23934 2008-08-07  Jim Meyering  <meyering@redhat.com>
23935
23936         * m4/inet_pton.m4: Fix typo in comment: s/inet_ntop/inet_pton/.
23937
23938         * modules/mkstemp (License): Relicense under LGPLv2+.
23939         * modules/tempname (License): Likewise.
23940
23941 2008-08-06  Bruno Haible  <bruno@clisp.org>
23942
23943         * lib/poll.c (poll): Further micro-optimization.
23944
23945 2008-08-06  Jim Meyering  <meyering@redhat.com>
23946
23947         inet_pton.c: use locale-independent tolower
23948         * lib/inet_pton.c: Include <c-ctype.h> rather than <ctype.h>.
23949         (inet_pton6): Use c_tolower rather than tolower.
23950         * modules/inet_pton (Depends-on): Add c-ctype.
23951
23952 2008-08-06  Paolo Bonzini  <bonzini@gnu.org>
23953
23954         * lib/poll.c (poll): Avoid division when timeout is 0, cache
23955         _SC_OPEN_MAX, avoid repeated access to errno.  Check for nfd < 0.
23956
23957 2008-08-06  Jim Meyering  <meyering@redhat.com>
23958
23959         * modules/inet_pton (License): Relicense under LGPLv2+.
23960
23961 2008-08-03  Bruno Haible  <bruno@clisp.org>
23962
23963         Additional non-aborting API for lock and tls.
23964         * lib/lock.h: Include <errno.h>.
23965         (glthread_lock_init): New macro/function.
23966         (gl_lock_init): Define as wrapper around glthread_lock_init.
23967         (glthread_lock_lock): New macro/function.
23968         (gl_lock_lock): Define as wrapper around glthread_lock_lock.
23969         (glthread_lock_unlock): New macro/function.
23970         (gl_lock_unlock): Define as wrapper around glthread_lock_unlock.
23971         (glthread_lock_destroy): New macro/function.
23972         (gl_lock_destroy): Define as wrapper around glthread_lock_destroy.
23973         (glthread_rwlock_init): New macro/function.
23974         (gl_rwlock_init): Define as wrapper around glthread_rwlock_init.
23975         (glthread_rwlock_rdlock): New macro/function.
23976         (gl_rwlock_rdlock): Define as wrapper around glthread_rwlock_rdlock.
23977         (glthread_rwlock_wrlock): New macro/function.
23978         (gl_rwlock_wrlock): Define as wrapper around glthread_rwlock_wrlock.
23979         (glthread_rwlock_unlock): New macro/function.
23980         (gl_rwlock_unlock): Define as wrapper around glthread_rwlock_unlock.
23981         (glthread_rwlock_destroy): New macro/function.
23982         (gl_rwlock_destroy): Define as wrapper around glthread_rwlock_destroy.
23983         (glthread_recursive_lock_init): New macro/function.
23984         (gl_recursive_lock_init): Define as wrapper around
23985         glthread_recursive_lock_init.
23986         (glthread_recursive_lock_lock): New macro/function.
23987         (gl_recursive_lock_lock): Define as wrapper around
23988         glthread_recursive_lock_lock.
23989         (glthread_recursive_lock_unlock): New macro/function.
23990         (gl_recursive_lock_unlock): Define as wrapper around
23991         glthread_recursive_lock_unlock.
23992         (glthread_recursive_lock_destroy): New macro/function.
23993         (gl_recursive_lock_destroy): Define as wrapper around
23994         glthread_recursive_lock_destroy.
23995         (glthread_once): New macro/function.
23996         (gl_once): Define as wrapper around glthread_once.
23997         Update function declarations.
23998         * lib/lock.c (glthread_rwlock_init_multithreaded): Renamed from
23999         glthread_rwlock_init. Return error code.
24000         (glthread_rwlock_rdlock_multithreaded): Renamed from
24001         glthread_rwlock_rdlock. Return error code.
24002         (glthread_rwlock_wrlock_multithreaded): Renamed from
24003         glthread_rwlock_wrlock. Return error code.
24004         (glthread_rwlock_unlock_multithreaded): Renamed from
24005         glthread_rwlock_unlock. Return error code.
24006         (glthread_rwlock_destroy_multithreaded): Renamed from
24007         glthread_rwlock_destroy. Return error code.
24008         (glthread_recursive_lock_init_multithreaded): Renamed from
24009         glthread_recursive_lock_init. Return error code.
24010         (glthread_recursive_lock_lock_multithreaded): Renamed from
24011         glthread_recursive_lock_lock. Return error code.
24012         (glthread_recursive_lock_unlock_multithreaded): Renamed from
24013         glthread_recursive_lock_unlock. Return error code.
24014         (glthread_recursive_lock_destroy_multithreaded): Renamed from
24015         glthread_recursive_lock_destroy. Return error code.
24016         (glthread_once_call): Make static.
24017         (glthread_once_multithreaded): Renamed from glthread_once.
24018         * lib/tls.h: Include <errno.h>.
24019         (glthread_tls_key_init): New macro/function.
24020         (gl_tls_key_init): Define as wrapper around glthread_tls_key_init.
24021         (glthread_tls_set): New macro/function.
24022         (gl_tls_set): Define as wrapper around glthread_tls_set.
24023         (glthread_tls_key_destroy): New macro/function.
24024         (gl_tls_key_destroy): Define as wrapper around glthread_tls_key_destroy.
24025         Update function declarations.
24026         * lib/tls.c (glthread_tls_get_multithreaded): Renamed from
24027         glthread_tls_get.
24028         Suggested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
24029
24030 2008-08-04  Eric Blake  <ebb9@byu.net>
24031
24032         gnumakefile: use space, not TAB, outside of targets
24033         * top/GNUmakefile (_dummy): Fix whitespace error in prior edit.
24034
24035 2008-08-02  Jim Meyering  <meyering@redhat.com>
24036
24037         getdate.y: avoid locale-dependent date parsing failure
24038         In Turkish locales, getdate would fail to recognize keywords
24039         containing a lowercase "i".  The solution is not to rely on
24040         locale-sensitive case-conversion.
24041         * lib/getdate.y: Include <c-ctype.h> rather than <ctype.h>.
24042         (lookup_word): Use c_toupper in place of toupper.
24043         (yylex, get_date): Use c_ prefixed variants of isspace and isalpha, too.
24044         Reported by Vefa Bicakci <bicave@superonline.com> in
24045         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/14184>.
24046         * modules/getdate (Depends-on): Add c-ctype.
24047
24048 2008-08-02  Bruno Haible  <bruno@clisp.org>
24049
24050         * gnulib-tool (func_import): When updating or creating a .gitignore
24051         file, prepend each added line with a slash, and ignore leading slashes
24052         from the existing lines.
24053         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
24054
24055 2008-08-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
24056
24057         Portability fix for GNU make 3.79.1.
24058         * top/GNUmakefile: Avoid 'else COND', which older GNU make
24059         versions do not understand.
24060
24061 2008-08-01  Bruno Haible  <bruno@clisp.org>
24062
24063         Work around bug of HP-UX 10.20 cc with -0.0 literal.
24064         * tests/test-isnanf.h (zero): New variable.
24065         (main): Avoid literal -0.0f.
24066         * tests/test-isnand.h (zero): New variable.
24067         (main): Avoid literal -0.0.
24068         * tests/test-isnanl.h (zero): New variable.
24069         (main): Avoid literal -0.0L.
24070         * tests/test-isnan.c (zerof, zerod, zerol): New variables.
24071         (test_float, test_double, test_long_double): Avoid literals -0.0f,
24072         -0.0, -0.0L.
24073         * tests/test-signbit.c (test_signbitf): Avoid literal -0.0f.
24074         (test_signbitd): Avoid literal -0.0.
24075         (test_signbitl): Avoid literal -0.0L.
24076         * tests/test-ceilf1.c (zero): New variable.
24077         (main): Avoid literal -0.0f.
24078         * tests/test-ceill.c (zero): New variable.
24079         (main): Avoid literal -0.0L.
24080         * tests/test-floorf1.c (zero): New variable.
24081         (main): Avoid literal -0.0f.
24082         * tests/test-floorl.c (zero): New variable.
24083         (main): Avoid literal -0.0L.
24084         * tests/test-roundf1.c (zero): New variable.
24085         (main): Avoid literal -0.0f.
24086         * tests/test-round1.c (zero): New variable.
24087         (main): Avoid literal -0.0.
24088         * tests/test-roundl.c (zero): New variable.
24089         (main): Avoid literal -0.0L.
24090         * tests/test-truncf1.c (zero): New variable.
24091         (main): Avoid literal -0.0f.
24092         * tests/test-trunc1.c (zero): New variable.
24093         (main): Avoid literal -0.0.
24094         * tests/test-truncl.c (zero): New variable.
24095         (main): Avoid literal -0.0L.
24096         * tests/test-frexp.c (zero): New variable.
24097         (main): Avoid literal -0.0.
24098         * tests/test-frexpl.c (zero): New variable.
24099         (main): Avoid literal -0.0L.
24100         * tests/test-ldexpl.c (zero): New variable.
24101         (main): Avoid literal -0.0L.
24102         * tests/test-snprintf-posix.h (have_minus_zero): Avoid literal -0.0.
24103         (zerod, zerol): New variables.
24104         (test_function): Avoid literals -0.0, -0.0L.
24105         * tests/test-sprintf-posix.h (have_minus_zero): Avoid literal -0.0.
24106         (zerod, zerol): New variables.
24107         (test_function): Avoid literals -0.0, -0.0L.
24108         * tests/test-vasnprintf-posix.c (have_minus_zero): Avoid literal -0.0.
24109         (zerod, zerol): New variables.
24110         (test_function): Avoid literals -0.0, -0.0L.
24111         * tests/test-vasprintf-posix.c (have_minus_zero): Avoid literal -0.0.
24112         (zerod, zerol): New variables.
24113         (test_function): Avoid literals -0.0, -0.0L.
24114         * tests/test-strtod.c (zero): New variable.
24115         (main): Avoid literal -0.0.
24116         Reported by Jonathan C. Patschke <jp@centtech.com>.
24117
24118 2008-07-31  Jim Meyering  <meyering@redhat.com>
24119
24120         sha256.h: correct definition of SHA224_DIGEST_SIZE
24121         * lib/sha256.h (SHA224_DIGEST_SIZE): Define to 28, not 24.
24122         Reported by Paulie Pena IV <paulie4@gmail.com>.
24123         Define as 224 / 8, rather than as a literal.
24124         (SHA256_DIGEST_SIZE): Define as 256/8 rather than equivalent literal.
24125         * lib/sha512.h (SHA384_DIGEST_SIZE): Likewise, define as equiv: 384/8.
24126         (SHA512_DIGEST_SIZE): Likewise, define as equivalent quotient: 512/8.
24127
24128 2008-07-31  Bruno Haible  <bruno@clisp.org>
24129
24130         * lib/regex_internal.h (BITSET_WORD_BITS): Make first conditional work
24131         on HP-UX 10.20 with "cc -Ae". Fix second conditional.
24132         Reported by Jonathan Patschke <jp@centtech.com>.
24133
24134 2008-07-31  Bruno Haible  <bruno@clisp.org>
24135
24136         * gnulib-tool (func_import): Make change from 2008-06-23 more robust.
24137         Reported by Paolo Bonzini <bonzini@gnu.org>.
24138
24139 2008-07-30  Eric Blake  <ebb9@byu.net>
24140
24141         test-strtod: allow compilation without -lm
24142         * tests/test-strtod.c (main): Avoid link dependence on fabs.
24143         Reported by Dennis Clarke <blastwave@gmail.com>.
24144
24145 2008-07-28  Jim Meyering  <meyering@redhat.com>
24146
24147         bootstrap: work also when there are no .po files in po/
24148         * build-aux/bootstrap (update_po_files): Complete the change
24149         that I began in bc960df8c789c878f1c1c54a28a3c2648dead8d9.
24150
24151 2008-07-27  Jim Meyering  <meyering@redhat.com>
24152
24153         * users.txt: Add zile.
24154
24155 2008-07-26  Ben Pfaff  <blp@gnu.org>
24156
24157         Add missing dependencies on new m4/exponent[fdl].m4 files.
24158         * modules/isnanf-nolibm: Add m4/exponentf.m4.
24159         * modules/isnand-nolibm: Add m4/exponentd.m4.
24160         * modules/isnanl-nolibm: Add m4/exponentl.m4.
24161         * modules/signbit-tests: Use m4/exponent[fdl].m4 instead of
24162         m4/isnan[fdl].m4, because the macros actually used moved.
24163         Reported by Jim Meyering.
24164
24165 2008-07-14  Ben Pfaff  <blp@gnu.org>
24166
24167         Add isinf module.
24168         * lib/isinf.c: New file.
24169         * lib/math.in.h: Define isinf macro if we have decided to replace
24170         it.
24171         * m4/isinf.m4: New file.
24172         * m4/math_h.m4: Initialize and substitute variables for isinf
24173         module.
24174         * modules/isinf: New file.
24175         * modules/isinf-tests: New file.
24176         * modules/math: Add substitutions for new module.
24177         * tests/test-isinf.c: New file.
24178         * doc/posix-functions/isinf.texi: Mention new module.
24179         * MODULES.html.sh: Mention new module.
24180
24181 2008-07-14  Ben Pfaff  <blp@gnu.org>
24182
24183         Factor out some macros for use by additional modules.
24184         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Move into new file
24185         exponentf.m4.
24186         * m4/isnand.m4 (gl_DOUBLE_EXPONENT_LOCATION): Move into new file
24187         exponentd.m4.
24188         * m4/isnanl.m4 (gl_LONG_DOUBLE_EXPONENT_LOCATION): Move into new
24189         file exponentl.m4.
24190         * m4/exponentf.m4: New file.
24191         * m4/exponentd.m4: New file.
24192         * m4/exponentl.m4: New file.
24193         * modules/isnanf: Use new file m4/exponentf.m4.
24194         * modules/isnand: Use new file m4/exponentd.m4.
24195         * modules/isnanl: Use new file m4/exponentl.m4.
24196
24197 2008-07-23  Ulrich Drepper  <drepper@redhat.com>
24198
24199         mktime.c: normalize tp->tm_isdst value to -1/0/1.
24200         * lib/mktime.c (__mktime_internal): Normalize tp->tm_isdst value.
24201         Reported by Michael Ringe <Michael.Ringe@gmx.de> in
24202         <http://sourceware.org/bugzilla/show_bug.cgi?id=6723>.
24203
24204         * lib/canonicalize-lgpl.c (__realpath): Avoid buffer overflow after
24205         readlink on platforms without PATH_MAX.
24206
24207 2008-07-21  Eric Blake  <ebb9@byu.net>
24208
24209         Warn, not fail, on stale version.
24210         * top/GNUmakefile (_curr-ver): Tone down previous patch.
24211
24212         Don't allow installation with stale devel version number.
24213         * top/GNUmakefile (_is-install-target): New macro.
24214         (_curr-ver): Forbid installation with stale version number.
24215
24216 2008-07-20  Bruno Haible  <bruno@clisp.org>
24217
24218         * modules/c-stack-tests (Makefile.am): Add LIBSIGSEGV to
24219         TESTS_ENVIRONMENT.
24220         * tests/test-c-stack2.sh: React differently if LIBSIGSEGV is in use.
24221
24222 2008-07-20  Bruno Haible  <bruno@clisp.org>
24223
24224         * lib/c-stack.h (c_stack_action): Add documentation.
24225         * lib/c-stack.c (c_stack_action): Remove incomplete documentation.
24226
24227 2008-07-20  Bruno Haible  <bruno@clisp.org>
24228
24229         * modules/canonicalize-lgpl (License): Relicense under LGPLv2+.
24230         * modules/readlink (License): Likewise.
24231
24232 2008-07-17  Eric Blake  <ebb9@byu.net>
24233
24234         * modules/c-stack (Link): Fix typo.
24235
24236         Make c-stack use libsigsegv, when available.
24237         * modules/c-stack (Depends-on): Add libsigsegv.
24238         * modules/c-stack-tests (Makefile.am): Link with libsigsegv, if
24239         needed.
24240         * lib/c-stack.c (SIGSTKSZ): Define fallback.
24241         (segv_handler, overflow_handler, c_stack_action)
24242         [HAVE_LIBSIGSEGV && !HAVE_XSI_STACK_OVERFLOW_HEURISTIC]: Add new
24243         implementation when libsigsegv is available, but only when using
24244         the library is necessary.
24245         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Add
24246         comment, explaining why XSI check fails on Linux.
24247         (gl_PREREQ_C_STACK): Supply LIBCSTACK, LTLIBCSTACK.
24248         * tests/test-c-stack2.sh: Tweak skip message.
24249         * NEWS: Document new link-time requirements.
24250
24251 2008-07-16  Eric Blake  <ebb9@byu.net>
24252
24253         c-stack: Expose false positives when not using libsigsegv.
24254         * modules/c-stack-tests (Files): Expand test.
24255         * tests/test-c-stack.c (main): Add means to conditionally trigger
24256         non-overflow SIGSEGV.
24257         * tests/test-c-stack2.sh: New file.
24258
24259 2008-07-14  Bruno Haible  <bruno@clisp.org>
24260
24261         * m4/libsigsegv.m4: Remove unneeded AC_PREREQ.
24262         Reported by Eric Blake.
24263
24264 2008-07-14  Sam Steingold  <sds@gnu.org>
24265             Bruno Haible  <bruno@clisp.org>
24266
24267         New module libsigsegv.
24268         * modules/libsigsegv: New file.
24269         * m4/libsigsegv.m4: New file, from GNU clisp sigsegv.m4 with
24270         modifications.
24271         * MODULES.html.sh (Signal handling): New section.
24272
24273 2008-07-14  Bruno Haible  <bruno@clisp.org>
24274
24275         * modules/unictype/ctype-* (Description): Add the word "function".
24276         Improves the resulting doc in MODULES.html.
24277
24278 2008-07-12  Ben Pfaff  <blp@gnu.org>
24279
24280         Add longlong module.
24281         * modules/longlong: New file.
24282
24283 2008-07-12  Bruno Haible  <bruno@clisp.org>
24284
24285         * m4/isnan.m4 (gl_ISNAN): When the replacement is used, set ISNAN_LIBM
24286         to empty.
24287
24288 2008-07-10  Ben Pfaff  <blp@gnu.org>
24289
24290         Add isnan module.
24291         * doc/posix-functions/isnan.texi: Mention new module.
24292         * lib/math.in.h: Define isnan macro if we have decided to replace
24293         it.
24294         * m4/isnan.m4: New file.
24295         * m4/isnanl.m4 (gl_FUNC_ISNANL): Factor out some code into new
24296         macro gl_BUILD_ISNANL so that isnan.m4 can use that functionality
24297         also.
24298         (gl_FUNC_ISNANL_NO_LIBM): Factor out same code, to reduce
24299         redundancy.
24300         * m4/math_h.m4: Initialize and substitute variables for isnan
24301         module.
24302         * modules/isnan: New file.
24303         * modules/isnan-tests: New file.
24304         * modules/math: Add substitutions for new module.
24305         * tests/test-isnan.c: New file.
24306         * MODULES.html.sh: Mention new module.
24307
24308 2008-07-10  Ben Pfaff  <blp@gnu.org>
24309
24310         Add isnanf module.
24311         * lib/isnanf.m4: New file.
24312         * m4/isnanf.m4 (gl_FUNC_ISNANF): New macro.
24313         (gl_HAVE_ISNANF_IN_LIBM): New macro.
24314         (gl_BUILD_ISNANF): New macro used by gl_FUNC_ISNANF,
24315         gl_FUNC_ISNANF_NO_LIBM, and gl_FUNC_ISNAN.
24316         * modules/isnanf: New file.
24317         * modules/isnanf-tests: New file.
24318         * modules/isnanf-nolibm-tests: Add tests/test-isnanf.h to list of
24319         files.
24320         * tests/test-isnanf-nolibm.c: factored most of its contents into
24321         new file tests/test-isnanf.h.
24322         * tests/test-isnanf.h: New file.
24323         * tests/test-isnanf.c: New file.
24324         * MODULES.html.sh: Mention new module.
24325         * doc/glibc-functions/isnanf.texi: Mention new module.
24326
24327 2008-07-10  Ben Pfaff  <blp@gnu.org>
24328
24329         Add isnand module.
24330         * lib/isnand.h: New file.
24331         * m4/isnand.m4 (gl_FUNC_ISNAND): New macro.
24332         (gl_FUNC_ISNAND_NO_LIBM): Split partially into new macro
24333         gl_HAVE_ISNAND_NO_LIBM so that gl_FUNC_ISNAND can use that
24334         functionality also.
24335         (gl_BUILD_ISNAND): New macro used by gl_FUNC_ISNAND,
24336         gl_FUNC_ISNAND_NO_LIBM, and gl_FUNC_ISNAN.
24337         (gl_HAVE_ISNAND_IN_LIBM): New macro.
24338         * modules/isnand: New file.
24339         * modules/isnand-tests: New file.
24340         * modules/isnand-nolibm-tests: Add tests/test-isnand.h to list of
24341         files.
24342         * tests/test-isnand-nolibm.c: factored most of its contents into
24343         new file tests/test-isnand.h.
24344         * tests/test-isnand.h: New file.
24345         * tests/test-isnand.c: New file.
24346         * MODULES.html.sh: Mention new module.
24347
24348 2008-07-10  Ben Pfaff  <blp@gnu.org>
24349
24350         * lib/isnanf.h: Rename lib/isnanf-nolibm.h.
24351         * lib/isnand.h: Rename lib/isnand-nolibm.h.
24352         * tests/test-isnanf.c: Rename tests/test-isnanf-nolibm.c.
24353         * tests/test-isnand.c: Rename tests/test-isnand-nolibm.c.
24354         * modules/isnanf-nolibm: Update references to renamed files.
24355         * modules/isnand-nolibm: Likewise.
24356         * modules/isnanf-nolibm-tests: Likewise.
24357         * modules/isnand-nolibm-tests: Likewise.
24358         * lib/frexp.c: Likewise.
24359         * lib/isfinite.c: Likewise.
24360         * lib/signbitd.c: Likewise.
24361         * lib/signbitf.c: Likewise.
24362         * lib/vasnprintf.c: Likewise.
24363         * tests/test-ceilf1.c: Likewise.
24364         * tests/test-ceilf2.c: Likewise.
24365         * tests/test-floorf1.c: Likewise.
24366         * tests/test-floorf2.c: Likewise.
24367         * tests/test-frexp.c: Likewise.
24368         * tests/test-round1.c: Likewise.
24369         * tests/test-round2.c: Likewise.
24370         * tests/test-roundf1.c: Likewise.
24371         * tests/test-strtod.c: Likewise.
24372         * tests/test-trunc1.c: Likewise.
24373         * tests/test-trunc2.c: Likewise.
24374         * tests/test-truncf1.c: Likewise.
24375         * tests/test-truncf2.c: Likewise.
24376         * NEWS: Mention the renamed header files.
24377
24378 2008-07-11  Jim Meyering  <meyering@redhat.com>
24379
24380         vc-list-files: make the last-resort awk code more portable
24381         * build-aux/vc-list-files: Don't rely on awk's "sub" command.
24382         /bin/awk from OpenSolaris 11's SUNWesu version 2008.03.22.10.56
24383         does not support it.
24384
24385 2008-07-10  Eric Blake  <ebb9@byu.net>
24386
24387         Work with tar's bootstrap.
24388         * gnulib-tool (func_emit_initmacro_end): Use m4_defn in the case
24389         where LIBSOURCES_DIR contains .#bootmp but must not be treated as
24390         an m4 comment.
24391
24392 2008-07-09  Jim Meyering  <meyering@redhat.com>
24393
24394         posix-shell.m4: fix typo that made this test malfunction
24395         * m4/posix-shell.m4: Remove capitalization in variable name.
24396
24397 2008-07-08  Bruno Haible  <bruno@clisp.org>
24398
24399         * m4/onceonly.m4: Update comments.
24400         Reported by Ben Pfaff <blp@cs.stanford.edu>.
24401
24402 2008-07-04  Jim Meyering  <meyering@redhat.com>
24403
24404         * users.txt: Add vc-dwim.
24405         (bison, coreutils): Use the gitweb URL.
24406
24407 2008-07-03  Jim Meyering  <meyering@redhat.com>
24408
24409         * users.txt: Add libffcall.  From Sam Steingold.
24410
24411 2008-07-03  Ondřej Vašík  <ovasik@redhat.com>
24412
24413         getdate.y: do not ignore TZ with relative day, month or year offset
24414         * lib/getdate.y (get_date): Move the tz-handling block to follow the
24415         relative-date-handling, since otherwise, the latter would clobber the
24416         sole output (an updated Start value) of the tz-handling block.
24417         * tests/test-getdate.c: Tests for the fix
24418
24419 2008-07-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
24420
24421         Recognize 'foo_LIBRARIES += libgnu.a'.
24422         * gnulib-tool (func_emit_lib_Makefile_am): Recognize if a
24423         makefile snippet has already specified an installation location,
24424         also using '+='.
24425
24426 2008-07-02  Ondřej Vašík  <ovasik@redhat.com>
24427
24428         getdate.y: factor out common actions
24429         * lib/getdate.y (apply_relative_time, set_hhmmss): New functions.
24430         Use them in place of open-coded actions.
24431
24432 2008-07-01  Simon Josefsson  <simon@josefsson.org>
24433
24434         Add self-test for getdate module.
24435         * modules/getdate-tests: New file.
24436         * tests/test-getdate.c: New file.
24437
24438 2008-06-29  Bruno Haible  <bruno@clisp.org>
24439
24440         * gnulib-tool (func_import): Put gnulib-comp.m4 into .cvsignore or
24441         .gitignore.
24442         Reported by Sylvain Beucler <beuc@beuc.net>.
24443
24444 2008-06-29  Bruno Haible  <bruno@clisp.org>
24445
24446         * doc/gnulib-tool.texi (VCS Issues): Mention --no-vc-files option.
24447         * m4/gnulib-tool.m4: Update to match current gnulib-tool.
24448
24449 2008-06-29  Bruno Haible  <bruno@clisp.org>
24450
24451         * gnulib-tool (func_import): Recommend to put gnulib-cache.m4 into
24452         EXTRA_DIST.
24453         Reported by Sylvain Beucler <beuc@beuc.net>.
24454
24455 2008-06-26  Jim Meyering  <meyering@redhat.com>
24456
24457         make several modules depend on the "open" module
24458         This provides slightly increased consistency when opening-for-write
24459         the name of a non-directory spelled with a trailing slash.
24460         * modules/chdir-safer: Likewise.
24461         * modules/chown: Likewise.
24462         * modules/clean-temp: Likewise.
24463         * modules/copy-file: Likewise.
24464         * modules/fchdir: Likewise.
24465         * modules/fcntl-safer: Likewise.
24466         * modules/pipe: Likewise.
24467         * modules/utime: Likewise.
24468         Prompted by Eric Blake and Bruno Haible.
24469
24470 2008-06-24  Andreas Schwab  <schwab@suse.de>
24471
24472         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Don't test whether compound
24473         literals can be used as initializers for global variables.
24474
24475 2008-06-23  Eric Blake  <ebb9@byu.net>
24476
24477         Make gnulib-cache.m4 easier to diff.
24478         * gnulib-tool (func_import): Allow newlines when reading cached
24479         gl_MODULES, and generate newlines when creating gnulib-cache.m4.
24480
24481 2008-06-23  Bruno Haible  <bruno@clisp.org>
24482
24483         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): Remove macro.
24484         (gl_PREREQ_SIGPROCMASK): Don't invoke it.
24485         * m4/sigaction.m4 (gl_PREREQ_SIG_HANDLER_H): New macro, moved here from
24486         m4/signalblocking.m4.
24487         (gl_PREREQ_SIGACTION): Don't invoke it.
24488         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Invoke
24489         gl_PREREQ_SIG_HANDLER_H.
24490         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
24491         Don't check for sigaction here.
24492
24493 2008-06-23  Bruno Haible  <bruno@clisp.org>
24494
24495         * lib/fatal-signal.c (fatal_signal_handler): Update comment.
24496         (install_handlers): Don't set the SA_RESETHAND flag.
24497
24498 2008-06-23  Bruno Haible  <bruno@clisp.org>
24499
24500         * m4/sigaction.m4: Comment fixes.
24501         * lib/signal.in.h: Likewise.
24502
24503 2008-06-23  Eric Blake  <ebb9@byu.net>
24504
24505         Fix typo.
24506         * tests/test-sigaction.c (MASK_SA_FLAGS): Add missing operator.
24507
24508         Avoid SA_ namespace.
24509         * tests/test-sigaction.c (MASK_SA_FLAGS): Rename from SA_MASK.
24510         Reported by Ralf Wildenhues.
24511
24512         Avoid test failure due to SA_RESTORER.
24513         * tests/test-sigaction.c (SA_MASK): New macro.
24514         (main): Avoid failing due to extension flags being set.
24515         Reported by Jim Meyering.
24516
24517         Revert use of sig-handler.h in sigprocmask.c.
24518         * modules/sigprocmask (Files): Don't rely on sig-handler.h, since
24519         it requires the existence of struct sigaction.
24520         * lib/sigprocmask.c (handler_t): Restore typedef.
24521         (rpl_signal, old_handlers): Use local type.
24522
24523 2008-06-22  Bruno Haible  <bruno@clisp.org>
24524
24525         * tests/test-stdint.c: Disable the INTMAX_MAX preprocessor test
24526         conditionally.
24527         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
24528
24529 2008-06-22  Bruno Haible  <bruno@clisp.org>
24530
24531         * doc/posix-functions/siginterrupt.texi: Move note.
24532
24533         * lib/signal.in.h (SA_RESTART): New macro.
24534         * lib/sigaction.c: Update comment.
24535
24536         * m4/sigaction.m4 (gl_SIGACTION): Require gl_SIGNAL_H_DEFAULTS.
24537
24538         * m4/signalblocking.m4 (gl_PREREQ_SIG_HANDLER_H): New macro.
24539         (gl_PREREQ_SIGPROCMASK): Invoke it.
24540         * m4/sigaction.m4 (gl_PREREQ_SIGACTION): Likewise.
24541
24542         * lib/nanosleep.c (rpl_nanosleep): Setup newact only when it is needed.
24543
24544         * lib/sigprocmask.c: Update a comment.
24545
24546 2008-06-21  Eric Blake  <ebb9@byu.net>
24547
24548         Use sigaction module rather than signal().
24549         * modules/c-stack (Depends-on): Add sigaction.
24550         * modules/fatal-signal (Depends-on): Likewise.
24551         * modules/nanosleep (Depends-on): Likewise.
24552         * modules/sigprocmask (Files): Add sig-handler.h.
24553         * modules/sigaction (Files): Likewise.
24554         * lib/sig-handler.h (get_handler): New file, suggested by Paul
24555         Eggert.
24556         * lib/c-stack.c (SIGACTION_WORKS): Simplify conditions.
24557         (c_stack_action) [!SIGACTION_WORKS]: Use sigaction, not signal.
24558         * lib/fatal-signal.c (uninstall_handlers, install_handlers)
24559         (init_fatal_signals): Likewise.
24560         * lib/nanosleep.c (rpl_nanosleep): Likewise.
24561         (siginterrupt): Delete fallback.
24562         * lib/sigprocmask.c (handler_t, old_handlers): Use sa_handler_t
24563         instead.
24564         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Drop check for
24565         siginterrupt.
24566
24567         New module sigaction, for mingw.
24568         * modules/sigaction: New module...
24569         * modules/sigaction-tests: ...and its test.
24570         * m4/sigaction.m4: New file.
24571         * lib/sigaction.c: Likewise.
24572         * tests/test-sigaction.c: Likewise.
24573         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Add sigaction variables.
24574         * modules/signal (Makefile.am): Likewise.
24575         * lib/signal.in.h (!@HAVE_SIGACTION@): Define replacements when
24576         needed.
24577         * doc/posix-headers/signal.texi (signal.h): Mention provided
24578         types.
24579         * doc/posix-functions/siginterrupt.texi (siginterrupt): Mention
24580         that sigaction is preferable.
24581         * doc/posix-functions/sigaction.texi (sigaction): Mention new
24582         module.
24583         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
24584         sigaction.
24585
24586         Improve robustness of sigprocmask by overriding signal.
24587         * lib/signal.in.h (rpl_signal): Override signal when sigprocmask
24588         is in use.
24589         * lib/sigprocmask.c (blocked_handler): Reinstall block handler.
24590         (SIGKILL, SIGSTOP): Provide fallbacks.
24591         (rpl_signal): Implement.
24592         (old_handlers, blocked_set): Mark volatile, since sigprocmask and
24593         signal can be called inside handlers.
24594
24595         Fix nanosleep module on mingw.
24596         * modules/nanosleep (Depends-on): Add sys_select.
24597         * lib/nanosleep.c (HAVE_SYS_SELECT_H): Rely on gnulib module.
24598
24599         Fix licensing of sigprocmask.
24600         * modules/raise (License): Relicense as LGPL.
24601
24602 2008-06-21  Bruno Haible  <bruno@clisp.org>
24603
24604         * lib/propername.c (proper_name_utf8): Don't use the transliterated
24605         result if it contains question marks.
24606         Reported by Michael Geng <linux@michaelgeng.de>.
24607
24608 2008-06-19  Bruno Haible  <bruno@clisp.org>
24609
24610         Fix CVS-ism.
24611         * doc/gnulib.texi: Include updated-stamp.texi.
24612         * doc/Makefile (GNULIB_TEXI_FILES): New variable.
24613         (updated-stamp.texi): New rule.
24614         (gnulib.info): Depend on it.
24615         * doc/.gitignore: Add updated-stamp.texi.
24616         Based on a patch by Thien-Thi Nguyen <ttn@gnuvola.org>.
24617
24618 2008-06-19  Bruno Haible  <bruno@clisp.org>
24619
24620         * doc/Makefile (gnulib.info): Update and simplify dependencies.
24621         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
24622
24623 2008-06-19  Eric Blake  <ebb9@byu.net>
24624
24625         Fix VPATH 'make dist' with GNU make and non-VCS tarball.
24626         * top/GNUmakefile (_curr-ver): Don't use $(srcdir) unnecessarily.
24627         Reported by Stepan Kasal.
24628
24629 2008-06-18  Bruno Haible  <bruno@clisp.org>
24630
24631         * lib/fatal-signal.c (init_fatal_signals): Add comment.
24632         Reported by Eric Blake.
24633
24634 2008-06-18  Eric Blake  <ebb9@byu.net>
24635
24636         Work around cygwin 1.5.25 strsignal bug.
24637         * tests/test-strsignal.c: Allow for const char *.
24638         * doc/glibc-functions/strsignal.texi (strsignal): Document the bug.
24639
24640 2008-06-18  Simon Josefsson  <simon@josefsson.org>
24641
24642         * users.txt: Update URL to article and add author/date
24643         information.
24644
24645 2008-06-17  Bruno Haible  <bruno@clisp.org>
24646
24647         New macro gl_DISABLE_THREADS.
24648         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Use value gl_use_threads_default
24649         if the user did not pass --enable-threads or --disable-threads option.
24650         (gl_DISABLE_THREADS): New macro.
24651         Reported by Eric Blake <ebb9@byu.net>.
24652
24653 2008-06-17  Bruno Haible  <bruno@clisp.org>
24654
24655         * lib/tls.h (gl_tls_key_init): Evaluate the destructor argument also
24656         when the macro ignores it.
24657         Based on a patch by Eric Blake <ebb9@byu.net>.
24658
24659 2008-06-17  Bruno Haible  <bruno@clisp.org>
24660
24661         * modules/tls (License): Change to LGPLv2+.
24662         Reported by Eric Blake.
24663
24664 2008-06-17  Eric Blake  <ebb9@byu.net>
24665
24666         Simplify c-stack prerequisites.
24667         * lib/c-stack.c (includes): Remove unused <sys/resource.h>.
24668         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Posix 200x
24669         no longer requires <ucontext.h> to exist.  Optimize setrlimit
24670         check.
24671         (gl_PREREQ_C_STACK): Remove check for unused getcontext and
24672         <sys/resource.h>.
24673
24674         Move c-stack test into testsuite.
24675         * modules/c-stack-tests: New file.
24676         * lib/c-stack.c [DEBUG]: Move test program...
24677         * tests/test-c-stack.c: ...into this new file.  Skip rather than
24678         fail test if sigaltstack is lacking.
24679         * tests/test-c-stack.sh: New driver file.
24680
24681 2008-06-16  Eric Blake  <ebb9@byu.net>
24682
24683         Use raise module consistently.
24684         * modules/fatal-signal (Depends-on): Add raise.
24685         * modules/sigprocmask (Depends-on): Likewise.
24686         * lib/fatal-signal.c (fatal_signal_handler): Rely on raise.
24687         * lib/sigprocmask.c (sigprocmask): Likewise.
24688         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Likewise.
24689         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Likewise.
24690
24691         Fix compliance bug in sigpending.
24692         * lib/sigprocmask.c (sigpending): Return pending array via
24693         parameter, not return value.
24694
24695 2008-06-14  Eric Blake  <ebb9@byu.net>
24696
24697         Improve obstack-printf test code.
24698         * tests/test-obstack-printf.c (test_function): Fix comment, and
24699         simplify usage of obstack_* in macros.  Add a test for coverage.
24700         Reported by Bruno Haible.
24701
24702 2008-06-14  Bruno Haible  <bruno@clisp.org>
24703
24704         * lib/obstack_printf.c (obstack_vprintf): Define the stack-allocated
24705         array size as a constant, not as a const variable.
24706         * m4/obstack-printf.m4 (gl_FUNC_OBSTACK_PRINTF): Require
24707         AC_USE_SYSTEM_EXTENSIONS.
24708         * m4/obstack-printf-posix.m4 (gl_FUNC_OBSTACK_PRINTF_POSIX): Likewise.
24709         Test whether the obstack_printf function actually exists.
24710         * modules/obstack-printf (Depends-on): Add extensions.
24711         (Include): Remove obstack.h.
24712         * modules/obstack-printf-posix (Depends-on): Add extensions.
24713         (Include): Remove obstack.h.
24714
24715 2008-06-13  Eric Blake  <ebb9@byu.net>
24716
24717         Add obstack-printf and obstack-printf-posix modules.
24718         * modules/obstack-printf: New file.
24719         * modules/obstack-printf-posix: Likewise.
24720         * MODULES.html.sh (Misc): Mention them.
24721         * doc/glibc-functions/obstack_printf.texi (obstack_printf):
24722         Likewise.
24723         * doc/glibc-functions/obstack_vprintf.texi (obstack_vprintf):
24724         Likewise.
24725         * modules/stdio (Makefile.am): Accomodate new modules.
24726         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
24727         * lib/stdio.in.h (rpl_obstack_printf, rpl_obstack_vprintf):
24728         Declare.
24729         * lib/obstack_printf.c (obstack_printf, obstack_vprintf): New
24730         functions.
24731         * m4/obstack-printf.m4 (gl_OBSTACK_PRINTF)
24732         (gl_REPLACE_OBSTACK_PRINTF): New macros
24733         * m4/obstack-printf-posix.m4 (gl_OBSTACK_PRINTF_POSIX): Likewise.
24734         * tests/test-obstack-printf.c: New file.
24735         * modules/obstack-printf-tests: Likewise.
24736         * modules/obstack-printf-posix-tests: Likewise.
24737
24738 2008-06-11  Bruno Haible  <bruno@clisp.org>
24739
24740         * m4/open.m4 (gl_FUNC_OPEN): Add test against trailing slash bug.
24741         * lib/open.c: Include errno.h.
24742         (open): Fail when attempting to write to a file that has a trailing
24743         slash.
24744         * tests/test-open.c (main): Test against trailing slash bug.
24745         * doc/posix-functions/open.texi: Mention the trailing slash bug.
24746
24747 2008-06-10  Bruno Haible  <bruno@clisp.org>
24748
24749         * tests/test-vc-list-files-git.sh: Make double use of 'exit'. Needed
24750         for $? to work inside the trap command, with various /bin/sh-s.
24751         * tests/test-vc-list-files-cvs.sh: Likewise.
24752
24753 2008-06-10  Bruno Haible  <bruno@clisp.org>
24754
24755         * lib/acl-internal.h: Don't include gettext.h here.
24756         * lib/set-mode-acl.c: Include gettext.h here.
24757         * lib/copy-acl.c: Likewise.
24758
24759 2008-06-10  Bruno Haible  <bruno@clisp.org>
24760
24761         * lib/wait-process.h (wait_subprocess): Add termsigp argument.
24762         * lib/wait-process.c (wait_subprocess): Likewise.
24763         * lib/execute.h (execute): Add termsigp argument.
24764         * lib/execute.c (execute): Likewise.
24765         * lib/csharpcomp.c (compile_csharp_using_pnet,
24766         compile_csharp_using_mono, compile_csharp_using_sscli): Update.
24767         * lib/csharpexec.c (execute_csharp_using_pnet,
24768         execute_csharp_using_mono, execute_csharp_using_sscli): Update.
24769         * lib/javacomp.c (compile_using_envjavac, compile_using_gcj,
24770         compile_using_javac, compile_using_jikes, is_envjavac_gcj,
24771         is_envjavac_gcj43, is_gcj_present, is_gcj_43, is_javac_present,
24772         is_jikes_present): Update.
24773         * lib/javaexec.c (execute_java_class): Update.
24774         * lib/javaversion.c (execute_and_read_line): Update.
24775         * NEWS: Document the changes.
24776         Reported by Eric Blake.
24777
24778 2008-06-10  Eric Blake  <ebb9@byu.net>
24779
24780         Add missing include.
24781         * tests/test-strstr.c (includes): Add <signal.h>.
24782         * tests/test-strcasestr.c (includes): Likewise.
24783         * tests/test-memmem.c (includes): Likewise.
24784
24785 2008-06-10  Bruno Haible  <bruno@clisp.org>
24786
24787         * lib/wait-process.c (wait_subprocess): Add an assertion.
24788
24789 2008-06-10  Bruno Haible  <bruno@clisp.org>
24790
24791         * lib/wait-process.c (wait_subprocess): Try to fix waitid() based code.
24792
24793 2008-06-10  Bruno Haible  <bruno@clisp.org>
24794
24795         * tests/test-memmem.c (main): Reset SIGALRM to default handling before
24796         using alarm().
24797         * tests/test-strcasestr.c (main): Likewise.
24798         * tests/test-strstr.c (main): Likewise.
24799
24800 2008-06-09  Bruno Haible  <bruno@clisp.org>
24801
24802         Work around the Solaris 10 ACE ACLs ABI change.
24803         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): Don't
24804         declare if ACL_NO_TRIVIAL is present.
24805         (ACE_ACCESS_ALLOWED_ACE_TYPE, ACE_ACCESS_DENIED_ACE_TYPE,
24806         NEW_ACE_OWNER, NEW_ACE_GROUP, NEW_ACE_IDENTIFIER_GROUP, ACE_EVERYONE,
24807         NEW_ACE_READ_DATA, NEW_ACE_WRITE_DATA, NEW_ACE_EXECUTE): New macros.
24808         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): Don't
24809         define if ACL_NO_TRIVIAL is present.
24810         (acl_ace_nontrivial): Detect whether the old or new ABI is in use,
24811         and use the current ABI.
24812         (file_has_acl): Use same #if condition as elsewhere.
24813         * lib/set-mode-acl.c (qset_acl): Detect whether the old or new ABI is
24814         in use, and use the current ABI.
24815         * doc/acl-resources.txt: More doc about newer Solaris 10 versions.
24816         Reported by Jim Meyering.
24817
24818 2008-06-09  Eric Blake  <ebb9@byu.net>
24819
24820         Work around environments that (stupidly) ignore SIGALRM.
24821         * m4/strstr.m4 (gl_FUNC_STRSTR): Reset SIGALRM to default handling
24822         before using alarm().
24823         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
24824         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
24825         Reported by Ian Beckwith <ianb@erislabs.net>.
24826
24827         Produce autobuild blurb earlier in log.
24828         * modules/autobuild (configure.ac-early): Move AB_INIT here.
24829
24830 2008-06-09  Jim Meyering  <meyering@redhat.com>
24831         and Ondřej Vašík  <ovasik@redhat.com>
24832
24833         utimens.c: correct kernel bug work-around
24834         Ondřej Vašík found that the invalid return value of 280 indicates
24835         failure, not success, and the kernel bug we're trying to work
24836         around affects not just the utimensat call, but also the fallback
24837         futimens call.
24838         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Simulate failure,
24839         not success.
24840         [HAVE_FUTIMENS]: Use the same work-around, here.
24841
24842 2008-06-09  Jim Meyering  <meyering@redhat.com>
24843
24844         add more guards around definition of ACE_-related code
24845         * lib/file-has-acl.c (acl_ace_nontrivial): Define only if
24846         ALLOW and ACE_OWNER are also defined.
24847
24848 2008-06-08  Bruno Haible  <bruno@clisp.org>
24849
24850         * lib/acl-internal.h: Add me as co-author.
24851         * lib/file-has-acl.c: Likewise.
24852         * lib/set-mode-acl.c: Likewise.
24853         * lib/copy-acl.c: Likewise.
24854
24855 2008-06-08  Bruno Haible  <bruno@clisp.org>
24856
24857         Add support for AIX ACLs.
24858         * lib/acl-internal.h (acl_nontrivial): New declaration.
24859         * lib/file-has-acl.c (acl_nontrivial): New function.
24860         (file_has_acl): Add implementation using AIX 4 ACL API.
24861         * lib/set-mode-acl.c (qset_acl): Likewise.
24862         * lib/copy-acl.c (qcopy_acl): Likewise.
24863
24864 2008-06-08  Bruno Haible  <bruno@clisp.org>
24865
24866         Add support for HP-UX ACLs.
24867         * lib/acl-internal.h (acl_nontrivial): New declaration.
24868         * lib/file-has-acl.c (acl_nontrivial): New function.
24869         (file_has_acl): Add implementation using HP-UX 11 ACL API.
24870         * lib/set-mode-acl.c (qset_acl): Likewise.
24871         * lib/copy-acl.c (qcopy_acl): Likewise.
24872
24873 2008-06-08  Bruno Haible  <bruno@clisp.org>
24874
24875         Add support for Cygwin ACLs.
24876         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro for Solaris-like API.
24877         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Don't optimize away
24878         the chmod_or_fchmod call.
24879         * lib/copy-acl.c (qcopy_acl) [!MODE_INSIDE_ACL]: Likewise.
24880
24881 2008-06-08  Bruno Haible  <bruno@clisp.org>
24882
24883         Fix bug with setuid modes in Solaris 10+ code.
24884         * lib/set-mode-acl.c (qset_acl): Call chmod_or_fchmod when acl_set
24885         succeeded, when the mode contains some special bits.
24886
24887 2008-06-08  Bruno Haible  <bruno@clisp.org>
24888
24889         Add support for Solaris 7..10 ACLs.
24890         * lib/acl-internal.h (acl_nontrivial, acl_ace_nontrivial): New
24891         declarations.
24892         * lib/file-has-acl.c (acl_nontrivial, acl_ace_nontrivial): New
24893         functions.
24894         (file_has_acl): Add implementation using Solaris 7..10 ACL API.
24895         * lib/set-mode-acl.c (qset_acl): Likewise.
24896         * lib/copy-acl.c (qcopy_acl): Likewise.
24897
24898 2008-06-08  Bruno Haible  <bruno@clisp.org>
24899
24900         * lib/acl-internal.h (acl_extended_nontrivial) [MacOS X]: New
24901         declaration.
24902         * lib/file-has-acl.c (acl_extended_nontrivial) [MacOS X]: New function.
24903         (acl_access_nontrivial): Remove MacOS X case.
24904         (file_has_acl): Use acl_extended_nontrivial.
24905         * lib/copy-acl.c (qcopy_acl): Likewise.
24906
24907 2008-06-08  Bruno Haible  <bruno@clisp.org>
24908
24909         * lib/set-mode-acl.c (qset_acl): Trivial code simplifications.
24910
24911 2008-06-08  Jim Meyering  <meyering@redhat.com>
24912
24913         * modules/acl (Maintainer): Add Bruno Haible.
24914
24915 2008-06-07  Bruno Haible  <bruno@clisp.org>
24916
24917         Improve support for Tru64 ACLs.
24918         * lib/file-has-acl.c (file_has_acl): Don't test the ACL_TYPE_DEFAULT
24919         ACL on OSF/1.
24920
24921 2008-06-07  Bruno Haible  <bruno@clisp.org>
24922
24923         Add support for MacOS X ACLs.
24924         * lib/file-has-acl.c (file_has_acl): Use ACL_TYPE_EXTENDED instead of
24925         ACL_TYPE_ACCESS and ACL_TYPE_DEFAULT.
24926         * lib/set-mode-acl.c (qset_acl): Likewise.
24927         * lib/copy-acl.c (qcopy_acl): Likewise.
24928
24929 2008-06-07  Bruno Haible  <bruno@clisp.org>
24930
24931         Fix memory leak introduced on 2008-05-22.
24932         * lib/set-mode-acl.c (qset_acl) [!MODE_INSIDE_ACL]: Free ACLs after
24933         use.
24934
24935 2008-06-07  Bruno Haible  <bruno@clisp.org>
24936
24937         * lib/set-mode-acl.c (qset_acl): Use acl_init(), not acl_from_text(),
24938         to construct an empty ACL.
24939
24940 2008-06-07  Bruno Haible  <bruno@clisp.org>
24941
24942         * lib/set-mode-acl.c (chmod_or_fchmod): Document return value
24943         precisely.
24944         * lib/copy-acl.c (qcopy_acl): Trivial code simplifications.
24945
24946 2008-06-07  Bruno Haible  <bruno@clisp.org>
24947
24948         * lib/copy-acl.c (qcopy_acl): Make the #if branches independent.
24949         * lib/set-mode-acl.c (qset_acl): Choose better local variable names.
24950
24951 2008-06-07  Bruno Haible  <bruno@clisp.org>
24952
24953         * doc/posix-functions/_setjmp.texi: Explain the use of this function
24954         regardless of POSIX.
24955         * doc/posix-functions/_longjmp.texi: Likewise.
24956         * doc/posix-functions/setjmp.texi: Mention HP-UX as not counting as a
24957         SystemV platform in this case.
24958
24959 2008-06-06  Eric Blake  <ebb9@byu.net>
24960
24961         Document abort() bugs.
24962         * doc/posix-functions/abort.texi (abort): Mention anomalies.
24963
24964         * doc/posix-functions/setjmp.texi (setjmp): Mingw has setjmp.
24965         * doc/posix-functions/sigsetjmp.texi (sigsetjmp): Cygwin has
24966         sigsetjmp.
24967         * doc/posix-functions/siglongjmp.texi (siglongjmp): Cygwin has
24968         siglongjmp, but only as a macro.
24969         * doc/posix-functions/_longjmp.texi (_longjmp): Mention that this
24970         is obsolete.
24971         * doc/posix-functions/_setjmp.texi (_setjmp): Likewise.
24972
24973         Tweak documentation to cover cygwin argz bugs.
24974         * m4/argz.m4 (gl_FUNC_ARGZ): Mention date of last known cygwin
24975         argz bug fix; no code change needed since no cygwin releases
24976         occurred between the last fix and the bug being tested.
24977         * doc/glibc-functions/argz_add.texi (argz_add): Document the argz
24978         module and recently fixed cygwin bugs.
24979         * doc/glibc-functions/argz_add_sep.texi (argz_add_sep): Likewise.
24980         * doc/glibc-functions/argz_append.texi (argz_append): Likewise.
24981         * doc/glibc-functions/argz_count.texi (argz_count): Likewise.
24982         * doc/glibc-functions/argz_create.texi (argz_create): Likewise.
24983         * doc/glibc-functions/argz_create_sep.texi (argz_create_sep):
24984         Likewise.
24985         * doc/glibc-functions/argz_delete.texi (argz_delete): Likewise.
24986         * doc/glibc-functions/argz_extract.texi (argz_extract): Likewise.
24987         * doc/glibc-functions/argz_insert.texi (argz_insert): Likewise.
24988         * doc/glibc-functions/argz_next.texi (argz_next): Likewise.
24989         * doc/glibc-functions/argz_replace.texi (argz_replace): Likewise.
24990         * doc/glibc-functions/argz_stringify.texi (argz_stringify):
24991         Likewise.
24992
24993         Avoid gcc warning on cygwin.
24994         * lib/copy-acl.c (qcopy_acl) [!HAVE_ACL_GET_FILE &&
24995         !ACL_NO_TRIVIAL]: Avoid unused variable.
24996
24997 2008-06-05  Eric Blake  <ebb9@byu.net>
24998
24999         Be tolerant of UNKNOWN version in gnulib-tool test dir.
25000         * top/GNUmakefile (_dummy): Warn rather than reconfigure if
25001         git-version-gen fails to come up with a version.
25002         Reported by Simon Josefsson.
25003
25004 2008-06-05  Jim Meyering  <meyering@redhat.com>
25005             Paul Eggert  <eggert@cs.ucla.edu>
25006
25007         utimens.c: work around a probable Linux kernel bug
25008         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT]: Work around what
25009         appears to be a kernel bug that causes utimensat to return 280
25010         instead of 0, indicating success.
25011
25012 2008-06-04  Bruno Haible  <bruno@clisp.org>
25013
25014         * lib/copy-acl.c (qcopy_acl): Call qset_acl, not set_acl. Fixes
25015         2008-06-01 commit.
25016
25017 2008-06-04  Bruno Haible  <bruno@clisp.org>
25018
25019         * lib/acl-internal.h (acl_access_nontrivial): New declaration.
25020         * lib/file-has-acl.c (acl_access_nontrivial): New function.
25021         (file_has_acl): Use it. Save errno afterwards.
25022         * lib/copy-acl.c (qcopy_acl): Use acl_access_nontrivial.
25023
25024 2008-06-03  Bruno Haible  <bruno@clisp.org>
25025
25026         * lib/file-has-acl.c (file_has_acl): Put Solaris 10 code after POSIX-
25027         draft code. Simplify #ifs.
25028         * lib/set-mode-acl.c (qset_acl): Don't test for symlink if !USE_ACL.
25029         Put Solaris code after POSIX-draft code. Fix comments regarding
25030         Solaris 10, HP-UX. Mention Cygwin.
25031         * lib/copy-acl.c (qcopy_acl): Simplify #ifs.
25032
25033 2008-06-03  Eric Blake  <ebb9@byu.net>
25034
25035         Provide fallback for older kernels.
25036         * lib/utimens.c (gl_futimens) [HAVE_UTIMENSAT, HAVE_FUTIMENS]:
25037         Provide runtime fallback if kernel lacks support.
25038         Reported by Mike Frysinger.
25039
25040 2008-06-02  Bruno Haible  <bruno@clisp.org>
25041
25042         * lib/acl-internal.h (ACL_NOT_WELL_SUPPORTED): Include EOPNOTSUPP if
25043         it exists.
25044
25045 2008-06-02  Bruno Haible  <bruno@clisp.org>
25046
25047         * lib/acl_entries.c (acl_entries): Rewrite to use acl_get_entry.
25048         * lib/copy-acl.c (qcopy_acl): Update comment.
25049
25050 2008-06-02  Bruno Haible  <bruno@clisp.org>
25051
25052         * lib/acl-entries.h: Enclose most definitions in #ifs for POSIX-draft
25053         like ACL APIs.
25054
25055 2008-06-02  Bruno Haible  <bruno@clisp.org>
25056
25057         * tests/test-file-has-acl.sh: Use different code for Cygwin.
25058         * tests/test-set-mode-acl.sh: Likewise.
25059         * tests/test-copy-acl.sh: Likewise.
25060         * tests/test-copy-file.sh: Likewise.
25061
25062 2008-06-02  Bruno Haible  <bruno@clisp.org>
25063
25064         * tests/test-file-has-acl.sh: Remove unused code.
25065
25066 2008-06-01  Bruno Haible  <bruno@clisp.org>
25067
25068         * lib/copy-acl.c (qcopy_acl): New function, extracted from copy_acl.
25069         (copy_acl): Just a wrapper around qcopy_acl that emits the error
25070         messages.
25071         * lib/set-mode-acl.c (qset_acl): Document return value precisely.
25072
25073 2008-06-01  Bruno Haible  <bruno@clisp.org>
25074
25075         * m4/acl.m4 (gl_FUNC_ACL): Separate the POSIX-like and the Solaris
25076         tests. Test for libpacl, needed for OSF/1. Test for extended ACLs,
25077         needed for MacOS X. Test for HP-UX API. Test for newer and older AIX
25078         APIs.
25079         * modules/acl-tests (configure.ac): Remove tests now contained in
25080         m4/acl.m4.
25081
25082 2008-06-02  Jim Meyering  <meyering@redhat.com>
25083
25084         announce-gen: use a better key-server host name
25085         * build-aux/announce-gen (main): Recommend keys.gnupg.net, since
25086         it may be more consistently reliable.  Suggested by Werner Koch
25087         in <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/13717>.
25088
25089 2008-06-01  Bruno Haible  <bruno@clisp.org>
25090
25091         * lib/stdio-impl.h (fp_ub): Use fp_. Needed for DragonFly BSD.
25092         Reported by Voroskoi Andras <voroskoi@gmail.com>.
25093
25094 2008-06-01  Voroskoi Andras  <voroskoi@gmail.com>  (tiny change)
25095
25096         * lib/stdio-impl.h [__DragonFly__]: Fix typo.
25097
25098 2008-06-01  Bruno Haible  <bruno@clisp.org>
25099
25100         New ACL tests.
25101         * tests/test-file-has-acl.sh: New file.
25102         * tests/test-file-has-acl.c: New file.
25103         * tests/test-set-mode-acl.sh: New file.
25104         * tests/test-set-mode-acl.c: New file.
25105         * tests/test-copy-acl.sh: New file, based on tests/test-copy-file.sh.
25106         * tests/test-copy-acl.c: New file.
25107         * modules/acl-tests: New file, based on modules/copy-file-tests.
25108         * modules/copy-file-tests (Files): Remove tests/test-sameacls.c.
25109         (Depends-on): Add acl-tests.
25110         (configure.ac): Remove checks.
25111         (Makefile.am): Don't create test-sameacls program here any more.
25112
25113 2008-06-01  Bruno Haible  <bruno@clisp.org>
25114
25115         * tests/test-copy-file.sh: Portability fixes for Solaris, HP-UX, IRIX.
25116         * tests/test-sameacls.c: Include progname.h.
25117         (main): Invoke set_program_name. Portability fixes for MacOS X,
25118         Solaris, HP-UX.
25119
25120 2008-06-01  Bruno Haible  <bruno@clisp.org>
25121
25122         * lib/freadahead.c (freadahead) [__DragonFly__]: Use the __sreadahead
25123         function.
25124         Reported by VOROSKOI Andras <voroskoi@gmail.com>.
25125
25126 2008-06-01  Bruno Haible  <bruno@clisp.org>
25127
25128         * modules/rpmatch (Depends-on): Add strdup.
25129
25130 2008-06-01  Bruno Haible  <bruno@clisp.org>
25131
25132         * lib/pipe.c: Include unistd-safer.h.
25133         (create_pipe): Ensure the returned file descriptors are not in {0,1,2}.
25134         * modules/pipe (Depends-on): Add unistd-safer.
25135
25136 2008-05-30  Simon Josefsson  <simon@josefsson.org>
25137
25138         * modules/autobuild (configure.ac): Call AB_INIT.
25139
25140 2008-05-30  Simon Josefsson  <simon@josefsson.org>
25141
25142         * tests/test-getaddrinfo.c: Don't print debug messages by default.
25143         Suggested by Bruno Haible <bruno@clisp.org>.
25144
25145 2008-05-30  Simon Josefsson  <simon@josefsson.org>
25146
25147         * tests/test-base64.c: Cast size_t to unsigned long when invoking
25148         printf.  Use %lu instead of %d.  Reported by Bruno Haible
25149         <bruno@clisp.org>.
25150
25151 2008-05-29  Eric Blake  <ebb9@byu.net>
25152
25153         Prefer new POSIX 200x interfaces over futimesat.
25154         * m4/utimens.m4 (gl_UTIMENS): Check for futimens, utimensat.
25155         * lib/utimens.c (gl_futimens): Use them for nanosecond resolution
25156         when available.
25157         [HAVE_BUGGY_NFS_TIME_STAMPS]: Allow C89 compilation.
25158
25159 2008-05-28  Bruno Haible  <bruno@clisp.org>
25160
25161         * modules/stpcpy (License): Change to LGPLv2+.
25162         Requested by David Lutterkort <dlutter@redhat.com>.
25163
25164 2008-05-27  Bruno Haible  <bruno@clisp.org>
25165
25166         * lib/localename.c (SUBLANG_TIBETAN_BHUTAN): Force value 2. Needed for
25167         current mingw.
25168         Reported by Jose E. Marchesi <jemarch@gnu.org>.
25169
25170 2008-05-27  Bruno Haible  <bruno@clisp.org>
25171
25172         * modules/iconv_open (Link): New section, from module 'iconv'.
25173         * modules/striconv (Link): Likewise.
25174         * modules/striconveh (Link): Likewise.
25175         * modules/xstriconv (Link): Likewise.
25176         * modules/unicodeio (Link): Likewise.
25177         * modules/propername (Link): Likewise.
25178         Reported by Jim Meyering.
25179
25180 2008-05-26  Jim Meyering  <meyering@redhat.com>
25181
25182         sha256: do not artificially restrict buffer length to be < 2^32
25183         * lib/sha256.h (struct sha256_ctx) [buflen]: Change type from
25184         uint32_t to size_t.
25185         * lib/sha256.c (sha256_conclude_ctx): Change type of a local
25186         to match.
25187
25188         avoid unaligned access errors, e.g., on sparc
25189         * lib/sha512.c (sha512_conclude_ctx): Use set_uint64 rather than
25190         direct access through a possibly-unaligned uint64* pointer.
25191         * lib/sha256.c (sha256_conclude_ctx): Use set_uint32 rather than
25192         direct access through a possibly-unaligned uint32* pointer.
25193         Prompted by this patch from Tom "spot" Callaway:
25194         http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13638
25195
25196         sha512.c: fix typo in comment
25197         * lib/sha512.c (sha512_conclude_ctx): Length is 128-bit, not 64-bit.
25198
25199 2008-05-25  Bruno Haible  <bruno@clisp.org>
25200
25201         * lib/set-mode-acl.c: Renamed from lib/acl.c.
25202         * modules/acl (Files): Add lib/set-mode-acl.c, remove lib/acl.c.
25203         (Makefile.am): Update lib_SOURCES.
25204
25205 2008-05-25  Bruno Haible  <bruno@clisp.org>
25206
25207         * m4/acl.m4 (gl_FUNC_ACL): Don't set LIB_ACL_TRIVIAL.
25208
25209 2008-05-25  Jim Meyering  <meyering@redhat.com>
25210
25211         useless-if-before-free: freed expr may have white-space differences
25212         * build-aux/useless-if-before-free: Recognize cases in which the
25213         freed expression differs from the tested one in embedded white
25214         space, e.g., if (p[i + 1]) free(p[i+1]).  Correct thinko in prev:
25215         $1 was used, so we can't make any regexp shy.  Improved tests now
25216         detect this.
25217
25218         useless-if-before-free: accept white space in the expression.
25219         * build-aux/useless-if-before-free: For now, any white space
25220         in the expression must be identical in the free argument.
25221
25222         useless-if-before-free: efficiency tweak
25223         * build-aux/useless-if-before-free: Make the expression-matching
25224         regexp "shy".
25225         Make the *outer* regexp shy, not the expr-matching one.
25226
25227         update code-in-comment to accept cast of free arg
25228         * build-aux/useless-if-before-free: Update regexp.
25229
25230 2008-05-25  Bruno Haible  <bruno@clisp.org>
25231
25232         * tests/test-sameacls.c: Renamed from tests/test-copy-file-sameacls.c.
25233         * modules/copy-file-tests (Files, Makefile.am): Update.
25234         * tests/test-copy-file.c (func_test_copy): Update.
25235
25236 2008-05-24  Andreas Färber  <andreas.faerber@web.de>  (tiny change)
25237
25238         * lib/stdbool.in.h [__HAIKU__]: Disable __BEOS__ workarounds.
25239
25240 2008-05-23  Bruno Haible  <bruno@clisp.org>
25241
25242         Improve support for ACLs on OSF/1.
25243         * lib/acl.c (qset_acl): For OSF/1, use a string that ends in a comma.
25244         Remove fallback for unknown flavors of ACLs.
25245
25246 2008-05-22  Bruno Haible  <bruno@clisp.org>
25247
25248         Add support for ACLs on OSF/1.
25249         * lib/acl-internal.h (acl_get_fd, acl_set_fd): New inline function
25250         replacements.
25251         (acl_free_text): New macro fallback.
25252         * lib/acl_entries.c (acl_entries): Use acl_free_text instead of
25253         acl_free.
25254         * m4/acl.m4 (gl_FUNC_ACL): Look also in libpacl library. Test for
25255         acl_free_text function. Require AC_C_INLINE.
25256
25257 2008-05-22  Bruno Haible  <bruno@clisp.org>
25258
25259         Make copy_acl work on MacOS X 10.5.
25260         * lib/acl-internal.h (MODE_INSIDE_ACL): New macro.
25261         (ACL_NOT_WELL_SUPPORTED): On MacOS X, also handle ENOENT.
25262         * lib/acl.c (qset_acl): Add different code branch for !MODE_INSIDE_ACL.
25263         If MODE_INSIDE_ACL, don't assume that every system has the same text
25264         representation for ACLs as FreeBSD.
25265         * lib/copy-acl.c (copy_acl): Add support for platforms with
25266         !MODE_INSIDE_ACL.
25267         * lib/file-has-acl.c (file_has_acl): Likewise.
25268         * m4/acl.m4 (gl_FUNC_ACL): Test for some functions that are witness of
25269         FreeBSD, MacOS X, or IRIX, respectively.
25270
25271 2008-05-22  Bruno Haible  <bruno@clisp.org>
25272
25273         * lib/acl.h: Don't include <sys/acl.h>.
25274         (GETACLCNT): Move fallback to lib/acl-internal.h.
25275         * lib/acl-internal.h: Include <sys/acl.h> here.
25276         (GETACLCNT): New macro fallback, moved here from lib/acl.h.
25277
25278 2008-05-22  Bruno Haible  <bruno@clisp.org>
25279
25280         Split off copy_acl function to separate file.
25281         * lib/copy-acl.c: New file, extracted from lib/acl.c.
25282         * lib/acl.c (copy_acl): Moved function to separate file.
25283         * m4/acl.m4 (gl_FUNC_ACL): Remove unconditional AC_LIBOBJs.
25284         * modules/acl (Files): Add lib/copy-acl.c.
25285         (Makefiles.am): Augment lib_SOURCES.
25286
25287 2008-05-22  Bruno Haible  <bruno@clisp.org>
25288
25289         * modules/copy-file-tests: New file.
25290         * tests/test-copy-file.sh: New file.
25291         * tests/test-copy-file.c: New file.
25292         * tests/test-copy-file-sameacls.c: New file.
25293
25294 2008-05-22  Eric Blake  <ebb9@byu.net>
25295
25296         Avoid gcc warning.
25297         * tests/test-memcmp.c (main): Pass NULL indirectly.
25298
25299 2008-05-21  Bruno Haible  <bruno@clisp.org>
25300
25301         Add reference doc about ACLs.
25302         * doc/acl-resources.txt: New file.
25303         * doc/acl-cygwin.txt: New file.
25304
25305 2008-05-21  Bruno Haible  <bruno@clisp.org>
25306
25307         Avoid one more warning from gcc.
25308         * lib/vasnprintf.c (IF_LINT): Update comments.
25309         (VASNPRINTF): Use it also for the 'prefix' array initializer.
25310
25311 2008-05-21  Jim Meyering  <meyering@redhat.com>
25312
25313         avoid a warning from gcc
25314         * lib/vasnprintf.c (IF_LINT): Define.
25315         (scale10_round_decimal_long_double):
25316         Use it to avoid a "may be used uninitialized" warning.
25317         (scale10_round_decimal_double): Likewise.
25318
25319 2008-05-21  Simon Josefsson  <simon@josefsson.org>
25320
25321         * m4/memcmp.m4: When cross-compiling, assume memcmp works if it is
25322         declared.
25323
25324 2008-05-20  Bruno Haible  <bruno@clisp.org>
25325
25326         * tests/test-memcmp.c (main): Test also the sign of the result. Test
25327         against two known bugs; code taken from autoconf's AC_FUNC_MEMCMP.
25328
25329 2008-05-20  Simon Josefsson  <simon@josefsson.org>
25330
25331         * modules/memcmp-tests: New file.
25332         * tests/test-memcmp.c: New file.
25333
25334 2008-05-19  Bruno Haible  <bruno@clisp.org>
25335
25336         * modules/propername (Notice, configure.ac): Put quoted "..." into
25337         --keyword option.
25338         * lib/propername.h: Update comments accordingly.
25339         Reported by Eric Blake.
25340
25341 2008-05-19  Martin Lambers  <marlam@marlam.de>  (tiny change)
25342
25343         * modules/getpass-gnu (Depends-on): Add fseeko.
25344
25345 2008-05-19  Simon Josefsson  <simon@josefsson.org>
25346
25347         * modules/base64-tests: New file.
25348
25349 2008-05-19  Bo Borgerson <gigabo@gmail.com>
25350
25351         * lib/base64.c (base64_decode_ctx): If a decode context structure
25352         was passed in use it to ignore newlines.  If a context structure
25353         was _not_ passed in, continue to treat newlines as garbage (this
25354         is the historical behavior).  Formerly base64_decode.
25355         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
25356         takes a decode context structure.
25357         * lib/base64.h (base64_decode): Macro for four-argument calls.
25358         (base64_decode_alloc): Likewise.
25359         * lib/base64.c (base64_decode_ctx): If a decode context structure
25360         was passed in use it to ignore newlines.  If a context structure
25361         was _not_ passed in, continue to treat newlines as garbage (this
25362         is the historical behavior).  Formerly base64_decode.
25363         (base64_decode_alloc_ctx): Formerly base64_decode_alloc.  Now
25364         takes a decode context structure.
25365         * lib/base64.h (base64_decode): Macro for four-argument calls.
25366         (base64_decode_alloc): Likewise.
25367
25368 2008-05-19  Jim Meyering  <meyering@redhat.com>
25369
25370         avoid a warning from gcc
25371         * lib/trim.c (IF_LINT): Define.
25372         (trim2): Use it to avoid a "may be used uninitialized" warning.
25373
25374         Fix doc typo.
25375         * doc/glibc-functions/getpass.texi (getpass): s/PATH_MAX/PASS_MAX/.
25376
25377 2008-05-19  Bruno Haible  <bruno@clisp.org>
25378
25379         * doc/glibc-functions/getpass.texi: Document limits of other
25380         implementations.
25381
25382 2008-05-19  Simon Josefsson  <simon@josefsson.org>
25383             Bruno Haible <bruno@clisp.org>
25384
25385         * doc/glibc-functions/getpass.texi: Document gnulib implementation.
25386
25387 2008-05-18  Bruno Haible  <bruno@clisp.org>
25388
25389         * modules/propername: New file, from GNU gettext.
25390         * lib/propername.h: New file, from GNU gettext.
25391         * lib/propername.c: New file, from GNU gettext.
25392         * MODULES.html.sh (Internationalization functions): Add propername.
25393
25394 2008-05-16  Jim Meyering  <meyering@redhat.com>
25395             Bruno Haible  <bruno@clisp.org>
25396
25397         Avoid some warnings from "gcc -Wshadow".
25398         * lib/vasnprintf.c (exp, remainder): Define to different identifiers.
25399
25400 2008-05-15  Eric Blake  <ebb9@byu.net>
25401
25402         Extend previous patch to cygwin 1.7.0.
25403         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a
25404         fast implementation in cygwin >= 1.7.0.
25405         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
25406         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
25407
25408 2008-05-15  Bruno Haible  <bruno@clisp.org>
25409
25410         * m4/memmem.m4 (gl_FUNC_MEMMEM): When cross-compiling, assume a fast
25411         implementation in glibc >= 2.9.
25412         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
25413         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
25414
25415 2008-05-15  Bruno Haible  <bruno@clisp.org>
25416
25417         * MODULES.html.sh (Internationalization functions): Remove linebreak.
25418         (Unicode string functions): Add unilbrk/*.
25419         Reported by Karl Berry.
25420
25421 2008-05-15  Eric Blake  <ebb9@byu.net>
25422
25423         Fix violation of <stdbool.h> replacement in regex.
25424         * lib/regcomp.c (re_compile_internal): Avoid implicit cast to bool.
25425         * lib/regexec.c (re_search_internal): Likewise.
25426         Reported by Heinrich Mislik <Heinrich.Mislik@univie.ac.at>.
25427
25428 2008-05-15  Jim Meyering  <meyering@redhat.com>
25429
25430         avoid distracting test output when git or cvs is not found
25431         * tests/test-vc-list-files-cvs.sh: Suppress 'init' error output.
25432         * tests/test-vc-list-files-git.sh: Likewise.
25433
25434 2008-05-15  Eric Blake  <ebb9@byu.net>
25435
25436         Glibc finally accepted the memmem speedup code, bugzilla #5514.
25437         * doc/glibc-functions/memmem.texi (memmem): Mention last broken
25438         glibc version.
25439         * doc/glibc-functions/strcasestr.texi (strcasestr): Likewise.
25440         * doc/posix-functions/strstr.texi (strstr): Likewise.
25441         * lib/str-two-way.h (MAX): Sychronize with glibc.
25442
25443 2008-05-15  Paolo Bonzini  <bonzini@gnu.org>
25444
25445         * lib/regcomp.c (optimize_utf8): Add a note on why we test
25446         opr.ctx_type.
25447         (calc_first): Initialize constraint field.
25448         (duplicate_node_closure): Use it instead of special casing ANCHORS.
25449         Fix grammar.
25450         (duplicate_node): Merge constraint field for all node types.
25451         (calc_eclosure_iter): Look at constraint field for all node types.
25452         * lib/regex_internal.c (create_cd_newstate): Don't look at
25453         opr.ctx_type.
25454
25455 2008-05-14  Bruno Haible  <bruno@clisp.org>
25456
25457         Help GCC to do better code generation.
25458         * lib/eealloc.h (eemalloc) [GCC >= 3]: Declare with attribute 'malloc'.
25459         * lib/pagealign_alloc.h (pagealign_alloc, pagealign_xalloc): Likewise.
25460         * lib/xalloc.h (ATTRIBUTE_MALLOC): New macro.
25461         (xmalloc, xzalloc, xcalloc, xmemdup, xstrdup, xnmalloc, xcharalloc):
25462         Declare with attribute 'malloc' if supported.
25463
25464 2008-05-14  Lasse Collin  <lasse.collin@tukaani.org>
25465
25466         use "echo STR|wc -c" rather than unportable "expr length STR"
25467         * build-aux/mktempd (mktempd): Vendor-supplied expr from at least
25468         OpenBSD 4.3 and Solaris 10 do not honor expr's "length" function.
25469
25470 2008-05-14  Jim Meyering  <meyering@redhat.com>
25471
25472         use dd ibs=$n count=1 ... rather than less-portable head -c$n
25473         * build-aux/mktempd (rand_bytes): head's -cN option is not accepted
25474         by Solaris 10's /bin/head or by the one from HP-UX 11.x.
25475         Reported in http://sourceforge.net/forum/message.php?msg_id=4960334
25476         via Collin Lasse.
25477
25478 2008-05-14  Eric Blake  <ebb9@byu.net>
25479
25480         Avoid quadratic growth in gl_LIBSOURCES.
25481         * gnulib-tool (func_emit_initmacro_done): s/\(m4_append\)_uniq/\1/.
25482         Suggested by Bruno Haible.
25483
25484         Test xmemdup0.
25485         * modules/xmemdup0-tests: New file.
25486         * tests/test-xmemdup0.c: Likewise.
25487
25488 2008-05-13  Eric Blake  <ebb9@byu.net>
25489
25490         Split xmemdup0 into its own module.
25491         * modules/xmemdup0: New file.
25492         * lib/xmemdup0.h: Likewise.
25493         * lib/xmemdup0.c: Likewise.
25494         * MODULES.html.sh (Memory management functions): Add xmemdup0.
25495         * lib/xalloc.h (xmemdup0): Remove.
25496         * lib/xmalloc.c (xmemdup0): Likewise.
25497
25498 2008-05-13  Eric Blake  <ebb9@byu.net>
25499             Bruno Haible  <bruno@clisp.org>
25500
25501         Reduce number of forks required during autoconf.
25502         * gnulib-tool (func_emit_initmacro_start): Prepare gl_LIBSOURCES_LIST
25503         and gl_LIBSOURCES_DIR.
25504         (func_emit_initmacro_end): Use them here in a single m4_syscmd...
25505         (func_emit_initmacro_done) <gl_LIBSOURCES>: ...rather than in one
25506         m4_syscmd per file.
25507         <m4_foreach_w>: Move...
25508         * m4/gnulib-common.m4 (m4_foreach_w): ...here.
25509
25510 2008-05-13  Eric Blake  <ebb9@byu.net>
25511
25512         * gnulib-tool: Fix various comment typos.
25513
25514 2008-05-12  Bruno Haible  <bruno@clisp.org>
25515
25516         Tailor the linebreaking algorithm.
25517         * lib/unilbrk/tables.c (unilbrk_table): Change (IS,AL) entry.
25518
25519 2008-05-12  Bruno Haible  <bruno@clisp.org>
25520
25521         Update to Unicode 5.0.0.
25522         * lib/unilbrk/tables.h (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
25523         LBP_JV, LBP_JT. Redistribute values.
25524         (unilbrk_table): Change size.
25525         * lib/unilbrk/tables.c (unilbrk_table): Change size. Update to match
25526         Unicode TR#14 rev. 22.
25527         * lib/unilbrk/gen-lbrk.c (LBP_*): Add LBP_WJ, LBP_H2, LBP_H3, LBP_JL,
25528         LBP_JV, LBP_JT. Redistribute values.
25529         (get_lbp): Update to match Unicode TR#14 rev. 21/22 and Unicode 5.0.0.
25530         (debug_output_lbp, fill_org_lbp, debug_output_org_lbp, output_lbp):
25531         Update.
25532         * lib/unilbrk/lbrkprop1.h: Regenerated.
25533         * lib/unilbrk/lbrkprop2.h: Regenerated.
25534         * lib/unilbrk/u8-possible-linebreaks.c (u8_possible_linebreaks):
25535         Change handling of LBP_CM after LBP_ZW. Update for new value of LBP_BK.
25536         * lib/unilbrk/u16-possible-linebreaks.c (u16_possible_linebreaks):
25537         Likewise.
25538         * lib/unilbrk/u32-possible-linebreaks.c (u32_possible_linebreaks):
25539         Likewise.
25540         * tests/unilbrk/test-u8-possible-linebreaks.c (main): Update expected
25541         result.
25542         * tests/unilbrk/test-u16-possible-linebreaks.c (main): Likewise.
25543         * tests/unilbrk/test-u32-possible-linebreaks.c (main): Likewise.
25544         * tests/unilbrk/test-ulc-possible-linebreaks.c (main): Likewise.
25545         * tests/unilbrk/test-u8-width-linebreaks.c (main): Likewise.
25546         * tests/unilbrk/test-u16-width-linebreaks.c (main): Likewise.
25547         * tests/unilbrk/test-u32-width-linebreaks.c (main): Likewise.
25548
25549 2008-05-11  Bruno Haible  <bruno@clisp.org>
25550
25551         * lib/unilbrk/gen-lbrk.c (output_lbp): Fix whitespace.
25552
25553 2008-05-11  Bruno Haible  <bruno@clisp.org>
25554
25555         * lib/unilbrk/gen-lbrk.c: New file, from GNU gettext (gen-lbrkprop.c).
25556         * modules/unilbrk/gen-lbrk: New file.
25557
25558 2008-05-11  Bruno Haible  <bruno@clisp.org>
25559
25560         * m4/sha256.m4 (gl_SHA256): Require AC_C_INLINE.
25561         * m4/sha512.m4 (gl_SHA512): Likewise.
25562
25563 2008-05-11  Jim Meyering  <meyering@redhat.com>
25564
25565         New modules: crypto/sha256, crypto/sha512 (from coreutils)
25566         * modules/crypto/sha256: New file.
25567         * modules/crypto/sha512: Likewise.
25568         * lib/sha256.c: Likewise.
25569         * lib/sha256.h: Likewise.
25570         * lib/sha512.c: Likewise.
25571         * lib/sha512.h: Likewise.
25572         * lib/u64.h: Likewise.
25573         * m4/sha256.m4: Likewise.
25574         * m4/sha512.m4: Likewise.
25575         * MODULES.html.sh (Cryptographic computations (low-level)): List them.
25576
25577 2008-05-10  Bruno Haible  <bruno@clisp.org>
25578
25579         * MODULES.html.sh (Environment variables <stdlib.h>): Add unsetenv.
25580         (Input/Output <stdio.h>): Add xprintf.
25581         (Signal handling <signal.h>): Add strsignal.
25582         (Cryptographic computations (high-level)): Add crypto/gc-camellia.
25583         (Core language properties): Add func.
25584         (Mathematics <math.h>): Add ceil, floor, frexp-nolibm.
25585         (Support for systems lacking POSIX:2001): Add environ, EOVERFLOW,
25586         strings.
25587         (Enhancements for POSIX:2001 functions): Add iconv_open-utf.
25588         (Input/output): New section.
25589         (File system functions): Add openat-die, stat-macros.
25590         (Networking functions): Add sockets.
25591         (Unicode string functions): Add unictype/*.
25592         (Support for building libraries and executables): Add gperf.
25593         (Support for building documentation): Add agpl-3.0.
25594         (Misc): Add nocrash.
25595
25596 2008-05-10  Bruno Haible  <bruno@clisp.org>
25597
25598         * modules/unictype/gen-ctype: New file.
25599
25600 2008-05-10  Jim Meyering  <meyering@redhat.com>
25601
25602         Make chdir-safer.c more efficient on a system with no symlinks.
25603         * lib/chdir-safer.c (chdir_no_follow): Skip lstat and fstat calls
25604         also if ELOOP is zero.  Suggested by Bruno Haible.
25605
25606         Make chdir-safer.c slightly safer.
25607         * lib/chdir-safer.c (chdir_no_follow): Test HAVE_WORKING_O_NOFOLLOW,
25608         not O_NOFOLLOW, in case the latter is nonzero and open ignores it.
25609
25610         Avoid compile failure on systems without ELOOP (like mingw).
25611         * lib/chdir-safer.c (ELOOP): Define if not already defined.
25612         Reported by Bruno Haible.
25613
25614 2008-05-10  Bruno Haible  <bruno@clisp.org>
25615
25616         * lib/unilbrk/ulc-common.c: Include c-strcaseeq.h instead of streq.h.
25617         (is_utf8_encoding): Use a case-insensitive comparison.
25618         * modules/unilbrk/ulc-common (Depends-on): Add c-strcaseeq. Remove
25619         streq.
25620
25621 2008-05-10  Bruno Haible  <bruno@clisp.org>
25622
25623         * lib/unilbrk/ulc-common.c: Don't include <stdlib.h>.
25624         (iconv_string_length, iconv_string_keeping_offsets): Remove functions.
25625         * lib/unilbrk/ulc-common.h (iconv_string_length,
25626         iconv_string_keeping_offsets): Remove declarations.
25627         * lib/unilbrk/ulc-possible-linebreaks.c: Include <string.h>, uniconv.h.
25628         Don't include <iconv.h>, streq.h, xsize.h.
25629         (ulc_possible_linebreaks): Use u8_conv_from_encoding for doing the
25630         conversion.
25631         * lib/unilbrk/ulc-width-linebreaks.c: Include uniconv.h. Don't include
25632         <iconv.h>, streq.h, xsize.h.
25633         (ulc_width_linebreaks): Use u8_conv_from_encoding for doing the
25634         conversion.
25635         * modules/unilbrk/ulc-common (Depends-on): Remove iconv.
25636         * modules/unilbrk/ulc-possible-linebreaks (Depends-on): Add
25637         uniconv/u8-conv-from-enc. Remove iconv_open, streq, xsize.
25638         * modules/unilbrk/ulc-width-linebreaks (Depends-on): Likewise.
25639
25640 2008-05-10  Bruno Haible  <bruno@clisp.org>
25641
25642         * modules/unilbrk/ulc-width-linebreaks-tests: New file.
25643         * tests/unilbrk/test-ulc-width-linebreaks.c: New file.
25644
25645         * modules/unilbrk/u32-width-linebreaks-tests: New file.
25646         * tests/unilbrk/test-u32-width-linebreaks.c: New file.
25647
25648         * modules/unilbrk/u16-width-linebreaks-tests: New file.
25649         * tests/unilbrk/test-u16-width-linebreaks.c: New file.
25650
25651         * modules/unilbrk/u8-width-linebreaks-tests: New file.
25652         * tests/unilbrk/test-u8-width-linebreaks.c: New file.
25653
25654         * modules/unilbrk/ulc-possible-linebreaks-tests: New file.
25655         * tests/unilbrk/test-ulc-possible-linebreaks.c: New file.
25656
25657         * modules/unilbrk/u32-possible-linebreaks-tests: New file.
25658         * tests/unilbrk/test-u32-possible-linebreaks.c: New file.
25659
25660         * modules/unilbrk/u16-possible-linebreaks-tests: New file.
25661         * tests/unilbrk/test-u16-possible-linebreaks.c: New file.
25662
25663         * modules/unilbrk/u8-possible-linebreaks-tests: New file.
25664         * tests/unilbrk/test-u8-possible-linebreaks.c: New file.
25665
25666 2008-05-10  Bruno Haible  <bruno@clisp.org>
25667
25668         Split up 'linebreak' module.
25669         * lib/unilbrk.h: New file, based on lib/linebreak.h.
25670         * lib/unilbrk/lbrkprop1.h: New file, extracted from lib/lbrkprop.h.
25671         * lib/unilbrk/lbrkprop2.h: New file, renamed from lib/lbrkprop.h with
25672         modifications.
25673         * lib/unilbrk/tables.h: New file, extracted from lib/linebreak.c.
25674         * lib/unilbrk/tables.c: New file, extracted from lib/linebreak.c.
25675         * lib/unilbrk/u8-possible-linebreaks.c: New file, extracted from
25676         lib/linebreak.c.
25677         * lib/unilbrk/u16-possible-linebreaks.c: New file, extracted from
25678         lib/linebreak.c.
25679         * lib/unilbrk/u32-possible-linebreaks.c: New file, extracted from
25680         lib/linebreak.c.
25681         * lib/unilbrk/ulc-common.h: New file, extracted from lib/linebreak.c.
25682         * lib/unilbrk/ulc-common.c: New file, extracted from lib/linebreak.c.
25683         * lib/unilbrk/ulc-possible-linebreaks.c: New file, extracted from
25684         lib/linebreak.c.
25685         * lib/unilbrk/u8-width-linebreaks.c: New file, extracted from
25686         lib/linebreak.c.
25687         * lib/unilbrk/u16-width-linebreaks.c: New file, extracted from
25688         lib/linebreak.c.
25689         * lib/unilbrk/u32-width-linebreaks.c: New file, extracted from
25690         lib/linebreak.c.
25691         * lib/unilbrk/ulc-width-linebreaks.c: New file, extracted from
25692         lib/linebreak.c.
25693         * modules/unilbrk/base: New file.
25694         * modules/unilbrk/tables: New file.
25695         * modules/unilbrk/u8-possible-linebreaks: New file.
25696         * modules/unilbrk/u16-possible-linebreaks: New file.
25697         * modules/unilbrk/u32-possible-linebreaks: New file.
25698         * modules/unilbrk/ulc-common: New file.
25699         * modules/unilbrk/ulc-possible-linebreaks: New file.
25700         * modules/unilbrk/u8-width-linebreaks: New file.
25701         * modules/unilbrk/u16-width-linebreaks: New file.
25702         * modules/unilbrk/u32-width-linebreaks: New file.
25703         * modules/unilbrk/ulc-width-linebreaks: New file.
25704         * lib/linebreak.h: Remove file.
25705         * lib/linebreak.c: Remove file.
25706         * m4/linebreak.m4: Remove file.
25707         * modules/linebreak: Remove file.
25708         * NEWS: Mention the changes.
25709
25710 2008-05-09  Eric Blake  <ebb9@byu.net>
25711
25712         Add xmemdup0.
25713         * lib/xalloc.h (xmemdup0): New prototype and C++ typesafe
25714         implementation.
25715         * lib/xmalloc.c (xmemdup0): New C implementation.
25716
25717 2008-05-08  Bruno Haible  <bruno@clisp.org>
25718
25719         * m4/wctype.m4 (gl_WCTYPE_H): Correct indentation.
25720
25721 2008-05-07  Eric Blake  <ebb9@byu.net>
25722
25723         Support cross-compilation of <wctype.h>.
25724         * m4/wctype.m4 (gl_WCTYPE_H): Fix improper nesting in
25725         AC_CACHE_CHECK.
25726
25727 2008-05-06  Soren Hansen  <soren@ubuntu.com>  (tiny change)
25728
25729         * build-aux/vc-list-files: Add support for bzr.
25730
25731 2008-05-03  Jim Meyering  <meyering@redhat.com>
25732
25733         avoid failed assertion with tight malloc
25734         * tests/test-getndelim2.c: Correct an off-by-one assertion.
25735
25736 2008-05-03  Simon Josefsson  <simon@josefsson.org>
25737
25738         * m4/inet_pton.m4: Set HAVE_DECL_INET_PTON to 0 when declarations
25739         are needed from arpa/inet.h.
25740         * m4/inet_ntop.m4: Likewise, for HAVE_DECL_INET_NTOP.
25741         Reported by Bruno Haible.
25742
25743 2008-05-02  Jim Meyering  <meyering@redhat.com>
25744
25745         avoid compilation error on FreeBSD 6
25746         * tests/test-getaddrinfo.c [!defined EAI_NODATA] (EAI_NODATA): Define.
25747
25748 2008-05-01  Jim Meyering  <meyering@redhat.com>
25749
25750         useless-if-before-free: correct --help's exit status description
25751         * build-aux/useless-if-before-free (usage): Like grep, exit 0
25752         for one or more matches, etc.  Reported by Bruno Haible.
25753
25754         vc-list-files: make the stand-alone gnulib test work
25755         * modules/vc-list-files-tests (configure.ac):
25756         Define and AC_SUBST abs_aux_dir.
25757         (Makefile.am) [TESTS_ENVIRONMENT]: Rather than passing
25758         $(abs_top_srcdir) to each script and having each of them
25759         duplicate the work of setting PATH, set PATH here, using
25760         the new variable, abs_aux_dir instead.
25761         * tests/test-vc-list-files-cvs.sh: Don't set PATH here.
25762         * tests/test-vc-list-files-git.sh: Likewise.
25763         Reported by Bruno Haible.
25764
25765 2008-05-01  Bruno Haible  <bruno@clisp.org>
25766
25767         * lib/getndelim2.c (getndelim2): Fix newsize computation during
25768         reallocation. Rename 'done' to 'found_delimiter'.
25769
25770 2008-05-01  Jim Meyering  <meyering@redhat.com>
25771
25772         vc-list-files: accommodate /bin/sh like the one from Solaris 10
25773         * build-aux/vc-list-files: Use `...`, not $(...).
25774
25775 2008-04-30  Jim Meyering  <meyering@redhat.com>
25776
25777         add tests for vc-list-files
25778         * modules/vc-list-files-tests: New module.
25779         * tests/test-vc-list-files-cvs.sh: New file.
25780         * tests/test-vc-list-files-git.sh: New file.
25781
25782         avoid a warning from gcc
25783         * lib/getndelim2.c (IF_LINT): Define.
25784         (getndelim2): Use it to avoid a "may be used uninitialized" warning.
25785
25786         vc-list-files: work properly with build-aux/cvsu, too
25787         * build-aux/vc-list-files: Hoist the "./"-removing code to apply
25788         to all cvs-based clauses.
25789
25790         vc-list-files: work properly in the CVS+awk case, too
25791         * build-aux/vc-list-files: In the CVS+awk case, remove "./" prefix.
25792
25793         vc-list-files: avoid use of ${*-*} that fails when /bin/sh is dash
25794         * build-aux/vc-list-files: Simplify ${*-*} to $dir, since we no longer
25795         take more than one file argument, so .  Add quotes, just in case $dir
25796         ever contains a shell meta-character.  Prompted by Soren Hansen in
25797         <http://thread.gmane.org/gmane.comp.emulators.libvirt/6221/focus=6240>.
25798
25799 2008-04-29  Eric Blake  <ebb9@byu.net>
25800
25801         Optimize getndelim2 to use block operations when possible.
25802         * modules/getndelim2 (Depends-on): Add stdbool, freadptr,
25803         freadseek, and memchr2.
25804         * lib/getndelim2.c (getndelim2): Use them for block reads.
25805
25806 2008-04-29  Bruno Haible  <bruno@clisp.org>
25807
25808         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_USE_SYSTEM_EXTENSIONS.
25809         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
25810         * modules/inet_ntop (Depends-on): Add extensions.
25811         * modules/inet_pton (Depends-on): Likewise.
25812         Reported by Simon Josefsson.
25813
25814 2008-04-29  Jim Meyering  <meyering@redhat.com>
25815
25816         When the is more than one match in a block, match all of them.
25817         * build-aux/useless-if-before-free: Iterate through each block
25818         until there are no more matches.
25819
25820         Fix broken useless-if-before-free script.
25821         * build-aux/useless-if-before-free: Fix typo: missing "?" after
25822         the expression to match cast of argument to free-like function.
25823
25824 2008-04-29  Eric Blake  <ebb9@byu.net>
25825
25826         Use new header.
25827         * lib/getaddrinfo.c (includes): s/"inet_ntop.h"/<arpa/inet.h>/.
25828
25829 2008-04-29  Jim Meyering  <meyering@redhat.com>
25830
25831         Avoid test segfault on x86_64 due to lack of inet_ntop declaration.
25832         * tests/test-getaddrinfo.c: Include <arpa/inet.h>, now guaranteed
25833         by gnulib to exist and to declare e.g., inet_ntop.
25834         Don't include "inet_ntop.h", now removed.
25835
25836         * m4/arpa_inet_h.m4: Remove trailing blanks.
25837
25838 2008-04-29  Eric Blake  <ebb9@byu.net>
25839
25840         Silence valgrind on safe reads beyond potential array bounds.
25841         * lib/rawmemchr.valgrind: New file.
25842         * lib/strchrnul.valgrind: Likewise.
25843         * modules/rawmemchr (Files): Distribute new file.
25844         * modules/strchrnul (Files): Likewise.
25845         Suggested by Bruno Haible.
25846
25847 2008-04-29  Bruno Haible  <bruno@clisp.org>
25848
25849         * lib/arpa_inet.in.h: Include system's <arpa/inet.h> if it exists.
25850         (inet_ntop, inet_pton): Change portability warning's wording.
25851         * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Set HAVE_ARPA_INET_H.
25852         Invoke gl_CHECK_NEXT_HEADERS.
25853         (gl_ARPA_INET_H_DEFAULTS): Initialize ARPA_INET_H.
25854         * m4/inet_ntop.m4 (gl_INET_NTOP): Require gl_ARPA_INET_H_DEFAULTS and
25855         set ARPA_INET_H.
25856         * m4/inet_pton.m4 (gl_INET_PTON): Likewise.
25857         * modules/arpa_inet (Description): No longer only for systems that
25858         lack it.
25859         (Depends-on): Add include_next.
25860         (Makeile.am): Substitute INCLUDE_NEXT, NEXT_ARPA_INET_H,
25861         HAVE_ARPA_INET_H.
25862
25863 2008-04-29  Jim Meyering  <meyering@redhat.com>
25864
25865         * modules/mkdir (License): Re-license as LGPLv2+.
25866
25867 2008-04-29  Bruno Haible  <bruno@clisp.org>
25868
25869         * modules/rawmemchr (Maintainer): Set to Eric.
25870         * modules/strchrnul (Maintainer): Likewise.
25871
25872 2008-04-29  Simon Josefsson  <simon@josefsson.org>
25873
25874         * m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Set
25875         HAVE_DECL_INET_NTOP and HAVE_DECL_INET_PTON.
25876
25877         * modules/arpa_inet (arpa/inet.h): Use them.
25878
25879 2008-04-28  Eric Blake  <ebb9@byu.net>
25880
25881         Test getndelim2.
25882         * modules/getndelim2-tests: New file.
25883         * tests/test-getndelim2.c: Likewise.
25884         * lib/getndelim2.c (getndelim2): Never return 0.  Lock the
25885         stream.
25886         * m4/getndelim2.m4 (gl_GETNDELIM2): Check for lock functions.
25887
25888         * MODULES.html.sh: Document new module.
25889
25890 2008-04-20  Bruno Haible  <bruno@clisp.org>
25891
25892         * lib/c-stack.c (die): Use raise.
25893         * modules/c-stack (Depends-on): Add raise.
25894
25895 2008-04-28  Bruno Haible  <bruno@clisp.org>
25896
25897         Expect rpmatch to be declared.
25898         * lib/yesno.c (rpmatch): Remove declaration.
25899
25900         Declare rpmatch.
25901         * lib/stdlib.in.h (rpmatch): New declaration.
25902         * lib/rpmatch.c: Include <stdlib.h> first.
25903         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Require AC_USE_SYSTEM_EXTENSIONS and
25904         gl_STDLIB_H_DEFAULTS. Set HAVE_RPMATCH.
25905         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RPMATCH,
25906         HAVE_RPMATCH.
25907         * modules/rpmatch (Depends-on): Add stdlib, extensions.
25908         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
25909         (Include): Set to <stdlib.h>.
25910         * modules/stdlib (Makefile.am): Substitute GNULIB_RPMATCH and
25911         HAVE_RPMATCH.
25912         * NEWS: Document the change.
25913
25914 2008-04-28  Bruno Haible  <bruno@clisp.org>
25915
25916         Change rpmatch to use nl_langinfo when appropriate.
25917         * lib/rpmatch.c: Include stdbool.h, string.h, langinfo.h.
25918         (N_): New macro.
25919         (localized_pattern): New function/macro.
25920         (try): Remove match, nomatch arguments. Copy the pattern into safe
25921         memory before caching it.
25922         (rpmatch): Use localized_pattern. Add translator comments.
25923         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Test for nl_langinfo and YESEXPR.
25924         Suggested by Eric Blake.
25925         * modules/rpmatch (Depends-on): Add stdbool.
25926
25927 2008-04-28  Eric Blake  <ebb9@byu.net>
25928
25929         Add rawmemchr module, matching glibc.
25930         * modules/string (Makefile.am): New indicator.
25931         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set it.
25932         * lib/string.in.h (rawmemchr): Declare when appropriate.
25933         * modules/rawmemchr: New file.
25934         * m4/rawmemchr.m4: Likewise.
25935         * lib/rawmemchr.c: Likewise.
25936         * modules/rawmemchr-tests: Likewise.
25937         * tests/test-rawmemchr.c: Likewise.
25938         * doc/glibc-functions/rawmemchr.texi (rawmemchr): Document
25939         module.
25940         * modules/strchrnul (Depends-on): Add rawmemchr.
25941         * lib/strchrnul.c (strchrnul): Optimize a corner case.
25942
25943         Whitespace cleanup.
25944         * tests/test-strchrnul.c: Reindent.
25945         * lib/strchrnul.c: Likewise.
25946
25947         Optimize and test strchrnul.
25948         * lib/strchrnul.c (strchrnul): Rewrite to do parallel search.
25949         * modules/strchrnul-tests: New file.
25950         * tests/test-strchrnul.c: Likewise.
25951
25952         Remove intprops dependency.
25953         * modules/memchr (Depends-on): Remove intprops.
25954         * modules/memrchr (Depends-on): Likewise.
25955         * modules/memchr2 (Depends-on): Likewise.
25956         * lib/memchr.c (__memchr): Hand-inline the TYPE_MAXIMUM check.
25957         * lib/memrchr.c (__memrchr): Likewise.
25958         * lib/memrchr2.c (memchr2): Likewise.
25959         Reported by Simon Josefsson.
25960
25961 2008-04-28  Simon Josefsson  <simon@josefsson.org>
25962
25963         * m4/sys_socket_h.m4: Move AC_REQUIRE([AC_C_INLINE]) to top.
25964         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
25965
25966 2008-04-28  Simon Josefsson  <simon@josefsson.org>
25967
25968         * lib/inet_ntop.h, lib/inet_pton.h: Remove files.
25969
25970         * lib/inet_ntop.c: Include arpa/inet.h instead of inet_ntop.h.
25971
25972         * lib/inet_pton.c: Include arpa/inet.h instead of inet_pton.h.
25973
25974         * lib/arpa_inet.in.h [@GNULIB_INET_NTOP@]: Inline inet_ntop.h
25975         declarations.
25976         [@GNULIB_INET_PTON@]: Inline inet_pton.h declarations.
25977
25978         * m4/inet_pton.m4: Don't check for header files.
25979
25980         * m4/inet_ntop.m4: Don't check for header files.
25981
25982 2008-04-28  Simon Josefsson  <simon@josefsson.org>
25983
25984         * m4/sys_socket_h.m4: Require AC_C_INLINE when necessary.
25985         * lib/sys_socket.in.h (setsockopt): Use proper win32 tests (don't
25986         trigger for cygwin).
25987         Reported by Bruno Haible  <bruno@clisp.org>.
25988
25989 2008-04-28  Bruno Haible  <bruno@clisp.org>
25990
25991         * doc/posix-functions/strdup.texi: Mention mingw problem.
25992
25993 2008-04-27  Bruno Haible  <bruno@clisp.org>
25994
25995         * modules/stat-time-tests (Depends-on): Add sleep.
25996         * tests/test-stat-time.c (force_unlink): New function.
25997         (cleanup): Use it.
25998         (test_mtime): Remove the ctime related tests.
25999         (test_ctime): New function, containing the ctime related tests.
26000         (main): Call test_ctime, except on native Windows platforms.
26001
26002 2008-04-27  Bruno Haible  <bruno@clisp.org>
26003
26004         * lib/rpmatch.c (rpmatch): Add some comments.
26005         Reported by James Youngman <jay@gnu.org>.
26006
26007 2008-04-27  Bruno Haible  <bruno@clisp.org>
26008
26009         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Also test the behaviour on
26010         quiet NaNs.
26011
26012 2008-04-27  Bruno Haible  <bruno@clisp.org>
26013
26014         Make test-yesno.sh work on mingw.
26015         * tests/test-yesno.sh: Postprocess the output to convert CR/LF to LF.
26016         * tests/test-yesno.c: Include yesno.h first. Include binary-io.h.
26017         (main): Set stdin to binary mode.
26018         * modules/yesno-tests (Depends-on): Add binary-io.
26019
26020 2008-04-27  Bruno Haible  <bruno@clisp.org>
26021
26022         Fix 'isfinite' on x86, x86_64, ia64 platforms.
26023         * tests/test-isfinite.c (test_isfinitel): Also test the behavior on
26024         argument that lie outside the IEEE 854 domain.
26025         * m4/isfinite.m4 (gl_ISFINITEL_WORKS): New macro.
26026         (gl_ISFINITE): Use it.
26027         * doc/posix-functions/isfinite.texi: Document the fixed bugs.
26028
26029 2008-04-27  Bruno Haible  <bruno@clisp.org>
26030
26031         Allow local renaming in config.h.
26032         * lib/memrchr.c (memrchr): Don't undefine outside libc.
26033
26034 2008-04-27  Bruno Haible  <bruno@clisp.org>
26035
26036         * lib/memchr.c (__memchr): Change type of 'i'.
26037         * lib/memchr2.c (memchr2): Likewise.
26038
26039 2008-04-26  Eric Blake  <ebb9@byu.net>
26040         and Bruno Haible  <bruno@clisp.org>
26041
26042         Optimize and test memrchr.
26043         * modules/memrchr (Depends-on): Add intprops.
26044         * lib/memrchr.c (__memrchr): Avoid false positives in loop.
26045         * modules/memrchr-tests: New file.
26046         * tests/test-memrchr.c: New file.
26047
26048 2008-04-26  Bruno Haible  <bruno@clisp.org>
26049
26050         Add tentative support for DragonFly BSD.
26051         * lib/stdio-impl.h: Add macros for DragonFly BSD.
26052         * lib/fbufmode.c (fbufmode): Update conditionals. Use fp_ instead of
26053         fp.
26054         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
26055         restore_seek_optimization, update_fpos_cache, rpl_fflush: Likewise.
26056         * lib/fpurge.c (fpurge): Likewise.
26057         * lib/freadable.c (freaadable): Likewise.
26058         * lib/freadahead.c (freadahead): Likewise.
26059         * lib/freading.c (freading): Likewise.
26060         * lib/freadptr.c (freadptr): Likewise.
26061         * lib/freadseek.c (freadptrinc): Likewise.
26062         * lib/fseeko.c (fseeko): Likewise.
26063         * lib/fseterr.c (fseterr): Likewise.
26064         * lib/fwritable.c (fwritable): Likewise.
26065         * lib/fwriting.c (fwriting): Likewise.
26066
26067 2008-04-26  Bruno Haible  <bruno@clisp.org>
26068
26069         * lib/stdio-impl.h: New file.
26070         * lib/fbufmode.c: Include stdio-impl.h.
26071         (fbufmode): Use fp_, remove redundant #defines.
26072         * lib/fflush.c: Include stdio-impl.h.
26073         (clear_ungetc_buffer): Remove redundant #defines.
26074         * lib/fpurge.c: Include stdio-impl.h.
26075         (fpurge): Remove redundant #defines.
26076         * lib/freadable.c: Include stdio-impl.h.
26077         (freadable): Remove redundant #defines.
26078         * lib/freadahead.c: Include stdio-impl.h.
26079         (freadahead): Remove redundant #defines.
26080         * lib/freading.c: Include stdio-impl.h.
26081         (freading): Remove redundant #defines.
26082         * lib/freadptr.c: Include stdio-impl.h.
26083         (freadptr): Remove redundant #defines.
26084         * lib/freadseek.c: Include stdio-impl.h.
26085         (freadptrinc): Remove redundant #defines.
26086         * lib/fseeko.c: Include stdio-impl.h.
26087         (rpl_fseeko): Remove redundant #defines.
26088         * lib/fseterr.c: Include stdio-impl.h.
26089         (fseterr): Remove redundant #defines.
26090         * lib/fwritable.c: Include stdio-impl.h.
26091         (fwritable: Remove redundant #defines.
26092         * lib/fwriting.c: Include stdio-impl.h.
26093         (fwriting): Remove redundant #defines.
26094         * modules/fbufmode (Files): Add lib/stdio-impl.h.
26095         * modules/fflush (Files): Likewise.
26096         * modules/fpurge (Files): Likewise.
26097         * modules/freadable (Files): Likewise.
26098         * modules/freadahead (Files): Likewise.
26099         * modules/freading (Files): Likewise.
26100         * modules/freadptr (Files): Likewise.
26101         * modules/freadseek (Files): Likewise.
26102         * modules/fseeko (Files): Likewise.
26103         * modules/fseterr (Files): Likewise.
26104         * modules/fwritable (Files): Likewise.
26105         * modules/fwriting (Files): Likewise.
26106
26107 2008-04-26  Bruno Haible  <bruno@clisp.org>
26108
26109         * lib/fflush.c (clear_ungetc_buffer, disable_seek_optimization,
26110         restore_seek_optimization, update_fpos_cache): New functions, extracted
26111         from rpl_fflush.
26112         (rpl_fflush): Use them.
26113         * m4/fflush.m4 (gl_PREREQ_FFLUSH): New macro.
26114         (gl_REPLACE_FFLUSH): Use it.
26115
26116 2008-04-26  Bruno Haible  <bruno@clisp.org>
26117
26118         * tests/test-xstrtol.sh: Work around limitation of an old 'tr' program
26119         on Solaris.
26120         * tests/test-xstrtoimax.sh: Likewise.
26121         * tests/test-xstrtoumax.sh: Likewise.
26122         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
26123
26124 2008-04-26  Bruno Haible  <bruno@clisp.org>
26125
26126         * modules/memchr-tests: New file.
26127         * tests/test-memchr.c; New file, based on tests/test-memchr2.c.
26128
26129 2008-04-26  Eric Blake  <ebb9@byu.net>
26130             Bruno Haible  <bruno@clisp.org>
26131
26132         * lib/memchr.c: Include intprops.h.
26133         (__memchr): Optimize parallel detection of matching bytes. Rename local
26134         variables. Add explanatory comments.
26135
26136 2008-04-26  Bruno Haible  <bruno@clisp.org>
26137
26138         Fix module 'memchr', broken since 2000-10-28.
26139         * lib/memchr.c: Outside glibc, define memchr, not __memchr.
26140
26141 2008-04-26  Bruno Haible  <bruno@clisp.org>
26142
26143         * lib/memchr2.c (memchr2): Rename local variables. Add explanatory
26144         comments.
26145
26146 2008-04-25  Eric Blake  <ebb9@byu.net>
26147
26148         Use native fstatat on cygwin 1.7.0.
26149         * m4/openat.m4 (gl_FUNC_OPENAT): Make sure lstat check is made
26150         first.
26151
26152 2008-04-23  Eric Blake  <ebb9@byu.net>
26153
26154         Improve memchr2 performance.
26155         * lib/memchr2.c (memchr2): Further optimize parallel detection of
26156         NUL bytes.
26157         * modules/memchr2 (Depends-on): Use intprops.h.
26158
26159 2008-04-23  Simon Josefsson  <simon@josefsson.org>
26160
26161         * lib/sys_socket.in.h (setsockopt): Be more type safe by declaring
26162         an inline function instead of a CPP macro.  Patch by Ben Pfaff
26163         <blp@cs.stanford.edu>.
26164
26165 2008-04-23  Simon Josefsson  <simon@josefsson.org>
26166
26167         * lib/arpa_inet.in.h: New file.
26168
26169         * modules/arpa_inet (Files): Add lib/arpa_inet.in.h.
26170         (Makefile.am): Sed in substitute header file.
26171
26172         * m4/arpa_inet_h.m4: Add gl_ARPA_INET_H_DEFAULTS and
26173         gl_ARPA_INET_MODULE_INDICATOR.  Use them.
26174
26175         * modules/inet_ntop (configure.ac): Use
26176         gl_ARPA_INET_MODULE_INDICATOR.
26177
26178         * modules/inet_pton (configure.ac): Use
26179         gl_ARPA_INET_MODULE_INDICATOR.
26180
26181 2008-04-22  Jim Meyering  <meyering@redhat.com>
26182
26183         * modules/verify (License): Re-license as LGPLv2+.
26184
26185 2008-04-22  Simon Josefsson  <simon@josefsson.org>
26186
26187         * lib/sys_socket.in.h: Define setsockopt macro to cast fourth
26188         parameter to void* as per POSIX standard (MinGW uses char*).
26189
26190 2008-04-21  Bruno Haible  <bruno@clisp.org>
26191
26192         * lib/wctype.in.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
26193         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
26194         Define to replacements if REPLACE_ISWCNTRL is 1.
26195         * m4/wctype.m4 (gl_WCTYPE_H): Test whether the isw* functions work.
26196         If not, set WCTYPE_H to nonempty and REPLACE_ISWCNTRL to 1.
26197         * modules/wctype (Makefile.am): Substitute REPLACE_ISWCNTRL.
26198         * doc/posix-functions/iswalnum.texi: Mention the 'wctype' module and
26199         what it fixes.
26200         * doc/posix-functions/iswalpha.texi: Likewise.
26201         * doc/posix-functions/iswblank.texi: Likewise.
26202         * doc/posix-functions/iswcntrl.texi: Likewise.
26203         * doc/posix-functions/iswdigit.texi: Likewise.
26204         * doc/posix-functions/iswgraph.texi: Likewise.
26205         * doc/posix-functions/iswlower.texi: Likewise.
26206         * doc/posix-functions/iswprint.texi: Likewise.
26207         * doc/posix-functions/iswpunct.texi: Likewise.
26208         * doc/posix-functions/iswspace.texi: Likewise.
26209         * doc/posix-functions/iswupper.texi: Likewise.
26210         * doc/posix-functions/iswxdigit.texi: Likewise.
26211         Reported by Alain Guibert.
26212
26213 2008-04-21  Bruno Haible  <bruno@clisp.org>
26214
26215         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Fix typo in last commit.
26216         Patch by Alain Guibert.
26217
26218 2008-04-21  Bruno Haible  <bruno@clisp.org>
26219
26220         Fix test failures on mingw.
26221         * tests/test-xstrtol.c (print_no_progname): New function.
26222         (main): Install it in error_print_progname hook.
26223         * tests/test-xstrtol.sh: Convert CR/LF to NL in output.
26224         * tests/test-xstrtoimax.sh: Likewise.
26225         * tests/test-xstrtoumax.sh: Likewise.
26226
26227 2008-04-21  Bruno Haible  <bruno@clisp.org>
26228
26229         Fix test failure on mingw.
26230         * tests/test-argp-2.sh (func_compare): Remove CRs from sed's output.
26231
26232 2008-04-21  Bruno Haible  <bruno@clisp.org>
26233
26234         * lib/localename.c (SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN):
26235         Actually assign a value.
26236
26237 2008-04-20  Bruno Haible  <bruno@clisp.org>
26238
26239         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl',
26240         take 2.
26241         * lib/canonicalize.c (canonicalize_file_name): Elide if the
26242         'canonicalize-lgpl' module is also used.
26243         * lib/canonicalize-lgpl.c: Undo last change.
26244         * modules/canonicalize-lgpl (configure.ac): Invoke gl_MODULE_INDICATOR.
26245
26246 2008-04-20  Bruno Haible  <bruno@clisp.org>
26247
26248         * lib/mkdir.c (mkdir): Undefine after the includes, not right after
26249         config.h. Provide _mkdir based fallback for mingw.
26250         * lib/sys_stat.in.h (mkdir): Define through an 'extern' declaration
26251         if REPLACE_MKDIR is 1. Otherwise, test for mingw directly.
26252         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Require
26253         gl_SYS_STAT_H_DEFAULTS. When doing the replacement, set REPLACE_MKDIR
26254         rather than defining mkdir in config.h.
26255         * m4/sys_stat_h.m4 (gl_SYS_STAT_MODULE_INDICATOR): New macro.
26256         (gl_SYS_STAT_H_DEFAULTS): New macro.
26257         (gl_HEADER_SYS_STAT_H): Require it. Don't set HAVE_DECL_MKDIR and
26258         HAVE_IO_H any more.
26259         * modules/sys_stat (Makefile.am): Substitute REPLACE_MKDIR instead of
26260         HAVE_DECL_MKDIR and HAVE_IO_H.
26261
26262 2008-04-20  Bruno Haible  <bruno@clisp.org>
26263
26264         * lib/isapipe.c: Port to native Windows platforms.
26265
26266 2008-04-20  Bruno Haible  <bruno@clisp.org>
26267
26268         * lib/gc-gnulib.c: Include <windows.h> before <wincrypt.h>.
26269
26270 2008-04-21  Eric Blake  <ebb9@byu.net>
26271
26272         Work around preprocessors that don't handle UINTMAX_MAX.
26273         * lib/memchr2.c (memchr2): Avoid embedded #if.
26274         Reported by Alain Guibert, fix suggested by Bruno Haible.
26275
26276 2008-04-21  Simon Josefsson  <simon@josefsson.org>
26277
26278         * doc/posix-functions/strftime.texi (strftime): Explain better
26279         Windows incompatibility.  Suggested by Micah Cowan
26280         <micah@cowan.name>.
26281
26282 2008-04-20  Bruno Haible  <bruno@clisp.org>
26283
26284         * modules/uniconv/u32-conv-to-enc (Depends-on): Add unistr/u32-mblen,
26285         unistr/u8-mblen.
26286
26287 2008-04-20  Bruno Haible  <bruno@clisp.org>
26288
26289         Fix test failure on platforms with non-GNU iconv.
26290         * lib/uniconv/u16-conv-to-enc.c (u16_to_u8_lenient): New function.
26291         (U_TO_U8): Use it, rather than u16_to_u8.
26292         * lib/uniconv/u-conv-to-enc.h (FUNC): Allow an incomplete sequence of
26293         units at the end of the input string.
26294         * modules/uniconv/u16-conv-to-enc (Depends-on): Update.
26295
26296 2008-04-20  Bruno Haible  <bruno@clisp.org>
26297
26298         * tests/uniconv/test-u8-conv-to-enc.c (main): Accept result == NULL
26299         when the resulting length is 0.
26300         * tests/uniconv/test-u16-conv-to-enc.c (main): Likewise.
26301
26302 2008-04-20  Bruno Haible  <bruno@clisp.org>
26303
26304         * m4/roundf.m4 (gl_FUNC_ROUNDF): Add test whether roundf actually
26305         works.
26306         * doc/posix-functions/roundf.texi: Mention roundf bug on mingw.
26307
26308 2008-04-20  Bruno Haible  <bruno@clisp.org>
26309
26310         * tests/test-tsearch.c (main): Don't use initstate if it is missing.
26311         * modules/tsearch-tests (configure.ac): Test for initstate function.
26312
26313 2008-04-20  Bruno Haible  <bruno@clisp.org>
26314
26315         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Also provided a substitute
26316         for nlink_t if missing.
26317         * tests/test-sys_stat.c: Check the existence of the nlink_t type.
26318
26319 2008-04-19  Bruno Haible  <bruno@clisp.org>
26320
26321         Work around snprintf bug on Linux libc5.
26322         * m4/printf.m4 (gl_SNPRINTF_SIZE1): New macro.
26323         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
26324         gl_SNPRINTF_SIZE1.
26325         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
26326         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Likewise. Replace snprintf if
26327         that test failed.
26328         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Likewise.
26329         * lib/vasnprintf.c (USE_SNPRINTF): Set to 0 on Linux libc5 systems.
26330         * modules/snprintf (Files): Add m4/printf.m4.
26331         * modules/vsnprintf (Files): Likewise.
26332         * doc/posix-functions/snprintf.texi: Document Linux libc5 problem.
26333         * doc/posix-functions/vsnprintf.texi: Likewise.
26334
26335 2008-04-19  Bruno Haible  <bruno@clisp.org>
26336
26337         * lib/vasnprintf.c (floorlog10l, floorlog10): Reduce maximum error
26338         from 0.0058 to less than 10^-7.
26339
26340 2008-04-19  Bruno Haible  <bruno@clisp.org>
26341
26342         Fix rounding when a precision is given.
26343         * lib/vasnprintf.c (is_borderline): New function.
26344         (VASNPRINTF): For %e and %g, consider replacing the digits 10....0 with
26345         9...9x.
26346         * tests/test-vasnprintf-posix.c (test_function): Test rounding with %f,
26347         %e, %g.
26348         * tests/test-vasprintf-posix.c (test_function): Likewise.
26349         * tests/test-snprintf-posix.h (test_function): Likewise.
26350         * tests/test-sprintf-posix.h (test_function): Likewise.
26351         * tests/test-fprintf-posix.h (test_function): Test rounding with %f.
26352         * tests/test-printf-posix.h (test_function): Likewise.
26353         * tests/test-printf-posix.output: Update.
26354         Reported by John Darrington <john@darrington.wattle.id.au> via
26355         Ben Pfaff <blp@cs.stanford.edu>.
26356
26357 2008-04-18  Simon Josefsson  <simon@josefsson.org>
26358
26359         * doc/posix-functions/strftime.texi (strftime): Clarify platform.
26360         Suggested by Bruno Haible <bruno@clisp.org>.
26361
26362 2008-04-17  Bruno Haible  <bruno@clisp.org>
26363
26364         * lib/lock.h (gl_lock_destroy, gl_rwlock_destroy,
26365         gl_recursive_lock_destroy): Provide no-op definitions for the dummy
26366         implementation.
26367         Patch by Bruce Merry <bmerry@gmail.com>.
26368
26369 2008-04-17  Simon Josefsson  <simon@josefsson.org>
26370
26371         * doc/posix-functions/strftime.texi (strftime): Mention that %e
26372         doesn't work under Windows.
26373
26374 2008-04-16  Bruno Haible  <bruno@clisp.org>
26375
26376         * lib/localename.c (LANG_MAORI, LANG_QUECHUA, LANG_SOTHO, LANG_UIGHUR):
26377         New macros.
26378         (SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_LATIN,
26379         SUBLANG_BOSNIAN_BOSNIA_HERZEGOVINA_CYRILLIC,
26380         SUBLANG_CROATIAN_CROATIA, SUBLANG_CROATIAN_BOSNIA_HERZEGOVINA_LATIN,
26381         SUBLANG_MONGOLIAN_CYRILLIC_MONGOLIA, SUBLANG_MONGOLIAN_PRC,
26382         SUBLANG_QUECHUA_BOLIVIA, SUBLANG_QUECHUA_ECUADOR, SUBLANG_QUECHUA_PERU,
26383         SUBLANG_RUSSIAN_RUSSIA, SUBLANG_RUSSIAN_MOLDAVIA, SUBLANG_SPANISH_US,
26384         SUBLANG_TIBETAN_PRC, SUBLANG_TIBETAN_BHUTAN, SUBLANG_UIGHUR_PRC): New
26385         macros.
26386         (gl_locale_name_from_win32_LANGID): Refine code for Croatian/Bosnian,
26387         Mongolian, Russian, Spanish, Tibetan. Add code for Maori, Quechua,
26388         Northern Sotho, Uighur.
26389
26390 2008-04-16  Bruno Haible  <bruno@clisp.org>
26391
26392         * lib/localename.c (SUBLANG_SINDHI_INDIA): New macro.
26393         (SUBLANG_SINDHI_PAKISTAN): Change value from 1 to 2.
26394         (gl_locale_name_from_win32_LANGID): Fix code for Sindhi.
26395         Reported by Daniel Bergström <daniel@octocode.com>.
26396
26397 2007-12-25  KJK::Hyperion  <hackbunny@reactos.com>
26398             Bruno Haible  <bruno@clisp.org>
26399
26400         * lib/localename.c (gl_locale_name_canonicalize) [WIN32_NATIVE]: New
26401         function.
26402         (gl_locale_name_from_win32_LANGID, gl_locale_name_from_win32_LCID):
26403         New functions, mostly extracted from gl_locale_name_default.
26404         (gl_locale_name_default): Use gl_locale_name_from_win32_LCID.
26405
26406 2008-04-16  Eric Blake  <ebb9@byu.net>
26407
26408         Adjust strtod detection to catch glibc 2.7 bug.
26409         * m4/strtod.m4 (gl_FUNC_STRTOD): Test "nan()" behavior.
26410         Reported by John Gatewood Ham.
26411
26412 2008-04-16  Bruno Haible  <bruno@clisp.org>
26413
26414         Add tentative support for Linux libc5.
26415         * lib/fbufmode.c (fbufmode) [__GNU_LIBRARY__==1]: Reuse glibc2 code.
26416         * lib/fpurge.c (fpurge): Likewise.
26417         * lib/freadable.c (freadable): Likewise.
26418         * lib/freadahead.c (freadahead): Likewise.
26419         * lib/freading.c (freading): Likewise.
26420         * lib/freadptr.c (freadptr): Likewise.
26421         * lib/freadseek.c (freadptrinc): Likewise.
26422         * lib/fseeko.c (rpl_fseeko): Likewise.
26423         * lib/fseterr.c (fseterr): Likewise.
26424         * lib/fwritable.c (fwritable): Likewise.
26425         * lib/fwriting.c (fwriting): Likewise.
26426         Reported by Alain Guibert <alguibert+bts@free.fr>.
26427
26428 2008-04-15  Bruno Haible  <bruno@clisp.org>
26429
26430         * modules/mathl (configure.ac): Define module indicator.
26431
26432 2008-04-15  Bruno Haible  <bruno@clisp.org>
26433
26434         * lib/logl.c (logl): Remove unused variables.
26435
26436 2008-04-15  Bruno Haible  <bruno@clisp.org>
26437
26438         * lib/uniconv/u-conv-to-enc.h (FUNC): Fix return value when U_TO_U8
26439         fails.
26440
26441 2008-04-15  Bruno Haible  <bruno@clisp.org>
26442
26443         * lib/trim.c (trim2): Fix argument of isspace() macro.
26444
26445 2008-04-15  Paolo Bonzini  <bonzini@gnu.org>
26446
26447         * lib/tanl.c (kernel_tanl): Rename flag to invert, initialize it
26448         to 0.
26449         * lib/trigl.c (ieee754_rem_pio2l): Fix range checks.
26450
26451 2008-04-14  Bruno Haible  <bruno@clisp.org>
26452
26453         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Fix underquoting of
26454         AC_LANG_PROGRAM argument.
26455         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Likewise.
26456         * m4/gethrxtime.m4 (gl_ARITHMETIC_HRTIME_T): Likewise.
26457         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Likewise.
26458         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
26459         * m4/math_h.m4 (gl_MATH_H): Likewise.
26460         * m4/mbstate_t.m4 (AC_TYPE_MBSTATE_T): Likewise.
26461         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
26462         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
26463         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Likewise.
26464         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
26465         * m4/regex.m4 (gl_REGEX): Likewise.
26466         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Likewise.
26467         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET): Likewise.
26468         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
26469         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Likewise.
26470         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
26471         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
26472         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
26473         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
26474
26475 2008-04-14  Jim Meyering  <meyering@redhat.com>
26476
26477         test-strtod: fix typos: s/abs/fabs/
26478         * tests/test-strtod.c (main): Use fabs, not narrowing-to-int "abs".
26479
26480 2008-04-13  Bruno Haible  <bruno@clisp.org>
26481
26482         Fix conflict between modules 'canonicalize' and 'canonicalize-lgpl'.
26483         * lib/canonicalize-lgpl.c: Elide the contents if the 'canonicalize'
26484         module is also used and while not building the reloc-wrapper.
26485
26486 2008-04-13  Bruno Haible  <bruno@clisp.org>
26487
26488         * tests/test-getaddrinfo.c (simple): Ignore EAI_NODATA error.
26489
26490 2008-04-13  Bruno Haible  <bruno@clisp.org>
26491
26492         Fix AIX compilation failure introduced on 2008-04-02.
26493         * tests/test-frexp.c (exp): Undefine before redefining.
26494         * tests/test-frexpl.c (exp): Likewise.
26495
26496 2008-04-13  Bruno Haible  <bruno@clisp.org>
26497
26498         Work around a HP-UX stdio bug.
26499         * tests/test-ftell.c (main): Disable the fseek/ftell test on HP-UX.
26500         * tests/test-ftello.c (main): Likewise.
26501         * doc/posix-functions/ftell.texi: Mention HP-UX bug.
26502         * doc/posix-functions/ftello.texi: Likewise.
26503
26504 2008-04-13  Bruno Haible  <bruno@clisp.org>
26505
26506         Make test-signbit pass on HP-UX/hppa.
26507         * tests/test-signbit.c (minus_zerol): New variable.
26508         (test_signbitl): Use it.
26509
26510 2008-04-13  Bruno Haible  <bruno@clisp.org>
26511
26512         Make truncl work on OSF/1 4.0.
26513         * m4/truncl.m4 (gl_FUNC_TRUNCL): Test whether truncl actually works.
26514         Set REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
26515         * lib/math.in.h (truncl): Test REPLACE_TRUNCL, not HAVE_DECL_TRUNCL.
26516         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_TRUNCL, not
26517         HAVE_DECL_TRUNCL.
26518         * modules/math (Makefile.am): Substitute REPLACE_TRUNCL, not
26519         HAVE_DECL_TRUNCL.
26520         * doc/posix-functions/truncl.texi: Document the OSF/1 4.0 problem.
26521
26522 2008-04-13  Bruno Haible  <bruno@clisp.org>
26523
26524         * lib/unictype.h: Remove trailing comma from enumeration definitions.
26525
26526 2008-04-13  Bruno Haible  <bruno@clisp.org>
26527
26528         * lib/count-one-bits.h (COUNT_ONE_BITS): Rewrite verification
26529         expression, so as to avoid HP-UX 11 cc compiler bug.
26530
26531 2008-04-13  Bruno Haible  <bruno@clisp.org>
26532
26533         * m4/regex.m4 (gl_PREREQ_REGEX): Also check for <libintl.h>.
26534
26535 2008-04-13  Bruno Haible  <bruno@clisp.org>
26536
26537         * lib/git-merge-changelog.c: Remove empty declaration outside of
26538         functions.
26539
26540 2008-04-13  Bruno Haible  <bruno@clisp.org>
26541
26542         * modules/quotearg-tests (Makefile.am): Define test_quotearg_LDADD.
26543
26544 2008-04-13  Bruno Haible  <bruno@clisp.org>
26545
26546         * doc/posix-headers/sys_socket.texi: Document the problem on EMX.
26547         * lib/sys_socket.in.h (SHUT_RD, SHUT_WR, SHUT_RDWR): Define if missing.
26548         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Replace <sys/socket.h>
26549         also if it exists but lacks definitions of the SHUT_* macros.
26550         * modules/sys_socket (Description): Update.
26551         Reported by Elbert Pol <e.pol@chello.nl>.
26552
26553 2008-04-13  Bruno Haible  <bruno@clisp.org>
26554
26555         * lib/localcharset.c (OS2): Don't redefine if already defined.
26556         Reported by Elbert Pol <e.pol@chello.nl>.
26557
26558 2008-04-13  Bruno Haible  <bruno@clisp.org>
26559
26560         * lib/binary-io.h [__EMX__]: Include <io.h>.
26561         Reported by Elbert Pol <e.pol@chello.nl>.
26562
26563 2008-04-12  Bruno Haible  <bruno@clisp.org>
26564
26565         * lib/fpucw.h: Enable the definitions also for x86_64.
26566         Needed for NetBSD/x86_64.
26567         Reported by Thomas Klausner <tk@giga.or.at>.
26568
26569 2008-04-12  Bruno Haible  <bruno@clisp.org>
26570
26571         * tests/test-strtod.c: Include isnand.h.
26572         (main): Use isnand instead of isnan.
26573         Reported by Jim Meyering.
26574
26575 2008-04-12  Bruno Haible  <bruno@clisp.org>
26576
26577         * m4/isnanf.m4 (gl_ISNANF_WORKS): Add a test for a special NaN.
26578         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
26579
26580 2008-04-12  Jim Meyering  <meyering@redhat.com>
26581
26582         * m4/math_h.m4 (gl_MATH_H): Fix typos.
26583
26584 2008-04-12  Bruno Haible  <bruno@clisp.org>
26585
26586         * lib/freadptr.c (freadptr) [__EMX__]: Fix wrong assertion.
26587         Reported by Elbert Pol <e.pol@chello.nl>.
26588
26589 2008-04-12  Eric Blake  <ebb9@byu.net>
26590
26591         Work around Solaris 10 math.h bug.
26592         * m4/math_h.m4 (gl_MATH_H): Check for bug.
26593         (gl_MATH_H_DEFAULTS): Set up default.
26594         * modules/math (Makefile.am): Replace new indicators.
26595         * lib/math.in.h (NAN, HUGE_VAL): Provide replacements.
26596         * tests/test-math.c (main): Test this.
26597         * m4/strtod.m4 (gl_FUNC_STRTOD): Don't rely on HUGE_VAL.
26598         * doc/posix-headers/math.texi (math.h): Mention bug.
26599         Reported by Nelson H. F. Beebe and Jim Meyering.
26600
26601 2008-04-11  Bruno Haible  <bruno@clisp.org>
26602
26603         Adapt to future versions of Apple GCC.
26604         * lib/argp-fmtstream.h (ARGP_FS_EI): Don't test __GNUC_GNU_INLINE__.
26605         Reported by Peter O'Gorman <peter@pogma.com>.
26606
26607 2008-04-11  Bruno Haible  <bruno@clisp.org>
26608
26609         * tests/test-getaddrinfo.c (simple): Ignore EAI_NONAME error.
26610
26611 2008-04-11  Bruno Haible  <bruno@clisp.org>
26612
26613         * modules/strsignal-tests (Makefile.am): Define test_strsignal_LDADD.
26614
26615         * modules/getaddrinfo-tests (Makefile.am): Define
26616         test_getaddrinfo_LDADD.
26617
26618 2008-04-11  Bruno Haible  <bruno@clisp.org>
26619
26620         * lib/strsignal.c (_sys_siglist): Don't declare if already declared.
26621         (init): Fix syntax error.
26622         * m4/strsignal.m4 (gl_PREREQ_STRSIGNAL): Check whether _sys_siglist
26623         is declared.
26624
26625 2008-04-11  Bruno Haible  <bruno@clisp.org>
26626
26627         * lib/glob.c: Include <stdbool.h>. Needed at least with IRIX cc.
26628         * modules/glob (Depends-on): Add stdbool.
26629
26630 2008-04-11  Bruno Haible  <bruno@clisp.org>
26631
26632         * lib/trim.c: Include <string.h>.
26633
26634 2008-04-11  Eric Blake  <ebb9@byu.net>
26635
26636         Avoid compile failure on OS/2.
26637         * lib/regex_internal.h (internal_function): Disable optimization
26638         on OS/2 (__EMX__), where it caused compiler error.
26639         Reported by Elbert Pol.
26640
26641 2008-04-11  Bruno Haible  <bruno@clisp.org>
26642
26643         Flush the standard error stream before aborting. Needed on mingw.
26644         * tests/test-argmatch.c (ASSERT): Call fflush(stderr) before abort().
26645         * tests/test-array_list.c (ASSERT): Likewise.
26646         * tests/test-array_oset.c (ASSERT): Likewise.
26647         * tests/test-avltree_list.c (ASSERT): Likewise.
26648         * tests/test-avltree_oset.c (ASSERT): Likewise.
26649         * tests/test-avltreehash_list.c (ASSERT): Likewise.
26650         * tests/test-binary-io.c (ASSERT): Likewise.
26651         * tests/test-byteswap.c (ASSERT): Likewise.
26652         * tests/test-c-ctype.c (ASSERT): Likewise.
26653         * tests/test-c-strcasecmp.c (ASSERT): Likewise.
26654         * tests/test-c-strcasestr.c (ASSERT): Likewise.
26655         * tests/test-c-strncasecmp.c (ASSERT): Likewise.
26656         * tests/test-c-strstr.c (ASSERT): Likewise.
26657         * tests/test-canonicalize-lgpl.c (ASSERT): Likewise.
26658         * tests/test-canonicalize.c (ASSERT): Likewise.
26659         * tests/test-carray_list.c (ASSERT): Likewise.
26660         * tests/test-ceilf1.c (ASSERT): Likewise.
26661         * tests/test-ceilf2.c (ASSERT): Likewise.
26662         * tests/test-ceill.c (ASSERT): Likewise.
26663         * tests/test-count-one-bits.c (ASSERT): Likewise.
26664         * tests/test-fbufmode.c (ASSERT): Likewise.
26665         * tests/test-fflush2.c (ASSERT): Likewise.
26666         * tests/test-floorf1.c (ASSERT): Likewise.
26667         * tests/test-floorf2.c (ASSERT): Likewise.
26668         * tests/test-floorl.c (ASSERT): Likewise.
26669         * tests/test-fopen.c (ASSERT): Likewise.
26670         * tests/test-fpending.c (ASSERT): Likewise.
26671         * tests/test-fprintf-posix.c (ASSERT): Likewise.
26672         * tests/test-fpurge.c (ASSERT): Likewise.
26673         * tests/test-freadable.c (ASSERT): Likewise.
26674         * tests/test-freadahead.c (ASSERT): Likewise.
26675         * tests/test-freading.c (ASSERT): Likewise.
26676         * tests/test-freadptr.c (ASSERT): Likewise.
26677         * tests/test-freadptr2.c (ASSERT): Likewise.
26678         * tests/test-freadseek.c (ASSERT): Likewise.
26679         * tests/test-freopen.c (ASSERT): Likewise.
26680         * tests/test-frexp.c (ASSERT): Likewise.
26681         * tests/test-frexpl.c (ASSERT): Likewise.
26682         * tests/test-fseek.c (ASSERT): Likewise.
26683         * tests/test-fseeko.c (ASSERT): Likewise.
26684         * tests/test-fstrcmp.c (ASSERT): Likewise.
26685         * tests/test-ftell.c (ASSERT): Likewise.
26686         * tests/test-ftello.c (ASSERT): Likewise.
26687         * tests/test-func.c (ASSERT): Likewise.
26688         * tests/test-fwritable.c (ASSERT): Likewise.
26689         * tests/test-fwriting.c (ASSERT): Likewise.
26690         * tests/test-getdelim.c (ASSERT): Likewise.
26691         * tests/test-getline.c (ASSERT): Likewise.
26692         * tests/test-i-ring.c (ASSERT): Likewise.
26693         * tests/test-iconv-utf.c (ASSERT): Likewise.
26694         * tests/test-iconv.c (ASSERT): Likewise.
26695         * tests/test-isfinite.c (ASSERT): Likewise.
26696         * tests/test-isnand.c (ASSERT): Likewise.
26697         * tests/test-isnanf.c (ASSERT): Likewise.
26698         * tests/test-isnanl.h (ASSERT): Likewise.
26699         * tests/test-ldexpl.c (ASSERT): Likewise.
26700         * tests/test-linked_list.c (ASSERT): Likewise.
26701         * tests/test-linkedhash_list.c (ASSERT): Likewise.
26702         * tests/test-localename.c (ASSERT): Likewise.
26703         * tests/test-lseek.c (ASSERT): Likewise.
26704         * tests/test-mbscasecmp.c (ASSERT): Likewise.
26705         * tests/test-mbscasestr1.c (ASSERT): Likewise.
26706         * tests/test-mbscasestr2.c (ASSERT): Likewise.
26707         * tests/test-mbscasestr3.c (ASSERT): Likewise.
26708         * tests/test-mbscasestr4.c (ASSERT): Likewise.
26709         * tests/test-mbschr.c (ASSERT): Likewise.
26710         * tests/test-mbscspn.c (ASSERT): Likewise.
26711         * tests/test-mbsncasecmp.c (ASSERT): Likewise.
26712         * tests/test-mbspbrk.c (ASSERT): Likewise.
26713         * tests/test-mbspcasecmp.c (ASSERT): Likewise.
26714         * tests/test-mbsrchr.c (ASSERT): Likewise.
26715         * tests/test-mbsspn.c (ASSERT): Likewise.
26716         * tests/test-mbsstr1.c (ASSERT): Likewise.
26717         * tests/test-mbsstr2.c (ASSERT): Likewise.
26718         * tests/test-mbsstr3.c (ASSERT): Likewise.
26719         * tests/test-memchr2.c (ASSERT): Likewise.
26720         * tests/test-memmem.c (ASSERT): Likewise.
26721         * tests/test-open.c (ASSERT): Likewise.
26722         * tests/test-printf-frexp.c (ASSERT): Likewise.
26723         * tests/test-printf-frexpl.c (ASSERT): Likewise.
26724         * tests/test-printf-posix.c (ASSERT): Likewise.
26725         * tests/test-quotearg.c (ASSERT): Likewise.
26726         * tests/test-rbtree_list.c (ASSERT): Likewise.
26727         * tests/test-rbtree_oset.c (ASSERT): Likewise.
26728         * tests/test-rbtreehash_list.c (ASSERT): Likewise.
26729         * tests/test-round1.c (ASSERT): Likewise.
26730         * tests/test-roundf1.c (ASSERT): Likewise.
26731         * tests/test-roundl.c (ASSERT): Likewise.
26732         * tests/test-signbit.c (ASSERT): Likewise.
26733         * tests/test-sleep.c (ASSERT): Likewise.
26734         * tests/test-snprintf-posix.c (ASSERT): Likewise.
26735         * tests/test-snprintf.c (ASSERT): Likewise.
26736         * tests/test-sprintf-posix.c (ASSERT): Likewise.
26737         * tests/test-stat-time.c (ASSERT): Likewise.
26738         * tests/test-strcasestr.c (ASSERT): Likewise.
26739         * tests/test-strerror.c (ASSERT): Likewise.
26740         * tests/test-striconv.c (ASSERT): Likewise.
26741         * tests/test-striconveh.c (ASSERT): Likewise.
26742         * tests/test-striconveha.c (ASSERT): Likewise.
26743         * tests/test-strsignal.c (ASSERT): Likewise.
26744         * tests/test-strstr.c (ASSERT): Likewise.
26745         * tests/test-strtod.c (ASSERT): Likewise.
26746         * tests/test-trunc1.c (ASSERT): Likewise.
26747         * tests/test-trunc2.c (ASSERT): Likewise.
26748         * tests/test-truncf1.c (ASSERT): Likewise.
26749         * tests/test-truncf2.c (ASSERT): Likewise.
26750         * tests/test-truncl.c (ASSERT): Likewise.
26751         * tests/test-vasnprintf-posix.c (ASSERT): Likewise.
26752         * tests/test-vasnprintf-posix2.c (ASSERT): Likewise.
26753         * tests/test-vasnprintf.c (ASSERT): Likewise.
26754         * tests/test-vasprintf-posix.c (ASSERT): Likewise.
26755         * tests/test-vasprintf.c (ASSERT): Likewise.
26756         * tests/test-vfprintf-posix.c (ASSERT): Likewise.
26757         * tests/test-vprintf-posix.c (ASSERT): Likewise.
26758         * tests/test-vsnprintf-posix.c (ASSERT): Likewise.
26759         * tests/test-vsnprintf.c (ASSERT): Likewise.
26760         * tests/test-vsprintf-posix.c (ASSERT): Likewise.
26761         * tests/test-wcwidth.c (ASSERT): Likewise.
26762         * tests/test-xfprintf-posix.c (ASSERT): Likewise.
26763         * tests/test-xprintf-posix.c (ASSERT): Likewise.
26764         * tests/test-xvasprintf.c (ASSERT): Likewise.
26765         * tests/uniconv/test-u16-conv-from-enc.c (ASSERT): Likewise.
26766         * tests/uniconv/test-u16-conv-to-enc.c (ASSERT): Likewise.
26767         * tests/uniconv/test-u16-strconv-from-enc.c (ASSERT): Likewise.
26768         * tests/uniconv/test-u16-strconv-to-enc.c (ASSERT): Likewise.
26769         * tests/uniconv/test-u32-conv-from-enc.c (ASSERT): Likewise.
26770         * tests/uniconv/test-u32-conv-to-enc.c (ASSERT): Likewise.
26771         * tests/uniconv/test-u32-strconv-from-enc.c (ASSERT): Likewise.
26772         * tests/uniconv/test-u32-strconv-to-enc.c (ASSERT): Likewise.
26773         * tests/uniconv/test-u8-conv-from-enc.c (ASSERT): Likewise.
26774         * tests/uniconv/test-u8-conv-to-enc.c (ASSERT): Likewise.
26775         * tests/uniconv/test-u8-strconv-from-enc.c (ASSERT): Likewise.
26776         * tests/uniconv/test-u8-strconv-to-enc.c (ASSERT): Likewise.
26777         * tests/unictype/test-bidi_byname.c (ASSERT): Likewise.
26778         * tests/unictype/test-bidi_name.c (ASSERT): Likewise.
26779         * tests/unictype/test-bidi_of.c (ASSERT): Likewise.
26780         * tests/unictype/test-bidi_test.c (ASSERT): Likewise.
26781         * tests/unictype/test-block_list.c (ASSERT): Likewise.
26782         * tests/unictype/test-block_of.c (ASSERT): Likewise.
26783         * tests/unictype/test-block_test.c (ASSERT): Likewise.
26784         * tests/unictype/test-categ_and.c (ASSERT): Likewise.
26785         * tests/unictype/test-categ_and_not.c (ASSERT): Likewise.
26786         * tests/unictype/test-categ_byname.c (ASSERT): Likewise.
26787         * tests/unictype/test-categ_name.c (ASSERT): Likewise.
26788         * tests/unictype/test-categ_none.c (ASSERT): Likewise.
26789         * tests/unictype/test-categ_of.c (ASSERT): Likewise.
26790         * tests/unictype/test-categ_or.c (ASSERT): Likewise.
26791         * tests/unictype/test-categ_test_withtable.c (ASSERT): Likewise.
26792         * tests/unictype/test-combining.c (ASSERT): Likewise.
26793         * tests/unictype/test-decdigit.c (ASSERT): Likewise.
26794         * tests/unictype/test-digit.c (ASSERT): Likewise.
26795         * tests/unictype/test-mirror.c (ASSERT): Likewise.
26796         * tests/unictype/test-numeric.c (ASSERT): Likewise.
26797         * tests/unictype/test-pr_byname.c (ASSERT): Likewise.
26798         * tests/unictype/test-pr_test.c (ASSERT): Likewise.
26799         * tests/unictype/test-predicate-part1.h (ASSERT): Likewise.
26800         * tests/unictype/test-scripts.c (ASSERT): Likewise.
26801         * tests/unictype/test-sy_c_ident.c (ASSERT): Likewise.
26802         * tests/unictype/test-sy_java_ident.c (ASSERT): Likewise.
26803         * tests/unistdio/test-u16-asnprintf1.c (ASSERT): Likewise.
26804         * tests/unistdio/test-u16-vasnprintf1.c (ASSERT): Likewise.
26805         * tests/unistdio/test-u16-vasnprintf2.c (ASSERT): Likewise.
26806         * tests/unistdio/test-u16-vasnprintf3.c (ASSERT): Likewise.
26807         * tests/unistdio/test-u16-vasprintf1.c (ASSERT): Likewise.
26808         * tests/unistdio/test-u16-vsnprintf1.c (ASSERT): Likewise.
26809         * tests/unistdio/test-u16-vsprintf1.c (ASSERT): Likewise.
26810         * tests/unistdio/test-u32-asnprintf1.c (ASSERT): Likewise.
26811         * tests/unistdio/test-u32-vasnprintf1.c (ASSERT): Likewise.
26812         * tests/unistdio/test-u32-vasnprintf2.c (ASSERT): Likewise.
26813         * tests/unistdio/test-u32-vasnprintf3.c (ASSERT): Likewise.
26814         * tests/unistdio/test-u32-vasprintf1.c (ASSERT): Likewise.
26815         * tests/unistdio/test-u32-vsnprintf1.c (ASSERT): Likewise.
26816         * tests/unistdio/test-u32-vsprintf1.c (ASSERT): Likewise.
26817         * tests/unistdio/test-u8-asnprintf1.c (ASSERT): Likewise.
26818         * tests/unistdio/test-u8-vasnprintf1.c (ASSERT): Likewise.
26819         * tests/unistdio/test-u8-vasnprintf2.c (ASSERT): Likewise.
26820         * tests/unistdio/test-u8-vasnprintf3.c (ASSERT): Likewise.
26821         * tests/unistdio/test-u8-vasprintf1.c (ASSERT): Likewise.
26822         * tests/unistdio/test-u8-vsnprintf1.c (ASSERT): Likewise.
26823         * tests/unistdio/test-u8-vsprintf1.c (ASSERT): Likewise.
26824         * tests/unistdio/test-ulc-asnprintf1.c (ASSERT): Likewise.
26825         * tests/unistdio/test-ulc-vasnprintf1.c (ASSERT): Likewise.
26826         * tests/unistdio/test-ulc-vasnprintf2.c (ASSERT): Likewise.
26827         * tests/unistdio/test-ulc-vasnprintf3.c (ASSERT): Likewise.
26828         * tests/unistdio/test-ulc-vasprintf1.c (ASSERT): Likewise.
26829         * tests/unistdio/test-ulc-vsnprintf1.c (ASSERT): Likewise.
26830         * tests/unistdio/test-ulc-vsprintf1.c (ASSERT): Likewise.
26831         * tests/uniwidth/test-u16-strwidth.c (ASSERT): Likewise.
26832         * tests/uniwidth/test-u16-width.c (ASSERT): Likewise.
26833         * tests/uniwidth/test-u32-strwidth.c (ASSERT): Likewise.
26834         * tests/uniwidth/test-u32-width.c (ASSERT): Likewise.
26835         * tests/uniwidth/test-u8-strwidth.c (ASSERT): Likewise.
26836         * tests/uniwidth/test-u8-width.c (ASSERT): Likewise.
26837         * tests/uniwidth/test-uc_width.c (ASSERT): Likewise.
26838         Reported by Eric Blake.
26839
26840 2008-04-11  Bruno Haible  <bruno@clisp.org>
26841
26842         * lib/wchar.in.h: Tweak comment.
26843
26844 2008-04-11  Bruno Haible  <bruno@clisp.org>
26845
26846         Fix __GNUC_STDC_INLINE__ predefine with Apple GCC on MacOS X 10.5.
26847         * gnulib-tool (func_emit_initmacro_start): Emit an invocation of
26848         gl_COMMON.
26849         * m4/gnulib-common.m4 (gl_COMMON, gl_COMMON_BODY): New macros.
26850
26851 2008-04-11  Bruno Haible  <bruno@clisp.org>
26852
26853         * modules/git-merge-changelog (git_merge_changelog_LDADD): Add LIBINTL.
26854
26855 2008-04-11  Simon Josefsson  <simon@josefsson.org>
26856
26857         * lib/gc-gnulib.c: On Windows, use CryptGenRandom from CSP instead
26858         of attempting to use non-existing /dev/*random.  Based on patch
26859         from Adam Strzelecki <ono@java.pl> in
26860         <http://lists.gnu.org/archive/html/help-gsasl/2008-02/msg00000.html>.
26861
26862 2008-04-08  Bruno Haible  <bruno@clisp.org>
26863
26864         Add tentative support for emx+gcc.
26865         * lib/fbufmode.c (fbufmode) [__EMX__]: Add conditional code.
26866         * lib/fpurge.c (fpurge): Likewise.
26867         * lib/freadable.c (freadable): Likewise.
26868         * lib/freadahead.c (freadahead): Likewise.
26869         * lib/freading.c (freading): Likewise.
26870         * lib/freadptr.c (freadptr): Likewise.
26871         * lib/freadseek.c (freadptrinc): Likewise.
26872         * lib/fseeko.c (rpl_fseeko): Likewise.
26873         * lib/fseterr.c (fseterr): Likewise.
26874         * lib/fwritable.c (fwritable): Likewise.
26875         * lib/fwriting.c (fwriting): Likewise.
26876         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for emx+gcc.
26877
26878 2008-04-09  Eric Blake  <ebb9@byu.net>
26879
26880         Avoid some autoconf warnings.
26881         * m4/regex.m4 (gl_REGEX): s/AC_HELP_STRING/AS_HELP_STRING/.
26882         * m4/acl.m4 (gl_FUNC_ACL): Likewise.
26883         * m4/afs.m4 (gl_AFS): Likewise.
26884         * m4/gc-random.m4 (gl_GC_RANDOM): Likewise.
26885         * m4/include_next.m4 (gl_INCLUDE_NEXT): s/AC_FOREACH/m4_foreach_w/.
26886         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
26887         * m4/stdint.m4 (gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED)
26888         (gl_INTEGER_TYPE_SUFFIX): Likewise.
26889         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE)
26890         (AC_CHECK_DECLS_ONCE): Likewise.
26891         Rename file...
26892         * m4/onceonly.m4: ...to this, and delete 2.54 variant, now that
26893         gnulib-tool requires autoconf 2.59 or better.
26894         * gnulib-tool (func_get_filelist): s/\(onceonly\)_2_57.m4/\1.m4/.
26895
26896 2008-04-08  Eric Blake  <ebb9@byu.net>
26897
26898         Use 'git describe --match' if present (added in git 1.5.5).
26899         * build-aux/git-version-gen: Limit result to tags that match 'v*'
26900         if possible.
26901
26902 2008-04-08  Bruno Haible  <bruno@clisp.org>
26903
26904         Add tentative support for OpenServer.
26905         * lib/fbufmode.c (fbufmode): Add conditional define for _flag, _base,
26906         _ptr, _cnt.
26907         * lib/fpurge.c (fpurge): Likewise.
26908         * lib/freadable.c (freadable): Likewise.
26909         * lib/freadahead.c (freadahead): Likewise.
26910         * lib/freading.c (freading): Likewise.
26911         * lib/freadptr.c (freadptr): Likewise.
26912         * lib/freadseek.c (freadptrinc): Likewise.
26913         * lib/fseeko.c (rpl_fseeko): Likewise.
26914         * lib/fseterr.c (fseterr): Likewise.
26915         * lib/fwritable.c (fwritable): Likewise.
26916         * lib/fwriting.c (fwriting): Likewise.
26917         Reported by Roger Cornelius <rac@tenzing.org> and
26918         Brian K. White <brian@aljex.com>.
26919
26920 2008-04-06  Jim Meyering  <meyering@redhat.com>
26921
26922         * gnulib-tool (func_add_or_update): s/backuped/backed up/ in diagnostic
26923
26924 2008-04-06  Bruno Haible  <bruno@clisp.org>
26925
26926         Avoid possible error with non-ASCII bytes in UTF-8 locales.
26927         * tests/test-fprintf-posix.sh: Use "LC_ALL=C tr" instead of "tr".
26928         * tests/test-printf-posix.sh: Likewise.
26929         * tests/test-vfprintf-posix.sh: Likewise.
26930         * tests/test-vprintf-posix.sh: Likewise.
26931         * tests/test-xprintf-posix.sh: Likewise.
26932
26933 2008-04-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
26934
26935         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT): Fix quoting,
26936         hide error from 'ls', needed on OS/2.
26937         Report by Elbert Pol <elbert.pol@gmail.com>.
26938
26939 2008-04-04  Eric Blake  <ebb9@byu.net>
26940
26941         Make test-fseeko.c failures meaningful.
26942         * tests/test-fseeko.c: Print line number on failure.
26943         * tests/test-fseek.c: Likewise.
26944         Reported by Nelson H. F. Beebe.
26945
26946         Improve strtod bug detection check.
26947         * m4/strtod.m4 (gl_FUNC_STRTOD): Also check for hex-float parsing,
26948         required for Solaris 10.
26949         Reported by Bob Friesenhahn and Nelson H. F. Beebe.
26950
26951 2008-04-04  Bruno Haible  <bruno@clisp.org>
26952
26953         * modules/relocatable-prog-wrapper (Files): Add m4/environ.m4. Needed
26954         by m4/setenv.m4.
26955
26956 2008-04-03  Eric Blake  <ebb9@byu.net>
26957
26958         Ensure sane .version contents.
26959         * top/GNUmakefile (_dummy): Also delete .version when rebuilding
26960         version string.
26961         * build-aux/git-version-gen: Improve documentation.
26962
26963         Make GNU make output nicer.
26964         * top/GNUmakefile [!_have-Makefile]: Add dependency on
26965         MAKECMDGOALS to enforce message for all command line targets.  Set
26966         srcdir for use in maint.mk.
26967
26968         Another maintainer tweak.
26969         * top/GNUmakefile (_is-dist-target): Allow maintainer-distcheck as
26970         a target that regenerates version.
26971
26972 2008-04-03  Jim Meyering  <meyering@redhat.com>
26973
26974         vc-list-files: don't cause coreutils "make po-check" failure
26975         * build-aux/vc-list-files: Skip postprocessing when $2 is '.'
26976
26977 2008-04-03  Eric Blake  <ebb9@byu.net>
26978
26979         Allow VPATH usage of vc-list-files.
26980         * build-aux/vc-list-files (scriptversion): Add timestamp.
26981         (options): Add --help, --version, -C.
26982         (CVS): Support installed cvsu.
26983
26984 2008-04-02  Bruno Haible  <bruno@clisp.org>
26985
26986         Avoid some "statement with no effect" warnings from gcc.
26987         * tests/test-wctype.c (main): Explicitly ignore unused values.
26988         Reported by Jim Meyering.
26989
26990 2008-04-02  Jim Meyering  <meyering@redhat.com>
26991
26992         Avoid some warnings from "gcc -Wshadow".
26993         * tests/test-frexp.c (exp): Define to a different identifier.
26994         * tests/test-frexpl.c (exp): Likewise.
26995
26996 2008-04-03  Jim Meyering  <meyering@redhat.com>
26997
26998         bootstrap: remove dangling *.[ch] symlinks from lib
26999         * build-aux/bootstrap [dangling symlink removal]: Move find's
27000         -depth option to precede all others, to avoid a warning.
27001         Remove *.[ch] files too, and from "$source_base" (usually lib/).
27002
27003 2008-04-02  Bruno Haible  <bruno@clisp.org>
27004
27005         Avoid some warnings from "gcc -Wshadow".
27006         * tests/tests-vfprintf-posix.c (my_fprintf): Move after test_function.
27007         * tests/tests-vprintf-posix.c (my_printf): Move after test_function.
27008         * tests/tests-vsnprintf-posix.c (my_snprintf): Move after test_function.
27009         * tests/tests-vsprintf-posix.c (my_sprintf): Move after test_function.
27010         Reported by Jim Meyering.
27011
27012 2008-04-01  Bruno Haible  <bruno@clisp.org>
27013
27014         Fix test to work on IRIX 6.5 with cc.
27015         * tests/test-math.c (numeric_equal): New function.
27016         (main): Use it.
27017
27018 2008-04-01  Bruno Haible  <bruno@clisp.org>
27019
27020         * doc/posix-headers/math.texi: Refine documentation of NAN problem.
27021
27022 2008-04-01  Bruno Haible  <bruno@clisp.org>
27023
27024         * tests/test-vasnprintf-posix.c: Include nan.h instead of <math.h>.
27025         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
27026         * modules/vasnprintf-posix-tests (Files): Add tests/nan.h.
27027         (Depends-on): Remove math.
27028
27029         * tests/test-vasprintf-posix.c: Include nan.h instead of <math.h>.
27030         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
27031         * modules/vasprintf-posix-tests (Files): Add tests/nan.h.
27032         (Depends-on): Remove math.
27033
27034         * tests/test-snprintf-posix.h: Include nan.h instead of <math.h>.
27035         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
27036         * modules/snprintf-posix-tests (Files): Add tests/nan.h.
27037         (Depends-on): Remove math.
27038         * modules/vsnprintf-posix-tests (Files): Add tests/nan.h.
27039         (Depends-on): Remove math.
27040
27041         * tests/test-sprintf-posix.h: Include nan.h instead of <math.h>.
27042         (test_function): Use NaNd, NaNl instead of NAN or 0.0L/0.0L.
27043         * modules/sprintf-posix-tests (Files): Add tests/nan.h.
27044         (Depends-on): Remove math.
27045         * modules/vsprintf-posix-tests (Files): Add tests/nan.h.
27046         (Depends-on): Remove math.
27047
27048         * tests/test-round1.c: Include nan.h.
27049         (main): Use NaNd instead of NAN.
27050         * modules/round-tests (Files): Add tests/nan.h.
27051
27052         * tests/test-trunc1.c: Include nan.h.
27053         (main): Use NaNd instead of NAN.
27054         * modules/trunc-tests (Files): Add tests/nan.h.
27055
27056         * tests/test-roundf1.c: Include nan.h.
27057         (main): Use NaNf instead of NAN.
27058         * modules/roundf-tests (Files): Add tests/nan.h.
27059
27060         * tests/test-truncf1.c: Include nan.h.
27061         (main): Use NaNf instead of NAN.
27062         * modules/truncf-tests (Files): Add tests/nan.h.
27063
27064         * tests/test-ceilf1.c: Include nan.h.
27065         (main): Use NaNf instead of NAN.
27066         * modules/ceilf-tests (Files): Add tests/nan.h.
27067
27068         * tests/test-floorf1.c: Include nan.h.
27069         (main): Use NaNf instead of NAN.
27070         * modules/floorf-tests (Files): Add tests/nan.h.
27071
27072         * tests/test-isnanf.c: Include nan.h instead of <math.h>.
27073         (main): Use NaNf instead of NAN.
27074         * modules/isnanf-nolibm-tests (Files): Add tests/nan.h.
27075
27076         * tests/test-isnand.c: Include nan.h instead of <math.h>.
27077         (main): Use NaNd instead of NAN.
27078         * modules/isnand-nolibm-tests (Files): Add tests/nan.h.
27079
27080         * tests/test-frexp.c: Include nan.h.
27081         (main): Use NaNd instead of NAN.
27082         * modules/frexp-tests (Files): Add tests/nan.h.
27083
27084         * lib/isnan.c: Don't include <math.h>.
27085         (FUNC): Don't use NAN macro.
27086         * modules/isnand-nolibm (Depends-on): Remove math.
27087         * modules/isnanf-nolibm (Depends-on): Remove math.
27088         * modules/isnanl (Depends-on): Remove math.
27089         * modules/isnanl-nolibm (Depends-on): Remove math.
27090
27091         * tests/nan.h: New file.
27092
27093 2008-04-01  Eric Blake  <ebb9@byu.net>
27094
27095         Fix typos.
27096         * tests/test-strtod.c (main): s/FLT_/DBL_/ for minimum and epsilon
27097         values to be the right type.
27098
27099         For now, cater to gnulib strtod inaccuracies.
27100         * tests/test-strtod.c (main): Allow 1-ulp error on expected
27101         fractional results.  While not as nice from a QoI perspective, it
27102         is a quicker patch than correctly implementing decimal to binary
27103         rounding.
27104
27105 2008-03-31  Eric Blake  <ebb9@byu.net>
27106
27107         Guarantee a definition of NAN.
27108         * lib/math.in.h (NAN): Define if missing.
27109         * tests/test-math.c (main): Test it.
27110         * doc/posix-headers/math.texi (math.h): Document this.
27111         * lib/isnan.c (rpl_isnand): Use it.
27112         * tests/test-ceilf1.c (NaN): Delete, and use NAN instead.
27113         * tests/test-floorf1.c (NaN): Likewise.
27114         * tests/test-frexp.c (NaN): Likewise.
27115         * tests/test-isnand.c (NaN): Likewise.
27116         * tests/test-isnanf.c (NaN): Likewise.
27117         * tests/test-round1.c (NaN): Likewise.
27118         * tests/test-roundf1.c (NaN): Likewise.
27119         * tests/test-snprintf-posix.h (NaN): Likewise.
27120         * tests/test-sprintf-posix.h (NaN): Likewise.
27121         * tests/test-trunc1.c (NaN): Likewise.
27122         * tests/test-truncf1.c (NaN): Likewise.
27123         * tests/test-vasnprintf-posix.c (NaN): Likewise.
27124         * tests/test-vasprintf-posix.c (NaN): Likewise.
27125         * modules/isnand-nolibm (Depends-on): Add math.
27126         * modules/isnanf-nolibm (Depends-on): Likewise.
27127         * modules/isnanl (Depends-on): Likewise.
27128         * modules/isnanl-nolibm (Depends-on): Likewise.
27129         * modules/snprintf-posix-tests (Depends-on): Likewise.
27130         * modules/sprintf-posix-tests (Depends-on): Likewise.
27131         * modules/vsnprintf-posix-tests (Depends-on): Likewise.
27132         * modules/vsprintf-posix-tests (Depends-on): Likewise.
27133         * modules/vasnprintf-posix-tests (Depends-on): Likewise.
27134         * modules/vasprintf-posix-tests (Depends-on): Likewise.
27135
27136 2008-03-31  Bruno Haible  <bruno@clisp.org>
27137
27138         * tests/test-strtod.c (main): Update results for OSF/1 platforms.
27139         * doc/posix-functions/strtod.texi: Likewise.
27140
27141 2008-03-31  Bruno Haible  <bruno@clisp.org>
27142
27143         * tests/test-strtod.c (main): Don't use C99 syntax.
27144
27145 2008-03-31  Bruno Haible  <bruno@clisp.org>
27146
27147         * tests/test-strtod.c (main): Don't test NAN macro. Needed for Solaris.
27148         Reported by Eric Blake.
27149
27150 2008-03-31  Jim Meyering  <meyering@redhat.com>
27151
27152         Don't compare actual signbit return values.
27153         * tests/test-strtod.c (main): Rather, compare only their
27154         zero/non-zero nature.
27155
27156 2008-03-31  Eric Blake  <ebb9@byu.net>
27157
27158         More strtod documentation.
27159         * doc/posix-functions/strtod.texi (strtod): Interpret more test
27160         failures as distinct bugs.
27161
27162 2008-03-30  Paul Eggert  <eggert@cs.ucla.edu>
27163
27164         * lib/wchar.in.h [defined __need_mbstate_t]: Just include <wchar.h>.
27165         Problem reported by Erik Benada in
27166         <http://lists.gnu.org/archive/html/bug-gnulib/2008-03/msg00249.html>.
27167
27168 2008-03-30  Bruno Haible  <bruno@clisp.org>
27169
27170         * tests/test-strtod.c: Add comments about which assertion fails on which
27171         platform.
27172         * doc/posix-functions/strtod.texi: Add info about many more platforms.
27173
27174 2008-03-30  Eric Blake  <ebb9@byu.net>
27175
27176         Test signbit behavior on zeros.
27177         * tests/test-signbit.c (test_signbitf): Add tests for zero.
27178         (test_signbitd, test_signbitl): Likewise.
27179
27180         More strtod touchups.
27181         * tests/test-strtod.c (main): Ignore tests for signbit on NaN, and
27182         sign of negative underflow, for now.  Use .5, not .1.
27183         * doc/posix-functions/strtod.texi (strtod): Mention these
27184         limitations.
27185         Reported by Jim Meyering.
27186
27187 2008-03-30  Bruno Haible  <bruno@clisp.org>
27188
27189         * lib/striconveh.h (mem_iconveh, str_iconveh): Optimize the conversion
27190         from UTF-8 to UTF-8//TRANSLIT in the same way as from UTF-8 to UTF-8.
27191
27192 2008-03-30  Bruno Haible  <bruno@clisp.org>
27193
27194         Avoid failure when attempting to return empty iconv results on some
27195         platforms.
27196         * lib/striconveh.c (mem_cd_iconveh_internal): In the final memory
27197         allocation, don't report ENOMEM when the resulting string is empty.
27198
27199 2008-03-30  Bruno Haible  <bruno@clisp.org>
27200
27201         Fix buffer overrun.
27202         * lib/vasnprintf.c (VASNPRINTF): If !USE_SNPRINTF && pad_ourselves:
27203         Don't consider the width for tmp_length. Check count against tmp_length
27204         before doing the padding. Ensure enough allocation during padding.
27205
27206 2008-03-30  Eric Blake  <ebb9@byu.net>
27207
27208         strtod touchups.
27209         * lib/strtod.c (strtod): Avoid compiler warnings.
27210         Reported by Jim Meyering.
27211
27212 2008-03-30  Bruno Haible  <bruno@clisp.org>
27213
27214         * lib/unistdio/u-vsprintf.h (EOVERFLOW): Remove fallback.
27215         * modules/unistdio/ulc-vsprintf (Depends-on): Add EOVERFLOW.
27216         * modules/unistdio/u8-vsprintf (Depends-on): Add EOVERFLOW.
27217         * modules/unistdio/u8-u8-vsprintf (Depends-on): Add EOVERFLOW.
27218         * modules/unistdio/u16-vsprintf (Depends-on): Add EOVERFLOW.
27219         * modules/unistdio/u16-u16-vsprintf (Depends-on): Add EOVERFLOW.
27220         * modules/unistdio/u32-vsprintf (Depends-on): Add EOVERFLOW.
27221         * modules/unistdio/u32-u32-vsprintf (Depends-on): Add EOVERFLOW.
27222
27223         * lib/unistdio/u-vsnprintf.h (EOVERFLOW): Remove fallback.
27224         * modules/unistdio/ulc-vsnprintf (Depends-on): Add EOVERFLOW.
27225         * modules/unistdio/u8-vsnprintf (Depends-on): Add EOVERFLOW.
27226         * modules/unistdio/u8-u8-vsnprintf (Depends-on): Add EOVERFLOW.
27227         * modules/unistdio/u16-vsnprintf (Depends-on): Add EOVERFLOW.
27228         * modules/unistdio/u16-u16-vsnprintf (Depends-on): Add EOVERFLOW.
27229         * modules/unistdio/u32-vsnprintf (Depends-on): Add EOVERFLOW.
27230         * modules/unistdio/u32-u32-vsnprintf (Depends-on): Add EOVERFLOW.
27231
27232         * lib/unistdio/u-vasprintf.h (EOVERFLOW): Remove fallback.
27233         * modules/unistdio/ulc-vasprintf (Depends-on): Add EOVERFLOW.
27234         * modules/unistdio/u8-vasprintf (Depends-on): Add EOVERFLOW.
27235         * modules/unistdio/u8-u8-vasprintf (Depends-on): Add EOVERFLOW.
27236         * modules/unistdio/u16-vasprintf (Depends-on): Add EOVERFLOW.
27237         * modules/unistdio/u16-u16-vasprintf (Depends-on): Add EOVERFLOW.
27238         * modules/unistdio/u32-vasprintf (Depends-on): Add EOVERFLOW.
27239         * modules/unistdio/u32-u32-vasprintf (Depends-on): Add EOVERFLOW.
27240
27241         * lib/unistdio/ulc-vfprintf.c (EOVERFLOW): Remove fallback.
27242         * modules/unistdio/ulc-vfprintf (Depends-on): Add EOVERFLOW.
27243
27244         * lib/unistdio/ulc-fprintf.c (EOVERFLOW): Remove fallback.
27245         * modules/unistdio/ulc-fprintf (Depends-on): Add EOVERFLOW.
27246
27247         * lib/xvasprintf.c (EOVERFLOW): Remove fallback.
27248         * modules/xvasprintf (Depends-on): Add EOVERFLOW.
27249
27250         * lib/vsprintf.c (EOVERFLOW): Remove fallback.
27251         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Drop gl_EOVERFLOW.
27252         * modules/vsprintf-posix (Depends-on): Add EOVERFLOW.
27253
27254         * lib/vsnprintf.c (EOVERFLOW): Remove fallback.
27255         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Drop gl_EOVERFLOW.
27256         * modules/vsnprintf (Depends-on): Add EOVERFLOW.
27257
27258         * lib/vfprintf.c (EOVERFLOW): Remove fallback.
27259         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Drop gl_EOVERFLOW.
27260         * modules/vfprintf-posix (Depends-on): Add EOVERFLOW.
27261
27262         * lib/vasprintf.c (EOVERFLOW): Remove fallback.
27263         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Drop gl_EOVERFLOW.
27264         * modules/vasprintf (Depends-on): Add EOVERFLOW.
27265
27266         * lib/vasnprintf.c (EOVERFLOW): Remove fallback.
27267         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Drop gl_EOVERFLOW.
27268         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Drop gl_EOVERFLOW.
27269         * modules/vasnprintf (Files): Remove m4/eoverflow.m4.
27270         (Depends-on): Add EOVERFLOW.
27271         * modules/unistdio/ulc-vasnprintf (Files): Remove m4/eoverflow.m4.
27272         (Depends-on): Add EOVERFLOW.
27273         * modules/unistdio/u8-vasnprintf (Files): Remove m4/eoverflow.m4.
27274         (Depends-on): Add EOVERFLOW.
27275         * modules/unistdio/u8-u8-vasnprintf (Files): Remove m4/eoverflow.m4.
27276         (Depends-on): Add EOVERFLOW.
27277         * modules/unistdio/u16-vasnprintf (Files): Remove m4/eoverflow.m4.
27278         (Depends-on): Add EOVERFLOW.
27279         * modules/unistdio/u16-u16-vasnprintf (Files): Remove m4/eoverflow.m4.
27280         (Depends-on): Add EOVERFLOW.
27281         * modules/unistdio/u32-vasnprintf (Files): Remove m4/eoverflow.m4.
27282         (Depends-on): Add EOVERFLOW.
27283         * modules/unistdio/u32-u32-vasnprintf (Files): Remove m4/eoverflow.m4.
27284         (Depends-on): Add EOVERFLOW.
27285
27286         * lib/sprintf.c (EOVERFLOW): Remove fallback.
27287         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Drop gl_EOVERFLOW.
27288         * modules/sprintf-posix (Depends-on): Add EOVERFLOW.
27289
27290         * lib/snprintf.c (EOVERFLOW): Remove fallback.
27291         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Drop gl_EOVERFLOW.
27292         * modules/snprintf (Depends-on): Add EOVERFLOW.
27293
27294         * lib/poll.c (EOVERFLOW): Remove fallback.
27295         * modules/poll (Depends-on): Add EOVERFLOW.
27296
27297         * lib/getugroups.c (EOVERFLOW): Remove fallback.
27298         * modules/getugroups (Depends-on): Add EOVERFLOW.
27299
27300         * lib/getdelim.c (EOVERFLOW): Remove fallback.
27301         * modules/getdelim (Depends-on): Add EOVERFLOW.
27302
27303         * lib/ftell.c (EOVERFLOW): Remove fallback.
27304         * modules/ftell (Depends-on): Add EOVERFLOW.
27305
27306         * lib/fprintf.c (EOVERFLOW): Remove fallback.
27307         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Drop gl_EOVERFLOW.
27308         * modules/fprintf-posix (Depends-on): Add EOVERFLOW.
27309
27310         * lib/c-stack.c (EOVERFLOW): Remove unused fallback.
27311
27312         * modules/EOVERFLOW-tests: New file.
27313         * tests/test-EOVERFLOW.c: New file.
27314
27315         * modules/EOVERFLOW: New file.
27316         * doc/posix-headers/errno.texi: Mention EOVERFLOW portability problem.
27317
27318 2008-03-30  Bruno Haible  <bruno@clisp.org>
27319
27320         Fix bug introduced on 2007-06-10.
27321         * lib/vasnprintf.c (VASNPRINTF): When performing zero-padding, use
27322         spaces instead of 0 digits for 's' also when ENABLE_UNISTDIO.
27323
27324 2008-03-30  Bruno Haible  <bruno@clisp.org>
27325
27326         Improve freadseek's efficiency after ungetc.
27327         * lib/freadseek.c: Include freadahead.h.
27328         (freadptrinc): New function, extracted from freadseek.
27329         (freadseek): Use it in a loop. Use freadahead to determine the number
27330         of loop iterations.
27331         * modules/freadseek (Depends-on): Add freadahead.
27332         (configure.ac): Require AC_C_INLINE.
27333
27334 2008-03-30  Bruno Haible  <bruno@clisp.org>
27335
27336         * lib/freadseek.c (freadseek): Don't ignore the return value of
27337         freadptr.
27338
27339 2008-03-29  Eric Blake  <ebb9@byu.net>
27340
27341         Add hex float support.
27342         * modules/strtod (Depends-on): Add c-ctype.
27343         (Link): Mention POW_LIB.
27344         * lib/strtod.c (strtod): Recognize hex floats.  Don't allow
27345         whitespace between 'e' and exponent.
27346         * tests/test-strtod.c (main): Enable hex float tests.
27347         * doc/posix-functions/strtod.texi (strtod): Document what gnulib
27348         now provides.
27349
27350         Document various strtod bugs, with some fixes.
27351         * doc/posix-functions/strtod.texi (strtod): Document bugs with
27352         "-0x", "inf", "nan", and hex constants.
27353         * doc/posix-functions/atof.texi (atof): Likewise.
27354         * modules/stdlib (Makefile.am): Support strtod.
27355         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
27356         * m4/strtod.m4 (gl_FUNC_STRTOD): Fit in stdlib framework, and
27357         detect additional strtod bugs.
27358         * lib/stdlib.in.h (rpl_strtod): Add declarations.
27359         * lib/strtod.c (strtod): Return -0.0 on negative underflow.  Use
27360         bool where appropriate.  Parse 'inf' and 'nan'.
27361         * tests/test-strtod.c: New file.
27362         * modules/strtod (Depends-on): Add stdbool, stdlib.
27363         (configure.ac): Turn on module indicator.
27364         * modules/strtod-tests: New module.
27365
27366 2008-03-29  Eric Blake  <ebb9@byu.net>
27367
27368         Fix ftell on mingw.
27369         * lib/ftell.c (EOVERFLOW): Define if the system lacks it.
27370         * modules/ftell-tests (Depends-on): Add binary-io.
27371         * modules/ftello-tests (Depends-on): Likewise.
27372         * tests/test-ftell.c (main): Enhance test to cover behavior after
27373         ungetc.  Enforce binary mode.
27374         * tests/test-ftello.c (main): Likewise.
27375
27376         Pass test-freadseek on cygwin.
27377         * modules/freadseek (Depends-on): Use freadptr, not freadahead.
27378         * lib/freadseek.c (freadseek): Don't increment beyond bounds of
27379         ungetc buffer.
27380
27381         * tests/test-fflush2.c (main): Fix typo.
27382
27383 2008-03-29  Bruno Haible  <bruno@clisp.org>
27384
27385         * tests/test-fflush2.c (main): Temporarily disable the contents of
27386         this test.
27387         * m4/fflush.m4 (gl_FUNC_FFLUSH): Add a TODO.
27388         Reported by Eric Blake.
27389
27390 2008-03-28  Simon Josefsson  <simon@josefsson.org>
27391
27392         * lib/gc.h (enum Gc_hash): Add GC_SHA224.
27393         (GC_SHA224_DIGEST_SIZE): Add.
27394
27395         * lib/gc-libgcrypt.c (gc_hash_open): Handle SHA-224.
27396         (gc_hash_digest_length): Likewise.
27397         (gc_hash_buffer): Likewise.
27398
27399 2008-03-25  Bruno Haible  <bruno@clisp.org>
27400
27401         * doc/gnulib-tool.texi (gettextize and autopoint): Explain in more
27402         detail which gettext release to use.
27403         Reported by Simon Josefsson.
27404
27405 2008-03-26  Jim Meyering  <meyering@redhat.com>
27406
27407         gnumakefile: remove file from $(top_builddir), not from $(top_srcdir)
27408         * modules/gnumakefile (clean-GNUmakefile): Also, use
27409         test ... && ... || : syntax rather than if-then ... fi.
27410
27411         gnumakefile: Don't double-quote-expand $(VPATH) value.
27412         * modules/gnumakefile (clean-GNUmakefile): Use single quotes.
27413
27414 2008-03-24  Eric Blake  <ebb9@byu.net>
27415
27416         Alter GNUmakefile to install into top directory.
27417         * modules/maintainer-makefile: Split, and add dependency...
27418         * modules/gnumakefile: to this new module.
27419         * build-aux/GNUmakefile: Move...
27420         * top/GNUmakefile: ...here.
27421         * build-aux/maint.mk: Move...
27422         * top/maint.mk: ...here.
27423         * MODULES.html.sh (Support for maintaining...): Document new
27424         module.
27425
27426 2008-03-23  Bruno Haible  <bruno@clisp.org>
27427
27428         * gnulib-tool: New options --vc-files, --no-vc-files.
27429         (func_usage): Document them.
27430         (vc_files): New variable.
27431         (func_import): Consider vc_files.
27432         (func_create_testdir): Set vc_files to empty.
27433         Suggested by Jim Meyering and Karl Berry.
27434
27435 2008-03-23  Bruno Haible  <bruno@clisp.org>
27436
27437         Fix regex compilation error on HP-UX 11.
27438         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_TYPE_MBSTATE_T.
27439         * modules/regex (Files): Add m4/mbstate_t.m4.
27440         Reported by Ton Voon <ton.voon@altinity.com>.
27441
27442 2008-03-23  Bruno Haible  <bruno@clisp.org>
27443
27444         * doc/gnulib-tool.texi (gettextize and autopoint): New section.
27445
27446 2008-03-23  Eric Blake  <ebb9@byu.net>
27447             Bruno Haible  <bruno@clisp.org>
27448
27449         Install files from top/ in the destination directory.
27450         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
27451         augmentation also for the files from top/.
27452         (func_import, func_create_testdir): Rewrite file names:
27453         top/filename -> filename.
27454
27455 2008-03-23  Bruno Haible  <bruno@clisp.org>
27456
27457         Tweak "gnulib --version" output.
27458         * gnulib-tool (func_version): Replace "-dirty" suffix with "-modified".
27459
27460 2008-03-23  Bruno Haible  <bruno@clisp.org>
27461
27462         Tweak "gnulib --version" output.
27463         * gnulib-tool (func_version): Use date of last commit to ChangeLog,
27464         rather than contents of ChangeLog, when possible.
27465
27466 2008-03-21  Eric Blake  <ebb9@byu.net>
27467
27468         More --version tweaks.
27469         * gnulib-tool (func_version): Obey GNU Coding Standards.  Output
27470         date of last ChangeLog entry.
27471
27472 2008-03-21  Jim Meyering  <meyering@redhat.com>
27473
27474         * build-aux/GNUmakefile (_have-git-version-gen): Split long line.
27475
27476 2008-03-20  Eric Blake  <ebb9@byu.net>
27477
27478         VPATH fix.
27479         * build-aux/GNUmakefile (_have_git-version-gen): Look in correct dir.
27480
27481 2008-03-20  Simon Josefsson  <simon@josefsson.org>
27482
27483         * build-aux/GNUmakefile: Make git-version-gen optional.  Add
27484         _build-aux variable.  Suggested by Eric Blake <ebb9@byu.net>.
27485
27486 2008-03-20  Eric Blake  <ebb9@byu.net>
27487
27488         Sync GNUmakefile with coreutils.
27489         * build-aux/GNUmakefile (have-Makefile): Rename...
27490         (_have-Makefile): ...to this, for namespace consideration.
27491         (GNUmakefile.cfg): Include, if present.
27492         (_autoreconf): Define a default.
27493         (_is-dist-target): New rule for rebuilds to pick up intra-release
27494         version.
27495         (maint-cfg.mk): Rename...
27496         (cfg.mk): ...to this.
27497
27498 2008-03-18  Jim Meyering  <meyering@redhat.com>
27499
27500         New script and module: mktempd
27501         * MODULES.html.sh (maint+release support): Add mktempd.
27502         * build-aux/mktempd: New file.
27503         * modules/mktempd: New file.
27504
27505 2008-03-15  Jim Meyering  <meyering@redhat.com>
27506
27507         Undo last change.
27508         * lib/sha1.c, lib/md5.c: 63 != ~63.
27509         Reported by Andreas Schwab.
27510
27511         sha1.c, md5.c: Hoist a redundant expression.
27512         * lib/sha1.c (sha1_process_bytes): AND-off the low bits in
27513         "ctx->buflen" only once, before calling *_process_block.
27514         * lib/md5.c (md5_process_bytes): Likewise.
27515
27516 2008-03-14  Eric Blake  <ebb9@byu.net>
27517
27518         Bump copyright year in files generated by gnulib-tool.
27519         * gnulib-tool (func_emit_copyright_notice): Extract copyright from
27520         gnulib-tool, rather than hard-coding it.
27521
27522         Fix 'gnulib-tool --version' output to work with git.
27523         * gnulib-tool (func_gnulib_dir): New function, extracted from...
27524         (startup): ...here.
27525         (func_version): Use it to invoke git-version-gen, rather than
27526         relying on CVS keyword expansion.  Modernize wording.
27527         (cvsdatestamp, last_checkin_date, version): Kill unused
27528         variables.
27529
27530 2008-03-12  Jim Meyering  <meyering@redhat.com>
27531
27532         Recognize optional cast of the argument to free.
27533         * build-aux/useless-if-before-free: Update regexps.
27534
27535         * build-aux/bootstrap (gnulib_tool): Remove trailing blanks.
27536
27537 2008-03-11  Bruno Haible  <bruno@clisp.org>
27538
27539         Extend AC_LIB_LINKFLAGS to the situation of several libraries provided
27540         by a single package.
27541         * m4/lib-link.m4 (AC_LIB_FROMPACKAGE): New macro.
27542         (AC_LIB_LINKFLAGS_BODY): Use the information stored by
27543         AC_LIB_FROMPACKAGE. Use AC_ARG_WITH instead of AC_LIB_ARG_WITH.
27544         Reported by Sam Steingold <sds@gnu.org>.
27545
27546 2008-03-12  Sergey Poznyakoff  <gray@gnu.org.ua>
27547
27548         * build-aux/bootstrap (version_controlled_file): Adapt for SVN
27549         repositories.
27550
27551 2008-03-11  Bruno Haible  <bruno@clisp.org>
27552
27553         Avoid conflicts between local macro definitions.
27554         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
27555         AC_LIB_LINKFLAGS_BODY): Use pushdef/popdef instead of define/undefine.
27556
27557 2008-03-10  Peter O'Gorman  <bug-gnulib@mlists.thewrittenword.com>
27558             Bruno Haible  <bruno@clisp.org>
27559
27560         Make va_copy work with some version of xlc on AIX 5.1.
27561         * lib/stdarg.in.h: New file.
27562         * m4/stdarg.m4 (gl_STDARG_H): Initialize STDARG_H and NEXT_STDARG_H.
27563         On AIX, use a <stdarg.h> file substitute.
27564         * modules/stdarg (Files): Add lib/stdarg.in.h.
27565         (Depends-on): Add include_next.
27566         (Makefile.am): Build a stdarg.h substitute if requested.
27567         * doc/posix-functions/va_copy.texi: Document the platforms lacking it.
27568
27569 2008-03-10  Bruno Haible  <bruno@clisp.org>
27570
27571         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Document a restriction.
27572         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Likewise.
27573         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
27574
27575 2008-03-10  Bruno Haible  <bruno@clisp.org>
27576
27577         * modules/stdlib (Depends-on): Add include_next, remove
27578         absolute-header.
27579
27580 2008-03-09  Bruno Haible  <bruno@clisp.org>
27581
27582         * lib/freadahead.h (freadahead): Document more precisely.
27583         * lib/freadahead.c (freadahead): When an ungetc is in effect, return
27584         the sum of both buffer sizes.
27585         * tests/test-freadahead.c (main): Also test behaviour after ungetc.
27586         * NEWS: Document the change.
27587
27588 2008-03-09  Bruno Haible  <bruno@clisp.org>
27589
27590         Extend freadptr to return also the buffer size.
27591         * lib/freadptr.h (freadptr): Add sizep argument.
27592         * lib/freadptr.c: Include freadptr.h, not freadahead.h.
27593         (freadptr): Add sizep argument. Determine buffer size like freadahead
27594         does.
27595         * tests/test-freadptr.c: Don't include freadahead.h.
27596         (main): Adapt for new calling convention of freadptr.
27597         * tests/test-freadptr2.c: New file, based on tests/test-freadahead.c.
27598         * tests/test-freadptr2.sh: New file, based on tests/test-freadahead.sh.
27599         * modules/freadptr-tests (Files): Add tests/test-freadptr2.c,
27600         tests/test-freadptr2.sh.
27601         (Depends): Remove freadahead.
27602         (TESTS): Add test-freadptr2.sh.
27603         (check_PROGRAMS): Add test-freadptr2.
27604
27605 2008-03-09  Bruno Haible  <bruno@clisp.org>
27606
27607         * doc/Makefile (%.pdf): Explain how to remedy the save_size error.
27608         Report and solution by Simon Josefsson.
27609
27610 2008-03-06  Bruno Haible  <bruno@clisp.org>
27611
27612         Make fflush after ungetc work on BSD platforms.
27613         * lib/fflush.c (rpl_fflush): Discard ungetc buffer if possible.
27614         * tests/test-fflush2.c: New file.
27615         * tests/test-fflush2.sh: New file.
27616         * modules/fflush-tests (Files): Add tests/test-fflush2.sh,
27617         tests/test-fflush2.c.
27618         (Makefile.am): Build test-fflush2 and run test-fflush2.sh.
27619         * doc/posix-functions/fflush.texi: Document fflush after ungetc bug.
27620
27621 2008-03-06  Eric Blake  <ebb9@byu.net>
27622
27623         Likewise for ftello.
27624         * modules/ftello (Dependencies): Add extensions.
27625         * m4/ftello.m4 (gl_FUNC_FTELLO): Require AC_USE_SYSTEM_EXTENSIONS.
27626
27627 2008-03-06  Bruno Haible  <bruno@clisp.org>
27628
27629         * modules/fseeko (Dependencies): Add extensions.
27630         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Require AC_USE_SYSTEM_EXTENSIONS.
27631         Needed on glibc systems.
27632
27633 2008-03-06  Bruno Haible  <bruno@clisp.org>
27634
27635         * doc/gnulib-tool.texi (@nosuchmodulenote): Avoid line break inside
27636         email address.
27637         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
27638
27639 2008-03-06  Bruno Haible  <bruno@clisp.org>
27640
27641         * users.txt: Add libgnupdf.
27642
27643 2008-03-06  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
27644
27645         * doc/gnulib-tool.texi (@nosuchmodulenote): New macro.
27646         (Header File Substitutes, Function Substitutes,
27647         Glibc Header File Substitutes, Glibc Function Substitutes): Use it.
27648         (Build robot for gnulib): Fix typo.
27649
27650 2008-03-06  Bruno Haible  <bruno@clisp.org>
27651
27652         * doc/gnulib-tool.texi (VCS Issues): Small updates.
27653         Reported by Thien-Thi Nguyen <ttn@gnuvola.org>.
27654
27655 2008-03-06  Bruno Haible  <bruno@clisp.org>
27656
27657         * doc/func.texi: New file, extracted from doc/gnulib.texi.
27658         * doc/gnulib.texi: Include it.
27659
27660 2008-03-06  Simon Josefsson  <simon@josefsson.org>
27661
27662         * modules/func (License): Change license to unlimited; there was
27663         no LGPL parts in the module anyway.
27664
27665 2008-03-06  Simon Josefsson  <simon@josefsson.org>
27666
27667         * modules/__func__: Renamed to modules/func.
27668         * modules/__func__-tests: Renamed to modules/func-tests.
27669         * tests/test-__func__.c: Renamed to tests/test-func.c.
27670         * m4/__func__.m4: Renamed to m4/func.m4.
27671         * doc/gnulib.texi (__func__): Section renamed to func.
27672         Suggested by Eric Blake <ebb9@byu.net>.
27673
27674 2008-03-06  Simon Josefsson  <simon@josefsson.org>
27675
27676         * doc/gnulib.texi (__func__): Use C99 terminology when talking
27677         about __func__.  Make example self-contained.  Suggested by Eric
27678         Blake <ebb9@byu.net>.
27679
27680         * tests/test-__func__.c (main): Avoid extraneous () around __func.
27681         Suggested by Eric Blake <ebb9@byu.net>.
27682
27683 2008-03-06  Simon Josefsson  <simon@josefsson.org>
27684
27685         * modules/__func__: New file.
27686         * modules/__func__-tests: New file.
27687         * tests/test-__func__.c: New file.
27688         * m4/__func__.m4: New file.
27689         * doc/gnulib.texi (__func__): Document __func__ module.
27690
27691 2008-03-05  Simon Josefsson  <simon@josefsson.org>
27692
27693         * modules/byteswap (License): Re-license as LGPLv2+.
27694
27695 2008-03-05  Simon Josefsson  <simon@josefsson.org>
27696
27697         * doc/Makefile: Add pdf target.
27698
27699 2008-03-05  Simon Josefsson  <simon@josefsson.org>
27700
27701         * modules/inline (License): Use 'unlimited', since there are only
27702         *.m4 files in this module.
27703
27704 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
27705             Bruno Haible  <bruno@clisp.org>
27706
27707         Add support for HP C 7.1 on OpenVMS 8.3.
27708         * lib/alloca.in.h (alloca): Define as alias for DEC C on VMS.
27709
27710 2008-03-03  John E. Malmberg  <wb8tyw@qsl.net>  (tiny change)
27711
27712         Update VMS specifics.
27713         * lib/getopt.c [VMS]: Remove include of unixlib.h.
27714
27715 2008-03-02  Jim Meyering  <meyering@redhat.com>
27716
27717         Remove the last dependency on the "free" module.
27718         * m4/readutmp.m4 (gl_READUTMP): Don't require gl_FUNC_FREE.
27719         Reported by Bob Proulx.
27720
27721         * lib/getdelim.c (getdelim): Don't leak memory upon failed realloc.
27722
27723         Remove useless "if" tests before free.  Deprecate "free" module.
27724         * doc/posix-functions/free.texi: Mention that this
27725         module is no longer useful.
27726         * modules/free (Notice): Say this module is obsolete.
27727         * modules/readutmp (Depends-on): Remove free.
27728         * lib/save-cwd.c (free_cwd): Remove useless "if" before free.
27729         * lib/putenv.c (putenv): Likewise.
27730         * lib/gc-gnulib.c (gc_cipher_close): Likewise.
27731         * lib/getaddrinfo.c (freeaddrinfo): Likewise.
27732         * tests/test-c-strcasestr.c (main): Likewise.
27733         * tests/test-c-strstr.c (main): Likewise.
27734         * tests/test-mbscasestr1.c (main): Likewise.
27735         * tests/test-mbscasestr2.c (main): Likewise.
27736         * tests/test-mbsstr1.c (main): Likewise.
27737         * tests/test-mbsstr2.c (main): Likewise.
27738         * tests/test-memmem.c (main): Likewise.
27739         * tests/test-strcasestr.c (main): Likewise.
27740         * tests/test-striconv.c (main): Likewise.
27741         * tests/test-striconveh.c (main): Likewise.
27742         * tests/test-striconveha.c (main): Likewise.
27743         * tests/test-strstr.c (main): Likewise.
27744
27745         * build-aux/git-version-gen: Adjust a comment and the Usage string.
27746
27747         bootstrap: sync from coreutils again
27748         * build-aux/bootstrap: Remove dangling m4/*.m4 symlinks.
27749
27750 2008-03-01  Jim Meyering  <meyering@redhat.com>
27751
27752         bootstrap: sync from coreutils
27753         * build-aux/bootstrap (update_po_files): Copy a .po file into place
27754         also when the target doesn't exist.
27755
27756 2008-03-01  Eric Blake  <ebb9@byu.net>
27757
27758         Fix bugs in last patch.
27759         * lib/memchr2.c (memchr2): Fix typo.
27760         * tests/test-memchr2.c: Test previous bug, and don't use GNU
27761         extension.
27762         Reported by Bruce Korb.
27763
27764         New module 'memchr2'.
27765         * modules/memchr2: New file.
27766         * modules/memchr2-tests: Likewise.
27767         * lib/memchr2.h: Likewise.
27768         * lib/memchr2.c: Likewise, based on memchr.c.
27769         * tests/test-memchr2.c: New test.
27770         * MODULES.html.sh (String handling): Add memchr2.
27771
27772 2008-02-29  Bruno Haible  <bruno@clisp.org>
27773
27774         * modules/freadseek-tests: New file.
27775         * tests/test-freadseek.sh: New file.
27776         * tests/test-freadseek.c: New file.
27777
27778         New module 'freadseek'.
27779         * modules/freadseek: New file.
27780         * lib/freadseek.h: New file.
27781         * lib/freadseek.c: New file.
27782         * MODULES.html.sh (File stream based Input/Output): Add freadseek.
27783
27784 2008-02-29  Sergey Poznyakoff  <gray@gnu.org.ua>
27785
27786         * users.txt: Add anubis, cpio, mailfromd, mailutils, radius,
27787         wydawca.
27788
27789         * m4/argp.m4 (gl_ARGP): Use AC_TRY_LINK to test if
27790         program_invocation_name and program_invocation_short_name are
27791         present.
27792
27793 2008-02-28  Bruno Haible  <bruno@clisp.org>
27794
27795         * tests/test-freadptr.c: Add a test for behaviour after ungetc.
27796         * tests/test-freadptr.sh: Also test non-seekable stdin.
27797
27798 2008-02-28  Sergey Poznyakoff  <gray@gnu.org.ua>
27799
27800         * build-aux/bootstrap (source_base, m4_base)
27801         (doc_base, tests_base): New variables.
27802         (gnulib_tool_options): Do not hardcode base directories, use
27803         the above variables instead.
27804
27805 2008-02-28  Atsushi SAKAI  <sakaia@jp.fujitsu.com>
27806
27807         * lib/xsize.h: Fix typo in comment: s/tupe/type/.
27808
27809 2008-02-28  Bruno Haible  <bruno@clisp.org>
27810
27811         * modules/freadptr-tests: New file.
27812         * tests/test-freadptr.sh: New file.
27813         * tests/test-freadptr.c: New file.
27814
27815         New module 'freadptr'.
27816         * modules/freadptr: New file.
27817         * lib/freadptr.h: New file.
27818         * lib/freadptr.c: New file.
27819         * MODULES.html.sh (File stream based Input/Output): Add freadptr.
27820
27821 2008-02-26  Karl Berry  <karl@freefriends.org>
27822
27823         Sync from Libtool:
27824         * libltdl/argz.c (argz_add, argz_count): New functions.
27825         * libltdl/argz.in.h: Declare them.
27826         Report by Juan Manuel Guerrero <juan.guerrero@gmx.de>.
27827
27828 2008-02-22  Bruno Haible  <bruno@clisp.org>
27829
27830         * m4/time_r.m4 (gl_TIME_R): Also check that localtime_r's return type
27831         is a pointer type.  Needed for HP-UX 10.
27832         * doc/posix-functions/localtime_r.texi: Mention HP-UX 10.
27833         * doc/posix-functions/gmtime_r.texi: Likewise.
27834         Reported by Peter O'Gorman <bug-gnulib@mlists.thewrittenword.com>.
27835
27836 2008-02-24  Bruno Haible  <bruno@clisp.org>
27837
27838         * modules/environ-tests: New file.
27839         * tests/test-environ.c: New file.
27840
27841         New module 'environ'.
27842         * modules/environ: New file.
27843         * lib/unistd.in.h (environ): New declaration.
27844         * m4/environ.m4: New file.
27845         (gt_CHECK_VAR_DECL): Moved here from m4/setenv.m4. Undefine gt_cv_var
27846         after use.
27847         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_ENVIRON and
27848         HAVE_DECL_ENVIRON.
27849         * modules/unistd (Makefile.am): Substitute also GNULIB_ENVIRON and
27850         HAVE_DECL_ENVIRON.
27851         * doc/posix-functions/environ.texi: Mention module 'environ'. Remove
27852         wrong claim that 'environ' is missing on some systems.
27853         * modules/execute (Depends-on): Add environ.
27854         * lib/execute.c (environ): Remove fallback declaration.
27855         * modules/pipe (Depends-on): Add environ.
27856         * lib/pipe.c (environ): Remove fallback declaration.
27857         * modules/setenv (Depends-on): Add environ.
27858         * lib/setenv.c (environ): Remove fallback declaration.
27859         * modules/unsetenv (Depends-on): Add environ.
27860         * lib/unsetenv.c (environ): Remove fallback declaration.
27861         * m4/setenv.m4 (gt_CHECK_VAR_DECL): Remove macro. Moved to
27862         m4/environ.m4.
27863         (gl_PREREQ_SETENV): Require gl_ENVIRON instead of testing for environ.
27864         (gl_PREREQ_UNSETENV): Likewise.
27865
27866 2008-02-24  Bruno Haible  <bruno@clisp.org>
27867
27868         * doc/posix-functions/environ.texi: Document the MacOS X problem.
27869
27870 2008-02-20  Bob Proulx  <bob@proulx.com>
27871
27872         Enable use of older two part flavor 'git describe'.
27873         * build-aux/git-version-gen: If using the older two part flavor of
27874         git version then recreate the third part now present in the
27875         newer three part flavor of git describe.
27876
27877 2008-02-20  Martin Buchholz  <martin@xemacs.org>  (tiny change)
27878
27879         * lib/fts.c (fts_build): Typo correction to comment.
27880
27881 2008-02-17  Bruno Haible  <bruno@clisp.org>
27882
27883         * lib/git-merge-changelog.c (main) [split_merged_entry]: Avoid
27884         generating no-op conflicts.
27885
27886 2008-02-17  Bruno Haible  <bruno@clisp.org>
27887
27888         Speed up by 10%.
27889         * lib/git-merge-changelog.c (main): Use the iterator to iterate through
27890         result_entries, rather than an index-based loop.
27891
27892 2008-02-17  Bruno Haible  <bruno@clisp.org>
27893
27894         Speed up by 25%.
27895         * lib/git-merge-changelog.c (struct entry): New fields 'hashcode',
27896         'hashcode_cached'.
27897         (entry_create): New function.
27898         (entry_hashcode): Use the cached hashcode if possible.
27899         (read_changelog_file, try_split_merged_entry): Use entry_create.
27900
27901 2008-02-17  Bruno Haible  <bruno@clisp.org>
27902
27903         Speed up from O(n^2) to O(n) for long ChangeLog files.
27904         * lib/git-merge-changelog.c: Include gl_rbtreehash_list.h.
27905         (read_changelog_file): Change implementation of entries_reversed list
27906         to rbtreehash.
27907         * modules/git-merge-changelog (Depends-on): Add rbtreehash-list.
27908
27909 2008-02-17  Bruno Haible  <bruno@clisp.org>
27910
27911         New option --split-merged-entry.
27912         * lib/git-merge-changelog.c (FSTRCMP_STRICTER_THRESHOLD): New macro.
27913         (find_paragraph_end, try_split_merged_entry): New functions.
27914         (long_options): Add option --split-merged-entry.
27915         (usage): Document option --split-merged-entry.
27916         (main): Implement option --split-merged-entry.
27917         Reported by Eric Blake.
27918
27919 2008-02-17  Bruno Haible  <bruno@clisp.org>
27920
27921         * lib/git-merge-changelog.c: Include c-strstr.h.
27922         (main): Support the "git pull --rebase" situation.
27923         * modules/git-merge-changelog (Depends-on): Add c-strstr.
27924         Reported by Eric Blake.
27925
27926 2008-02-16  Eric Blake  <ebb9@byu.net>
27927
27928         Avoid doubling \ in common case of "c-maybe" quoting style.
27929         * lib/quotearg.c (quotearg_buffer_restyled): Don't escape \ when
27930         eliding outer quotes.
27931         * lib/quotearg.h: Document this.
27932         * tests/test-quotearg.c (result_strings, inputs, results_g)
27933         (flag_results, locale_results): Test it by adding a new string to
27934         each test group.
27935         (compare_strings): Test new string.
27936
27937 2008-02-13  Eric Blake  <ebb9@byu.net>
27938
27939         Avoid trigraph quoting in default output.
27940         * lib/quotearg.h (enum quoting_flags): Add QA_SPLIT_TRIGRAPHS.
27941         * lib/quotearg.c (quotearg_buffer_restyled): Don't quote trigraphs
27942         unless explicitly requested.
27943         * tests/test-quotearg.c (flag_results, main): Add additional tests.
27944
27945 2008-02-13  Lasse Collin  <lasse.collin@tukaani.org>
27946
27947         Don't rely on signed integer overflowing to negative value.
27948         * lib/getugroups.c (getugroups): Include <limits.h>.
27949         Instead, compare against INT_MAX, and increment only if the test passes.
27950
27951 2008-02-13  Jim Meyering  <meyering@redhat.com>
27952         and Eric Blake  <ebb9@byu.net>
27953
27954         Avoid shadowing warning and compile errors on Linux.
27955         * tests/test-quotearg.c [ENABLE_NLS]: Disable <libintl.h>
27956         forwarding macros on Linux.
27957         (dcgettext): Define a stub, for Linux.
27958         (results_g, main): Avoid warnings.
27959
27960 2008-02-12  Eric Blake  <ebb9@byu.net>
27961
27962         Silence warning in last patch.
27963         * lib/quotearg.c (quotearg_buffer_restyled): Add missing const.
27964
27965         Quotearg part 4: add tests, fix c-maybe colon quoting.
27966         * lib/quotearg.h: Improve documentation.
27967         * lib/quotearg.c (quotearg_buffer_restyled): Don't add extra
27968         escapes when adding outer quotes.  When quoting trigraphs, use
27969         valid C notation.  When quoting NUL, omit extra characters if next
27970         character is not digit.  Alter prototype.
27971         (quotearg_buffer, quotearg_alloc_mem, quotearg_n_options): Adjust
27972         callers.
27973         * modules/quotearg-tests: New module.
27974         * tests/test-quotearg.c: New test.
27975
27976 2008-02-07  Eric Blake  <ebb9@byu.net>
27977
27978         Quotearg part 3: add flag to control outer quote elision.
27979         * lib/quotearg.h (c_maybe_quoting_style): New style.
27980         (enum quoting_flags): Better documentation of flags.
27981         * lib/quotearg.c (quoting_style_args, quoting_style_vals): Add
27982         c-maybe style.
27983         (quotearg_buffer_restyled): Handle new flag to elide outer
27984         quotes.
27985
27986         Quotearg part 2: add flag that can control NUL elision.
27987         * lib/quotearg.h (set_quoting_flags): New prototype.
27988         * lib/quotearg.c (struct quoting_options): Add flag field.
27989         (set_quoting_flags): New function.
27990         (quotearg_buffer_restyled): Add flags parameter.
27991         (quotearg_alloc_mem): Set the flag if length cannot be returned.
27992         (quotearg_n_options): Set the flag, since length cannot be
27993         returned.
27994         (quoting_options_from_style): Default flags correctly.
27995
27996         Quotearg part 1: more wrappers, restore quotearg_char state.
27997         * lib/quotearg.h (quotearg_alloc_mem, quotearg_n_mem)
27998         (quotearg_mem, quotearg_style_mem, quotearg_char_mem)
27999         (quotearg_colon_mem): New wrappers.
28000         * lib/quotearg.c (quotearg_alloc, quotearg_char): Rewrite...
28001         (quotearg_alloc_mem, quotearg_char_mem): ...in terms of these new
28002         functions.
28003         (quotearg_n_mem, quotearg_mem, quotearg_style_mem)
28004         (quotearg_colon_mem): New functions.
28005
28006 2008-02-11  Bruno Haible  <bruno@clisp.org>
28007
28008         * modules/git-merge-changelog (Makefile.am): Don't use -L and -l for a
28009         library in the current directory: it does not work with parallel make.
28010         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
28011
28012 2008-02-11  Bruno Haible  <bruno@clisp.org>
28013
28014         * .gitattributes: New file.
28015
28016 2008-02-11  Jim Meyering  <meyering@redhat.com>
28017
28018         useless-if-before-free: Fix reversed exit values.
28019         * build-aux/useless-if-before-free: Use correct values
28020         for EXIT_MATCH and EXIT_NO_MATCH.
28021
28022         * build-aux/useless-if-before-free: Close stdout carefully.
28023
28024 2008-02-10  Bruno Haible  <bruno@clisp.org>
28025
28026         New module 'git-merge-changelog'.
28027         * modules/git-merge-changelog: New file.
28028         * lib/git-merge-changelog.c: New file.
28029
28030 2008-02-10  Jim Meyering  <meyering@redhat.com>
28031
28032         useless-if-before-free: New option: --list (-l).
28033
28034         useless-if-before-free: Don't exit immediately upon open failure.
28035         * build-aux/useless-if-before-free: Exit 2 for errors.
28036         Upon failure to open a file, don't exit immediately.
28037         Rather, just warn and continue with any remaining files.
28038
28039 2008-02-10  Bruno Haible  <bruno@clisp.org>
28040
28041         New abstract list operation 'node_set_value'.
28042         * lib/gl_list.h (gl_list_node_set_value): New function.
28043         (struct gl_list_implementation): New field node_set_value.
28044         * lib/gl_list.c (gl_list_node_set_value): New function.
28045         * lib/gl_array_list.c (gl_array_node_set_value): New function.
28046         (gl_array_list_implementation): Update.
28047         * lib/gl_carray_list.c (gl_carray_node_set_value): New function.
28048         (gl_carray_list_implementation): Update.
28049         * lib/gl_anylinked_list2.h (gl_linked_node_set_value): New function.
28050         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
28051         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
28052         * lib/gl_anytree_list2.h (gl_tree_node_set_value): New function.
28053         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
28054         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
28055         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
28056         Update.
28057         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
28058         * lib/gl_sublist.c (gl_sublist_node_set_value): New function.
28059         (gl_sublist_list_implementation): Update.
28060
28061 2008-02-10  Bruno Haible  <bruno@clisp.org>
28062
28063         * lib/diffseq.h: Write "ELEMENT const" instead of "const ELEMENT".
28064         Needed when ELEMENT is #defined to 'some_type *'.
28065
28066 2008-02-10  Jim Meyering  <meyering@redhat.com>
28067
28068         New script and module: useless-if-before-free
28069         * MODULES.html.sh (maint+release support): Add useless-if-before-free.
28070         * build-aux/useless-if-before-free: New file.
28071         * modules/useless-if-before-free: New file.
28072
28073         * build-aux/gitlog-to-changelog: Use committer date, not author date.
28074
28075         xstrtol_error: Fix typo.
28076         * lib/xstrtol-error.c (xstrtol_error): The parameter was unused:
28077         s/exit_failure/exit_status/.
28078
28079 2008-02-09  Jim Meyering  <meyering@redhat.com>
28080
28081         New script and module: gitlog-to-changelog
28082         * MODULES.html.sh (maint+release support): Add gitlog-to-changelog.
28083         * modules/gitlog-to-changelog: New file.
28084         * build-aux/gitlog-to-changelog: New file.
28085
28086 2008-02-08  Jim Meyering  <meyering@redhat.com>
28087
28088         Avoid two "parameter unused" warnings.
28089         * lib/stat-time.h (get_stat_birthtime_ns, get_stat_birthtime):
28090         Mark "st" as used.
28091
28092         Use "git COMMAND", not "git-COMMAND".
28093         * build-aux/bootstrap (version_controlled_file): s/git-rm/git-rm/.
28094         * build-aux/announce-gen (get_tool_versions): Correct a diagnostic.
28095         * build-aux/git-version-gen: Use "git status", not "git-status".
28096
28097 2008-02-07  Bruno Haible  <bruno@clisp.org>
28098
28099         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on native Woe32 systems.
28100         Avoids a crash on Windows Vista.
28101         Reported by Adam Strzelecki <ono@java.pl> via
28102         Simon Josefsson <simon@josefsson.org>.
28103
28104 2008-02-06  Bruno Haible  <bruno@clisp.org>
28105
28106         Fix *printf behaviour regarding the left-adjust flag on HP-UX 10.20.
28107         * m4/printf.m4 (gl_PRINTF_FLAG_LEFTADJUST): New macro.
28108         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_FLAG_LEFTADJUST.
28109         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST): New macro.
28110         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
28111         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
28112         gl_PRINTF_FLAG_LEFTADJUST and test its result. Invoke
28113         gl_PREREQ_VASNPRINTF_FLAG_LEFTADJUST.
28114         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
28115         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
28116         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
28117         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
28118         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
28119         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
28120         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
28121         * tests/test-vasnprintf-posix.c (test_function): Add testcases for the
28122         left-adjust flag.
28123         * tests/test-snprintf-posix.h (test_function): Likewise.
28124         * tests/test-sprintf-posix.h (test_function): Likewise.
28125         * tests/test-vasprintf-posix.c (test_function): Likewise.
28126         * doc/posix-functions/fprintf.texi: Update.
28127         * doc/posix-functions/printf.texi: Update.
28128         * doc/posix-functions/snprintf.texi: Update.
28129         * doc/posix-functions/sprintf.texi: Update.
28130         * doc/posix-functions/vfprintf.texi: Update.
28131         * doc/posix-functions/vprintf.texi: Update.
28132         * doc/posix-functions/vsnprintf.texi: Update.
28133         * doc/posix-functions/vsprintf.texi: Update.
28134         Reported by Peter Fales <psfales@alcatel-lucent.com>.
28135
28136 2008-02-06  Bruno Haible  <bruno@clisp.org>
28137
28138         Fix bug introduced on 2008-01-26.
28139         * lib/isnan.c (FUNC): Set to rpl_isnand, not rpl_isnan.
28140
28141 2008-02-06  Bruno Haible  <bruno@clisp.org>
28142
28143         Fix bug introduced on 2007-06-10.
28144         * lib/vasnprintf.c (VASNPRINTF): Perform zero-padding also if
28145         !NEED_PRINTF_FLAG_ZERO.
28146
28147 2008-02-05  Peter O'Gorman <pogma@thewrittenword.com>
28148
28149         getloadavg: use libperfstat on AIX5
28150         * lib/getloadavg.c, m4/getloadavg.m4 [aix]: Use libperfstat
28151
28152 2008-02-03  Bruno Haible  <bruno@clisp.org>
28153
28154         * lib/diffseq.h: Add comments about required #includes.
28155         Reported by Michael Biggs <gnulib@doubleplum.net>.
28156
28157 2008-02-01  Bruno Haible  <bruno@clisp.org>
28158
28159         * users.txt: Add gnuit.
28160
28161 2008-01-31  Bruno Haible  <bruno@clisp.org>
28162
28163         * lib/md4.c (set_uint32): Mark as inline.
28164         * lib/md5.c (set_uint32): Likewise.
28165         * lib/sha1.c (set_uint32): Likewise.
28166         * m4/md4.m4 (gl_MD4): Require AC_C_INLINE.
28167         * m4/md5.m4 (gl_MD5): Likewise.
28168         * m4/sha1.m4 (gl_SHA1): Likewise.
28169
28170 2008-01-31  Jim Meyering  <meyering@redhat.com>
28171
28172         Use "sizeof VAR", rather than a literal "4".
28173         * lib/md5.c (md5_read_ctx): Use sizeof ctx->A, not 4.
28174         * lib/md4.c (md4_read_ctx): Likewise.
28175         * lib/sha1.c (sha1_read_ctx): Likewise.
28176
28177 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28178
28179         * tests/test-sha1.c: New file, based on test-md5.c.
28180
28181         * modules/crypto/sha1-tests: New file.
28182
28183 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28184
28185         * lib/sha1.h (SHA1_DIGEST_SIZE): Define.
28186
28187 2008-01-31  Jim Meyering  <meyering@redhat.com>
28188
28189         Prefer "sizeof v" over the equivalent "4".
28190         * lib/md4.c (set_uint32): Use "sizeof v" as memcpy length, not 4.
28191         * lib/md5.c (set_uint32): Likewise.
28192         * lib/sha1.c (set_uint32): Likewise.
28193
28194 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28195
28196         * lib/sha1.c (set_uint32): Mark function as static.
28197
28198 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28199
28200         md2: clarify comments to say that alignment is not required.
28201         * lib/md2.h: Remove warning about alignment in comment.
28202         * lib/md2.c (md2_read_ctx, md2_finish_ctx): Doc fix, alignment has
28203         never been required.
28204
28205 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28206
28207         md4: adapt alignment constraint fix from sha1.
28208         * lib/md4.c (set_uint32): New function, from sha1.c
28209         (md4_read_ctx): Use it.
28210         (md4_finish_ctx): Doc fix.
28211         * lib/md4.h: Doc fix.
28212
28213 2008-01-31  Simon Josefsson  <simon@josefsson.org>
28214
28215         md5: adapt alignment constraint fix from sha1.
28216         * lib/md5.c (set_uint32): New function, from sha1.c
28217         (md5_read_ctx): Use it.
28218         (md5_finish_ctx): Doc fix.
28219         * lib/md5.h: Doc fix.
28220
28221 2008-01-30  Peter Palfrader  <weasel@debian.org>
28222
28223         sha1: remove the result buffer alignment constraint
28224         * lib/sha1.c (set_uint32): New function.
28225         (sha1_read_ctx): Rewrite to remove the result buffer alignment
28226         constraint.
28227         (sha1_finish_ctx): Remove comment warning about alignment constraint.
28228         * lib/sha1.h: Likewise.
28229
28230 2008-01-30  Andreas Schwab  <schwab@suse.de>
28231             Bruno Haible  <bruno@clisp.org>
28232
28233         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Include <float.h> and ensure a
28234         correct definition of LDBL_MIN_EXP.
28235
28236 2008-01-30  Karl Berry  <karl@gnu.org>
28237
28238         * config/srclist-update: try to preserve x bit on updates.
28239         * config/srclistvars.sh: update for karl.
28240
28241 2008-01-29  Jim Meyering  <meyering@redhat.com>
28242
28243         vasnprintf.c: Avoid warning about unused label
28244         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Guard the
28245         "overflow" label definition and associated code with the
28246         same cpp condition that guards the sole use of that label.
28247
28248 2008-01-26  Bruno Haible  <bruno@clisp.org>
28249
28250         * m4/isnanl.m4 (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM,
28251         gl_FUNC_ISNANL_WORKS): Test the GCC >= 4.0 built-in.
28252         * lib/isnanl.h (isnanl): Use the GCC >= 4.0 built-in.
28253         * lib/isnanl-nolibm.h (isnanl): Likewise.
28254         Reported by Paul Eggert <eggert@cs.ucla.edu>.
28255
28256 2008-01-26  Bruno Haible  <bruno@clisp.org>
28257
28258         * m4/isnand.m4 (gl_FUNC_ISNAND_NO_LIBM): Test the GCC >= 4.0 built-in.
28259         * lib/isnand.h (isnand): Use the GCC >= 4.0 built-in.
28260
28261 2008-01-26  Bruno Haible  <bruno@clisp.org>
28262
28263         * m4/isnanf.m4 (gl_HAVE_ISNANF_NO_LIBM, gl_ISNANF_WORKS): Test the
28264         GCC >= 4.0 built-in.
28265         * lib/isnanf.h (isnanf): Use the GCC >= 4.0 built-in.
28266
28267 2008-01-26  Bruno Haible  <bruno@clisp.org>
28268
28269         Rename isnan, applicable to 'double' only, to isnand.
28270         * modules/isnand-nolibm: Renamed from modules/isnan-nolibm.
28271         (Files): Add lib/isnand.h, lib/isnand.c. Remove lib/isnan.h.
28272         (configure.ac): Update.
28273         (Include): Replace "isnan.h" with "isnand.h".
28274         * m4/isnand.m4: Renamed from m4/isnan.m4.
28275         (gl_FUNC_ISNAND_NO_LIBM): Renamed from gl_FUNC_ISNAN_NO_LIBM. Set
28276         HAVE_ISNAND_IN_LIBC instead of HAVE_ISNAN_IN_LIBC. Build isnand.c
28277         instead of isnan.c.
28278         * lib/isnand.h: Renamed from lib/isnan.h. Test HAVE_ISNAND_IN_LIBC
28279         instead of HAVE_ISNAN_IN_LIBC.
28280         (isnand): Renamed from isnan.
28281         * lib/isnand.c: New file.
28282         * modules/isnand-nolibm-tests: Renamed from modules/isnan-nolibm-tests.
28283         (Files): Add tests/test-isnand.c. Remove tests/test-isnan.c.
28284         (Makefile.am): Update.
28285         * tests/test-isnand.c: Renamed from tests/test-isnan.c.
28286         Include isnand.h instead of isnan.h.
28287         (main): Test isnand instead of isnan.
28288         * modules/fprintf-posix (Depends-on): Add isnand-nolibm, remove
28289         isnan-nolibm.
28290         * modules/frexp (Depends-on): Likewise.
28291         * modules/frexp-tests (Depends-on): Likewise.
28292         * modules/frexp-nolibm (Depends-on): Likewise.
28293         * modules/frexp-nolibm-tests (Depends-on): Likewise.
28294         * modules/isfinite (Depends-on): Likewise.
28295         * modules/round-tests (Depends-on): Likewise.
28296         * modules/signbit (Depends-on): Likewise.
28297         * modules/signbit-tests (Depends-on): Likewise.
28298         * modules/snprintf-posix (Depends-on): Likewise.
28299         * modules/sprintf-posix (Depends-on): Likewise.
28300         * modules/trunc-tests (Depends-on): Likewise.
28301         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
28302         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
28303         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
28304         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
28305         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
28306         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
28307         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
28308         * modules/vasnprintf-posix (Depends-on): Likewise.
28309         * modules/vasprintf-posix (Depends-on): Likewise.
28310         * modules/vfprintf-posix (Depends-on): Likewise.
28311         * modules/vsnprintf-posix (Depends-on): Likewise.
28312         * modules/vsprintf-posix (Depends-on): Likewise.
28313         * lib/frexp.c: Include isnand.h instead of isnan.h.
28314         (ISNAN): Set to isnand instead of isnan.
28315         * lib/isfinite.c: Include isnand.h instead of isnan.h.
28316         (gl_isfinited): Use isnand instead of isnan.
28317         * lib/signbitd.c: Include isnand.h instead of isnan.h.
28318         (gl_signbitd): Use isnand instead of isnan.
28319         * lib/vasnprintf.c: Include isnand.h instead of isnan.h.
28320         (is_infinite_or_zero, VASNPRINTF): Use isnand instead of isnan.
28321         * tests/test-frexp.c: Include isnand.h instead of isnan.h.
28322         (main): Use isnand instead of isnan.
28323         * tests/test-round1.c: Include isnand.h.
28324         (main): Use isnand instead of isnan.
28325         * tests/test-round2.c: Include isnand.h instead of isnan.h.
28326         (ISNAN): Set to isnand instead of isnan.
28327         * tests/test-trunc1.c: Include isnand.h.
28328         (main): Use isnand instead of isnan.
28329         * tests/test-trunc2.c: Include isnand.h instead of isnan.h.
28330         (equal): Use isnand instead of isnan.
28331         * MODULES.html.sh (Mathematics <math.h>): Replace isnan-nolibm with
28332         isnand-nolibm.
28333         * NEWS: Mention the change.
28334
28335 2008-01-25  Paul Eggert  <eggert@cs.ucla.edu>
28336             Bruno Haible  <bruno@clisp.org>
28337
28338         * m4/signbit.m4 (gl_SIGNBIT): Require a macro definition. Test whether
28339         the GCC builtins for signbits are present and set
28340         REPLACE_SIGNBIT_USING_GCC if so.
28341         * lib/math.in.h (signbit): Define using GCC builtins if
28342         REPLACE_SIGNBIT_USING_GCC is set.
28343         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize
28344         REPLACE_SIGNBIT_USING_GCC.
28345         * modules/math (Makefile.am): Substitute REPLACE_SIGNBIT_USING_GCC.
28346
28347 2008-01-25  Jim Meyering  <meyering@redhat.com>
28348
28349         Prefer <config.h> over "config.h".  See autoconf doc for explanation.
28350         * lib/poll.c: Include <config.h>, not "config.h".
28351         * tests/test-getaddrinfo.c: Likewise.
28352
28353 2008-01-25  Simon Josefsson  <simon@josefsson.org>
28354
28355         * modules/sockets-tests: New file.
28356
28357 2008-01-24  Simon Josefsson  <simon@josefsson.org>
28358
28359         * modules/sockets: New module, can be used to call WSA_Startup and
28360         WSA_Cleanup when needed.
28361
28362         * lib/sockets.h, lib/sockets.c: New files.
28363
28364         * m4/sockets.m4: New file.
28365
28366         * tests/test-sockets.c: New file.
28367
28368 2008-01-19  Bruno Haible  <bruno@clisp.org>
28369
28370         * doc/posix-headers: Renamed from doc/headers.
28371         * doc/posix-functions: Renamed from doc/functions.
28372         * doc/gnulib.texi: Update.
28373
28374 2008-01-19  Bruno Haible  <bruno@clisp.org>
28375
28376         * doc/glibc-functions/strcasestr.texi: Include contents of
28377         doc/functions/strcasestr.texi, fixing the list of platforms.
28378         * doc/functions/strcasestr.texi: Remove file.
28379
28380 2008-01-19  Bruno Haible  <bruno@clisp.org>
28381
28382         * doc/glibc-functions/memmem.texi: Include contents of
28383         doc/functions/memmem.texi.
28384         * doc/functions/memmem.texi: Remove file.
28385
28386 2008-01-18  Bruno Haible  <bruno@clisp.org>
28387
28388         * doc/glibc-functions/*.texi: New files.
28389         * doc/gnulib.texi (Glibc Function Substitutes): Completely rewritten
28390         to use the new files.
28391
28392 2008-01-17  Bruno Haible  <bruno@clisp.org>
28393
28394         * tests/test-gethostname.c (main): Fix printf statement.
28395
28396 2008-01-17  Simon Josefsson  <simon@josefsson.org>
28397
28398         * modules/gethostname-tests: New file.
28399
28400         * tests/test-gethostname.c: New file.
28401
28402 2008-01-17  Simon Josefsson  <simon@josefsson.org>
28403
28404         * lib/gethostname.c: Include string.h unconditionally, strncpy is
28405         used by the UNAME case.  Reported by Bruno Haible
28406         <bruno@clisp.org>.
28407
28408 2008-01-17  Eric Blake  <ebb9@byu.net>
28409
28410         Convert c-strcasestr to be more efficient.
28411         * modules/c-strcasestr (Files): Use Two-Way, not KMP.
28412         (Depends-on): Add c-strcase, remove malloca, strnlen.
28413         * tests/test-c-strcasestr.c (main): Enhance test.
28414         * lib/c-strcasestr.c (c_strcasestr): Rewrite to new algorithm.
28415
28416 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
28417
28418         * build-aux/bootstrap (MSGID_BUGS_ADDRESS): New overridable variable.
28419         Use it in creating po/Makevars.
28420
28421 2008-01-15  Simon Josefsson  <simon@josefsson.org>
28422
28423         * lib/gc-libgcrypt.c (gc_init): Disable secure memory by default.
28424         Applications that requires it should initialize libgcrypt
28425         manually.
28426
28427 2008-01-16  Simon Josefsson  <simon@josefsson.org>
28428
28429         * lib/gethostname.c [!HAVE_UNAME]: Need string.h for strcpy.
28430
28431 2008-01-15  Paul Eggert  <eggert@cs.ucla.edu>
28432
28433         Fix problem with getdate on mingw32 reported by Simon Josefsson
28434         in <http://lists.gnu.org/archive/html/bug-gnulib/2008-01/msg00192.html>.
28435         * lib/getdate.y (get_date): Check "HAVE_DECL_TZNAME", not "defined
28436         tzname", when deciding whether to declare tzname.
28437         * lib/strftime.c (tzname): Likewise.
28438
28439 2008-01-15  Bruno Haible  <bruno@clisp.org>
28440
28441         Work around a MacOS X 10.5 bug in frexpl().
28442         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Also check denormalized numbers.
28443         * doc/functions/frexpl.texi: Document the bug.
28444         Reported by Elias Pipping <pipping@gentoo.org>.
28445
28446 2008-01-14  Eric Blake  <ebb9@byu.net>
28447
28448         Touch up previous patch.
28449         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR_SIMPLE): Fix typo.
28450         * doc/functions/strcasestr.texi (strcasestr): Document OpenBSD bug.
28451
28452         Convert strcasestr module to use Two-Way algorithm.
28453         * modules/strcasestr-simple: New module, based on the old
28454         strcasestr, but with Two-Way rather than KMP.
28455         * modules/strcasestr (Depends-on): Change to strcasestr-simple.
28456         * lib/string.in.h (rpl_strcasestr): Declare.
28457         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Check for linear
28458         performance.
28459         * lib/strcasestr.c (strcasestr): Simplify, and avoid malloc.
28460         * modules/string (Makefile.am): Support strcasestr.
28461         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
28462         * modules/strcasestr-tests (Depends-on): Check for alarm.
28463         * tests/test-strcasestr.c: Augment test.
28464         * lib/str-two-way.h: Clean up stray macro.
28465         * NEWS: Document new module.
28466         * MODULES.html.sh (string handling): Likewise.
28467         * doc/functions/strcasestr.texi: New file.
28468         * doc/gnulib.texi (Function Substitutes): New node.  Move memmem
28469         here, since it is not a POSIX function.
28470
28471 2008-01-14  Colin Watson  <cjwatson@debian.org>
28472             Bruno Haible  <bruno@clisp.org>
28473
28474         * m4/strsignal.m4 (gl_FUNC_STRSIGNAL): Also check whether strsignal
28475         works fine; if not, set REPLACE_STRSIGNAL.
28476         (gl_PREREQ_STRSIGNAL): Require AC_DECL_SYS_SIGLIST.
28477         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
28478         REPLACE_STRSIGNAL.
28479         * lib/string.in.h (strsignal): Consider REPLACE_STRSIGNAL.
28480         * modules/string (Makefile.am): Substitute REPLACE_STRSIGNAL.
28481         * tests/test-strsignal.c (main): Check out-of-range signal numbers.
28482
28483 2008-01-14  Bruno Haible  <bruno@clisp.org>
28484
28485         * modules/strsignal (Include): Change to <string.h>.
28486
28487 2008-01-14  Colin Watson  <cjwatson@debian.org>
28488
28489         * modules/argp (Notice): Add a notice recommending to change
28490         XGETTEXT_OPTIONS.
28491         (configure.ac): Invoke AM_XGETTEXT_OPTION if it exists.
28492
28493 2008-01-13  Colin Watson  <cjwatson@debian.org>
28494
28495         * modules/strsignal-tests: New file.
28496         * tests/test-strsignal.c: New file.
28497
28498         * lib/strsignal.c: New file, from glibc with modifications.
28499         * lib/siglist.h: New file, from glibc with modifications.
28500         * lib/string.in.h (strsignal): New declaration.
28501         * m4/strsignal.m4: New file.
28502         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
28503         GNULIB_STRSIGNAL and HAVE_DECL_STRSIGNAL.
28504         * modules/strsignal: New file.
28505         * modules/string (Makefile.am): Substitute GNULIB_STRSIGNAL and
28506         HAVE_DECL_STRSIGNAL.
28507
28508 2008-01-13  Bruno Haible  <bruno@clisp.org>
28509
28510         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check that the
28511         locale encoding is not ASCII. Needed for OpenBSD 4.0.
28512         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
28513         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
28514
28515 2008-01-13  Bruno Haible  <bruno@clisp.org>
28516
28517         * lib/argp-fmtstream.h (__attribute__): Don't redefine if
28518         __STRICT_ANSI__ is set: it's not needed by any version of gcc.
28519         * lib/argp.h (__attribute__): Likewise.
28520         * lib/c-stack.c (__attribute__): Likewise.
28521         * lib/error.h (__attribute__): Likewise.
28522         * lib/fts.c (__attribute__): Likewise.
28523         * lib/openat.h (__attribute__): Likewise.
28524         * lib/stdio.in.h (__attribute__): Likewise.
28525         * lib/string.in.h (__attribute__): Likewise.
28526         * lib/utimens.c (__attribute__): Likewise.
28527         * lib/vasnprintf.h (__attribute__): Likewise.
28528         * lib/xalloc.h (__attribute__): Likewise.
28529         * lib/xprintf.h (__attribute__): Likewise.
28530         * lib/xstrtol.h (__attribute__): Likewise.
28531         * lib/xvasprintf.h (__attribute__): Likewise.
28532
28533 2008-01-12  Bruno Haible  <bruno@clisp.org>
28534
28535         * doc/gnulib.texi (Glibc Header File Substitutes): New chapter.
28536         * doc/glibc-headers/a.out.texi: New file.
28537         * doc/glibc-headers/aliases.texi: New file.
28538         * doc/glibc-headers/alloca.texi: New file.
28539         * doc/glibc-headers/ar.texi: New file.
28540         * doc/glibc-headers/argp.texi: New file.
28541         * doc/glibc-headers/argz.texi: New file.
28542         * doc/glibc-headers/byteswap.texi: New file.
28543         * doc/glibc-headers/crypt.texi: New file.
28544         * doc/glibc-headers/endian.texi: New file.
28545         * doc/glibc-headers/envz.texi: New file.
28546         * doc/glibc-headers/err.texi: New file.
28547         * doc/glibc-headers/error.texi: New file.
28548         * doc/glibc-headers/execinfo.texi: New file.
28549         * doc/glibc-headers/fpu_control.texi: New file.
28550         * doc/glibc-headers/fstab.texi: New file.
28551         * doc/glibc-headers/fts.texi: New file.
28552         * doc/glibc-headers/getopt.texi: New file.
28553         * doc/glibc-headers/ieee754.texi: New file.
28554         * doc/glibc-headers/ifaddrs.texi: New file.
28555         * doc/glibc-headers/libintl.texi: New file.
28556         * doc/glibc-headers/mcheck.texi: New file.
28557         * doc/glibc-headers/mntent.texi: New file.
28558         * doc/glibc-headers/obstack.texi: New file.
28559         * doc/glibc-headers/paths.texi: New file.
28560         * doc/glibc-headers/printf.texi: New file.
28561         * doc/glibc-headers/pty.texi: New file.
28562         * doc/glibc-headers/resolv.texi: New file.
28563         * doc/glibc-headers/shadow.texi: New file.
28564         * doc/glibc-headers/sysexits.texi: New file.
28565         * doc/glibc-headers/ttyent.texi: New file.
28566
28567 2008-01-12  Jim Meyering  <meyering@redhat.com>
28568
28569         announce-gen: emit Gnulib's git-based version string.
28570         * build-aux/announce-gen: Remove option: --gnulib-snapshot-time-stamp=S.
28571         New option --gnulib-version=V, where V is expected to be
28572         the output of running git describe in the gnulib directory.
28573         (get_tool_versions): Request feedback on xdelta.  I suspect it's
28574         not useful, and plan to stop publishing an xdelta file with each
28575         coreutils release.
28576
28577         * build-aux/announce-gen: Also check for lzma-compressed files.
28578
28579 2008-01-11  Bruno Haible  <bruno@clisp.org>
28580
28581         * tests/test-memmem.c (main): Increase maximum allowed time.
28582         * tests/test-strstr.c (main): Likewise.
28583
28584 2008-01-11  Bruno Haible  <bruno@clisp.org>
28585
28586         * doc/functions/memmem.texi: Add more precisions about platforms.
28587         * doc/functions/strstr.texi: Likewise.
28588
28589 2008-01-10  Eric Blake  <ebb9@byu.net>
28590
28591         * m4/strstr.m4: Delete cruft from copy-n-paste.
28592         Reported by Bruno Haible.
28593
28594 2008-01-10  Bruno Haible  <bruno@clisp.org>
28595
28596         Make c-strstr rely on strstr.
28597         * lib/c-strstr.c: Don't include str-kmp.h.
28598         (c_strstr): Define in terms of strstr.
28599         * modules/c-strstr (Files): Remove lib/str-kmp.h.
28600         (Depends-on): Remove stdbool, malloca, strnlen. Add strstr.
28601
28602 2008-01-10  Bruno Haible  <bruno@clisp.org>
28603
28604         * doc/gnulib.texi (String Functions in C Locale): New section.
28605         * doc/c-ctype.texi: New file.
28606         * doc/c-strcase.texi: New file.
28607         * doc/c-strcaseeq.texi: New file.
28608         * doc/c-strcasestr.texi: New file.
28609         * doc/c-strstr.texi: New file.
28610         * doc/c-strtod.texi: New file.
28611         * doc/c-strtold.texi: New file.
28612
28613 2008-01-10  Eric Blake  <ebb9@byu.net>
28614
28615         * lib/relocatable.h: Fix a comment.
28616
28617 2008-01-10  Eric Blake  <ebb9@byu.net>
28618
28619         Share two-way algorithm.
28620         * lib/str-two-way.h: New file, merged from...
28621         * lib/memmem.c: ...here...
28622         * lib/strstr.c: ...and here.
28623         * modules/memmem (Files): Use it.
28624         * modules/strstr (Files): Likewise.
28625
28626         Avoid quadratic strstr implementations.
28627         * lib/strstr.c: New file.
28628         * m4/strstr.m4: Likewise.
28629         * modules/strstr: Likewise.
28630         * modules/strstr-tests: Likewise.
28631         * tests/test-strstr.c: Likewise.
28632         * lib/string.in.h (rpl_strstr): Declare.
28633         (memmem) [GNULIB_POSIXCHECK]: Document speed issue.
28634         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Support strstr.
28635         * modules/string (Makefile.am): Likewise.
28636         * MODULES.html.sh (string handling): Mention new module.
28637         * doc/functions/strstr.texi (strstr): Document the bug.
28638
28639 2008-01-10  Bruno Haible  <bruno@clisp.org>
28640
28641         * lib/relocatable.h (relocate): State whether result is freshly
28642         allocated or not.
28643         * lib/relocatable.c (relocate): Return a freshly allocated string
28644         instead of a pointer to a privately held string.
28645         Reported by Sylvain Beucler <beuc@gnu.org>.
28646
28647 2008-01-10  Colin Watson  <cjwatson@debian.org>
28648
28649         * lib/canonicalize-lgpl.c [!_LIBC]: Fix typo in #if directive:
28650         s/S_ISNLK/S_ISLNK/.
28651
28652 2008-01-09  Bruno Haible  <bruno@clisp.org>
28653
28654         * doc/functions/memmem.texi: Use the same structure as snprintf.texi
28655         and other files.
28656         * m4/memmem.m4 (gl_FUNC_MEMMEM): Say "guessing no" instead of "no"
28657         if it's only a guess.
28658         * modules/memmem: Simplify by depending on memmem-simple.
28659
28660 2008-01-09  Bruno Haible  <bruno@clisp.org>
28661
28662         Work around OpenBSD 4.0 tdelete() bug.
28663         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Also check tdelete's return value.
28664         * lib/search.in.h: If REPLACE_TSEARCH is 1, define tsearch etc. as
28665         macros and don't redefine the enum values.
28666         * m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Initialize REPLACE_TSEARCH.
28667         * modules/search (Makefile.am): Also substitute REPLACE_TSEARCH.
28668         * doc/functions/tdelete.texi: Document the OpenBSD 4.0 bug.
28669
28670 2008-01-09  Bruno Haible  <bruno@clisp.org>
28671
28672         * tests/test-wcwidth.c: Include <string.h> and localcharset.h.
28673         (main): Don't perform the tests if setlocale did not install a UTF-8
28674         locale. Needed on OpenBSD 4.0.
28675         * modules/wcwidth-tests (Depends-on): Add localcharset.
28676
28677 2008-01-09  Paul Eggert  <eggert@cs.ucla.edu>
28678
28679         gl_FUNC_ALLOCA no longer defines HAVE_ALLOCA_H unconditionally.
28680         See <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00149.html>.
28681         * NEWS: announce this.
28682         * m4/alloca.m4 (gl_FUNC_ALLOCA): Don't define HAVE_ALLOCA_H.
28683
28684 2008-01-09  Simon Josefsson  <simon@josefsson.org>
28685         and Eric Blake  <ebb9@byu.net>
28686
28687         Add memmem-simple module.
28688         * m4/memmem.m4 (gl_FUNC_MEMMEM_SIMPLE): New macro.
28689         (gl_FUNC_MEMMEM): Separate performance from presence checks.
28690         * modules/memmem-simple: New file.
28691         * modules/memmem (Description): Tweak.
28692         * MODULES.html.sh (string handling): Mention new module.
28693         * doc/functions/memmem.texi (memmem): Distinguish which flaws are
28694         addressed by memmem-simple.
28695         * NEWS: Document the difference.
28696
28697 2008-01-09  Eric Blake  <ebb9@byu.net>
28698
28699         Give gcc some memmem optimization hints.
28700         * lib/string.in.h (memmem, memrchr, strchrnul, strnlen, strpbrk)
28701         (strcasestr): Declare as pure.
28702         * modules/memmem (Maintainer): Claim my implementation.
28703
28704 2008-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
28705
28706         Support AIX 6.1 and higher.
28707         * build-aux/config.libpath: Likewise.
28708         * build-aux/config.rpath: Likewise.
28709
28710 2008-01-08  Jim Meyering  <meyering@redhat.com>
28711             Bruno Haible  <bruno@clisp.org>
28712
28713         * lib/printf-parse.c (PRINTF_PARSE): Handle a size specifier "q"
28714         on MacOS X and a size specifier "I64" on mingw. Needed for PRIdMAX.
28715         Reported by Peter Fales in
28716         <http://lists.gnu.org/archive/html/bug-coreutils/2007-12/msg00148.html>.
28717
28718 2008-01-08  Bruno Haible  <bruno@clisp.org>
28719
28720         * modules/unictype/category-of (Depends-on): Add
28721         unictype/category-none.
28722         * modules/unictype/category-and-tests (Depends-on): Add
28723         unictype/category-{L,N,Lu,Nd}.
28724         * modules/unictype/category-and-not-tests (Depends-on): Likewise.
28725         * modules/unictype/category-or-tests (Depends-on): Add
28726         unictype/category-{L,N}.
28727         * modules/unictype/category-name-tests (Depends-on): Add
28728         unictype/category-{Z,Nl}.
28729         Reported by Simon Josefsson.
28730
28731 2008-01-08  Bruno Haible  <bruno@clisp.org>
28732
28733         * lib/str-kmp.h (knuth_morris_pratt_unibyte): Document the calling
28734         convention better.
28735         * lib/mbsstr.c (knuth_morris_pratt_multibyte): Likewise.
28736         * lib/mbscasestr.c (knuth_morris_pratt_multibyte): Likewise.
28737         Reported by Peter Miller <millerp@canb.auug.org.au>.
28738
28739 2008-01-08  Eric Blake  <ebb9@byu.net>
28740
28741         Rewrite memmem to guarantee linear complexity without malloc.
28742         * lib/memmem.c (memmem): Use Two-Way rather than
28743         Knuth-Morris-Pratt, to allow O(1) space usage.
28744         (critical_factorization, two_way_short_needle)
28745         (two_way_long_needle): New functions.
28746         (knuth_morris_pratt): Delete.
28747         * modules/memmem (Depends-on): No longer need malloca or stdbool.
28748         Add stdint.
28749         * tests/test-memmem.c (main): Add tests for periodic needle and
28750         sublinear performance.
28751         * doc/functions/memmem.texi (memmem): Document other deficiencies
28752         in cygwin and older glibc.
28753
28754 2008-01-08  Bruno Haible  <bruno@clisp.org>
28755
28756         * modules/memmem-tests (Makefile.am): Remove TESTS_ENVIRONMENT
28757         augmentation.
28758
28759 2008-01-08  Mike Frysinger  <vapier@gentoo.org>
28760
28761         Add a configure time option: --disable-acl.
28762         * m4/acl.m4 (gl_FUNC_ACL): Wrap all ACL logic in a call to
28763         AC_ARG_ENABLE(acl).
28764
28765 2008-01-06  Simon Josefsson  <simon@josefsson.org>
28766
28767         * tests/test-localename.c: Don't include obsolete "setenv.h".
28768
28769         * modules/localename-tests (Depends-on): Need unsetenv.
28770
28771 2008-01-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
28772
28773         * DEPENDENCIES: Require Texinfo version 4.6 or newer.
28774
28775 2008-01-06  Colin Watson  <cjwatson@debian.org>
28776
28777         * users.txt: Add man-db.
28778
28779 2008-01-07  Bruno Haible  <bruno@clisp.org>
28780
28781         * doc/gnulib-intro.texi (Library vs Reusable Code): Restore the
28782         previous section name.
28783
28784 2008-01-07  Bruno Haible  <bruno@clisp.org>
28785
28786         * lib/progname.c (set_program_name): Don't strip off a leading
28787         "lt-" prefix outside a .libs directory.
28788         Suggested by Paul Eggert.
28789
28790 2008-01-01  Sylvain Beucler  <beuc@gnu.org>
28791             Bruno Haible  <bruno@clisp.org>
28792
28793         Improve memory cleanup in 'relocatable' module.
28794         * lib/relocatable.h (compute_curr_prefix): Change return type to
28795         'char *'.
28796         * lib/relocatable.c (compute_curr_prefix): Change return type to
28797         'char *'. Free curr_installdir after use.
28798         (relocate): Free curr_prefix_better after use.
28799         * lib/progreloc.c (prepare_relocate): Free curr_prefix after use.
28800
28801 2008-01-01  Bruno Haible  <bruno@clisp.org>
28802
28803         * tests/test-wcwidth.c (main): Relax test of U+2060. Avoids a test
28804         failure on older glibc systems.
28805         Reported by Peter Fales <psfales@alcatel-lucent.com>.
28806
28807 2008-01-05  Eric Blake  <ebb9@byu.net>
28808
28809         Avoid quadratic system memmem.
28810         * m4/memmem.m4 (gl_FUNC_MEMMEM): Check for quadratic memmem.
28811         Reported by Ralf Wildenhues.
28812
28813         Fix memmem test for mingw.
28814         * modules/memmem-tests (configure.ac): Check for alarm.
28815         * tests/test-memmem.c (main): Avoid alarm on platforms that lack
28816         it.
28817         * doc/functions/memmem.texi: New file.
28818         * doc/gnulib.texi (Function Substitutes): Add memmem.
28819         Reported by Bruno Haible.
28820
28821 2008-01-04  Bruno Haible  <bruno@clisp.org>
28822
28823         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP):
28824         Require gl_HEADER_STRINGS_H_DEFAULTS, not
28825         gl_HEADER_STRING_H_DEFAULTS.
28826
28827 2008-01-04  Eric Blake  <ebb9@byu.net>
28828
28829         Shorten duration of memmem test.
28830         * tests/test-memmem.c (main): Use alarm to declare failure if test
28831         is taking too long.
28832         Reported by Ralf Wildenhues.
28833
28834 2007-12-21  Simon Josefsson  <simon@josefsson.org>
28835
28836         * modules/relocatable-prog-wrapper (Depends-on): Add intprops and
28837         string, needed by strerror.
28838
28839 2008-01-03  Colin Watson  <cjwatson@debian.org>
28840             Bruno Haible  <bruno@clisp.org>
28841
28842         * doc/gnulib-tool.texi (Localization): New section.
28843
28844 2008-01-02  Bruno Haible  <bruno@clisp.org>
28845
28846         * lib/memmem.c (knuth_morris_pratt, memmem): Change all 'char *'
28847         variables to 'unsigned char *' type.
28848         Reported by Paul Eggert.
28849
28850 2008-01-02  Jim Meyering  <jim@meyering.net>
28851
28852         * lib/version-etc.c (COPYRIGHT_YEAR): Increase for new year.
28853
28854 2007-12-31  Jim Meyering  <jim@meyering.net>
28855
28856         Avoid use of private FTS type name.
28857         * lib/fts.c (fts_sort): Use FTSENT rather than "struct _ftsent".
28858
28859 2007-12-30  Karl Berry  <karl@gnu.org>
28860
28861         * doc/gnulib.texi (Library vs. Reusable Code): remove period, to
28862         work around defect in Texinfo and/or the standalone Info browser.
28863
28864 2007-12-30  Bruno Haible  <bruno@clisp.org>
28865
28866         Unify 5 copies of the KMP code.
28867         * lib/str-kmp.h: New file.
28868         * lib/c-strcasestr.c: Include str-kmp.h.
28869         (knuth_morris_pratt): Remove function.
28870         (c_strcasestr): Update.
28871         * lib/c-strstr.c: Include str-kmp.h.
28872         (knuth_morris_pratt): Remove function.
28873         (c_strcasestr): Update.
28874         * lib/mbscasestr.c: Include str-kmp.h.
28875         (knuth_morris_pratt_unibyte): Remove function.
28876         * lib/mbsstr.c: Include str-kmp.h.
28877         (knuth_morris_pratt_unibyte): Remove function.
28878         * lib/strcasestr.c: Include str-kmp.h.
28879         (knuth_morris_pratt): Remove function.
28880         (strcasestr): Update.
28881         * modules/c-strcasestr (Files): Add lib/str-kmp.h.
28882         * modules/c-strstr (Files): Likewise.
28883         * modules/mbscasestr (Files): Likewise.
28884         * modules/mbsstr (Files): Likewise.
28885         * modules/strcasestr (Files): Likewise.
28886         Suggested by Paul Eggert.
28887
28888 2007-12-30  Bruno Haible  <bruno@clisp.org>
28889
28890         * lib/xmalloca.c (xmmalloca): Don't define if HAVE_ALLOCA is not
28891         defined.
28892
28893 2007-12-30  Bruno Haible  <bruno@clisp.org>
28894
28895         * lib/xmalloca.h: Include xalloc.h.
28896         (xnmalloca): New macro.
28897
28898 2007-12-30  Bruno Haible  <bruno@clisp.org>
28899
28900         * lib/malloca.h (nmalloca): New macro.
28901         * lib/c-strcasestr.c (knuth_morris_pratt): Use it.
28902         * lib/c-strstr.c (knuth_morris_pratt): Likewise.
28903         * lib/mbscasestr.c (knuth_morris_pratt_unibyte,
28904         knuth_morris_pratt_multibyte): Likewise.
28905         * lib/mbsstr.c (knuth_morris_pratt_unibyte,
28906         knuth_morris_pratt_multibyte): Likewise.
28907         * lib/memmem.c (knuth_morris_pratt): Likewise.
28908         * lib/strcasestr.c (knuth_morris_pratt): Likewise.
28909
28910 2007-12-25  Bruno Haible  <bruno@clisp.org>
28911
28912         Fixup after 2007-10-17 commit. Ensure that 'glob' stays under LGPLv2+.
28913         * lib/glob.c: Don't include openat.h.
28914         (link_exists2_p): Add back the code that deals with the
28915         !GLOB_ALTDIRFUNC case.
28916         (link_exists_p) [!_LIBC && !HAVE_FSTATAT]: Just call link_exists2_p and
28917         let it do the filename concatenation.
28918         * m4/glob.m4 (gl_PREREQ_GLOB): Add check for fstatat.
28919         * modules/glob (Depends-on): Remove openat.
28920
28921 2007-12-31  Bruno Haible  <bruno@clisp.org>
28922
28923         * modules/dirfd (License): Change to LGPLv2+.
28924         Approved by Jim Meyering.
28925
28926 2007-12-29  Paul Eggert  <eggert@cs.ucla.edu>
28927
28928         * lib/memmem.c (knuth_morris_pratt): Check for size_t overflow
28929         when multiplying M by sizeof (size_t).
28930
28931 2007-12-10  Martin Lambers  <marlam@marlam.de>
28932
28933         Override getpagesize on mingw.
28934         * lib/getpagesize.c: New file.
28935         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Enable replacement on mingw.
28936         * modules/getpagesize (Files): Add lib/getpagesize.c.
28937         * lib/unistd.in.h (getpagesize): Declare if we are using a replacement.
28938         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize
28939         REPLACE_GETPAGESIZE.
28940         * modules/unistd (Makefile.am): Substitute REPLACE_GETPAGESIZE.
28941
28942 2007-12-25  Bruno Haible  <bruno@clisp.org>
28943
28944         * modules/localcharset (Notice): New field.
28945         (configure.ac): Define LOCALCHARSET_TESTS_ENVIRONMENT.
28946         Suggested by Ben Pfaff <blp@cs.stanford.edu>.
28947
28948 2007-12-25  Paul Eggert  <eggert@cs.ucla.edu>
28949             Bruno Haible  <bruno@clisp.org>
28950
28951         Avoid using the syntax symbol() in formatted documentation.
28952         * MODULES.html.sh (func_module): When replacing symbol() with a
28953         hyperlink, remove the parentheses. Show an error if some remain.
28954         Recognize and render the '...' syntax.
28955         * doc/alloca-opt.texi: Remove parentheses from symbol reference.
28956         Rework. Add paragraph about GCC's inlining.
28957         * doc/alloca.texi: Likewise.
28958         * doc/error.texi: Remove parentheses from symbol reference.
28959         * doc/gnulib-intro.texi: Likewise.
28960         * doc/gnulib.texi (alloca, alloca-opt): New nodes.
28961         * modules/fnmatch (Description): Reword to say "the ... function".
28962         * modules/full-read (Description): Likewise.
28963         * modules/full-write (Description): Likewise.
28964         * modules/safe-read (Description): Likewise.
28965         * modules/safe-write (Description): Likewise.
28966         * modules/strchrnul (Description): Likewise.
28967         * modules/trim (Description): Likewise.
28968         * modules/error (Description): Remove parentheses from symbol
28969         references.
28970         * modules/verror (Description): Likewise.
28971         Reported by Karl Berry.
28972
28973 2007-12-25  Bruno Haible  <bruno@clisp.org>
28974
28975         Fixup after 2007-10-16 commit.
28976         * lib/glob.c (glob_in_dir): Don't use ISO C99 syntax.
28977
28978 2007-12-24  Bruno Haible  <bruno@clisp.org>
28979
28980         Make --enable-relocatable work with DESTDIR.
28981         * build-aux/install-reloc: Accept another argument 'destdir'. Use it
28982         to compute installdir from destprog.
28983         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): In INSTALL_PROGRAM_ENV,
28984         also set the RELOC_DESTDIR variable.
28985         Reported by Левашев Иван <octagram@bluebottle.com>.
28986
28987 2007-12-24  Bruno Haible  <bruno@clisp.org>
28988
28989         Fix link error due to xalloc_die().
28990         * lib/progreloc.c: When NO_XMALLOC is defined, use areadlink instead
28991         of xreadlink.
28992         * lib/relocwrapper.c: Update comments.
28993         * build-aux/install-reloc: Remove xreadlink.c from file list.
28994         * modules/relocatable-prog-wrapper (Files): Remove xreadlink.h and
28995         xreadlink.c.
28996         Reported by Левашев Иван <octagram@bluebottle.com>.
28997
28998 2007-12-24  Bruno Haible  <bruno@clisp.org>
28999
29000         Split setenv module into setenv and unsetenv. Get rid of setenv.h.
29001         * lib/setenv.h: Remove file.
29002         * lib/stdlib.in.h (setenv, unsetenv): New declarations, moved here from
29003         lib/setenv.h.
29004         * modules/setenv (Files): Remove lib/setenv.h, lib/unsetenv.c.
29005         (Depends-on): Add stdlib.
29006         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR. Don't invoke
29007         gl_FUNC_UNSETENV.
29008         (Include): Replace setenv.h with <stdlib.h>.
29009         * modules/unsetenv: New file.
29010         * lib/setenv.c: Include <stdlib.h> first, after alloca.h.
29011         * lib/unsetenv.c: Include <stdlib.h> first.
29012         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_SETENV_SEPARATE): Require
29013         gl_STDLIB_H_DEFAULTS. Conditionally set HAVE_SETENV to 0.
29014         (gl_FUNC_UNSETENV): Require gl_STDLIB_H_DEFAULTS. Conditionally set
29015         HAVE_UNSETENV to 0. Set VOID_UNSETENV as an AC_SUBSTed variable.
29016         * modules/stdlib (Makefile.am): Substitute also GNULIB_SETENV,
29017         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
29018         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_SETENV,
29019         HAVE_SETENV, GNULIB_UNSETENV, HAVE_UNSETENV, VOID_UNSETENV.
29020         * doc/functions/unsetenv.texi: Update.
29021         * modules/xsetenv (Depends-on): Add unsetenv.
29022         * modules/getdate (Depends-on): Likewise.
29023         * lib/xsetenv.h: Include <stdlib.h> instead of setenv.h.
29024         * lib/xsetenv.c: Don't include setenv.h.
29025         * lib/getdate.y: Likewise.
29026         * lib/relocwrapper.c: Likewise.
29027         * modules/relocatable-prog-wrapper (Files): Remove lib/setenv.h.
29028         (Depends-on): Add stdlib.
29029         * NEWS: Mention the changes.
29030         Reported by Левашев Иван <octagram@bluebottle.com>.
29031
29032 2007-12-23  Bruno Haible  <bruno@clisp.org>
29033
29034         * lib/memmem.c (memmem): Use lowercase variable names. Tab
29035         indentation.
29036
29037 2007-12-23  Bruno Haible  <bruno@clisp.org>
29038
29039         * lib/c-strcasestr.c: Add more comments.
29040         * lib/c-strstr.c: Likewise.
29041         * lib/mbscasestr.c: Likewise.
29042         * lib/mbsstr.c: Likewise.
29043         * lib/strcasestr.c: Likewise.
29044         * lib/memmem.c: Likewise.
29045
29046 2007-12-23  Bruno Haible  <bruno@clisp.org>
29047
29048         * tests/test-memmem.c: Include <string.h> first.
29049
29050 2007-12-22  Bruno Haible  <bruno@clisp.org>
29051
29052         * gnulib-tool (func_create_testdir): Change $auxdir while generating
29053         the contents of $testsbase.
29054         Reported by Ralf Wildenhues.
29055
29056 2007-12-22  Bruno Haible  <bruno@clisp.org>
29057
29058         * gnulib-tool (func_emit_tests_Makefile_am): Replace local_ldadd with
29059         two variables local_ldadd_before, local_ldadd_last.
29060
29061 2007-12-20  Eric Blake  <ebb9@byu.net>
29062
29063         Work around circular library issue when cross-compiling.
29064         * lib/progname.c (set_program_name): Use strncmp, not memcmp, so
29065         that progname.o does not need to pull in rpl_memcmp.
29066
29067 2007-12-19  Eric Blake  <ebb9@byu.net>
29068
29069         Fix memmem to avoid O(n^2) worst-case complexity.
29070         * lib/memmem.c (knuth_morris_pratt): New function.
29071         (memmem): Use it if first few naive iterations fail.
29072         * m4/memmem.m4 (gl_FUNC_MEMMEM): Detect cygwin bug.
29073         * modules/memcmp (License): Set to LGPLv2+, not LGPL.
29074         * modules/memchr (License): Likewise.
29075         * modules/memmem (Depends-on): Add memcmp, memchr, stdbool, and
29076         malloca.
29077         * tests/test-memmem.c: Rewrite, borrowing ideas from
29078         test-mbsstr1.c; the old version wouldn't even compile!
29079         * modules/memmem-tests: New file.
29080         * lib/string.in.h (rpl_memmem): Add declaration.
29081         * modules/string (Makefile.am): Substitute REPLACE_MEMMEM.
29082         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Default for
29083         REPLACE_MEMMEM.
29084
29085 2007-12-18  Paul Eggert  <eggert@cs.ucla.edu>
29086
29087         Fix problem with _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H on VMS.
29088         * lib/stdint.in.h (_GL_JUST_INCLUDE_SYSTEM_INTTYPES_H): Define
29089         before any system include files, and undef after them all.  This
29090         should fix a problem on VMS reported by John E. Malmberg in
29091         <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00118.html>.
29092
29093 2007-12-17  Eric Blake  <ebb9@byu.net>
29094
29095         Revert addition of verify, for BSD/OS.
29096         * lib/fseeko.c [!HAVE_FSEEKO]: Allow off_t > long, even though it
29097         can't handle large files, for the sake of obsolete platforms.
29098         * modules/fseeko (Depends-on): Remove verify.
29099         * doc/functions/fseeko.texi (fseeko): Document BSD/OS limitation.
29100         * doc/functions/ftello.texi (ftello): Likewise.
29101         * doc/functions/fgetpos.texi (fgetpos): Likewise.
29102         Reported by Larry Jones.
29103
29104 2007-12-17  Petr Salinger  <Petr.Salinger@seznam.cz>
29105
29106         getcwd.c: Use a more readable witness: HAVE_OPENAT_SUPPORT
29107         * lib/getcwd.c: Define and use HAVE_OPENAT_SUPPORT, in place of AT_FDCWD.
29108
29109 2007-12-17  Jim Meyering  <meyering@redhat.com>
29110
29111         Port to GNU/kFreeBSD - FreeBSD kernel + GNU libc,
29112         which has no openat syscall, yet <fcntl.h> does define AT_FDCWD.
29113         * lib/getcwd.c: Undef AT_FDCWD if there is no openat function.
29114         * modules/getcwd (Depends-on): Add openat.
29115         Reported by Petr Salinger.
29116
29117 2007-12-17  Bruno Haible  <bruno@clisp.org>
29118
29119         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Use GL_NOCRASH to
29120         avoid a segmentation fault of the configure test on x86_64 systems.
29121
29122 2007-12-15  Jim Meyering  <meyering@redhat.com>
29123
29124         * build-aux/gnupload (GPG): Don't hard-code absolute name of gpg binary.
29125
29126 2007-12-13  Eric Blake  <ebb9@byu.net>
29127
29128         Another fseek test.
29129         * tests/test-fseek.c (main): Also test ungetc handling.
29130         * tests/test-fseeko.c (main): Likewise.
29131         * modules/fseeko (Depends-on): Add verify.
29132         * lib/fseeko.c [!HAVE_FSEEKO]: Verify that off_t is not too
29133         large.
29134         Reported by Larry Jones.
29135
29136         Fix fseeko on mingw.
29137         * lib/fseeko.c (rpl_fseeko) [_IOERR]: Reset EOF flag on successful
29138         seek.
29139
29140         Beef up fseek tests.
29141         * tests/test-fseek.c (main): Also test eof handling.
29142         * tests/test-fseeko.c (main): Likewise.
29143         Reported by Larry Jones.
29144
29145 2007-12-13  Larry Jones  <lawrence.jones@siemens.com>  (tiny change)
29146
29147         Fix fseeko on BSD-based platforms.
29148         * lib/fseeko.c (rpl_fseeko) [__sferror]: Reset EOF flag on
29149         successful seek.
29150
29151 2007-12-12  Eric Blake  <ebb9@byu.net>
29152
29153         Allow circular dependency of separate libtests.a
29154         * gnulib-tool (func_emit_tests_Makefile_am): Add AM_LIBTOOLFLAGS
29155         when use_libtests.
29156
29157 2007-12-11  Eric Blake  <ebb9@byu.net>
29158
29159         Fix bug with -0.0L in previous patch.
29160         * lib/isnan.c (rpl_isnanl): Make robust to -0.0L and pad bits.
29161         * tests/test-isnan.c (main): Also test on zeroes.
29162         * tests/test-isnanf.c (main): Likewise.
29163         * tests/test-isnanl.h (main): Likewise.
29164
29165         Detect pseudo-denormals on x86 even when cross-compiling.
29166         * lib/isnan.c (rpl_isnanl) [!KNOWN_EXPBIT0_LOCATION
29167         && USE_LONG_DOUBLE && x86]: Add one more check to filter out
29168         invalid bit patterns that happen to satisfy ==.
29169
29170         Avoid link failures with separate libtests.a.
29171         * gnulib-tool (func_emit_tests_Makefile_am): Also list local_ldadd
29172         last, to satisfy circular dependencies.
29173
29174 2007-12-11  Eric Blake  <ebb9@byu.net>
29175         and Bruno Haible  <bruno@clisp.org>
29176
29177         Fix OpenBSD 4.0 <float.h> handling of long double.
29178         * m4/float_h.m4 (gl_FLOAT_H): Also claim OpenBSD is broken.
29179         * lib/float.in.h [__OpenBSD__]: Add fixes for OpenBSD.
29180         * doc/headers/float.texi (float.h): Document OpenBSD bug.
29181
29182 2007-12-11  Jim Meyering  <meyering@redhat.com>
29183
29184         * users.txt: Add libvirt.
29185
29186         Support versions of autoconf prior to 2.59c.
29187         * gnulib-tool (func_emit_initmacro_done): Define m4_foreach_w
29188         if it is not already defined.
29189
29190 2007-12-09  Bruno Haible  <bruno@clisp.org>
29191
29192         Let 'gnulib-tool --import' collect sources needed for the tests in
29193         tests/ rather than in lib/.
29194         * gnulib-tool (func_emit_tests_Makefile_am): Accept use_libtests
29195         argument. If true, add rules to generate libtests.a, and put libtests.a
29196         into $(LDADD). Consider source files in subdirectories and set
29197         uses_subdirs.
29198         (func_emit_initmacro_start, func_emit_initmacro_end,
29199         func_emit_initmacro_done): Pass all arguments explicitly.
29200         (func_import): Determine two module lists main_modules,
29201         testsrelated_modules. Determine use_libtests. Determine two variables
29202         sed_transform_main_lib_file, sed_transform_testsrelated_lib_file
29203         instead of just sed_transform_lib_file. Determine two variables
29204         main_files and testsrelated_files. Compute 'files' as the union of
29205         both. Adjust sed_rewrite_old_files, sed_rewrite_new_files,
29206         func_add_or_update. In the generated gnulib-comp.m4, collect the
29207         object files for tests/ in different variables than those for lib/.
29208         Substitute LIBTESTS_LIBDEPS.
29209         (func_create_testdir): Combine the uses_subdirs results from
29210         func_emit_lib_Makefile_am and from func_emit_tests_Makefile_am.
29211
29212 2007-12-09  Bruno Haible  <bruno@clisp.org>
29213
29214         * gnulib-tool (func_emit_tests_Makefile_am): Expand references to
29215         the build-aux directory.
29216
29217 2007-12-09  Bruno Haible  <bruno@clisp.org>
29218
29219         * gnulib-tool (func_emit_tests_Makefile_am): Remove redundant code
29220         introduced on 2006-09-09.
29221
29222 2007-12-07  Jim Meyering  <meyering@redhat.com>
29223
29224         Let these macros work also with autoconf-2.59.
29225         * m4/getline.m4 (gl_FUNC_GETLINE): Require only autoconf-2.59.  2.60
29226         is not needed, since gnulib now permits use of AC_CHECK_DECLS_ONCE.
29227         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
29228
29229 2007-12-06  Jim Meyering  <meyering@redhat.com>
29230
29231         Avoid a configure-time syntax error in gl_FUNC_ACL.
29232         * m4/acl.m4 (gl_FUNC_ACL): Be careful to check for the acl_trivial
29233         function in each branch, before testing the cache variable.
29234
29235 2007-12-04  Eric Blake  <ebb9@byu.net>
29236
29237         Make scripts executable.
29238         * build-aux/config.guess: Add execute permissions.
29239         * build-aux/config.sub: Likewise.
29240         * build-aux/gendocs.sh: Likewise.
29241
29242         Fix frexp on mingw.
29243         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Detect mingw bug when
29244         cross-compiling.
29245         * doc/functions/frexp.texi (frexp): Document the bug.
29246
29247         Make cygwin fseeko check more reliable.
29248         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Use cygwin
29249         version numbers, rather than unrelated feature check.
29250         * doc/functions/fseeko.texi (fseeko): Tweak failure report.
29251         * doc/functions/ftello.texi (ftello): Likewise.
29252         Reported by Bruno Haible.
29253
29254         * m4/strerror.m4: Bump version number.
29255
29256 2007-12-03  Bruno Haible  <bruno@clisp.org>
29257
29258         * doc/functions/mprotect.texi: Mention the mingw problem.
29259
29260 2007-12-03  Eric Blake  <ebb9@byu.net>
29261
29262         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): Ensure
29263         REPLACE_STRERROR is initialized before this macro.
29264
29265 2007-12-03  Paul Eggert  <eggert@cs.ucla.edu>
29266
29267         Add support for Solaris 10 ACLs.  Also, ACLs are Gnulib, not Autoconf.
29268         * modules/acl (configure.ac): Rename AC_FUNC_ACL to gl_FUNC_ACL.
29269         * m4/acl.m4 (gl_FUNC_ACL): Renamed from AC_FUNC_ACL.  On Solaris,
29270         put -lsec in even for programs other than 'ls'.  This fixes a problem
29271         for gettext reported by Bruno Haible in
29272         <http://lists.gnu.org/archive/html/bug-gnulib/2007-12/msg00007.html>.
29273         * lib/acl.c (copy_acl, qset_acl) [USE_ACL && defined ACL_NO_TRIVIAL]:
29274         Add support for Solaris 10.  This isn't efficient, but should get the
29275         job done for now.
29276
29277 2007-12-03  James Youngman  <jay@gnu.org>
29278
29279         * doc/regexprops-generic.texi: change "an close-group" to "a
29280         close-group" and "illegal" to "not allowed".
29281
29282 2007-11-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29283
29284         * lib/unictype/pr_byname.c: Include unictype/pr_byname.h instead of
29285         pr_byname.h. Needed for the rare case when the maintainer has done
29286         "make maintainer-clean" in the source directory and then attempts a
29287         build outside the source directory.
29288         * lib/unictype/scripts.c: Include unictype/scripts_byname.h instead of
29289         scripts_byname.h.
29290
29291 2007-12-02  Martin Lambers <marlam@marlam.de>
29292             Bruno Haible  <bruno@clisp.org>
29293
29294         * lib/getpagesize.h: Remove file.
29295         * lib/unistd.in.h: Include declaration of getpagesize here.
29296         * m4/getpagesize.m4 (gl_FUNC_GETPAGESIZE): Renamed from gl_GETPAGESIZE.
29297         Invoke gl_UNISTD_H_DEFAULTS. Set HAVE_GETPAGESIZE, HAVE_OS_H,
29298         HAVE_SYS_PARAM_H.
29299         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_GETPAGESIZE,
29300         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
29301         * modules/getpagesize (Files): Remove lib/getpagesize.h.
29302         (Depends-on): Add unistd.
29303         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
29304         (Include): Use <unistd.h> instead of getpagesize.h.
29305         * modules/unistd (Makefile.am): Substitute also GNULIB_GETPAGESIZE,
29306         HAVE_GETPAGESIZE, HAVE_OS_H, HAVE_SYS_PARAM_H.
29307         * m4/pagealign_alloc.m4 (gl_PREREQ_PAGEALIGN_ALLOC): Remove
29308         gl_GETPAGESIZE invocation, already handled by module dependency.
29309         * lib/pagealign_alloc.c: Don't include getpagesize.h.
29310
29311 2007-12-02  Bruno Haible  <bruno@clisp.org>
29312
29313         * modules/strings-tests: New file.
29314         * tests/test-strings.c: New file.
29315
29316         Move declarations of str{,n}casecmp from <string.h> to <strings.h>.
29317         * lib/strings.in.h: New file.
29318         * lib/string.in.h (strcasecmp, strncasecmp): Remove declarations.
29319         * m4/strings_h.m4: New file.
29320         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Remove initialization
29321         of HAVE_STRCASECMP, HAVE_DECL_STRNCASECMP.
29322         * modules/strings: New file.
29323         * modules/string (Makefile.am): Update.
29324         * modules/strcase (Include): Mention <strings.h>, not <string.h>.
29325         Reported by Karl Berry.
29326
29327 2007-12-01  Eric Blake  <ebb9@byu.net>
29328
29329         * m4/stdio_h.m4 (gl_STDIN_LARGE_OFFSET) [__CYGWIN__]: Rewrite to
29330         accomodate fix in cygwin 1.5.25.
29331
29332 2007-12-01  Jim Meyering  <meyering@redhat.com>
29333
29334         Fix a bug that inhibited much of the utf8-optimization in regcomp.c.
29335         * lib/regcomp.c (optimize_utf8): Fix a typo, s/idx/ctx_type/,
29336         that would inhibit utf8-optimization of a regexp containing line-
29337         or buffer-anchors, e.g., `^', `$'.
29338
29339 2007-11-30  Bruno Haible  <bruno@clisp.org>
29340
29341         * lib/lock.h (gl_recursive_lock_init) [PTHREAD &&
29342         PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: Call
29343         glthread_recursive_lock_init.
29344         * lib/lock.c (glthread_recursive_lock_init)
29345         [PTHREAD_RECURSIVE_MUTEX_INITIALIZER]: New function.
29346         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
29347
29348 2007-11-28  Paul Eggert  <eggert@cs.ucla.edu>
29349
29350         New function qset_acl, like set_acl but with syscall semantics.
29351         * lib/acl.h (qset_acl): New decl.
29352         * lib/acl.c (qset_acl): New function.
29353         (set_acl): Use new function.  Use more-consistent diagnostics.
29354
29355 2007-11-28  Jim Meyering  <meyering@redhat.com>
29356
29357         * modules/physmem (License): Change from GPL to LGPLv2+.
29358
29359 2007-11-26  Bruno Haible  <bruno@clisp.org>
29360
29361         * lib/vasnprintf.c (decode_long_double): Don't abort if the
29362         'long double' type has excess precision.
29363         Reported by Jim Meyering in
29364         <http://lists.gnu.org/archive/html/bug-gnulib/2007-11/msg00120.html>.
29365
29366 2007-11-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
29367
29368         * doc/fdl.texi, doc/gpl-3.0.texi, doc/lgpl-3.0.texi:
29369         Sync from <http://gnu.org/licenses>.
29370         * modules/agpl-3.0, doc/agpl-3.0.texi: New module,
29371         with license text from same location.
29372         * doc/maintain.texi, doc/standards.texi:  Sync from
29373         <http://savannah.gnu.org/projects/gnustandards>.
29374
29375 2007-11-22  Ondřej Vašík  <ovasik@redhat.com>
29376         and Jim Meyering  <meyering@redhat.com>
29377
29378         Adjust getdate' grammar to accept a slightly more regular language.
29379         E.g., accept "YYYYMMDD +N days" as well as "YYYYMMDD N days".
29380         Before, the former was rejected.
29381         * lib/getdate.y (digits_to_date_time): New function, factored
29382         out of ...
29383         (number): ...here.  Just call digits_to_date_time.
29384         (hybrid): New non-terminal to handle an <unsigned number,
29385         signed relative offset> sequence consistently.
29386
29387 2007-11-18  Jim Meyering  <meyering@redhat.com>
29388
29389         Pull my changes from coreutils:
29390         bootstrap: fix typo to enable use of $gnulib_tool_option_extras.
29391         * build-aux/bootstrap (gnulib_tool_options): Add a space before the
29392         use of $gnulib_tool_option_extras, so that it's separated from the
29393         preceding argument.
29394
29395         Fix bootstrap failure to handle files like lib/uniwidth/cjk.h.
29396         * build-aux/bootstrap (cp_mark_as_generated): Create any required
29397         parent destination directories before copying a file into place.
29398
29399 2007-11-18  Sergey Poznyakoff  <gray@gnu.org.ua>
29400
29401         bootstrap: work also with 4-argument variant of AC_INIT
29402         * build-aux/bootstrap (gnulib_extra_files): Adjust sed command.
29403
29404 2007-11-16  Paul Eggert  <eggert@cs.ucla.edu>
29405
29406         Port test-getaddrinfo to Solaris.
29407         Problem reported by Bruno Haible in
29408         <http://lists.gnu.org/archive/html/bug-gnulib/2007-03/msg00171.html>.
29409         * tests/test-getaddrinfo.c (simple): Add a comment asking for an
29410         explanation of setting 'hints'.
29411         Don't reject an implementation merely because it returns EAI_SERVICE.
29412         (EAI_SERVICE): Define to 0 if not defined.
29413
29414 2007-11-15  Paul Eggert  <eggert@cs.ucla.edu>
29415
29416         The license of gnu-make and posix-shell is now "GPLed build tool".
29417         * modules/gnu-make (License): Likewise.
29418         * modules/posix-shell (License): Likewise.
29419
29420         New module posix-shell, for determining a POSIX shell
29421         or perhaps something that is close enough to a POSIX shell.
29422         * m4/posix-shell.m4: New file.
29423         * modules/posix-shell: New file.
29424
29425         * MODULES.html.sh: Mention new module.
29426
29427         New module gnu-make, for determining whether we're using GNU Make.
29428         * m4/gnu-make.m4: New file.
29429         * modules/gnu-make: New file.
29430         * MODULES.html.sh: Mention new module.
29431
29432 2007-11-14  Jim Meyering  <meyering@redhat.com>
29433
29434         Define a sometimes-link-required function using ARGMATCH_DIE_DECL.
29435         * tests/test-argmatch.c (ARGMATCH_DIE_DECL): When defined,
29436         use this macro to create a function _definition_.
29437         Remove useless "#undef ARGMATCH_DIE".
29438
29439 2007-11-14  Bruno Haible  <bruno@clisp.org>
29440
29441         * lib/config.charset: Update for OpenBSD 4.1.
29442         Reported and helped by Ben Pfaff <blp@cs.stanford.edu>.
29443
29444 2007-11-12  Paul Eggert  <eggert@cs.ucla.edu>
29445
29446         Document 64-bit #if problems in stdint.texi.
29447         * doc/headers/stdint.texi (stdint.h): Mention problems with
29448         64-bit-#if, and how to work around them.
29449
29450         Don't insist on 'long long int' support in the preprocessor.  It
29451         breaks too many things.  For example, PRIdMAX still uses a 'long
29452         long int' format with the latest Sun compiler, even though
29453         HAVE_LONG_LONG_INT isn't defined due to that compiler's
29454         preprocessor problem.  This causes the latest coreutils to dump
29455         core on Solaris 10 sparc with the Sun C compiler.
29456         Instead, fix the 2007-10-16 problem in a different way, by evaluating
29457         the troublesome expressions at configure-time, not at #if-time.
29458         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): Don't test the
29459         preprocessor.
29460         * m4/inttypes.m4 (gl_INTTYPES_H): Move the #if checks into
29461         compile-time C checks, done at 'configure'-time.
29462         (gl_INTTYPES_CHECK_LONG_LONG_INT_CONDITION): New macro.
29463         * modules/inttypes (Makefile): Substitute the new symbols that
29464         gl_INTTYPES_H now generates.
29465         * lib/inttypes.in.h: Don't use constants wider than 'long' in #if.
29466
29467 2007-11-12  Bruno Haible  <bruno@clisp.org>
29468
29469         Tests for Unicode character classification functions.
29470
29471         * modules/unictype/bidicategory-byname-tests: New file.
29472         * modules/unictype/bidicategory-name-tests: New file.
29473         * modules/unictype/bidicategory-of-tests: New file.
29474         * modules/unictype/bidicategory-test-tests: New file.
29475         * modules/unictype/block-list-tests: New file.
29476         * modules/unictype/block-of-tests: New file.
29477         * modules/unictype/block-test-tests: New file.
29478         * modules/unictype/category-C-tests: New file.
29479         * modules/unictype/category-Cc-tests: New file.
29480         * modules/unictype/category-Cf-tests: New file.
29481         * modules/unictype/category-Cn-tests: New file.
29482         * modules/unictype/category-Co-tests: New file.
29483         * modules/unictype/category-Cs-tests: New file.
29484         * modules/unictype/category-L-tests: New file.
29485         * modules/unictype/category-Ll-tests: New file.
29486         * modules/unictype/category-Lm-tests: New file.
29487         * modules/unictype/category-Lo-tests: New file.
29488         * modules/unictype/category-Lt-tests: New file.
29489         * modules/unictype/category-Lu-tests: New file.
29490         * modules/unictype/category-M-tests: New file.
29491         * modules/unictype/category-Mc-tests: New file.
29492         * modules/unictype/category-Me-tests: New file.
29493         * modules/unictype/category-Mn-tests: New file.
29494         * modules/unictype/category-N-tests: New file.
29495         * modules/unictype/category-Nd-tests: New file.
29496         * modules/unictype/category-Nl-tests: New file.
29497         * modules/unictype/category-No-tests: New file.
29498         * modules/unictype/category-P-tests: New file.
29499         * modules/unictype/category-Pc-tests: New file.
29500         * modules/unictype/category-Pd-tests: New file.
29501         * modules/unictype/category-Pe-tests: New file.
29502         * modules/unictype/category-Pf-tests: New file.
29503         * modules/unictype/category-Pi-tests: New file.
29504         * modules/unictype/category-Po-tests: New file.
29505         * modules/unictype/category-Ps-tests: New file.
29506         * modules/unictype/category-S-tests: New file.
29507         * modules/unictype/category-Sc-tests: New file.
29508         * modules/unictype/category-Sk-tests: New file.
29509         * modules/unictype/category-Sm-tests: New file.
29510         * modules/unictype/category-So-tests: New file.
29511         * modules/unictype/category-Z-tests: New file.
29512         * modules/unictype/category-Zl-tests: New file.
29513         * modules/unictype/category-Zp-tests: New file.
29514         * modules/unictype/category-Zs-tests: New file.
29515         * modules/unictype/category-and-not-tests: New file.
29516         * modules/unictype/category-and-tests: New file.
29517         * modules/unictype/category-byname-tests: New file.
29518         * modules/unictype/category-name-tests: New file.
29519         * modules/unictype/category-none-tests: New file.
29520         * modules/unictype/category-of-tests: New file.
29521         * modules/unictype/category-or-tests: New file.
29522         * modules/unictype/category-test-withtable-tests: New file.
29523         * modules/unictype/combining-class-tests: New file.
29524         * modules/unictype/ctype-alnum-tests: New file.
29525         * modules/unictype/ctype-alpha-tests: New file.
29526         * modules/unictype/ctype-blank-tests: New file.
29527         * modules/unictype/ctype-cntrl-tests: New file.
29528         * modules/unictype/ctype-digit-tests: New file.
29529         * modules/unictype/ctype-graph-tests: New file.
29530         * modules/unictype/ctype-lower-tests: New file.
29531         * modules/unictype/ctype-print-tests: New file.
29532         * modules/unictype/ctype-punct-tests: New file.
29533         * modules/unictype/ctype-space-tests: New file.
29534         * modules/unictype/ctype-upper-tests: New file.
29535         * modules/unictype/ctype-xdigit-tests: New file.
29536         * modules/unictype/decimal-digit-tests: New file.
29537         * modules/unictype/digit-tests: New file.
29538         * modules/unictype/mirror-tests: New file.
29539         * modules/unictype/numeric-tests: New file.
29540         * modules/unictype/property-alphabetic-tests: New file.
29541         * modules/unictype/property-ascii-hex-digit-tests: New file.
29542         * modules/unictype/property-bidi-arabic-digit-tests: New file.
29543         * modules/unictype/property-bidi-arabic-right-to-left-tests: New file.
29544         * modules/unictype/property-bidi-block-separator-tests: New file.
29545         * modules/unictype/property-bidi-boundary-neutral-tests: New file.
29546         * modules/unictype/property-bidi-common-separator-tests: New file.
29547         * modules/unictype/property-bidi-control-tests: New file.
29548         * modules/unictype/property-bidi-embedding-or-override-tests: New file.
29549         * modules/unictype/property-bidi-eur-num-separator-tests: New file.
29550         * modules/unictype/property-bidi-eur-num-terminator-tests: New file.
29551         * modules/unictype/property-bidi-european-digit-tests: New file.
29552         * modules/unictype/property-bidi-hebrew-right-to-left-tests: New file.
29553         * modules/unictype/property-bidi-left-to-right-tests: New file.
29554         * modules/unictype/property-bidi-non-spacing-mark-tests: New file.
29555         * modules/unictype/property-bidi-other-neutral-tests: New file.
29556         * modules/unictype/property-bidi-pdf-tests: New file.
29557         * modules/unictype/property-bidi-segment-separator-tests: New file.
29558         * modules/unictype/property-bidi-whitespace-tests: New file.
29559         * modules/unictype/property-byname-tests: New file.
29560         * modules/unictype/property-combining-tests: New file.
29561         * modules/unictype/property-composite-tests: New file.
29562         * modules/unictype/property-currency-symbol-tests: New file.
29563         * modules/unictype/property-dash-tests: New file.
29564         * modules/unictype/property-decimal-digit-tests: New file.
29565         * modules/unictype/property-default-ignorable-code-point-tests: New file.
29566         * modules/unictype/property-deprecated-tests: New file.
29567         * modules/unictype/property-diacritic-tests: New file.
29568         * modules/unictype/property-extender-tests: New file.
29569         * modules/unictype/property-format-control-tests: New file.
29570         * modules/unictype/property-grapheme-base-tests: New file.
29571         * modules/unictype/property-grapheme-extend-tests: New file.
29572         * modules/unictype/property-grapheme-link-tests: New file.
29573         * modules/unictype/property-hex-digit-tests: New file.
29574         * modules/unictype/property-hyphen-tests: New file.
29575         * modules/unictype/property-id-continue-tests: New file.
29576         * modules/unictype/property-id-start-tests: New file.
29577         * modules/unictype/property-ideographic-tests: New file.
29578         * modules/unictype/property-ids-binary-operator-tests: New file.
29579         * modules/unictype/property-ids-trinary-operator-tests: New file.
29580         * modules/unictype/property-ignorable-control-tests: New file.
29581         * modules/unictype/property-iso-control-tests: New file.
29582         * modules/unictype/property-join-control-tests: New file.
29583         * modules/unictype/property-left-of-pair-tests: New file.
29584         * modules/unictype/property-line-separator-tests: New file.
29585         * modules/unictype/property-logical-order-exception-tests: New file.
29586         * modules/unictype/property-lowercase-tests: New file.
29587         * modules/unictype/property-math-tests: New file.
29588         * modules/unictype/property-non-break-tests: New file.
29589         * modules/unictype/property-not-a-character-tests: New file.
29590         * modules/unictype/property-numeric-tests: New file.
29591         * modules/unictype/property-other-alphabetic-tests: New file.
29592         * modules/unictype/property-other-default-ignorable-code-point-tests: New file.
29593         * modules/unictype/property-other-grapheme-extend-tests: New file.
29594         * modules/unictype/property-other-id-continue-tests: New file.
29595         * modules/unictype/property-other-id-start-tests: New file.
29596         * modules/unictype/property-other-lowercase-tests: New file.
29597         * modules/unictype/property-other-math-tests: New file.
29598         * modules/unictype/property-other-uppercase-tests: New file.
29599         * modules/unictype/property-paired-punctuation-tests: New file.
29600         * modules/unictype/property-paragraph-separator-tests: New file.
29601         * modules/unictype/property-pattern-syntax-tests: New file.
29602         * modules/unictype/property-pattern-white-space-tests: New file.
29603         * modules/unictype/property-private-use-tests: New file.
29604         * modules/unictype/property-punctuation-tests: New file.
29605         * modules/unictype/property-quotation-mark-tests: New file.
29606         * modules/unictype/property-radical-tests: New file.
29607         * modules/unictype/property-sentence-terminal-tests: New file.
29608         * modules/unictype/property-soft-dotted-tests: New file.
29609         * modules/unictype/property-space-tests: New file.
29610         * modules/unictype/property-terminal-punctuation-tests: New file.
29611         * modules/unictype/property-test-tests: New file.
29612         * modules/unictype/property-titlecase-tests: New file.
29613         * modules/unictype/property-unassigned-code-value-tests: New file.
29614         * modules/unictype/property-unified-ideograph-tests: New file.
29615         * modules/unictype/property-uppercase-tests: New file.
29616         * modules/unictype/property-variation-selector-tests: New file.
29617         * modules/unictype/property-white-space-tests: New file.
29618         * modules/unictype/property-xid-continue-tests: New file.
29619         * modules/unictype/property-xid-start-tests: New file.
29620         * modules/unictype/property-zero-width-tests: New file.
29621         * modules/unictype/scripts-tests: New file.
29622         * modules/unictype/syntax-c-ident-tests: New file.
29623         * modules/unictype/syntax-c-whitespace-tests: New file.
29624         * modules/unictype/syntax-java-ident-tests: New file.
29625         * modules/unictype/syntax-java-whitespace-tests: New file.
29626         * tests/unictype/test-bidi_byname.c: New file.
29627         * tests/unictype/test-bidi_name.c: New file.
29628         * tests/unictype/test-bidi_of.c: New file.
29629         * tests/unictype/test-bidi_test.c: New file.
29630         * tests/unictype/test-block_list.c: New file.
29631         * tests/unictype/test-block_of.c: New file.
29632         * tests/unictype/test-block_test.c: New file.
29633         * tests/unictype/test-categ_and.c: New file.
29634         * tests/unictype/test-categ_and_not.c: New file.
29635         * tests/unictype/test-categ_byname.c: New file.
29636         * tests/unictype/test-categ_name.c: New file.
29637         * tests/unictype/test-categ_none.c: New file.
29638         * tests/unictype/test-categ_of.c: New file.
29639         * tests/unictype/test-categ_or.c: New file.
29640         * tests/unictype/test-categ_test_withtable.c: New file.
29641         * tests/unictype/test-combining.c: New file.
29642         * tests/unictype/test-decdigit.c: New file.
29643         * tests/unictype/test-digit.c: New file.
29644         * tests/unictype/test-mirror.c: New file.
29645         * tests/unictype/test-numeric.c: New file.
29646         * tests/unictype/test-pr_byname.c: New file.
29647         * tests/unictype/test-pr_test.c: New file.
29648         * tests/unictype/test-predicate-part1.h: New file.
29649         * tests/unictype/test-predicate-part2.h: New file.
29650         * tests/unictype/test-scripts.c: New file.
29651         * tests/unictype/test-sy_c_ident.c: New file.
29652         * tests/unictype/test-sy_java_ident.c: New file.
29653
29654         * tests/unictype/test-categ_C.c: New file, generated by gen-ctype.c
29655         for Unicode 5.0.0.
29656         * tests/unictype/test-categ_Cc.c: Likewise.
29657         * tests/unictype/test-categ_Cf.c: Likewise.
29658         * tests/unictype/test-categ_Cn.c: Likewise.
29659         * tests/unictype/test-categ_Co.c: Likewise.
29660         * tests/unictype/test-categ_Cs.c: Likewise.
29661         * tests/unictype/test-categ_L.c: Likewise.
29662         * tests/unictype/test-categ_Ll.c: Likewise.
29663         * tests/unictype/test-categ_Lm.c: Likewise.
29664         * tests/unictype/test-categ_Lo.c: Likewise.
29665         * tests/unictype/test-categ_Lt.c: Likewise.
29666         * tests/unictype/test-categ_Lu.c: Likewise.
29667         * tests/unictype/test-categ_M.c: Likewise.
29668         * tests/unictype/test-categ_Mc.c: Likewise.
29669         * tests/unictype/test-categ_Me.c: Likewise.
29670         * tests/unictype/test-categ_Mn.c: Likewise.
29671         * tests/unictype/test-categ_N.c: Likewise.
29672         * tests/unictype/test-categ_Nd.c: Likewise.
29673         * tests/unictype/test-categ_Nl.c: Likewise.
29674         * tests/unictype/test-categ_No.c: Likewise.
29675         * tests/unictype/test-categ_P.c: Likewise.
29676         * tests/unictype/test-categ_Pc.c: Likewise.
29677         * tests/unictype/test-categ_Pd.c: Likewise.
29678         * tests/unictype/test-categ_Pe.c: Likewise.
29679         * tests/unictype/test-categ_Pf.c: Likewise.
29680         * tests/unictype/test-categ_Pi.c: Likewise.
29681         * tests/unictype/test-categ_Po.c: Likewise.
29682         * tests/unictype/test-categ_Ps.c: Likewise.
29683         * tests/unictype/test-categ_S.c: Likewise.
29684         * tests/unictype/test-categ_Sc.c: Likewise.
29685         * tests/unictype/test-categ_Sk.c: Likewise.
29686         * tests/unictype/test-categ_Sm.c: Likewise.
29687         * tests/unictype/test-categ_So.c: Likewise.
29688         * tests/unictype/test-categ_Z.c: Likewise.
29689         * tests/unictype/test-categ_Zl.c: Likewise.
29690         * tests/unictype/test-categ_Zp.c: Likewise.
29691         * tests/unictype/test-categ_Zs.c: Likewise.
29692         * tests/unictype/test-ctype_alnum.c: Likewise.
29693         * tests/unictype/test-ctype_alpha.c: Likewise.
29694         * tests/unictype/test-ctype_blank.c: Likewise.
29695         * tests/unictype/test-ctype_cntrl.c: Likewise.
29696         * tests/unictype/test-ctype_digit.c: Likewise.
29697         * tests/unictype/test-ctype_graph.c: Likewise.
29698         * tests/unictype/test-ctype_lower.c: Likewise.
29699         * tests/unictype/test-ctype_print.c: Likewise.
29700         * tests/unictype/test-ctype_punct.c: Likewise.
29701         * tests/unictype/test-ctype_space.c: Likewise.
29702         * tests/unictype/test-ctype_upper.c: Likewise.
29703         * tests/unictype/test-ctype_xdigit.c: Likewise.
29704         * tests/unictype/test-decdigit.h: Likewise.
29705         * tests/unictype/test-digit.h: Likewise.
29706         * tests/unictype/test-numeric.h: Likewise.
29707         * tests/unictype/test-pr_alphabetic.c: Likewise.
29708         * tests/unictype/test-pr_ascii_hex_digit.c: Likewise.
29709         * tests/unictype/test-pr_bidi_arabic_digit.c: Likewise.
29710         * tests/unictype/test-pr_bidi_arabic_right_to_left.c: Likewise.
29711         * tests/unictype/test-pr_bidi_block_separator.c: Likewise.
29712         * tests/unictype/test-pr_bidi_boundary_neutral.c: Likewise.
29713         * tests/unictype/test-pr_bidi_common_separator.c: Likewise.
29714         * tests/unictype/test-pr_bidi_control.c: Likewise.
29715         * tests/unictype/test-pr_bidi_embedding_or_override.c: Likewise.
29716         * tests/unictype/test-pr_bidi_eur_num_separator.c: Likewise.
29717         * tests/unictype/test-pr_bidi_eur_num_terminator.c: Likewise.
29718         * tests/unictype/test-pr_bidi_european_digit.c: Likewise.
29719         * tests/unictype/test-pr_bidi_hebrew_right_to_left.c: Likewise.
29720         * tests/unictype/test-pr_bidi_left_to_right.c: Likewise.
29721         * tests/unictype/test-pr_bidi_non_spacing_mark.c: Likewise.
29722         * tests/unictype/test-pr_bidi_other_neutral.c: Likewise.
29723         * tests/unictype/test-pr_bidi_pdf.c: Likewise.
29724         * tests/unictype/test-pr_bidi_segment_separator.c: Likewise.
29725         * tests/unictype/test-pr_bidi_whitespace.c: Likewise.
29726         * tests/unictype/test-pr_combining.c: Likewise.
29727         * tests/unictype/test-pr_composite.c: Likewise.
29728         * tests/unictype/test-pr_currency_symbol.c: Likewise.
29729         * tests/unictype/test-pr_dash.c: Likewise.
29730         * tests/unictype/test-pr_decimal_digit.c: Likewise.
29731         * tests/unictype/test-pr_default_ignorable_code_point.c: Likewise.
29732         * tests/unictype/test-pr_deprecated.c: Likewise.
29733         * tests/unictype/test-pr_diacritic.c: Likewise.
29734         * tests/unictype/test-pr_extender.c: Likewise.
29735         * tests/unictype/test-pr_format_control.c: Likewise.
29736         * tests/unictype/test-pr_grapheme_base.c: Likewise.
29737         * tests/unictype/test-pr_grapheme_extend.c: Likewise.
29738         * tests/unictype/test-pr_grapheme_link.c: Likewise.
29739         * tests/unictype/test-pr_hex_digit.c: Likewise.
29740         * tests/unictype/test-pr_hyphen.c: Likewise.
29741         * tests/unictype/test-pr_id_continue.c: Likewise.
29742         * tests/unictype/test-pr_id_start.c: Likewise.
29743         * tests/unictype/test-pr_ideographic.c: Likewise.
29744         * tests/unictype/test-pr_ids_binary_operator.c: Likewise.
29745         * tests/unictype/test-pr_ids_trinary_operator.c: Likewise.
29746         * tests/unictype/test-pr_ignorable_control.c: Likewise.
29747         * tests/unictype/test-pr_iso_control.c: Likewise.
29748         * tests/unictype/test-pr_join_control.c: Likewise.
29749         * tests/unictype/test-pr_left_of_pair.c: Likewise.
29750         * tests/unictype/test-pr_line_separator.c: Likewise.
29751         * tests/unictype/test-pr_logical_order_exception.c: Likewise.
29752         * tests/unictype/test-pr_lowercase.c: Likewise.
29753         * tests/unictype/test-pr_math.c: Likewise.
29754         * tests/unictype/test-pr_non_break.c: Likewise.
29755         * tests/unictype/test-pr_not_a_character.c: Likewise.
29756         * tests/unictype/test-pr_numeric.c: Likewise.
29757         * tests/unictype/test-pr_other_alphabetic.c: Likewise.
29758         * tests/unictype/test-pr_other_default_ignorable_code_point.c: Likewise.
29759         * tests/unictype/test-pr_other_grapheme_extend.c: Likewise.
29760         * tests/unictype/test-pr_other_id_continue.c: Likewise.
29761         * tests/unictype/test-pr_other_id_start.c: Likewise.
29762         * tests/unictype/test-pr_other_lowercase.c: Likewise.
29763         * tests/unictype/test-pr_other_math.c: Likewise.
29764         * tests/unictype/test-pr_other_uppercase.c: Likewise.
29765         * tests/unictype/test-pr_paired_punctuation.c: Likewise.
29766         * tests/unictype/test-pr_paragraph_separator.c: Likewise.
29767         * tests/unictype/test-pr_pattern_syntax.c: Likewise.
29768         * tests/unictype/test-pr_pattern_white_space.c: Likewise.
29769         * tests/unictype/test-pr_private_use.c: Likewise.
29770         * tests/unictype/test-pr_punctuation.c: Likewise.
29771         * tests/unictype/test-pr_quotation_mark.c: Likewise.
29772         * tests/unictype/test-pr_radical.c: Likewise.
29773         * tests/unictype/test-pr_sentence_terminal.c: Likewise.
29774         * tests/unictype/test-pr_soft_dotted.c: Likewise.
29775         * tests/unictype/test-pr_space.c: Likewise.
29776         * tests/unictype/test-pr_terminal_punctuation.c: Likewise.
29777         * tests/unictype/test-pr_titlecase.c: Likewise.
29778         * tests/unictype/test-pr_unassigned_code_value.c: Likewise.
29779         * tests/unictype/test-pr_unified_ideograph.c: Likewise.
29780         * tests/unictype/test-pr_uppercase.c: Likewise.
29781         * tests/unictype/test-pr_variation_selector.c: Likewise.
29782         * tests/unictype/test-pr_white_space.c: Likewise.
29783         * tests/unictype/test-pr_xid_continue.c: Likewise.
29784         * tests/unictype/test-pr_xid_start.c: Likewise.
29785         * tests/unictype/test-pr_zero_width.c: Likewise.
29786         * tests/unictype/test-sy_c_whitespace.c: Likewise.
29787         * tests/unictype/test-sy_java_whitespace.c: Likewise.
29788
29789 2007-11-12  Bruno Haible  <bruno@clisp.org>
29790
29791         Unicode character classification functions.
29792         * lib/unictype.h: New file.
29793         * modules/unictype/base: New file.
29794         * modules/unictype/category-L: New file.
29795         * modules/unictype/category-Lu: New file.
29796         * modules/unictype/category-Ll: New file.
29797         * modules/unictype/category-Lt: New file.
29798         * modules/unictype/category-Lm: New file.
29799         * modules/unictype/category-Lo: New file.
29800         * modules/unictype/category-M: New file.
29801         * modules/unictype/category-Mn: New file.
29802         * modules/unictype/category-Mc: New file.
29803         * modules/unictype/category-Me: New file.
29804         * modules/unictype/category-N: New file.
29805         * modules/unictype/category-Nd: New file.
29806         * modules/unictype/category-Nl: New file.
29807         * modules/unictype/category-No: New file.
29808         * modules/unictype/category-P: New file.
29809         * modules/unictype/category-Pc: New file.
29810         * modules/unictype/category-Pd: New file.
29811         * modules/unictype/category-Ps: New file.
29812         * modules/unictype/category-Pe: New file.
29813         * modules/unictype/category-Pi: New file.
29814         * modules/unictype/category-Pf: New file.
29815         * modules/unictype/category-Po: New file.
29816         * modules/unictype/category-S: New file.
29817         * modules/unictype/category-Sm: New file.
29818         * modules/unictype/category-Sc: New file.
29819         * modules/unictype/category-Sk: New file.
29820         * modules/unictype/category-So: New file.
29821         * modules/unictype/category-Z: New file.
29822         * modules/unictype/category-Zs: New file.
29823         * modules/unictype/category-Zl: New file.
29824         * modules/unictype/category-Zp: New file.
29825         * modules/unictype/category-C: New file.
29826         * modules/unictype/category-Cc: New file.
29827         * modules/unictype/category-Cf: New file.
29828         * modules/unictype/category-Cs: New file.
29829         * modules/unictype/category-Co: New file.
29830         * modules/unictype/category-Cn: New file.
29831         * modules/unictype/category-or: New file.
29832         * modules/unictype/category-of: New file.
29833         * modules/unictype/category-test: New file.
29834         * modules/unictype/category-test-withtable: New file.
29835         * modules/unictype/category-byname: New file.
29836         * modules/unictype/category-none: New file.
29837         * modules/unictype/category-and: New file.
29838         * modules/unictype/category-and-not: New file.
29839         * modules/unictype/category-name: New file.
29840         * modules/unictype/combining-class: New file.
29841         * modules/unictype/category-all: New file.
29842         * modules/unictype/bidicategory-all: New file.
29843         * modules/unictype/bidicategory-byname: New file.
29844         * modules/unictype/bidicategory-name: New file.
29845         * modules/unictype/bidicategory-of: New file.
29846         * modules/unictype/bidicategory-test: New file.
29847         * modules/unictype/decimal-digit: New file.
29848         * modules/unictype/digit: New file.
29849         * modules/unictype/numeric: New file.
29850         * modules/unictype/mirror: New file.
29851         * modules/unictype/property-white-space: New file.
29852         * modules/unictype/property-alphabetic: New file.
29853         * modules/unictype/property-other-alphabetic: New file.
29854         * modules/unictype/property-not-a-character: New file.
29855         * modules/unictype/property-default-ignorable-code-point: New file.
29856         * modules/unictype/property-other-default-ignorable-code-point: New
29857         file.
29858         * modules/unictype/property-deprecated: New file.
29859         * modules/unictype/property-logical-order-exception: New file.
29860         * modules/unictype/property-variation-selector: New file.
29861         * modules/unictype/property-private-use: New file.
29862         * modules/unictype/property-unassigned-code-value: New file.
29863         * modules/unictype/property-uppercase: New file.
29864         * modules/unictype/property-other-uppercase: New file.
29865         * modules/unictype/property-lowercase: New file.
29866         * modules/unictype/property-other-lowercase: New file.
29867         * modules/unictype/property-titlecase: New file.
29868         * modules/unictype/property-soft-dotted: New file.
29869         * modules/unictype/property-id-start: New file.
29870         * modules/unictype/property-other-id-start: New file.
29871         * modules/unictype/property-id-continue: New file.
29872         * modules/unictype/property-other-id-continue: New file.
29873         * modules/unictype/property-xid-start: New file.
29874         * modules/unictype/property-xid-continue: New file.
29875         * modules/unictype/property-pattern-white-space: New file.
29876         * modules/unictype/property-pattern-syntax: New file.
29877         * modules/unictype/property-join-control: New file.
29878         * modules/unictype/property-grapheme-base: New file.
29879         * modules/unictype/property-grapheme-extend: New file.
29880         * modules/unictype/property-other-grapheme-extend: New file.
29881         * modules/unictype/property-grapheme-link: New file.
29882         * modules/unictype/property-bidi-control: New file.
29883         * modules/unictype/property-bidi-left-to-right: New file.
29884         * modules/unictype/property-bidi-hebrew-right-to-left: New file.
29885         * modules/unictype/property-bidi-arabic-right-to-left: New file.
29886         * modules/unictype/property-bidi-european-digit: New file.
29887         * modules/unictype/property-bidi-eur-num-separator: New file.
29888         * modules/unictype/property-bidi-eur-num-terminator: New file.
29889         * modules/unictype/property-bidi-arabic-digit: New file.
29890         * modules/unictype/property-bidi-common-separator: New file.
29891         * modules/unictype/property-bidi-block-separator: New file.
29892         * modules/unictype/property-bidi-segment-separator: New file.
29893         * modules/unictype/property-bidi-whitespace: New file.
29894         * modules/unictype/property-bidi-non-spacing-mark: New file.
29895         * modules/unictype/property-bidi-boundary-neutral: New file.
29896         * modules/unictype/property-bidi-pdf: New file.
29897         * modules/unictype/property-bidi-embedding-or-override: New file.
29898         * modules/unictype/property-bidi-other-neutral: New file.
29899         * modules/unictype/property-hex-digit: New file.
29900         * modules/unictype/property-ascii-hex-digit: New file.
29901         * modules/unictype/property-ideographic: New file.
29902         * modules/unictype/property-unified-ideograph: New file.
29903         * modules/unictype/property-radical: New file.
29904         * modules/unictype/property-ids-binary-operator: New file.
29905         * modules/unictype/property-ids-trinary-operator: New file.
29906         * modules/unictype/property-zero-width: New file.
29907         * modules/unictype/property-space: New file.
29908         * modules/unictype/property-non-break: New file.
29909         * modules/unictype/property-iso-control: New file.
29910         * modules/unictype/property-format-control: New file.
29911         * modules/unictype/property-dash: New file.
29912         * modules/unictype/property-hyphen: New file.
29913         * modules/unictype/property-punctuation: New file.
29914         * modules/unictype/property-line-separator: New file.
29915         * modules/unictype/property-paragraph-separator: New file.
29916         * modules/unictype/property-quotation-mark: New file.
29917         * modules/unictype/property-sentence-terminal: New file.
29918         * modules/unictype/property-terminal-punctuation: New file.
29919         * modules/unictype/property-currency-symbol: New file.
29920         * modules/unictype/property-math: New file.
29921         * modules/unictype/property-other-math: New file.
29922         * modules/unictype/property-paired-punctuation: New file.
29923         * modules/unictype/property-left-of-pair: New file.
29924         * modules/unictype/property-combining: New file.
29925         * modules/unictype/property-composite: New file.
29926         * modules/unictype/property-decimal-digit: New file.
29927         * modules/unictype/property-numeric: New file.
29928         * modules/unictype/property-diacritic: New file.
29929         * modules/unictype/property-extender: New file.
29930         * modules/unictype/property-ignorable-control: New file.
29931         * modules/unictype/property-test: New file.
29932         * modules/unictype/property-byname: New file.
29933         * modules/unictype/property-all: New file.
29934         * modules/unictype/scripts: New file.
29935         * modules/unictype/scripts-all: New file.
29936         * modules/unictype/block-of: New file.
29937         * modules/unictype/block-test: New file.
29938         * modules/unictype/block-list: New file.
29939         * modules/unictype/block-all: New file.
29940         * modules/unictype/syntax-c-whitespace: New file.
29941         * modules/unictype/syntax-java-whitespace: New file.
29942         * modules/unictype/syntax-c-ident: New file.
29943         * modules/unictype/syntax-java-ident: New file.
29944         * modules/unictype/ctype-alnum: New file.
29945         * modules/unictype/ctype-alpha: New file.
29946         * modules/unictype/ctype-cntrl: New file.
29947         * modules/unictype/ctype-digit: New file.
29948         * modules/unictype/ctype-graph: New file.
29949         * modules/unictype/ctype-lower: New file.
29950         * modules/unictype/ctype-print: New file.
29951         * modules/unictype/ctype-punct: New file.
29952         * modules/unictype/ctype-space: New file.
29953         * modules/unictype/ctype-upper: New file.
29954         * modules/unictype/ctype-xdigit: New file.
29955         * modules/unictype/ctype-blank: New file.
29956         * lib/unictype/bidi_byname.c: New file.
29957         * lib/unictype/bidi_name.c: New file.
29958         * lib/unictype/bidi_of.c: New file.
29959         * lib/unictype/bidi_test.c: New file.
29960         * lib/unictype/bitmap.h: New file.
29961         * lib/unictype/block_test.c: New file.
29962         * lib/unictype/blocks.c: New file.
29963         * lib/unictype/categ_C.c: New file.
29964         * lib/unictype/categ_Cc.c: New file.
29965         * lib/unictype/categ_Cf.c: New file.
29966         * lib/unictype/categ_Cn.c: New file.
29967         * lib/unictype/categ_Co.c: New file.
29968         * lib/unictype/categ_Cs.c: New file.
29969         * lib/unictype/categ_L.c: New file.
29970         * lib/unictype/categ_Ll.c: New file.
29971         * lib/unictype/categ_Lm.c: New file.
29972         * lib/unictype/categ_Lo.c: New file.
29973         * lib/unictype/categ_Lt.c: New file.
29974         * lib/unictype/categ_Lu.c: New file.
29975         * lib/unictype/categ_M.c: New file.
29976         * lib/unictype/categ_Mc.c: New file.
29977         * lib/unictype/categ_Me.c: New file.
29978         * lib/unictype/categ_Mn.c: New file.
29979         * lib/unictype/categ_N.c: New file.
29980         * lib/unictype/categ_Nd.c: New file.
29981         * lib/unictype/categ_Nl.c: New file.
29982         * lib/unictype/categ_No.c: New file.
29983         * lib/unictype/categ_P.c: New file.
29984         * lib/unictype/categ_Pc.c: New file.
29985         * lib/unictype/categ_Pd.c: New file.
29986         * lib/unictype/categ_Pe.c: New file.
29987         * lib/unictype/categ_Pf.c: New file.
29988         * lib/unictype/categ_Pi.c: New file.
29989         * lib/unictype/categ_Po.c: New file.
29990         * lib/unictype/categ_Ps.c: New file.
29991         * lib/unictype/categ_S.c: New file.
29992         * lib/unictype/categ_Sc.c: New file.
29993         * lib/unictype/categ_Sk.c: New file.
29994         * lib/unictype/categ_Sm.c: New file.
29995         * lib/unictype/categ_So.c: New file.
29996         * lib/unictype/categ_Z.c: New file.
29997         * lib/unictype/categ_Zl.c: New file.
29998         * lib/unictype/categ_Zp.c: New file.
29999         * lib/unictype/categ_Zs.c: New file.
30000         * lib/unictype/categ_and.c: New file.
30001         * lib/unictype/categ_and_not.c: New file.
30002         * lib/unictype/categ_byname.c: New file.
30003         * lib/unictype/categ_name.c: New file.
30004         * lib/unictype/categ_none.c: New file.
30005         * lib/unictype/categ_of.c: New file.
30006         * lib/unictype/categ_or.c: New file.
30007         * lib/unictype/categ_test.c: New file.
30008         * lib/unictype/combining.c: New file.
30009         * lib/unictype/ctype_alnum.c: New file.
30010         * lib/unictype/ctype_alpha.c: New file.
30011         * lib/unictype/ctype_blank.c: New file.
30012         * lib/unictype/ctype_cntrl.c: New file.
30013         * lib/unictype/ctype_digit.c: New file.
30014         * lib/unictype/ctype_graph.c: New file.
30015         * lib/unictype/ctype_lower.c: New file.
30016         * lib/unictype/ctype_print.c: New file.
30017         * lib/unictype/ctype_punct.c: New file.
30018         * lib/unictype/ctype_space.c: New file.
30019         * lib/unictype/ctype_upper.c: New file.
30020         * lib/unictype/ctype_xdigit.c: New file.
30021         * lib/unictype/decdigit.c: New file.
30022         * lib/unictype/digit.c: New file.
30023         * lib/unictype/identsyntaxmap.h: New file.
30024         * lib/unictype/mirror.c: New file.
30025         * lib/unictype/numeric.c: New file.
30026         * lib/unictype/pr_alphabetic.c: New file.
30027         * lib/unictype/pr_ascii_hex_digit.c: New file.
30028         * lib/unictype/pr_bidi_arabic_digit.c: New file.
30029         * lib/unictype/pr_bidi_arabic_right_to_left.c: New file.
30030         * lib/unictype/pr_bidi_block_separator.c: New file.
30031         * lib/unictype/pr_bidi_boundary_neutral.c: New file.
30032         * lib/unictype/pr_bidi_common_separator.c: New file.
30033         * lib/unictype/pr_bidi_control.c: New file.
30034         * lib/unictype/pr_bidi_embedding_or_override.c: New file.
30035         * lib/unictype/pr_bidi_eur_num_separator.c: New file.
30036         * lib/unictype/pr_bidi_eur_num_terminator.c: New file.
30037         * lib/unictype/pr_bidi_european_digit.c: New file.
30038         * lib/unictype/pr_bidi_hebrew_right_to_left.c: New file.
30039         * lib/unictype/pr_bidi_left_to_right.c: New file.
30040         * lib/unictype/pr_bidi_non_spacing_mark.c: New file.
30041         * lib/unictype/pr_bidi_other_neutral.c: New file.
30042         * lib/unictype/pr_bidi_pdf.c: New file.
30043         * lib/unictype/pr_bidi_segment_separator.c: New file.
30044         * lib/unictype/pr_bidi_whitespace.c: New file.
30045         * lib/unictype/pr_byname.c: New file.
30046         * lib/unictype/pr_byname.gperf: New file.
30047         * lib/unictype/pr_combining.c: New file.
30048         * lib/unictype/pr_composite.c: New file.
30049         * lib/unictype/pr_currency_symbol.c: New file.
30050         * lib/unictype/pr_dash.c: New file.
30051         * lib/unictype/pr_decimal_digit.c: New file.
30052         * lib/unictype/pr_default_ignorable_code_point.c: New file.
30053         * lib/unictype/pr_deprecated.c: New file.
30054         * lib/unictype/pr_diacritic.c: New file.
30055         * lib/unictype/pr_extender.c: New file.
30056         * lib/unictype/pr_format_control.c: New file.
30057         * lib/unictype/pr_grapheme_base.c: New file.
30058         * lib/unictype/pr_grapheme_extend.c: New file.
30059         * lib/unictype/pr_grapheme_link.c: New file.
30060         * lib/unictype/pr_hex_digit.c: New file.
30061         * lib/unictype/pr_hyphen.c: New file.
30062         * lib/unictype/pr_id_continue.c: New file.
30063         * lib/unictype/pr_id_start.c: New file.
30064         * lib/unictype/pr_ideographic.c: New file.
30065         * lib/unictype/pr_ids_binary_operator.c: New file.
30066         * lib/unictype/pr_ids_trinary_operator.c: New file.
30067         * lib/unictype/pr_ignorable_control.c: New file.
30068         * lib/unictype/pr_iso_control.c: New file.
30069         * lib/unictype/pr_join_control.c: New file.
30070         * lib/unictype/pr_left_of_pair.c: New file.
30071         * lib/unictype/pr_line_separator.c: New file.
30072         * lib/unictype/pr_logical_order_exception.c: New file.
30073         * lib/unictype/pr_lowercase.c: New file.
30074         * lib/unictype/pr_math.c: New file.
30075         * lib/unictype/pr_non_break.c: New file.
30076         * lib/unictype/pr_not_a_character.c: New file.
30077         * lib/unictype/pr_numeric.c: New file.
30078         * lib/unictype/pr_other_alphabetic.c: New file.
30079         * lib/unictype/pr_other_default_ignorable_code_point.c: New file.
30080         * lib/unictype/pr_other_grapheme_extend.c: New file.
30081         * lib/unictype/pr_other_id_continue.c: New file.
30082         * lib/unictype/pr_other_id_start.c: New file.
30083         * lib/unictype/pr_other_lowercase.c: New file.
30084         * lib/unictype/pr_other_math.c: New file.
30085         * lib/unictype/pr_other_uppercase.c: New file.
30086         * lib/unictype/pr_paired_punctuation.c: New file.
30087         * lib/unictype/pr_paragraph_separator.c: New file.
30088         * lib/unictype/pr_pattern_syntax.c: New file.
30089         * lib/unictype/pr_pattern_white_space.c: New file.
30090         * lib/unictype/pr_private_use.c: New file.
30091         * lib/unictype/pr_punctuation.c: New file.
30092         * lib/unictype/pr_quotation_mark.c: New file.
30093         * lib/unictype/pr_radical.c: New file.
30094         * lib/unictype/pr_sentence_terminal.c: New file.
30095         * lib/unictype/pr_soft_dotted.c: New file.
30096         * lib/unictype/pr_space.c: New file.
30097         * lib/unictype/pr_terminal_punctuation.c: New file.
30098         * lib/unictype/pr_test.c: New file.
30099         * lib/unictype/pr_titlecase.c: New file.
30100         * lib/unictype/pr_unassigned_code_value.c: New file.
30101         * lib/unictype/pr_unified_ideograph.c: New file.
30102         * lib/unictype/pr_uppercase.c: New file.
30103         * lib/unictype/pr_variation_selector.c: New file.
30104         * lib/unictype/pr_white_space.c: New file.
30105         * lib/unictype/pr_xid_continue.c: New file.
30106         * lib/unictype/pr_xid_start.c: New file.
30107         * lib/unictype/pr_zero_width.c: New file.
30108         * lib/unictype/scripts.c: New file.
30109         * lib/unictype/sy_c_ident.c: New file.
30110         * lib/unictype/sy_c_whitespace.c: New file.
30111         * lib/unictype/sy_java_ident.c: New file.
30112         * lib/unictype/sy_java_whitespace.c: New file.
30113
30114         * lib/unictype/bidi_of.h: New file, generated by gen-ctype.c for
30115         Unicode 5.0.0.
30116         * lib/unictype/blocks.h: Likewise.
30117         * lib/unictype/categ_C.h: Likewise.
30118         * lib/unictype/categ_Cc.h: Likewise.
30119         * lib/unictype/categ_Cf.h: Likewise.
30120         * lib/unictype/categ_Cn.h: Likewise.
30121         * lib/unictype/categ_Co.h: Likewise.
30122         * lib/unictype/categ_Cs.h: Likewise.
30123         * lib/unictype/categ_L.h: Likewise.
30124         * lib/unictype/categ_Ll.h: Likewise.
30125         * lib/unictype/categ_Lm.h: Likewise.
30126         * lib/unictype/categ_Lo.h: Likewise.
30127         * lib/unictype/categ_Lt.h: Likewise.
30128         * lib/unictype/categ_Lu.h: Likewise.
30129         * lib/unictype/categ_M.h: Likewise.
30130         * lib/unictype/categ_Mc.h: Likewise.
30131         * lib/unictype/categ_Me.h: Likewise.
30132         * lib/unictype/categ_Mn.h: Likewise.
30133         * lib/unictype/categ_N.h: Likewise.
30134         * lib/unictype/categ_Nd.h: Likewise.
30135         * lib/unictype/categ_Nl.h: Likewise.
30136         * lib/unictype/categ_No.h: Likewise.
30137         * lib/unictype/categ_P.h: Likewise.
30138         * lib/unictype/categ_Pc.h: Likewise.
30139         * lib/unictype/categ_Pd.h: Likewise.
30140         * lib/unictype/categ_Pe.h: Likewise.
30141         * lib/unictype/categ_Pf.h: Likewise.
30142         * lib/unictype/categ_Pi.h: Likewise.
30143         * lib/unictype/categ_Po.h: Likewise.
30144         * lib/unictype/categ_Ps.h: Likewise.
30145         * lib/unictype/categ_S.h: Likewise.
30146         * lib/unictype/categ_Sc.h: Likewise.
30147         * lib/unictype/categ_Sk.h: Likewise.
30148         * lib/unictype/categ_Sm.h: Likewise.
30149         * lib/unictype/categ_So.h: Likewise.
30150         * lib/unictype/categ_Z.h: Likewise.
30151         * lib/unictype/categ_Zl.h: Likewise.
30152         * lib/unictype/categ_Zp.h: Likewise.
30153         * lib/unictype/categ_Zs.h: Likewise.
30154         * lib/unictype/categ_of.h: Likewise.
30155         * lib/unictype/combining.h: Likewise.
30156         * lib/unictype/ctype_alnum.h: Likewise.
30157         * lib/unictype/ctype_alpha.h: Likewise.
30158         * lib/unictype/ctype_blank.h: Likewise.
30159         * lib/unictype/ctype_cntrl.h: Likewise.
30160         * lib/unictype/ctype_digit.h: Likewise.
30161         * lib/unictype/ctype_graph.h: Likewise.
30162         * lib/unictype/ctype_lower.h: Likewise.
30163         * lib/unictype/ctype_print.h: Likewise.
30164         * lib/unictype/ctype_punct.h: Likewise.
30165         * lib/unictype/ctype_space.h: Likewise.
30166         * lib/unictype/ctype_upper.h: Likewise.
30167         * lib/unictype/ctype_xdigit.h: Likewise.
30168         * lib/unictype/decdigit.h: Likewise.
30169         * lib/unictype/digit.h: Likewise.
30170         * lib/unictype/mirror.h: Likewise.
30171         * lib/unictype/numeric.h: Likewise.
30172         * lib/unictype/pr_alphabetic.h: Likewise.
30173         * lib/unictype/pr_ascii_hex_digit.h: Likewise.
30174         * lib/unictype/pr_bidi_arabic_digit.h: Likewise.
30175         * lib/unictype/pr_bidi_arabic_right_to_left.h: Likewise.
30176         * lib/unictype/pr_bidi_block_separator.h: Likewise.
30177         * lib/unictype/pr_bidi_boundary_neutral.h: Likewise.
30178         * lib/unictype/pr_bidi_common_separator.h: Likewise.
30179         * lib/unictype/pr_bidi_control.h: Likewise.
30180         * lib/unictype/pr_bidi_embedding_or_override.h: Likewise.
30181         * lib/unictype/pr_bidi_eur_num_separator.h: Likewise.
30182         * lib/unictype/pr_bidi_eur_num_terminator.h: Likewise.
30183         * lib/unictype/pr_bidi_european_digit.h: Likewise.
30184         * lib/unictype/pr_bidi_hebrew_right_to_left.h: Likewise.
30185         * lib/unictype/pr_bidi_left_to_right.h: Likewise.
30186         * lib/unictype/pr_bidi_non_spacing_mark.h: Likewise.
30187         * lib/unictype/pr_bidi_other_neutral.h: Likewise.
30188         * lib/unictype/pr_bidi_pdf.h: Likewise.
30189         * lib/unictype/pr_bidi_segment_separator.h: Likewise.
30190         * lib/unictype/pr_bidi_whitespace.h: Likewise.
30191         * lib/unictype/pr_combining.h: Likewise.
30192         * lib/unictype/pr_composite.h: Likewise.
30193         * lib/unictype/pr_currency_symbol.h: Likewise.
30194         * lib/unictype/pr_dash.h: Likewise.
30195         * lib/unictype/pr_decimal_digit.h: Likewise.
30196         * lib/unictype/pr_default_ignorable_code_point.h: Likewise.
30197         * lib/unictype/pr_deprecated.h: Likewise.
30198         * lib/unictype/pr_diacritic.h: Likewise.
30199         * lib/unictype/pr_extender.h: Likewise.
30200         * lib/unictype/pr_format_control.h: Likewise.
30201         * lib/unictype/pr_grapheme_base.h: Likewise.
30202         * lib/unictype/pr_grapheme_extend.h: Likewise.
30203         * lib/unictype/pr_grapheme_link.h: Likewise.
30204         * lib/unictype/pr_hex_digit.h: Likewise.
30205         * lib/unictype/pr_hyphen.h: Likewise.
30206         * lib/unictype/pr_id_continue.h: Likewise.
30207         * lib/unictype/pr_id_start.h: Likewise.
30208         * lib/unictype/pr_ideographic.h: Likewise.
30209         * lib/unictype/pr_ids_binary_operator.h: Likewise.
30210         * lib/unictype/pr_ids_trinary_operator.h: Likewise.
30211         * lib/unictype/pr_ignorable_control.h: Likewise.
30212         * lib/unictype/pr_iso_control.h: Likewise.
30213         * lib/unictype/pr_join_control.h: Likewise.
30214         * lib/unictype/pr_left_of_pair.h: Likewise.
30215         * lib/unictype/pr_line_separator.h: Likewise.
30216         * lib/unictype/pr_logical_order_exception.h: Likewise.
30217         * lib/unictype/pr_lowercase.h: Likewise.
30218         * lib/unictype/pr_math.h: Likewise.
30219         * lib/unictype/pr_non_break.h: Likewise.
30220         * lib/unictype/pr_not_a_character.h: Likewise.
30221         * lib/unictype/pr_numeric.h: Likewise.
30222         * lib/unictype/pr_other_alphabetic.h: Likewise.
30223         * lib/unictype/pr_other_default_ignorable_code_point.h: Likewise.
30224         * lib/unictype/pr_other_grapheme_extend.h: Likewise.
30225         * lib/unictype/pr_other_id_continue.h: Likewise.
30226         * lib/unictype/pr_other_id_start.h: Likewise.
30227         * lib/unictype/pr_other_lowercase.h: Likewise.
30228         * lib/unictype/pr_other_math.h: Likewise.
30229         * lib/unictype/pr_other_uppercase.h: Likewise.
30230         * lib/unictype/pr_paired_punctuation.h: Likewise.
30231         * lib/unictype/pr_paragraph_separator.h: Likewise.
30232         * lib/unictype/pr_pattern_syntax.h: Likewise.
30233         * lib/unictype/pr_pattern_white_space.h: Likewise.
30234         * lib/unictype/pr_private_use.h: Likewise.
30235         * lib/unictype/pr_punctuation.h: Likewise.
30236         * lib/unictype/pr_quotation_mark.h: Likewise.
30237         * lib/unictype/pr_radical.h: Likewise.
30238         * lib/unictype/pr_sentence_terminal.h: Likewise.
30239         * lib/unictype/pr_soft_dotted.h: Likewise.
30240         * lib/unictype/pr_space.h: Likewise.
30241         * lib/unictype/pr_terminal_punctuation.h: Likewise.
30242         * lib/unictype/pr_titlecase.h: Likewise.
30243         * lib/unictype/pr_unassigned_code_value.h: Likewise.
30244         * lib/unictype/pr_unified_ideograph.h: Likewise.
30245         * lib/unictype/pr_uppercase.h: Likewise.
30246         * lib/unictype/pr_variation_selector.h: Likewise.
30247         * lib/unictype/pr_white_space.h: Likewise.
30248         * lib/unictype/pr_xid_continue.h: Likewise.
30249         * lib/unictype/pr_xid_start.h: Likewise.
30250         * lib/unictype/pr_zero_width.h: Likewise.
30251         * lib/unictype/scripts.h: Likewise.
30252         * lib/unictype/scripts_byname.gperf: Likewise.
30253         * lib/unictype/sy_c_ident.h: Likewise.
30254         * lib/unictype/sy_c_whitespace.h: Likewise.
30255         * lib/unictype/sy_java_ident.h: Likewise.
30256         * lib/unictype/sy_java_whitespace.h: Likewise.
30257
30258         * lib/unictype/Makefile: New file.
30259         * lib/unictype/gen-ctype.c: New file, based on gen-unicode-ctype.c in
30260         glibc.
30261         * lib/unictype/3level.h: New file, copied from glibc.
30262         * lib/unictype/3levelbit.h: New file.
30263
30264 2007-11-11  Bruno Haible  <bruno@clisp.org>
30265
30266         * modules/gperf: New file.
30267         * modules/iconv_open (Depends-on): Add it.
30268         (Makefile.am): Remove the GPERF definition.
30269
30270 2007-11-11  Bruno Haible  <bruno@clisp.org>
30271
30272         * m4/round.m4 (gl_FUNC_ROUND): Test against NetBSD 3.0 bug.
30273         * doc/functions/round.texi: Mention the NetBSD 3.0 bug.
30274
30275 2007-11-11  Bruno Haible  <bruno@clisp.org>
30276
30277         * tests/test-argmatch.c (ARGMATCH_DIE): Undefine.
30278         (usage): Remove function.
30279
30280 2007-11-11  Bruno Haible  <bruno@clisp.org>
30281
30282         * m4/roundf.m4 (gl_FUNC_ROUNDF): Use gl_FUNC_FLOORF_LIBS and
30283         gl_FUNC_CEILF_LIBS.
30284         * m4/round.m4 (gl_FUNC_ROUND): Use gl_FUNC_FLOOR_LIBS and
30285         gl_FUNC_CEIL_LIBS.
30286         * m4/roundl.m4 (gl_FUNC_ROUNDL): Use gl_FUNC_FLOORL_LIBS and
30287         gl_FUNC_CEILL_LIBS.
30288         * modules/roundf (Files): Add m4/floorf.m4, m4/ceilf.m4.
30289         * modules/round (Files): Add m4/floor.m4, m4/ceil.m4.
30290         * modules/roundl (Files): Add m4/floorl.m4, m4/ceill.m4.
30291
30292 2007-11-11  Bruno Haible  <bruno@clisp.org>
30293
30294         * m4/roundf.m4 (gl_FUNC_ROUNDF): Handle the case that floorf and
30295         roundf were declared but do not exist on functions.
30296         * m4/roundl.m4 (gl_FUNC_ROUNDL): Handle the case that floorl and
30297         roundl were declared but do not exist on functions.
30298         * lib/round.c (HAVE_FLOOR_AND_CEIL): Use HAVE_FLOORF_AND_CEILF and
30299         HAVE_FLOORL_AND_CEILL, respectively.
30300         Needed for Sun C on Solaris 10.
30301
30302 2007-11-11  Bruno Haible  <bruno@clisp.org>
30303
30304         * m4/roundf.m4 (gl_FUNC_ROUNDF): Set REPLACE_ROUNDF instead of
30305         HAVE_DECL_ROUNDF. Remove redundant AC_SUBST.
30306         * m4/round.m4 (gl_FUNC_ROUND): Set REPLACE_ROUND instead of
30307         HAVE_DECL_ROUND. Remove redundant AC_SUBST.
30308         * m4/roundl.m4 (gl_FUNC_ROUNDL): Set REPLACE_ROUNDL instead of
30309         HAVE_DECL_ROUNDL. Remove redundant AC_SUBST.
30310         * lib/math.in.h (roundf): Use REPLACE_ROUNDF instead of
30311         HAVE_DECL_ROUNDF.
30312         (round): Use REPLACE_ROUND instead of HAVE_DECL_ROUND.
30313         (roundl): Use REPLACE_ROUNDL instead of HAVE_DECL_ROUNDL.
30314         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_ROUND* instead
30315         of HAVE_DECL_ROUND*.
30316         * modules/math (Makefile.am): Update.
30317
30318 2007-11-10  Bruno Haible  <bruno@clisp.org>
30319
30320         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Use same check for
30321         ptrdiff_t as m4/intl.m4.
30322
30323 2007-11-10  Jim Meyering  <meyering@redhat.com>
30324
30325         Avoid link failure for the argmatch test.
30326         * tests/test-argmatch.c (usage): Define function to avoid a link
30327         failure: argmatch_die requires a usage function.
30328
30329 2007-11-09  Bruno Haible  <bruno@clisp.org>
30330
30331         * doc/functions/snprintf.texi: Mention BeOS deficiency.
30332         * doc/functions/vsnprintf.texi: Likewise.
30333         * lib/vasnprintf.c (VASNPRINTF): Ensure that we never call snprintf
30334         with a size argument < 2.
30335
30336 2007-11-09  Bruno Haible  <bruno@clisp.org>
30337
30338         * lib/vasnprintf.c (VASNPRINTF): Increase reallocation of snprintf
30339         buffer. Fixes an inefficiency introduced on 2007-11-03.
30340
30341 2007-11-09  Bruno Haible  <bruno@clisp.org>
30342
30343         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8) [BeOS]: Make this test return
30344         none instead of tr_TR. Fixes a failure of test-c-strcasecmp.c.
30345
30346 2007-11-08  Jim Meyering  <meyering@redhat.com>
30347
30348         Change cache variable name prefix "jm_" to "gl_" everywhere.
30349         * m4/d-type.m4, m4/jm-winsz1.m4, m4/jm-winsz2.m4, m4/link-follow.m4:
30350         * m4/putenv.m4, m4/strtoimax.m4, m4/strtoumax.m4, m4/unlink-busy.m4:
30351         * m4/uptime.m4: s/gl_/jm_/
30352
30353 2007-11-07  Bruno Haible  <bruno@clisp.org>
30354
30355         Update to GNU gettext 0.17.
30356         * m4/intl.m4: Update to GNU gettext 0.17.
30357         * m4/po.m4: Likewise.
30358         * modules/gettext (Files): Remove m4/ulonglong.m4.
30359         (configure.ac): Require gettext infrastructure from version 0.17.
30360
30361 2007-11-06  Bruno Haible  <bruno@clisp.org>
30362
30363         * lib/fbufmode.c (fbufmode) [QNX]: Use numerical values for flags; the
30364         symbolic values are not defined in a public header.
30365         * lib/freadable.c (freadable) [QNX]: Likewise.
30366         * lib/freadahead.c (freadahead) [QNX]: Likewise.
30367         * lib/freading.c (freading) [QNX]: Likewise.
30368         * lib/fseterr.c (fseterr) [QNX]: Likewise.
30369         * lib/fwritable.c (fwritable) [QNX]: Likewise.
30370         * lib/fwriting.c (fwriting) [QNX]: Likewise.
30371         * lib/fpurge.c (fpurge) [QNX]: Likewise. Add a return statement.
30372         Reported by Alain Magloire.
30373
30374         * m4/fpending.m4 (gl_FUNC_FPENDING): Add a variant for QNX.
30375
30376 2007-11-05  Bruno Haible  <bruno@clisp.org>
30377
30378         * lib/vasnprintf.c (VASNPRINTF): Expand the NEED_PRINTF_DIRECTIVE_A
30379         code when NEED_PRINTF_LONG_DOUBLE or NEED_PRINTF_DOUBLE is set.
30380         Needed on Cygwin, where !NEED_PRINTF_DIRECTIVE_A && NEED_PRINTF_DOUBLE.
30381         Reported by Eric Blake.
30382
30383 2007-10-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30384             Bruno Haible  <bruno@clisp.org>
30385
30386         * modules/malloc (configure.ac): Define GNULIB_MALLOC_GNU always.
30387         * modules/realloc (configure.ac): Define GNULIB_REALLOC_GNU always.
30388         * lib/realloc.c (SYSTEM_MALLOC_GLIBC_COMPATIBLE): New macro.
30389         (malloc): Undefine also before including <stdlib.h>.
30390         (rpl_realloc): Turn malloc(0) into malloc(1) if necessary.
30391         Needed on OSF/1 4.0.
30392
30393 2007-11-05  Jim Meyering  <meyering@redhat.com>
30394
30395         git-version-gen: sync from coreutils.
30396         * build-aux/git-version-gen: Add comments.
30397         Change the first '-' to '.' in the snapshot version string,
30398         e.g., 6.9-377-08144 -> 6.9.377-08144
30399         Remove first parameter.
30400         Don't declare a version "-dirty" merely because a time
30401         stamp has changed.
30402
30403 2007-11-04  Bruno Haible  <bruno@clisp.org>
30404
30405         * lib/lock.h: Protect all macro definitions containing an 'if'
30406         statement through a "do { ... } while (0)".
30407         * lib/tls.h: Likewise.
30408
30409 2007-11-04  Bruno Haible  <bruno@clisp.org>
30410
30411         * lib/vasnprintf.c (DCHAR_IS_TCHAR, DCHAR_CPY): Undefine at the end.
30412
30413 2007-11-04  Bruno Haible  <bruno@clisp.org>
30414
30415         * m4/printf.m4 (gl_PRINTF_ENOMEM): Use GL_NOCRASH.
30416         * modules/fprintf-posix (Depends-on): Add nocrash.
30417         * modules/snprintf-posix (Depends-on): Likewise.
30418         * modules/sprintf-posix (Depends-on): Likewise.
30419         * modules/vasnprintf-posix (Depends-on): Likewise.
30420         * modules/vasprintf-posix (Depends-on): Likewise.
30421         * modules/vfprintf-posix (Depends-on): Likewise.
30422         * modules/vsnprintf-posix (Depends-on): Likewise.
30423         * modules/vsprintf-posix (Depends-on): Likewise.
30424         * modules/unistdio/u8-vasnprintf (Depends-on): Likewise.
30425         * modules/unistdio/u8-u8-vasnprintf (Depends-on): Likewise.
30426         * modules/unistdio/u16-vasnprintf (Depends-on): Likewise.
30427         * modules/unistdio/u16-u16-vasnprintf (Depends-on): Likewise.
30428         * modules/unistdio/u32-vasnprintf (Depends-on): Likewise.
30429         * modules/unistdio/u32-u32-vasnprintf (Depends-on): Likewise.
30430         * modules/unistdio/ulc-vasnprintf (Depends-on): Likewise.
30431
30432 2007-11-04  Bruno Haible  <bruno@clisp.org>
30433
30434         * modules/nocrash: New file.
30435         * m4/nocrash.m4: New file, taken from GNU clisp. Code taken from
30436         GNU libsigsegv, with permission of GNU libsigsegv's copyright holders.
30437
30438 2007-11-04  Bruno Haible  <bruno@clisp.org>
30439
30440         * tests/test-vasnprintf-posix.c (test_function): Add some tests of
30441         precision handling.
30442         * tests/test-vasprintf-posix.c (test_function): Likewise.
30443         * tests/test-snprintf-posix.h (test_function): Likewise.
30444         * tests/test-sprintf-posix.h (test_function): Likewise.
30445
30446         Fix *printf behaviour for large precisions on mingw and BeOS.
30447         * m4/printf.m4 (gl_PRINTF_PRECISION): New macro.
30448         * lib/vasnprintf.c (VASNPRINTF): Handle NEED_PRINTF_UNBOUNDED_PRECISION.
30449         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_PRECISION): New macro.
30450         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
30451         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
30452         gl_PRINTF_PRECISION and test its result. Invoke
30453         gl_PREREQ_VASNPRINTF_PRECISION.
30454         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
30455         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30456         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30457         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30458         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30459         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30460         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30461         * doc/functions/fprintf.texi: Update.
30462         * doc/functions/printf.texi: Update.
30463         * doc/functions/snprintf.texi: Update.
30464         * doc/functions/sprintf.texi: Update.
30465         * doc/functions/vfprintf.texi: Update.
30466         * doc/functions/vprintf.texi: Update.
30467         * doc/functions/vsnprintf.texi: Update.
30468         * doc/functions/vsprintf.texi: Update.
30469
30470 2007-11-04  Bruno Haible  <bruno@clisp.org>
30471
30472         * lib/vasnprintf.c (scale10_round_decimal_decoded): Fix shift loop.
30473
30474 2007-11-04  Bruno Haible  <bruno@clisp.org>
30475
30476         * modules/relocatable-prog (Files): Add m4/lib-ld.m4.
30477         Reported by Sylvain Beucler <beuc@gnu.org>.
30478
30479 2007-11-03  Bruno Haible  <bruno@clisp.org>
30480
30481         * tests/test-fprintf-posix2.sh: New file.
30482         * tests/test-fprintf-posix2.c: New file.
30483         * modules/fprintf-posix-tests (Files): Add them.
30484         (TESTS): Add test-fprintf-posix2.sh.
30485         (configure.ac): Check for getrlimit and setrlimit.
30486         (check_PROGRAMS): Add test-fprintf-posix2.
30487
30488         * tests/test-printf-posix2.sh: New file.
30489         * tests/test-printf-posix2.c: New file.
30490         * modules/printf-posix-tests (Files): Add them.
30491         (TESTS): Add test-printf-posix2.sh.
30492         (configure.ac): Check for getrlimit and setrlimit.
30493         (check_PROGRAMS): Add test-printf-posix2.
30494
30495         Fix *printf behaviour in out-of-memory situations on MacOS X and *BSD.
30496         * m4/printf.m4 (gl_PRINTF_ENOMEM): New macro.
30497         * lib/vasnprintf.c: Implement NEED_PRINTF_DOUBLE.
30498         (decode_double): New function, copied from decode_long_double.
30499         (scale10_round_decimal_decoded): New function, extracted from
30500         scale10_round_decimal_long_double.
30501         (scale10_round_decimal_long_double): Use it.
30502         (scale10_round_decimal_double): New function.
30503         (floorlog10): New function.
30504         (VASNPRINTF): Handle NEED_PRINTF_DOUBLE case.
30505         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_ENOMEM): New macro.
30506         (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): Invoke it.
30507         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
30508         gl_PRINTF_ENOMEM and test its result. Invoke
30509         gl_PREREQ_VASNPRINTF_ENOMEM.
30510         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
30511         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
30512         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
30513         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
30514         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
30515         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
30516         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
30517         * modules/fprintf-posix (Depends-on): Add frexp-nolibm.
30518         * modules/snprintf-posix (Depends-on): Likewise.
30519         * modules/sprintf-posix (Depends-on): Likewise.
30520         * modules/vasnprintf-posix (Depends-on): Likewise.
30521         * modules/vasprintf-posix (Depends-on): Likewise.
30522         * modules/vfprintf-posix (Depends-on): Likewise.
30523         * modules/vsnprintf-posix (Depends-on): Likewise.
30524         * modules/vsprintf-posix (Depends-on): Likewise.
30525         * doc/functions/fprintf.texi: Update.
30526         * doc/functions/printf.texi: Update.
30527         * doc/functions/snprintf.texi: Update.
30528         * doc/functions/sprintf.texi: Update.
30529         * doc/functions/vfprintf.texi: Update.
30530         * doc/functions/vprintf.texi: Update.
30531         * doc/functions/vsnprintf.texi: Update.
30532         * doc/functions/vsprintf.texi: Update.
30533
30534 2007-11-03  Bruno Haible  <bruno@clisp.org>
30535
30536         * modules/frexp-nolibm-tests: New file.
30537
30538         * modules/frexp-nolibm: New file.
30539         * m4/frexp.m4 (gl_FUNC_FREXP_NO_LIBM): New macro.
30540
30541 2007-11-03  Bruno Haible  <bruno@clisp.org>
30542
30543         * lib/vasnprintf.c (VASNPRINTF): Don't assume that snprintf's return
30544         value is C99 compliant.
30545         Needed for OSF/1 5.1.
30546
30547 2007-11-03  Bruno Haible  <bruno@clisp.org>
30548
30549         Fix out-of-memory handling of vasnprintf.
30550         * lib/printf-parse.c: Include <errno.h>.
30551         (PRINTF_PARSE): When failing, set errno to EINVAL or ENOMEM.
30552         * lib/vasnprintf.c (VASNPRINTF): When PRINTF_PARSE fails, assume errno
30553         is already set.
30554
30555 2007-11-02  Eric Blake  <ebb9@byu.net>
30556
30557         Fix tests on cygwin.
30558         * modules/xprintf-posix-tests (Makefile.am): Link against -lintl.
30559
30560 2007-11-01  Bruno Haible  <bruno@clisp.org>
30561
30562         * lib/stdlib.in.h (putenv): Remove the "not POSIX compliant everywhere"
30563         warning.
30564         * doc/functions/putenv.texi: Clarify that the 'putenv' module is not
30565         needed for POSIX compatibility.
30566
30567 2007-11-01  Paul Eggert  <eggert@cs.ucla.edu>
30568
30569         * m4/putenv.m4 (gl_FUNC_PUTENV): Also mention that we're checking
30570         for compatibility with GNU.
30571
30572 2007-11-01  Bruno Haible  <bruno@clisp.org>
30573
30574         * lib/putenv.c: Include <stdlib.h>. Remove rpl_putenv declaration.
30575         (putenv): Renamed from rpl_putenv. Change argument type from
30576         'const char *' to 'char *'.
30577         * m4/putenv.m4 (gl_FUNC_PUTENV): Require gl_STDLIB_H_DEFAULTS. Instead
30578         of defining putenv in config.h, just set REPLACE_PUTENV.
30579         * modules/putenv (Depends-on): Add stdlib.
30580         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
30581         (Include): Use <stdlib.h>.
30582         * lib/stdlib.in.h (putenv): New declaration.
30583         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_PUTENV and
30584         REPLACE_PUTENV.
30585         * modules/stdlib (Makefile.am): Substitute GNULIB_PUTENV and
30586         REPLACE_PUTENV.
30587         Needed for MacOS X 10.5.0.
30588         Reported by Peter O'Gorman <peter@pogma.com>.
30589
30590 2007-11-01  Jim Meyering  <meyering@redhat.com>
30591
30592         Treat an empty date string exactly like "0".
30593         * lib/getdate.y (get_date): Once any isspace or TZ= prefix is consumed,
30594         if the remaining date string (to be parsed) is empty, use "0".
30595         Reported by Mischa Molhoek and discussed in this thread:
30596         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/11726>.
30597
30598 2007-10-31  Bruno Haible  <bruno@clisp.org>
30599
30600         * m4/intmax_t.m4 (gl_AC_TYPE_INTMAX_T, gt_AC_TYPE_INTMAX_T): Use
30601         AC_TYPE_LONG_LONG_INT instead of gl_AC_TYPE_LONG_LONG.
30602         * m4/uintmax_t.m4 (gl_AC_TYPE_UINTMAX_T): Use
30603         AC_TYPE_UNSIGNED_LONG_LONG_INT instead of gl_AC_TYPE_UNSIGNED_LONG_LONG.
30604         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Remove macro.
30605         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG): Remove macro.
30606
30607 2007-10-31  Bruno Haible  <bruno@clisp.org>
30608
30609         * m4/longlong.m4 (_AC_TYPE_LONG_LONG_SNIPPET): New macro, extracted
30610         from AC_TYPE_LONG_LONG_INT and AC_TYPE_UNSIGNED_LONG_LONG_INT.
30611         (AC_TYPE_LONG_LONG_INT): Use it.
30612         (AC_TYPE_UNSIGNED_LONG_LONG_INT): Moved here from m4/ulonglong.m4. Use
30613         it as well.
30614         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Remove macro; moved
30615         to m4/longlong.m4.
30616         * modules/stdint (Files): Remove m4/ulonglong.m4.
30617         * modules/strtoull (Files): Use m4/longlong.m4 instead of
30618         m4/ulonglong.m4.
30619         * modules/strtoumax (Files): Likewise.
30620
30621 2007-10-30  Bruno Haible  <bruno@clisp.org>
30622
30623         * modules/xvasprintf-posix: New file.
30624         Suggested by Eric Blake.
30625
30626 2007-10-30  Bruno Haible  <bruno@clisp.org>
30627
30628         * modules/xprintf-posix-tests: New file.
30629         * tests/test-xprintf-posix.sh: New file.
30630         * tests/test-xprintf-posix.c: New file.
30631         * tests/test-xfprintf-posix.c: New file.
30632
30633         * modules/xprintf-posix: New file.
30634
30635 2007-10-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30636
30637         * modules/fbufmode-tests (MOSTLYCLEANFILES): Remove temp files.
30638         * modules/freadable-tests (MOSTLYCLEANFILES): Likewise.
30639         * modules/fwritable-tests (MOSTLYCLEANFILES): Likewise.
30640
30641 2007-10-29  Bruno Haible  <bruno@clisp.org>
30642
30643         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): Rename the cache variable to
30644         contain the special marker '_cv_'.
30645         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): Likewise.
30646         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): Likewise.
30647         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): Likewise.
30648         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): Likewise.
30649         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): Likewise.
30650         Reported by Ralf Wildenhues.
30651
30652 2007-10-29  Bruno Haible  <bruno@clisp.org>
30653
30654         * gnulib-tool (func_import): When --lgpl is not specified, set
30655         sed_transform_lib_file to convert LGPL and GPLv2+ copyright headers to
30656         GPLv3.
30657         Reported by Simon Josefsson.
30658
30659 2007-10-28  Bruno Haible  <bruno@clisp.org>
30660
30661         * lib/math.in.h: Test REPLACE_ISFINITE instead of HAVE_DECL_ISFINITE.
30662         * m4/isfinite.m4 (gl_ISFINITE): Initialize REPLACE_ISFINITE instead of
30663         HAVE_DECL_ISFINITE.
30664         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
30665         * modules/math (Makefile.am): Substitute REPLACE_ISFINITE instead of
30666         HAVE_DECL_ISFINITE.
30667
30668 2007-10-28  Bruno Haible  <bruno@clisp.org>
30669
30670         * lib/stdint.in.h (_STDINT_MAX): Subtract 1 from an unused signed
30671         integer shift in the signed case. Fixes warnings with OSF/1 5.1 cc.
30672
30673 2007-10-28  Bruno Haible  <bruno@clisp.org>
30674
30675         Fix link errors with Sun C 5.0 on Solaris 10.
30676         * m4/floorf.m4 (gl_FUNC_FLOORF): Consider also the case that the
30677         function is declared but not present in the compiler's libm.
30678         * m4/floorl.m4 (gl_FUNC_FLOORL): Likewise.
30679         * m4/ceilf.m4 (gl_FUNC_CEILF): Likewise.
30680         * m4/ceill.m4 (gl_FUNC_CEILL: Likewise.
30681         * lib/math.in.h: Test REPLACE_CEILF instead of HAVE_DECL_CEILF.
30682         Test REPLACE_CEILL instead of HAVE_DECL_CEILL.
30683         Test REPLACE_FLOORF instead of HAVE_DECL_FLOORF.
30684         Test REPLACE_FLOORL instead of HAVE_DECL_FLOORL.
30685         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Update.
30686         * modules/math (Makefile.am): Substitute REPLACE_CEILF instead of
30687         HAVE_DECL_CEILF, REPLACE_CEILL instead of HAVE_DECL_CEILL,
30688         REPLACE_FLOORF instead of HAVE_DECL_FLOORF, REPLACE_FLOORL instead of
30689         HAVE_DECL_FLOORL.
30690
30691 2007-10-28  Bruno Haible  <bruno@clisp.org>
30692
30693         * m4/floorl.m4 (gl_FUNC_FLOORL_LIBS): New macro, extracted from
30694         gl_FUNC_FLOORL. Cache the result.
30695         (gl_FUNC_FLOORL): Use it.
30696         * m4/ceill.m4 (gl_FUNC_CEILL_LIBS): New macro, extracted from
30697         gl_FUNC_CEILL. Cache the result.
30698         (gl_FUNC_CEILL): Use it.
30699
30700         * m4/floor.m4 (gl_FUNC_FLOOR_LIBS): New macro, extracted from
30701         gl_FUNC_FLOOR. Cache the result.
30702         (gl_FUNC_FLOOR): Use it.
30703         * m4/ceil.m4 (gl_FUNC_CEIL_LIBS): New macro, extracted from
30704         gl_FUNC_CEIL. Cache the result.
30705         (gl_FUNC_CEIL): Use it.
30706
30707         * m4/floorf.m4 (gl_FUNC_FLOORF_LIBS): New macro, extracted from
30708         gl_FUNC_FLOORF. Cache the result.
30709         (gl_FUNC_FLOORF): Use it.
30710         * m4/ceilf.m4 (gl_FUNC_CEILF_LIBS): New macro, extracted from
30711         gl_FUNC_CEILF. Cache the result.
30712         (gl_FUNC_CEILF): Use it.
30713
30714 2007-10-28  Bruno Haible  <bruno@clisp.org>
30715
30716         * gnulib-tool: Allow specifying the LGPL version number through
30717         --lgpl=2 or --lgpl=3.
30718         (func_usage): Document --lgpl with argument.
30719         Handle --lgpl=... arguments.
30720         (func_import): Recognize also gl_LGPL calls with an argument. When
30721         --lgpl=2 is used and the module's license is just LGPL, report an
30722         error. Set sed_transform_lib_file according to the lgpl variable. In
30723         the generated files, use --lgpl or gl_LGPL invocations with argument,
30724         if necessary.
30725         * doc/gnulib-intro.texi (Copyright): Explain how to get modules under
30726         an LGPv2+ license.
30727         * doc/gnulib-tool.texi (Modified imports): Update explanation of
30728         gl_LGPL macro.
30729
30730 2007-10-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30731             Bruno Haible  <bruno@clisp.org>
30732
30733         * lib/unistr.h (u8_uctomb_aux): Declare also if !HAVE_INLINE.
30734         (u16_uctomb_aux): Likewise.
30735         * lib/unistr/u8-uctomb-aux.c (u8_uctomb_aux): Define also if
30736         !HAVE_INLINE.
30737         * lib/unistr/u16-uctomb-aux.c (u16_uctomb_aux): Likewise
30738
30739 2007-10-28  Bruno Haible  <bruno@clisp.org>
30740
30741         * modules/error: Add a notice recommending to change XGETTEXT_OPTIONS.
30742         Invoke AM_GETTEXT_OPTION if it exists.
30743         * modules/vasprintf: Likewise.
30744         * modules/verror: Likewise.
30745         * modules/xprintf: Likewise.
30746         * modules/xvasprintf: Likewise.
30747
30748 2007-10-27  Ben Pfaff  <blp@gnu.org>
30749
30750         * lib/math.in.h: Define isfinite macro and prototypes for
30751         gl_isfinitef, gl_isfinited, gl_isfinitel if we are providing
30752         implementations.
30753         * m4/math_h.m4: New substitutions for isfinite module.
30754         * lib/isfinite.c: New file.
30755         * m4/isfinite.m4: New file.
30756         * modules/math: Replace isfinite-related @VARS@ in math.in.h.
30757         * modules/isfinite: New file.
30758         * modules/isfinite-tests: New file.
30759         * tests/tests-isfinite.c: New file.
30760         * doc/functions/isfinite.texi: Mention isfinite module.
30761         * MODULES.html.sh: Mention new module.
30762
30763 2007-10-27  Ben Pfaff  <blp@gnu.org>
30764
30765         Ralf Wildenhues reported that Tru64 4.0D declares the round
30766         functions but does not have definitions.
30767         * m4/check-math-lib.m4 (gl_CHECK_MATH_LIB): If the target function
30768         cannot be found in any library, set the output variable to
30769         "missing" instead of "".
30770         * m4/round.m4: Also use our substitute if we cannot find round in
30771         any library, even if it is declared.
30772         * m4/roundf.m4: Likewise for roundf.
30773         * m4/roundl.m4: Likewise for roundl.
30774         * lib/math.in.h: Undefine roundf, round, roundl before defining
30775         their replacements, to allow for hypothetical systems where these
30776         may be defined as macros but not available in libraries.
30777
30778 2007-10-27  Bruno Haible  <bruno@clisp.org>
30779
30780         * doc/gnulib.texi: Invoke @firstparagraphindent.
30781         * doc/gnulib-tool.texi (Simple update): Mention possible incompatible
30782         changes in gnulib.
30783         (Source changes): New section.
30784
30785 2007-10-26  Bruno Haible  <bruno@clisp.org>
30786
30787         * m4/gnulib-common.m4 (AC_C_RESTRICT): New overriding definition,
30788         borrowed from autoconf.
30789
30790 2007-10-26  Bruno Haible  <bruno@clisp.org>
30791
30792         * lib/strerror.c (rpl_strerror): Return "Unknown error ..." also if
30793         strerror returned the empty string. Needed on HP-UX 11.00.
30794
30795 2007-10-24  Micah Cowan  <micah@cowan.name>
30796
30797         Remove vestiges of cvs-gnulib-checkout process.  Now we use git.
30798         * build-aux/bootstrap: Remove support for now-unnecessary option,
30799         --cvs-user, and envvars CVS_USER, CVS_RSH.
30800
30801 2007-10-24  Jim Meyering  <meyering@redhat.com>
30802
30803         Avoid diagnostics from sha1sum when there is no cached checksum.
30804         * build-aux/bootstrap (update_po_files): Skip the sha1sum check
30805         if the po.s1 file hasn't been created yet.
30806
30807         * build-aux/bootstrap: Sync from coreutils:
30808         2007-10-24  Jim Meyering  <meyering@redhat.com>
30809         Get gnulib from the git repository, not from an obsolete cvs one.
30810         * build-aux/bootstrap: Suggestion from Micah Cowan.
30811         2007-10-04  Jim Meyering  <jim@meyering.net>
30812         * build-aux/bootstrap (slurp): Adapt to _.h -> .in.h name change.
30813         (update_po_files): Work also when there are no .po files in po/.
30814
30815 2007-10-24  Paul Eggert  <eggert@cs.ucla.edu>
30816
30817         * README: Append ".git" to git and cg examples.
30818         Problem reported by Benoit Sigoure.
30819
30820 2007-10-23  Micah Cowan  <micah@cowan.name>
30821
30822         * users.txt: Add wget.
30823
30824 2007-10-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30825
30826         Fix linking of some unistdio tests on FreeBSD.
30827         * modules/unistdio/u16-vsnprintf-tests
30828         (test_u16_vsprintf1_LDADD): Add @LIBINTL@.
30829         * modules/unistdio/u16-vsprintf-tests
30830         (test_u16_vsnprintf1_LDADD): Likewise.
30831         * modules/unistdio/u32-vsnprintf-tests
30832         (test_u32_vsnprintf1_LDADD): Likewise.
30833         * modules/unistdio/u32-vsprintf-tests
30834         (test_u32_vsprintf1_LDADD): Likewise.
30835         * modules/unistdio/u8-vsnprintf-tests
30836         (test_u8_vsnprintf1_LDADD): Likewise.
30837         * modules/unistdio/u8-vsprintf-tests
30838         (test_u8_vsprintf1_LDADD): Likewise.
30839         * modules/unistdio/ulc-vsnprintf-tests
30840         (test_ulc_vsnprintf1_LDADD): Likewise.
30841         * modules/unistdio/ulc-vsprintf-tests
30842         (test_ulc_vsprintf1_LDADD): Likewise.
30843
30844         Fix linking of some uniconv tests on FreeBSD.
30845         * modules/uniconv/u16-conv-from-enc-tests
30846         (test_u16_conv_from_enc_LDADD): Link $(LDADD) before @LIBICONV@.
30847         * modules/uniconv/u16-conv-to-enc-tests
30848         (test_u16_conv_to_enc_LDADD): Likewise.
30849         * modules/uniconv/u16-strconv-from-enc-tests
30850         (test_u16_strconv_from_enc_LDADD): Likewise.
30851         * modules/uniconv/u16-strconv-to-enc-tests
30852         (test_u16_strconv_to_enc_LDADD): Likewise.
30853         * modules/uniconv/u32-conv-from-enc-tests
30854         (test_u32_conv_from_enc_LDADD): Likewise.
30855         * modules/uniconv/u32-conv-to-enc-tests
30856         (test_u32_conv_to_enc_LDADD): Likewise.
30857         * modules/uniconv/u32-strconv-from-enc-tests
30858         (test_u32_strconv_from_enc_LDADD): Likewise.
30859         * modules/uniconv/u32-strconv-to-enc-tests
30860         (test_u32_strconv_to_enc_LDADD): Likewise.
30861         * modules/uniconv/u8-conv-from-enc-tests
30862         (test_u8_conv_from_enc_LDADD): Likewise.
30863         * modules/uniconv/u8-conv-to-enc-tests
30864         (test_u8_conv_to_enc_LDADD): Likewise.
30865         * modules/uniconv/u8-strconv-from-enc-tests
30866         (test_u8_strconv_from_enc_LDADD): Likewise.
30867         * modules/uniconv/u8-strconv-to-enc-tests
30868         (test_u8_strconv_to_enc_LDADD): Likewise.
30869
30870 2007-10-22  Bruno Haible  <bruno@clisp.org>
30871
30872         * lib/stdint.in.h: Add check that intmax_t and uintmax_t have the same
30873         size.
30874
30875 2007-10-22  Eric Blake  <ebb9@byu.net>
30876
30877         Tweak x*printf documentation.
30878         * lib/xprintf.c (xprintf, xvprintf, xfprintf, xvfprintf): Adjust
30879         variable name and comments.
30880         Suggested by Bruno Haible.
30881
30882 2007-10-22  Bruno Haible  <bruno@clisp.org>
30883
30884         * lib/acl.c (copy_acl): Fix file name in comment.
30885
30886 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
30887
30888         Fix Tru64 problem with stdbool.h.
30889         * lib/stdbool.in.h (false, true):
30890         [! (defined __cplusplus || defined __BEOS__) && !defined __GNUC__]:
30891         Don't declare as an enum in this situation; it runs afoul of Tru64.
30892         Problem reported by Steven M. Schweda in
30893         <http://lists.gnu.org/archive/html/bug-autoconf/2007-10/msg00019.html>.
30894
30895 2007-10-22  Eric Blake  <ebb9@byu.net>
30896
30897         Also wrap vf?printf.
30898         * lib/xprintf.h (xvprintf, xvfprintf): New declarations.
30899         * lib/xprintf.c (xprintf, xfprintf): Work for C89.
30900         (xvprintf, xvfprintf): New functions.
30901
30902 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30903
30904         * modules/fstrcmp-tests (test_fstrcmp_LDADD): New, add
30905         @LIBINTL@ for FreeBSD 6.2, $(LIBTHREAD) for AIX 4.3.3.
30906
30907         * lib/uniconv/u16-conv-to-enc.c (U_MBLEN): Define.
30908         * lib/uniconv/u32-conv-to-enc.c (U_MBLEN): Likewise.
30909
30910 2007-10-22  Paul Eggert  <eggert@cs.ucla.edu>
30911
30912         * lib/acl.c (copy_acl): Adjust to IRIX 6.5.  Problem reported
30913         by Bruno Haible.
30914
30915 2007-10-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
30916
30917         * lib/getloadavg.c
30918         [defined (__osf__) && (defined (__alpha) || defined (__alpha__)]:
30919         Undef `sys' after including sys/table.h, for Tru64 4.0D.
30920
30921         * tests/test-i-ring.c: Work for C89.
30922
30923 2007-10-22  Bruno Haible  <bruno@clisp.org>
30924
30925         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Use -1ull, not
30926         -1u, in preprocessor expression, so that we don't test for the bug
30927         in HP-UX 11.00 cpp.  Testing for this bug caused problems; see
30928         <http://lists.gnu.org/archive/html/bug-gnulib/2007-10/msg00329.html>.
30929
30930 2007-10-22  Eric Blake  <ebb9@byu.net>
30931
30932         * tests/test-yesno.sh: Silence stderr during test.
30933
30934 2007-10-22  Simon Josefsson  <simon@josefsson.org>
30935
30936         * modules/crypto/gc-camellia: New file.
30937
30938         * m4/gc-camellia.m4: New file.
30939
30940         * lib/gc-libgcrypt.c (gc_cipher_open): Support Camellia.
30941
30942         * lib/gc.h (enum Gc_cipher): Add GC_CAMELLIA128, GC_CAMELLIA256.
30943
30944 2007-10-22  Simon Josefsson  <simon@josefsson.org>
30945
30946         * build-aux/maint.mk (gzip_rsyncable): Don't fail if gzip sends
30947         --help to stdout.  Reported by sms@antinode.org (Steven
30948         M. Schweda).
30949
30950 2007-10-22  Simon Josefsson  <simon@josefsson.org>
30951
30952         * users.txt: Fix link to libksba.
30953
30954 2007-10-21  Ben Pfaff  <blp@gnu.org>
30955
30956         * modules/roundf-tests: Add dependency on floorf, ceilf to allow
30957         round.c roundf implementation that depends on floorf and ceilf to
30958         be tested unconditionally.
30959
30960 2007-10-21  Ben Pfaff  <blp@gnu.org>
30961
30962         * m4/check-libm-func.m4: Removed.
30963         * m4/check-math-lib.m4: New file.
30964         * m4/round.m4: Rewrite to use gl_CHECK_MATH_LIB.
30965         * m4/roundf.m4: Ditto, and fix lack of HAVE_DECL_ROUNDF
30966         definition and lack of AC_LIBOBJ([roundf]).
30967         * m4/roundl.m4: Ditto, and similarly for roundl.
30968         * modules/round: Reference new m4 file.
30969         * modules/roundf: Ditto.
30970         * modules/roundl: Ditto.
30971         * tests/test-round2.c (main): Use ROUND instead of round.
30972         Bug report from Bruno Haible.
30973
30974 2007-10-21  Bruno Haible  <bruno@clisp.org>
30975
30976         * lib/printf-parse.c: Don't assume <stdint.h> exists in IN_LIBASPRINTF
30977         context.
30978
30979 2007-10-21  Bruno Haible  <bruno@clisp.org>
30980
30981         * tests/test-wcwidth.c (main): Allow negative result for some control
30982         characters.
30983
30984         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Check also the width of U+200B.
30985         Needed on OSF/1 5.1.
30986
30987 2007-10-21  Bruno Haible  <bruno@clisp.org>
30988
30989         * tests/test-floorf1.c: Include isnanf.h.
30990         (main): Use isnanf() instead of isnan().
30991         * tests/test-ceilf1.c: Include isnanf.h.
30992         (main): Use isnanf() instead of isnan().
30993         * tests/test-truncf1.c: Include isnanf.h.
30994         (main): Use isnanf() instead of isnan().
30995         * tests/test-roundf1.c: Include isnanf.h.
30996         (main): Use isnanf() instead of isnan().
30997
30998 2007-10-21  Eric Blake  <ebb9@byu.net>
30999
31000         * users.txt: Update URL for m4.
31001
31002 2007-10-21  Bruno Haible  <bruno@clisp.org>
31003
31004         * users.txt: Add clisp. Update URLs to Simon Josefsson's projects.
31005
31006 2007-10-21  Bruno Haible  <bruno@clisp.org>
31007
31008         * gnulib-tool (func_create_megatestdir): Determine the cvsdate from
31009         Git's management files if the CVS files are not present.
31010
31011 2007-10-20  Bruno Haible  <bruno@clisp.org>
31012
31013         * lib/count-one-bits.h (COUNT_ONE_BITS): Use the builtin also for
31014         gcc-3.4.x.
31015
31016 2007-10-20  Ben Pfaff  <blp@gnu.org>
31017
31018         * lib/math.in.h: Declare round, roundf, roundl if we are providing
31019         implementations.
31020         * m4/math_h.m4: New substitutions for round, roundf, roundl modules.
31021         * lib/round.c: New file.
31022         * lib/roundf.c: New file.
31023         * lib/roundl.c: New file.
31024         * m4/round.m4: New file.
31025         * m4/roundf.m4: New file.
31026         * m4/roundl.m4: New file.
31027         * m4/check-libm-func-m4: New file.
31028         * modules/math: Replace round, roundf, roundl related @VARS@ in
31029         math.in.h.
31030         * modules/round: New file.
31031         * modules/round-tests: New file.
31032         * modules/roundf: New file.
31033         * modules/roundf-tests: New file.
31034         * modules/roundl: New file.
31035         * modules/roundl-tests: New file.
31036         * tests/test-round1.c: New file.
31037         * tests/test-round2.c: New file.
31038         * tests/test-roundf1.c: New file.
31039         * tests/test-roundf2.c: New file.
31040         * tests/test-roundl.c: New file.
31041         * doc/functions/round.texi: Mention round module.
31042         * doc/functions/roundf.texi: Mention roundf module.
31043         * doc/functions/roundl.texi: Mention roundl module.
31044         * MODULES.html.sh: Mention new modules.
31045         Thanks to Bruno Haible for suggestions.
31046
31047 2007-10-20  Jim Meyering  <meyering@redhat.com>
31048
31049         * lib/xprintf.c: Include <config.h> unconditionally.
31050
31051         Change xprintf's license to GPL.
31052         * modules/xprintf (License): s/LGPL/GPL/, since this module
31053         depends on modules (exit and exitfail) which are GPL.
31054         Suggestion from Bruno Haible.
31055
31056         xprintf fixes.
31057         * lib/xprintf.c (xprintf, xfprintf): Use va_end.
31058         Use a clearer diagnostic.
31059         Patch from Bruno Haible.
31060
31061 2007-10-20  Bruno Haible  <bruno@clisp.org>
31062
31063         * lib/vasnprintf.c (VASNPRINTF): Don't report overflow if the available
31064         length is INT_MAX and sizeof (DCHAR_T) > sizeof (TCHAR_T).
31065         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
31066
31067 2007-10-20  Bruno Haible  <bruno@clisp.org>
31068
31069         * tests/test-floorf2.c (correct_result_p): Don't rely on excess
31070         precision in the comparison result > x - 1 or similar.
31071         * tests/test-ceilf2.c (correct_result_p): Likewise.
31072         * tests/test-truncf2.c (correct_result_p): Likewise.
31073         * tests/test-trunc2.c (correct_result_p): Likewise.
31074         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
31075
31076 2007-10-20  Bruno Haible  <bruno@clisp.org>
31077
31078         * modules/ceil: New file.
31079         * m4/ceil.m4: New file.
31080         * doc/functions/ceil.texi: Mention the 'ceil' module.
31081
31082 2007-10-20  Bruno Haible  <bruno@clisp.org>
31083
31084         * modules/floor: New file.
31085         * m4/floor.m4: New file.
31086         * doc/functions/floor.texi: Mention the 'floor' module.
31087
31088 2007-10-20  Bruno Haible  <bruno@clisp.org>
31089
31090         * modules/ceilf-tests (Depends-on): Add fprintf-posix. Needed for use
31091         of %a.
31092         * modules/floorf-tests (Depends-on): Likewise.
31093         * modules/truncf-tests (Depends-on): Likewise.
31094         * modules/trunc-tests (Depends-on): Likewise.
31095         Reported by Ben Pfaff.
31096
31097 2007-10-19  Jim Meyering  <meyering@redhat.com>
31098
31099         * lib/xprintf.c (xprintf, xfprintf): Test err < 0, not just "err".
31100         Don't bother testing specific errno values.  Just test ferror.
31101
31102         New module: xprintf
31103         * modules/xprintf, lib/xprintf.c, lib/xprintf.h: New files.
31104
31105 2007-10-19  Bruno Haible  <bruno@clisp.org>
31106
31107         * modules/csharpexec (Makefile.am): Use @FOO@ syntax instead of $(FOO)
31108         syntax.
31109         * modules/javaexec (Makefile.am): Likewise.
31110         * modules/relocatable-prog (Makefile.am): Likewise.
31111         Suggested by Jim Meyering.
31112
31113 2007-10-18  Bruno Haible  <bruno@clisp.org>
31114
31115         * lib/vasnprintf.c (VASNPRINTF): Don't use %n on glibc >= 2.3 systems.
31116         Reported by Jim Meyering.
31117
31118 2007-10-18  Eric Blake  <ebb9@byu.net>
31119
31120         * modules/filenamecat-tests (Makefile.am): Link against -lintl.
31121
31122 2007-10-18  Bruno Haible  <bruno@clisp.org>
31123
31124         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_N, gl_SNPRINTF_DIRECTIVE_N): Put
31125         the format string into writable memory. Needed in Fortify conditions.
31126
31127 2007-10-18  Colin Watson <cjwatson@debian.org>  (tiny change)
31128             Bruno Haible  <bruno@clisp.org>
31129
31130         * lib/trim.c: Include config.h unconditionally. Include trim.h always.
31131         Include ctype.h always. Include stdlib.h, not mbuiter.h, for MB_CUR_MAX.
31132         * modules/trim (Depends-on): Add mbchar.
31133         (configure.ac): Add gl_FUNC_MBRTOWC.
31134         (Makefile.am): Augment lib_SOURCES.
31135
31136 2007-10-17  Paul Eggert  <eggert@cs.ucla.edu>
31137
31138         Modify glob.c to use fstatat and dirfd, to simplify it.
31139         Suggested by Eric Blake.
31140         * lib/glob.c (__fxstatat64) [!_LIBC]: New macro.
31141         Don't include <stdbool.h>; not used.
31142         (link_exists2_p, glob_in_dir) [!_LIBC]: No longer a special case.
31143         (link_exists_p): Simplify implementation, since we can now assume
31144         dirfd and fstatat.
31145         * modules/glob (Depends-on): Add dirfd, openat.  Remove stdbool.
31146
31147 2007-10-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
31148
31149         * gnulib-tool (func_get_dependencies): Fix sed script to
31150         match only tests.
31151
31152 2007-10-17  Bruno Haible  <bruno@clisp.org>
31153
31154         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): On Cygwin, don't
31155         allow locale names without encoding suffix.
31156         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): Likewise.
31157         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
31158
31159 2007-10-16  Bruno Haible  <bruno@clisp.org>
31160
31161         * lib/getcwd.c (__getcwd): Define with explicit rpl_ prefix.
31162         * lib/getgroups.c (getgroups): Likewise.
31163         * lib/gettimeofday.c (localtime, gmtime, tzset): Likewise.
31164
31165 2007-10-16  Bruno Haible  <bruno@clisp.org>
31166
31167         * modules/absolute-header (License): Change from LGPL to LGPLv2+.
31168         * modules/malloc-posix (License): Likewise.
31169         * modules/realloc-posix (License): Likewise.
31170         * modules/calloc-posix (License): Likewise.
31171         * modules/intprops (License): Change from GPL to LGPL, with
31172         Paul Eggert's approval.
31173
31174 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
31175
31176         Merge glibc changes into lib/glob.c.
31177
31178         * lib/glob.c (glob_in_dir): Sync with glibc/posix/glob.c, dated
31179         2007-10-15 04:59:03 UTC.  Here are the changes:
31180
31181         2007-10-14  Ulrich Drepper  <drepper@redhat.com>
31182
31183         * lib/glob.c: Reimplement link_exists_p to use fstatat64.
31184
31185         * lib/glob.c: Add some branch prediction throughout.
31186
31187         2007-10-07  Ulrich Drepper  <drepper@redhat.com>
31188
31189         [BZ #5103]
31190         * lib/glob.c (glob): Recognize patterns starting \/.
31191
31192         2007-02-14  Jakub Jelinek  <jakub@redhat.com>
31193
31194         [BZ #3996]
31195         * lib/glob.c (attribute_hidden): Define if not defined.
31196         (glob): Unescape dirname, filename or username when needed and not
31197         GLOB_NOESCAPE.  Handle \/ correctly.  Handle GLOB_MARK if filename
31198         is NULL.  Handle unescaped [ in pattern without closing ].
31199         Don't pass GLOB_CHECK down to recursive glob for directories.
31200         (__glob_pattern_type): New function.
31201         (__glob_pattern_p): Implement using __glob_pattern_type.
31202         (glob_in_dir): Handle GLOB_NOCHECK patterns containing no meta
31203         characters and backslashes if not GLOB_NOESCAPE or unterminated [.
31204         Remove unreachable code.
31205
31206         2006-09-30  Ulrich Drepper  <drepper@redhat.com>
31207
31208         * lib/glob.c (glob_in_dir): Add some comments and asserts to
31209         explain why there are no leaks.
31210
31211         2006-09-25  Jakub Jelinek  <jakub@redhat.com>
31212
31213         [BZ #3253]
31214         * lib/glob.c (glob_in_dir): Don't alloca one struct globlink at a
31215         time, rather allocate increasingly bigger arrays of pointers, if
31216         possible with alloca, if too large with malloc.
31217
31218 2007-10-16  Paul Eggert  <eggert@cs.ucla.edu>
31219
31220         Check for 64-bit int errors in HP-UX 10.20 preprocessor.
31221         Problem reported by H.Merijn Brand in
31222         <http://lists.gnu.org/archive/html/bug-tar/2007-10/msg00018.html>.
31223         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Check preprocessor too.
31224         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
31225
31226 2007-10-15  Bruno Haible  <bruno@clisp.org>
31227
31228         * lib/fchdir.c (close, open, closedir, opendir, dup, dup2): Define
31229         with explicit rpl_ prefix.
31230         * lib/fopen.c (fopen): Likewise.
31231         * lib/freopen.c (freopen): Likewise.
31232         * lib/iconv.c (iconv): Likewise.
31233         * lib/iconv_close.c (iconv_close): Likewise.
31234
31235 2007-10-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
31236
31237         * m4/iconv_open (gl_FUNC_ICONV_OPEN_UTF): Fix cache variable name.
31238
31239 2007-10-15  Bruno Haible  <bruno@clisp.org>
31240
31241         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Use
31242         <stddef.h> instead of <stdlib.h> since we only need NULL.
31243         Reported by Ben Pfaff <blp@cs.stanford.edu>.
31244
31245 2007-10-15  Bruno Haible  <bruno@clisp.org>
31246
31247         * doc/gnulib-tool.texi (Initial import): Swap order of -I directives.
31248         Replace paragraph talking about LIBOBJS.
31249         Reported by Colin Watson <cjwatson@debian.org>.
31250
31251 2007-10-15  Bruno Haible  <bruno@clisp.org>
31252
31253         * m4/getaddrinfo.m4 (gl_GETADDRINFO, gl_PREREQ_GETADDRINFO): Include
31254         <stdlib.h> before using NULL.
31255
31256 2007-10-15  Simon Josefsson  <simon@josefsson.org>
31257
31258         * m4/getaddrinfo.m4: Use NULL rather than 0 for pointers.
31259         Reported by Albert Chin <china@thewrittenword.com>.
31260
31261 2007-10-14  Bruno Haible  <bruno@clisp.org>
31262
31263         * modules/iconv_open-utf-tests: New file.
31264         * tests/test-iconv-utf.c: New file.
31265
31266         Enhance iconv_open to support UTF-16BE, UTF-16LE, UTF-32BE, UTF-32LE.
31267         * modules/iconv_open-utf: New file.
31268         * lib/iconv.in.h (_ICONV_UTF8_UTF*, _ICONV_UTF*_UTF8): New macros.
31269         (iconv, iconv_close): New declarations.
31270         * lib/iconv_open.c: Include c-strcase.h. Don't require ICONV_FLAVOR to
31271         be defined.
31272         (iconv_open): Add special handling of conversion between UTF-8 and
31273         UTF-{16,32}{BE,LE}.
31274         * lib/iconv.c: New file, incorporating code from GNU libiconv 1.11.
31275         * lib/iconv_close.c: New file.
31276         * m4/iconv_open.m4 (gl_REPLACE_ICONV_OPEN): New macro, extracted from
31277         gl_FUNC_ICONV_OPEN.
31278         (gl_FUNC_ICONV_OPEN): Use it.
31279         (gl_FUNC_ICONV_OPEN_UTF): New macro.
31280         * m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Initialize also REPLACE_ICONV
31281         and REPLACE_ICONV_UTF.
31282         * modules/iconv_open (Depends-on): Add c-strcase.
31283         (Makefile.am): Substitute also REPLACE_ICONV, REPLACE_ICONV_UTF,
31284         ICONV_CONST.
31285         * doc/functions/iconv_open.texi: Mention the iconv_open-utf module.
31286
31287 2007-10-13  Albert Chin  <china@thewrittenword.com>
31288             Bruno Haible  <bruno@clisp.org>
31289
31290         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Perform the test for getaddrinfo
31291         through a link check that includes <netdb.h>. Needed for OSF/1 5.1.
31292
31293 2007-10-13  Bruno Haible  <bruno@clisp.org>
31294
31295         * lib/argp-fmtstream.h (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is
31296         defined, use the ISO C99 inline semantics.
31297         * lib/argp.h (ARGP_EI): Likewise.
31298
31299 2007-10-13  Bruno Haible  <bruno@clisp.org>
31300
31301         Handle 'inline' change in gcc 4.3.0.
31302         * lib/argp-fmtstream.h (argp_fmtstream_putc, argp_fmtstream_puts,
31303         argp_fmtstream_write, argp_fmtstream_set_lmargin,
31304         argp_fmtstream_set_rmargin, argp_fmtstream_set_wmargin,
31305         argp_fmtstream_point): Disable 'extern' declaration if the function
31306         definition is going to be provided inline.
31307         (ARGP_FS_EI): If __GNUC_STDC_INLINE__ is defined, use the GNU C inline
31308         semantics, not the ISO C99 inline semantics.
31309         * lib/argp.h (argp_usage, _option_is_short, _option_is_end): Disable
31310         'extern' declaration if the function definition is going to be provided
31311         inline.
31312         (ARGP_EI): Don't assume GNU C. If __GNUC_STDC_INLINE__ is defined, use
31313         the GNU C inline semantics, not the ISO C99 inline semantics. With
31314         GCC 4.2, avoid a warning.
31315
31316 2007-10-13  Bruno Haible  <bruno@clisp.org>
31317
31318         * lib/freading.h (freading): Enable the use of __freading for
31319         glibc >= 2.7.
31320         * lib/freading.c (freading): Likewise.
31321
31322 2007-10-12  Paul Eggert  <eggert@cs.ucla.edu>
31323
31324         * lib/argp-fmtstream.h (ARGP_FS_EI): Work around GCC 4.2.1 diagnostic
31325         "warning: C99 inline functions are not supported; using GNU89".
31326
31327 2007-10-12  Bruno Haible  <bruno@clisp.org>
31328
31329         * lib/ceil.c (FUNC): Avoid rounding errors for values near a power
31330         of 2.
31331         * tests/test-ceilf2.c: New file.
31332         * modules/ceilf-tests: (Files, Depends-on, Makefile.am): Add new test.
31333
31334         * tests/test-ceilf1.c: Renamed from tests/test-ceilf.c.
31335         * modules/ceilf-tests: Update.
31336
31337 2007-10-12  Bruno Haible  <bruno@clisp.org>
31338
31339         * lib/floor.c (FUNC): Avoid rounding errors for values near a power
31340         of 2.
31341         * tests/test-floorf2.c: New file.
31342         * modules/floorf-tests: (Files, Depends-on, Makefile.am): Add new test.
31343
31344         * tests/test-floorf1.c: Renamed from tests/test-floorf.c.
31345         * modules/floorf-tests: Update.
31346
31347 2007-10-12  Bruno Haible  <bruno@clisp.org>
31348
31349         * tests/test-trunc2.c: New file.
31350         * modules/trunc-tests: (Files, Depends-on, Makefile.am): Add new test.
31351
31352         * tests/test-trunc1.c: Renamed from tests/test-trunc.c.
31353         * modules/trunc-tests: Update.
31354
31355 2007-10-12  Bruno Haible  <bruno@clisp.org>
31356
31357         * lib/trunc.c (FUNC): Avoid rounding errors for values near a power
31358         of 2.
31359         * tests/test-truncf2.c: New file.
31360         * modules/truncf-tests: (Files, Depends-on, Makefile.am): Add new test.
31361
31362         * tests/test-truncf1.c: Renamed from tests/test-truncf.c.
31363         * modules/truncf-tests: Update.
31364
31365 2007-10-11  Eric Blake  <ebb9@byu.net>
31366
31367         Don't claim strerror is broken on Interix.
31368         * doc/functions/strerror.texi (strerror): Known broken systems are
31369         now Solaris 8, and not Interix.
31370         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): No longer filter out
31371         Interix on cross-compile.
31372         Reported by Martin Koeppe in
31373         http://lists.gnu.org/archive/html/bug-gnulib/2007-10/msg00005.html.
31374
31375 2007-10-11  Bruno Haible  <bruno@clisp.org>
31376
31377         * modules/i-ring-tests: New file.
31378         * tests/test-i-ring.c: Renamed from lib/i-ring-test.c. Use ASSERT
31379         instead of assert.
31380
31381 2007-10-11  Bruno Haible  <bruno@clisp.org>
31382
31383         * modules/filenamecat-tests: New file.
31384         * tests/test-filenamecat.c: New file, extracted from lib/filenamecat.c.
31385         * lib/filenamecat.c: Remove test code.
31386
31387 2007-10-11  Paul Eggert  <eggert@cs.ucla.edu>
31388
31389         Simplify and modernize strerror substitute, partly to fix Solaris 8 bug.
31390
31391         * lib/strerror.c: Include <string.h> always, to test interface,
31392         and to remove the need for the dummy.
31393         Include intprops.h to compute width instead of doing it ourselves
31394         and missing a CHAR_BIT declaration, which broke tar 1.19 on Solaris 8.
31395         (strerror): Define it to return NULL if there's no system strerror.
31396         (rpl_strerror): Use INT_STRLEN_BOUND to compute bound.
31397         Omit !HAVE_STRERROR code.  We don't need to worry about supporting
31398         ancient pre-strerror Unix systems well any more.  Saying "unknown
31399         system error" is enough.
31400         * lib/string.in.h (strerror): Simplify the ifdef to reflect the
31401         simpler strerror.c implementation.
31402         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE, gl_PREREQ_STDERROR):
31403         Simplify the tests to reflect the simpler strerror implementation.
31404         * modules/strerror (Depends-on): Add intprops.
31405
31406 2007-10-09  Eric Blake  <ebb9@byu.net>
31407
31408         Silence test-fpending.
31409         * modules/fpending-tests (Files): Add wrapper script.
31410         * tests/test-fpending.sh: New file.
31411
31412 2007-10-09  Bruno Haible  <bruno@clisp.org>
31413
31414         * MODULES.html.sh (func_module): Don't create a hyperlink for
31415         function names like 'printf_frexp'.
31416         (Misc): Add crc, memxor.
31417         (Characteristics of floating types): New section.
31418         (Mathematics): Add ceilf, ceill, floorf, floorl, frexpl-nolibm,
31419         isnanf-nolibm, signbit, trunc, truncf, truncl.
31420         (Enhancements for ISO C 99 functions): New subsection Input/output.
31421         (Support for systems lacking POSIX:2001): Add arpa_inet, calloc-posix,
31422         fcntl, fopen, freopen, fseek, fseeko, ftell, ftello, iconv_open,
31423         locale, malloc-posix, netinet_in, open, realloc-posix, signal, sleep.
31424         (Compatibility checks for POSIX:2001 functions): Add clock-time.
31425         (Enhancements for POSIX:2001 functions): Add chdir-long.
31426         (File system functions): Add areadlink, chdir-safer, read-file.
31427         Remove cycle-check.
31428         (File system as inode set): New section.
31429         (Date and time): Add gethrxtime.
31430         (Multithreading): Add openmp.
31431         (Internationalization functions): Add localename.
31432         (Unicode string functions): Add unistr/u*-mbsnlen.
31433         (Support for maintaining and releasing projects): Add git-version-gen.
31434         (Lone files): Remove directories.
31435
31436 2007-10-08  Ben Pfaff  <blp@gnu.org>
31437
31438         * lib/xmalloca.h: Fix typo in comment.
31439
31440 2007-10-08  Paul Eggert  <eggert@cs.ucla.edu>
31441
31442         * lib/xnanosleep.c (xnanosleep): Don't assume GCC 4.3.0 behavior
31443         when avoiding problems with integer overflow.  Use a portable test
31444         instead.
31445
31446 2007-10-08  Simon Josefsson  <simon@josefsson.org>
31447
31448         * modules/dummy (License): Change to LGPLv2+.
31449         * modules/float (License): Likewise
31450         * modules/realloc (License): Likewise
31451         * modules/stdlib (License): Likewise
31452
31453 2007-10-07  Bruno Haible  <bruno@clisp.org>
31454
31455         * trunc.c (TWO_MANT_DIG): Change type to DOUBLE.
31456         * floor.c (TWO_MANT_DIG): Likewise.
31457         * ceil.c (TWO_MANT_DIG): Likewise.
31458         Reported by Ben Pfaff.
31459
31460 2007-10-07  Bruno Haible  <bruno@clisp.org>
31461
31462         Avoid gcc warnings "declaration of 'exp' shadows a global declaration".
31463         * lib/math.in.h (frexp, frexpl): Change parameter name to 'expptr'.
31464         * lib/frexp.c (FUNC): Likewise.
31465         * lib/printf-frexp.h (printf_frexp): Likewise.
31466         * lib/printf-frexpl.h (printf_frexpl): Likewise.
31467         * lib/printf-frexp.c (FUNC): Likewise.
31468         Suggested by Jim Meyering.
31469
31470 2007-10-07  Jim Meyering  <meyering@redhat.com>
31471
31472         Make xnanosleep's integer overflow test more robust.
31473         * lib/xnanosleep.c (xnanosleep): Declare a temporary to be "volatile",
31474         so that gcc-4.3.0 doesn't optimize away this test for overflow.
31475
31476 2007-10-07  Bruno Haible  <bruno@clisp.org>
31477
31478         * NEWS: Mention the license change.
31479
31480         * doc/gnulib-intro.texi (Copyright): Update the meaning of the license
31481         abbreviations in the modules files.
31482
31483         Change copyright notice from GPLv2+ to GPLv3+.
31484         * README: Change copyright notice.
31485         * MODULES.html.sh: Likewise.
31486         * build-aux/bootstrap.conf: Likewise.
31487         * build-aux/config.libpath: Likewise.
31488         * build-aux/csharpcomp.sh.in: Likewise.
31489         * build-aux/csharpexec.sh.in: Likewise.
31490         * build-aux/install-reloc: Likewise.
31491         * build-aux/javacomp.sh.in: Likewise.
31492         * build-aux/javaexec.sh.in: Likewise.
31493         * build-aux/ldd.sh.in: Likewise.
31494         * build-aux/reloc-ldflags: Likewise.
31495         * build-aux/relocatable.sh.in: Likewise.
31496         * build-aux/x-to-1.in: Likewise.
31497         * check-module: Likewise.
31498         * config/srclistvars.sh: Likewise.
31499         * gnulib-tool: Likewise.
31500         * lib/acl-internal.h: Likewise.
31501         * lib/acl.c: Likewise.
31502         * lib/acl.h: Likewise.
31503         * lib/acl_entries.c: Likewise.
31504         * lib/areadlink-with-size.c: Likewise.
31505         * lib/areadlink.c: Likewise.
31506         * lib/areadlink.h: Likewise.
31507         * lib/argmatch.c: Likewise.
31508         * lib/argmatch.h: Likewise.
31509         * lib/argp-ba.c: Likewise.
31510         * lib/argp-eexst.c: Likewise.
31511         * lib/argp-fmtstream.c: Likewise.
31512         * lib/argp-fmtstream.h: Likewise.
31513         * lib/argp-fs-xinl.c: Likewise.
31514         * lib/argp-help.c: Likewise.
31515         * lib/argp-namefrob.h: Likewise.
31516         * lib/argp-parse.c: Likewise.
31517         * lib/argp-pin.c: Likewise.
31518         * lib/argp-pv.c: Likewise.
31519         * lib/argp-pvh.c: Likewise.
31520         * lib/argp-xinl.c: Likewise.
31521         * lib/argp.h: Likewise.
31522         * lib/at-func.c: Likewise.
31523         * lib/atanl.c: Likewise.
31524         * lib/backupfile.c: Likewise.
31525         * lib/backupfile.h: Likewise.
31526         * lib/basename.c: Likewise.
31527         * lib/binary-io.h: Likewise.
31528         * lib/byteswap.in.h: Likewise.
31529         * lib/c-stack.c: Likewise.
31530         * lib/c-stack.h: Likewise.
31531         * lib/c-strcasestr.c: Likewise.
31532         * lib/c-strcasestr.h: Likewise.
31533         * lib/c-strstr.c: Likewise.
31534         * lib/c-strstr.h: Likewise.
31535         * lib/c-strtod.c: Likewise.
31536         * lib/calloc.c: Likewise.
31537         * lib/canon-host.c: Likewise.
31538         * lib/canon-host.h: Likewise.
31539         * lib/canonicalize-lgpl.c: Likewise.
31540         * lib/canonicalize.c: Likewise.
31541         * lib/canonicalize.h: Likewise.
31542         * lib/ceil.c: Likewise.
31543         * lib/ceilf.c: Likewise.
31544         * lib/ceill.c: Likewise.
31545         * lib/chdir-long.c: Likewise.
31546         * lib/chdir-long.h: Likewise.
31547         * lib/chdir-safer.c: Likewise.
31548         * lib/chdir-safer.h: Likewise.
31549         * lib/chown.c: Likewise.
31550         * lib/classpath.c: Likewise.
31551         * lib/classpath.h: Likewise.
31552         * lib/clean-temp.c: Likewise.
31553         * lib/clean-temp.h: Likewise.
31554         * lib/cloexec.c: Likewise.
31555         * lib/close-stream.c: Likewise.
31556         * lib/closein.c: Likewise.
31557         * lib/closein.h: Likewise.
31558         * lib/closeout.c: Likewise.
31559         * lib/closeout.h: Likewise.
31560         * lib/concat-filename.c: Likewise.
31561         * lib/copy-file.c: Likewise.
31562         * lib/copy-file.h: Likewise.
31563         * lib/count-one-bits.h: Likewise.
31564         * lib/crc.c: Likewise.
31565         * lib/crc.h: Likewise.
31566         * lib/creat-safer.c: Likewise.
31567         * lib/csharpcomp.c: Likewise.
31568         * lib/csharpcomp.h: Likewise.
31569         * lib/csharpexec.c: Likewise.
31570         * lib/csharpexec.h: Likewise.
31571         * lib/cycle-check.c: Likewise.
31572         * lib/cycle-check.h: Likewise.
31573         * lib/diacrit.c: Likewise.
31574         * lib/diacrit.h: Likewise.
31575         * lib/diffseq.h: Likewise.
31576         * lib/dirchownmod.c: Likewise.
31577         * lib/dirent.in.h: Likewise.
31578         * lib/dirfd.c: Likewise.
31579         * lib/dirfd.h: Likewise.
31580         * lib/dirname.c: Likewise.
31581         * lib/dirname.h: Likewise.
31582         * lib/dummy.c: Likewise.
31583         * lib/dup-safer.c: Likewise.
31584         * lib/dup2.c: Likewise.
31585         * lib/eealloc.h: Likewise.
31586         * lib/error.c: Likewise.
31587         * lib/error.h: Likewise.
31588         * lib/euidaccess.c: Likewise.
31589         * lib/exclude.c: Likewise.
31590         * lib/exclude.h: Likewise.
31591         * lib/execute.c: Likewise.
31592         * lib/execute.h: Likewise.
31593         * lib/exitfail.c: Likewise.
31594         * lib/exitfail.h: Likewise.
31595         * lib/expl.c: Likewise.
31596         * lib/fatal-signal.c: Likewise.
31597         * lib/fatal-signal.h: Likewise.
31598         * lib/fbufmode.c: Likewise.
31599         * lib/fbufmode.h: Likewise.
31600         * lib/fchdir.c: Likewise.
31601         * lib/fchmodat.c: Likewise.
31602         * lib/fchownat.c: Likewise.
31603         * lib/fcntl--.h: Likewise.
31604         * lib/fcntl-safer.h: Likewise.
31605         * lib/fcntl.in.h: Likewise.
31606         * lib/fd-safer.c: Likewise.
31607         * lib/fflush.c: Likewise.
31608         * lib/file-has-acl.c: Likewise.
31609         * lib/file-set.c: Likewise.
31610         * lib/file-type.c: Likewise.
31611         * lib/file-type.h: Likewise.
31612         * lib/fileblocks.c: Likewise.
31613         * lib/filemode.c: Likewise.
31614         * lib/filemode.h: Likewise.
31615         * lib/filename.h: Likewise.
31616         * lib/filenamecat.c: Likewise.
31617         * lib/filenamecat.h: Likewise.
31618         * lib/findprog.c: Likewise.
31619         * lib/findprog.h: Likewise.
31620         * lib/float.in.h: Likewise.
31621         * lib/floor.c: Likewise.
31622         * lib/floorf.c: Likewise.
31623         * lib/floorl.c: Likewise.
31624         * lib/fopen-safer.c: Likewise.
31625         * lib/fopen.c: Likewise.
31626         * lib/fpending.c: Likewise.
31627         * lib/fpending.h: Likewise.
31628         * lib/fprintf.c: Likewise.
31629         * lib/fprintftime.h: Likewise.
31630         * lib/fpucw.h: Likewise.
31631         * lib/fpurge.c: Likewise.
31632         * lib/fpurge.h: Likewise.
31633         * lib/freadable.c: Likewise.
31634         * lib/freadable.h: Likewise.
31635         * lib/freadahead.c: Likewise.
31636         * lib/freadahead.h: Likewise.
31637         * lib/freading.c: Likewise.
31638         * lib/freading.h: Likewise.
31639         * lib/free.c: Likewise.
31640         * lib/freopen.c: Likewise.
31641         * lib/frexp.c: Likewise.
31642         * lib/frexpl.c: Likewise.
31643         * lib/fseek.c: Likewise.
31644         * lib/fseterr.c: Likewise.
31645         * lib/fseterr.h: Likewise.
31646         * lib/fstatat.c: Likewise.
31647         * lib/fstrcmp.c: Likewise.
31648         * lib/fstrcmp.h: Likewise.
31649         * lib/fsusage.c: Likewise.
31650         * lib/fsusage.h: Likewise.
31651         * lib/ftell.c: Likewise.
31652         * lib/ftello.c: Likewise.
31653         * lib/fts-cycle.c: Likewise.
31654         * lib/fts.c: Likewise.
31655         * lib/fts_.h: Likewise.
31656         * lib/full-read.c: Likewise.
31657         * lib/full-read.h: Likewise.
31658         * lib/full-write.c: Likewise.
31659         * lib/full-write.h: Likewise.
31660         * lib/fwritable.c: Likewise.
31661         * lib/fwritable.h: Likewise.
31662         * lib/fwriteerror.c: Likewise.
31663         * lib/fwriteerror.h: Likewise.
31664         * lib/fwriting.c: Likewise.
31665         * lib/fwriting.h: Likewise.
31666         * lib/gcd.c: Likewise.
31667         * lib/gcd.h: Likewise.
31668         * lib/getcwd.c: Likewise.
31669         * lib/getdate.h: Likewise.
31670         * lib/getdate.y: Likewise.
31671         * lib/getdomainname.c: Likewise.
31672         * lib/getdomainname.h: Likewise.
31673         * lib/getgroups.c: Likewise.
31674         * lib/gethostname.c: Likewise.
31675         * lib/gethrxtime.c: Likewise.
31676         * lib/gethrxtime.h: Likewise.
31677         * lib/getloadavg.c: Likewise.
31678         * lib/getndelim2.c: Likewise.
31679         * lib/getndelim2.h: Likewise.
31680         * lib/getnline.c: Likewise.
31681         * lib/getnline.h: Likewise.
31682         * lib/getopt.c: Likewise.
31683         * lib/getopt.in.h: Likewise.
31684         * lib/getopt1.c: Likewise.
31685         * lib/getopt_int.h: Likewise.
31686         * lib/getpagesize.h: Likewise.
31687         * lib/getsubopt.c: Likewise.
31688         * lib/gettime.c: Likewise.
31689         * lib/getugroups.c: Likewise.
31690         * lib/getugroups.h: Likewise.
31691         * lib/getusershell.c: Likewise.
31692         * lib/gl_anyavltree_list1.h: Likewise.
31693         * lib/gl_anyavltree_list2.h: Likewise.
31694         * lib/gl_anyhash_list1.h: Likewise.
31695         * lib/gl_anyhash_list2.h: Likewise.
31696         * lib/gl_anylinked_list1.h: Likewise.
31697         * lib/gl_anylinked_list2.h: Likewise.
31698         * lib/gl_anyrbtree_list1.h: Likewise.
31699         * lib/gl_anyrbtree_list2.h: Likewise.
31700         * lib/gl_anytree_list1.h: Likewise.
31701         * lib/gl_anytree_list2.h: Likewise.
31702         * lib/gl_anytree_oset.h: Likewise.
31703         * lib/gl_anytreehash_list1.h: Likewise.
31704         * lib/gl_anytreehash_list2.h: Likewise.
31705         * lib/gl_array_list.c: Likewise.
31706         * lib/gl_array_list.h: Likewise.
31707         * lib/gl_array_oset.c: Likewise.
31708         * lib/gl_array_oset.h: Likewise.
31709         * lib/gl_avltree_list.c: Likewise.
31710         * lib/gl_avltree_list.h: Likewise.
31711         * lib/gl_avltree_oset.c: Likewise.
31712         * lib/gl_avltree_oset.h: Likewise.
31713         * lib/gl_avltreehash_list.c: Likewise.
31714         * lib/gl_avltreehash_list.h: Likewise.
31715         * lib/gl_carray_list.c: Likewise.
31716         * lib/gl_carray_list.h: Likewise.
31717         * lib/gl_linked_list.c: Likewise.
31718         * lib/gl_linked_list.h: Likewise.
31719         * lib/gl_linkedhash_list.c: Likewise.
31720         * lib/gl_linkedhash_list.h: Likewise.
31721         * lib/gl_list.c: Likewise.
31722         * lib/gl_list.h: Likewise.
31723         * lib/gl_oset.c: Likewise.
31724         * lib/gl_oset.h: Likewise.
31725         * lib/gl_rbtree_list.c: Likewise.
31726         * lib/gl_rbtree_list.h: Likewise.
31727         * lib/gl_rbtree_oset.c: Likewise.
31728         * lib/gl_rbtree_oset.h: Likewise.
31729         * lib/gl_rbtreehash_list.c: Likewise.
31730         * lib/gl_rbtreehash_list.h: Likewise.
31731         * lib/gl_sublist.c: Likewise.
31732         * lib/gl_sublist.h: Likewise.
31733         * lib/group-member.c: Likewise.
31734         * lib/group-member.h: Likewise.
31735         * lib/hard-locale.c: Likewise.
31736         * lib/hard-locale.h: Likewise.
31737         * lib/hash-pjw.c: Likewise.
31738         * lib/hash-pjw.h: Likewise.
31739         * lib/hash-triple.c: Likewise.
31740         * lib/hash.c: Likewise.
31741         * lib/hash.h: Likewise.
31742         * lib/human.c: Likewise.
31743         * lib/human.h: Likewise.
31744         * lib/i-ring.c: Likewise.
31745         * lib/i-ring.h: Likewise.
31746         * lib/idcache.c: Likewise.
31747         * lib/imaxabs.c: Likewise.
31748         * lib/imaxdiv.c: Likewise.
31749         * lib/inet_pton.c: Likewise.
31750         * lib/inet_pton.h: Likewise.
31751         * lib/intprops.h: Likewise.
31752         * lib/inttostr.c: Likewise.
31753         * lib/inttostr.h: Likewise.
31754         * lib/inttypes.in.h: Likewise.
31755         * lib/isapipe.c: Likewise.
31756         * lib/isdir.c: Likewise.
31757         * lib/isnan.c: Likewise.
31758         * lib/isnan.h: Likewise.
31759         * lib/isnanf.c: Likewise.
31760         * lib/isnanf.h: Likewise.
31761         * lib/isnanl-nolibm.h: Likewise.
31762         * lib/isnanl.c: Likewise.
31763         * lib/isnanl.h: Likewise.
31764         * lib/javacomp.c: Likewise.
31765         * lib/javacomp.h: Likewise.
31766         * lib/javaexec.c: Likewise.
31767         * lib/javaexec.h: Likewise.
31768         * lib/javaversion.c: Likewise.
31769         * lib/javaversion.h: Likewise.
31770         * lib/javaversion.java: Likewise.
31771         * lib/lbrkprop.h: Likewise.
31772         * lib/lchmod.h: Likewise.
31773         * lib/lchown.c: Likewise.
31774         * lib/ldexpl.c: Likewise.
31775         * lib/linebreak.c: Likewise.
31776         * lib/linebreak.h: Likewise.
31777         * lib/linebuffer.c: Likewise.
31778         * lib/linebuffer.h: Likewise.
31779         * lib/locale.in.h: Likewise.
31780         * lib/logl.c: Likewise.
31781         * lib/long-options.c: Likewise.
31782         * lib/long-options.h: Likewise.
31783         * lib/lstat.c: Likewise.
31784         * lib/lstat.h: Likewise.
31785         * lib/math.in.h: Likewise.
31786         * lib/mbchar.c: Likewise.
31787         * lib/mbchar.h: Likewise.
31788         * lib/mbfile.h: Likewise.
31789         * lib/mbiter.h: Likewise.
31790         * lib/mbscasecmp.c: Likewise.
31791         * lib/mbscasestr.c: Likewise.
31792         * lib/mbschr.c: Likewise.
31793         * lib/mbscspn.c: Likewise.
31794         * lib/mbslen.c: Likewise.
31795         * lib/mbsncasecmp.c: Likewise.
31796         * lib/mbsnlen.c: Likewise.
31797         * lib/mbspbrk.c: Likewise.
31798         * lib/mbspcasecmp.c: Likewise.
31799         * lib/mbsrchr.c: Likewise.
31800         * lib/mbssep.c: Likewise.
31801         * lib/mbsspn.c: Likewise.
31802         * lib/mbsstr.c: Likewise.
31803         * lib/mbstok_r.c: Likewise.
31804         * lib/mbswidth.c: Likewise.
31805         * lib/mbswidth.h: Likewise.
31806         * lib/mbuiter.h: Likewise.
31807         * lib/memcasecmp.c: Likewise.
31808         * lib/memcasecmp.h: Likewise.
31809         * lib/memchr.c: Likewise.
31810         * lib/memcmp.c: Likewise.
31811         * lib/memcoll.c: Likewise.
31812         * lib/memcoll.h: Likewise.
31813         * lib/memcpy.c: Likewise.
31814         * lib/memrchr.c: Likewise.
31815         * lib/mkancesdirs.c: Likewise.
31816         * lib/mkdir-p.c: Likewise.
31817         * lib/mkdir-p.h: Likewise.
31818         * lib/mkdir.c: Likewise.
31819         * lib/mkdirat.c: Likewise.
31820         * lib/mkdtemp.c: Likewise.
31821         * lib/mkstemp-safer.c: Likewise.
31822         * lib/mkstemp.c: Likewise.
31823         * lib/modechange.c: Likewise.
31824         * lib/modechange.h: Likewise.
31825         * lib/mountlist.c: Likewise.
31826         * lib/mountlist.h: Likewise.
31827         * lib/mpsort.c: Likewise.
31828         * lib/nanosleep.c: Likewise.
31829         * lib/obstack.c: Likewise.
31830         * lib/obstack.h: Likewise.
31831         * lib/open-safer.c: Likewise.
31832         * lib/open.c: Likewise.
31833         * lib/openat-die.c: Likewise.
31834         * lib/openat-priv.h: Likewise.
31835         * lib/openat-proc.c: Likewise.
31836         * lib/openat.c: Likewise.
31837         * lib/openat.h: Likewise.
31838         * lib/pagealign_alloc.c: Likewise.
31839         * lib/pagealign_alloc.h: Likewise.
31840         * lib/physmem.c: Likewise.
31841         * lib/physmem.h: Likewise.
31842         * lib/pipe-safer.c: Likewise.
31843         * lib/pipe.c: Likewise.
31844         * lib/pipe.h: Likewise.
31845         * lib/posixtm.c: Likewise.
31846         * lib/posixtm.h: Likewise.
31847         * lib/posixver.c: Likewise.
31848         * lib/printf-frexp.c: Likewise.
31849         * lib/printf-frexp.h: Likewise.
31850         * lib/printf-frexpl.c: Likewise.
31851         * lib/printf-frexpl.h: Likewise.
31852         * lib/printf.c: Likewise.
31853         * lib/progname.c: Likewise.
31854         * lib/progname.h: Likewise.
31855         * lib/progreloc.c: Likewise.
31856         * lib/putenv.c: Likewise.
31857         * lib/quote.c: Likewise.
31858         * lib/quote.h: Likewise.
31859         * lib/quotearg.c: Likewise.
31860         * lib/quotearg.h: Likewise.
31861         * lib/raise.c: Likewise.
31862         * lib/readline.c: Likewise.
31863         * lib/readline.h: Likewise.
31864         * lib/readlink.c: Likewise.
31865         * lib/readtokens.c: Likewise.
31866         * lib/readtokens.h: Likewise.
31867         * lib/readtokens0.c: Likewise.
31868         * lib/readtokens0.h: Likewise.
31869         * lib/readutmp.c: Likewise.
31870         * lib/readutmp.h: Likewise.
31871         * lib/realloc.c: Likewise.
31872         * lib/relocwrapper.c: Likewise.
31873         * lib/rename-dest-slash.c: Likewise.
31874         * lib/rename.c: Likewise.
31875         * lib/rmdir.c: Likewise.
31876         * lib/rpmatch.c: Likewise.
31877         * lib/safe-read.c: Likewise.
31878         * lib/safe-read.h: Likewise.
31879         * lib/safe-write.c: Likewise.
31880         * lib/safe-write.h: Likewise.
31881         * lib/same-inode.h: Likewise.
31882         * lib/same.c: Likewise.
31883         * lib/same.h: Likewise.
31884         * lib/save-cwd.c: Likewise.
31885         * lib/save-cwd.h: Likewise.
31886         * lib/savedir.c: Likewise.
31887         * lib/savedir.h: Likewise.
31888         * lib/savewd.c: Likewise.
31889         * lib/savewd.h: Likewise.
31890         * lib/search.in.h: Likewise.
31891         * lib/setenv.c: Likewise.
31892         * lib/setenv.h: Likewise.
31893         * lib/settime.c: Likewise.
31894         * lib/sh-quote.c: Likewise.
31895         * lib/sh-quote.h: Likewise.
31896         * lib/sig2str.c: Likewise.
31897         * lib/sig2str.h: Likewise.
31898         * lib/signal.in.h: Likewise.
31899         * lib/signbitd.c: Likewise.
31900         * lib/signbitf.c: Likewise.
31901         * lib/signbitl.c: Likewise.
31902         * lib/sigprocmask.c: Likewise.
31903         * lib/sincosl.c: Likewise.
31904         * lib/sleep.c: Likewise.
31905         * lib/sprintf.c: Likewise.
31906         * lib/sqrtl.c: Likewise.
31907         * lib/stat-time.h: Likewise.
31908         * lib/stdio--.h: Likewise.
31909         * lib/stdio-safer.h: Likewise.
31910         * lib/stdlib--.h: Likewise.
31911         * lib/stdlib-safer.h: Likewise.
31912         * lib/stdlib.in.h: Likewise.
31913         * lib/stpcpy.c: Likewise.
31914         * lib/stpncpy.c: Likewise.
31915         * lib/strchrnul.c: Likewise.
31916         * lib/strcspn.c: Likewise.
31917         * lib/strerror.c: Likewise.
31918         * lib/strftime.c: Likewise.
31919         * lib/strftime.h: Likewise.
31920         * lib/striconveh.c: Likewise.
31921         * lib/striconveh.h: Likewise.
31922         * lib/striconveha.c: Likewise.
31923         * lib/striconveha.h: Likewise.
31924         * lib/stripslash.c: Likewise.
31925         * lib/strnlen1.c: Likewise.
31926         * lib/strnlen1.h: Likewise.
31927         * lib/strtod.c: Likewise.
31928         * lib/strtoimax.c: Likewise.
31929         * lib/strtok_r.c: Likewise.
31930         * lib/strtol.c: Likewise.
31931         * lib/strtoll.c: Likewise.
31932         * lib/strtoul.c: Likewise.
31933         * lib/strtoull.c: Likewise.
31934         * lib/sysexits.in.h: Likewise.
31935         * lib/tempname.c: Likewise.
31936         * lib/tempname.h: Likewise.
31937         * lib/timespec.h: Likewise.
31938         * lib/tls.c: Likewise.
31939         * lib/tls.h: Likewise.
31940         * lib/tmpdir.c: Likewise.
31941         * lib/tmpdir.h: Likewise.
31942         * lib/tmpfile-safer.c: Likewise.
31943         * lib/tmpfile.c: Likewise.
31944         * lib/trigl.c: Likewise.
31945         * lib/trigl.h: Likewise.
31946         * lib/trim.c: Likewise.
31947         * lib/trim.h: Likewise.
31948         * lib/trunc.c: Likewise.
31949         * lib/truncf.c: Likewise.
31950         * lib/truncl.c: Likewise.
31951         * lib/tsearch.c: Likewise.
31952         * lib/unicodeio.c: Likewise.
31953         * lib/unicodeio.h: Likewise.
31954         * lib/unistd--.h: Likewise.
31955         * lib/unistd-safer.h: Likewise.
31956         * lib/unistdio/ulc-fprintf.c: Likewise.
31957         * lib/unistdio/ulc-vfprintf.c: Likewise.
31958         * lib/unlinkdir.c: Likewise.
31959         * lib/unlinkdir.h: Likewise.
31960         * lib/unlocked-io.h: Likewise.
31961         * lib/unsetenv.c: Likewise.
31962         * lib/userspec.c: Likewise.
31963         * lib/utime.c: Likewise.
31964         * lib/utimecmp.c: Likewise.
31965         * lib/utimecmp.h: Likewise.
31966         * lib/utimens.c: Likewise.
31967         * lib/verify.h: Likewise.
31968         * lib/verror.c: Likewise.
31969         * lib/verror.h: Likewise.
31970         * lib/version-etc-fsf.c: Likewise.
31971         * lib/version-etc.c: Likewise.
31972         * lib/version-etc.h: Likewise.
31973         * lib/vfprintf.c: Likewise.
31974         * lib/vprintf.c: Likewise.
31975         * lib/vsprintf.c: Likewise.
31976         * lib/w32spawn.h: Likewise.
31977         * lib/wait-process.c: Likewise.
31978         * lib/wait-process.h: Likewise.
31979         * lib/wcwidth.c: Likewise.
31980         * lib/write-any-file.c: Likewise.
31981         * lib/xalloc-die.c: Likewise.
31982         * lib/xalloc.h: Likewise.
31983         * lib/xasprintf.c: Likewise.
31984         * lib/xgetcwd.c: Likewise.
31985         * lib/xgetcwd.h: Likewise.
31986         * lib/xgetdomainname.c: Likewise.
31987         * lib/xgetdomainname.h: Likewise.
31988         * lib/xgethostname.c: Likewise.
31989         * lib/xmalloc.c: Likewise.
31990         * lib/xmalloca.c: Likewise.
31991         * lib/xmalloca.h: Likewise.
31992         * lib/xmemcoll.c: Likewise.
31993         * lib/xnanosleep.c: Likewise.
31994         * lib/xreadlink.c: Likewise.
31995         * lib/xreadlink.h: Likewise.
31996         * lib/xsetenv.c: Likewise.
31997         * lib/xsetenv.h: Likewise.
31998         * lib/xstriconv.c: Likewise.
31999         * lib/xstriconv.h: Likewise.
32000         * lib/xstrndup.c: Likewise.
32001         * lib/xstrndup.h: Likewise.
32002         * lib/xstrtod.c: Likewise.
32003         * lib/xstrtod.h: Likewise.
32004         * lib/xstrtol-error.c: Likewise.
32005         * lib/xstrtol.c: Likewise.
32006         * lib/xstrtol.h: Likewise.
32007         * lib/xtime.h: Likewise.
32008         * lib/xvasprintf.c: Likewise.
32009         * lib/xvasprintf.h: Likewise.
32010         * lib/yesno.c: Likewise.
32011         * lib/yesno.h: Likewise.
32012         * posix-modules: Likewise.
32013         * tests/test-alloca-opt.c: Likewise.
32014         * tests/test-arcfour.c: Likewise.
32015         * tests/test-arctwo.c: Likewise.
32016         * tests/test-argmatch.c: Likewise.
32017         * tests/test-argp-2.sh: Likewise.
32018         * tests/test-argp.c: Likewise.
32019         * tests/test-arpa_inet.c: Likewise.
32020         * tests/test-array_list.c: Likewise.
32021         * tests/test-array_oset.c: Likewise.
32022         * tests/test-atexit.c: Likewise.
32023         * tests/test-avltree_list.c: Likewise.
32024         * tests/test-avltree_oset.c: Likewise.
32025         * tests/test-avltreehash_list.c: Likewise.
32026         * tests/test-base64.c: Likewise.
32027         * tests/test-binary-io.c: Likewise.
32028         * tests/test-byteswap.c: Likewise.
32029         * tests/test-c-ctype.c: Likewise.
32030         * tests/test-c-strcasecmp.c: Likewise.
32031         * tests/test-c-strcasestr.c: Likewise.
32032         * tests/test-c-strncasecmp.c: Likewise.
32033         * tests/test-c-strstr.c: Likewise.
32034         * tests/test-canonicalize-lgpl.c: Likewise.
32035         * tests/test-canonicalize.c: Likewise.
32036         * tests/test-carray_list.c: Likewise.
32037         * tests/test-ceilf.c: Likewise.
32038         * tests/test-ceill.c: Likewise.
32039         * tests/test-count-one-bits.c: Likewise.
32040         * tests/test-crc.c: Likewise.
32041         * tests/test-dirname.c: Likewise.
32042         * tests/test-fbufmode.c: Likewise.
32043         * tests/test-fcntl.c: Likewise.
32044         * tests/test-fflush.c: Likewise.
32045         * tests/test-floorf.c: Likewise.
32046         * tests/test-floorl.c: Likewise.
32047         * tests/test-fopen.c: Likewise.
32048         * tests/test-fprintf-posix.c: Likewise.
32049         * tests/test-fprintf-posix.h: Likewise.
32050         * tests/test-fpurge.c: Likewise.
32051         * tests/test-freadable.c: Likewise.
32052         * tests/test-freadahead.c: Likewise.
32053         * tests/test-freading.c: Likewise.
32054         * tests/test-freopen.c: Likewise.
32055         * tests/test-frexp.c: Likewise.
32056         * tests/test-frexpl.c: Likewise.
32057         * tests/test-fseek.c: Likewise.
32058         * tests/test-fseeko.c: Likewise.
32059         * tests/test-fseterr.c: Likewise.
32060         * tests/test-fstrcmp.c: Likewise.
32061         * tests/test-ftell.c: Likewise.
32062         * tests/test-ftello.c: Likewise.
32063         * tests/test-fwritable.c: Likewise.
32064         * tests/test-fwriting.c: Likewise.
32065         * tests/test-getaddrinfo.c: Likewise.
32066         * tests/test-getpass.c: Likewise.
32067         * tests/test-gettimeofday.c: Likewise.
32068         * tests/test-hmac-md5.c: Likewise.
32069         * tests/test-hmac-sha1.c: Likewise.
32070         * tests/test-iconv.c: Likewise.
32071         * tests/test-iconvme.c: Likewise.
32072         * tests/test-inttypes.c: Likewise.
32073         * tests/test-isnan.c: Likewise.
32074         * tests/test-isnanf.c: Likewise.
32075         * tests/test-isnanl-nolibm.c: Likewise.
32076         * tests/test-isnanl.c: Likewise.
32077         * tests/test-isnanl.h: Likewise.
32078         * tests/test-ldexpl.c: Likewise.
32079         * tests/test-linked_list.c: Likewise.
32080         * tests/test-linkedhash_list.c: Likewise.
32081         * tests/test-locale.c: Likewise.
32082         * tests/test-localename.c: Likewise.
32083         * tests/test-lock.c: Likewise.
32084         * tests/test-lseek.c: Likewise.
32085         * tests/test-malloca.c: Likewise.
32086         * tests/test-math.c: Likewise.
32087         * tests/test-mbscasecmp.c: Likewise.
32088         * tests/test-mbscasestr1.c: Likewise.
32089         * tests/test-mbscasestr2.c: Likewise.
32090         * tests/test-mbscasestr3.c: Likewise.
32091         * tests/test-mbscasestr4.c: Likewise.
32092         * tests/test-mbschr.c: Likewise.
32093         * tests/test-mbscspn.c: Likewise.
32094         * tests/test-mbsncasecmp.c: Likewise.
32095         * tests/test-mbspbrk.c: Likewise.
32096         * tests/test-mbspcasecmp.c: Likewise.
32097         * tests/test-mbsrchr.c: Likewise.
32098         * tests/test-mbsspn.c: Likewise.
32099         * tests/test-mbsstr1.c: Likewise.
32100         * tests/test-mbsstr2.c: Likewise.
32101         * tests/test-mbsstr3.c: Likewise.
32102         * tests/test-md5.c: Likewise.
32103         * tests/test-memmem.c: Likewise.
32104         * tests/test-netinet_in.c: Likewise.
32105         * tests/test-open.c: Likewise.
32106         * tests/test-printf-frexp.c: Likewise.
32107         * tests/test-printf-frexpl.c: Likewise.
32108         * tests/test-printf-posix.c: Likewise.
32109         * tests/test-printf-posix.h: Likewise.
32110         * tests/test-rbtree_list.c: Likewise.
32111         * tests/test-rbtree_oset.c: Likewise.
32112         * tests/test-rbtreehash_list.c: Likewise.
32113         * tests/test-read-file.c: Likewise.
32114         * tests/test-rijndael.c: Likewise.
32115         * tests/test-search.c: Likewise.
32116         * tests/test-signbit.c: Likewise.
32117         * tests/test-sleep.c: Likewise.
32118         * tests/test-snprintf-posix.c: Likewise.
32119         * tests/test-snprintf-posix.h: Likewise.
32120         * tests/test-snprintf.c: Likewise.
32121         * tests/test-sprintf-posix.c: Likewise.
32122         * tests/test-sprintf-posix.h: Likewise.
32123         * tests/test-stat-time.c: Likewise.
32124         * tests/test-stdbool.c: Likewise.
32125         * tests/test-stdint.c: Likewise.
32126         * tests/test-stdio.c: Likewise.
32127         * tests/test-stdlib.c: Likewise.
32128         * tests/test-stpncpy.c: Likewise.
32129         * tests/test-strcasestr.c: Likewise.
32130         * tests/test-striconv.c: Likewise.
32131         * tests/test-striconveh.c: Likewise.
32132         * tests/test-striconveha.c: Likewise.
32133         * tests/test-string.c: Likewise.
32134         * tests/test-sys_select.c: Likewise.
32135         * tests/test-sys_socket.c: Likewise.
32136         * tests/test-sys_stat.c: Likewise.
32137         * tests/test-sys_time.c: Likewise.
32138         * tests/test-sysexits.c: Likewise.
32139         * tests/test-time.c: Likewise.
32140         * tests/test-tls.c: Likewise.
32141         * tests/test-trunc.c: Likewise.
32142         * tests/test-truncf.c: Likewise.
32143         * tests/test-truncl.c: Likewise.
32144         * tests/test-unistd.c: Likewise.
32145         * tests/test-vasnprintf-posix.c: Likewise.
32146         * tests/test-vasnprintf-posix2.c: Likewise.
32147         * tests/test-vasnprintf.c: Likewise.
32148         * tests/test-vasprintf-posix.c: Likewise.
32149         * tests/test-vasprintf.c: Likewise.
32150         * tests/test-verify.c: Likewise.
32151         * tests/test-vfprintf-posix.c: Likewise.
32152         * tests/test-vprintf-posix.c: Likewise.
32153         * tests/test-vsnprintf-posix.c: Likewise.
32154         * tests/test-vsnprintf.c: Likewise.
32155         * tests/test-vsprintf-posix.c: Likewise.
32156         * tests/test-wchar.c: Likewise.
32157         * tests/test-wctype.c: Likewise.
32158         * tests/test-wcwidth.c: Likewise.
32159         * tests/test-xstrtol.c: Likewise.
32160         * tests/test-xvasprintf.c: Likewise.
32161         * tests/uniconv/test-u16-conv-from-enc.c: Likewise.
32162         * tests/uniconv/test-u16-conv-to-enc.c: Likewise.
32163         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
32164         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
32165         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
32166         * tests/uniconv/test-u32-conv-to-enc.c: Likewise.
32167         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
32168         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
32169         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
32170         * tests/uniconv/test-u8-conv-to-enc.c: Likewise.
32171         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
32172         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
32173         * tests/uniname/test-uninames.c: Likewise.
32174         * tests/unistdio/test-u16-asnprintf1.c: Likewise.
32175         * tests/unistdio/test-u16-asnprintf1.h: Likewise.
32176         * tests/unistdio/test-u16-printf1.h: Likewise.
32177         * tests/unistdio/test-u16-vasnprintf1.c: Likewise.
32178         * tests/unistdio/test-u16-vasnprintf2.c: Likewise.
32179         * tests/unistdio/test-u16-vasnprintf3.c: Likewise.
32180         * tests/unistdio/test-u16-vasprintf1.c: Likewise.
32181         * tests/unistdio/test-u16-vsnprintf1.c: Likewise.
32182         * tests/unistdio/test-u16-vsprintf1.c: Likewise.
32183         * tests/unistdio/test-u32-asnprintf1.c: Likewise.
32184         * tests/unistdio/test-u32-asnprintf1.h: Likewise.
32185         * tests/unistdio/test-u32-printf1.h: Likewise.
32186         * tests/unistdio/test-u32-vasnprintf1.c: Likewise.
32187         * tests/unistdio/test-u32-vasnprintf2.c: Likewise.
32188         * tests/unistdio/test-u32-vasnprintf3.c: Likewise.
32189         * tests/unistdio/test-u32-vasprintf1.c: Likewise.
32190         * tests/unistdio/test-u32-vsnprintf1.c: Likewise.
32191         * tests/unistdio/test-u32-vsprintf1.c: Likewise.
32192         * tests/unistdio/test-u8-asnprintf1.c: Likewise.
32193         * tests/unistdio/test-u8-asnprintf1.h: Likewise.
32194         * tests/unistdio/test-u8-printf1.h: Likewise.
32195         * tests/unistdio/test-u8-vasnprintf1.c: Likewise.
32196         * tests/unistdio/test-u8-vasnprintf2.c: Likewise.
32197         * tests/unistdio/test-u8-vasnprintf3.c: Likewise.
32198         * tests/unistdio/test-u8-vasprintf1.c: Likewise.
32199         * tests/unistdio/test-u8-vsnprintf1.c: Likewise.
32200         * tests/unistdio/test-u8-vsprintf1.c: Likewise.
32201         * tests/unistdio/test-ulc-asnprintf1.c: Likewise.
32202         * tests/unistdio/test-ulc-asnprintf1.h: Likewise.
32203         * tests/unistdio/test-ulc-printf1.h: Likewise.
32204         * tests/unistdio/test-ulc-vasnprintf1.c: Likewise.
32205         * tests/unistdio/test-ulc-vasnprintf2.c: Likewise.
32206         * tests/unistdio/test-ulc-vasnprintf3.c: Likewise.
32207         * tests/unistdio/test-ulc-vasprintf1.c: Likewise.
32208         * tests/unistdio/test-ulc-vsnprintf1.c: Likewise.
32209         * tests/unistdio/test-ulc-vsprintf1.c: Likewise.
32210         * tests/uniwidth/test-u16-strwidth.c: Likewise.
32211         * tests/uniwidth/test-u16-width.c: Likewise.
32212         * tests/uniwidth/test-u32-strwidth.c: Likewise.
32213         * tests/uniwidth/test-u32-width.c: Likewise.
32214         * tests/uniwidth/test-u8-strwidth.c: Likewise.
32215         * tests/uniwidth/test-u8-width.c: Likewise.
32216         * tests/uniwidth/test-uc_width.c: Likewise.
32217         * config/srclist-update: Likewise.
32218         (fixlicense): Update to GPLv3+.
32219
32220         Change copyright notice from LGPLv2.1+ to LGPLv3+.
32221         * tests/test-tsearch.c: Change copyright notice.
32222
32223         Change copyright notice from LGPLv2.0+ to LGPLv3+.
32224         * lib/c-strcaseeq.h: Change copyright notice.
32225         * lib/streq.h: Likewise.
32226         * lib/uniconv.h: Likewise.
32227         * lib/uniconv/u-conv-from-enc.h: Likewise.
32228         * lib/uniconv/u-conv-to-enc.h: Likewise.
32229         * lib/uniconv/u-strconv-from-enc.h: Likewise.
32230         * lib/uniconv/u-strconv-to-enc.h: Likewise.
32231         * lib/uniconv/u16-conv-from-enc.c: Likewise.
32232         * lib/uniconv/u16-conv-to-enc.c: Likewise.
32233         * lib/uniconv/u16-strconv-from-enc.c: Likewise.
32234         * lib/uniconv/u16-strconv-from-locale.c: Likewise.
32235         * lib/uniconv/u16-strconv-to-enc.c: Likewise.
32236         * lib/uniconv/u16-strconv-to-locale.c: Likewise.
32237         * lib/uniconv/u32-conv-from-enc.c: Likewise.
32238         * lib/uniconv/u32-conv-to-enc.c: Likewise.
32239         * lib/uniconv/u32-strconv-from-enc.c: Likewise.
32240         * lib/uniconv/u32-strconv-from-locale.c: Likewise.
32241         * lib/uniconv/u32-strconv-to-enc.c: Likewise.
32242         * lib/uniconv/u32-strconv-to-locale.c: Likewise.
32243         * lib/uniconv/u8-conv-from-enc.c: Likewise.
32244         * lib/uniconv/u8-conv-to-enc.c: Likewise.
32245         * lib/uniconv/u8-strconv-from-enc.c: Likewise.
32246         * lib/uniconv/u8-strconv-from-locale.c: Likewise.
32247         * lib/uniconv/u8-strconv-to-enc.c: Likewise.
32248         * lib/uniconv/u8-strconv-to-locale.c: Likewise.
32249         * lib/uniname.h: Likewise.
32250         * lib/uniname/uniname.c: Likewise.
32251         * lib/unistdio.h: Likewise.
32252         * lib/unistdio/u-asnprintf.h: Likewise.
32253         * lib/unistdio/u-asprintf.h: Likewise.
32254         * lib/unistdio/u-printf-args.c: Likewise.
32255         * lib/unistdio/u-printf-args.h: Likewise.
32256         * lib/unistdio/u-printf-parse.h: Likewise.
32257         * lib/unistdio/u-snprintf.h: Likewise.
32258         * lib/unistdio/u-sprintf.h: Likewise.
32259         * lib/unistdio/u-vasprintf.h: Likewise.
32260         * lib/unistdio/u-vsnprintf.h: Likewise.
32261         * lib/unistdio/u-vsprintf.h: Likewise.
32262         * lib/unistdio/u16-asnprintf.c: Likewise.
32263         * lib/unistdio/u16-asprintf.c: Likewise.
32264         * lib/unistdio/u16-printf-parse.c: Likewise.
32265         * lib/unistdio/u16-snprintf.c: Likewise.
32266         * lib/unistdio/u16-sprintf.c: Likewise.
32267         * lib/unistdio/u16-u16-asnprintf.c: Likewise.
32268         * lib/unistdio/u16-u16-asprintf.c: Likewise.
32269         * lib/unistdio/u16-u16-snprintf.c: Likewise.
32270         * lib/unistdio/u16-u16-sprintf.c: Likewise.
32271         * lib/unistdio/u16-u16-vasnprintf.c: Likewise.
32272         * lib/unistdio/u16-u16-vasprintf.c: Likewise.
32273         * lib/unistdio/u16-u16-vsnprintf.c: Likewise.
32274         * lib/unistdio/u16-u16-vsprintf.c: Likewise.
32275         * lib/unistdio/u16-vasnprintf.c: Likewise.
32276         * lib/unistdio/u16-vasprintf.c: Likewise.
32277         * lib/unistdio/u16-vsnprintf.c: Likewise.
32278         * lib/unistdio/u16-vsprintf.c: Likewise.
32279         * lib/unistdio/u32-asnprintf.c: Likewise.
32280         * lib/unistdio/u32-asprintf.c: Likewise.
32281         * lib/unistdio/u32-printf-parse.c: Likewise.
32282         * lib/unistdio/u32-snprintf.c: Likewise.
32283         * lib/unistdio/u32-sprintf.c: Likewise.
32284         * lib/unistdio/u32-u32-asnprintf.c: Likewise.
32285         * lib/unistdio/u32-u32-asprintf.c: Likewise.
32286         * lib/unistdio/u32-u32-snprintf.c: Likewise.
32287         * lib/unistdio/u32-u32-sprintf.c: Likewise.
32288         * lib/unistdio/u32-u32-vasnprintf.c: Likewise.
32289         * lib/unistdio/u32-u32-vasprintf.c: Likewise.
32290         * lib/unistdio/u32-u32-vsnprintf.c: Likewise.
32291         * lib/unistdio/u32-u32-vsprintf.c: Likewise.
32292         * lib/unistdio/u32-vasnprintf.c: Likewise.
32293         * lib/unistdio/u32-vasprintf.c: Likewise.
32294         * lib/unistdio/u32-vsnprintf.c: Likewise.
32295         * lib/unistdio/u32-vsprintf.c: Likewise.
32296         * lib/unistdio/u8-asnprintf.c: Likewise.
32297         * lib/unistdio/u8-asprintf.c: Likewise.
32298         * lib/unistdio/u8-printf-parse.c: Likewise.
32299         * lib/unistdio/u8-snprintf.c: Likewise.
32300         * lib/unistdio/u8-sprintf.c: Likewise.
32301         * lib/unistdio/u8-u8-asnprintf.c: Likewise.
32302         * lib/unistdio/u8-u8-asprintf.c: Likewise.
32303         * lib/unistdio/u8-u8-snprintf.c: Likewise.
32304         * lib/unistdio/u8-u8-sprintf.c: Likewise.
32305         * lib/unistdio/u8-u8-vasnprintf.c: Likewise.
32306         * lib/unistdio/u8-u8-vasprintf.c: Likewise.
32307         * lib/unistdio/u8-u8-vsnprintf.c: Likewise.
32308         * lib/unistdio/u8-u8-vsprintf.c: Likewise.
32309         * lib/unistdio/u8-vasnprintf.c: Likewise.
32310         * lib/unistdio/u8-vasprintf.c: Likewise.
32311         * lib/unistdio/u8-vsnprintf.c: Likewise.
32312         * lib/unistdio/u8-vsprintf.c: Likewise.
32313         * lib/unistdio/ulc-asnprintf.c: Likewise.
32314         * lib/unistdio/ulc-asprintf.c: Likewise.
32315         * lib/unistdio/ulc-printf-parse.c: Likewise.
32316         * lib/unistdio/ulc-snprintf.c: Likewise.
32317         * lib/unistdio/ulc-sprintf.c: Likewise.
32318         * lib/unistdio/ulc-vasnprintf.c: Likewise.
32319         * lib/unistdio/ulc-vasprintf.c: Likewise.
32320         * lib/unistdio/ulc-vsnprintf.c: Likewise.
32321         * lib/unistdio/ulc-vsprintf.c: Likewise.
32322         * lib/unistr.h: Likewise.
32323         * lib/unistr/u-cpy-alloc.h: Likewise.
32324         * lib/unistr/u-cpy.h: Likewise.
32325         * lib/unistr/u-endswith.h: Likewise.
32326         * lib/unistr/u-move.h: Likewise.
32327         * lib/unistr/u-set.h: Likewise.
32328         * lib/unistr/u-startswith.h: Likewise.
32329         * lib/unistr/u-stpcpy.h: Likewise.
32330         * lib/unistr/u-stpncpy.h: Likewise.
32331         * lib/unistr/u-strcat.h: Likewise.
32332         * lib/unistr/u-strcpy.h: Likewise.
32333         * lib/unistr/u-strcspn.h: Likewise.
32334         * lib/unistr/u-strdup.h: Likewise.
32335         * lib/unistr/u-strlen.h: Likewise.
32336         * lib/unistr/u-strncat.h: Likewise.
32337         * lib/unistr/u-strncpy.h: Likewise.
32338         * lib/unistr/u-strnlen.h: Likewise.
32339         * lib/unistr/u-strpbrk.h: Likewise.
32340         * lib/unistr/u-strspn.h: Likewise.
32341         * lib/unistr/u-strstr.h: Likewise.
32342         * lib/unistr/u-strtok.h: Likewise.
32343         * lib/unistr/u16-check.c: Likewise.
32344         * lib/unistr/u16-chr.c: Likewise.
32345         * lib/unistr/u16-cmp.c: Likewise.
32346         * lib/unistr/u16-cpy-alloc.c: Likewise.
32347         * lib/unistr/u16-cpy.c: Likewise.
32348         * lib/unistr/u16-endswith.c: Likewise.
32349         * lib/unistr/u16-mblen.c: Likewise.
32350         * lib/unistr/u16-mbsnlen.c: Likewise.
32351         * lib/unistr/u16-mbtouc-aux.c: Likewise.
32352         * lib/unistr/u16-mbtouc-unsafe-aux.c: Likewise.
32353         * lib/unistr/u16-mbtouc-unsafe.c: Likewise.
32354         * lib/unistr/u16-mbtouc.c: Likewise.
32355         * lib/unistr/u16-mbtoucr.c: Likewise.
32356         * lib/unistr/u16-move.c: Likewise.
32357         * lib/unistr/u16-next.c: Likewise.
32358         * lib/unistr/u16-prev.c: Likewise.
32359         * lib/unistr/u16-set.c: Likewise.
32360         * lib/unistr/u16-startswith.c: Likewise.
32361         * lib/unistr/u16-stpcpy.c: Likewise.
32362         * lib/unistr/u16-stpncpy.c: Likewise.
32363         * lib/unistr/u16-strcat.c: Likewise.
32364         * lib/unistr/u16-strchr.c: Likewise.
32365         * lib/unistr/u16-strcmp.c: Likewise.
32366         * lib/unistr/u16-strcpy.c: Likewise.
32367         * lib/unistr/u16-strcspn.c: Likewise.
32368         * lib/unistr/u16-strdup.c: Likewise.
32369         * lib/unistr/u16-strlen.c: Likewise.
32370         * lib/unistr/u16-strmblen.c: Likewise.
32371         * lib/unistr/u16-strmbtouc.c: Likewise.
32372         * lib/unistr/u16-strncat.c: Likewise.
32373         * lib/unistr/u16-strncmp.c: Likewise.
32374         * lib/unistr/u16-strncpy.c: Likewise.
32375         * lib/unistr/u16-strnlen.c: Likewise.
32376         * lib/unistr/u16-strpbrk.c: Likewise.
32377         * lib/unistr/u16-strrchr.c: Likewise.
32378         * lib/unistr/u16-strspn.c: Likewise.
32379         * lib/unistr/u16-strstr.c: Likewise.
32380         * lib/unistr/u16-strtok.c: Likewise.
32381         * lib/unistr/u16-to-u32.c: Likewise.
32382         * lib/unistr/u16-to-u8.c: Likewise.
32383         * lib/unistr/u16-uctomb-aux.c: Likewise.
32384         * lib/unistr/u16-uctomb.c: Likewise.
32385         * lib/unistr/u32-check.c: Likewise.
32386         * lib/unistr/u32-chr.c: Likewise.
32387         * lib/unistr/u32-cmp.c: Likewise.
32388         * lib/unistr/u32-cpy-alloc.c: Likewise.
32389         * lib/unistr/u32-cpy.c: Likewise.
32390         * lib/unistr/u32-endswith.c: Likewise.
32391         * lib/unistr/u32-mblen.c: Likewise.
32392         * lib/unistr/u32-mbsnlen.c: Likewise.
32393         * lib/unistr/u32-mbtouc-unsafe.c: Likewise.
32394         * lib/unistr/u32-mbtouc.c: Likewise.
32395         * lib/unistr/u32-mbtoucr.c: Likewise.
32396         * lib/unistr/u32-move.c: Likewise.
32397         * lib/unistr/u32-next.c: Likewise.
32398         * lib/unistr/u32-prev.c: Likewise.
32399         * lib/unistr/u32-set.c: Likewise.
32400         * lib/unistr/u32-startswith.c: Likewise.
32401         * lib/unistr/u32-stpcpy.c: Likewise.
32402         * lib/unistr/u32-stpncpy.c: Likewise.
32403         * lib/unistr/u32-strcat.c: Likewise.
32404         * lib/unistr/u32-strchr.c: Likewise.
32405         * lib/unistr/u32-strcmp.c: Likewise.
32406         * lib/unistr/u32-strcpy.c: Likewise.
32407         * lib/unistr/u32-strcspn.c: Likewise.
32408         * lib/unistr/u32-strdup.c: Likewise.
32409         * lib/unistr/u32-strlen.c: Likewise.
32410         * lib/unistr/u32-strmblen.c: Likewise.
32411         * lib/unistr/u32-strmbtouc.c: Likewise.
32412         * lib/unistr/u32-strncat.c: Likewise.
32413         * lib/unistr/u32-strncmp.c: Likewise.
32414         * lib/unistr/u32-strncpy.c: Likewise.
32415         * lib/unistr/u32-strnlen.c: Likewise.
32416         * lib/unistr/u32-strpbrk.c: Likewise.
32417         * lib/unistr/u32-strrchr.c: Likewise.
32418         * lib/unistr/u32-strspn.c: Likewise.
32419         * lib/unistr/u32-strstr.c: Likewise.
32420         * lib/unistr/u32-strtok.c: Likewise.
32421         * lib/unistr/u32-to-u16.c: Likewise.
32422         * lib/unistr/u32-to-u8.c: Likewise.
32423         * lib/unistr/u32-uctomb.c: Likewise.
32424         * lib/unistr/u8-check.c: Likewise.
32425         * lib/unistr/u8-chr.c: Likewise.
32426         * lib/unistr/u8-cmp.c: Likewise.
32427         * lib/unistr/u8-cpy-alloc.c: Likewise.
32428         * lib/unistr/u8-cpy.c: Likewise.
32429         * lib/unistr/u8-endswith.c: Likewise.
32430         * lib/unistr/u8-mblen.c: Likewise.
32431         * lib/unistr/u8-mbsnlen.c: Likewise.
32432         * lib/unistr/u8-mbtouc-aux.c: Likewise.
32433         * lib/unistr/u8-mbtouc-unsafe-aux.c: Likewise.
32434         * lib/unistr/u8-mbtouc-unsafe.c: Likewise.
32435         * lib/unistr/u8-mbtouc.c: Likewise.
32436         * lib/unistr/u8-mbtoucr.c: Likewise.
32437         * lib/unistr/u8-move.c: Likewise.
32438         * lib/unistr/u8-next.c: Likewise.
32439         * lib/unistr/u8-prev.c: Likewise.
32440         * lib/unistr/u8-set.c: Likewise.
32441         * lib/unistr/u8-startswith.c: Likewise.
32442         * lib/unistr/u8-stpcpy.c: Likewise.
32443         * lib/unistr/u8-stpncpy.c: Likewise.
32444         * lib/unistr/u8-strcat.c: Likewise.
32445         * lib/unistr/u8-strchr.c: Likewise.
32446         * lib/unistr/u8-strcmp.c: Likewise.
32447         * lib/unistr/u8-strcpy.c: Likewise.
32448         * lib/unistr/u8-strcspn.c: Likewise.
32449         * lib/unistr/u8-strdup.c: Likewise.
32450         * lib/unistr/u8-strlen.c: Likewise.
32451         * lib/unistr/u8-strmblen.c: Likewise.
32452         * lib/unistr/u8-strmbtouc.c: Likewise.
32453         * lib/unistr/u8-strncat.c: Likewise.
32454         * lib/unistr/u8-strncmp.c: Likewise.
32455         * lib/unistr/u8-strncpy.c: Likewise.
32456         * lib/unistr/u8-strnlen.c: Likewise.
32457         * lib/unistr/u8-strpbrk.c: Likewise.
32458         * lib/unistr/u8-strrchr.c: Likewise.
32459         * lib/unistr/u8-strspn.c: Likewise.
32460         * lib/unistr/u8-strstr.c: Likewise.
32461         * lib/unistr/u8-strtok.c: Likewise.
32462         * lib/unistr/u8-to-u16.c: Likewise.
32463         * lib/unistr/u8-to-u32.c: Likewise.
32464         * lib/unistr/u8-uctomb-aux.c: Likewise.
32465         * lib/unistr/u8-uctomb.c: Likewise.
32466         * lib/unitypes.h: Likewise.
32467         * lib/uniwidth.h: Likewise.
32468         * lib/uniwidth/cjk.h: Likewise.
32469         * lib/uniwidth/u16-strwidth.c: Likewise.
32470         * lib/uniwidth/u16-width.c: Likewise.
32471         * lib/uniwidth/u32-strwidth.c: Likewise.
32472         * lib/uniwidth/u32-width.c: Likewise.
32473         * lib/uniwidth/u8-strwidth.c: Likewise.
32474         * lib/uniwidth/u8-width.c: Likewise.
32475         * lib/uniwidth/width.c: Likewise.
32476
32477 2007-10-07  Bruno Haible  <bruno@clisp.org>
32478
32479         * lib/inttypes.in.h: Change copyright notice from LGPL to GPL.
32480         The file is still under LGPL (see modules/inttypes).
32481
32482 2007-10-06  Bruno Haible  <bruno@clisp.org>
32483
32484         * modules/trunc (Dependencies): Add 'extensions'.
32485         * m4/trunc.m4 (gl_FUNC_TRUNC): Require gl_USE_SYSTEM_EXTENSIONS.
32486         Reported by Ben Pfaff <blp@gnu.org>.
32487
32488 2007-10-06  Bruno Haible  <bruno@clisp.org>
32489
32490         * modules/freopen-tests: New file.
32491         * tests/test-freopen.c: New file.
32492
32493         * modules/fopen-tests: New file.
32494         * tests/test-fopen.c: New file.
32495
32496         * modules/fopen: New file.
32497         * lib/fopen.c: New file.
32498         * m4/fopen.m4: New file.
32499         * modules/freopen: New file.
32500         * lib/freopen.c: New file.
32501         * m4/freopen.m4: New file.
32502         * lib/stdio.in.h (fopen, freopen): New declarations.
32503         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize also GNULIB_FOPEN,
32504         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
32505         * modules/stdio (Makefile.am): Substitute also GNULIB_FOPEN,
32506         GNULIB_FREOPEN, REPLACE_FOPEN, REPLACE_FREOPEN.
32507         * doc/functions/fopen.texi: Mention the 'fopen' module.
32508         * doc/functions/freopen.texi: Mention the 'freopen' module.
32509
32510 2007-10-06  Bruno Haible  <bruno@clisp.org>
32511
32512         * modules/open-tests: New file.
32513         * tests/test-open.c: New file.
32514
32515         * modules/open: New file.
32516         * lib/open.c: New file.
32517         * m4/open.m4: New file.
32518         * lib/fchdir.c (open): If the gnulib module 'open' is used, do what
32519         lib/open.c does.
32520         * lib/fcntl.in.h (open): Declare also if replaced by the 'open' module.
32521         * m4/fcntl_h.m4 (gl_FCNTL_MODULE_INDICATOR, gl_FCNTL_H_DEFAULTS): New
32522         macros.
32523         (gl_FCNTL_H): Require gl_FCNTL_H_DEFAULTS.
32524         * modules/fcntl (Makefile.am): Also substitute GNULIB_OPEN and
32525         REPLACE_OPEN.
32526         * doc/functions/open.texi: Mention the 'open' module.
32527
32528 2007-10-04  Bruno Haible  <bruno@clisp.org>
32529
32530         * modules/ceill-tests: New file.
32531         * tests/test-ceill.c: New file.
32532
32533         * modules/ceill: New file.
32534         * lib/ceill.c: Replace entire file.
32535         * m4/ceill.m4: New file.
32536         * lib/math.in.h (ceill): Replace declaration.
32537         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILL.
32538         * modules/math (Makefile.am): Substitute also GNULIB_CEILL.
32539         * doc/functions/ceill.texi: Mention the 'ceill' module.
32540         * modules/mathl (Files): Remove lib/ceill.c.
32541         (Depends-on): Add ceill.
32542
32543 2007-10-04  Bruno Haible  <bruno@clisp.org>
32544
32545         * modules/ceilf-tests: New file.
32546         * tests/test-ceilf.c: New file.
32547
32548         * modules/ceilf: New file.
32549         * lib/ceil.c: New file.
32550         * lib/ceilf.c: New file.
32551         * m4/ceilf.m4: New file.
32552         * lib/math.in.h (ceilf): New declaration.
32553         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_CEILF and
32554         HAVE_DECL_CEILF.
32555         * modules/math (Makefile.am): Substitute also GNULIB_CEILF and
32556         HAVE_DECL_CEILF.
32557         * doc/functions/ceilf.texi: Mention the 'ceilf' module.
32558
32559 2007-10-04  Bruno Haible  <bruno@clisp.org>
32560
32561         * modules/floorl-tests: New file.
32562         * tests/test-floorl.c: New file.
32563
32564         * modules/floorl: New file.
32565         * lib/floorl.c: Replace entire file.
32566         * m4/floorl.m4: New file.
32567         * lib/math.in.h (floorl): Replace declaration.
32568         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORL.
32569         * modules/math (Makefile.am): Substitute also GNULIB_FLOORL.
32570         * doc/functions/floorl.texi: Mention the 'floorl' module.
32571         * modules/mathl (Files): Remove lib/floorl.c.
32572         (Depends-on): Add floorl.
32573
32574 2007-10-04  Bruno Haible  <bruno@clisp.org>
32575
32576         * modules/floorf-tests: New file.
32577         * tests/test-floorf.c: New file.
32578
32579         * modules/floorf: New file.
32580         * lib/floor.c: New file.
32581         * lib/floorf.c: New file.
32582         * m4/floorf.m4: New file.
32583         * lib/math.in.h (floorf): New declaration.
32584         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FLOORF and
32585         HAVE_DECL_FLOORF.
32586         * modules/math (Makefile.am): Substitute also GNULIB_FLOORF and
32587         HAVE_DECL_FLOORF.
32588         * doc/functions/floorf.texi: Mention the 'floorf' module.
32589
32590 2007-10-04  Benoit Sigoure  <tsuna@lrde.epita.fr>
32591             Bruno Haible  <bruno@clisp.org>
32592
32593         Advertise for the Git server instead of the CVS server.
32594         * doc/gnulib-intro.texi (Steady Development): Mention the Git
32595         repository instead of the CVS one.
32596         * doc/gnulib-tool.texi (VCS Issues): Renamed from "CVS Issues". Talk
32597         about all VCS systems generically.
32598         * doc/gnulib.texi (Introduction): Capitalize `Git'.
32599
32600 2007-10-04  Bruno Haible  <bruno@clisp.org>
32601
32602         * doc/gnulib.texi (Function Substitutes): Explain what an absent module
32603         means.
32604         Reported by Benoît Sigoure <tsuna@lrde.epita.fr>.
32605
32606 2007-10-04  Bruno Haible  <bruno@clisp.org>
32607
32608         * modules/truncl-tests: New file.
32609         * tests/test-truncl.c: New file.
32610
32611         * modules/truncl: New file.
32612         * lib/truncl.c: New file.
32613         * m4/truncl.m4: New file.
32614         * lib/math.in.h (truncl): New declaration.
32615         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCL and
32616         HAVE_DECL_TRUNCL.
32617         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCL and
32618         HAVE_DECL_TRUNCL.
32619         * doc/functions/truncl.texi: Mention the 'truncl' module.
32620
32621 2007-10-04  Bruno Haible  <bruno@clisp.org>
32622
32623         * modules/truncf-tests: New file.
32624         * tests/test-truncf.c: New file.
32625
32626         * modules/truncf: New file.
32627         * lib/trunc.c: Make paramerizable through USE_* macros.
32628         * lib/truncf.c: New file.
32629         * m4/truncf.m4: New file.
32630         * lib/math.in.h (truncf): New declaration.
32631         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNCF and
32632         HAVE_DECL_TRUNCF.
32633         * modules/math (Makefile.am): Substitute also GNULIB_TRUNCF and
32634         HAVE_DECL_TRUNCF.
32635         * doc/functions/truncf.texi: Mention the 'truncf' module.
32636
32637 2007-10-03  Bruno Haible  <bruno@clisp.org>
32638
32639         * gnulib-tool (func_get_automake_snippet): Synthesize an EXTRA_DIST
32640         augmentation also for tests modules.
32641         * modules/argp-tests (Makefile.am): Remove EXTRA_DIST augmentation.
32642         * modules/atexit-tests (Makefile.am): Likewise.
32643         * modules/binary-io-tests (Makefile.am): Likewise.
32644         * modules/c-strcase-tests (Makefile.am): Likewise.
32645         * modules/canonicalize-lgpl-tests (Makefile.am): Likewise.
32646         * modules/canonicalize-tests (Makefile.am): Likewise.
32647         * modules/closein-tests (Makefile.am): Likewise.
32648         * modules/fprintf-posix-tests (Makefile.am): Likewise.
32649         * modules/freadahead-tests (Makefile.am): Likewise.
32650         * modules/fseek-tests (Makefile.am): Likewise.
32651         * modules/fseeko-tests (Makefile.am): Likewise.
32652         * modules/ftell-tests (Makefile.am): Likewise.
32653         * modules/ftello-tests (Makefile.am): Likewise.
32654         * modules/isnanl-nolibm-tests (Makefile.am): Likewise.
32655         * modules/isnanl-tests (Makefile.am): Likewise.
32656         * modules/lseek-tests (Makefile.am): Likewise.
32657         * modules/mbscasecmp-tests (Makefile.am): Likewise.
32658         * modules/mbscasestr-tests (Makefile.am): Likewise.
32659         * modules/mbschr-tests (Makefile.am): Likewise.
32660         * modules/mbscspn-tests (Makefile.am): Likewise.
32661         * modules/mbsncasecmp-tests (Makefile.am): Likewise.
32662         * modules/mbspbrk-tests (Makefile.am): Likewise.
32663         * modules/mbspcasecmp-tests (Makefile.am): Likewise.
32664         * modules/mbsrchr-tests (Makefile.am): Likewise.
32665         * modules/mbsspn-tests (Makefile.am): Likewise.
32666         * modules/mbsstr-tests (Makefile.am): Likewise.
32667         * modules/printf-posix-tests (Makefile.am): Likewise.
32668         * modules/snprintf-posix-tests (Makefile.am): Likewise.
32669         * modules/sprintf-posix-tests (Makefile.am): Likewise.
32670         * modules/tsearch-tests (Makefile.am): Likewise.
32671         * modules/uniname/uniname-tests (Makefile.am): Likewise.
32672         * modules/unistdio/u16-vasnprintf-tests (Makefile.am): Likewise.
32673         * modules/unistdio/u32-vasnprintf-tests (Makefile.am): Likewise.
32674         * modules/unistdio/u8-vasnprintf-tests (Makefile.am): Likewise.
32675         * modules/unistdio/ulc-vasnprintf-tests (Makefile.am): Likewise.
32676         * modules/vasnprintf-posix-tests (Makefile.am): Likewise.
32677         * modules/vfprintf-posix-tests (Makefile.am): Likewise.
32678         * modules/vprintf-posix-tests (Makefile.am): Likewise.
32679         * modules/vsnprintf-posix-tests (Makefile.am): Likewise.
32680         * modules/vsprintf-posix-tests (Makefile.am): Likewise.
32681         * modules/xstrtoimax-tests (Makefile.am): Likewise.
32682         * modules/xstrtol-tests (Makefile.am): Likewise.
32683         * modules/xstrtoumax-tests (Makefile.am): Likewise.
32684         * modules/yesno-tests (Makefile.am): Likewise.
32685
32686 2007-10-03  Bruno Haible  <bruno@clisp.org>
32687
32688         * modules/trunc-tests: New file.
32689         * tests/test-trunc.c: New file.
32690
32691         * modules/trunc: New file.
32692         * lib/trunc.c: New file.
32693         * m4/trunc.m4: New file.
32694         * lib/math.in.h (trunc): New declaration.
32695         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_TRUNC and
32696         HAVE_DECL_TRUNC.
32697         * modules/math (Makefile.am): Substitute also GNULIB_TRUNC and
32698         HAVE_DECL_TRUNC.
32699         * doc/functions/trunc.texi: Mention the 'trunc' module.
32700
32701 2007-10-03  Bruno Haible  <bruno@clisp.org>
32702
32703         * tests/test-fpending.c: New file, mostly copied
32704         from coreutils/lib/t-fpending.c.
32705         * modules/fpending-tests: New file.
32706
32707 2007-10-03  Bruno Haible  <bruno@clisp.org>
32708
32709         Port the stdio extensions to QNX (untested).
32710         * lib/fseterr.c (fseterr): Add support for QNX.
32711         * lib/fbufmode.c (fbufmode): Likewise.
32712         * lib/freadable.c (freadable): Likewise.
32713         * lib/fwritable.c (fwritable): Likewise.
32714         * lib/freading.c (freading): Likewise.
32715         * lib/fwriting.c (fwriting): Likewise.
32716         * lib/freadahead.c (freadahed): Likewise.
32717         * lib/fpurge.c (fpurge): Likewise.
32718         * lib/fseeko.c (rpl_fseeko): Likewise.
32719
32720 2007-10-03  Bruno Haible  <bruno@clisp.org>
32721             Jim Meyering  <jim@meyering.net>
32722             Eric Blake  <ebb9@byu.net>
32723
32724         * doc/relocatable.texi: Use @command instead of @program.
32725
32726 2007-10-02  Jim Meyering  <jim@meyering.net>
32727
32728         Perform one more "_.h" -> ".in.h" substitution.
32729         * modules/unistd (Makefile.am) [unistd.h]: Use unistd.h.in
32730         instead of unistd_.h here, too.
32731
32732 2007-10-01  Bruno Haible  <bruno@clisp.org>
32733
32734         * gnulib-tool (func_emit_initmacro_done): Special case for alloca.c.
32735         Needed for the alloca-opt module.
32736
32737 2007-09-30  Bruno Haible  <bruno@clisp.org>
32738
32739         * lib/alloca.in.h: Renamed from lib/alloca_.h.
32740         * modules/alloca-opt (Files, Makefile.am): Use alloca.in.h instead of
32741         alloca_.h.
32742         * lib/argz.in.h: Renamed from lib/argz_.h.
32743         * modules/argz (Files, Makefile.am): Use argz.in.h instead of argz_.h.
32744         * lib/byteswap.in.h: Renamed from lib/byteswap_.h.
32745         * modules/byteswap (Files, Makefile.am): Use byteswap.in.h instead of
32746         byteswap_.h.
32747         * lib/dirent.in.h: Renamed from lib/dirent_.h.
32748         * modules/fchdir (Files, Makefile.am): Use dirent.in.h instead of
32749         dirent_.h.
32750         * lib/fcntl.in.h: Renamed from lib/fcntl_.h.
32751         * modules/fcntl (Files, Makefile.am): Use fcntl.in.h instead of
32752         fcntl_.h.
32753         * lib/float.in.h: Renamed from lib/float_.h.
32754         * modules/float (Files, Makefile.am): Use float.in.h instead of
32755         float_.h.
32756         * lib/fnmatch.in.h: Renamed from lib/fnmatch_.h.
32757         * modules/fnmatch (Files, Makefile.am): Use fnmatch.in.h instead of
32758         fnmatch_.h.
32759         * lib/getopt.in.h: Renamed from lib/getopt_.h.
32760         * modules/getopt (Files, Makefile.am): Use getopt.in.h instead of
32761         getopt_.h.
32762         * lib/glob.in.h: Renamed from lib/glob_.h.
32763         * modules/glob (Files, Makefile.am): Use glob.in.h instead of glob_.h.
32764         * lib/iconv.in.h: Renamed from lib/iconv_.h.
32765         * modules/iconv_open (Files, Makefile.am): Use iconv.in.h instead of
32766         iconv_.h.
32767         * lib/inttypes.in.h: Renamed from lib/inttypes_.h.
32768         * modules/inttypes (Files, Makefile.am): Use inttypes.in.h instead of
32769         inttypes_.h.
32770         * lib/locale.in.h: Renamed from lib/locale_.h.
32771         * modules/locale (Files, Makefile.am): Use locale.in.h instead of
32772         locale_.h.
32773         * lib/math.in.h: Renamed from lib/math_.h.
32774         * modules/math (Files, Makefile.am): Use math.in.h instead of math_.h.
32775         * lib/netinet_in.in.h: Renamed from lib/netinet_in_.h.
32776         * modules/netinet_in (Files, Makefile.am): Use netinet_in.in.h instead
32777         of netinet_in_.h. Add dependency.
32778         * lib/poll.in.h: Renamed from lib/poll_.h.
32779         * modules/poll (Files, Makefile.am): Use poll.in.h instead of poll_.h.
32780         * lib/search.in.h: Renamed from lib/search_.h.
32781         * modules/search (Files, Makefile.am): Use search.in.h instead of
32782         search_.h.
32783         * lib/signal.in.h: Renamed from lib/signal_.h.
32784         * modules/signal (Files, Makefile.am): Use signal.in.h instead of
32785         _signal.h.
32786         * lib/stdbool.in.h: Renamed from lib/stdbool_.h.
32787         * modules/stdbool (Files, Makefile.am): Use stdbool.in.h instead of
32788         stdbool_.h.
32789         * lib/stdint.in.h: Renamed from lib/stdint_.h.
32790         * modules/stdint (Files, Makefile.am): Use stdint.in.h instead of
32791         stdint_.h.
32792         * lib/stdio.in.h: Renamed from lib/stdio_.h.
32793         * modules/stdio (Files, Makefile.am): Use stdio.in.h instead of
32794         stdio_.h.
32795         * lib/stdlib.in.h: Renamed from lib/stdlib_.h.
32796         * modules/stdlib (Files, Makefile.am): Use stdlib.in.h instead of
32797         stdlib_.h.
32798         * lib/string.in.h: Renamed from lib/string_.h.
32799         * modules/string (Files, Makefile.am): Use string.in.h instead of
32800         string_.h.
32801         * doc/gnulib-tool.texi (Initial import): Update.
32802         * lib/sys_select.in.h: Renamed from lib/sys_select_.h.
32803         * modules/sys_select (Files, Makefile.am): Use sys_select.in.h instead
32804         of sys_select_.h. Add dependency.
32805         * lib/sys_socket.in.h: Renamed from lib/sys_socket_.h.
32806         * modules/sys_socket (Files, Makefile.am): Use sys_socket.in.h instead
32807         of sys_socket_.h.
32808         * lib/sys_stat.in.h: Renamed from lib/sys_stat_.h.
32809         * modules/sys_stat (Files, Makefile.am): Use sys_stat.in.h instead of
32810         sys_stat_.h.
32811         * lib/sys_time.in.h: Renamed from lib/sys_time_.h.
32812         * modules/sys_time (Files, Makefile.am): Use sys_time.in.h instead of
32813         sys_time_.h.
32814         * lib/sysexits.in.h: Renamed from lib/sysexits_.h.
32815         * modules/sysexits (Files, Makefile.am): Use sysexits.in.h instead of
32816         sysexits_.h.
32817         * lib/time.in.h: Renamed from lib/time_.h.
32818         * modules/time (Files, Makefile.am): Use time.in.h instead of time_.h.
32819         * lib/unistd.in.h: Renamed from lib/unistd_.h.
32820         * modules/unistd (Files, Makefile.am): Use unistd.in.h instead of
32821         unistd_.h.
32822         * lib/wchar.in.h: Renamed from lib/wchar_.h.
32823         * modules/wchar (Files, Makefile.am): Use wchar.in.h instead of
32824         wchar_.h.
32825         * lib/wctype.in.h: Renamed from lib/wctype_.h.
32826         * modules/wctype (Files, Makefile.am): Use wctype.in.h instead of
32827         wctype_.h.
32828         * build-aux/bootstrap (slurp): Update.
32829         * lib/.cppi-disable: Update.
32830
32831 2007-09-30  Bruno Haible  <bruno@clisp.org>
32832
32833         * tests/test-getaddrinfo.c (AF_UNSPEC): Provide a fallback definition.
32834         Needed on BeOS.
32835
32836 2007-09-30  Bruno Haible  <bruno@clisp.org>
32837
32838         * modules/dirname-tests (check_PROGRAMS): Renamed from noinst_PROGRAMS.
32839
32840 2007-09-29  Bruno Haible  <bruno@clisp.org>
32841
32842         * lib/stdio_.h (getdelim, getline): Add identifiers. Doc tweak.
32843
32844 2007-09-29  Bruno Haible  <bruno@clisp.org>
32845
32846         * lib/xreadlink.c (xreadlink): Simplify to a wrapper around areadlink.
32847         * modules/xreadlink (Depends-on): Add areadlink, remove readlink etc.
32848         * build-aux/install-reloc: Compile also areadlink.c.
32849         * modules/relocatable-prog-wrapper (Files): Add lib/areadlink.[hc].
32850
32851 2007-09-29  Bruno Haible  <bruno@clisp.org>
32852
32853         * gnulib-tool (func_emit_initmacro_done): Indentation.
32854
32855 2007-09-29  Bruno Haible  <bruno@clisp.org>
32856
32857         * README: Add CVS checkout update instructions.
32858         Info from Bob Proulx <bob@proulx.com>.
32859
32860 2007-09-28  Eric Blake  <ebb9@byu.net>
32861
32862         Provide move-if-change.
32863         * build-aux/move-if-change: New file, based on best practice
32864         rather than any canonical upstream location.
32865
32866 2007-09-28  Jim Meyering  <jim@meyering.net>
32867
32868         Fix canonicalize loop-detection corner case.
32869         Do not attempt to stat the symlink values stored via seen_triple.
32870         Without this, coreutils' tests/misc/readlink-fp-loop test would fail
32871         on linux-2.6.18, (but not 2.6.22).
32872         * lib/canonicalize.c (seen_triple): Use triple_compare_ino_str, not
32873         triple_compare.  The former compares dev,ino,filename, while the latter
32874         would actually stat dirname(filename) when dev and ino were equal.
32875         * lib/hash-triple.c: Install <string.h>.
32876         (STREQ): Define.
32877         (triple_compare_ino_str): New function.
32878         * lib/hash-triple.h (triple_compare_ino_str): Declare it.
32879
32880 2007-09-28  Eric Blake  <ebb9@byu.net>
32881
32882         Enforce that AC_REPLACE_FUNCS files exist.
32883         * gnulib-tool (func_emit_initmacro_done): Make AC_LIBSOURCES
32884         override check for typos.
32885
32886         Fix test-closein on Solaris 10.
32887         * tests/test-closein.c (main): Don't assume stdin can be inherited
32888         closed on all systems.
32889         * tests/test-closein.sh: Likewise.
32890         Reported by Piotr Tarnowski.
32891
32892 2007-09-28  Jim Meyering  <jim@meyering.net>
32893
32894         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Fix typo in comment.
32895
32896 2007-09-27  Jim Meyering  <jim@meyering.net>
32897
32898         canonicalize: Avoid a false-positive cycle failure.
32899         * modules/canonicalize (Depends-on): Add file-set and hash-triple.
32900         Sort.  Remove cycle-check.
32901         * lib/canonicalize.c: Include file-set.h and hash-triple.h,
32902         not cycle-check.h.
32903         (seen_triple): New function.
32904         (canonicalize_filename_mode): Use it instead of cycle-check.
32905         * tests/test-canonicalize.c: Add a test for this bug.
32906         * tests/test-canonicalize.sh: Set up and run the test.
32907
32908         New module, file-set, from coreutils.
32909         * modules/file-set: Define it.
32910         * lib/file-set.c, lib/file-set.h: Implement.
32911
32912         New module, hash-triple, from coreutils.
32913         * modules/hash-triple: Define it.
32914         * lib/hash-triple.c, lib/hash-triple.h: Implement.
32915
32916 2007-09-25  Eric Blake  <ebb9@byu.net>
32917
32918         Fix strerror on Interix.
32919         * lib/string_.h (strerror): Declare replacement.
32920         * doc/functions/strerror.texi (strerror): Document the Interix
32921         shortcoming.
32922         * modules/string (Makefile.am): Support new hooks.
32923         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Add new hooks.
32924         * m4/strerror.m4 (gl_FUNC_STRERROR): Defer to
32925         gl_FUNC_STRERROR_SEPARATE.
32926         (gl_FUNC_STRERROR_SEPARATE): Check for Interix bug.
32927         * lib/strerror.c (rpl_strerror): Provide replacement.
32928         * modules/strerror (Depends-on): Add string.
32929         (configure.ac): Detect use of module.
32930         * tests/test-strerror.c: New file.
32931         * modules/strerror-tests: New test module.
32932         * modules/argp (Depends-on): Add strerror.
32933         * modules/error (Depends-on): Likewise.
32934         Reported by Martin Koeppe.
32935
32936 2007-09-24  Bruno Haible  <bruno@clisp.org>
32937
32938         * README: Update git instructions.
32939
32940 2007-09-24  Eric Blake  <ebb9@byu.net>
32941
32942         Revert fpending breakage from 2007-09-08.
32943         * m4/fpending.m4 (gl_FUNC_FPENDING): Don't require existence of
32944         __fpending.c.
32945
32946 2007-09-24  Jim Meyering  <jim@meyering.net>
32947
32948         filenamecat.c: Add a test.
32949         * lib/filenamecat.c (main) [TEST_FILE_NAME_CONCAT]: Add a test
32950         showing how the function works when DIR is the empty string.
32951
32952 2007-09-21  Simon Josefsson  <simon@josefsson.org>
32953
32954         * tests/test-canonicalize.sh: Turn on executable bit.
32955
32956 2007-09-19  Eric Blake  <ebb9@byu.net>
32957
32958         * README: Update CVS instructions.
32959
32960 2007-09-18  Bruno Haible  <bruno@clisp.org>
32961
32962         * modules/areadlink: New file.
32963         * lib/areadlink.h (areadlink): New declaration.
32964         * lib/areadlink.c: New file, based on lib/xreadlink.c.
32965
32966 2007-09-17  Jim Meyering  <jim@meyering.net>
32967
32968         * lib/savewd.c (ESTALE) [!defined]: Define.
32969         Reported to be required on Interix by Martin Koeppe.
32970
32971 2007-09-17  Bruno Haible  <bruno@clisp.org>
32972
32973         * gnulib-tool (func_version): Use $version.
32974
32975 2007-09-16  Bruno Haible  <bruno@clisp.org>
32976
32977         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE, gl_PRINTF_INFINITE,
32978         gl_PRINTF_INFINITE_LONG_DOUBLE): Increase buf's size from 100 to 10000.
32979         Needed on glibc-2.6.1 with -fstack-protector -D_FORTIFY_SOURCE=2.
32980         Reported by Greg Schafer <gschafer@zip.com.au>.
32981
32982 2007-09-15  Bruno Haible  <bruno@clisp.org>
32983
32984         * gnulib-tool (sed): Try a little harder to make bash understand the
32985         alias.
32986         Reported by Bruce Korb <bruce.korb@gmail.com>.
32987
32988 2007-09-13  Eric Blake  <ebb9@byu.net>
32989
32990         * ChangeLog: Remove conflict markers.
32991
32992 2007-09-13  Simon Josefsson  <simon@josefsson.org>
32993
32994         * lib/gc-gnulib.c (gc_hash_open): Catch NULL calloc return value.
32995         Reported by Bruno Haible <bruno@clisp.org>.
32996
32997 2007-09-12  Bruno Haible  <bruno@clisp.org>
32998
32999         * m4/lock.m4: Don't provide an AC_USE_SYSTEM_EXTENSIONS definition.
33000         (gl_LOCK_EARLY_BODY): Use AC_GNU_SOURCE when AC_USE_SYSTEM_EXTENSIONS
33001         is not defined.
33002
33003 2007-09-12  Eric Blake  <ebb9@byu.net>
33004
33005         Track CVS Autoconf on AC_USE_SYSTEM_EXTENSIONS.
33006         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Update to CVS
33007         Autoconf definition.
33008         * modules/euidaccess (Depends-on): Add extensions, for
33009         AC_USE_SYSTEM_EXTENSIONS with autoconf <= 2.59.
33010         * modules/fnmatch (Depends-on): Likewise.
33011         * modules/getaddrinfo (Depends-on): Likewise.
33012         * modules/getdelim (Depends-on): Likewise.
33013         * modules/getline (Depends-on): Likewise.
33014         * modules/getsubopt (Depends-on): Likewise.
33015         * modules/gettext (Depends-on): Likewise.
33016         * modules/group-member (Depends-on): Likewise.
33017         * modules/mbchar (Depends-on): Likewise.
33018         * modules/memmem (Depends-on): Likewise.
33019         * modules/mempcpy (Depends-on): Likewise.
33020         * modules/memrchr (Depends-on): Likewise.
33021         * modules/pagealign_alloc (Depends-on): Likewise.
33022         * modules/readutmp (Depends-on): Likewise.
33023         * modules/stpcpy (Depends-on): Likewise.
33024         * modules/stpncpy (Depends-on): Likewise.
33025         * modules/strchrnul (Depends-on): Likewise.
33026         * modules/strndup (Depends-on): Likewise.
33027         * modules/strsep (Depends-on): Likewise.
33028         * modules/strverscmp (Depends-on): Likewise.
33029         * modules/vasprintf (Depends-on): Likewise.
33030         * modules/wcwidth (Depends-on): Likewise.
33031         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): AC_GNU_SOURCE will be
33032         obsolete in Autoconf 2.62; use AC_USE_SYSTEM_EXTENSIONS instead.
33033         * m4/fnmatch.m4 (gl_FUNC_FNMATCH_GNU): Likewise.
33034         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDR_INFO): Likewise.
33035         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Likewise.
33036         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
33037         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Likewise.
33038         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
33039         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER): Likewise.
33040         * m4/mbchar.m4 (gl_MBCHAR): Likewise.
33041         * m4/memmem.m4 (gl_FUNC_MEMMEM): Likewise.
33042         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
33043         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
33044         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Likewise.
33045         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC): Likewise.
33046         * m4/readutmp.m4 (gl_READUTMP): Likewise.
33047         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
33048         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
33049         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
33050         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
33051         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
33052         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
33053         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
33054         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP): Likewise.
33055         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): Likewise.
33056         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
33057         * m4/lock.m4 (gl_LOCK_EARLY_BODY): Likewise, but provide fallback,
33058         so that lock.m4 can be used in gettext without extensions module.
33059
33060 2007-09-11  Bruno Haible  <bruno@clisp.org>
33061
33062         * m4/isc-posix.m4: Remove file.
33063         Suggested by Eric Blake.
33064
33065 2007-09-11  Eric Blake  <ebb9@byu.net>
33066
33067         * ChangeLog: Restore lines accidentally truncated 2007-04-06.
33068
33069 2007-09-10  Bruno Haible  <bruno@clisp.org>
33070
33071         * posix-modules: Fix typo in error message.
33072         Reported by Matt <mkraai@beckman.com>.
33073
33074 2007-09-09  Bruno Haible  <bruno@clisp.org>
33075
33076         * doc/functions/getdelim.texi: Update list of platforms lacking the
33077         function.
33078         * doc/functions/getline.texi: Likewise.
33079
33080 2007-09-09  Jim Meyering  <jim@meyering.net>
33081
33082         * lib/hash.c (hash_initialize): Detect calloc failure.
33083         Reported by Bruno Haible.
33084
33085 2007-09-09  Bruno Haible  <bruno@clisp.org>
33086
33087         * lib/canonicalize-lgpl.c (__realpath): Set errno to ENOMEM when
33088         malloc or realloc fails.
33089
33090 2007-09-09  Bruno Haible  <bruno@clisp.org>
33091
33092         * modules/getcwd (Depends-on): Add malloc-posix.
33093         * modules/glob (Depends-on): Likewise.
33094         * modules/putenv (Depends-on): Likewise.
33095         * modules/strdup (Depends-on): Likewise.
33096         * modules/getdelim (Depends-on): Add realloc-posix.
33097         * modules/read-file (Depends-on): Likewise.
33098
33099 2007-09-09  Bruno Haible  <bruno@clisp.org>
33100
33101         * m4/malloc.m4 (gl_CHECK_MALLOC_POSIX): New macro.
33102         (gl_FUNC_MALLOC_POSIX): Require it.
33103         * m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
33104         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Likewise.
33105         * modules/realloc (Files): Add m4/malloc.m4.
33106         * modules/calloc (Files): Likewise.
33107
33108 2007-09-09  Bruno Haible  <bruno@clisp.org>
33109
33110         * modules/malloc-posix: New file.
33111         * modules/malloc (Depends-on): Add malloc-posix.
33112         * lib/malloc.c: Include errno.h.
33113         (rpl_malloc): Merge the requirements of a glibc-compatible malloc
33114         and a POSIX-compatible malloc into a single function. Set ENOMEM
33115         when returning NULL.
33116         * m4/malloc.m4: New file.
33117         * doc/functions/malloc.texi: Mention the malloc-posix module.
33118         * lib/stdlib_.h (malloc): New declaration.
33119         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
33120         GNULIB_MALLOC_POSIX and HAVE_MALLOC_POSIX.
33121         * modules/stdlib (stdlib.h): Substitute also GNULIB_MALLOC_POSIX
33122         and HAVE_MALLOC_POSIX.
33123
33124 2007-09-09  Bruno Haible  <bruno@clisp.org>
33125
33126         * modules/realloc-posix: New file.
33127         * modules/realloc (Depends-on): Add realloc-posix.
33128         * lib/realloc.c: Include errno.h.
33129         (rpl_realloc): Merge the requirements of a glibc-compatible realloc
33130         and a POSIX-compatible realloc into a single function. Set ENOMEM
33131         when returning NULL.
33132         * m4/realloc.m4: New file.
33133         * doc/functions/realloc.texi: Mention the realloc-posix module.
33134         * lib/stdlib_.h (realloc): New declaration.
33135         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
33136         GNULIB_REALLOC_POSIX and HAVE_REALLOC_POSIX.
33137         * modules/stdlib (stdlib.h): Substitute also GNULIB_REALLOC_POSIX
33138         and HAVE_REALLOC_POSIX.
33139
33140 2007-09-09  Bruno Haible  <bruno@clisp.org>
33141
33142         * modules/calloc-posix: New file.
33143         * modules/calloc (Depends-on): Add calloc-posix.
33144         * lib/calloc.c: Include errno.h.
33145         (rpl_calloc): Merge the requirements of a glibc-compatible calloc
33146         and a POSIX-compatible calloc into a single function. Set ENOMEM
33147         when returning NULL.
33148         * m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): New macro.
33149         * doc/functions/calloc.texi: Mention the calloc-posix module.
33150         * lib/stdlib_.h (calloc): New declaration.
33151         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
33152         GNULIB_CALLOC_POSIX and HAVE_CALLOC_POSIX.
33153         * modules/stdlib (stdlib.h): Substitute also GNULIB_CALLOC_POSIX
33154         and HAVE_CALLOC_POSIX.
33155
33156 2007-09-09  Bruno Haible  <bruno@clisp.org>
33157
33158         Allow for modules to show an arbitrary notice.
33159         * modules/TEMPLATE-EXTENDED: Add 'Notice' field.
33160         * gnulib-tool: New option --extract-notice.
33161         (func_usage): Document it.
33162         (sed_extract_prog): Update.
33163         (func_get_notice): New function.
33164         (func_modules_notice): New function.
33165         (func_import, func_create_testdir): Invoke it.
33166         Suggested by Jim Meyering.
33167
33168 2007-09-09  Bruno Haible  <bruno@clisp.org>
33169
33170         * gnulib-tool: New options --verbose, --quiet.
33171         (func_usage): Document them.
33172         (verbose): New variable.
33173         (func_execute_command): New function.
33174         (func_import): Don't show the module list and the file list if
33175         $verbose < 0.
33176         (func_create_testdir): Likewise. Use func_execute_command.
33177         (func_create_megatestdir): Use func_execute_command.
33178
33179 2007-09-08  Bruno Haible  <bruno@clisp.org>
33180
33181         * gnulib-tool (func_import): Prefer rsync over wget when available,
33182         for fetching the PO files.
33183
33184 2007-09-08  Bruno Haible  <bruno@clisp.org>
33185
33186         * posix-modules: New file. Portions copied from gnulib-tool.
33187         * doc/gnulib.texi (POSIX Substitutes Library): New chapter.
33188
33189 2007-09-08  Jim Meyering  <jim@meyering.net>
33190
33191         Rename __fpending.c -> fpending.c and __fpending.h -> fpending.h
33192         * lib/fpending.h: Rename from __fpending.h.
33193         * lib/fpending.c: Rename from __fpending.c.
33194         Include "fpending.h", not "__fpending.h".
33195         * lib/__fpending.h, lib/__fpending.c: Remove files.
33196         * modules/fpending (Files): Reflect new file names.
33197         * lib/close-stream.c: Include "fpending.h", not "__fpending.h".
33198
33199 2007-09-08  Bruno Haible  <bruno@clisp.org>
33200
33201         * m4/inttypes-h.m4: Remove stub file.
33202
33203 2007-09-07  Simon Josefsson  <simon@josefsson.org>
33204
33205         * doc/headers/stdint.texi: Discuss #include_next issue.
33206
33207 2007-09-06  Paul Eggert  <eggert@cs.ucla.edu>
33208
33209         * build-aux/bootstrap: Remove obsolete comment about wget --help.
33210
33211 2007-09-06  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
33212
33213         * m4/time_h.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Fix misspelling
33214         in variable name.
33215
33216 2007-09-03  Jim Meyering  <jim@meyering.net>
33217
33218         New module: git-version-gen.
33219         * modules/git-version-gen: New file.
33220
33221         Import changes from coreutils for bootstrap script.
33222
33223         * build-aux/bootstrap (WGET_COMMAND): Remove code to set this variable.
33224
33225         bootstrap: uses rsync to download the .po files
33226         * build-aux/bootstrap (po_download_command_format): New global.
33227         (download_po_files): Use rsync.
33228         (update_po_files): Don't remove .po files after download,
33229         so future rsync runs can take advantage of the copies.
33230
33231         * build-aux/bootstrap (gnulib_tool): Make sha1sum check quietly.
33232
33233         Solve the unnecessary-.po-file-regeneration problem once and for all.
33234         * build-aux/bootstrap (download_po_files): New function, renamed from
33235         get_translations.  Now, downloads, but doesn't update LINGUAS.
33236         (update_po_files): New function.
33237
33238         bootstrap: Ignore more.
33239         * build-aux/bootstrap (symlink_to_dir): Add a directory name like
33240         uniwidth to e.g., lib/.gitignore.
33241         (slurp): Handle the sys_stat_.h -> sys mapping, too.
33242
33243         * build-aux/bootstrap: New setting: vc_ignore.
33244         (insert_sorted_if_absent): Create $file if absent.
33245         Adapt to new, possibly empty, list: $vc_ignore.
33246
33247         bootstrap: generate more ignorable names
33248         * build-aux/bootstrap (slurp): When generating ignorable names,
33249         also map .sin to .sed, .gperf to .c, and .y to .c.
33250
33251 2007-09-03  Jim Meyering  <jim@meyering.net>
33252
33253         * build-aux/git-version-gen: New file, from coreutils.  For details, see
33254         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commitdiff;h=bfe49f506
33255
33256 2007-09-02  Bruno Haible  <bruno@clisp.org>
33257
33258         Fix mis-recognition of 'mcs' on QNX 6.
33259         * m4/csharpcomp.m4 (gt_CSHARPCOMP): Test whether the "mcs --version"
33260         output contains the string "Mono".
33261         * lib/csharpcomp.c (compile_csharp_using_mono): Likewise.
33262         Reported by <kraai@ftbfs.org> at <https://savannah.gnu.org/bugs/?18337>.
33263
33264 2007-09-01  Bruno Haible  <bruno@clisp.org>
33265
33266         Fix collision between uniwidth/* and linebreak modules.
33267         * lib/linebreak.h (locale_charset, uc_width, u8_width, u16_width,
33268         u32_width): Remove declarations.
33269         * lib/linebreak.c: Include uniwidth.h, uniwidth/cjk.h, streq.h.
33270         (u32_mbtouc_unsafe, streq9, streq8, streq7, streq6, streq5, streq4,
33271         streq3, streq2, streq1, streq0): Remove functions.
33272         (STREQ): Remove macro.
33273         (is_cjk_encoding): Remove function.
33274         (nonspacing_table_data, nonspacing_table_ind): Remove constants.
33275         (uc_width, u8_width, u16_width, u32_width): Remove functions.
33276         * modules/linebreak (Depends-on): Add streq, uniwidth/width.
33277         * NEWS: Document the change.
33278
33279 2007-09-01  Bruno Haible  <bruno@clisp.org>
33280
33281         * lib/streq.h: Add double-inclusion guard.
33282
33283 2007-09-01  Karl Berry  <karl@gnu.org>
33284
33285         * MODULES.html.sh: Rename mreadlink_with_size to areadlink_with_size.
33286
33287 2007-08-28  Jim Meyering  <jim@meyering.net>
33288
33289         Rename mreadlink_with_size to areadlink_with_size.
33290         * NEWS: Document the change.
33291         * lib/mreadlink-with-size.c (mreadlink_with_size): Rename this to...
33292         * lib/areadlink-with-size.c (areadlink_with_size): ...this.
33293         * lib/mreadlink.h: Rename this to...
33294         * lib/areadlink.h: ...this.
33295         * modules/mreadlink-with-size: Rename this to...
33296         * modules/areadlink-with-size: ...this.
33297         * lib/canonicalize.c: Reflect the renaming.
33298         * modules/canonicalize: Likewise.
33299
33300 2007-08-26  Bruno Haible  <bruno@clisp.org>
33301
33302         * gnulib-tool (func_import): When deciding which files to remove,
33303         consider also dangling symbolic links.
33304         Reported by Eric Blake.
33305
33306 2007-08-26  Bruno Haible  <bruno@clisp.org>
33307
33308         * gnulib-tool (func_ln_if_changed): Use "test -h", not "test -L".
33309
33310 2007-08-23  Simon Josefsson  <simon@josefsson.org>
33311
33312         * lib/readline.c: Don't include getline.h, the prototype is now
33313         found in stdio.h.
33314
33315 2007-08-23  Jim Meyering  <jim@meyering.net>
33316
33317         Getdelim touchup.
33318         * lib/getdelim.c (getdelim): Don't bother to save/restore errno
33319         around the funlockfile call, since funlockfile never sets errno.
33320         Don't set errno upon failed realloc.
33321
33322 2007-08-22  Eric Blake  <ebb9@byu.net>
33323
33324         Getline touchups.
33325         * lib/getdelim.c (getdelim): Revert regression that required *n to
33326         be 0 when *lineptr is NULL.  Preserve errno across funlockfile.
33327         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Check for declaration of
33328         getdelim, rather than whether implementation is missing.
33329         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise for getline.
33330         * lib/stdio_.h (getline): Also declare if replacement is
33331         required.
33332         * doc/functions/getdelim.texi: New file.
33333         * doc/functions/getline.texi: Likewise.
33334         * doc/gnulib.texi (Function Substitutes): Add new files.
33335         Reported by Bruno Haible.
33336
33337 2007-08-22  Ludovic Courtès  <ludo@gnu.org>
33338
33339         * users.txt: Add Guile.
33340
33341 2007-08-22  Eric Blake  <ebb9@byu.net>
33342
33343         * tests/test-getdelim.c (main): Use remove, not unlink.
33344         * tests/test-getline.c (main): Likewise.
33345
33346         Move getline and getdelim into stdio.h, per POSIX 200x.
33347         * modules/getline (Files): Remove getline.h.
33348         (Depends-on): Add stdio.
33349         (configure.ac): Add module indicator.
33350         * modules/getdelim (Files): Remove getdelim.h.
33351         (Depends-on): Add stdio.
33352         (configure.ac): Add module indicator.
33353         * modules/stdio (Makefile.am): Work with new indicators.
33354         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Add new defaults.
33355         * m4/getdelim.m4 (gl_FUNC_GETDELIM): Work with stdio needs.
33356         * m4/getline.m4 (gl_FUNC_GETLINE): Likewise.
33357         * lib/getdelim.h: Delete.
33358         * lib/getline.h: Delete.
33359         * lib/stdio_.h (getdelim, getline): Declare.
33360         * modules/getdelim-tests: New module.
33361         * modules/getline-tests: Likewise.
33362         * tests/test-getdelim.c: New file.
33363         * tests/test-getline.c: Likewise.
33364         * NEWS: Document the change.
33365         * lib/getline.c: Update choice of header.
33366         * lib/csharpcomp.c: Likewise.
33367         * lib/getpass.c: Likewise.
33368         * lib/javacomp.c: Likewise.
33369         * lib/javaversion.c: Likewise.
33370         * lib/yesno.c: Likewise.
33371         * lib/getdelim.c: Likewise.
33372         (getdelim): Set errno on failure, and avoid memory leak.
33373
33374 2007-08-19  Bruno Haible  <bruno@clisp.org>
33375
33376         * modules/closein (Depends-on): Add freadahead.
33377         * lib/closein.c: Include freadahead.h.
33378         (close_stdin): Skip the fseeko and fflush calls if freadahead(stdin)
33379         is zero.
33380
33381 2007-08-19  Bruno Haible  <bruno@clisp.org>
33382
33383         * modules/freadahead-tests: New file.
33384         * tests/test-freadahead.sh: New file.
33385         * tests/test-freadahead.c: New file.
33386
33387         * modules/freadahead: New file.
33388         * lib/freadahead.h: New file.
33389         * lib/freadahead.c: New file.
33390         * MODULES.html.sh (File stream based Input/Output): Add freadahead,
33391         fbufmode, fpurge, freadable, fwritable.
33392
33393 2007-08-19  Eric Blake  <ebb9@byu.net>
33394
33395         Test yesno in combination with closein.
33396         * lib/yesno.c (yesno): Document use of stdin.
33397         * modules/yesno-tests (Files): New module.
33398         * tests/test-yesno.c (main): New file.
33399         * tests/test-yesno.sh: Likewise.
33400
33401 2007-08-19  Bruno Haible  <bruno@clisp.org>
33402
33403         * lib/fbufmode.c (fbufmode): Add tentative support for Solaris/AMD64.
33404         * lib/fseeko.c (rpl_fseeko): Likewise.
33405         * lib/fseterr.c (fseterr): Likewise.
33406
33407 2007-08-19  Bruno Haible  <bruno@clisp.org>
33408
33409         * tests/test-lseek.c (main): Disable a test for BeOS.
33410         * doc/functions/lseek.texi: Document the BeOS bug.
33411
33412 2007-08-19  Bruno Haible  <bruno@clisp.org>
33413             Eric Blake  <ebb9@byu.net>
33414
33415         * lib/lseek.c: Include <sys/stat.h>.
33416         (rpl_lseek): Add workaround code also for Unix platforms.
33417         Needed for BeOS.
33418         * m4/lseek.m4 (gl_FUNC_LSEEK): When cross-compiling, fail on BeOS.
33419         * doc/functions/lseek.texi: Document BeOS definiency.
33420
33421 2007-08-18  Bruno Haible  <bruno@clisp.org>
33422
33423         * modules/fstrcmp-tests: New file.
33424         * tests/test-fstrcmp.c: New file.
33425
33426 2007-08-18  Bruno Haible  <bruno@clisp.org>
33427
33428         * modules/fstrcmp: New file, from GNU gettext with modifications.
33429         * lib/fstrcmp.h: New file, from GNU gettext.
33430         * lib/fstrcmp.c: New file, from GNU gettext.
33431         * MODULES.html.sh (String handling): Add fstrcmp.
33432
33433 2007-08-18  Bruno Haible  <bruno@clisp.org>
33434
33435         * lib/diffseq.h (struct context): Change type of 'heuristic' field to
33436         'bool'.
33437         (diag, compareseq): Remove const from the ctxt argument.
33438         (USE_HEURISTIC): Undefine at the end.
33439
33440 2007-08-18  Jim Meyering  <jim@meyering.net>
33441
33442         New file: lib/idcache.h
33443         * NEWS: Mention the addition.
33444         * modules/idcache (Files): Add lib/idcache.h
33445         * lib/idcache.c: Include "idcache.h".
33446         Don't include <sys/types.h>.
33447         Add a FIXME comment.
33448         Move file-scoped "static" declarations to the top.
33449         * lib/idcache.h: New file.  Include <sys/types.h> here, instead.
33450
33451 2007-08-17  Bruno Haible  <bruno@clisp.org>
33452         and Paul Eggert  <eggert@cs.ucla.edu>
33453
33454         * MODULES.html.sh: Add diffseq.
33455         * modules/diffseq: New file.
33456         * lib/diffseq.h: New file, from GNU gettext with a few minor changes,
33457         extracted from GNU gettext's fstrcmp.c and GNU diff's analyze.c.
33458
33459 2007-08-15  Paul Eggert  <eggert@cs.ucla.edu>
33460
33461         Import changes from coreutils for bootstrap script.
33462
33463         2007-07-21  Paul Eggert  <eggert@cs.ucla.edu>
33464
33465         * build-aux/bootstrap (slurp): Work even in environments where
33466         "ls" defaults to "ls -A".  Put in a FIXME, though, since the
33467         current code does not slurp files whose names start with ".", and
33468         this looks like it might be a troublesome area.
33469
33470         2007-07-11  Jim Meyering  <jim@meyering.net>
33471
33472         If there's a GPL vN copyright comment, require that N == 3.
33473
33474         2007-07-08  Jim Meyering  <jim@meyering.net>
33475
33476         Run the coreutils-specific code only if tests/Makefile.am.in exists.
33477         * build-aux/bootstrap (mam_template): Move definition out of loop.
33478
33479         Create symlinks for gl/{lib,m4}/*, just as for gnulib/{lib,m4}/*.
33480
33481         * build-aux/bootstrap (symlink_to_dir): Rename function from
33482         symlink_to_gnulib.  Add a directory parameter.  Update all
33483         callers.
33484         (cp_mark_as_generated): Also check for -- and link to -- files in
33485         gl/.
33486
33487         2007-07-08  Jim Meyering  <jim@meyering.net>
33488
33489         Adapt to deeper hierarchy in gnulib.
33490         * build-aux/bootstrap (symlink_to_dir): If the destination
33491         directory doesn't exist, create it. This is required at least for
33492         "lib/uniwidth/cjk.h".
33493
33494         2007-05-15  Jim Meyering  <jim@meyering.net>
33495
33496         * build-aux/bootstrap: Now that generated Makefile.am files
33497         are no longer under version control, they must be created at
33498         bootstrap time.
33499
33500 2007-08-14  Ben Pfaff  <blp@gnu.org>
33501
33502         * lib/count-one-bits.h: Add comments.  From Bruno Haible.
33503
33504 2007-08-14  Paul Eggert  <eggert@cs.ucla.edu>
33505
33506         * lib/count-one-bits.h: Don't include <limits.h>; no longer needed
33507         given the changes below.
33508         (COUNT_ONE_BITS): Use 'verify' rather than 'verify_true'.  Work
33509         even on hosts that have padding bits beyond the supported 64.
33510
33511 2007-08-10  Paul Eggert  <eggert@cs.ucla.edu>
33512
33513         * NEWS: In xstrtol, remove STRTOL_FATAL_ERROR and add xstrtol_fatal.
33514         * lib/xstrtol.h: Don't include exitfail.h; that's now internal to
33515         xstrtol.c.  Include getopt.h, since xstrtol_fatal's signature
33516         depends on it.
33517         (xstrtol_error): Remove.
33518         (xstrtol_fatal): New decl, replacing the functionality of xstrtol_error
33519         but with a different signature.
33520         (ATTRIBUTE_NORETURN, __attribute__): New macros.
33521         * lib/xstrtol-error.c: Include exitfail.h.
33522         (xstrtol_fatal): New function, with a different signature from the
33523         old xstrtol_error, so that the caller need not worry about passing
33524         in an exit status, or about storage management of the option argument.
33525         (xstrtol_error): Now a static function.  Redo signature to
33526         implement xstrtol_fatal.  Output the correct number of hyphens in
33527         front of the option so that the caller need not worry about
33528         storage management.
33529         (N_): New macro.
33530         (_): Remove; not used now.
33531         * modules/xstrtol: Depend on getopt.
33532         * tests/test-xstrtol.c (main): Use new xstrtol_error function instead
33533         of old STRTOL_FATAL_ERROR macro.
33534         * tests/test-xstrtol.sh (t-xstrtol.xo): Adjust to match new behavior
33535         of test program.
33536         * tests/test-xstrtoimax.sh (t-xstrtoimax.xo): Likewise.
33537         * tests/test-xstrtoumax.sh (t-xstrtoumax.xo): Likewise.
33538
33539 2007-08-08  Eric Blake  <ebb9@byu.net>
33540
33541         * lib/xstrtol-error.c: Add missing include.
33542
33543         Move xstrtol messages into gnulib domain, when --pobase is used.
33544         * lib/xstrtol.h (_STRTOL_ERROR): Move messages out of macro...
33545         * lib/xstrtol-error.c (xstrtol_error): ...into new file.
33546         * modules/xstrtol (Files): Distribute new file.
33547         * m4/xstrtol.m4 (gl_XSTRTOL): Build new file.
33548         * lib/xstrtol.c (TESTING_XSTRTO): Move tests...
33549         * tests/test-xstrtol.c: ...into new file.
33550         * tests/test-xstrtoul.c: Also test xstrtoul.
33551         * tests/test-xstrtoimax.c: Also test xstrtoimax.
33552         * tests/test-xstrtoumax.c: Also test xstrtoumax.
33553         * tests/test-xstrtol.sh: Drive the tests.
33554         * tests/test-xstrtoimax.sh: Likewise.
33555         * tests/test-xstrtoumax.sh: Likewise.
33556         * modules/xstrtol-tests: New module.
33557         * modules/xstrtoimax-tests: Likewise.
33558         * modules/xstrtoumax-tests: Likewise.
33559
33560 2007-08-08  Jim Meyering  <jim@meyering.net>
33561
33562         New function: mfile_name_concat.
33563         * lib/filenamecat.c (mfile_name_concat): New function, just like
33564         file_name_concat, but return NULL upon failure rather than exiting
33565         with a diagnostic.
33566         * lib/filenamecat.h: Declare it.
33567
33568 2007-08-07  Bruno Haible  <bruno@clisp.org>
33569
33570         * m4/inttypes.m4 (gl_INTTYPES_H): Use GL_TRIGGER_STDC_LIMIT_MACROS
33571         instead of __STDC_LIMIT_MACROS_TRIGGER. This avoids a redefinition
33572         warning from gcc.
33573         Reported by Eric Blake.
33574
33575 2007-08-07  Simon Josefsson  <simon@josefsson.org>
33576
33577         * modules/crypto/arctwo (License): Use the synonymous term "LGPLv2+".
33578         * modules/crypto/arcfour (License): Likewise.
33579         * modules/crypto/des-tests (License): Likewise.
33580         * modules/crypto/gc-arctwo-tests (License): Likewise.
33581         * modules/crypto/gc-des-tests (License): Likewise.
33582         * modules/crypto/gc-hmac-md5-tests (License): Likewise.
33583         * modules/crypto/gc-hmac-sha1-tests (License): Likewise.
33584         * modules/crypto/gc-md2-tests (License): Likewise.
33585         * modules/crypto/gc-md4-tests (License): Likewise.
33586         * modules/crypto/gc-md5-tests (License): Likewise.
33587         * modules/crypto/gc-pbkdf2-sha1-tests (License): Likewise.
33588         * modules/crypto/gc-rijndael-tests (License): Likewise.
33589         * modules/crypto/gc-sha1-tests (License): Likewise.
33590         * modules/crypto/gc-tests (License): Likewise.
33591         * modules/crypto/hmac-md5 (License): Likewise.
33592         * modules/crypto/hmac-sha1 (License): Likewise.
33593         * modules/crypto/md2-tests (License): Likewise.
33594         * modules/crypto/md4-tests (License): Likewise.
33595         * modules/crypto/md5 (License): Likewise.
33596         * modules/crypto/rijndael (License): Likewise.
33597         * modules/crypto/sha1 (License): Likewise.
33598         * modules/memxor (License): Likewise.
33599
33600 2007-08-06  Paul Eggert  <eggert@cs.ucla.edu>
33601         and Bruno Haible  <bruno@clisp.org>
33602
33603         * NEWS: Describe interface changes to human, xstrtol.
33604         * lib/human.h: Include <xstrtol.h>.
33605         (human_options): Return enum strtol_error, not int.  Remove
33606         bool arg; take int * instead.
33607         * lib/human.c: Don't include "gettext.h".
33608         (_): Remove; no longer used.
33609         Don't include <xstrtol.h>, since human.h does it.
33610         (human_options): Adjust to abovementioned interface changes.
33611         Do not report error to stderr; that's now the caller's
33612         responsibility.
33613         * lib/xstrtol.c (main) [defined TESTING_XSTRTO]: Adjust to
33614         interface change.
33615         * lib/xstrtol.h (_STRTOL_ERROR): Take Option, Arg rather than
33616         Str, Argument_type_string.  All uses changed.  Put " argument"
33617         in diagnostics to make them clearer.  Change wording of suffix
33618         message for clarity.
33619         (STRTOL_FATAL_ERROR): Take Option, Arg rather than Str,
33620         Argument_type_string.
33621         (STRTOL_FATAL_WARN): Remove; no longer used.
33622         * modules/human (Depends-on): Remove gettext-h.
33623
33624 2007-08-06  Simon Josefsson  <simon@josefsson.org>
33625
33626         * build-aux/maint.mk, build-aux/GNUmakefile: Relicense to GPLv3+.
33627
33628 2007-07-31  Bruno Haible  <bruno@clisp.org>
33629
33630         * m4/stdint.m4 (gl_STDINT_H): Test whether WCHAR_MIN and WCHAR_MAX
33631         are defined by <stdint.h> (as opposed to <wchar.h>, as on Dragonfly).
33632         Reported by Joerg Sonnenberger <joerg@britannica.bec.de>.
33633
33634 2007-07-31  Bruno Haible  <bruno@clisp.org>
33635
33636         * lib/fflush.c (rpl_fflush): On BSD systems, use the __SNPT flag.
33637         Suggested by Joerg Sonnenberger <joerg@britannica.bec.de>.
33638
33639 2007-07-30  Bruno Haible  <bruno@clisp.org>
33640
33641         * modules/base64 (License): Use the synonymous term "LGPLv2+".
33642         * modules/c-ctype (License): Likewise.
33643         * modules/c-strcase (License): Likewise.
33644         * modules/check-version (License): Likewise.
33645         * modules/iconv (License): Likewise.
33646         * modules/iconv_open (License): Likewise.
33647         * modules/read-file (License): Likewise.
33648         * modules/striconv (License): Likewise.
33649         * modules/strverscmp (License): Likewise.
33650         * modules/vasprintf (License): Likewise.
33651         * modules/crypto/des (License): Likewise.
33652         * modules/crypto/gc (License): Likewise.
33653         * modules/crypto/gc-arcfour (License): Likewise.
33654         * modules/crypto/gc-arctwo (License): Likewise.
33655         * modules/crypto/gc-des (License): Likewise.
33656         * modules/crypto/gc-hmac-md5 (License): Likewise.
33657         * modules/crypto/gc-hmac-sha1 (License): Likewise.
33658         * modules/crypto/gc-md2 (License): Likewise.
33659         * modules/crypto/gc-md4 (License): Likewise.
33660         * modules/crypto/gc-md5 (License): Likewise.
33661         * modules/crypto/gc-pbkdf2-sha1 (License): Likewise.
33662         * modules/crypto/gc-random (License): Likewise.
33663         * modules/crypto/gc-rijndael (License): Likewise.
33664         * modules/crypto/gc-sha1 (License): Likewise.
33665         * modules/crypto/md2 (License): Likewise.
33666         * modules/crypto/md4 (License): Likewise.
33667
33668 2007-07-30  Jim Meyering  <jim@meyering.net>
33669
33670         * lib/fts.c (fts_read): Upon failure to chdir into a subdirectory,
33671         set fts_info to FTS_DNR, not to FTS_ERR, so that the caller knows
33672         it has valid stat data.  This bug would cause du not to count the
33673         sizes of inaccessible directories.
33674         Patch by Bryan Mason <bmason@redhat.com>, via Jose Maria Plans
33675         in <http://bugzilla.redhat.com/250077>.
33676
33677 2007-07-25  Peter O'Gorman  <peter@pogma.com>
33678             Bruno Haible  <bruno@clisp.org>
33679
33680         * m4/include_next.m4 (gl_INCLUDE_NEXT): Test whether #include_next
33681         really works. Needed because AIX 4.3 "xlc -E" doesn't understand
33682         #include_next, gives a diagnostic about it, but reports no error in
33683         the exit code.
33684         Reported by Gary V. Vaughan <gary@thewrittenword.com>.
33685
33686 2007-07-24  Ben Pfaff  <blp@gnu.org>
33687
33688         Improve name: "count-one-bits" is better than "popcount".
33689         * MODULES.html.sh: Update name.
33690         * lib/popcount.h: Renamed lib/count-one-bits.h.
33691         (popcount): Renamed count_one_bits.
33692         (popcountl): Renamed count_one_bits_l.
33693         (popcountll): Renamed count_one_bits_ll.
33694         * m4/popcount.m4: Renamed m4/count-one-bits.m4.
33695         * modules/popcount: Renamed module/count-one-bits.
33696         * modules/popcount-tests: Renamed module/count-one-bits-tests.
33697         * tests/test-popcount.c: Renamed tests/test-count-one-bits.c.
33698
33699 2007-07-23  Ben Pfaff  <blp@gnu.org>
33700
33701         * lib/popcount.h (popcount32): Reduce size of constants, to allow
33702         better code generation, and add U to large constants to avoid
33703         warnings, in non-GCC case.
33704         Suggested by Bruno Haible.
33705
33706 2007-07-23  Ben Pfaff  <blp@gnu.org>
33707
33708         * lib/popcount.h: Use verify_true instead of if...abort.
33709         * modules/popcount: Depend on verify module.
33710         Suggested by Jim Meyering.
33711
33712 2007-07-23  Bruno Haible  <bruno@clisp.org>
33713
33714         * gnulib-tool (func_import): Create a .cvsignore file also when the
33715         directory is not yet in CVS but the toplevel directory is. When
33716         creating a .cvsignore file, add ".deps" and ".dirstamp" to it.
33717         Reported by Karl Berry.
33718
33719 2007-07-22  Ben Pfaff  <blp@gnu.org>
33720
33721         * lib/popcount.h: Use faster, branchless algorithm for non-GCC
33722         case.
33723         Suggested by Eric Blake.
33724
33725 2007-07-22  Ben Pfaff  <blp@gnu.org>
33726
33727         New module: popcount.
33728         * MODULES.html.sh: Add popcount.
33729         * modules/popcount: New file.
33730         * modules/popcount-tests: New file.
33731         * tests/test-popcount.c: New file.
33732         * lib/popcount.h: New file.
33733         * m4/popcount.m4: New file.
33734
33735 2007-07-22  Paul Eggert  <eggert@cs.ucla.edu>
33736
33737         * build-aux/announce-gen: Update to GPLv3.
33738
33739         * build-aux/config.guess: Update from config.
33740
33741 2007-07-21  Bruno Haible  <bruno@clisp.org>
33742
33743         * lib/error.c (_) [ENABLE_NLS]: Define to gettext.
33744         * lib/verror.c (_) [ENABLE_NLS]: Likewise.
33745
33746 2007-07-20  Jim Meyering  <jim@meyering.net>
33747
33748         * check-module: Diagnose a self-dependency.
33749
33750 2007-07-19  Bruno Haible  <bruno@clisp.org>
33751
33752         * gnulib-tool (func_import): Don't abort if pobase or po_domain is
33753         empty.
33754         Reported by Eric Blake.
33755
33756 2007-07-18  Bruno Haible  <bruno@clisp.org>
33757
33758         * gnulib-tool: New options --po-base, --po-domain.
33759         (func_usage): Document them.
33760         (pobase, po_domain): New variables.
33761         (func_emit_lib_Makefile_am): Augment AM_CPPFLAGS, defining
33762         DEFAULT_TEXT_DOMAIN.
33763         (func_emit_po_Makevars, func_emit_po_POTFILES_in): New functions.
33764         (func_import): Consider pobase and po_domain. Create a po/ directory.
33765         (func_create_testdir): Set pobase and po_domain to empty.
33766         * build-aux/po/Makefile.in.in: New file, from GNU gettext 0.16.1.
33767         * build-aux/po/remove-potcdate.sin: New file, from GNU gettext 0.16.1.
33768
33769 2007-07-18  Bruno Haible  <bruno@clisp.org>
33770
33771         * gnulib-tool (func_get_automake_snippet): Synthesize also an
33772         EXTRA_DIST augmentation for files in build-aux/.
33773
33774 2007-07-16  Bruno Haible  <bruno@clisp.org>
33775
33776         * modules/lseek (License): Use the synonymous term "LGPLv2+".
33777         * modules/getdelim (License): Likewise.
33778
33779 2007-07-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
33780
33781         * modules/arpa_inet (License): Use the synonymous term LGPLv2+.
33782         * modules/d-type (License): Likewise.
33783         * modules/extensions (License): Likewise.
33784         * modules/fnmatch (License): Likewise.
33785         * modules/fseeko (License): Likewise.
33786         * modules/getaddrinfo (License): Likewise.
33787         * modules/getline (License): Likewise.
33788         * modules/getlogin_r (License): Likewise.
33789         * modules/getpass (License): Likewise.
33790         * modules/gettimeofday (License): Likewise.
33791         * modules/glob (License): Likewise.
33792         * modules/inet_ntop (License): Likewise.
33793         * modules/malloc (License): Likewise.
33794         * modules/malloca (License): Likewise.
33795         * modules/memmem (License): Likewise.
33796         * modules/mempcpy (License): Likewise.
33797         * modules/memset (License): Likewise.
33798         * modules/minmax (License): Likewise.
33799         * modules/mktime (License): Likewise.
33800         * modules/netinet_in (License): Likewise.
33801         * modules/pathmax (License): Likewise.
33802         * modules/poll (License): Likewise.
33803         * modules/regex (License): Likewise.
33804         * modules/snprintf (License): Likewise.
33805         * modules/stdbool (License): Likewise.
33806         * modules/stdint (License): Likewise.
33807         * modules/stdio (License): Likewise.
33808         * modules/strcase (License): Likewise.
33809         * modules/strcasestr (License): Likewise.
33810         * modules/strdup (License): Likewise.
33811         * modules/string (License): Likewise.
33812         * modules/strndup (License): Likewise.
33813         * modules/strnlen (License): Likewise.
33814         * modules/strpbrk (License): Likewise.
33815         * modules/strptime (License): Likewise.
33816         * modules/strsep (License): Likewise.
33817         * modules/sys_select (License): Likewise.
33818         * modules/sys_socket (License): Likewise.
33819         * modules/sys_stat (License): Likewise.
33820         * modules/sys_time (License): Likewise.
33821         * modules/time (License): Likewise.
33822         * modules/time_r (License): Likewise.
33823         * modules/timegm (License): Likewise.
33824         * modules/unistd (License): Likewise.
33825         * modules/vsnprintf (License): Likewise.
33826         * modules/wctype (License): Likewise.
33827
33828 2007-07-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
33829
33830         * modules/argz (License): LGPLv2+.
33831
33832 2007-07-15  Karl Berry  <karl@gnu.org>
33833
33834         * doc/gnulib.texi: revise node structure per new fdl.texi.
33835
33836 2007-07-14  Bruno Haible  <bruno@clisp.org>
33837
33838         * lib/uniname/gen-uninames.lisp (main): Emit a "do not edit" line to
33839         the output file.
33840         * lib/uniname/uninames.h: Regenerated.
33841
33842 2007-07-14  Karl Berry  <karl@gnu.org>
33843
33844         * doc/*gpl*.texi, doc/fdl.texi: new versions, consistently
33845         omitting sectioning and index commands.
33846
33847 2007-07-13  Bruno Haible  <bruno@clisp.org>
33848
33849         New gnulib-tool option --more-symlinks.
33850         * gnulib-tool (func_usage): Document --more-symlinks.
33851         (do_copyrights): New variable.
33852         Recognize option --more-symlinks.
33853         (func_import): Don't add a copyright notice transform to
33854         sed_transform_lib_file if do_copyrights is empty.
33855
33856 2007-07-13  Bruno Haible  <bruno@clisp.org>
33857
33858         * lib/vasnprintf.c (decimal_point_char): Define also if
33859         (NEED_PRINTF_LONG_DOUBLE || NEED_PRINTF_INFINITE_DOUBLE)
33860         && !NEED_PRINTF_DIRECTIVE_A.
33861         Reported by Clemens Koller <clemens.koller@anagramm.de> via
33862         Gary V. Vaughan <gary@gnu.org>.
33863
33864 2007-07-13  Paul Eggert  <eggert@cs.ucla.edu>
33865
33866         * lib/inttypes_.h: Undo previous change, since it was fixed
33867         in a different way in the 2007-07-02 fix to m4/inttypes.m4.
33868
33869 2007-07-13  Bruno Haible  <bruno@clisp.org>
33870
33871         * lib/stdint_.h: Fix typo: _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H was
33872         misspelled as _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H.
33873
33874 2007-07-13  Jim Meyering  <jim@meyering.net>
33875
33876         df: Don't fail for Tru64's "file-on-file mount".
33877         * m4/fsusage.m4 (gl_FSUSAGE): Reject Tru64's buggy statvfs,
33878         so we fall through and use statfs instead.  Details here:
33879         <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/10878>
33880         Reported by Albert Chin.
33881
33882 2007-07-13  Bruno Haible  <bruno@clisp.org>
33883
33884         * modules/alloca-opt (License): Use the synonymous term "LGPLv2+".
33885         * modules/configmake (License): Likewise.
33886         * modules/gettext (License): Likewise.
33887         * modules/gettext-h (License): Likewise.
33888         * modules/include_next (License): Likewise.
33889         * modules/link-warning (License): Likewise.
33890         * modules/localcharset (License): Likewise.
33891         * modules/localename (License): Likewise.
33892         * modules/lock (License): Likewise.
33893         * modules/relocatable-lib-lgpl (License): Likewise.
33894         * modules/size_max (License): Likewise.
33895         * modules/vasnprintf (License): Likewise.
33896         * modules/wchar (License): Likewise.
33897         * modules/xsize (License): Likewise.
33898
33899 2007-07-13  Bruno Haible  <bruno@clisp.org>
33900
33901         * gnulib-tool (func_import): Treat LGPLv2 as synonymous to LGPL.
33902         (func_create_testdir): Handle copying terms "GPLv2+" and "LGPLv2+".
33903
33904 2007-07-12  Bruno Haible  <bruno@clisp.org>
33905
33906         * doc/gnulib-intro.texi (Copyright): Clarify the license abbreviations
33907         in the modules files.
33908
33909 2007-07-11  Karl Berry  <karl@gnu.org>
33910
33911         * MODULES.html.sh (func_module): use
33912          sed -e '\|^'"${includefile}"'$|d'
33913          instead of /.../d, to avoid errors on $includefile's containing /.
33914
33915 2007-07-10  Sergey Poznyakoff  <gray@gnu.org.ua>
33916
33917         * gnulib-tool (func_import): Avoid duplication of --avoid
33918         statements
33919         (func_dest_tmpfilename,func_create_testdir): Translate `-' in file
33920         names to `_' in variable names.
33921
33922 2007-07-10  Eric Blake  <ebb9@byu.net>
33923
33924         * lib/version-etc.c (version_etc_va): Default to GPLv3+.
33925         * NEWS: Document this change.
33926
33927 2007-07-08  Bruno Haible  <bruno@clisp.org>
33928
33929         Update to Unicode 5.0.
33930         * lib/uniwidth/width.c (nonspacing_table_data): Add U+00AD,
33931         U+0350..U+035F, U+05A2, U+05BA, U+05C5, U+05C7, U+0600..U+0603,
33932         U+0610..U+0615, U+0656..U+065E, U+07EB..U+07F3, U+0A01, U+0AE2..U+0AE3,
33933         U+0CBC. Remove U+0CBF, U+0CC6. Add U+0CE2..U+0CE3, U+135F,
33934         U+17B4..U+17B5, U+17DD. Remove U+180E. Add U+1920..U+1922,
33935         U+1927..U+192B, U+1932, U+1939..U+193B, U+1A17..U+1A18, U+1B00..U+1B03,
33936         U+1B34, U+1B36..U+1B3A, U+1B3C, U+1B42, U+1B6B..U+1B73, U+1DC0..U+1DCA,
33937         U+1DFE..U+1DFF, U+20EB..U+20EF, U+A802, U+A806, U+A80B, U+A825..U+A826,
33938         U+10A01..U+10A03, U+10A05..U+10A06, U+10A0C..U+10A0F, U+10A38..U+10A3A,
33939         U+10A3F, U+1D242..U+1D244.
33940         (nonspacing_table_ind): Update.
33941         (uc_width): Assign width 0 to U+E0100..U+E01EF. Assign width 1 to
33942         U+4DC0..U+4DFF. Assign width 2 to U+2329..U+232A, U+FE10..U+FE1F.
33943
33944 2007-07-08  Bruno Haible  <bruno@clisp.org>
33945
33946         Update to Unicode 5.0.
33947         * lib/uniname/gen-uninames.lisp (main): Add the range 0x12xxx to the
33948         code transform. Extend the name index field of unicode_name_to_code and
33949         unicode_code_to_name from 16 to 24 bits.
33950         * lib/uniname/uniname.c (unicode_character_name,
33951         unicode_name_character): Add the range 0x12xxx to the code transform.
33952         * lib/uniname/uninames.h: Regenerated.
33953         * tests/uniname/UnicodeDataNames.txt: Update to Unicode 5.0.
33954
33955 2007-07-07  Bruno Haible  <bruno@clisp.org>
33956
33957         * modules/wcwidth-tests: New file.
33958         * tests/test-wcwidth.c: New file.
33959
33960         Work around MacOS X wcwidth() bug.
33961         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Test against MacOS X 10.3 bug.
33962         * lib/wcwidth.c: Include localcharset.h, streq.h, uniwidth.h.
33963         (rpl_wcwidth): Special-case the UTF-8 locales. Fall back to the
33964         original wcwidth in non-UTF-8 locales.
33965         * modules/wcwidth (Depends-on): Add localcharset, streq,
33966         uniwidth/width.
33967         * doc/functions/wcwidth.texi: Update.
33968
33969 2007-07-07  Bruno Haible  <bruno@clisp.org>
33970
33971         * lib/wchar_.h: Include the GL_LINK_WARNING macro.
33972         (wcwidth): New declaration.
33973         * m4/wchar.m4 (gl_WCHAR_MODULE_INDICATOR, gl_WCHAR_H_DEFAULTS): New
33974         macros.
33975         (gl_WCHAR_H): Require gl_WCHAR_H_DEFAULTS. Don't set WCHAR_H to empty
33976         here. Prepare for creating <wchar.h> unconditionally.
33977         * modules/wchar (Depends-on): Add link-warning.
33978         (Makefile.am): Substitute also GNULIB_WCWIDTH, HAVE_DECL_WCWIDTH,
33979         REPLACE_WCWIDTH, and GL_LINK_WARNING.
33980         * lib/wcwidth.h: Remove file.
33981         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gl_WCHAR_H_DEFAULTS. Set
33982         HAVE_DECL_WCWIDTH, REPLACE_WCWIDTH, WCHAR_H.
33983         * modules/wcwidth (Files): Remove lib/wcwidth.h.
33984         (configure.ac): Invoke gl_WCHAR_MODULE_INDICATOR.
33985         (Include): Replace wcwidth.h with <wchar.h>.
33986         * lib/wcwidth.c: Include <wchar.h> instead of wcwidth.h.
33987         * lib/mbchar.h: Don't include wcwidth.h.
33988         * lib/mbswidth.c: Likewise.
33989         * NEWS: Mention the change.
33990
33991 2007-07-07  Bruno Haible  <bruno@clisp.org>
33992
33993         * lib/wcwidth.c: New file, extracted from lib/wcwidth.h.
33994         * lib/wcwidth.h: Don't include wctype.h. Replace inline function
33995         definition with an external declaration.
33996         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Use wcwidth.c when wcwidth is not
33997         defined as a function. Remove AC_C_INLINE requirement.
33998         * modules/wcwidth (Files): Add lib/wcwidth.c.
33999         (Makefile.am): Remove redundant statement.
34000
34001 2007-07-07  Bruno Haible  <bruno@clisp.org>
34002
34003         * MODULES.html.sh (Unicode string functions): Add the new modules.
34004
34005         * tests/uniwidth/test-u32-strwidth.c: New file.
34006         * modules/uniwidth/u32-strwidth-tests: New file.
34007
34008         * lib/uniwidth/u32-strwidth.c: New file.
34009         * modules/uniwidth/u32-strwidth: New file.
34010
34011         * tests/uniwidth/test-u16-strwidth.c: New file.
34012         * modules/uniwidth/u16-strwidth-tests: New file.
34013
34014         * lib/uniwidth/u16-strwidth.c: New file.
34015         * modules/uniwidth/u16-strwidth: New file.
34016
34017         * tests/uniwidth/test-u8-strwidth.c: New file.
34018         * modules/uniwidth/u8-strwidth-tests: New file.
34019
34020         * lib/uniwidth/u8-strwidth.c: New file.
34021         * modules/uniwidth/u8-strwidth: New file.
34022
34023         * tests/uniwidth/test-u32-width.c: New file.
34024         * modules/uniwidth/u32-width-tests: New file.
34025
34026         * lib/uniwidth/u32-width.c: New file.
34027         * modules/uniwidth/u32-width: New file.
34028
34029         * tests/uniwidth/test-u16-width.c: New file.
34030         * modules/uniwidth/u16-width-tests: New file.
34031
34032         * lib/uniwidth/u16-width.c: New file.
34033         * modules/uniwidth/u16-width: New file.
34034
34035         * tests/uniwidth/test-u8-width.c: New file.
34036         * modules/uniwidth/u8-width-tests: New file.
34037
34038         * lib/uniwidth/u8-width.c: New file.
34039         * modules/uniwidth/u8-width: New file.
34040
34041         * tests/uniwidth/test-uc_width.c: New file.
34042         * modules/uniwidth/width-tests: New file.
34043
34044         * lib/uniwidth/width.c: New file, from GNU libiconv.
34045         * lib/uniwidth/cjk.h: New file, from GNU libiconv.
34046         * modules/uniwidth/width: New file.
34047
34048         * lib/uniwidth.h: New file, from GNU libiconv.
34049         * modules/uniwidth/base: New file.
34050
34051 2007-07-07  Bruno Haible  <bruno@clisp.org>
34052
34053         * lib/uniname.h: New file, from GNU gettext.
34054         * lib/uniname/gen-uninames.lisp: New file, from GNU gettext.
34055         * lib/uniname/uninames.h: New file, from GNU gettext.
34056         * lib/uniname/uniname.c: New file, from GNU gettext.
34057         * tests/uniname/test-uninames.sh: New file.
34058         * tests/uniname/test-uninames.c: New file, from GNU gettext.
34059         * tests/uniname/UnicodeDataNames.txt: New file, from GNU gettext.
34060         * modules/uniname/base: New file.
34061         * modules/uniname/uniname: New file.
34062         * modules/uniname/uniname-tests: New file.
34063         * MODULES.html.sh (Unicode string functions): Add the new modules.
34064
34065 2007-07-06  Bruno Haible  <bruno@clisp.org>
34066
34067         * doc/Makefile (TEXI2HTML): Specify a --reference-limit.
34068
34069 2007-07-06  Bruno Haible  <bruno@clisp.org>
34070
34071         * lib/sys_time_.h: Use a recursion-safe inclusion guard rather than
34072         a split double-inclusion guard. Needed for cygwin, where <sys/time.h>
34073         includes <cygwin/sys_time.h> which includes <sys/select.h> which
34074         include <sys/time.h>.
34075         Reported by Eric Blake.
34076
34077 2007-07-06  Eric Blake  <ebb9@byu.net>
34078
34079         Fix testing canonicalize on cygwin.
34080         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
34081         Revert patch from 2007-06-19.
34082         * tests/test-canonicalize-lgpl.c (main): Instead, skip test when
34083         canonicalize module is also in use.
34084         * tests/test-canonicalize.c: New file.
34085         * tests/test-canonicalize.sh: Likewise.
34086         * modules/canonicalize-tests: Likewise.
34087
34088 2007-07-06  Jim Meyering  <jim@meyering.net>
34089
34090         * lib/getugroups.c (getugroups): Detect getgrent failure.
34091         Adjust comment to reflect reality: this function may return -1.
34092
34093 2007-07-05  Sergey Poznyakoff  <gray@gnu.org.ua>
34094
34095         * build-aux/bootstrap (TP_URL,get_translations): Update to use
34096         the new TP address.
34097         (usage): Fix typo
34098         (gnulib_mk): New variable.
34099
34100 2007-07-05  Jim Meyering  <jim@meyering.net>
34101
34102         Don't let endgrent clobber errno, no matter how improbable.
34103         * lib/getugroups.c (getugroups): Save and restore errno around
34104         endgrent call.
34105
34106         Close the group DB even when failing with 2^31 or more members.
34107         * lib/getugroups.c (getugroups): Don't return without calling endgrent.
34108
34109 2007-07-04  Jim Meyering  <jim@meyering.net>
34110
34111         * lib/getugroups.h: New file.
34112         * lib/getugroups.c: Include "getugroups.h".
34113         Remove uses of "register" keyword.
34114         Move local variable, "cp", down into scope where used.
34115         Give "username" parameter the "const" attribute.
34116         * modules/getugroups (Files): Add lib/getugroups.h
34117
34118 2007-07-04  Karl Berry  <karl@gnu.org>
34119
34120         * MODULES.html.sh (func_all_modules): Complete rename of
34121         gpl/lgpl to gpl-2.0 and lgpl-2.1, and add gpl-3.0.
34122
34123 2007-07-02  Bruno Haible  <bruno@clisp.org>
34124
34125         * m4/inttypes.m4 (gl_INTTYPES_H): Define __STDC_LIMIT_MACROS in C++
34126         mode, when inttypes.h comes from gnulib.
34127         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
34128
34129 2007-07-02  Simon Josefsson  <simon@josefsson.org>
34130
34131         * NEWS: Mention lgpl module name change.
34132
34133         * modules/lgpl-2.1: Renamed from lgpl.
34134
34135         * NEWS: Mention gpl module name change.
34136
34137         * modules/gpl-3.0: New file, based on gpl-2.0.
34138
34139         * modules/gpl-2.0: Renamed from gpl.
34140
34141         * modules/gpl: Fix filename, doc/gpl.texi is now found at
34142         doc/gpl-2.0.texi.
34143
34144 2007-07-02  Paul Eggert  <eggert@cs.ucla.edu>
34145
34146         * lib/inttypes_.h [defined __cplusplus&&!defined __STDC_LIMIT_MACROS]:
34147         #define __STDC_LIMIT_MACROS temporarily while including
34148         <stdint.h>, so that __STDC_LIMIT_MACROS is defined.
34149         Problem reported by Joel E. Denny in
34150         <http://lists.gnu.org/archive/html/bug-gnulib/2007-07/msg00008.html>.
34151
34152 2007-07-01  Bruno Haible  <bruno@clisp.org>
34153
34154         * lib/unistdio.h: New file.
34155         * lib/unistdio/u-asnprintf.h: New file.
34156         * lib/unistdio/u-asprintf.h: New file.
34157         * lib/unistdio/u-printf-args.c: New file.
34158         * lib/unistdio/u-printf-args.h: New file.
34159         * lib/unistdio/u-printf-parse.h: New file.
34160         * lib/unistdio/u-snprintf.h: New file.
34161         * lib/unistdio/u-sprintf.h: New file.
34162         * lib/unistdio/u-vasprintf.h: New file.
34163         * lib/unistdio/u-vsnprintf.h: New file.
34164         * lib/unistdio/u-vsprintf.h: New file.
34165         * lib/unistdio/ulc-asnprintf.c: New file.
34166         * lib/unistdio/ulc-asprintf.c: New file.
34167         * lib/unistdio/ulc-fprintf.c: New file, based on lib/fprintf.c.
34168         * lib/unistdio/ulc-printf-parse.c: New file.
34169         * lib/unistdio/ulc-snprintf.c: New file.
34170         * lib/unistdio/ulc-sprintf.c: New file.
34171         * lib/unistdio/ulc-vasnprintf.c: New file.
34172         * lib/unistdio/ulc-vasprintf.c: New file.
34173         * lib/unistdio/ulc-vfprintf.c: New file, based on lib/vfprintf.c.
34174         * lib/unistdio/ulc-vsnprintf.c: New file.
34175         * lib/unistdio/ulc-vsprintf.c: New file.
34176         * lib/unistdio/u8-asnprintf.c: New file.
34177         * lib/unistdio/u8-asprintf.c: New file.
34178         * lib/unistdio/u8-printf-parse.c: New file.
34179         * lib/unistdio/u8-snprintf.c: New file.
34180         * lib/unistdio/u8-sprintf.c: New file.
34181         * lib/unistdio/u8-vasnprintf.c: New file.
34182         * lib/unistdio/u8-vasprintf.c: New file.
34183         * lib/unistdio/u8-vsnprintf.c: New file.
34184         * lib/unistdio/u8-vsprintf.c: New file.
34185         * lib/unistdio/u8-u8-asnprintf.c: New file.
34186         * lib/unistdio/u8-u8-asprintf.c: New file.
34187         * lib/unistdio/u8-u8-snprintf.c: New file.
34188         * lib/unistdio/u8-u8-sprintf.c: New file.
34189         * lib/unistdio/u8-u8-vasnprintf.c: New file.
34190         * lib/unistdio/u8-u8-vasprintf.c: New file.
34191         * lib/unistdio/u8-u8-vsnprintf.c: New file.
34192         * lib/unistdio/u8-u8-vsprintf.c: New file.
34193         * lib/unistdio/u16-asnprintf.c: New file.
34194         * lib/unistdio/u16-asprintf.c: New file.
34195         * lib/unistdio/u16-printf-parse.c: New file.
34196         * lib/unistdio/u16-snprintf.c: New file.
34197         * lib/unistdio/u16-sprintf.c: New file.
34198         * lib/unistdio/u16-vasnprintf.c: New file.
34199         * lib/unistdio/u16-vasprintf.c: New file.
34200         * lib/unistdio/u16-vsnprintf.c: New file.
34201         * lib/unistdio/u16-vsprintf.c: New file.
34202         * lib/unistdio/u16-u16-asnprintf.c: New file.
34203         * lib/unistdio/u16-u16-asprintf.c: New file.
34204         * lib/unistdio/u16-u16-snprintf.c: New file.
34205         * lib/unistdio/u16-u16-sprintf.c: New file.
34206         * lib/unistdio/u16-u16-vasnprintf.c: New file.
34207         * lib/unistdio/u16-u16-vasprintf.c: New file.
34208         * lib/unistdio/u16-u16-vsnprintf.c: New file.
34209         * lib/unistdio/u16-u16-vsprintf.c: New file.
34210         * lib/unistdio/u32-asnprintf.c: New file.
34211         * lib/unistdio/u32-asprintf.c: New file.
34212         * lib/unistdio/u32-printf-parse.c: New file.
34213         * lib/unistdio/u32-snprintf.c: New file.
34214         * lib/unistdio/u32-sprintf.c: New file.
34215         * lib/unistdio/u32-vasnprintf.c: New file.
34216         * lib/unistdio/u32-vasprintf.c: New file.
34217         * lib/unistdio/u32-vsnprintf.c: New file.
34218         * lib/unistdio/u32-vsprintf.c: New file.
34219         * lib/unistdio/u32-u32-asnprintf.c: New file.
34220         * lib/unistdio/u32-u32-asprintf.c: New file.
34221         * lib/unistdio/u32-u32-snprintf.c: New file.
34222         * lib/unistdio/u32-u32-sprintf.c: New file.
34223         * lib/unistdio/u32-u32-vasnprintf.c: New file.
34224         * lib/unistdio/u32-u32-vasprintf.c: New file.
34225         * lib/unistdio/u32-u32-vsnprintf.c: New file.
34226         * lib/unistdio/u32-u32-vsprintf.c: New file.
34227         * tests/unistdio/test-ulc-asnprintf1.c: New file.
34228         * tests/unistdio/test-ulc-asnprintf1.h: New file.
34229         * tests/unistdio/test-ulc-printf1.h: New file.
34230         * tests/unistdio/test-ulc-vasnprintf1.c: New file.
34231         * tests/unistdio/test-ulc-vasnprintf2.c: New file.
34232         * tests/unistdio/test-ulc-vasnprintf2.sh: New file.
34233         * tests/unistdio/test-ulc-vasnprintf3.c: New file.
34234         * tests/unistdio/test-ulc-vasnprintf3.sh: New file.
34235         * tests/unistdio/test-ulc-vasprintf1.c: New file.
34236         * tests/unistdio/test-ulc-vsnprintf1.c: New file.
34237         * tests/unistdio/test-ulc-vsprintf1.c: New file.
34238         * tests/unistdio/test-u8-asnprintf1.c: New file.
34239         * tests/unistdio/test-u8-asnprintf1.h: New file.
34240         * tests/unistdio/test-u8-printf1.h: New file.
34241         * tests/unistdio/test-u8-vasnprintf1.c: New file.
34242         * tests/unistdio/test-u8-vasnprintf2.c: New file.
34243         * tests/unistdio/test-u8-vasnprintf2.sh: New file.
34244         * tests/unistdio/test-u8-vasnprintf3.c: New file.
34245         * tests/unistdio/test-u8-vasnprintf3.sh: New file.
34246         * tests/unistdio/test-u8-vasprintf1.c: New file.
34247         * tests/unistdio/test-u8-vsnprintf1.c: New file.
34248         * tests/unistdio/test-u8-vsprintf1.c: New file.
34249         * tests/unistdio/test-u16-asnprintf1.c: New file.
34250         * tests/unistdio/test-u16-asnprintf1.h: New file.
34251         * tests/unistdio/test-u16-printf1.h: New file.
34252         * tests/unistdio/test-u16-vasnprintf1.c: New file.
34253         * tests/unistdio/test-u16-vasnprintf2.c: New file.
34254         * tests/unistdio/test-u16-vasnprintf2.sh: New file.
34255         * tests/unistdio/test-u16-vasnprintf3.c: New file.
34256         * tests/unistdio/test-u16-vasnprintf3.sh: New file.
34257         * tests/unistdio/test-u16-vasprintf1.c: New file.
34258         * tests/unistdio/test-u16-vsnprintf1.c: New file.
34259         * tests/unistdio/test-u16-vsprintf1.c: New file.
34260         * tests/unistdio/test-u32-asnprintf1.c: New file.
34261         * tests/unistdio/test-u32-asnprintf1.h: New file.
34262         * tests/unistdio/test-u32-printf1.h: New file.
34263         * tests/unistdio/test-u32-vasnprintf1.c: New file.
34264         * tests/unistdio/test-u32-vasnprintf2.c: New file.
34265         * tests/unistdio/test-u32-vasnprintf2.sh: New file.
34266         * tests/unistdio/test-u32-vasnprintf3.c: New file.
34267         * tests/unistdio/test-u32-vasnprintf3.sh: New file.
34268         * tests/unistdio/test-u32-vasprintf1.c: New file.
34269         * tests/unistdio/test-u32-vsnprintf1.c: New file.
34270         * tests/unistdio/test-u32-vsprintf1.c: New file.
34271         * modules/unistdio/base: New file.
34272         * modules/unistdio/u-printf-args: New file.
34273         * modules/unistdio/ulc-asnprintf: New file.
34274         * modules/unistdio/ulc-asprintf: New file.
34275         * modules/unistdio/ulc-fprintf: New file.
34276         * modules/unistdio/ulc-printf-parse: New file.
34277         * modules/unistdio/ulc-snprintf: New file.
34278         * modules/unistdio/ulc-sprintf: New file.
34279         * modules/unistdio/ulc-vasnprintf: New file.
34280         * modules/unistdio/ulc-vasprintf: New file.
34281         * modules/unistdio/ulc-vfprintf: New file.
34282         * modules/unistdio/ulc-vsnprintf: New file.
34283         * modules/unistdio/ulc-vsprintf: New file.
34284         * modules/unistdio/u8-asnprintf: New file.
34285         * modules/unistdio/u8-asprintf: New file.
34286         * modules/unistdio/u8-printf-parse: New file.
34287         * modules/unistdio/u8-snprintf: New file.
34288         * modules/unistdio/u8-sprintf: New file.
34289         * modules/unistdio/u8-vasnprintf: New file.
34290         * modules/unistdio/u8-vasprintf: New file.
34291         * modules/unistdio/u8-vsnprintf: New file.
34292         * modules/unistdio/u8-vsprintf: New file.
34293         * modules/unistdio/u8-u8-asnprintf: New file.
34294         * modules/unistdio/u8-u8-asprintf: New file.
34295         * modules/unistdio/u8-u8-snprintf: New file.
34296         * modules/unistdio/u8-u8-sprintf: New file.
34297         * modules/unistdio/u8-u8-vasnprintf: New file.
34298         * modules/unistdio/u8-u8-vasprintf: New file.
34299         * modules/unistdio/u8-u8-vsnprintf: New file.
34300         * modules/unistdio/u8-u8-vsprintf: New file.
34301         * modules/unistdio/u16-asnprintf: New file.
34302         * modules/unistdio/u16-asprintf: New file.
34303         * modules/unistdio/u16-printf-parse: New file.
34304         * modules/unistdio/u16-snprintf: New file.
34305         * modules/unistdio/u16-sprintf: New file.
34306         * modules/unistdio/u16-vasnprintf: New file.
34307         * modules/unistdio/u16-vasprintf: New file.
34308         * modules/unistdio/u16-vsnprintf: New file.
34309         * modules/unistdio/u16-vsprintf: New file.
34310         * modules/unistdio/u16-u16-asnprintf: New file.
34311         * modules/unistdio/u16-u16-asprintf: New file.
34312         * modules/unistdio/u16-u16-snprintf: New file.
34313         * modules/unistdio/u16-u16-sprintf: New file.
34314         * modules/unistdio/u16-u16-vasnprintf: New file.
34315         * modules/unistdio/u16-u16-vasprintf: New file.
34316         * modules/unistdio/u16-u16-vsnprintf: New file.
34317         * modules/unistdio/u16-u16-vsprintf: New file.
34318         * modules/unistdio/u32-asnprintf: New file.
34319         * modules/unistdio/u32-asprintf: New file.
34320         * modules/unistdio/u32-printf-parse: New file.
34321         * modules/unistdio/u32-snprintf: New file.
34322         * modules/unistdio/u32-sprintf: New file.
34323         * modules/unistdio/u32-vasnprintf: New file.
34324         * modules/unistdio/u32-vasprintf: New file.
34325         * modules/unistdio/u32-vsnprintf: New file.
34326         * modules/unistdio/u32-vsprintf: New file.
34327         * modules/unistdio/u32-u32-asnprintf: New file.
34328         * modules/unistdio/u32-u32-asprintf: New file.
34329         * modules/unistdio/u32-u32-snprintf: New file.
34330         * modules/unistdio/u32-u32-sprintf: New file.
34331         * modules/unistdio/u32-u32-vasnprintf: New file.
34332         * modules/unistdio/u32-u32-vasprintf: New file.
34333         * modules/unistdio/u32-u32-vsnprintf: New file.
34334         * modules/unistdio/u32-u32-vsprintf: New file.
34335         * modules/unistdio/ulc-asnprintf-tests: New file.
34336         * modules/unistdio/ulc-vasnprintf-tests: New file.
34337         * modules/unistdio/ulc-vasprintf-tests: New file.
34338         * modules/unistdio/ulc-vsnprintf-tests: New file.
34339         * modules/unistdio/ulc-vsprintf-tests: New file.
34340         * modules/unistdio/u8-asnprintf-tests: New file.
34341         * modules/unistdio/u8-vasnprintf-tests: New file.
34342         * modules/unistdio/u8-vasprintf-tests: New file.
34343         * modules/unistdio/u8-vsnprintf-tests: New file.
34344         * modules/unistdio/u8-vsprintf-tests: New file.
34345         * modules/unistdio/u16-asnprintf-tests: New file.
34346         * modules/unistdio/u16-vasnprintf-tests: New file.
34347         * modules/unistdio/u16-vasprintf-tests: New file.
34348         * modules/unistdio/u16-vsnprintf-tests: New file.
34349         * modules/unistdio/u16-vsprintf-tests: New file.
34350         * modules/unistdio/u32-asnprintf-tests: New file.
34351         * modules/unistdio/u32-vasnprintf-tests: New file.
34352         * modules/unistdio/u32-vasprintf-tests: New file.
34353         * modules/unistdio/u32-vsnprintf-tests: New file.
34354         * modules/unistdio/u32-vsprintf-tests: New file.
34355         * MODULES.html.sh (Unicode string functions): Add the new modules.
34356
34357 2007-07-01  Bruno Haible  <bruno@clisp.org>
34358
34359         * lib/sprintf.c (sprintf): Limit the available length estimation,
34360         to avoid address wraparound.
34361         * lib/vsprintf.c (vsprintf): Likewise.
34362         * modules/sprintf-posix (Dependencies): Add stdint.
34363         * modules/vsprintf-posix (Dependencies): Likewise.
34364
34365 2007-07-01  Bruno Haible  <bruno@clisp.org>
34366
34367         * gnulib-tool (self_abspathname): Determine PATH_SEPARATOR and handle
34368         Windows PATH as well. Conservative double-quoting. Comments.
34369
34370 2007-07-01  Bruno Haible  <bruno@clisp.org>
34371             Eric Blake  <ebb9@byu.net>
34372             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34373
34374         * gnulib-tool (self_abspathname): Fix algorithm to cope with
34375         empty components in $PATH, denoting '.'.
34376
34377 2007-07-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34378
34379         * gnulib-tool: Fix indentation.
34380         (func_create_megatestdir): Likewise.
34381         Report by Bruno Haible.
34382
34383 2007-06-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34384
34385         Sync from Automake.
34386         * build-aux/gnupload: Fix shell portability issues with for loops.
34387         Report by Karl Berry.
34388
34389 2007-06-29  Simon Josefsson  <simon@josefsson.org>
34390
34391         * build-aux/maint.mk (POURL): Use translationproject.org.
34392
34393 2007-06-27  Simon Josefsson  <simon@josefsson.org>
34394             Bruno Haible  <bruno@clisp.org>
34395
34396         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Require gl_HEADER_SYS_SOCKET
34397         before using HAVE_WS2TCPIP_H. Check for gai_strerror through an
34398         explicit link test, rather than AC_REPLACE_FUNCS - for mingw.
34399         (gl_PREREQ_GETADDRINFO): Require gl_HEADER_SYS_SOCKET before using
34400         HAVE_SYS_SOCKET_H and HAVE_WS2TCPIP_H.
34401
34402 2007-06-27  Bruno Haible  <bruno@clisp.org>
34403
34404         * build-aux/config.rpath: Upgrade to libtool-1.5.24.
34405         * build-aux/config.libpath: Upgrade to libtool-1.5.24.
34406
34407 2007-06-26  Karl Berry  <karl@gnu.org>
34408
34409         * MODULES.html.sh: remove xreadlink-with-size.
34410
34411 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
34412
34413         * lib/time_.h: Port to Solaris 8 with Sun Studio 11, using a
34414         method that I hope also handles the double-include problem noted
34415         by Bruno Haible in
34416         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00186.html>.
34417
34418 2007-06-23  Bruno Haible  <bruno@clisp.org>
34419
34420         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
34421         Don't let the 'mostlyclean' target fail if the last subdirectory could
34422         not be removed.
34423         Reported by Karl Berry.
34424
34425 2007-06-23  Bruno Haible  <bruno@clisp.org>
34426
34427         * gnulib-tool (echo): Add a speedier workaround for ksh.
34428         * tests/test-echo.sh: Likewise.
34429
34430 2007-06-23  Bruno Haible  <bruno@clisp.org>
34431
34432         * gnulib-tool (echo): Add workarounds also for bash versions < 2.04.
34433         * tests/test-echo.sh: Likewise.
34434
34435 2007-06-23  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34436
34437         * gnulib-tool (IFS): Initialize early, so we don't set it to
34438         empty later.
34439         (self_abspathname): Rewrite algorithm to set it, reindent.
34440         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am)
34441         (func_create_megatestdir): Merge some sed scripts.
34442
34443 2007-06-23  Paul Eggert  <eggert@cs.ucla.edu>
34444
34445         * m4/include_next.m4 (gl_CHECK_NEXT_HEADERS): Check some typos
34446         exposed by Sun Studio 11 cc on Solaris 8.
34447
34448 2007-06-22  Bruno Haible  <bruno@clisp.org>
34449
34450         * gnulib-tool (echo): Ensure the echo primitive does not interpret
34451         backslashes.
34452         * tests/test-echo.sh: New file.
34453
34454 2007-06-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
34455
34456         * gnulib-tool (func_add_or_update, func_create_testdir): Do not
34457         simplify `sed_replace_build_aux' scripts, they are portable but
34458         echoing them with `echo' is not.
34459         Report and analysis by Fernando Ferreira <fernando.prog@netcabo.pt>.
34460
34461 2007-06-21  Karl Berry  <karl@gnu.org>
34462
34463         * config/srclist.txt: guess we can't handle the licenses via
34464         srclist at the moment.
34465
34466 2007-06-21  Paul Eggert  <eggert@cs.ucla.edu>
34467
34468         * MODULES.html.sh: Add include_next.
34469         * modules/include_next: New file.
34470
34471 2007-06-20  Paul Eggert  <eggert@cs.ucla.edu>
34472
34473         * m4/include_next.m4 (gl_INCLUDE_NEXT): Define and AC_SUBST
34474         INCLUDE_NEXT.
34475         (gl_CHECK_NEXT_HEADERS): New macro.
34476         * m4/fcntl_h.m4 (gl_FCNTL_H): use gl_CHECK_NEXT_HEADERS instead of
34477         the obsolescent gl_ABSOLUTE_HEADER.
34478         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Likewise.
34479         * m4/float_h.m4 (gl_FLOAT_H): Likewise.
34480         * m4/iconv_h.m4 (gl_ICONV_H): Likewise.
34481         * m4/inttypes.m4 (gl_INTTYPES_H): Likewise.
34482         * m4/locale_h.m4 (gl_LOCALE_H): Likewise.
34483         * m4/math_h.m4 (gl_MATH_H): Likewise.
34484         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Likewise.
34485         * m4/search_h.m4 (gl_SEARCH_H): Likewise.
34486         * m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
34487         * m4/stdint.m4 (gl_STDINT_H): Likewise.
34488         * m4/stdio_h.m4 (gl_STDIO_H): Likewise.
34489         * m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
34490         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Likewise.
34491         * m4/sys_select_h.m4 (gl_HEADER_SYS_SELECT): Likewise.
34492         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
34493         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
34494         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Likewise.
34495         * m4/sysexits.m4 (gl_SYSEXITS): Likewise.
34496         * m4/time_h.m4 (gl_HEADER_TIME_H_BODY): Likewise.
34497         * m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
34498         * m4/wchar.m4 (gl_WCHAR_H): Likewise.
34499         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
34500         * m4/inttypes.m4 (gl_INTTYPES_H): Define
34501         _GL_JUST_INCLUDE_SYSTEM_INTTYPES_H to avoid the problem of unclean
34502         builds, since ABSOLUTE_INTTYPES_H is no longer being defined.
34503         * m4/stdint.m4 (gl_STDINT_H): Likewise, for
34504         _GL_JUST_INCLUDE_SYSTEM_STDINT_H.
34505         * lib/fcntl_.h: Use @INCLUDE_NEXT@ @NEXT_foo_H@
34506         rather than @HAVE_INCLUDE_NEXT@ and @ABSOLUTE_foo_H@.
34507         * lib/float_.h: Likewise.
34508         * lib/inttypes_.h: Likewise.
34509         * lib/math_.h: Likewise.
34510         * lib/search_.h: Likewise.
34511         * lib/signal_.h: Likewise.
34512         * lib/stdint_.h: Likewise.
34513         * lib/stdio_.h: Likewise.
34514         * lib/stdlib_.h: Likewise.
34515         * lib/string_.h: Likewise.
34516         * lib/sys_stat_.h: Likewise.
34517         * lib/sys_time_.h: Likewise.
34518         * lib/time_.h: Likewise.
34519         * lib/unistd_.h: Likewise.
34520         * lib/wchar_.h: Likewise.
34521         * lib/wctype_.h: Likewise.
34522         * lib/dirent_.h: Likewise.
34523         * lib/iconv_.h: Likewise.
34524         * lib/locale_.h: Likewise.
34525         * lib/netinet_in_.h: Likewise.
34526         * lib/sys_select_.h: Likewise.
34527         * lib/sys_socket_.h: Likewise.
34528         * lib/sysexits_.h: Likewise.
34529         * modules/fcntl (Depends-on): Depend on include_next, not
34530         absolute_header.
34531         (Makefile): Substitute INCLUDE_NEXT and NEXT_foo_H, not
34532         HAVE_INCLUDE_NEXT and ABSOLUTE_foo_H.
34533         * modules/fchdir: Likewise.
34534         * modules/float: Likewise.
34535         * modules/iconv_open: Likewise.
34536         * modules/inttypes: Likewise.
34537         * modules/locale: Likewise.
34538         * modules/math: Likewise.
34539         * modules/netinet_in: Likewise.
34540         * modules/search: Likewise.
34541         * modules/signal: Likewise.
34542         * modules/stdint: Likewise.
34543         * modules/stdio: Likewise.
34544         * modules/stdlib: Likewise.
34545         * modules/string: Likewise.
34546         * modules/sys_select: Likewise.
34547         * modules/sys_socket: Likewise.
34548         * modules/sys_stat: Likewise.
34549         * modules/sys_time: Likewise.
34550         * modules/sysexits: Likewise.
34551         * modules/time: Likewise.
34552         * modules/unistd: Likewise.
34553         * modules/wchar: Likewise.
34554         * modules/wctype: Likewise.
34555         * modules/sys_stat: Change maintainer to "all".
34556         * modules/unistd: Likewise.
34557
34558 2007-06-20  Karl Berry  <karl@gnu.org>
34559
34560         * config/srclist.txt: track www changes in license files.
34561
34562 2007-06-20  Sergey Poznyakoff  <gray@gnu.org.ua>
34563
34564         * build-aux/bootstrap: Remove stray dot.
34565         Make sure build_aux settings are honored when linking
34566         gnulib_extra_files.
34567
34568 2007-06-19  Eric Blake  <ebb9@byu.net>
34569
34570         * modules/canonicalize-lgpl-tests (test_canonicalize_lgpl_LDADD):
34571         Allow compilation on cygwin.
34572
34573 2007-06-19  Jim Meyering  <jim@meyering.net>
34574
34575         xreadlink-with-size: Remove module.  No longer used.
34576         Ex-callers now use xreadlink or mreadlink-with-size.
34577         * modules/xreadlink-with-size: Remove module.
34578         * lib/xreadlink-with-size.c: Remove file.
34579         * lib/xreadlink.h (xreadlink_with_size): Remove prototype.
34580         (xreadlink): Remove inaccurate comment.  The one in xreadlink.c,
34581         just before the function definition *is* accurate.
34582
34583         Eliminate one way canonicalize_filename_mode could exit.
34584         * lib/canonicalize.c (canonicalize_filename_mode):
34585         Use mreadlink_with_size, not xreadlink_with_size.
34586
34587 2007-06-18  Paul Eggert  <eggert@cs.ucla.edu>
34588
34589         Detect porting problems to FreeBSD/arm, which has time_t wider than
34590         long int.  Original problem reported for GNU diff by Xin Li in
34591         <http://lists.gnu.org/archive/html/bug-gnu-utils/2007-06/msg00091.html>.
34592         * modules/getdate (Depends-on): Add intprops, verify.
34593         * lib/getdate.y: Include intprops.h, verify.h.  Verify that time_t
34594         is an integer type no wider than long int.
34595
34596 2007-06-18  Jim Meyering  <jim@meyering.net>
34597
34598         New module: mreadlink-with-size.
34599         * MODULES.html.sh: Add mreadlink-with-size.
34600         * modules/mreadlink-with-size: New module
34601         * modules/canonicalize (Depends-on): Depend on mreadlink-with-size,
34602         not xreadlink-with-size.
34603         * lib/mreadlink-with-size.c, lib/mreadlink.h: New files.
34604
34605 2007-06-16  Bruno Haible  <bruno@clisp.org>
34606
34607         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Catch the MacOS X 10.4 bug.
34608         * doc/functions/frexpl.texi: Document the MacOS X 10.4 bug.
34609         Reported by Gary V. Vaughan <gary@gnu.org>.
34610
34611 2007-06-15  Paul Eggert  <eggert@cs.ucla.edu>
34612
34613         Revamp lchown so that it lives in unistd.h where it belongs.
34614         * lib/lchown.h: Remove.
34615         * lib/dirchownmod.c: Don't include lib/lchown.h.
34616         * lib/fchownat.c: Likewise.
34617         * lib/openat.c: Likewise.
34618         * lib/lchown.c (REPLACE_CHOWN): Define to 0 if the system chown
34619         does not follow symlinks.
34620         (EOPNOTSUPP): Define if not defined.
34621         * lib/unistd_.h (chown): Do not replace if REPLADE_CHOWN
34622         is defined to 0.
34623         (lchown): New decl.
34624         * m4/lchown.m4 (gl_FUNC_LCHOWN): Require gl_UNISTD_H_DEFAULTS.
34625         Do not check for lchown decl.
34626         Set REPLACE_LCHOWN.
34627         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Set GNULIB_LCHOWN,
34628         REPLACE_LCHOWN.
34629         * modules/chown: Make it clear it follows symlinks.
34630         * modules/lchown: Make it clear it doesn't follow symlinks.
34631         (Files): Remove lib/lchown.h
34632         (Depends-on): Add unistd.
34633         (configure.ac): Add gl_UNISTD_MODULE_INDICATOR([lchown]).
34634         (Include): Include <unistd.h>, not "lchown.h".
34635         * modules/unistd (unistd.h): Substitude GNULIB_LCHOWN and
34636         REPLACE_LCHOWN.
34637
34638 2007-06-15  Jim Meyering  <jim@meyering.net>
34639
34640         Change license (GPL to LGPL) of fsusage and dependents.
34641         * modules/fsusage (License): Change to LGPL.
34642         * modules/full-read (License): Likewise.
34643         * modules/full-write (License): Likewise.
34644         * modules/safe-read (License): Likewise.
34645         * modules/safe-write (License): Likewise.
34646
34647 2007-06-14  Ben Pfaff  <blp@gnu.org>
34648
34649         Missing part of allocsa -> malloca transition.
34650         * modules/relocatable-prog-wrapper: gl_ALLOCSA should be
34651         gl_MALLOCA.
34652
34653 2007-06-12  Bruno Haible  <bruno@clisp.org>
34654
34655         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Guess no when cross-compiling
34656         to ia64, x86_64, i386.
34657         Reported by Eric Blake.
34658
34659 2007-06-12  Bruno Haible  <bruno@clisp.org>
34660
34661         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Guess no also when
34662         cross-compiling to x86_64.
34663
34664 2007-06-12  Paul Eggert  <eggert@cs.ucla.edu>
34665
34666         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Fix POSIX sed portability
34667         glitch reported by Ralf Wildenhues in
34668         <http://lists.gnu.org/archive/html/bug-gnulib/2007-06/msg00114.html>.
34669
34670         * m4/regex.m4 (gl_REGEX): Catch a bug with [[:alnum:]_-] reported by
34671         Vin Shelton.
34672
34673 2007-06-11  Bruno Haible  <bruno@clisp.org>
34674
34675         * lib/printf-args.c (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Fix NULL
34676         replacement string.
34677         Reported by Eric Blake.
34678
34679 2007-06-10  Bruno Haible  <bruno@clisp.org>
34680
34681         Prepare vasnprintf code for use with Unicode strings.
34682         * lib/printf-args.h (PRINTF_FETCHARGS): New macro.
34683         (arg_type) [ENABLE_UNISTDIO]: Define TYPE_U8_STRING, TYPE_U16_STRING,
34684         TYPE_U32_STRING.
34685         (argument) [ENABLE_UNISTDIO]: Add a_u8_string, a_u16_string,
34686         a_u32_string variants.
34687         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
34688         * lib/printf-args.c: Don't include config.h and the specification
34689         header if PRINTF_FETCHARGS is already defined.
34690         (PRINTF_FETCHARGS): Renamed from printf_fetchargs.
34691         (PRINTF_FETCHARGS) [ENABLE_UNISTDIO]: Add code for TYPE_U8_STRING,
34692         TYPE_U16_STRING, TYPE_U32_STRING.
34693         * lib/printf-parse.h [ENABLE_UNISTDIO] (u8_directive, u8_directives,
34694         u16_directive, u16_directives, u32_directive, u32_directives): New
34695         types.
34696         (ulc_printf_parse, u8_printf_parse, u16_printf_parse, u32_printf_parse):
34697         New declarations.
34698         * lib/printf-parse.c: Don't include config.h and the specification
34699         header if PRINTF_PARSE is already defined. Eliminate the set of
34700         parameters for WIDE_CHAR_VERSION; the user of this file must provide
34701         them now. Include c-ctype.h.
34702         (PRINTF_PARSE) [ENABLE_UNISTDIO]: Add code implementing the 'U'
34703         directive and CHAR_T_ONLY_ASCII.
34704         * lib/vasnprintf.c: Don't include config.h and the specification header
34705         if VASNPRINTF is already defined.
34706         (DCHAR_IS_TCHAR, DCHAR_CPY): New macros.
34707         (VASNPRINTF): Use PRINTF_FETCHARGS instead of printf_fetchargs. Use
34708         DCHAR_CPY. Handle the case that DCHAR_T and FCHAR_T are not the same
34709         type. Handle the case that TCHAR_T and FCHAR_T are not of the same
34710         size. Handle the case that DCHAR_T and TCHAR_T are not the same type,
34711         add a conversion from TCHAR_T[] to DCHAR_T[], and rework the padding
34712         code accordingly.
34713         (VASNPRINTF) [ENABLE_UNISTDIO]: Implement the 'U' directive. Enable
34714         pad_ourselves also in this case, with the 'c' and 's' directives, and
34715         with a different notion of "width".
34716         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_WITH_EXTRAS): New macros.
34717
34718 2007-06-10  Bruno Haible  <bruno@clisp.org>
34719
34720         * modules/unistr/u32-mbsnlen: New file.
34721         * lib/unistr/u32-mbsnlen.c: New file.
34722
34723         * modules/unistr/u16-mbsnlen: New file.
34724         * lib/unistr/u16-mbsnlen.c: New file.
34725
34726         * modules/unistr/u8-mbsnlen: New file.
34727         * lib/unistr/u8-mbsnlen.c: New file.
34728
34729         * lib/unistr.h (u8_mbsnlen, u16_mbsnlen, u32_mbsnlen): New
34730         declarations.
34731
34732 2007-06-10  Bruno Haible  <bruno@clisp.org>
34733
34734         * lib/string_.h (mbsnlen): New declaration.
34735         * lib/mbsnlen.c: New file.
34736         * m4/mbsnlen.m4: New file.
34737         * modules/mbsnlen: New file.
34738         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Set GNULIB_MBSNLEN.
34739         * modules/string (string.h): Substitute GNULIB_MBSNLEN.
34740         * MODULES.html.sh (Internationalization functions): Add mbsnlen.
34741
34742 2007-06-10  Bruno Haible  <bruno@clisp.org>
34743
34744         * lib/mbslen.c: Include <stdlib.h>, needed for MB_CUR_MAX.
34745
34746 2007-06-10  Bruno Haible  <bruno@clisp.org>
34747
34748         * lib/mbiter.h: Include <stddef.h>, needed for ptrdiff_t.
34749         * lib/mbuiter.h: Likewise.
34750
34751 2007-06-10  Bruno Haible  <bruno@clisp.org>
34752
34753         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Check for _snprintf
34754         declaration.
34755
34756 2007-06-10  Karl Berry  <karl@gnu.org>
34757
34758         * config/srclist.txt: remove gettext entries, Bruno prefers
34759         to update individually.
34760
34761 2007-06-10  Bruno Haible  <bruno@clisp.org>
34762
34763         * lib/vasnprintf.c (VASNPRINTF) [!USE_SNPRINTF]: Remove variable
34764         'maxlen'. Ensure only length + width bytes are allocated, not
34765         length + 1 + width.
34766
34767 2007-06-09  Bruno Haible  <bruno@clisp.org>
34768
34769         * lib/vasnprintf.c (FCHAR_T, DCHAR_T, TCHAR_T): New macros.
34770         (CHAR_T): Remove macro.
34771         (VASNPRINTF): Update.
34772
34773 2007-06-09  Bruno Haible  <bruno@clisp.org>
34774
34775         * MODULES.html.sh (Unicode string functions): Add the new modules.
34776
34777         * modules/uniconv/u32-conv-to-enc: New file.
34778         * lib/uniconv/u32-conv-to-enc.c: New file.
34779         * modules/uniconv/u32-conv-to-enc-tests: New file.
34780         * tests/uniconv/test-u32-conv-to-enc.c: New file.
34781
34782         * modules/uniconv/u16-conv-to-enc: New file.
34783         * lib/uniconv/u16-conv-to-enc.c: New file.
34784         * lib/uniconv/u-conv-to-enc.h: New file.
34785         * modules/uniconv/u16-conv-to-enc-tests: New file.
34786         * tests/uniconv/test-u16-conv-to-enc.c: New file.
34787
34788         * modules/uniconv/u8-conv-to-enc: New file.
34789         * lib/uniconv/u8-conv-to-enc.c: New file.
34790         * modules/uniconv/u8-conv-to-enc-tests: New file.
34791         * tests/uniconv/test-u8-conv-to-enc.c: New file.
34792
34793         * lib/uniconv.h (u8_conv_to_encoding, u16_conv_to_encoding,
34794         u32_conv_to_encoding): New declarations.
34795
34796 2007-06-09  Bruno Haible  <bruno@clisp.org>
34797
34798         * tests/uniconv/test-u32-strconv-to-enc.c (main): Remove unused code.
34799
34800 2007-06-09  Bruno Haible  <bruno@clisp.org>
34801
34802         Rename 'allocsa' -> 'malloca', 'freesa' -> 'freea'.
34803         * modules/malloca: Renamed from modules/allocsa, updated.
34804         * lib/malloca.h: Renamed from lib/allocsa.h, updated.
34805         * lib/malloca.c: Renamed from lib/allocsa.c, updated.
34806         * lib/malloca.valgrind: Renamed from lib/allocsa.valgrind, updated.
34807         * m4/malloca.m4: Renamed from m4/allocsa.m4, updated.
34808         * modules/malloca-tests: Renamed from modules/allocsa-tests, updated.
34809         * tests/test-malloca.c: Renamed from tests/test-allocsa.c, updated.
34810         * modules/xmalloca: Renamed from modules/xallocsa, updated.
34811         * lib/xmalloca.h: Renamed from lib/xallocsa.h, updated.
34812         * lib/xmalloca.c: Renamed from lib/xallocsa.c, updated.
34813         * modules/c-strcasestr (Depends-on): Update.
34814         * lib/c-strcasestr.c: Update.
34815         * modules/c-strstr (Depends-on): Update.
34816         * lib/c-strstr.c: Update.
34817         * modules/canonicalize-lgpl (Depends-on): Update.
34818         * lib/canonicalize-lgpl.c: Update.
34819         * modules/clean-temp (Depends-on): Update.
34820         * lib/clean-temp.c: Update.
34821         * modules/csharpcomp (Depends-on): Update.
34822         * lib/csharpcomp.c: Update.
34823         * modules/csharpexec (Depends-on): Update.
34824         * lib/csharpexec.c: Update.
34825         * modules/javacomp (Depends-on): Update.
34826         * lib/javacomp.c: Update.
34827         * modules/javaexec (Depends-on): Update.
34828         * lib/javaexec.c: Update.
34829         * modules/mbscasestr (Depends-on): Update.
34830         * lib/mbscasestr.c: Update.
34831         * modules/mbsstr (Depends-on): Update.
34832         * lib/mbsstr.c: Update.
34833         * modules/setenv (Depends-on): Update.
34834         * lib/setenv.c: Update.
34835         * modules/strcasestr (Depends-on): Update.
34836         * lib/strcasestr.c: Update.
34837         * modules/striconveha (Depends-on): Update.
34838         * lib/striconveha.c: Update.
34839         * modules/relocatable-prog-wrapper (Files): Update.
34840         * lib/relocwrapper.c: Update.
34841         * build-aux/install-reloc: Update.
34842         * MODULES.html.sh (Memory management functions <stdlib.h>): Update.
34843
34844 2007-06-08  Bruno Haible  <bruno@clisp.org>
34845
34846         Port to uClibc.
34847         * lib/fbufmode.c (fbufmode): Add special code for uClibc.
34848         * lib/fpurge.c (fpurge): Likewise.
34849         * lib/freading.c (freading): Likewise.
34850         * lib/fseeko.c (rpl_fseeko): Likewise.
34851         * lib/fseterr.c (fseterr): Likewise.
34852         * lib/fwriting.c (fwriting): Likewise.
34853         * tests/test-fflush.c (main): Avoid a failure on uClibc.
34854
34855 2007-06-08  Bruno Haible  <bruno@clisp.org>
34856
34857         * m4/intlmacosx.m4: New file, extracted from gettext.m4.
34858         * m4/gettext.m4 (gt_INTL_MACOSX): Remove macro, moved to intlmacosx.m4.
34859         * modules/gettext (Files): Add m4/intlmacosx.m4.
34860
34861 2007-06-07  Bruno Haible  <bruno@clisp.org>
34862
34863         * modules/localename-tests: New file.
34864         * tests/test-localename.c: New file.
34865
34866         New module 'localename'.
34867         * lib/localename.h: New file.
34868         * lib/localename.c: New file, from GNU gettext.
34869         * m4/localename.m4: New file.
34870         * modules/localename: New file.
34871
34872 2007-06-07  Bruno Haible  <bruno@clisp.org>
34873
34874         Work around the lack of <wchar.h> on some builds of uClibc.
34875         * doc/headers/wchar.texi: Update.
34876         * lib/wchar_.h: Include <wchar.h> only if it exists.
34877         * m4/wchar.m4 (gl_WCHAR_H): Check for <wchar.h>. Set HAVE_WCHAR_H.
34878         * m4/stdint.m4 (gl_STDINT_H): Check for <wchar.h>.
34879         (gl_STDINT_TYPE_PROPERTIES): Don't try to include <wchar.h> if it
34880         doesn't exist.
34881         * modules/wchar (wchar.h): Substitute HAVE_WCHAR_H.
34882         * modules/mbfile (Depends-on): Add wchar.
34883         * modules/mbiter (Depends-on): Likewise.
34884         * modules/mbuiter (Depends-on): Likewise.
34885         Reported by Simon Josefsson.
34886
34887 2007-06-06  Paul Eggert  <eggert@cs.ucla.edu>
34888
34889         Work around problem reported by Steven M. Schweda in
34890         <http://lists.gnu.org/archive/html/bug-tar/2007-06/msg00002.html>:
34891         Tru64 5.1B with the Compaq compiler environment installed declares
34892         an 'isblank' function but does not define it in the C library.
34893         * lib/fnmatch.c (isblank): Check for HAVE_ISBLANK, too.
34894         * lib/regex_internal.h (isblank): Likewise.
34895         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for isblank existence.
34896         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
34897
34898 2007-06-05  Bruno Haible  <bruno@clisp.org>
34899
34900         Fix *printf so that it recognizes non-IEEE numbers on i386, x86_64,
34901         ia64.
34902         * modules/printf-safe: New file.
34903         * modules/fprintf-posix (Depends-on): Add printf-safe.
34904         * modules/printf-posix (Depends-on): Likewise.
34905         * modules/snprintf-posix (Depends-on): Likewise.
34906         * modules/sprintf-posix (Depends-on): Likewise.
34907         * modules/vasnprintf-posix (Depends-on): Likewise.
34908         * modules/vasprintf-posix (Depends-on): Likewise.
34909         * modules/vfprintf-posix (Depends-on): Likewise.
34910         * modules/vprintf-posix (Depends-on): Likewise.
34911         * modules/vsnprintf-posix (Depends-on): Likewise.
34912         * modules/vsprintf-posix (Depends-on): Likewise.
34913         * m4/printf.m4 (gl_PRINTF_INFINITE_LONG_DOUBLE): Require
34914         AC_C_BIGENDIAN. Define CHECK_PRINTF_SAFE if printf-safe is used. Test
34915         non-IEEE numbers on i386, x86_64, ia64. When cross-compiling, guess
34916         "no" on i386, x86_64, ia64.
34917         * tests/test-snprintf-posix.h (LDBL80_WORDS): New macro.
34918         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
34919         on i386, x86_64, ia64.
34920         * tests/test-sprintf-posix.h (LDBL80_WORDS): New macro.
34921         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
34922         on i386, x86_64, ia64.
34923         * tests/test-vasnprintf-posix.c: Include float.h.
34924         (LDBL80_WORDS): New macro.
34925         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
34926         on i386, x86_64, ia64.
34927         * tests/test-vasprintf-posix.c: Include float.h.
34928         (LDBL80_WORDS): New macro.
34929         (test_function): Check result of %La, %Lf, %Le, %Lg on non-IEEE numbers
34930         on i386, x86_64, ia64.
34931         * tests/test-snprintf-posix.c: Include float.h.
34932         * tests/test-sprintf-posix.c: Likewise.
34933         * tests/test-vsnprintf-posix.c: Likewise.
34934         * tests/test-vsprintf-posix.c: Likewise.
34935
34936 2007-06-05  Bruno Haible  <bruno@clisp.org>
34937
34938         Fix isnanl so that it recognizes non-IEEE numbers on i386, x86_64, ia64.
34939         * m4/isnanl.m4 (gl_FUNC_ISNANL_WORKS): Require AC_C_BIGENDIAN. Test
34940         non-IEEE numbers on i386, x86_64, ia64.
34941         (gl_LONG_DOUBLE_EXPONENT_LOCATION): Require AC_C_BIGENDIAN.
34942         * lib/isnan.c (FUNC): Add special code for i386, x86_64, ia64.
34943         * tests/test-isnanl.h: Include float.h.
34944         (main): Check also non-IEEE numbers on i386, x86_64, ia64.
34945
34946 2007-06-05  Bruno Haible  <bruno@clisp.org>
34947
34948         * lib/vasnprintf.c (VASNPRINTF): Do the extra handling of NaN and Inf
34949         also the %a / %A. Handle the %a / %A code before this extra handling.
34950
34951 2007-06-05  Bruno Haible  <bruno@clisp.org>
34952
34953         * lib/vasnprintf.c [NEED_PRINTF_LONG_DOUBLE ||
34954         NEED_PRINTF_INFINITE_LONG_DOUBLE]: Include fpucw.h.
34955
34956 2007-06-05  Bruno Haible  <bruno@clisp.org>
34957
34958         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): Fix
34959         typo in variable name.
34960
34961 2007-06-05  Eric Blake  <ebb9@byu.net>
34962
34963         * m4/lseek.m4 (gl_FUNC_LSEEK): Work when cross-compiling.
34964         Reported by Simon Josefsson.
34965
34966 2007-06-04  Bruno Haible  <bruno@clisp.org>
34967
34968         Avoid test failures on some PowerPC platforms.
34969         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP):
34970         Define differently for PowerPC.
34971         * tests/test-frexpl.c (MIN_NORMAL_EXP): Likewise.
34972         Reported by Gary V. Vaughan <gary@gnu.org>.
34973
34974 2007-06-02  Bruno Haible  <bruno@clisp.org>
34975
34976         Fix test-stdint failure on FreeBSD/ia64.
34977         * m4/stdint.m4 (gl_STDINT_H): Check the values of PTRDIFF_MIN,
34978         PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN,
34979         WCHAR_MAX, WINT_MIN, WINT_MAX entirely, not only for plausibility.
34980         * doc/headers/stdint.texi: Update.
34981
34982 2007-06-01  Bruno Haible  <bruno@clisp.org>
34983
34984         * tests/test-binary-io.c (main): Pass a third argument to open().
34985         Reported by Gary V. Vaughan <gary@gnu.org>.
34986
34987 2007-06-01  Bruno Haible  <bruno@clisp.org>
34988
34989         * doc/functions/frexpl.texi: Update for mingw.
34990
34991 2007-06-01  Bruno Haible  <bruno@clisp.org>
34992
34993         * tests/test-lseek.c (main): Disable test of errno for invalid third
34994         argument.
34995         * doc/functions/lseek.texi: Update.
34996         Reported by Gary V. Vaughan <gary@gnu.org>.
34997
34998 2007-05-28  Bruno Haible  <bruno@clisp.org>
34999
35000         * m4/intl.m4 (AM_INTL_SUBDIR): Substitute variables WOE32, WINDRES.
35001
35002 2007-05-31  Eric Blake  <ebb9@byu.net>
35003
35004         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Guess no on mingw when
35005         cross compiling.
35006
35007 2007-05-30  Eric Blake  <ebb9@byu.net>
35008         and Bruno Haible  <bruno@clisp.org>
35009
35010         Work around mingw test failures exposed by m4-1.4.9b.
35011         * m4/stdint.m4 (gl_STDINT_H): Detect mingw bug.
35012         * tests/test-unistd.c: Disable uid_t and git_t tests for the
35013         moment.
35014
35015 2007-05-30  Bruno Haible  <bruno@clisp.org>
35016
35017         * tests/test-lseek.c: Explicitly close file descriptors 0 and 1 before
35018         assuming that they are closed. Needed on HP-UX 11.
35019
35020 2007-05-29  Bruno Haible  <bruno@clisp.org>
35021
35022         Fix a problem with #include_next.
35023         * lib/dirent_.h: Split the double-inclusion guard.
35024         * lib/fcntl_.h: Likewise.
35025         * lib/float_.h: Likewise.
35026         * lib/iconv_.h: Likewise.
35027         * lib/inttypes_.h: Likewise.
35028         * lib/locale_.h: Likewise.
35029         * lib/math_.h: Likewise.
35030         * lib/netinet_in_.h: Likewise.
35031         * lib/search_.h: Likewise.
35032         * lib/signal_.h: Likewise.
35033         * lib/stdint_.h: Likewise.
35034         * lib/stdio_.h: Likewise.
35035         * lib/stdlib_.h: Likewise.
35036         * lib/string_.h: Likewise.
35037         * lib/sys_select_.h: Likewise.
35038         * lib/sys_socket_.h: Likewise.
35039         * lib/sys_stat_.h: Likewise.
35040         * lib/sys_time_.h: Likewise.
35041         * lib/sysexits_.h: Likewise.
35042         * lib/time_.h: Likewise.
35043         * lib/unistd_.h: Likewise.
35044         * lib/wchar_.h: Likewise.
35045         * lib/wctype_.h: Likewise.
35046
35047 2007-05-29  Bruno Haible  <bruno@clisp.org>
35048
35049         * tests/test-unistd.c: Disable the tests for useconds_t and intptr_t
35050         for the moment.
35051
35052 2007-05-29  Bruno Haible  <bruno@clisp.org>
35053
35054         * m4/isnan.m4 (gl_DOUBLE_EXPONENT_LOCATION): Silence the AC_C_BIGENDIAN
35055         invocation.
35056         Reported by Eric Blake.
35057
35058 2007-05-29  Bruno Haible  <bruno@clisp.org>
35059
35060         * m4/isnanf.m4 (gl_FLOAT_EXPONENT_LOCATION): Fix typo in cross-
35061         compiling case.
35062
35063 2007-05-29  Eric Blake  <ebb9@byu.net>
35064             Bruno Haible  <bruno@clisp.org>
35065
35066         * m4/isnanf.m4 (gl_FUNC_ISNANF_NO_LIBM): Avoid syntax error on
35067         cross compiles.
35068
35069 2007-05-28  Eric Blake  <ebb9@byu.net>
35070
35071         * modules/closein-tests (test_closein_LDADD): Support test on
35072         cygwin with libtool.
35073
35074 2007-05-28  Bruno Haible  <bruno@clisp.org>
35075
35076         * tests/uniconv/test-u16-conv-from-enc.c: Remove #ifdef HAVE_CONFIG_H.
35077         * tests/uniconv/test-u16-strconv-from-enc.c: Likewise.
35078         * tests/uniconv/test-u16-strconv-to-enc.c: Likewise.
35079         * tests/uniconv/test-u32-conv-from-enc.c: Likewise.
35080         * tests/uniconv/test-u32-strconv-from-enc.c: Likewise.
35081         * tests/uniconv/test-u32-strconv-to-enc.c: Likewise.
35082         * tests/uniconv/test-u8-conv-from-enc.c: Likewise.
35083         * tests/uniconv/test-u8-strconv-from-enc.c: Likewise.
35084         * tests/uniconv/test-u8-strconv-to-enc.c: Likewise.
35085
35086 2007-05-28  Eric Blake  <ebb9@byu.net>
35087
35088         Unconditionally include <config.h> in unit tests.
35089         * tests/test-alloca-opt.c: Remove #ifdef HAVE_CONFIG_H.
35090         * tests/test-allocsa.c, tests/test-arcfour.c,
35091         tests/test-arctwo.c, tests/test-argmatch.c, tests/test-argp.c,
35092         tests/test-array_list.c, tests/test-array_oset.c,
35093         tests/test-atexit.c, test-avltree_list.c, test-avltree_oset.c,
35094         test-avltreehash_list.c, test-base64.c, test-binary-io.c,
35095         test-c-ctype.c, test-c-strcasecmp.c, test-c-strcasestr.c,
35096         test-c-strncasecmp.c, test-c-strstr.c, test-canonicalize-lgpl.c,
35097         test-carray_list.c, test-crc.c, test-des.c, test-dirname.c,
35098         test-fflush.c, test-fprintf-posix.c, test-gc-arcfour.c,
35099         test-gc-arctwo.c, test-gc-des.c, test-gc-hmac-md5.c,
35100         test-gc-hmac-sha1.c, test-gc-md2.c, test-gc-md4.c, test-gc-md5.c,
35101         test-gc-pbkdf2-sha1.c, test-gc-rijndael.c, test-gc-sha1.c,
35102         test-gc.c, test-getpass.c, test-hmac-md5.c, test-hmac-sha1.c,
35103         test-iconv.c, test-linked_list.c, test-linkedhash_list.c,
35104         test-lock.c, test-mbscasecmp.c, test-mbscasestr1.c,
35105         test-mbscasestr2.c, test-mbscasestr3.c, test-mbscasestr4.c,
35106         test-mbschr.c, test-mbscspn.c, test-mbsncasecmp.c, test-mbspbrk.c,
35107         test-mbspcasecmp.c, test-mbsrchr.c, test-mbsspn.c, test-mbsstr1.c,
35108         test-mbsstr2.c, test-mbsstr3.c, test-md2.c, test-md4.c,
35109         test-md5.c, test-memmem.c, test-printf-posix.c,
35110         test-rbtree_list.c, test-rbtree_oset.c, test-rbtreehash_list.c,
35111         test-read-file.c, test-rijndael.c, test-snprintf-posix.c,
35112         test-snprintf.c, test-sprintf-posix.c, test-stdint.c,
35113         test-strcasestr.c, test-striconv.c, test-striconveh.c,
35114         test-striconveha.c, test-tls.c, test-vasnprintf-posix.c,
35115         test-vasnprintf-posix2.c, test-vasnprintf.c,
35116         test-vasprintf-posix.c, test-vasprintf.c, test-verify.c,
35117         test-vfprintf-posix.c, test-vprintf-posix.c,
35118         test-vsnprintf-posix.c, test-vsnprintf.c, test-vsprintf-posix.c,
35119         test-xvasprintf.c: Likewise.
35120
35121 2007-05-28  Bruno Haible  <bruno@clisp.org>
35122
35123         * gnulib-tool (func_import): Remember the --with-tests command-line
35124         option through the macro gl_WITH_TESTS in the gnulib-cache.m4.
35125         Reported by Eric Blake.
35126
35127 2007-05-28  Bruno Haible  <bruno@clisp.org>
35128
35129         * modules/ftell-tests: New file.
35130         * tests/test-ftell.c: New file, based on tests/test-ftello.c.
35131         * tests/test-ftell.sh: New file, based on tests/test-ftello.sh.
35132
35133         * lib/ftell.c: New file.
35134         * modules/ftell: New file.
35135         * m4/ftell.m4: New file.
35136         * doc/functions/ftell.texi: Update.
35137         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELL,
35138         REPLACE_FTELL.
35139         * lib/stdio_.h (rpl_ftell): New declaration.
35140         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELL,
35141         REPLACE_FTELL.
35142
35143 2007-05-28  Eric Blake  <ebb9@byu.net>
35144
35145         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
35146
35147 2007-05-28  Bruno Haible  <bruno@clisp.org>
35148
35149         * modules/fseek-tests: New file.
35150         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
35151         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
35152
35153         * lib/fseek.c: New file.
35154         * modules/fseek: New file.
35155         * m4/fseek.m4: New file.
35156         * doc/functions/fseek.texi: Update.
35157         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
35158         REPLACE_FSEEK.
35159         * lib/stdio_.h (rpl_fseek): New declaration.
35160         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
35161         REPLACE_FSEEK.
35162
35163 2007-05-28  Bruno Haible  <bruno@clisp.org>
35164
35165         * lib/stdio_.h (fflush): More comments.
35166
35167 2007-05-28  Bruno Haible  <bruno@clisp.org>
35168
35169         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
35170         runtime test.
35171
35172 2007-05-28  Eric Blake  <ebb9@byu.net>
35173
35174         Improve lseek module.
35175         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
35176         * lib/unistd_.h (lseek): Scale back link warning message.
35177         * tests/test-lseek.c: Beef up test.
35178         * tests/test-lseek.sh: Exercise more facets of lseek.
35179         Reported by Bruno Haible.
35180
35181 2007-05-28  Bruno Haible  <bruno@clisp.org>
35182
35183         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
35184         to define.
35185
35186 2007-05-27  Bruno Haible  <bruno@clisp.org>
35187
35188         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
35189
35190 2007-05-27  Bruno Haible  <bruno@clisp.org>
35191
35192         * modules/openmp: New file.
35193         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
35194         Noah Misch.
35195
35196 2007-05-26  Bruno Haible  <bruno@clisp.org>
35197
35198         * modules/chdir-long (Depends-on): Add fchdir.
35199         * modules/chdir-safer (Depends-on): Likewise.
35200         * modules/fts (Depends-on): Likewise.
35201         * modules/fts-lgpl (Depends-on): Likewise.
35202         * modules/openat (Depends-on): Likewise.
35203         * modules/savewd (Depends-on): Likewise.
35204
35205 2007-05-24  Eric Blake  <ebb9@byu.net>
35206
35207         Fix lseek on mingw.
35208         * modules/lseek: New module.
35209         * m4/lseek.m4: New file.
35210         * lib/lseek.c: New file.
35211         * modules/lseek-tests: New file.
35212         * tests/test-lseek.c: New file.
35213         * tests/test-lseek.sh: New file.
35214         * MODULES.html.sh: Document lseek module.
35215         * modules/fflush (Depends-on): Add lseek, fseeko.
35216         * modules/fseeko (Depends-on): Likewise.
35217         * modules/ftello (Depends-on): Likewise.
35218         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
35219         broken.
35220         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
35221         broken.
35222         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
35223         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
35224         * lib/ftello.c (rpl_ftello): Likewise.
35225         * tests/test-fseeko.c (main): Test this.
35226         * tests/test-fseeko.sh: Likewise.
35227         * tests/test-ftello.c (main): Likewise.
35228         * tests/test-ftello.sh: Likewise.
35229         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
35230         implies replacing fseek.
35231         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
35232         HAVE_FTELLO.
35233         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
35234         * modules/unistd (Makefile.am): Likewise.
35235         * lib/unistd_.h (lseek): Declare a replacement.
35236         * doc/functions/lseek.texi (lseek): Document this fix.
35237         * doc/functions/fseek.texi (fseek): Likewise.
35238         * doc/functions/ftell.texi (ftell): Likewise.
35239
35240 2007-05-24  Bruno Haible  <bruno@clisp.org>
35241
35242         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
35243         in the printed representation of a NaN.
35244         * tests/test-vasprintf-posix.c (test_function): Likewise.
35245         * tests/test-snprintf-posix.h (test_function): Likewise.
35246         * tests/test-sprintf-posix.h (test_function): Likewise.
35247         Reported by Eric Blake.
35248
35249 2007-05-23  Eric Blake  <ebb9@byu.net>
35250
35251         Fix fseeko/ftello on cygwin 1.5.24.
35252         * doc/functions/fseeko.texi (fseeko): Document the fix.
35253         * doc/functions/ftello.texi (ftello): Document the fix.
35254         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
35255         * doc/functions/stdout.text (stdout): New file.
35256         * doc/functions/stderr.text (stderr): New file.
35257         * doc/gnulib.texi (Function Substitutes): Use new files.
35258         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
35259         prior to 1.7.0.
35260         * tests/test-ftello.c (main): Likewise for ftello.
35261         * tests/test-fseeko.sh: New file.
35262         * tests/test-ftello.sh: New file.
35263         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
35264         with seekable stdin.
35265         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
35266         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
35267         (gl_REPLACE_FSEEKO): New macro.
35268         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
35269         * modules/fseeko (Files): Distribute fseeko.c.
35270         * modules/ftello (Files): Distribute ftello.c.
35271         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
35272         mode.
35273         * lib/ftello.c (rpl_ftello): New file.
35274         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
35275         fseeko, ftello.
35276         (gl_STDIN_LARGE_OFFSET): New macro.
35277         * modules/stdio (Makefile.am): Perform the replacement.
35278         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
35279
35280 2007-05-23  Bruno Haible  <bruno@clisp.org>
35281
35282         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
35283         GNULIB_POSIXCHECK is defined.
35284
35285 2007-05-21  Bruno Haible  <bruno@clisp.org>
35286
35287         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
35288         Check also the output for NaN arguments. When cross-compiling, guess
35289         no on IRIX.
35290         * lib/vasnprintf.c: Update comments.
35291         * tests/test-vasnprintf-posix.c (strisnan): New function.
35292         (test_function): Use it.
35293         * tests/test-vasprintf-posix.c (strisnan): New function.
35294         (test_function): Use it.
35295         * tests/test-snprintf-posix.h (strisnan): New function.
35296         (test_function): Use it.
35297         * tests/test-sprintf-posix.h (strisnan): New function.
35298         (test_function): Use it.
35299         Reported by Eric Blake.
35300
35301 2007-05-20  Bruno Haible  <bruno@clisp.org>
35302
35303         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
35304         numbers that fails on BeOS.
35305         * doc/functions/frexpl.texi: Update.
35306
35307 2007-05-20  Jim Meyering  <jim@meyering.net>
35308
35309         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
35310         forced upon us by glibc-2.6.
35311
35312 2007-05-20  Bruno Haible  <bruno@clisp.org>
35313
35314         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
35315         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
35316         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
35317         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
35318         NEED_PRINTF_INFINITE.
35319         (is_infinitel): New function.
35320         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
35321         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
35322         gl_PREREQ_VASNPRINTF_INFINITE.
35323         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
35324         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
35325         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
35326         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
35327         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
35328         gl_PREREQ_VASNPRINTF_INFINITE.
35329         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
35330         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
35331         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
35332         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
35333         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
35334         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35335         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
35336         * doc/functions/fprintf.texi: Update.
35337         * doc/functions/printf.texi: Update.
35338         * doc/functions/snprintf.texi: Update.
35339         * doc/functions/sprintf.texi: Update.
35340         * doc/functions/vfprintf.texi: Update.
35341         * doc/functions/vprintf.texi: Update.
35342         * doc/functions/vsnprintf.texi: Update.
35343         * doc/functions/vsprintf.texi: Update.
35344
35345 2007-05-20  Bruno Haible  <bruno@clisp.org>
35346
35347         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
35348         was not found in libc.
35349         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
35350
35351 2007-05-20  Bruno Haible  <bruno@clisp.org>
35352
35353         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
35354         printed as "-nan" instead of "nan".
35355         * tests/test-vasprintf-posix.c (test_function): Likewise.
35356         * tests/test-snprintf-posix.h (test_function): Likewise.
35357         * tests/test-sprintf-posix.h (test_function): Likewise.
35358         Needed for HP-UX 11.
35359
35360 2007-05-20  Jim Meyering  <jim@meyering.net>
35361
35362         Fix buggy test for the fchownat-deref bug.
35363         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
35364         symlink required for the run-test.  Without it, this test would
35365         always declare that fchownat doesn't work, and client code would
35366         unnecessarily use the replacement function with fixed libc.
35367         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
35368         Reported by Greg Schafer.
35369
35370 2007-05-19  Bruno Haible  <bruno@clisp.org>
35371
35372         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
35373         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
35374         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
35375         Needed for IRIX 6.5 and Solaris 2.5.1.
35376
35377 2007-05-19  Bruno Haible  <bruno@clisp.org>
35378
35379         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
35380         (test_function): Skip tests involving -0.0 on platforms where
35381         -0.0 = 0.0.
35382         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
35383         (test_function): Skip tests involving -0.0 on platforms where
35384         -0.0 = 0.0.
35385         * tests/test-snprintf-posix.h (have_minus_zero): New function.
35386         (test_function): Skip tests involving -0.0 on platforms where
35387         -0.0 = 0.0.
35388         * tests/test-sprintf-posix.h (have_minus_zero): New function.
35389         (test_function): Skip tests involving -0.0 on platforms where
35390         -0.0 = 0.0.
35391         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
35392         tests.
35393         * tests/test-printf-posix.h (test_function): Likewise.
35394         * tests/test-printf-posix.output: Remove all -0.0 related results.
35395         Needed for IRIX 6.5.
35396
35397 2007-05-19  Bruno Haible  <bruno@clisp.org>
35398
35399         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
35400         printed as "nan0x7fffffff" instead of "nan".
35401         * tests/test-vasprintf-posix.c (test_function): Likewise.
35402         * tests/test-snprintf-posix.h (test_function): Likewise.
35403         * tests/test-sprintf-posix.h (test_function): Likewise.
35404         * tests/test-fprintf-posix.h (NaN): Remove macro.
35405         (test_function): Remove all NaN related tests.
35406         * tests/test-printf-posix.h (NaN): Remove macro.
35407         (test_function): Remove all NaN related tests.
35408         * tests/test-printf-posix.output: Remove all NaN related results.
35409         Needed for IRIX 6.5.
35410
35411 2007-05-19  Bruno Haible  <bruno@clisp.org>
35412
35413         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
35414         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
35415
35416 2007-05-19  Bruno Haible  <bruno@clisp.org>
35417
35418         * lib/float_.h: New file.
35419         * m4/float_h.m4: New file.
35420         * modules/float: New file.
35421         * modules/isnanl (Dependencies): Add float.
35422         * modules/isnanl-nolibm (Dependencies): Likewise.
35423         * modules/mathl (Dependencies): Likewise.
35424         * modules/printf-frexpl (Dependencies): Likewise.
35425         * modules/signbit (Dependencies): Likewise.
35426         * modules/vasnprintf (Dependencies): Likewise.
35427         * doc/headers/float.texi: Update.
35428
35429 2007-05-19  Jim Meyering  <jim@meyering.net>
35430
35431         * lib/utimens.c (gl_futimens): Rename from futimens,
35432         now that glibc-2.6 declares futimens.
35433         * lib/utimens.h: Likewise.
35434
35435 2007-05-19  Bruno Haible  <bruno@clisp.org>
35436
35437         Avoid test failures on mingw.
35438         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
35439         * tests/test-printf-posix.sh: Likewise.
35440         * tests/test-vfprintf-posix.sh: Likewise.
35441         * tests/test-vprintf-posix.sh: Likewise.
35442
35443 2007-05-19  Bruno Haible  <bruno@clisp.org>
35444
35445         Fix *printf result for NaN, Inf, -0.0 on mingw.
35446         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
35447         * lib/vasnprintf.c: Include math.h and isnan.h.
35448         (is_infinite_or_zero): New function.
35449         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
35450         values in the %f, %F, %e, %E, %g, %G directives.
35451         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
35452         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
35453         gl_PRINTF_INFINITE and test its result. Invoke
35454         gl_PREREQ_VASNPRINTF_INFINITE.
35455         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
35456         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
35457         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
35458         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
35459         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
35460         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35461         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
35462         * doc/functions/fprintf.texi: Update.
35463         * doc/functions/printf.texi: Update.
35464         * doc/functions/snprintf.texi: Update.
35465         * doc/functions/sprintf.texi: Update.
35466         * doc/functions/vfprintf.texi: Update.
35467         * doc/functions/vprintf.texi: Update.
35468         * doc/functions/vsnprintf.texi: Update.
35469         * doc/functions/vsprintf.texi: Update.
35470
35471 2007-05-19  Bruno Haible  <bruno@clisp.org>
35472
35473         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
35474         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
35475         Instead of multiplying with 10^k, set extra_zeroes to k.
35476         (scale10_round_long_double): Remove function.
35477
35478 2007-05-18  Bruno Haible  <bruno@clisp.org>
35479
35480         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
35481         introduced on 2007-05-06.
35482
35483 2007-05-18  Bruno Haible  <bruno@clisp.org>
35484
35485         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
35486         %g directives.
35487         * tests/test-vasprintf-posix.c (test_function): Likewise.
35488         * tests/test-snprintf-posix.h (test_function): Likewise.
35489         * tests/test-sprintf-posix.h (test_function): Likewise.
35490
35491 2007-05-18  Bruno Haible  <bruno@clisp.org>
35492
35493         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
35494         (strmatch): New function.
35495         (test_function): Test the %f directive on numbers of various exponents.
35496         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
35497         (strmatch): New function.
35498         (test_function): Test the %f directive on numbers of various exponents.
35499         * tests/test-snprintf-posix.h (strmatch): New function.
35500         (test_function): Test the %f directive on numbers of various exponents.
35501         * tests/test-sprintf-posix.h (strmatch): New function.
35502         (test_function): Test the %f directive on numbers of various exponents.
35503         * tests/test-snprintf-posix.c (SIZEOF): New macro.
35504         * tests/test-sprintf-posix.c (SIZEOF): New macro.
35505         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
35506         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
35507
35508 2007-05-18  Bruno Haible  <bruno@clisp.org>
35509
35510         Add support for 'long double' number output.
35511         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
35512         * lib/vasnprintf.c: Include math.h and float+.h.
35513         (mp_limb_t): New type.
35514         (GMP_LIMB_BITS): New macro.
35515         (mp_twolimb_t): New type.
35516         (GMP_TWOLIMB_BITS): New macro.
35517         (mpn_t): New type.
35518         (multiply, divide, convert_to_decimal, decode_long_double,
35519         scale10_round_long_double, scale10_round_decimal_long_double,
35520         floorlog10l): New functions.
35521         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
35522         for the %f, %F, %e, %E, %g, %G directives.
35523         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
35524         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
35525         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
35526         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
35527         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
35528         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
35529         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
35530         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
35531         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
35532         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35533         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
35534         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
35535         * modules/snprintf-posix (Depends-on): Likewise.
35536         * modules/sprintf-posix (Depends-on): Likewise.
35537         * modules/vasnprintf-posix (Depends-on): Likewise.
35538         * modules/vasprintf-posix (Depends-on): Likewise.
35539         * modules/vfprintf-posix (Depends-on): Likewise.
35540         * modules/vsnprintf-posix (Depends-on): Likewise.
35541         * modules/vsprintf-posix (Depends-on): Likewise.
35542         * modules/vasnprintf (Files): Add lib/float+.h.
35543         * doc/functions/fprintf.texi: Update.
35544         * doc/functions/printf.texi: Update.
35545         * doc/functions/snprintf.texi: Update.
35546         * doc/functions/sprintf.texi: Update.
35547         * doc/functions/vfprintf.texi: Update.
35548         * doc/functions/vprintf.texi: Update.
35549         * doc/functions/vsnprintf.texi: Update.
35550         * doc/functions/vsprintf.texi: Update.
35551
35552 2007-05-18  Bruno Haible  <bruno@clisp.org>
35553
35554         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
35555
35556 2007-05-18  Bruno Haible  <bruno@clisp.org>
35557
35558         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
35559         for printing 64-bit integers. Needed for mingw.
35560
35561 2007-05-18  Bruno Haible  <bruno@clisp.org>
35562
35563         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
35564         gl_FUNC_FREXPL_WORKS.
35565         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
35566
35567 2007-05-18  Bruno Haible  <bruno@clisp.org>
35568
35569         * modules/frexpl-nolibm-tests: New file.
35570
35571         * modules/frexpl-nolibm: New file.
35572         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
35573
35574 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
35575
35576         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
35577         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
35578         GCC 4.2, which otherwise issues a lot of warnings.
35579         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
35580         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
35581         Likewise.
35582         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
35583         * modules/iconv_open (iconv.h): Likewise.
35584         * modules/locale (locale.h): Likewise.
35585         * modules/netinet_in (netinet/in.h): Likewise.
35586         * modules/sys_select (sys_select.h): Likewise.
35587         * modules/sys_socket (sys/socket.h): Likewise.
35588         * modules/sys_stat (sys/stat.h): Likewise.
35589         * modules/sysexits (sysexits.h): Likewise.
35590         * modules/unistd (unistd.h): Likewise.
35591
35592 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
35593
35594         * modules/closein-tests (Makefile.am): Distribute
35595         `test-closein.sh'.
35596
35597 2007-05-17  Bruno Haible  <bruno@clisp.org>
35598
35599         * tests/test-printf-posix.output: Renamed from
35600         tests/test-fprintf-posix.out.
35601         * modules/fprintf-posix-tests: Update.
35602         * modules/printf-posix-tests: Update.
35603         * modules/vfprintf-posix-tests: Update.
35604         * modules/vprintf-posix-tests: Update.
35605         * tests/test-fprintf-posix.sh: Update.
35606         * tests/test-printf-posix.sh: Update.
35607         * tests/test-vfprintf-posix.sh: Update.
35608         * tests/test-vprintf-posix.sh: Update.
35609         Reported by Ralf Wildenhues.
35610
35611 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
35612
35613         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
35614         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
35615         GCC 4.2, which otherwise issues a lot of warnings.
35616         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
35617         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
35618         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
35619         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
35620         it should no longer be needed.
35621         * lib/string_.h: Likewise.
35622         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
35623         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
35624         * modules/inttypes (inttypes.h): Likewise.
35625         * modules/math (math.h): Likewise.
35626         * modules/search (search.h): Likewise.
35627         * modules/signal (signal.h): Likewise.
35628         * modules/stdint (stdint.h): Likewise.
35629         * modules/stdio (stdio.h): Likewise.
35630         * modules/stdlib (stdlib.h): Likewise.
35631         * modules/string (string.h): Likewise.
35632         * modules/sys_time (sys/time.h): Likewise.
35633         * modules/time (time.h): Likewise.
35634         * modules/wchar (wchar.h): Likewise.
35635         * modules/wctype (wtype.h): Likewise.
35636
35637 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
35638
35639         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
35640
35641 2007-05-13  Bruno Haible  <bruno@clisp.org>
35642
35643         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
35644         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
35645         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
35646         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
35647         (gl_PREREQ_STRTOK_R): Don't require it here.
35648
35649 2007-05-13  Bruno Haible  <bruno@clisp.org>
35650
35651         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
35652         when used in C++ mode.
35653
35654 2007-05-12  Bruno Haible  <bruno@clisp.org>
35655
35656         * lib/linebuffer.h: Tweak doc.
35657         * lib/linebuffer.c: Likewise.
35658
35659 2007-05-12  James Youngman  <jay@gnu.org>
35660
35661         * lib/linebuffer.c (readlinebuffer_delim): New function,
35662         like readlinebuffer, but use a caller-specified delimiter.
35663         (readlinebuffer): Just call readlinebuffer_delim with '\n'
35664         as the delimiter.
35665         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
35666
35667 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
35668
35669         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
35670         * modules/openat (Files): Remove openat-die.c.
35671         (Depends-on): Add openat-die.
35672         * modules/openat-die: New module.
35673
35674 2007-05-06  Bruno Haible  <bruno@clisp.org>
35675
35676         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
35677         Update with info about Cygwin.
35678         * doc/functions/fprintf.texi: Update.
35679         * doc/functions/printf.texi: Update.
35680         * doc/functions/snprintf.texi: Update.
35681         * doc/functions/sprintf.texi: Update.
35682         * doc/functions/vfprintf.texi: Update.
35683         * doc/functions/vprintf.texi: Update.
35684         * doc/functions/vsnprintf.texi: Update.
35685         * doc/functions/vsprintf.texi: Update.
35686         Reported by Eric Blake.
35687
35688 2007-05-06  Bruno Haible  <bruno@clisp.org>
35689
35690         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
35691         padding ourselves for the floating-point directives.
35692         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
35693         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
35694         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
35695         gl_PRINTF_FLAG_ZERO and test its result. Invoke
35696         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
35697         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
35698         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
35699         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
35700         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
35701         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
35702         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35703         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
35704         * tests/test-snprintf-posix.h (test_function): Also check the width
35705         and some flags in the %f directive.
35706         * tests/test-sprintf-posix.h (test_function): Likewise.
35707         * tests/test-vasnprintf-posix.c (test_function): Likewise.
35708         * tests/test-vasprintf-posix.c (test_function): Likewise.
35709         * doc/functions/fprintf.texi: Update.
35710         * doc/functions/printf.texi: Update.
35711         * doc/functions/snprintf.texi: Update.
35712         * doc/functions/sprintf.texi: Update.
35713         * doc/functions/vfprintf.texi: Update.
35714         * doc/functions/vprintf.texi: Update.
35715         * doc/functions/vsnprintf.texi: Update.
35716         * doc/functions/vsprintf.texi: Update.
35717
35718 2007-05-06  Bruno Haible  <bruno@clisp.org>
35719
35720         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
35721         pass the ' flag character to sprintf or snprintf.
35722         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
35723         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
35724         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
35725         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
35726         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
35727         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
35728         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
35729         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
35730         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
35731         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
35732         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35733         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
35734         * tests/test-snprintf-posix.h (test_function): Also check the grouping
35735         flag.
35736         * tests/test-sprintf-posix.h (test_function): Likewise.
35737         * tests/test-vasnprintf-posix.c (test_function): Likewise.
35738         * tests/test-vasprintf-posix.c (test_function): Likewise.
35739         * doc/functions/fprintf.texi: Update.
35740         * doc/functions/printf.texi: Update.
35741         * doc/functions/snprintf.texi: Update.
35742         * doc/functions/sprintf.texi: Update.
35743         * doc/functions/vfprintf.texi: Update.
35744         * doc/functions/vprintf.texi: Update.
35745         * doc/functions/vsnprintf.texi: Update.
35746         * doc/functions/vsprintf.texi: Update.
35747
35748 2007-05-01  Bruno Haible  <bruno@clisp.org>
35749
35750         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
35751
35752 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
35753
35754         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
35755         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
35756
35757 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
35758
35759         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
35760         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
35761         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
35762
35763 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
35764
35765         * lib/argp-help.c (struct hol_entry): New member `ord'.
35766         (HOL_ENTRY_PTRCMP): Use ord for comparison
35767         (hol_sort): Initialize ord.
35768
35769 2007-05-01  Bruno Haible  <bruno@clisp.org>
35770
35771         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
35772         Reported by Eric Blake.
35773         * doc/gnulib.texi (Function Substitutes): Update.
35774
35775 2007-05-01  Bruno Haible  <bruno@clisp.org>
35776
35777         * doc/functions.texi: Remove file, now redundant through
35778         doc/functions/*.texi.
35779
35780 2007-05-01  Bruno Haible  <bruno@clisp.org>
35781
35782         * modules/argp (Depends-on): Add sleep.
35783
35784 2007-05-01  Bruno Haible  <bruno@clisp.org>
35785
35786         * modules/sleep-tests: New file.
35787         * tests/test-sleep.c: New file.
35788
35789         * modules/sleep: New file.
35790         * lib/sleep.c: New file.
35791         * m4/sleep.m4: New file.
35792         * lib/unistd_.h (sleep): New declaration.
35793         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
35794         HAVE_SLEEP.
35795         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
35796         * doc/functions/sleep.texi: Document the sleep module.
35797
35798 2007-05-01  Bruno Haible  <bruno@clisp.org>
35799
35800         * lib/sigprocmask.h: Remove file.
35801         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
35802         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
35803         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
35804         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
35805         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
35806         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
35807         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
35808         HAVE_SIGSET_T as a shell variable.
35809         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
35810         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
35811         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
35812         (Depends-on): Add signal. Remove verify.
35813         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
35814         (Include): Mention <signal.h> instead of sigprocmask.h.
35815         * NEWS: Mention the change.
35816         * lib/fatal-signal.c: Don't include sigprocmask.h.
35817
35818 2007-05-01  Bruno Haible  <bruno@clisp.org>
35819
35820         * modules/signal: New file.
35821         * lib/signal_.h: New file.
35822         * m4/signal_h.m4: New file.
35823
35824 2007-05-01  Bruno Haible  <bruno@clisp.org>
35825
35826         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
35827         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
35828         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
35829         HAVE_WCTYPE_CTMP_BUG into wctype.h.
35830
35831 2007-05-01  Bruno Haible  <bruno@clisp.org>
35832
35833         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
35834         configure time.
35835         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
35836         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
35837         * modules/sys_stat (Makefile.am): Substitute their values into
35838         sys/stat.h.
35839
35840 2007-05-01  Bruno Haible  <bruno@clisp.org>
35841
35842         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
35843         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
35844         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
35845
35846 2007-05-01  Bruno Haible  <bruno@clisp.org>
35847
35848         * doc/header/assert.texi: Undo last change: don't mention the gnulib
35849         'assert' module here.
35850
35851 2007-05-01  Bruno Haible  <bruno@clisp.org>
35852
35853         * doc/functions/*.texi: New files.
35854         * doc/functions/google-ranking.txt: New file.
35855         * doc/gnulib.texi (Function Substitutes): New chapter.
35856         (ctime, inet_ntoa): Remove sections.
35857         * doc/ctime.texi: Remove file.
35858         * doc/inet_ntoa.texi: Remove file.
35859         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
35860         dependencies.
35861         (%.info): New rule, specifying a --reference-limit.
35862
35863 2007-05-01  Bruno Haible  <bruno@clisp.org>
35864
35865         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
35866
35867 2007-05-01  Bruno Haible  <bruno@clisp.org>
35868
35869         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
35870         the portability of 'mkdir' to mingw systems.
35871
35872 2007-05-01  Bruno Haible  <bruno@clisp.org>
35873
35874         * doc/headers/google-ranking.txt: New file.
35875
35876 2007-04-30  Eric Blake  <ebb9@byu.net>
35877
35878         Prefer fseeko to fseek.
35879         * modules/getpass (Depends-on): Add fseeko.
35880         * lib/getpass.c (getpass): Use fseeko, not fseek.
35881
35882 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
35883
35884         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
35885         assumes the sorting is stable, while most qsort implementations
35886         are not.  Use argument addresses to ensure they never compare as
35887         equal.
35888
35889         * tests/test-argp-2.sh (usage-indent test): Fix output
35890         (func_compare): Restore diff options
35891         * tests/test-argp.c: Restore #include "progname.h"
35892
35893 2007-04-29  Bruno Haible  <bruno@clisp.org>
35894
35895         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
35896         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
35897         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
35898         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
35899         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
35900         (configure.ac): Define CHECK_SNPRINTF_POSIX.
35901         (TESTS, check_PROGRAMS): Add test-snprintf.
35902         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
35903         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
35904         (TESTS, check_PROGRAMS): Add test-vsnprintf.
35905         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
35906         assertions that fail on HP-UX, OSF/1, or IRIX.
35907         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
35908
35909 2007-04-29  Bruno Haible  <bruno@clisp.org>
35910
35911         * MODULES.html.sh (posix_functions): Remove 'contents'.
35912
35913 2007-04-29  Karl Berry  <karl@gnu.org>
35914
35915         * config/srclist.txt (gendocs_template_min): new entry.
35916
35917 2007-04-29  Bruno Haible  <bruno@clisp.org>
35918
35919         Work around fpurge bug on BSD systems.
35920         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
35921         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
35922         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
35923         fpurge to rpl_fpurge if the system already has this function.
35924         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
35925         the case where the system already has this function. Correct invariants
35926         on BSD systems.
35927         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
35928         BSD systems.
35929
35930 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
35931
35932         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
35933         proposed by Sven Verdoolaege.
35934
35935         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
35936         options.
35937         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
35938         (usage and help tests): Update
35939
35940 2007-04-29  Bruno Haible  <bruno@clisp.org>
35941
35942         * tests/test-fflush.c (main): Use a file of size 17, not 10.
35943         Print more information in case of failure. Disable a test on BeOS.
35944
35945 2007-04-29  Bruno Haible  <bruno@clisp.org>
35946
35947         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
35948         This helps debugging on systems on which no gdb is available.
35949
35950 2007-04-29  Bruno Haible  <bruno@clisp.org>
35951
35952         * lib/freading.h: Improve comments.
35953         * lib/fwriting.h: Likewise.
35954         * tests/test-freading.c (main): Don't check freading immediately after
35955         repositioning. Needed for glibc.
35956
35957 2007-04-29  Bruno Haible  <bruno@clisp.org>
35958
35959         * lib/freading.c (freading): Trivial simplification.
35960
35961 2007-04-28  Bruno Haible  <bruno@clisp.org>
35962
35963         * tests/test-fwriting.c (main): Also test the interaction between
35964         fflush and fwriting.
35965         * modules/fwriting-tests (Depends-on): Add fflush.
35966
35967         * tests/test-freading.c (main): Also test the interaction between
35968         fflush and freading.
35969         * modules/freading-tests (Depends-on): Add fflush.
35970
35971 2007-04-28  Bruno Haible  <bruno@clisp.org>
35972
35973         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
35974         fseeko and ftello.
35975         Suggested by Eric Blake.
35976
35977 2007-04-28  Jim Meyering  <jim@meyering.net>
35978
35979         Avoid false-negative in gl_STDINT_H's C99 conformance test.
35980         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
35981         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
35982
35983 2007-04-27  Eric Blake  <ebb9@byu.net>
35984
35985         * doc/headers/assert.texi (assert.h): Document assert module use.
35986
35987 2007-04-27  Bruno Haible  <bruno@clisp.org>
35988
35989         * doc/headers/*.texi: New files.
35990         * doc/gnulib.texi (Header File Substitutes): New chapter.
35991         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
35992         dependencies.
35993         (standards.info ,standards.html, standards.dvi): Update dependencies.
35994         (mostlyclean, clean): New targets.
35995
35996 2007-04-27  Bruno Haible  <bruno@clisp.org>
35997
35998         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
35999         * modules/sysexits (Files, Makefile.am): Update.
36000
36001         * lib/sys_socket_.h: Renamed from lib/socket_.h.
36002         * modules/sys_socket (Files, Makefile.am): Update.
36003
36004         * lib/sys_stat_.h: Renamed from lib/stat_.h.
36005         * modules/sys_stat (Files, Makefile.am): Update.
36006
36007 2007-04-27  Eric Blake  <ebb9@byu.net>
36008
36009         * lib/freading.h: Improve comments.
36010         * lib/fwriting.h: Likewise.
36011         * lib/fflush.c: Likewise.
36012
36013         Fix closein for mingw.
36014         * modules/closein-tests: Add tests for closein.
36015         * tests/test-closein.c: New file.
36016         * tests/test-closein.sh: Likewise.
36017         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
36018         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
36019
36020 2007-04-27  Bruno Haible  <bruno@clisp.org>
36021
36022         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
36023         version is < 6.
36024         * lib/math_.h [__DECC]: Likewise.
36025         * lib/stdio_.h [__DECC]: Likewise.
36026         * lib/stdlib_.h [__DECC]: Likewise.
36027         * lib/string_.h [__DECC]: Likewise.
36028         * lib/time_.h [__DECC]: Likewise.
36029         * lib/wchar_.h [__DECC]: Likewise.
36030         * lib/wctype_.h [__DECC]: Likewise.
36031
36032 2007-04-27  Bruno Haible  <bruno@clisp.org>
36033
36034         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
36035
36036 2007-04-27  Bruno Haible  <bruno@clisp.org>
36037
36038         * lib/fflush.c: Add comments.
36039         * modules/fpurge-tests (Depends-on): Add fflush.
36040         * modules/freadable-tests (Depends-on): Likewise.
36041         * modules/fwritable-tests (Depends-on): Likewise.
36042
36043 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
36044
36045         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
36046         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
36047         Report by Bruno Haible <bruno@clisp.org>.
36048
36049 2007-04-26  Eric Blake  <ebb9@byu.net>
36050
36051         Fix fflush on mingw.
36052         * modules/fflush (Depends-on): Add freading.
36053         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
36054         but unread data.
36055
36056 2007-04-26  Eric Blake  <ebb9@byu.net>
36057         and Bruno Haible  <bruno@clisp.org>
36058
36059         Implement freading and fwriting.
36060         * lib/freading.c: New file.
36061         * lib/freading.h: Likewise.
36062         * m4/freading.m4: Likewise.
36063         * modules/freading: Likewise.
36064         * modules/freading-tests: Likewise.
36065         * tests/test-freading.c: Likewise.
36066         * lib/fwriting.c: New file.
36067         * lib/fwriting.h: Likewise.
36068         * m4/fwriting.m4: Likewise.
36069         * modules/fwriting: Likewise.
36070         * modules/fwriting-tests: Likewise.
36071         * tests/test-fwriting.c: Likewise.
36072         * MODULES.html.sh (File stream based Input/Output): Mention them.
36073
36074 2007-04-26  Bruno Haible  <bruno@clisp.org>
36075
36076         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
36077         'long' when we assume it.
36078         Suggested by Eric Blake.
36079
36080 2007-04-26  Bruno Haible  <bruno@clisp.org>
36081
36082         Ensure fseeko, ftello are declared on glibc systems.
36083         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
36084         * modules/fseeko (configure.ac-early): Likewise.
36085         * modules/ftello (configure.ac-early): Likewise.
36086         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
36087         AC_FUNC_FSEEKO for this.
36088         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
36089         (gl_CHECK_FSEEKO): Remove macro.
36090
36091 2007-04-26  Bruno Haible  <bruno@clisp.org>
36092
36093         * tests/test-fflush.c (main): Also check the ftell result after
36094         fflush and fseek/fseeko.
36095         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
36096         file descriptor position cache in the stream.
36097         * lib/fseeko.c (rpl_fseeko): Likewise.
36098
36099 2007-04-26  Bruno Haible  <bruno@clisp.org>
36100
36101         * modules/fflush-tests (Depends-on): Add fseeko.
36102
36103 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
36104             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
36105
36106         * lib/argz_.h: ensure error_t definition is obtained in same
36107         mechanism system argz.h would have.
36108         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
36109         argz facilities are known bad.  Err on the side of caution if
36110         cross-compiling.
36111
36112 2007-04-25  Eric Blake  <ebb9@byu.net>
36113
36114         * lib/fpurge.c (includes): Use stdlib.h for free.
36115         * tests/test-fflush.c (main): Also test fflush-fseeko.
36116
36117 2007-04-25  Bruno Haible  <bruno@clisp.org>
36118
36119         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
36120         * lib/fseeko.c: New file.
36121         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
36122         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
36123         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
36124         gl_FUNC_FSEEKO.
36125         (gl_FUNC_FSEEKO): Invoke it.
36126         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
36127         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
36128         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
36129
36130 2007-04-25  Bruno Haible  <bruno@clisp.org>
36131
36132         * modules/fflush (Depends-on): Add ftello.
36133
36134 2007-04-25  Bruno Haible  <bruno@clisp.org>
36135
36136         * modules/ftello-tests: New file.
36137         * tests/test-ftello.c: New file.
36138
36139         * modules/ftello: New file.
36140         * m4/ftello.m4: New file.
36141         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
36142         HAVE_FTELLO.
36143         * lib/stdio_.h (ftello): New declaration.
36144         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
36145         HAVE_FTELLO.
36146
36147 2007-04-25  Bruno Haible  <bruno@clisp.org>
36148
36149         * modules/fseeko-tests: New file.
36150         * tests/test-fseeko.c: New file.
36151
36152         * modules/fseeko: New file.
36153         * m4/fseeko.m4: New file.
36154         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
36155         HAVE_FSEEKO.
36156         * lib/stdio_.h (fseeko): New declaration.
36157         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
36158         HAVE_FSEEKO.
36159
36160 2007-04-25  Bruno Haible  <bruno@clisp.org>
36161
36162         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
36163
36164 2007-04-25  Bruno Haible  <bruno@clisp.org>
36165
36166         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
36167         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
36168         * tests/test-unistd.c: Likewise.
36169         * tests/test-fcntl.c: Likewise.
36170
36171 2007-04-23  Eric Blake  <ebb9@byu.net>
36172
36173         * lib/fflush.c: Fix missing include.
36174         Reported by Bruno Haible.
36175
36176 2007-04-23  Bruno Haible  <bruno@clisp.org>
36177
36178         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
36179         Reported by Eric Blake.
36180
36181 2007-04-23  Bruno Haible  <bruno@clisp.org>
36182
36183         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
36184
36185 2007-04-23  Bruno Haible  <bruno@clisp.org>
36186
36187         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
36188
36189 2007-04-23  Bruno Haible  <bruno@clisp.org>
36190
36191         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
36192         Needed on HP-UX 11.
36193
36194 2007-04-16  Eric Blake  <ebb9@byu.net>
36195
36196         Make fflush rely on fpurge.
36197         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
36198         open coding all variants.
36199         * modules/fflush (Depends-on): Add fpurge and unistd.
36200         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
36201         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
36202
36203         Fix --with-tests compilation on cygwin.
36204         * modules/argmatch-tests (Makefile.am): List gnulib library first
36205         in LDADD.
36206         * modules/argp-tests (Makefile.am): Likewise.
36207         * modules/array-list-tests (Makefile.am): Likewise.
36208         * modules/array-oset-tests (Makefile.am): Likewise.
36209         * modules/avltree-list-tests (Makefile.am): Likewise.
36210         * modules/avltree-oset-tests (Makefile.am): Likewise.
36211         * modules/avltreehash-list-tests (Makefile.am): Likewise.
36212         * modules/carray-list-tests (Makefile.am): Likewise.
36213         * modules/dirname-tests (Makefile.am): Likewise.
36214         * modules/frexp-tests (Makefile.am): Likewise.
36215         * modules/isnanl-tests (Makefile.am): Likewise.
36216         * modules/linked-list-tests (Makefile.am): Likewise.
36217         * modules/linkedhash-list-tests (Makefile.am): Likewise.
36218         * modules/lock-tests (Makefile.am): Likewise.
36219         * modules/rbtree-list-tests (Makefile.am): Likewise.
36220         * modules/rbtree-oset-tests (Makefile.am): Likewise.
36221         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
36222         * modules/tls-tests (Makefile.am): Likewise.
36223         * modules/tsearch-tests (Makefile.am): Likewise.
36224         * modules/xvasprintf-tests (Makefile.am): Likewise.
36225
36226         Fix fpurge for cygwin.
36227         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
36228         value.
36229         * modules/fpurge-tests (Depends-on): Clean up trash.
36230
36231 2007-04-16  Simon Josefsson  <simon@josefsson.org>
36232
36233         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
36234
36235         * m4/autobuild.m4: Re-indent.
36236
36237 2007-04-13  Bruno Haible  <bruno@clisp.org>
36238
36239         * modules/fpurge-tests: New file.
36240         * tests/test-fpurge.c: New file.
36241
36242         * modules/fpurge: New file.
36243         * lib/fpurge.h: New file.
36244         * lib/fpurge.c: New file.
36245         * m4/fpurge.m4: New file.
36246
36247 2007-04-13  Bruno Haible  <bruno@clisp.org>
36248
36249         * modules/fbufmode-tests: New file.
36250         * tests/test-fbufmode.c: New file.
36251
36252         * modules/fbufmode: New file.
36253         * lib/fbufmode.h: New file.
36254         * lib/fbufmode.c: New file.
36255         * m4/fbufmode.m4: New file.
36256
36257 2007-04-13  Bruno Haible  <bruno@clisp.org>
36258
36259         * modules/fwritable-tests: New file.
36260         * tests/test-fwritable.c: New file.
36261
36262         * modules/fwritable: New file.
36263         * lib/fwritable.h: New file.
36264         * lib/fwritable.c: New file.
36265         * m4/fwritable.m4: New file.
36266
36267 2007-04-13  Bruno Haible  <bruno@clisp.org>
36268
36269         * modules/freadable-tests: New file.
36270         * tests/test-freadable.c: New file.
36271
36272         * modules/freadable: New file.
36273         * lib/freadable.h: New file.
36274         * lib/freadable.c: New file.
36275         * m4/freadable.m4: New file.
36276
36277 2007-04-13  Bruno Haible  <bruno@clisp.org>
36278
36279         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
36280         MOSTLYCLEANFILES.
36281
36282 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
36283
36284         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
36285         gzip bootstrap.conf to avoid dragging in i18n machinery.
36286         (gnulib_tool_option): Use it.
36287
36288 2007-04-13  Bruno Haible  <bruno@clisp.org>
36289
36290         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
36291         %F directives.
36292         * tests/test-vasprintf-posix.c (test_function): Likewise.
36293         * tests/test-snprintf-posix.h (test_function): Likewise.
36294         * tests/test-sprintf-posix.h (test_function): Likewise.
36295         * tests/test-fprintf-posix.h (test_function): Likewise.
36296         * tests/test-printf-posix.h (test_function): Likewise.
36297         * tests/test-fprintf-posix.out: Likewise.
36298
36299 2007-04-13  Bruno Haible  <bruno@clisp.org>
36300
36301         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
36302         * modules/tls-tests (configure.ac): Likewise.
36303         Reported by Arto C. Nirkko <anirkko@insel.ch>.
36304
36305 2007-04-13  Bruno Haible  <bruno@clisp.org>
36306
36307         * lib/tls.c (glthread_tls_get): Fix return type.
36308         Patch by Arto C. Nirkko <anirkko@insel.ch>.
36309
36310 2007-04-12  Eric Blake  <ebb9@byu.net>
36311
36312         * modules/gettime (Depends-on): Remove gettime.
36313         Reported by Dmitry V. Levin.
36314
36315 2007-04-12  Bruno Haible  <bruno@clisp.org>
36316
36317         * modules/fflush (Include): Mention <stdio.h>.
36318         * modules/strtoimax (Include): Mention <inttypes.h>.
36319         * modules/strtoumax (Include): Likewise.
36320
36321 2007-04-12  Eric Blake  <ebb9@byu.net>
36322
36323         * .cvsignore: New file.
36324         * .gitignore: Likewise.
36325
36326 2007-04-12  Bruno Haible  <bruno@clisp.org>
36327
36328         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
36329         not before, since $(LDADD) often contains libgnu.a.
36330         * modules/striconv-tests (test_striconv_LDADD): Likewise.
36331         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
36332         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
36333         Needed on Cygwin.
36334
36335 2007-04-12  Eric Blake  <ebb9@byu.net>
36336
36337         Work around glibc's failure to flush stdin on fclose.
36338         * lib/closein.c (close_stdin): Flush stdin before closing.
36339
36340         Work around glibc's failure to reset seekable stdin on exit.
36341         * modules/closein: New module.
36342         * lib/closein.c: New file.
36343         * lib/closein.h: Likewise.
36344         * m4/closein.m4: Likewise.
36345         * MODULES.html.sh (File stream based Input/Output): Document it.
36346
36347 2007-04-12  Simon Josefsson  <simon@josefsson.org>
36348
36349         * gnulib-tool: Rename generated 'autobuild' script to
36350         'do-autobuild' in --create-megatestdir output.
36351
36352         * doc/gnulib.texi (Build robot for gnulib): Fix.
36353
36354 2007-04-12  Simon Josefsson  <simon@josefsson.org>
36355
36356         * modules/sysexits (Depends-on): Add absolute-header.
36357
36358 2007-04-12  Eric Blake  <ebb9@byu.net>
36359
36360         No need to preserve errno on success.
36361         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
36362         Reported by Bruno Haible.
36363
36364 2007-04-12  Simon Josefsson  <simon@josefsson.org>
36365
36366         * MODULES.html.sh (Support for maintaining and releasing
36367         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
36368
36369 2007-04-12  Simon Josefsson  <simon@josefsson.org>
36370
36371         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
36372
36373 2007-04-12  Simon Josefsson  <simon@josefsson.org>
36374
36375         * modules/autobuild: New module.
36376
36377         * m4/autobuild.m4: New file.
36378
36379 2007-04-11  Bruno Haible  <bruno@clisp.org>
36380
36381         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
36382         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
36383         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
36384         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
36385         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
36386         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36387         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36388         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
36389         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36390         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36391         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
36392         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36393         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36394         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
36395         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36396         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36397         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
36398         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36399         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36400         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
36401         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36402         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36403         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
36404         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36405         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36406         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
36407         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
36408         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
36409         Reported by Eric Blake.
36410
36411 2007-04-11  Bruno Haible  <bruno@clisp.org>
36412
36413         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
36414
36415 2007-04-10  Bruno Haible  <bruno@clisp.org>
36416
36417         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
36418         for NaN and Infinity. Needed on FreeBSD 6.1.
36419         * tests/test-vasnprintf-posix.c (test_function): Undo last change
36420         regarding results for "%010a" of Infinity and NaN.
36421         * tests/test-vasprintf-posix.c (test_function): Likewise.
36422         * tests/test-snprintf-posix.h (test_function): Likewise.
36423         * tests/test-sprintf-posix.h (test_function): Likewise.
36424         * tests/test-fprintf-posix.h (test_function): Likewise.
36425         * tests/test-printf-posix.h (test_function): Likewise.
36426         * tests/test-fprintf-posix.out: Likewise.
36427
36428 2007-04-10  Bruno Haible  <bruno@clisp.org>
36429
36430         * modules/locale-tests: New file.
36431         * tests/test-locale.c: New file.
36432
36433         * modules/locale: New file.
36434         * lib/locale_.h: New file.
36435         * m4/locale_h.m4: New file.
36436
36437 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
36438             Bruno Haible  <bruno@clisp.org>
36439
36440         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
36441         be determined, test for availability of the copysignf, copysign,
36442         copysignl functions.
36443         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
36444         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
36445         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
36446
36447 2007-04-09  Eric Blake  <ebb9@byu.net>
36448
36449         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
36450         * modules/stdio (Makefile.am): Support fflush.
36451         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
36452         * modules/fflush: New file.
36453         * lib/fflush.c: Likewise.
36454         * m4/fflush.m4: Likewise.
36455         * modules/fflush-tests: New test.
36456         * tests/test-fflush.c: Likewise.
36457         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
36458
36459 2007-04-06  Bruno Haible  <bruno@clisp.org>
36460
36461         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
36462         (VASNPRINTF): Use signbit for faster determination whether to print a
36463         minus sign.
36464         * modules/vasnprintf (Files): Remove lib/float+.h.
36465         * modules/fprintf-posix (Depends-on): Add signbit.
36466         * modules/snprintf-posix (Depends-on): Likewise.
36467         * modules/sprintf-posix (Depends-on): Likewise.
36468         * modules/vasnprintf-posix (Depends-on): Likewise.
36469         * modules/vasprintf-posix (Depends-on): Likewise.
36470         * modules/vfprintf-posix (Depends-on): Likewise.
36471         * modules/vsnprintf-posix (Depends-on): Likewise.
36472         * modules/vsprintf-posix (Depends-on): Likewise.
36473
36474 2007-04-06  Bruno Haible  <bruno@clisp.org>
36475
36476         * tests/test-frexp.c (main): Test also the sign bit of zero results.
36477         * tests/test-frexpl.c (main): Likewise.
36478         * tests/test-ldexpl.c (main): Likewise.
36479         * modules/frexp-tests (Depends-on): Add signbit.
36480         * modules/frexpl-tests (Depdends-on): Likewise.
36481         * modules/ldexpl-tests (Depdends-on): Likewise.
36482
36483 2007-04-06  Bruno Haible  <bruno@clisp.org>
36484
36485         * modules/signbit-tests: New file.
36486         * tests/test-signbit.c: New file.
36487
36488         * modules/signbit: New file.
36489         * lib/signbitf.c: New file.
36490         * lib/signbitd.c: New file.
36491         * lib/signbitl.c: New file.
36492         * m4/signbit.m4: New file.
36493         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
36494         (signbit): New macro.
36495         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
36496         REPLACE_SIGNBIT.
36497         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
36498         REPLACE_FREXPL into math.h.
36499
36500 2007-04-06  Bruno Haible  <bruno@clisp.org>
36501
36502         * modules/isnanf-nolibm-tests: New file.
36503         * tests/test-isnanf.c: New file.
36504
36505         * modules/isnanf-nolibm: New file.
36506         * lib/isnanf.h: New file.
36507         * lib/isnanf.c: New file.
36508         * lib/isnan.c: Consider the USE_FLOAT macro.
36509         * m4/isnanf.m4: New file.
36510
36511 2007-04-06  Bruno Haible  <bruno@clisp.org>
36512
36513         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
36514         (Link): New section.
36515
36516         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
36517
36518 2007-04-06  Bruno Haible  <bruno@clisp.org>
36519
36520         Assume the 'long double' type.
36521         * m4/longdouble.m4: Remove file.
36522         * config/srclist.txt: Don't mention longdouble.m4.
36523         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
36524         * lib/float+.h: Likewise.
36525         * lib/frexp.c: Likewise.
36526         * lib/printf-args.h: Likewise.
36527         * lib/printf-args.c: Likewise.
36528         * lib/printf-frexp.c: Likewise.
36529         * lib/printf-parse.c: Likewise.
36530         * lib/vasnprintf.c: Likewise.
36531         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
36532         * m4/intl.m4: Likewise.
36533         * m4/isnanl.m4: Likewise.
36534         * m4/printf.m4: Likewise.
36535         * m4/printf-frexpl.m4: Likewise.
36536         * m4/vasnprintf.m4: Likewise.
36537         * modules/allocsa (Files): Remove m4/longdouble.m4.
36538         * modules/gettext (Files): Likewise.
36539         * modules/relocatable-prog-wrapper (Files): Likewise.
36540         * modules/vasnprintf (Files): Likewise.
36541         * modules/isnanl (Files): Likewise.
36542         (Include): Simplify.
36543         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
36544         (Include): Simplify.
36545         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
36546         (Include): Simplify.
36547         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
36548         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36549         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
36550         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36551         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
36552         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36553         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
36554         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36555         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
36556         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36557         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
36558         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
36559         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
36560         * tests/test-isnanl.c: Likewise.
36561         * tests/test-snprintf-posix.h: Likewise.
36562         * tests/test-sprintf-posix.h: Likewise.
36563         * tests/test-vasnprintf-posix.c: Likewise.
36564         * tests/test-vasnprintf-posix2.c: Likewise.
36565         * tests/test-vasprintf-posix.c: Likewise.
36566
36567 2007-04-06  Bruno Haible  <bruno@clisp.org>
36568
36569         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
36570         * lib/math_.h [__DECC]: Include the overridden include file through
36571         #include_next, outside the double-inclusion guard.
36572         * lib/stdio_.h [__DECC]: Likewise.
36573         * lib/stdlib_.h [__DECC]: Likewise.
36574         * lib/string_.h [__DECC]: Likewise.
36575         * lib/time_.h [__DECC]: Likewise.
36576         * lib/wchar_.h [__DECC]: Likewise.
36577         * lib/wctype_.h [__DECC]: Likewise.
36578         * lib/inttypes_.h [__DECC]: Likewise.
36579         Reported by Albert Chin <china@thewrittenword.com> in
36580         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
36581
36582 2007-04-04  Eric Blake  <ebb9@byu.net>
36583
36584         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
36585         1.5.x.
36586
36587 2007-04-04  Bruno Haible  <bruno@clisp.org>
36588
36589         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
36590         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
36591
36592 2007-04-04  Bruno Haible  <bruno@clisp.org>
36593
36594         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
36595         results for "%010a" of Infinity and NaN.
36596         * tests/test-vasprintf-posix.c (test_function): Likewise.
36597         * tests/test-snprintf-posix.h (test_function): Likewise.
36598         * tests/test-sprintf-posix.h (test_function): Likewise.
36599         * tests/test-fprintf-posix.h (test_function): Remove these tests.
36600         * tests/test-printf-posix.h (test_function): Likewise.
36601         * tests/test-fprintf-posix.out: Update.
36602         Needed for FreeBSD 6.1.
36603
36604 2007-04-04  Bruno Haible  <bruno@clisp.org>
36605
36606         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
36607         directly used by the gnulib modules nor by gnulib-tool.
36608
36609 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
36610
36611         * DEPENDENCIES: Give overall description of version dependency
36612         desirability.  Use more-typical names for apps.
36613         Add shell, coreutils, diffutils, grep, tar, gzip.
36614
36615 2007-04-04  Simon Josefsson  <simon@josefsson.org>
36616
36617         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
36618
36619 2007-04-04  Karl Berry  <karl@gnu.org>
36620
36621         * MODULES.html.sh (func_module): missing '.
36622
36623 2007-04-03  Bruno Haible  <bruno@clisp.org>
36624
36625         * modules/argmatch-tests (Makefile.am): New variable
36626         test_argmatch_LDADD.
36627         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
36628         * modules/array-list-tests (Makefile.am): New variable
36629         test_array_list_LDADD.
36630         * modules/array-oset-tests (Makefile.am): New variable
36631         test_array_oset_LDADD.
36632         * modules/avltree-list-tests (Makefile.am): New variable
36633         test_avltree_list_LDADD.
36634         * modules/avltree-oset-tests (Makefile.am): New variable
36635         test_avltree_oset_LDADD.
36636         * modules/avltreehash-list-tests (Makefile.am): New variable
36637         test_avltreehash_list_LDADD.
36638         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
36639         test_canonicalize_lgpl_LDADD.
36640         * modules/carray-list-tests (Makefile.am): New variable
36641         test_carray_list_LDADD.
36642         * modules/dirname-tests (Makefile.am): New variable
36643         test_dirname_LDADD.
36644         * modules/linked-list-tests (Makefile.am): New variable
36645         test_linked_list_LDADD.
36646         * modules/linkedhash-list-tests (Makefile.am): New variable
36647         test_linkedhash_list_LDADD.
36648         * modules/rbtree-list-tests (Makefile.am): New variable
36649         test_rbtree_list_LDADD.
36650         * modules/rbtree-oset-tests (Makefile.am): New variable
36651         test_rbtree_oset_LDADD.
36652         * modules/rbtreehash-list-tests (Makefile.am): New variable
36653         test_rbtreehash_list_LDADD.
36654         * modules/xvasprintf-tests (Makefile.am): New variable
36655         test_xvasprintf_LDADD.
36656         Reported by Eric Blake.
36657
36658 2007-04-03  Eric Blake  <ebb9@byu.net>
36659
36660         * DEPENDENCIES: Weaken m4 requirements.
36661
36662 2007-04-03  Bruno Haible  <bruno@clisp.org>
36663
36664         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
36665         * modules/isnanl-tests (configure.ac): Likewise.
36666
36667 2007-04-03  Ben Pfaff  <blp@gnu.org>
36668
36669         * modules/iconv_open: Add $(srcdir)/ to source directory
36670         references in Makefile fragments that call gperf, to fix VPATH
36671         builds.
36672
36673 2007-04-03  Bruno Haible  <bruno@clisp.org>
36674
36675         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
36676         * lib/ldexpl.c: Undo last change.
36677
36678 2007-04-03  Bruno Haible  <bruno@clisp.org>
36679
36680         * modules/printf-frexpl (Depends-on): Undo last change.
36681         (Files): Add m4/ldexpl.m4.
36682
36683 2007-04-03  Bruno Haible  <bruno@clisp.org>
36684
36685         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
36686         * modules/isnanl (Link): New section.
36687
36688         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
36689         * modules/frexp (Link): New section.
36690
36691         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
36692         * modules/frexpl (Link): New section.
36693
36694         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
36695         * modules/ldexpl (Link): New section.
36696
36697 2007-04-03  Bruno Haible  <bruno@clisp.org>
36698
36699         * modules/TEMPLATE-EXTENDED: New file.
36700         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
36701
36702 2007-04-03  Bruno Haible  <bruno@clisp.org>
36703
36704         * DEPENDENCIES: New file.
36705         Suggested by Simon Josefsson.
36706
36707 2007-04-03  Bruno Haible  <bruno@clisp.org>
36708
36709         * doc/gnulib.texi: Escape @.
36710
36711 2007-04-03  James Youngman  <jay@gnu.org>
36712         and Paul Eggert  <eggert@cs.ucla.edu>
36713
36714         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
36715         birthtime on all systems that have birthtime, not just those which
36716         use st_birthtimensec rather than st_birthtim.  Putting zero in
36717         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
36718         that the birth time is not available for files on an NFS mount.
36719
36720 2007-04-03  Simon Josefsson  <simon@josefsson.org>
36721
36722         * modules/memxor: Move back from crypto/, suggested by Bruno.
36723         * modules/crypto/hmac-sha1: Fix memxor dependency.
36724
36725         * modules/crypto/gc: Moved from ../.
36726
36727 2007-04-02  Eric Blake  <ebb9@byu.net>
36728
36729         * lib/ldexpl.c (includes): Avoid libm.
36730
36731         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
36732
36733 2007-04-02  Bruno Haible  <bruno@clisp.org>
36734
36735         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
36736         on IRIX.
36737
36738 2007-04-02  Bruno Haible  <bruno@clisp.org>
36739
36740         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
36741         x86 or x86_64 platforms running MacOS X.
36742         Reported by Ryan Schmidt <@ryandesign.com>.
36743
36744 2007-04-02  Bruno Haible  <bruno@clisp.org>
36745
36746         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
36747         i386.
36748
36749 2007-04-01  Simon Josefsson  <simon@josefsson.org>
36750
36751         * modules/crypto/arcfour: Moved from ../.
36752         * modules/crypto/arcfour-tests: Moved from ../.
36753         * modules/crypto/arctwo: Moved from ../.
36754         * modules/crypto/arctwo-tests: Moved from ../.
36755         * modules/crypto/des: Moved from ../.
36756         * modules/crypto/des-tests: Moved from ../.
36757         * modules/crypto/gc-arcfour: Moved from ../.
36758         * modules/crypto/gc-arcfour-tests: Moved from ../.
36759         * modules/crypto/gc-arctwo: Moved from ../.
36760         * modules/crypto/gc-arctwo-tests: Moved from ../.
36761         * modules/crypto/gc-des: Moved from ../.
36762         * modules/crypto/gc-des-tests: Moved from ../.
36763         * modules/crypto/gc-hmac-md5: Moved from ../.
36764         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
36765         * modules/crypto/gc-hmac-sha1: Moved from ../.
36766         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
36767         * modules/crypto/gc-md2: Moved from ../.
36768         * modules/crypto/gc-md2-tests: Moved from ../.
36769         * modules/crypto/gc-md4: Moved from ../.
36770         * modules/crypto/gc-md4-tests: Moved from ../.
36771         * modules/crypto/gc-md5: Moved from ../.
36772         * modules/crypto/gc-md5-tests: Moved from ../.
36773         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
36774         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
36775         * modules/crypto/gc-random: Moved from ../.
36776         * modules/crypto/gc-rijndael: Moved from ../.
36777         * modules/crypto/gc-rijndael-tests: Moved from ../.
36778         * modules/crypto/gc-sha1: Moved from ../.
36779         * modules/crypto/gc-sha1-tests: Moved from ../.
36780         * modules/crypto/gc-tests: Moved from ../.
36781         * modules/crypto/hmac-md5: Moved from ../.
36782         * modules/crypto/hmac-md5-tests: Moved from ../.
36783         * modules/crypto/hmac-sha1: Moved from ../.
36784         * modules/crypto/hmac-sha1-tests: Moved from ../.
36785         * modules/crypto/md2: Moved from ../.
36786         * modules/crypto/md2-tests: Moved from ../.
36787         * modules/crypto/md4: Moved from ../.
36788         * modules/crypto/md4-tests: Moved from ../.
36789         * modules/crypto/md5: Moved from ../.
36790         * modules/crypto/md5-tests: Moved from ../.
36791         * modules/crypto/memxor: Moved from ../.
36792         * modules/crypto/rijndael: Moved from ../.
36793         * modules/crypto/rijndael-tests: Moved from ../.
36794         * modules/crypto/sha1: Moved from ../.
36795
36796 2007-03-30  James Youngman  <jay@gnu.org>
36797
36798         * tests/test-stat-time.c (prepare_test): use chmod() rather than
36799         rename() to change the ctime of a file (because ctime is unaffected
36800         by rename on jfs2 on AIX 5.1).
36801         (main): Start by doing cleanup, in case a previous run failed leaving
36802         test files behind.
36803
36804 2007-03-31  Bruno Haible  <bruno@clisp.org>
36805
36806         Support old proprietary implementations of iconv.
36807         * modules/iconv_open: New file.
36808         * lib/iconv_.h: New file.
36809         * m4/iconv_h.m4: New file.
36810         * lib/iconv_open.c: New file.
36811         * lib/iconv_open-aix.gperf: New file.
36812         * lib/iconv_open-hpux.gperf: New file.
36813         * lib/iconv_open-irix.gperf: New file.
36814         * lib/iconv_open-osf.gperf: New file.
36815         * m4/iconv_open.m4: New file.
36816         * modules/linebreak (Depends-on): Add iconv_open.
36817         * modules/striconv (Depends-on): Likewise.
36818         * modules/striconveh (Depends-on): Likewise.
36819         * modules/unicodeio (Depends-on): Likewise.
36820         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
36821         (iconv_t)(-1).
36822         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
36823         conversion if cd is (iconv_t)(-1).
36824         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
36825         is not possible.
36826
36827 2007-03-31  Bruno Haible  <bruno@clisp.org>
36828
36829         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
36830         work on Solaris either. Protect also second use of "autodetect_jp".
36831
36832 2007-03-31  Bruno Haible  <bruno@clisp.org>
36833
36834         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
36835         the function is not present.
36836
36837 2007-03-31  Bruno Haible  <bruno@clisp.org>
36838
36839         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
36840         the function is not present.
36841
36842 2007-03-31  Bruno Haible  <bruno@clisp.org>
36843
36844         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
36845         a bug in HP-UX iconv_open().
36846
36847 2007-03-31  Bruno Haible  <bruno@clisp.org>
36848
36849         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
36850         (Mathematics <math.h>): New section, add fpieee.
36851         (Input/output <stdio.h>): Add fseterr.
36852         (Mathematics <math.h>): New section, add printf-frexp.
36853         (Container data structures): Add sublist.
36854         (Core language properties): Add fpucw, inline.
36855         (Functions for greatest-width integer types <inttypes.h>): Add
36856         imaxabs, imaxdiv, inttypes.
36857         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
36858         isnanl-nolibm, ldexp.
36859         (Mathematics <math.h>): New section, add printf-frexpl.
36860         (Support for systems lacking POSIX:2001): Add fprintf-posix,
36861         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
36862         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
36863         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
36864         (Unicode string functions): Add unistr/u*-mbtoucr.
36865         (Java): Add javacomp-script, javaexec-script.
36866         (C#): Add csharpcomp-script, csharpexec-script.
36867         (Support for building libraries and executables): Add havelib,
36868         relocatable-*.
36869         (Support for maintaining and releasing projects): Renamed from
36870         'Support for maintaining and release projects'. Add announce-gen.
36871
36872 2007-03-31  Bruno Haible  <bruno@clisp.org>
36873
36874         * README: Talk primarily about git.
36875         (git and CVS): Renamed from CVS.
36876         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
36877         gnulib is available through git.
36878         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
36879
36880 2007-03-30  Bruno Haible  <bruno@clisp.org>
36881
36882         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
36883         * lib/poll_.h: Likewise.
36884         * lib/stat_.h: Likewise.
36885         * lib/sys_time_.h: Likewise.
36886         * lib/sysexit_.h: Likewise.
36887         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
36888         * lib/stdbool_.h: Likewise.
36889         * lib/byteswap_.h: Add double-inclusion guard.
36890
36891 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
36892
36893         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
36894
36895 2007-03-30  Karl Berry  <karl@gnu.org>
36896
36897         * config/srclist-update: double space after USA in the license
36898         substitution, since that's how it's usually (?) written.
36899
36900 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
36901
36902         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
36903         reported by Bruno Haible.
36904
36905 2007-03-29  Bruno Haible  <bruno@clisp.org>
36906
36907         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
36908         a bug in AIX iconv().
36909
36910 2007-03-29  Bruno Haible  <bruno@clisp.org>
36911
36912         * modules/ldexpl-tests: New file.
36913         * tests/test-ldexpl.c: New file.
36914
36915 2007-03-29  Bruno Haible  <bruno@clisp.org>
36916
36917         * lib/ldexpl.c: Include fpucw.h.
36918         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
36919         multiplication.
36920         * modules/ldexpl (Depends-on): Add fpucw.
36921
36922 2007-03-29  Bruno Haible  <bruno@clisp.org>
36923
36924         * modules/ldexpl: New file.
36925         * m4/ldexpl.m4: New file.
36926         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
36927         set.
36928         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
36929         REPLACE_LDEXPL.
36930         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
36931         REPLACE_LDEXPL.
36932         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
36933         gl_FUNC_LDEXPL_WORKS.
36934         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
36935         * modules/mathl (Files): Remove lib/ldexpl.c.
36936         (Depends-on): Add ldexpl.
36937
36938 2007-03-29  Bruno Haible  <bruno@clisp.org>
36939
36940         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
36941
36942 2007-03-29  Bruno Haible  <bruno@clisp.org>
36943
36944         * tests/test-striconveh.c (main): Don't assume that a direct conversion
36945         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
36946         and possibly also HP-UX.
36947         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
36948         work on AIX, IRIX, HP-UX, OSF/1.
36949         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
36950         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
36951         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
36952         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
36953         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
36954         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
36955
36956 2007-03-29  Bruno Haible  <bruno@clisp.org>
36957
36958         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
36959
36960 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
36961
36962         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
36963         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
36964
36965 2007-03-29  Eric Blake  <ebb9@byu.net>
36966
36967         * lib/acl-internal.h: Remove redundant include.
36968         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
36969         Cygwin when a file is locked.
36970
36971 2007-03-29  Bruno Haible  <bruno@clisp.org>
36972
36973         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
36974         file.
36975         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
36976
36977 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
36978
36979         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
36980         try to remove a parent directory if the child couldn't be removed
36981         (except for the first rmdir, which could fail because the child
36982         doesn't exist).  Problem reported by Jeff Blaine in
36983         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
36984
36985 2007-03-28  Bruno Haible  <bruno@clisp.org>
36986
36987         * lib/striconveh.c (utf8conv_carefully): New function.
36988         (mem_cd_iconveh_internal): Invoke it.
36989
36990 2007-03-28  Bruno Haible  <bruno@clisp.org>
36991
36992         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
36993         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
36994         input.
36995         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
36996         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
36997         unistr/u8-uctomb.
36998
36999 2007-03-28  Bruno Haible  <bruno@clisp.org>
37000
37001         * modules/unistr/u8-mbtoucr: New file.
37002         * lib/unistr/u8-mbtoucr.c: New file.
37003         * modules/unistr/u16-mbtoucr: New file.
37004         * lib/unistr/u16-mbtoucr.c: New file.
37005         * modules/unistr/u16-mbtoucr: New file.
37006         * lib/unistr/u16-mbtoucr.c: New file.
37007         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
37008
37009 2007-03-27  Simon Josefsson  <simon@josefsson.org>
37010             Bruno Haible  <bruno@clisp.org>
37011
37012         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
37013         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
37014         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
37015
37016         * m4/stdio_h.m4: Add stubs for vasprintf too.
37017
37018         * modules/stdio: Support vasprintf in sed command.
37019
37020         * modules/vasprintf: Depend on stdio for prototypes.  Remove
37021         vasprintf.h.  Add stdio module indicator.
37022
37023         * lib/stdio_.h: Declare asprintf and vasprintf, based on
37024         vasprintf.h.
37025
37026         * lib/vasprintf.h: File removed.
37027
37028         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
37029         * lib/vasprintf.c: Ditto.
37030         * lib/xvasprintf.c: Ditto.
37031         * tests/test-vasprintf-posix.c: Ditto.
37032         * tests/test-vasprintf.c: Ditto.
37033
37034 2007-03-27  Bruno Haible  <bruno@clisp.org>
37035
37036         Make vasnprintf multithread-safe.
37037         * lib/vasnprintf.c (decimal_point_char): New function.
37038         (VASNPRINTF): Use it.
37039         Suggested by Simon Josefsson.
37040
37041 2007-03-27  Eric Blake  <ebb9@byu.net>
37042
37043         Support sub-second birthtime on cygwin.
37044         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
37045         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
37046         (get_stat_birthtime): Also work with st_birthtim.
37047
37048 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
37049
37050         * lib/stat-time.h (USE_BIRTHTIME): Remove.
37051         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
37052         (get_stat_birthtime_ns): Do not try to use "spare" fields.
37053         (get_stat_birthtime_ns): Simplify compile-time tests.
37054         (get_stat_birthtime): Change the API to look like
37055         get_stat_mtime etc., except return a negative tv_nsec on error.
37056         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
37057         Don't check for "spare" fields.
37058         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
37059         or for struct stat.st_birthtime, as these tests aren't used.
37060         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
37061
37062 2007-03-27  Bruno Haible  <bruno@clisp.org>
37063
37064         * lib/stat-time.h: Include <sys/stat.h>.
37065
37066 2007-03-27  James Youngman  <jay@gnu.org>
37067
37068         * lib/stat-time.h (get_stat_birthtime): New function for
37069           retrieving st_birthtime as provided by UFS2 (hence *BSD).
37070         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
37071           and its variants.
37072         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
37073         * modules/stat-time-test: New file.
37074         * tests/test-stat-time.c: New test, devised by Bruno Haible.
37075
37076 2007-03-26  Bruno Haible  <bruno@clisp.org>
37077
37078         Better support of signalling NaNs.
37079         * lib/atanl.c: Include isnanl.h.
37080         (atanl): Perform test for NaN at the beginning of the function and
37081         through a call to isnanl.
37082         * lib/cosl.c: Include isnanl.h.
37083         (cosl): Perform test for NaN at the beginning of the function and
37084         through a call to isnanl.
37085         * lib/ldexpl.c: Include isnanl.h.
37086         (ldexpl): Perform test for NaN through a call to isnanl.
37087         * lib/logl.c: Include isnanl.h.
37088         (logl): Perform test for NaN at the beginning of the function and
37089         through a call to isnanl.
37090         * lib/sinl.c: Include isnanl.h.
37091         (sinl): Perform test for NaN at the beginning of the function and
37092         through a call to isnanl.
37093         * lib/sqrtl.c: Include isnanl.h.
37094         (sqrtl): Perform test for NaN at the beginning of the function and
37095         through a call to isnanl.
37096         * lib/tanl.c: Include isnanl.h.
37097         (tanl): Perform test for NaN at the beginning of the function and
37098         through a call to isnanl.
37099         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
37100         * modules/mathl (Depends-on): Add isnanl.
37101
37102 2007-03-26  Eric Blake  <ebb9@byu.net>
37103
37104         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
37105         regression in logic sense of previous patch.
37106
37107 2007-03-26  Bruno Haible  <bruno@clisp.org>
37108
37109         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
37110         unportable shell command "if ! ...".
37111         Reported by Ralf Wildenhues.
37112
37113 2007-03-25  Bruno Haible  <bruno@clisp.org>
37114
37115         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
37116         <sysexits.h> file, and only add EX_CONFIG.
37117         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
37118         absolute file name and whether it is sufficient. Substitute also
37119         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
37120         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
37121         ABSOLUTE_SYSEXITS_H into sysexits.h.
37122
37123 2007-03-25  Bruno Haible  <bruno@clisp.org>
37124
37125         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
37126         hints is NULL.
37127
37128 2007-03-25  Bruno Haible  <bruno@clisp.org>
37129
37130         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
37131         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
37132
37133 2007-03-25  Bruno Haible  <bruno@clisp.org>
37134
37135         * lib/vasnprintf.c: Include langinfo.h.
37136         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
37137         multithread-safe.
37138         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
37139         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
37140         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
37141         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
37142         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
37143         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
37144         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
37145         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
37146         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
37147         Reported by Simon Josefsson.
37148
37149 2007-03-25  Bruno Haible  <bruno@clisp.org>
37150
37151         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
37152         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
37153         * modules/vasnprintf (Depends-on): Add stdint.
37154
37155 2007-03-25  Bruno Haible  <bruno@clisp.org>
37156
37157         * modules/fpieee: New file.
37158         * m4/fpieee.m4: New file.
37159         * modules/isnan-nolibm (Depends-on): Add fpieee.
37160         * modules/isnanl-nolibm (Depends-on): Add fpieee.
37161         * modules/isnanl (Depends-on): Add fpieee.
37162
37163 2007-03-25  Bruno Haible  <bruno@clisp.org>
37164
37165         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
37166
37167 2007-03-25  Bruno Haible  <bruno@clisp.org>
37168
37169         Avoid test failures on IRIX 6.5.
37170         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
37171         (main): Use it.
37172         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
37173         macros.
37174         (main): Use them.
37175
37176 2007-03-25  Bruno Haible  <bruno@clisp.org>
37177
37178         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
37179         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
37180         exists but doesn't work.
37181         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
37182         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
37183         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
37184         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
37185
37186 2007-03-25  Bruno Haible  <bruno@clisp.org>
37187
37188         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
37189         returns inf. Needed on IRIX 6.5.
37190
37191 2007-03-25  Bruno Haible  <bruno@clisp.org>
37192
37193         * tests/test-frexpl.c: Include isnanl-nolibm.h.
37194         (main): Use isnanl instead of x != x idiom.
37195         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
37196
37197         * tests/test-frexp.c: Include isnan.h.
37198         (main): Use isnan instead of x != x idiom.
37199         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
37200
37201 2007-03-25  Bruno Haible  <bruno@clisp.org>
37202
37203         * tests/test-frexp.c (NaN): New function/macro.
37204         (main): Use it instead of 0.0 / 0.0.
37205         * tests/test-isnan.c (NaN): New function/macro.
37206         (main): Use it instead of 0.0 / 0.0.
37207         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
37208         (test_function): Use it instead of 0.0 / 0.0.
37209         * tests/test-vasprintf-posix.c (NaN): New function/macro.
37210         (test_function): Use it instead of 0.0 / 0.0.
37211         * tests/test-snprintf-posix.h (NaN): New function/macro.
37212         (test_function): Use it instead of 0.0 / 0.0.
37213         * tests/test-sprintf-posix.h (NaN): New function/macro.
37214         (test_function): Use it instead of 0.0 / 0.0.
37215         * tests/test-fprintf-posix.h (NaN): New function/macro.
37216         (test_function): Use it instead of 0.0 / 0.0.
37217         * tests/test-printf-posix.h (NaN): New function/macro.
37218         (test_function): Use it instead of 0.0 / 0.0.
37219
37220         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
37221
37222 2007-03-25  Bruno Haible  <bruno@clisp.org>
37223
37224         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
37225
37226 2007-03-25  Bruno Haible  <bruno@clisp.org>
37227
37228         * lib/regexec.c (merge_state_with_log): Make static.
37229
37230 2007-03-25  Bruno Haible  <bruno@clisp.org>
37231
37232         * lib/trigl.c (kernel_rem_pio2): Make static.
37233
37234 2007-03-25  Bruno Haible  <bruno@clisp.org>
37235
37236         * lib/sincosl.c (sincosl_table): Make static.
37237
37238 2007-03-25  Bruno Haible  <bruno@clisp.org>
37239
37240         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
37241         if the compiler does not support C99.
37242
37243 2007-03-25  Bruno Haible  <bruno@clisp.org>
37244
37245         * modules/time (Makefile.am): Ensure all rule action lines start with a
37246         tab.
37247
37248 2007-03-24  Bruno Haible  <bruno@clisp.org>
37249
37250         * modules/tsearch-tests: New file.
37251         * tests/test-tsearch.sh: New file.
37252         * tests/test-tsearch.c: New file, mostly copied from glibc.
37253
37254         * modules/search-tests: New file.
37255         * tests/test-search.c: New file.
37256
37257         * modules/search: New file.
37258         * lib/search_.h: New file, incorporating lib/tsearch.h.
37259         * m4/search_h.m4: New file.
37260         * lib/tsearch.h: Remove file.
37261         * lib/tsearch.c: Include search.h instead of tsearch.h.
37262         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
37263         HAVE_TSEARCH.
37264         * modules/tsearch (Files): Remove lib/tsearch.h.
37265         (Depends-on): Add search.
37266         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
37267         (Include): Change tsearch.h into search.h.
37268
37269 2007-03-24  Bruno Haible  <bruno@clisp.org>
37270
37271         * modules/fpucw: New file.
37272         * lib/fpucw.h: New file.
37273         * lib/frexp.c: Include fpucw.h.
37274         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
37275         (FUNC): Use them.
37276         * lib/printf-frexp.c: Include fpucw.h.
37277         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
37278         (FUNC): Use them.
37279         * lib/vasnprintf.c: Include fpucw.h.
37280         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
37281         'long double' calculations.
37282         * tests/test-frexpl.c: Include fpucw.h.
37283         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
37284         * tests/test-printf-frexpl.c: Include fpucw.h.
37285         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
37286         * modules/frexpl (Depends-on): Add fpucw.
37287         * modules/printf-frexpl (Depends-on): Likewise.
37288         * modules/fprintf-posix (Depends-on): Likewise.
37289         * modules/snprintf-posix (Depends-on): Likewise.
37290         * modules/sprintf-posix (Depends-on): Likewise.
37291         * modules/vasnprintf-posix (Depends-on): Likewise.
37292         * modules/vasprintf-posix (Depends-on): Likewise.
37293         * modules/vfprintf-posix (Depends-on): Likewise.
37294         * modules/vsnprintf-posix (Depends-on): Likewise.
37295         * modules/vsprintf-posix (Depends-on): Likewise.
37296         * modules/frexpl-tests (Depends-on): Likewise.
37297         * modules/printf-frexpl-tests (Depends-on): Likewise.
37298
37299 2007-03-24  Bruno Haible  <bruno@clisp.org>
37300
37301         * lib/float+.h: New file.
37302         * lib/isnan.c: Include float+.h.
37303         (SIZE): New macro.
37304         (FUNC): Compare only SIZE bytes of the value.
37305         * lib/vasnprintf.c: Include float+.h.
37306         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
37307         SIZEOF_LDBL or SIZEOF_DBL bytes.
37308         * modules/isnan-nolibm (Files): Add lib/float+.h.
37309         * modules/isnanl-nolibm (Files): Add lib/float+.h.
37310         * modules/isnanl (Files): Add lib/float+.h.
37311         * modules/vasnprintf (Files): Add lib/float+.h.
37312
37313 2007-03-24  Bruno Haible  <bruno@clisp.org>
37314
37315         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
37316         include isnanl-nolibm.h.
37317
37318 2007-03-24  Bruno Haible  <bruno@clisp.org>
37319
37320         * tests/test-read-file.c (main): Don't produce spurious output for
37321         expected situations. Make the test fail if it encountered unexpected
37322         results.
37323
37324 2007-03-24  Bruno Haible  <bruno@clisp.org>
37325
37326         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
37327         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
37328
37329 2007-03-24  Bruno Haible  <bruno@clisp.org>
37330
37331         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
37332
37333 2007-03-24  Bruno Haible  <bruno@clisp.org>
37334
37335         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
37336         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
37337
37338         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
37339         * modules/utf8-ucs4: Turn into a symbolic link to module
37340         unistr/u8-mbtouc.
37341
37342         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
37343         utf8-ucs4-unsafe.
37344         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
37345         unistr/u8-mbtouc-unsafe.
37346
37347         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
37348         * modules/utf16-ucs4: Turn into a symbolic link to module
37349         unistr/u16-mbtouc.
37350
37351         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
37352         utf16-ucs4-unsafe.
37353         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
37354         unistr/u16-mbtouc-unsafe.
37355
37356         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
37357         * modules/ucs4-utf8: Turn into a symbolic link to module
37358         unistr/u8-ubtomb.
37359
37360         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
37361         * modules/ucs4-utf16: Turn into a symbolic link to module
37362         unistr/u16-ubtomb.
37363
37364 2007-03-24  Bruno Haible  <bruno@clisp.org>
37365
37366         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
37367         Enable the function only if HAVE_INLINE.
37368         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
37369         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
37370         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
37371         Enable the function only if HAVE_INLINE.
37372         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
37373         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
37374         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
37375         Enable the function only if HAVE_INLINE.
37376         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
37377         Enable the function only if HAVE_INLINE.
37378         * modules/utf8-ucs4: Update.
37379         * modules/utf8-ucs4-unsafe: Update.
37380         * modules/utf16-ucs4: Update.
37381         * modules/utf16-ucs4-unsafe: Update.
37382         * modules/ucs4-utf8: Update.
37383         * modules/ucs4-utf16: Update.
37384
37385 2007-03-24  Bruno Haible  <bruno@clisp.org>
37386
37387         * lib/utf8-ucs4.h: Remove file.
37388         * lib/utf8-ucs4-unsafe.h: Remove file.
37389         * lib/utf16-ucs4.h: Remove file.
37390         * lib/utf16-ucs4-unsafe.h: Remove file.
37391         * lib/ucs4-utf8.h: Remove file.
37392         * lib/ucs4-utf16.h: Remove file.
37393         * lib/unistr.h: Include their previous contents.
37394         * m4/utf-ucs4.m4: Remove file.
37395         * m4/ucs4-utf.m4: Remove file.
37396         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
37397         (Depends-on): Add unistr/base.
37398         (configure.ac): Remove gl_UTF_UCS4.
37399         (Makefile.am): Update.
37400         (Include): Change to unistr.h.
37401         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
37402         (Depends-on): Add unistr/base.
37403         (configure.ac): Remove gl_UTF_UCS4.
37404         (Makefile.am): Update.
37405         (Include): Change to unistr.h.
37406         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
37407         (Depends-on): Add unistr/base.
37408         (configure.ac): Remove gl_UTF_UCS4.
37409         (Makefile.am): Update.
37410         (Include): Change to unistr.h.
37411         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
37412         (Depends-on): Add unistr/base.
37413         (configure.ac): Remove gl_UTF_UCS4.
37414         (Makefile.am): Update.
37415         (Include): Change to unistr.h.
37416         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
37417         (Depends-on): Add unistr/base.
37418         (configure.ac): Remove gl_UCS4_UTF.
37419         (Makefile.am): Update.
37420         (Include): Change to unistr.h.
37421         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
37422         (Depends-on): Add unistr/base.
37423         (configure.ac): Remove gl_UCS4_UTF.
37424         (Makefile.am): Update.
37425         (Include): Change to unistr.h.
37426         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
37427         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
37428         utf8-ucs4-unsafe.h.
37429         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
37430         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
37431         utf16-ucs4-unsafe.h.
37432         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
37433         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
37434         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
37435         * lib/unistr/u8-strchr.c: Likewise.
37436         * lib/unistr/u8-strrchr.c: Likewise.
37437         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
37438         * lib/unistr/u16-strchr.c: Likewise.
37439         * lib/unistr/u16-strrchr.c: Likewise.
37440         * lib/striconveh.c: Update.
37441         * lib/linebreak.c: Update.
37442
37443 2007-03-24  Bruno Haible  <bruno@clisp.org>
37444
37445         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
37446         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
37447
37448 2007-03-22  Bruno Haible  <bruno@clisp.org>
37449
37450         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
37451
37452 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
37453
37454         * MODULES.html.sh (File system functions): New module write-any-file.
37455         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
37456         * m4/write-any-file.m4: New files.
37457
37458 2007-03-23  Eric Blake  <ebb9@byu.net>
37459
37460         * gnulib-tool: Rearrange space-tab sequences, since some editors
37461         like to eat them.
37462
37463 2007-03-23  Eric Blake  <ebb9@byu.net>
37464
37465         * lib/version-etc.c (version_etc_va): Update license wording to
37466         be more concise.  Recommended by Richard Stallman.
37467
37468 2007-03-22  Bruno Haible  <bruno@clisp.org>
37469
37470         * lib/poll.c (MSG_PEEK): New fallback definition.
37471
37472 2007-03-22  Bruno Haible  <bruno@clisp.org>
37473
37474         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
37475         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
37476         (main): Update.
37477         Fixes a compilation error on BeOS.
37478
37479 2007-03-22  Bruno Haible  <bruno@clisp.org>
37480
37481         * modules/frexpl-tests: New file.
37482         * tests/test-frexpl.c: New file.
37483
37484         * modules/frexpl: New file.
37485         * m4/frexpl.m4: New file.
37486         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
37487         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
37488         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
37489         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
37490         (Depends-on): Add frexpl. Remove isnanl-nolibm.
37491         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
37492
37493 2007-03-22  Bruno Haible  <bruno@clisp.org>
37494
37495         * lib/frexpl.c: Share code with lib/frexp.c.
37496         * modules/mathl (Files): Add lib/frexp.c.
37497         (Depends-on): Add isnanl-nolibm.
37498
37499 2007-03-22  Bruno Haible  <bruno@clisp.org>
37500
37501         * modules/printf-frexp (Files): Add m4/frexp.m4.
37502         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
37503         only if the found frexp function actually works.
37504
37505 2007-03-22  Bruno Haible  <bruno@clisp.org>
37506
37507         * lib/frexp.c: Remove older implementation that uses divisions.
37508
37509 2007-03-21  Bruno Haible  <bruno@clisp.org>
37510
37511         * modules/frexp-tests: New file.
37512         * tests/test-frexp.c: New file.
37513
37514         * modules/frexp: New file.
37515         * lib/frexp.c: New file.
37516         * m4/frexp.m4: New file.
37517         * lib/math_.h (frexp): New declaration.
37518         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
37519         REPLACE_FREXP.
37520         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
37521
37522 2007-03-21  Bruno Haible  <bruno@clisp.org>
37523
37524         * modules/isnanl-tests: New file.
37525         * tests/test-isnanl.c: New file.
37526
37527         * modules/isnanl: New file.
37528         * lib/isnanl.h: New file.
37529         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
37530         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
37531         gl_FUNC_ISNANL_WORKS.
37532         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
37533         New macros.
37534
37535 2007-03-21  Bruno Haible  <bruno@clisp.org>
37536
37537         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
37538         lib/isnanl.h.
37539         (Include): Update.
37540         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
37541         * lib/vasnprintf.c: Update.
37542         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
37543         tests/test-isnanl.h, remove tests/test-isnanl.c.
37544         (Makefile.am): Update.
37545         * tests/test-isnanl-nolibm.c: New file.
37546         * tests/test-isnanl.h: New file.
37547         * tests/test-isnanl.c: Remove file.
37548
37549 2007-03-21  Jim Meyering  <jim@meyering.net>
37550
37551         When trying to open ".", treat ESTALE like EACCES.
37552         * lib/savewd.c (savewd_save): Resort to forking not just upon
37553         failure with EACCES, but also when errno is ESTALE.
37554
37555 2007-03-20  Bruno Haible  <bruno@clisp.org>
37556
37557         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
37558         Needed on AIX 5.1. Reported by Matthew Woehlke.
37559
37560 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
37561
37562         Suggestions by Bruno Haible:
37563         * lib/acl-internal.h: Include "gettext.h" rather than rolling
37564         our own.
37565         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
37566         * modules/acl (Depends-on): Add gettext.
37567
37568 2007-03-19  Bruno Haible  <bruno@clisp.org>
37569
37570         * modules/iconvme: Remove file.
37571         * lib/iconvme.h: Remove file.
37572         * lib/iconvme.c: Remove file.
37573         * m4/iconvme.m4: Remove file.
37574
37575 2007-03-19  Bruno Haible  <bruno@clisp.org>
37576
37577         * doc/relocatable-maint.texi: Break long shell script line.
37578         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
37579
37580 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
37581
37582         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
37583         handle file_has_acl.
37584         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
37585         * lib/acl.c: Move header inclusions and related macro defns into
37586         lib/acl-internal.h.
37587         (S_ISLNK): Remove defn, since that's now done for us.
37588         (file_has_acl): Move to lib/file-has-acl.c.
37589         Call acl_trivial if available.  This is the crucial part of the fix.
37590         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
37591         shared within the library.  Rewrite a bit, partly to make it compatible
37592         with the GNU coding style.
37593         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
37594         Remove unnecessary double-quotes.
37595         Don't test for acl_to_text; the build will catch that.
37596         Replace acl_entries if it doesn't exist and it is needed.
37597         Check for -lsec and acl_trivial (as used on Solaris 10).
37598         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
37599         lib/file-has-acl.c.
37600         (Depends-on): Add sys_stat, for S_ISLNK.
37601
37602 2007-03-19  Ben Pfaff  <blp@gnu.org>
37603
37604         * doc/gnulib.texi: Fix typos.
37605         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
37606
37607 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
37608
37609         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
37610         If size is zero here, buf must be zero.
37611
37612 2007-03-19  Simon Josefsson  <simon@josefsson.org>
37613
37614         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
37615         <bruno@clisp.org>.
37616
37617 2007-03-18  Bruno Haible  <bruno@clisp.org>
37618
37619         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
37620         Suggested by Eric Blake.
37621
37622 2007-03-18  Ben Pfaff  <blp@gnu.org>
37623
37624         * doc/relocatable.texi: Recommend using as prefix a directory
37625         that does not exist and will never be created.  Based on
37626         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
37627         and others.
37628
37629 2007-03-17  Bruno Haible  <bruno@clisp.org>
37630
37631         * lib/fchownat.c: Include lchown.h.
37632
37633 2007-03-17  Bruno Haible  <bruno@clisp.org>
37634
37635         Fix endless loop when the given allocated size was > INT_MAX.
37636         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
37637         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
37638         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
37639         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
37640         * lib/sprintf.c (sprintf): Likewise.
37641
37642 2007-03-17  Bruno Haible  <bruno@clisp.org>
37643
37644         * tests/test-argp-2.sh (func_compare): Output a context diff.
37645
37646 2007-03-17  Bruno Haible  <bruno@clisp.org>
37647
37648         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
37649         locale's decimal-point character.
37650
37651 2007-03-17  Bruno Haible  <bruno@clisp.org>
37652
37653         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
37654         before comparing it. Needed because on some platforms (e.g. x86) a
37655         'long double' occupies less bytes than sizeof (long double).
37656
37657 2007-03-17  Bruno Haible  <bruno@clisp.org>
37658
37659         * tests/test-crc.c (main): Make printf statements 64-bit clean.
37660         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
37661         * tests/test-getaddrinfo.c (simple): Likewise.
37662         * tests/test-read-file.c (main): Likewise.
37663
37664 2007-03-17  Bruno Haible  <bruno@clisp.org>
37665
37666         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
37667
37668 2007-03-17  Bruno Haible  <bruno@clisp.org>
37669
37670         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
37671         unused variable.
37672
37673 2007-03-17  Bruno Haible  <bruno@clisp.org>
37674
37675         * tests/test-c-strcasecmp.c: Include c-strcase.h.
37676         * tests/test-c-strncasecmp.c: Likewise.
37677
37678 2007-03-17  Bruno Haible  <bruno@clisp.org>
37679
37680         * modules/stdlib (Depends-on): Add unistd.
37681         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
37682         Needed for MacOS X 10.3.
37683
37684 2007-03-17  Bruno Haible  <bruno@clisp.org>
37685
37686         * lib/unistr/u-strdup.h: Include <stdlib.h>.
37687
37688 2007-03-17  Bruno Haible  <bruno@clisp.org>
37689
37690         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
37691
37692 2007-03-17  Bruno Haible  <bruno@clisp.org>
37693
37694         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
37695         to reflect files copied from gnulib (with or without modifications).
37696         Suggested by Jim Meyering.
37697
37698 2007-03-17  Eric Blake  <ebb9@byu.net>
37699
37700         * NEWS: Document stdlib change from 2007-02-18.
37701
37702 2007-03-17  Jim Meyering  <jim@meyering.net>
37703
37704         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
37705         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
37706         someone uses a name containing shell meta-characters.
37707         Reported by Alfred M. Szmidt.
37708
37709         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
37710
37711 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
37712
37713         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
37714         and copy gettext configuration files only if configure.ac contains
37715         a use of AM_GNU_GETTEXT_VERSION.
37716
37717 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
37718
37719         * build-aux/bootstrap (gnulib_name): New variable.
37720         (gnulib_tool_options): Use it.
37721
37722 2007-03-13  Simon Josefsson  <simon@josefsson.org>
37723
37724         * tests/test-des.c: Use new namespace.
37725
37726 2007-03-15  Bruno Haible  <bruno@clisp.org>
37727
37728         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
37729         Reported by James Youngman <jay@gnu.org>.
37730
37731 2007-03-15  Bruno Haible  <bruno@clisp.org>
37732
37733         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
37734         declared prototype. Needed with cc on OSF/1 5.1.
37735
37736 2007-03-15  Bruno Haible  <bruno@clisp.org>
37737
37738         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
37739         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
37740         (struct gl_list_implementation): Add dispose_fn argument to the
37741         'create_empty', 'create' methods.
37742         (struct gl_list_impl_base): Add field 'dispose_fn'.
37743         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
37744         argument.
37745         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
37746         dispose_fn argument.
37747         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
37748         dispose_fn on the dropped values.
37749         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
37750         dispose_fn argument.
37751         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
37752         dropped values.
37753         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
37754         (gl_tree_remove_node): Call dispose_fn on the dropped value.
37755         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
37756         (gl_tree_remove_node): Call dispose_fn on the dropped value.
37757         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
37758         argument.
37759         (gl_tree_list_free): Call dispose_fn on the dropped values.
37760         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
37761         the dropped values.
37762         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
37763         Add dispose_fn argument.
37764         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
37765         Call dispose_fn on the dropped values.
37766         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
37767         Add dispose_fn argument.
37768         (gl_sublist_create): Initialize the 'dispose_fn' field.
37769         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
37770         * tests/test-array_list.c (main): Update.
37771         * tests/test-carray_list.c (main): Update.
37772         * tests/test-avltree_list.c (main): Update.
37773         * tests/test-rbtree_list.c (main): Update.
37774         * tests/test-avltreehash_list.c (main): Update.
37775         * tests/test-rbtreehash_list.c (main): Update.
37776         * tests/test-linked_list.c (main): Update.
37777         * tests/test-linkedhash_list.c (main): Update.
37778         * tests/test-array_oset.c (main): Update.
37779
37780 2007-03-15  Bruno Haible  <bruno@clisp.org>
37781
37782         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
37783         (gl_oset_create_empty): Add dispose_fn argument.
37784         (struct gl_oset_implementation): Add dispose_fn argument to
37785         'create_empty' method.
37786         (struct gl_oset_impl_base): Add dispose_fn field.
37787         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
37788         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
37789         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
37790         values.
37791         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
37792         (gl_tree_oset_free): Call dispose_fn on the dropped values.
37793         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
37794         dropped value.
37795         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
37796         dropped value.
37797         * tests/test-array_oset.c (main): Update.
37798         * tests/test-avltree_oset.c (main): Update.
37799         * tests/test-rbtree_oset.c (main): Update.
37800         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
37801
37802 2007-03-13  Bruno Haible  <bruno@clisp.org>
37803
37804         * tests/test-stdbool.c (i): Update after last patch.
37805
37806 2007-03-12  Bruno Haible  <bruno@clisp.org>
37807
37808         * lib/quotearg.c: Include <wctype.h> early, before the definition of
37809         the iswprint macro. Needed on Solaris 2.5.1.
37810
37811 2007-03-12  Bruno Haible  <bruno@clisp.org>
37812
37813         * tests/test-printf-frexp.c (main): Declare x as volatile.
37814
37815 2007-03-12  Simon Josefsson  <simon@josefsson.org>
37816
37817         * doc/gnulib.texi (Build robot for gnulib): New section.
37818
37819 2007-03-12  Jim Meyering  <jim@meyering.net>
37820
37821         * build-aux/bootstrap: New file.
37822         * build-aux/bootstrap.conf: New file, from coreutils.
37823
37824 2007-03-11  Bruno Haible  <bruno@clisp.org>
37825
37826         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
37827
37828 2007-03-12  Simon Josefsson  <simon@josefsson.org>
37829
37830         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
37831         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
37832         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
37833
37834 2007-03-11  Bruno Haible  <bruno@clisp.org>
37835
37836         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
37837         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
37838
37839 2007-03-11  Bruno Haible  <bruno@clisp.org>
37840
37841         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
37842         formula. Needed for SunPRO C 5.0.
37843
37844 2007-03-11  Bruno Haible  <bruno@clisp.org>
37845
37846         * modules/long-options (Depends-on): Add getopt.
37847
37848 2007-03-11  Bruno Haible  <bruno@clisp.org>
37849
37850         * modules/modechange (Depends-on): Add stdbool.
37851
37852 2007-03-11  Bruno Haible  <bruno@clisp.org>
37853
37854         * modules/i-ring (Depends-on): Add stdbool.
37855
37856 2007-03-11  Bruno Haible  <bruno@clisp.org>
37857
37858         * modules/gc-des (Depends-on): Add stdbool.
37859
37860 2007-03-11  Bruno Haible  <bruno@clisp.org>
37861
37862         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
37863
37864 2007-03-11  Bruno Haible  <bruno@clisp.org>
37865
37866         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
37867
37868 2007-03-11  Bruno Haible  <bruno@clisp.org>
37869
37870         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
37871
37872 2007-03-11  Bruno Haible  <bruno@clisp.org>
37873
37874         * lib/vasnprintf.c (sprintf): Undefine.
37875
37876 2007-03-11  Bruno Haible  <bruno@clisp.org>
37877
37878         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
37879         initializers in SunPRO C and Compaq C compilers.
37880
37881 2007-03-11  Bruno Haible  <bruno@clisp.org>
37882
37883         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
37884         decrementing code ANSI C compliant.
37885
37886 2007-03-11  Bruno Haible  <bruno@clisp.org>
37887
37888         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
37889         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
37890
37891 2007-03-11  Bruno Haible  <bruno@clisp.org>
37892
37893         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
37894         <stdbool.h> substitute doesn't pass.
37895
37896 2007-03-11  Bruno Haible  <bruno@clisp.org>
37897
37898         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
37899
37900 2007-03-11  Bruno Haible  <bruno@clisp.org>
37901
37902         * gnulib-tool (func_create_megatestdir): Create also an autobuild
37903         script, for submission to autobuild.josefsson.org.
37904
37905 2007-03-10  Bruno Haible  <bruno@clisp.org>
37906
37907         * modules/canonicalize-lgpl-tests: New file.
37908         * tests/test-canonicalize-lgpl.sh: New file.
37909         * tests/test-canonicalize-lgpl.c: New file.
37910
37911         * modules/c-strcase-tests: New file.
37912         * tests/test-c-strcase.sh: New file.
37913         * tests/test-c-strcasecmp.c: New file.
37914         * tests/test-c-strncasecmp.c: New file.
37915
37916         * modules/atexit-tests: New file.
37917         * tests/test-atexit.sh: New file.
37918         * tests/test-atexit.c: New file.
37919
37920 2007-03-10  Bruno Haible  <bruno@clisp.org>
37921
37922         * tests/test-binary-io.sh: Use temporary filenames that are not so
37923         likely to clash with those of other tests (in a parallel make).
37924         * tests/test-binary-io.c: Likewise.
37925
37926 2007-03-10  Bruno Haible  <bruno@clisp.org>
37927
37928         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
37929         fallback; use #error instead.
37930         Suggested by Simon Josefsson.
37931
37932 2007-03-10  Bruno Haible  <bruno@clisp.org>
37933
37934         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
37935         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
37936         first and the last.
37937
37938 2007-03-10  Bruno Haible  <bruno@clisp.org>
37939
37940         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
37941
37942 2007-03-10  Bruno Haible  <bruno@clisp.org>
37943
37944         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
37945         "make distcheck".
37946         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
37947         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
37948         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
37949
37950 2007-03-10  Bruno Haible  <bruno@clisp.org>
37951
37952         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
37953         variable.
37954         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
37955         variable.
37956
37957 2007-03-09  Eric Blake  <ebb9@byu.net>
37958         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
37959
37960         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
37961         types are not being provided by gnulib.
37962         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
37963         types are supported.
37964
37965 2007-03-10  Bruno Haible  <bruno@clisp.org>
37966
37967         * lib/stdio_.h (__attribute__): New macro.
37968         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
37969         vsprintf): Specify __attribute__ __format__ for GCC.
37970         Suggested by Eric Blake.
37971
37972 2007-03-09  Bruno Haible  <bruno@clisp.org>
37973
37974         * modules/printf-posix-tests: New file.
37975         * tests/test-printf-posix.sh: New file.
37976         * tests/test-printf-posix.c: New file.
37977
37978         * modules/printf-posix: New file.
37979         * lib/printf.c: New file.
37980         * m4/printf-posix-rpl.m4: New file.
37981         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
37982         REPLACE_PRINTF.
37983         * lib/stdio_.h (printf): New declaration.
37984         (format, __format__, ____printf____, ____scanf____, ____strftime____,
37985         ____strfmon____): New macros.
37986         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
37987         REPLACE_PRINTF.
37988
37989 2007-03-09  Bruno Haible  <bruno@clisp.org>
37990
37991         * tests/test-vasnprintf-posix2.sh: New file.
37992         * tests/test-vasnprintf-posix2.c: New file.
37993         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
37994         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
37995         (Makefile.am): Activate test-vasnprintf-posix2.sh.
37996
37997         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
37998         a locale dependent decimal point, rather than always '.'.
37999
38000 2007-03-09  Eric Blake  <ebb9@byu.net>
38001
38002         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
38003         spite of platforms like Tandem/NSK that define it to -1.
38004
38005 2007-03-08  Bruno Haible  <bruno@clisp.org>
38006
38007         * modules/vprintf-posix-tests: New file.
38008         * tests/test-vprintf-posix.sh: New file.
38009         * tests/test-vprintf-posix.c: New file.
38010         * tests/test-printf-posix.h: New file.
38011
38012         * modules/vprintf-posix: New file.
38013         * lib/vprintf.c: New file.
38014         * m4/vprintf-posix.m4: New file.
38015         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
38016         REPLACE_VPRINTF.
38017         * lib/stdio_.h (vprintf): New declaration.
38018         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
38019         REPLACE_VPRINTF.
38020
38021 2007-03-08  Bruno Haible  <bruno@clisp.org>
38022
38023         * modules/fprintf-posix-tests: New file.
38024         * tests/test-fprintf-posix.sh: New file.
38025         * tests/test-fprintf-posix.c: New file.
38026
38027         * modules/fprintf-posix: New file.
38028         * lib/fprintf.c: New file.
38029         * m4/fprintf-posix.m4: New file.
38030         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
38031         REPLACE_FPRINTF.
38032         * lib/stdio_.h (fprintf): New declaration.
38033         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
38034         REPLACE_FPRINTF.
38035
38036 2007-03-08  Bruno Haible  <bruno@clisp.org>
38037
38038         * modules/vfprintf-posix-tests: New file.
38039         * tests/test-vfprintf-posix.sh: New file.
38040         * tests/test-vfprintf-posix.c: New file.
38041         * tests/test-fprintf-posix.h: New file.
38042         * tests/test-fprintf-posix.out: New file.
38043
38044         * modules/vfprintf-posix: New file.
38045         * lib/vfprintf.c: New file.
38046         * m4/vfprintf-posix.m4: New file.
38047         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
38048         REPLACE_VFPRINTF.
38049         * lib/stdio_.h (vfprintf): New declaration.
38050         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
38051         REPLACE_VFPRINTF.
38052
38053 2007-03-08  Bruno Haible  <bruno@clisp.org>
38054
38055         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
38056
38057 2007-03-08  Bruno Haible  <bruno@clisp.org>
38058
38059         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
38060         instead of 'expr' invocations.
38061         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
38062         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
38063         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
38064         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
38065         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
38066         Suggested by Paul Eggert.
38067
38068 2007-03-08  Bruno Haible  <bruno@clisp.org>
38069
38070         * modules/fseterr-tests: New file.
38071         * tests/test-fseterr.c: New file.
38072
38073         * modules/fseterr: New file.
38074         * lib/fseterr.h: New file.
38075         * lib/fseterr.c: New file.
38076
38077 2007-03-08  Bruno Haible  <bruno@clisp.org>
38078
38079         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
38080         * lib/getopt_.h: Likewise.
38081         * lib/mbswidth.h: Likewise.
38082         * lib/setenv.h: Likewise.
38083         * lib/vasnprintf.h: Likewise.
38084         * lib/vasprintf.h: Likewise.
38085         * lib/verror.h: Likewise.
38086         * lib/xsetenv.h: Likewise.
38087         * lib/xvasprintf.h: Likewise.
38088
38089 2007-03-08  Jim Meyering  <jim@meyering.net>
38090
38091         * users.txt: Add parted.
38092
38093         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
38094
38095 2007-03-07  Bruno Haible  <bruno@clisp.org>
38096
38097         * m4/printf.m4: Make the shell script snippets copy&pastable.
38098
38099 2007-03-02  Bruno Haible  <bruno@clisp.org>
38100
38101         * lib/netinet_in_.h: New file.
38102         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
38103         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
38104         * modules/netinet_in (Files): Add lib/netinet_in_.h.
38105         (Depends-on): Add absolute-header.
38106         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
38107         into netinet/in.h.
38108
38109 2007-03-03  Bruno Haible  <bruno@clisp.org>
38110
38111         * lib/sys_select_.h: New file.
38112         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
38113         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
38114         * modules/sys_select (Files): Add lib/sys_select_.h.
38115         (Depends-on): Add absolute-header.
38116         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
38117         into sys/select.h.
38118
38119 2007-03-02  Bruno Haible  <bruno@clisp.org>
38120
38121         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
38122         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
38123         values.
38124         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
38125         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
38126         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
38127         * modules/sys_socket (Depends-on): Add absolute-header.
38128         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
38129         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
38130         (Include): Remove requirement of inclusion of <sys/types.h>.
38131
38132 2007-03-02  Bruno Haible  <bruno@clisp.org>
38133
38134         * lib/byteswap_.h (bswap_32): Fix formula.
38135
38136 2007-03-06  Bruno Haible  <bruno@clisp.org>
38137
38138         * modules/sprintf-posix-tests: New file.
38139         * tests/test-sprintf-posix.c: New file.
38140
38141         * modules/sprintf-posix: New file.
38142         * lib/sprintf.c: New file.
38143         * m4/sprintf-posix.m4: New file.
38144         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
38145         REPLACE_SPRINTF.
38146         * lib/stdio_.h (sprintf): New declaration.
38147         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
38148         REPLACE_SPRINTF.
38149
38150 2007-03-06  Bruno Haible  <bruno@clisp.org>
38151
38152         * modules/vsprintf-posix-tests: New file.
38153         * tests/test-vsprintf-posix.c: New file.
38154         * tests/test-sprintf-posix.h: New file.
38155
38156         * modules/vsprintf-posix: New file.
38157         * lib/vsprintf.c: New file.
38158         * m4/vsprintf-posix.m4: New file.
38159         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
38160         REPLACE_VSPRINTF.
38161         * lib/stdio_.h (vsprintf): New declaration.
38162         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
38163         REPLACE_VSPRINTF.
38164
38165 2007-03-06  Bruno Haible  <bruno@clisp.org>
38166
38167         * modules/vsnprintf (Depend-on): Remove minmax.
38168
38169 2007-03-06  Bruno Haible  <bruno@clisp.org>
38170
38171         * modules/snprintf-posix-tests: New file.
38172         * tests/test-snprintf-posix.c: New file.
38173
38174         * modules/snprintf-posix: New file.
38175         * m4/snprintf-posix.m4: New file.
38176         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
38177         gl_FUNC_SNPRINTF.
38178         (gl_FUNC_SNPRINTF): Invoke it.
38179         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
38180         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
38181         is set.
38182         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
38183
38184 2007-03-06  Bruno Haible  <bruno@clisp.org>
38185
38186         * modules/vsnprintf-posix-tests: New file.
38187         * tests/test-vsnprintf-posix.c: New file.
38188         * tests/test-snprintf-posix.h: New file.
38189
38190         * modules/vsnprintf-posix: New file.
38191         * m4/vsnprintf-posix.m4: New file.
38192         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
38193         gl_FUNC_VSNPRINTF.
38194         (gl_FUNC_VSNPRINTF): Invoke it.
38195         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
38196         * lib/stdio_.h (vsnprintf): Define as a replacement if
38197         REPLACE_VSNPRINTF is set.
38198         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
38199
38200 2007-03-06  Bruno Haible  <bruno@clisp.org>
38201
38202         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
38203         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
38204
38205 2007-03-06  Bruno Haible  <bruno@clisp.org>
38206
38207         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
38208         (asinl): Declare also if HAVE_DECL_ASINL is set.
38209         (atanl): Declare also if HAVE_DECL_ATANL is set.
38210         (ceill): Declare also if HAVE_DECL_CEILL is set.
38211         (cosl): Declare also if HAVE_DECL_COSL is set.
38212         (expl): Declare also if HAVE_DECL_EXPL is set.
38213         (floorl): Declare also if HAVE_DECL_FLOORL is set.
38214         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
38215         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
38216         (logl): Declare also if HAVE_DECL_LOGL is set.
38217         (sinl): Declare also if HAVE_DECL_SINL is set.
38218         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
38219         (tanl): Declare also if HAVE_DECL_TANL is set.
38220         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
38221         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
38222         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
38223         declaration of frexpl, ldexpl.
38224         * modules/printf-frexpl (Depends-on): Add math.
38225         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
38226
38227 2007-03-05  Bruno Haible  <bruno@clisp.org>
38228
38229         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
38230         frexpl and ldexpl are declared.
38231         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
38232
38233 2007-03-05  Bruno Haible  <bruno@clisp.org>
38234
38235         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
38236         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
38237
38238 2007-03-05  Bruno Haible  <bruno@clisp.org>
38239
38240         * lib/stdio_.h: Include <stddef.h>.
38241
38242 2007-03-05  Bruno Haible  <bruno@clisp.org>
38243
38244         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
38245
38246 2007-03-05  Bruno Haible  <bruno@clisp.org>
38247
38248         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
38249         NetBSD 4, from Ralf Wildenhues.
38250
38251 2007-03-04  Bruno Haible  <bruno@clisp.org>
38252
38253         * lib/vasprintf.h: Update #if logic for the case when the functions
38254         exist but are overridden.
38255
38256 2007-03-04  Bruno Haible  <bruno@clisp.org>
38257
38258         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
38259         implementations: glibc-2.4 and MacOS X 10.3.
38260         * tests/test-vasnprintf-posix.c (test_function): Test also the case
38261         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
38262         * tests/test-vasprintf-posix.c (test_function): Likewise.
38263
38264 2007-03-04  Bruno Haible  <bruno@clisp.org>
38265
38266         * modules/vasprintf-posix-tests: New file.
38267         * tests/test-vasprintf-posix.c: New file.
38268
38269         * modules/vasprintf-posix: New file.
38270         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
38271         defined.
38272         * m4/vasprintf-posix.m4: New file.
38273         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
38274         gl_FUNC_VASPRINTF.
38275         (gl_FUNC_VASPRINTF): Invoke it.
38276         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
38277         here.
38278         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
38279
38280 2007-03-04  Bruno Haible  <bruno@clisp.org>
38281
38282         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
38283         REPLACE_GETTIMEOFDAY.
38284         * modules/sys_time (Makefile.am): Likewise.
38285         * m4/sys_time_h.m4: Likewise.
38286         * m4/gettimeofday.m4: Likewise.
38287
38288 2007-03-04  Bruno Haible  <bruno@clisp.org>
38289
38290         * modules/vasnprintf-posix-tests: New file.
38291         * tests/test-vasnprintf-posix.c: New file.
38292
38293         * modules/vasnprintf-posix: New file.
38294         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
38295         printf-frexpl.h.
38296         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
38297         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
38298         REPLACE_VASNPRINTF is defined.
38299         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
38300         gl_FUNC_VASNPRINTF.
38301         (gl_FUNC_VASNPRINTF): Invoke it.
38302         * m4/vasnprintf-posix.m4: New file.
38303         * m4/printf.m4: New file.
38304
38305 2007-03-04  Bruno Haible  <bruno@clisp.org>
38306
38307         Compile progreloc.c only if --enable-relocatable is specified.
38308         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
38309         if --enable-relocatable was specified.
38310         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
38311         lib_SOURCES.
38312
38313 2007-03-04  Jim Meyering  <jim@meyering.net>
38314
38315         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
38316         Use it consistently, rather than enumerating errno constants.
38317
38318 2007-03-04  Bruno Haible  <bruno@clisp.org>
38319
38320         * modules/xvasprintf-tests: New file.
38321         * tests/test-xvasprintf.c: New file.
38322
38323         * modules/vasprintf-tests: New file.
38324         * tests/test-vasprintf.c: New file.
38325
38326         * modules/vasnprintf-tests: New file.
38327         * tests/test-vasnprintf.c: New file.
38328
38329         * modules/vsnprintf-tests: New file.
38330         * tests/test-vsnprintf.c: New file.
38331
38332         * modules/snprintf-tests: New file.
38333         * tests/test-snprintf.c: New file.
38334
38335 2007-03-04  Bruno Haible  <bruno@clisp.org>
38336
38337         Compile relocatable.c only if --enable-relocatable is specified.
38338         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
38339         gl_RELOCATABLE_LIBRARY.
38340         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
38341         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
38342         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
38343         gl_RELOCATABLE_LIBRARY.
38344         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
38345         (Makefile.am): Remove lib_SOURCES.
38346         * modules/relocatable-lib-lgpl (configure.ac): Invoke
38347         gl_RELOCATABLE_LIBRARY.
38348         (Makefile.am): Remove lib_SOURCES.
38349         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
38350         always.
38351         * modules/relocatable-prog-wrapper (configure.ac): Invoke
38352         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
38353
38354 2007-03-04  Bruno Haible  <bruno@clisp.org>
38355
38356         * modules/argmatch-tests: New file.
38357         * tests/test-argmatch.c: New file.
38358
38359         * tests/test-allocsa.c (main): Halve the number of loop runs.
38360
38361         * modules/alloca-opt-tests: New file.
38362         * tests/test-alloca-opt.c: New file.
38363
38364 2007-03-04  Jim Meyering  <jim@meyering.net>
38365
38366         Work around difference between Linux ACLs and Solaris 10 ZFS.
38367         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
38368         for EINVAL.
38369
38370 2007-03-03  Bruno Haible  <bruno@clisp.org>
38371
38372         * modules/relocatable-prog (Depends-on): Add back progreloc's
38373         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
38374
38375 2007-03-03  Bruno Haible  <bruno@clisp.org>
38376
38377         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
38378         * modules/relocatable-lib: New file.
38379
38380 2007-03-03  Bruno Haible  <bruno@clisp.org>
38381
38382         * modules/relocatable-prog: Renamed from modules/relocatable.
38383         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
38384
38385 2007-03-03  Bruno Haible  <bruno@clisp.org>
38386
38387         * modules/relocatable-script (Files): Add doc/relocatable.texi,
38388         m4/relocatable-lib.m4.
38389         (Depends-on): Remove 'relocatable'.
38390         (configure.ac): Add gl_RELOCATABLE_NOP.
38391
38392 2007-03-03  Bruno Haible  <bruno@clisp.org>
38393
38394         * modules/relocatable-prog-wrapper: New file.
38395         * modules/relocatable (Depends-on): Add it. Remove all other
38396         dependencies except progname.
38397         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
38398
38399         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
38400         (gl_FUNC_STRERROR): Nop.
38401         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
38402
38403         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
38404         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
38405
38406         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
38407         (gl_FUNC_READLINK): Update.
38408
38409         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
38410
38411 2007-03-03  Bruno Haible  <bruno@clisp.org>
38412
38413         * lib/xreadlink.c: Include <unistd.h> unconditionally.
38414         * modules/xreadlink (Depends-on): Add unistd.
38415         * modules/xreadlink-with-size (Depends-on): Likewise.
38416
38417 2007-03-03  Bruno Haible  <bruno@clisp.org>
38418
38419         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
38420         extracted from gt_FUNC_SETENV.
38421         (gt_FUNC_SETENV): Remove macro.
38422         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
38423         remove gt_FUNC_SETENV.
38424
38425 2007-03-03  Bruno Haible  <bruno@clisp.org>
38426
38427         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
38428         ENABLE_RELOCATABLE here.
38429         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
38430
38431 2007-03-03  Bruno Haible  <bruno@clisp.org>
38432
38433         * modules/rbtreehash-list-tests (Depends-on): Add progname.
38434         * tests/test-rbtreehash_list.c: Include progname.h.
38435         (main): Call set_program_name.
38436
38437         * modules/rbtree-oset-tests (Depends-on): Add progname.
38438         * tests/test-rbtree_oset.c: Include progname.h.
38439         (main): Call set_program_name.
38440
38441         * modules/rbtree-list-tests (Depends-on): Add progname.
38442         * tests/test-rbtree_list.c: Include progname.h.
38443         (main): Call set_program_name.
38444
38445         * modules/linked-list-tests (Depends-on): Add progname.
38446         * tests/test-linked_list.c: Include progname.h.
38447         (main): Call set_program_name.
38448
38449 2007-03-03  Bruno Haible  <bruno@clisp.org>
38450
38451         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
38452         All uses of __restrict changed to _Restrict_.
38453         * lib/glob_.h (__restrict): Remove macro.
38454
38455 2007-03-02  Bruno Haible  <bruno@clisp.org>
38456
38457         * modules/gettext (configure.ac): Require gettext infrastructure
38458         from version 0.16.1.
38459
38460 2007-03-02  Bruno Haible  <bruno@clisp.org>
38461
38462         * modules/linkedhash-list-tests (Depends-on): Add progname.
38463         * tests/test-linkedhash_list.c: Include progname.h.
38464         (main): Call set_program_name.
38465
38466         * modules/carray-list-tests (Depends-on): Add progname.
38467         * tests/test-carray_list.c: Include progname.h.
38468         (main): Call set_program_name.
38469
38470         * modules/avltreehash-list-tests (Depends-on): Add progname.
38471         * tests/test-avltreehash_list.c: Include progname.h.
38472         (main): Call set_program_name.
38473
38474         * modules/avltree-oset-tests (Depends-on): Add progname.
38475         * tests/test-avltree_oset.c: Include progname.h.
38476         (main): Call set_program_name.
38477
38478         * modules/avltree-list-tests (Depends-on): Add progname.
38479         * tests/test-avltree_list.c: Include progname.h.
38480         (main): Call set_program_name.
38481
38482         * modules/array-oset-tests (Depends-on): Add progname.
38483         * tests/test-array_oset.c: Include progname.h.
38484         (main): Call set_program_name.
38485
38486         * modules/array-list-tests (Depends-on): Add progname.
38487         * tests/test-array_list.c: Include progname.h.
38488         (main): Call set_program_name.
38489
38490         * modules/argp-tests (Depends-on): Add progname.
38491         * tests/test-argp.c: Include argp.h first. Include progname.h.
38492         (main): Call set_program_name.
38493
38494 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
38495
38496         * doc/gnulib-tool.texi (Initial import): Reword description of
38497         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
38498         limited effect even if defined after the first system include.
38499
38500 2007-03-01  Bruno Haible  <bruno@clisp.org>
38501
38502         * build-aux/config.libpath: Update to libtool-1.5.22.
38503         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
38504
38505 2007-03-01  Bruno Haible  <bruno@clisp.org>
38506
38507         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
38508         foo_CFLAGS.
38509         Reported by Ralf Wildenhues.
38510
38511 2007-03-01  Bruno Haible  <bruno@clisp.org>
38512
38513         * build-aux/install-reloc: Remove object files left over by some
38514         compilers.
38515         Reported by Ralf Wildenhues.
38516
38517 2007-03-01  Bruno Haible  <bruno@clisp.org>
38518
38519         * build-aux/install-reloc: Break long lines.
38520
38521 2007-03-01  Bruno Haible  <bruno@clisp.org>
38522
38523         * doc/relocatable.texi: Document that it may not work on OpenBSD.
38524         Reported by Ralf Wildenhues.
38525
38526 2007-03-01  Bruno Haible  <bruno@clisp.org>
38527
38528         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
38529         include ordering constraints.
38530
38531 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
38532
38533         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
38534         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
38535         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
38536         as another example.
38537         * lib/time_.h: Fix misspelling.
38538         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
38539         Require gl_HEADER_TIME_H_DEFAULTS.
38540         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
38541         * m4/time_r.m4 (gl_TIME_R): Likewise.
38542         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
38543
38544 2007-03-01  Bruno Haible  <bruno@clisp.org>
38545
38546         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
38547         * m4/utimens.m4 (gl_UTIMENS): Likewise.
38548
38549 2007-03-01  Jim Meyering  <jim@meyering.net>
38550
38551         * modules/xreadlink (Maintainer): Add my name.
38552         * modules/xreadlink-with-size (Depends-on): Alphabetize.
38553
38554 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
38555             Bruno Haible  <bruno@clisp.org>
38556
38557         * build-aux/install-reloc: Compile also c-ctype.c.
38558         * build-aux/relocatable.sh.in: New file.
38559         * doc/relocatable.texi: New file.
38560         * doc/relocatable-maint.texi: New file.
38561         * doc/gnulib.texi: Include relocatable-maint.texi.
38562         * lib/progreloc.c: Include unistd.h unconditionally.
38563         * lib/relocwrapper.c: Include unistd.h unconditionally.
38564         Include c-ctype.h.
38565         (add_dotbin): Use c_tolower.
38566         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
38567         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
38568         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
38569         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
38570         to m4/relocatable-lib.m4.
38571         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
38572         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
38573         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
38574         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
38575         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
38576         * modules/relocatable: New file.
38577         * modules/relocatable-lib: New file.
38578         * modules/relocatable-script: New file.
38579
38580 2007-02-28  Bruno Haible  <bruno@clisp.org>
38581
38582         Import --enable-relocatable infrastructure.
38583         * build-aux/config.libpath: New file, from GNU gettext.
38584         * build-aux/install-reloc: New file, from GNU gettext.
38585         * build-aux/reloc-ldflags: New file, from GNU gettext.
38586         * lib/relocatable.h: New file, from GNU gettext.
38587         * lib/relocatable.c: New file, from GNU gettext.
38588         * lib/relocwrapper.c: New file, from GNU gettext.
38589         * m4/relocatable.m4: New file, from GNU gettext.
38590
38591 2007-02-28  Bruno Haible  <bruno@clisp.org>
38592
38593         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
38594
38595         * modules/xreadlink: New file, from GNU gettext with modifications.
38596         * lib/xreadlink.c: New file, from GNU gettext.
38597         * lib/xreadlink.h: Add comments.
38598         (xreadlink): New declaration.
38599
38600         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
38601         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
38602         lib/xreadlink-with-size.c.
38603         (configure.ac): Remove gl_XREADLINK invocation.
38604         (Makefile.am): Augment lib_SOURCES.
38605         * m4/xreadlink.m4: Remove file.
38606         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
38607         (xreadlink_with_size): Renamed from xreadink.
38608         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
38609         * modules/canonicalize (Depends-on): Replace xreadlink with
38610         xreadlink-with-size.
38611         * lib/canonicalize.c (canonicalize_filename_mode): Update.
38612
38613 2007-02-25  Jim Meyering  <jim@meyering.net>
38614
38615         * build-aux/announce-gen: When complaining about excess arguments,
38616         list them.
38617
38618 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
38619
38620         * README: Document signed integer overflow situation more
38621         accurately.
38622
38623 2007-02-25  Bruno Haible  <bruno@clisp.org>
38624
38625         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
38626         'a' or 'A' conversion.
38627
38628 2007-02-25  Bruno Haible  <bruno@clisp.org>
38629
38630         * modules/filename: Renamed from modules/pathname.
38631         (Files): Replace lib/pathname.h with lib/filename.h. Replace
38632         lib/concatpath.c with lib/concat-filename.c.
38633         (Makefile.am): Update.
38634         (Include): Replace pathname.h with filename.h.
38635         * lib/filename.h: Renamed from lib/pathname.h.
38636         (concatenated_filename): Renamed from concatenated_pathname.
38637         * lib/concat-filename.c: Renamed from lib/concatpath.c.
38638         (concatenated_filename): Renamed from concatenated_pathname.
38639         * lib/findprog.c: Include filename.h instead of pathname.h.
38640         (find_in_path): Update.
38641         * lib/javacomp.c: Include filename.h instead of pathname.h.
38642         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
38643         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
38644         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
38645         is_oldgcj_14_13_usable, is_javac_usable): Update.
38646         * lib/javaexec.c: Include filename.h instead of pathname.h.
38647         (execute_java_class): Update.
38648         * modules/findprog: Update.
38649         * modules/javacomp: Update.
38650         * modules/javaexec: Update.
38651         * MODULES.html.sh (File system functions): Add 'filename', remove
38652         'pathname'.
38653
38654 2007-02-25  Bruno Haible  <bruno@clisp.org>
38655
38656         * modules/printf-frexpl-tests: New file.
38657         * tests/test-printf-frexpl.c: New file.
38658
38659         * modules/printf-frexpl: New file.
38660         * lib/printf-frexpl.h: New file.
38661         * lib/printf-frexpl.c: New file.
38662         * m4/printf-frexpl.m4: New file.
38663
38664 2007-02-25  Bruno Haible  <bruno@clisp.org>
38665
38666         * modules/printf-frexp-tests: New file.
38667         * tests/test-printf-frexp.c: New file.
38668
38669         * modules/printf-frexp: New file.
38670         * lib/printf-frexp.h: New file.
38671         * lib/printf-frexp.c: New file.
38672         * m4/printf-frexp.m4: New file.
38673
38674 2007-02-25  Bruno Haible  <bruno@clisp.org>
38675
38676         Assume automake >= 1.10 for the tests.
38677         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
38678         * modules/arctwo-tests: Likewise.
38679         * modules/argp-tests: Likewise.
38680         * modules/avltree-list-tests: Likewise.
38681         * modules/avltree-oset-tests: Likewise.
38682         * modules/avltreehash-list-tests: Likewise.
38683         * modules/carray-list-tests: Likewise.
38684         * modules/crc-tests: Likewise.
38685         * modules/des-tests: Likewise.
38686         * modules/gc-arcfour-tests: Likewise.
38687         * modules/gc-arctwo-tests: Likewise.
38688         * modules/gc-des-tests: Likewise.
38689         * modules/gc-hmac-md5-tests: Likewise.
38690         * modules/gc-hmac-sha1-tests: Likewise.
38691         * modules/gc-md2-tests: Likewise.
38692         * modules/gc-md4-tests: Likewise.
38693         * modules/gc-md5-tests: Likewise.
38694         * modules/gc-pbkdf2-sha1-tests: Likewise.
38695         * modules/gc-rijndael-tests: Likewise.
38696         * modules/gc-sha1-tests: Likewise.
38697         * modules/gc-tests: Likewise.
38698         * modules/getaddrinfo-tests: Likewise.
38699         * modules/hmac-md5-tests: Likewise.
38700         * modules/hmac-sha1-tests: Likewise.
38701         * modules/linked-list-tests: Likewise.
38702         * modules/linkedhash-list-tests: Likewise.
38703         * modules/lock-tests: Likewise.
38704         * modules/md2-tests: Likewise.
38705         * modules/md4-tests: Likewise.
38706         * modules/md5-tests: Likewise.
38707         * modules/rbtree-list-tests: Likewise.
38708         * modules/rbtree-oset-tests: Likewise.
38709         * modules/rbtreehash-list-tests: Likewise.
38710         * modules/read-file-tests: Likewise.
38711         * modules/rijndael-tests: Likewise.
38712         * modules/stdint-tests: Likewise.
38713         * modules/tls-tests: Likewise.
38714
38715 2007-02-24  Bruno Haible  <bruno@clisp.org>
38716
38717         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
38718         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
38719         function; instead check whether isnan with a double argument links.
38720         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
38721         function; instead check whether isnan with a 'long double' argument
38722         links.
38723         Reported by Eric Blake <ebb9@byu.net>.
38724
38725 2007-02-24  Bruno Haible  <bruno@clisp.org>
38726
38727         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
38728         defined.
38729         * lib/isnanl.c: Remove all code. Just include isnan.c.
38730         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
38731
38732 2007-02-25  Jim Meyering  <jim@meyering.net>
38733
38734         Avoid conflicting types for 'unsetenv' on FreeBSD.
38735         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
38736         conflicting with FreeBSD's (5.0 and 6.1) function declaration
38737         in stdlib.h.
38738
38739 2007-02-24  Bruno Haible  <bruno@clisp.org>
38740
38741         * modules/isnanl-nolibm-tests: New file.
38742         * tests/test-isnanl.c: New file.
38743
38744         * modules/isnanl-nolibm: New file.
38745         * lib/isnanl.h: New file.
38746         * lib/isnanl.c: New file.
38747         * m4/isnanl.m4: New file.
38748
38749 2007-02-24  Bruno Haible  <bruno@clisp.org>
38750
38751         * modules/isnan-nolibm-tests: New file.
38752         * tests/test-isnan.c: New file.
38753
38754         * modules/isnan-nolibm: New file.
38755         * lib/isnan.h: New file.
38756         * lib/isnan.c: New file.
38757         * m4/isnan.m4: New file.
38758
38759 2007-02-24  Bruno Haible  <bruno@clisp.org>
38760
38761         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
38762         assume that an exponent fits in 20 bits.
38763
38764 2007-02-24  Jim Meyering  <jim@meyering.net>
38765
38766         * m4/regex.m4: Update the description of the configure-time option,
38767         --without-included-regex, to state accurately what the defaults are,
38768         and perhaps to give people an idea why using this option is risky.
38769
38770 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
38771
38772         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
38773         loops on small arguments.  This attempts to avoid the problem
38774         Bruno Haible reported for AIX 4.3.2 in
38775         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
38776
38777 2007-02-23  Bruno Haible  <bruno@clisp.org>
38778
38779         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
38780         Needed for help2man.
38781
38782 2007-02-23  Karl Berry  <karl@gnu.org>
38783
38784         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
38785         exists, foo.h should be cvs-ignored, not committed.
38786
38787 2007-02-23  Eric Blake  <ebb9@byu.net>
38788
38789         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
38790         * lib/stat-time.h (includes): Likewise.
38791         * lib/utimecmp.c (includes): Likewise.
38792         * lib/utimens.h (includes): Likewise.
38793         * lib/getdate.y (includes): Also include "timespec.h" for use
38794         internal to the module.
38795         * modules/utimens (Depends-on): Revert yesterday's patch.
38796         * modules/nanosleep (Depends-on): Add missing dependency.
38797
38798 2007-02-22  Bruno Haible  <bruno@clisp.org>
38799
38800         * lib/glob.c: Don't include getlogin_r.h.
38801
38802 2007-02-22  Jim Meyering  <jim@meyering.net>
38803
38804         * modules/utimens (Depends-on): Add timespec, required for
38805         utimens.h's inclusion of timespec.h.
38806
38807 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
38808
38809         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
38810         long unreadable paths in GNU/Linux.  Problem reported by Andreas
38811         Schwab in
38812         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
38813         I'll try to think of a better way to fix the Solaris problem.
38814
38815         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
38816         like glibc; on Solaris 10, it fails with errno == EINVAL.
38817         POSIX says the behavior is unspecified if the first argument is NULL,
38818         so play it safe and never pass NULL to the system getcwd.
38819
38820 2007-02-21  Jim Meyering  <jim@meyering.net>
38821
38822         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
38823         of gettimeofday.  It would conflict with the one now always
38824         provided via sys_time_.h.  Reported by Matthew Woehlke, as
38825         an IRIX 6.5 build failure.
38826
38827 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
38828
38829         Minor fixups to port to Solaris 10 with Sun C 5.8.
38830         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
38831         * modules/getcwd (Depends-on): Add dirfd.
38832         * lib/putenv.c (putenv): #undef it.
38833         (rpl_putenv): New decl.
38834         (malloc, free): Include <stdlib.h> rather than prototyping separately.
38835
38836 2007-02-20  Bruno Haible  <bruno@clisp.org>
38837
38838         * modules/stdio-tests: New file.
38839         * tests/test-stdio.c: New file.
38840
38841         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
38842         (Depends-on): Add stdio.
38843         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
38844         (Include): Use <stdio.h> instead of vsnprintf.h.
38845         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
38846         HAVE_DECL_VSNPRINTF.
38847         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
38848
38849         * modules/snprintf (Files): Remove lib/snprintf.h.
38850         (Depends-on): Add stdio.
38851         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
38852         (Include): Use <stdio.h> instead of snprintf.h.
38853         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
38854         HAVE_DECL_SNPRINTF.
38855         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
38856         * lib/getaddrinfo.c: Likewise.
38857
38858         * modules/stdio: New file.
38859         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
38860         * lib/snprintf.h: Remove file.
38861         * lib/vsnprintf.h: Remove file.
38862         * lib/.cppi-disable: Remove snprintf.h.
38863         * m4/stdio_h.m4: New file.
38864         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
38865
38866 2007-02-20  Jim Meyering  <jim@meyering.net>
38867
38868         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
38869         used by e.g., mingw.  From Bruno Haible.
38870
38871 2007-02-19  Bruno Haible  <bruno@clisp.org>
38872
38873         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
38874         warnings.
38875         Reported by Ben Pfaff <blp@cs.stanford.edu>.
38876
38877 2007-02-19  Bruno Haible  <bruno@clisp.org>
38878
38879         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
38880         from mingw users.
38881
38882 2007-02-19  Bruno Haible  <bruno@clisp.org>
38883
38884         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
38885         warnings.
38886         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
38887
38888 2007-02-19  Jim Meyering  <jim@meyering.net>
38889
38890         Don't use FD after a successful "fdopendir (fd)".
38891         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
38892         Reset it by calling dirfd on the just-obtained DIR*.
38893
38894         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
38895         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
38896
38897 2007-02-18  Bruno Haible  <bruno@clisp.org>
38898
38899         * lib/readlink.c: Include <unistd.h>.
38900         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
38901         HAVE_READLINK.
38902         * modules/readlink (Depends-on): Add unistd.
38903         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38904         (Include): Add <unistd.h>.
38905
38906         * lib/getlogin_r.h: Remove file.
38907         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
38908         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
38909         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
38910         HAVE_DECL_GETLOGIN_R.
38911         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
38912         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38913         (Include): Use <unistd.h> instead of getlogin_r.h.
38914
38915         * lib/getcwd.h: Remove file.
38916         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
38917         * lib/xgetcwd.c: Likewise.
38918         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
38919         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
38920         * modules/getcwd (Files): Remove lib/getcwd.h.
38921         (Depends-on): Add unistd.
38922         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38923         (Include): Use <unistd.h> instad of getcwd.h.
38924
38925         * lib/ftruncate.c: Include <unistd.h> first.
38926         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
38927         Set HAVE_FTRUNCATE.
38928         * modules/ftruncate (Depends-on): Add unistd.
38929         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38930
38931         * lib/fchdir.c: Include <unistd.h> first.
38932         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
38933         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
38934         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
38935         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38936         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
38937
38938         * lib/dup2.c: Include <unistd.h> first.
38939         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
38940         HAVE_DUP2.
38941         * modules/dup2 (Depends-on): Add unistd.
38942         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38943
38944         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
38945         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
38946         REPLACE_CHOWN. Don't define chown as a macro here.
38947         * modules/chown (Depends-on): Add unistd.
38948         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
38949
38950         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
38951         Add definition for GL_LINK_WARNING.
38952         (chown, dup2): New declarations.
38953         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
38954         link warning.
38955         (ftruncate): New declaration.
38956         (getcwd): New declaration, taken from old getcwd.h.
38957         (getlogin_r): New declaration, taken from old getlogin_r.h.
38958         (readlink): New declaration.
38959         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
38960         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
38961         (gl_PREREQ_UNISTD): Remove macro.
38962         (gl_UNISTD_MODULE_INDICATOR): New macro.
38963         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
38964         many new variables. Don't set UNISTD_H.
38965         * modules/unistd (Description): Change.
38966         (Depends-on): Add link-warning.
38967         (configure.ac): Update.
38968         (Makefile.am): Create unistd.h always. Substitute many new variables
38969         into it.
38970
38971 2007-02-18  Bruno Haible  <bruno@clisp.org>
38972
38973         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
38974         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
38975         HAVE_GETSUBOPT.
38976         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
38977         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
38978         * lib/getsubopt.h: Remove file.
38979         * modules/getsubopt (Files): Remove lib/getsubopt.h.
38980         (Depends-on): Add stdlib.
38981         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
38982         (Includes): Use <stdlib.h> instead of getsubopt.h.
38983         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
38984         Set HAVE_GETSUBOPT.
38985         * lib/getsubopt.c: Don't include getsubopt.h.
38986
38987 2007-02-18  Bruno Haible  <bruno@clisp.org>
38988
38989         * modules/fchdir (Depends-on): Add dup2.
38990
38991 2007-02-18  Bruno Haible  <bruno@clisp.org>
38992
38993         * lib/stdlib_.h: Handle glibc's special invocation convention
38994         specially.
38995
38996 2007-02-18  Bruno Haible  <bruno@clisp.org>
38997
38998         * modules/stdlib-tests: New file.
38999         * tests/test-stdlib.c: New file.
39000
39001         * modules/mkstemp (Files): Remove lib/mkstemp.h.
39002         (Depends-on): Add stdlib.
39003         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
39004         (Includes): Use <stdlib.h> instead of mkstemp.h.
39005         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
39006         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
39007         * lib/mkstemp.c: Don't include mkstemp.h.
39008         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
39009         * lib/stdlib--.h: Don't include mkstemp.h.
39010
39011         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
39012         (Depends-on): Add stdlib.
39013         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
39014         (Includes): Use <stdlib.h> instead of mkdtemp.h.
39015         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
39016         HAVE_MKDTEMP.
39017         * lib/mkdtemp.c: Don't include mkdtemp.h.
39018         * lib/clean-temp.c: Don't include mkdtemp.h.
39019
39020         * modules/exit (Files): Remove lib/exit.h.
39021         (Depends-on): Add stdlib.
39022         (Makefile.am): Remove lib_SOURCES.
39023         (Include): Use <stdlib.h> instead of exit.h.
39024         * lib/argmatch.c: Don't include exit.h.
39025         * lib/execute.c: Likewise.
39026         * lib/pagealign_alloc.c: Likewise.
39027         * lib/pipe.c: Likewise.
39028         * lib/wait-process.c: Likewise.
39029         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
39030         * lib/exitfail.c: Likewise.
39031         * lib/savewd.c: Likewise.
39032         * lib/xsetenv.c: Likewise.
39033
39034         * modules/stdlib: New file.
39035         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
39036         and extra comments about mkstemp().
39037         * lib/exit.h: Remove file.
39038         * lib/mkdtemp.h: Remove file.
39039         * lib/mkstemp.h: Remove file.
39040         * m4/stdlib_h.m4: New file.
39041         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
39042
39043 2007-02-18  Bruno Haible  <bruno@clisp.org>
39044
39045         * modules/math-tests: New file.
39046         * tests/test-math.c: New file.
39047
39048         * modules/math: New file.
39049         * modules/mathl (Files): Remove lib/mathl.h.
39050         (Depends-on): Add math.
39051         (Makefile.am): Don't mention mathl.h.
39052         (Include): Use <math.h> instead of mathl.h.
39053         * lib/math_.h: New file.
39054         * lib/mathl.h: Remove file.
39055         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
39056         mathl.h.
39057         * lib/asinl.c: Likewise.
39058         * lib/atanl.c: Likewise.
39059         * lib/ceill.c: Likewise.
39060         * lib/cosl.c: Likewise.
39061         * lib/expl.c: Likewise.
39062         * lib/floorl.c: Likewise.
39063         * lib/frexpl.c: Likewise.
39064         * lib/ldexpl.c: Likewise.
39065         * lib/logl.c: Likewise.
39066         * lib/sincosl.c: Likewise.
39067         * lib/sinl.c: Likewise.
39068         * lib/sqrtl.c: Likewise.
39069         * lib/tanl.c: Likewise.
39070         * lib/trigl.c: Likewise.
39071         * m4/math_h.m4: New file.
39072         * MODULES.html.sh (Mathematics): Add math.
39073
39074 2007-02-17  Bruno Haible  <bruno@clisp.org>
39075
39076         * modules/wctype-tests: New file.
39077         * tests/test-wctype.c: New file.
39078
39079         * modules/wchar-tests: New file.
39080         * tests/test-wchar.c: New file.
39081
39082         * modules/unistd-tests: New file.
39083         * tests/test-unistd.c: New file.
39084
39085         * modules/time-tests: New file.
39086         * tests/test-time.c: New file.
39087
39088         * modules/sysexits-tests: New file.
39089         * tests/test-sysexits.c: New file.
39090
39091         * modules/sys_time-tests: New file.
39092         * tests/test-sys_time.c: New file.
39093
39094         * modules/sys_stat-tests: New file.
39095         * tests/test-sys_stat.c: New file.
39096
39097         * modules/sys_socket-tests: New file.
39098         * tests/test-sys_socket.c: New file.
39099
39100         * modules/sys_select-tests: New file.
39101         * tests/test-sys_select.c: New file.
39102
39103         * modules/string-tests: New file.
39104         * tests/test-string.c: New file.
39105
39106         * modules/stdbool-tests: New file.
39107         * tests/test-stdbool.c: New file.
39108
39109         * modules/netinet_in-tests: New file.
39110         * tests/test-netinet_in.c: New file.
39111
39112         * modules/inttypes-tests: New file.
39113         * tests/test-inttypes.c: New file.
39114
39115         * modules/fcntl-tests: New file.
39116         * tests/test-fcntl.c: New file.
39117
39118         * modules/byteswap-tests: New file.
39119         * tests/test-byteswap.c: New file.
39120
39121         * modules/arpa_inet-tests: New file.
39122         * tests/test-arpa_inet.c: New file.
39123
39124 2007-02-17  Bruno Haible  <bruno@clisp.org>
39125
39126         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
39127         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
39128         if the corresponding module is not enabled. Emit link warnings if
39129         the function is used nevertheless.
39130         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
39131         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
39132         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
39133         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
39134         * modules/inttypes (Depends-on): Add link-warning.
39135         (Makefile.am): Copy the contents of build-aux/link-warning.h into
39136         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
39137         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
39138         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
39139         * modules/imaxdiv (configure.ac): Likewise.
39140         * modules/strtoimax (configure.ac): Likewise.
39141         * modules/strtoumax (configure.ac): Likewise.
39142
39143 2007-02-17  Bruno Haible  <bruno@clisp.org>
39144
39145         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
39146         gl_STRING_MODULE_INDICATOR_DEFAULTS.
39147         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
39148         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
39149
39150 2007-02-17  Bruno Haible  <bruno@clisp.org>
39151
39152         * modules/link-warning: New file.
39153         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
39154         * lib/string_.h (GL_LINK_WARNING): Remove definition.
39155         * modules/string (Depends-on): Add link-warning.
39156         (Makefile.am): Copy the contents of build-aux/link-warning.h into
39157         string.h.
39158         * MODULES.html.sh (Support for building libraries and executables): Add
39159         link-warning.
39160
39161 2007-02-17  Bruno Haible  <bruno@clisp.org>
39162
39163         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
39164         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
39165         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
39166         long lines.
39167
39168 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
39169             Bruno Haible  <bruno@clisp.org>
39170
39171         * modules/tmpfile: New file.
39172         * lib/tmpfile.c: New file.
39173         * m4/tmpfile.m4: New file.
39174         * MODULES.html.sh (func_all_modules): New section "Input/output".
39175
39176 2007-02-15  Bruno Haible  <bruno@clisp.org>
39177
39178         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
39179         (supports_delete_on_close): New function.
39180         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
39181
39182 2007-02-14  Bruno Haible  <bruno@clisp.org>
39183
39184         * modules/mbspcasecmp-tests: New file.
39185         * tests/test-mbspcasecmp.sh: New file.
39186         * tests/test-mbspcasecmp.c: New file.
39187
39188         New module mbspcasecmp.
39189         * modules/mbspcasecmp: New file.
39190         * lib/mbspcasecmp.c: New file.
39191         * lib/string_.h (strncasecmp): Change warning message.
39192         (mbspcasecmp): New declaration.
39193         * m4/mbspcasecmp.m4: New file.
39194         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39195         GNULIB_MBSPCASECMP.
39196         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
39197         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
39198
39199 2007-02-14  Bruno Haible  <bruno@clisp.org>
39200
39201         * modules/mbsncasecmp-tests: New file.
39202         * tests/test-mbsncasecmp.sh: New file.
39203         * tests/test-mbsncasecmp.c: New file.
39204
39205         New module mbsncasecmp.
39206         * modules/mbsncasecmp: New file.
39207         * lib/mbsncasecmp.c: New file.
39208         * lib/string_.h (mbsncasecmp): New declaration.
39209         * m4/mbsncasecmp.m4: New file.
39210         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39211         GNULIB_MBSNCASECMP.
39212         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
39213         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
39214
39215 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
39216
39217         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
39218         Verify that it doesn't overlap with our flags.
39219         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
39220         do not have the desired effect in multibyte locales; instead, use
39221         mbscasecmp.
39222         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
39223         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
39224         we don't require GNU fnmatch ourselves (if our users require it, they
39225         should do so explicitly).
39226
39227         Fix regex code so it doesn't rely on strcasecmp.
39228         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
39229         Otherwise, include gnulib's langinfo.h.
39230         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
39231         undesirable behavior in non-C locales.  Instead, rely on localecharset.
39232         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
39233         * modules/regex (FILES): Remove m4/codeset.m4.
39234         (Depends-on): Add localcharset.  Remove strcase.
39235
39236 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
39237
39238         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
39239         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
39240
39241 2007-02-13  Bruno Haible  <bruno@clisp.org>
39242
39243         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
39244         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
39245
39246 2007-02-12  Bruno Haible  <bruno@clisp.org>
39247
39248         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
39249         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
39250         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
39251         time warning rather than a link error.
39252
39253 2007-02-12  Bruno Haible  <bruno@clisp.org>
39254
39255         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
39256         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
39257         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
39258
39259 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
39260
39261         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
39262         args, not 2.
39263
39264 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
39265
39266         New module 'time', so that apps can include <time.h> as per
39267         POSIX and GNU instead of separate include files like time_r.h
39268         and timegm.h.  This implementation tries out a simpler approach
39269         for replacing decls in standard include files (as compared to
39270         the string module), somewhat as an experiment.
39271
39272         * config/srclist.txt: Comment out mktime.c for now.
39273         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
39274         since it doesn't apply any more.  Use generic wording instead.
39275         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
39276         'time'.
39277         * lib/time_.h, m4/time_h.m4, modules/time: New files.
39278         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
39279         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
39280         Don't include <sys/types.h>; no longer needed since we assume C89.
39281         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
39282         * lib/strftime.c: Likewise.
39283         * lib/time_r.c: Likewise.
39284         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
39285         * lib/nanosleep.c: Include <time.h> first, to check interface.
39286         * lib/strptime.c: Likewise.
39287         * lib/time_r.c: Likewise.
39288         * lib/timegm.c: Likewise.
39289         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
39290         needed.
39291         * lib/timegm.c: Don't include timegm.h; no longer needed.
39292         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
39293         time.h now handles any problems in that area.
39294         (struct timespec, nanosleep): Remove; time.h now arranges for these.
39295         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
39296         that time.h defines struct timespec.
39297         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
39298         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
39299         handles that.
39300         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
39301         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
39302         needed.  Set REPLACE_LOCALTIME.
39303         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
39304         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
39305         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
39306         nanosleep; time_h.m4 now does that.  Don't require
39307         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
39308         module handles this now.
39309         * modules/getdate (Depends-on): Remove timespec.  Add time.
39310         * modules/nanosleep (Depends-on): Likewise.
39311         * modules/stat-time (Depends-on): Likewise.
39312         * modules/nanosleep (Include): Include time.h, not timespec.h.
39313         * modules/strptime (Files): Remove lib/strptime.h.
39314         (Depends-on): Add extensions, time.
39315         (Include): Include time.h, not strptime.h.
39316         * modules/time_r (Files): Remove lib/time_r.h.
39317         (Depends-on): Add time.
39318         (Include): Include time.h, not time_r.h.
39319         * modules/timegm: Likewise.
39320         * modules/timespec (Description): Now does timespec-related decls
39321         of our own, instead of struct timespec itself.
39322         (Depends-on): Add time; remove extensions.
39323         (Maintainer): Add self.
39324         * modules/utimecmp (Depends-on): Add time; remove timespec.
39325         * modules/utimens (Depends-on): Likewise.
39326         * modules/xnanosleep (Depends-on): Likewise.
39327
39328 2007-02-11  Bruno Haible  <bruno@clisp.org>
39329
39330         * lib/c-strstr.c: Include allocsa.h.
39331         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
39332         * lib/c-strcasestr.c: Include allocsa.h.
39333         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
39334         * lib/strcasestr.c: Include allocsa.h.
39335         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
39336         * lib/mbsstr.c: Include allocsa.h.
39337         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
39338         allocsa/freesa instead of malloc/free.
39339         * lib/mbscasestr.c: Include allocsa.h.
39340         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
39341         allocsa/freesa instead of malloc/free.
39342         * modules/c-strstr (Depends-on): Add allocsa.
39343         * modules/c-strcasestr (Depends-on): Likewise.
39344         * modules/strcasestr (Depends-on): Likewise.
39345         * modules/mbsstr (Depends-on): Likewise.
39346         * modules/mbscasestr (Depends-on): Likewise.
39347
39348 2007-02-11  Bruno Haible  <bruno@clisp.org>
39349
39350         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
39351
39352         * modules/mbsspn-tests: New file.
39353         * tests/test-mbsspn.sh: New file.
39354         * tests/test-mbsspn.c: New file.
39355
39356 2007-02-11  Bruno Haible  <bruno@clisp.org>
39357
39358         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
39359
39360         * modules/mbspbrk-tests: New file.
39361         * tests/test-mbspbrk.sh: New file.
39362         * tests/test-mbspbrk.c: New file.
39363
39364 2007-02-11  Bruno Haible  <bruno@clisp.org>
39365
39366         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
39367         unneeded cast.
39368
39369         * modules/mbscspn-tests: New file.
39370         * tests/test-mbscspn.sh: New file.
39371         * tests/test-mbscspn.c: New file.
39372
39373 2007-02-11  Bruno Haible  <bruno@clisp.org>
39374
39375         * modules/mbscasecmp-tests: New file.
39376         * tests/test-mbscasecmp.sh: New file.
39377         * tests/test-mbscasecmp.c: New file.
39378
39379 2007-02-11  Bruno Haible  <bruno@clisp.org>
39380
39381         Ensure O(n) worst-case complexity of mbscasestr.
39382         * lib/mbscasestr.c: Include stdbool.h.
39383         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
39384         functions.
39385         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
39386         the bookkeeping indicates that it's worth it.
39387         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
39388
39389         * modules/mbscasestr-tests: New file.
39390         * tests/test-mbscasestr1.c: New file.
39391         * tests/test-mbscasestr2.sh: New file.
39392         * tests/test-mbscasestr2.c: New file.
39393         * tests/test-mbscasestr3.sh: New file.
39394         * tests/test-mbscasestr3.c: New file.
39395         * tests/test-mbscasestr4.sh: New file.
39396         * tests/test-mbscasestr4.c: New file.
39397         * m4/locale-tr.m4: New file.
39398
39399 2007-02-11  Bruno Haible  <bruno@clisp.org>
39400
39401         Ensure O(n) worst-case complexity of mbsstr.
39402         * lib/mbsstr.c: Include stdbool.h.
39403         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
39404         functions.
39405         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
39406         bookkeeping indicates that it's worth it.
39407         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
39408
39409         * modules/mbsstr-tests: New file.
39410         * tests/test-mbsstr1.c: New file.
39411         * tests/test-mbsstr2.sh: New file.
39412         * tests/test-mbsstr2.c: New file.
39413         * tests/test-mbsstr3.sh: New file.
39414         * tests/test-mbsstr3.c: New file.
39415         * m4/locale-fr.m4: New file.
39416
39417 2007-02-11  Bruno Haible  <bruno@clisp.org>
39418
39419         * lib/mbsrchr.c (mbsrchr): Fix bug.
39420
39421         * modules/mbsrchr-tests: New file.
39422         * tests/test-mbsrchr.sh: New file.
39423         * tests/test-mbsrchr.c: New file.
39424
39425 2007-02-11  Bruno Haible  <bruno@clisp.org>
39426
39427         * lib/mbschr.c (mbschr): Fix bug.
39428
39429         * modules/mbschr-tests: New file.
39430         * tests/test-mbschr.sh: New file.
39431         * tests/test-mbschr.c: New file.
39432         * m4/locale-zh.m4: New file.
39433
39434 2007-02-11  Bruno Haible  <bruno@clisp.org>
39435
39436         Support for copying multibyte string iterators.
39437         * lib/mbiter.h: Include <string.h>.
39438         (mbiter_multi_copy): New function.
39439         (mbi_copy): New macro.
39440         * lib/mbuiter.h: Include <string.h>.
39441         (mbuiter_multi_copy): New function.
39442         (mbui_copy): New macro.
39443
39444 2007-02-11  Bruno Haible  <bruno@clisp.org>
39445
39446         New module mbslen.
39447         * modules/mbslen: New file.
39448         * lib/mbslen.c: New file.
39449         * lib/string_.h (mbslen): New declaration.
39450         * m4/mbslen.m4: New file.
39451         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39452         GNULIB_MBSLEN.
39453         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
39454         * MODULES.html.sh (Internationalization functions): Add mbslen.
39455
39456 2007-02-11  Bruno Haible  <bruno@clisp.org>
39457
39458         Ensure O(n) worst-case complexity of strcasestr substitute.
39459         * lib/strcasestr.c: Include stdbool.h.
39460         (knuth_morris_pratt): New function.
39461         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
39462         bookkeeping indicates that it's worth it.
39463         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
39464
39465         * modules/strcasestr-tests: New file.
39466         * tests/test-strcasestr.c: New file.
39467
39468 2007-02-11  Bruno Haible  <bruno@clisp.org>
39469
39470         Ensure O(n) worst-case complexity of c_strcasestr.
39471         * lib/c-strcasestr.c: Include stdbool.h, string.h.
39472         (knuth_morris_pratt): New function.
39473         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
39474         the bookkeeping indicates that it's worth it.
39475         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
39476
39477         * modules/c-strcasestr-tests: New file.
39478         * tests/test-c-strcasestr.c: New file.
39479
39480 2007-02-11  Bruno Haible  <bruno@clisp.org>
39481
39482         Ensure O(n) worst-case complexity of c_strstr.
39483         * lib/c-strstr.c: Include stdbool.h, string.h.
39484         (knuth_morris_pratt): New function.
39485         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
39486         bookkeeping indicates that it's worth it.
39487         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
39488
39489         * lib/c-strstr.c: Complete rewrite for maintainability.
39490
39491         * modules/c-strstr-tests: New file.
39492         * tests/test-c-strstr.c: New file.
39493
39494 2007-02-11  Bruno Haible  <bruno@clisp.org>
39495
39496         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
39497         5.2.1 and earlier, whereby \055 was treated just like the range
39498         delimiter '-'.
39499         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
39500
39501 2007-02-08  Bruno Haible  <bruno@clisp.org>
39502
39503         * modules/regex (Depends-on): Add stdbool.
39504         Reported by Dalibor Topic <robilad@kaffe.org>.
39505
39506 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
39507
39508         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
39509         Prefer returning from main to exiting from it.
39510         Remove unnecessary parens after sizeof.
39511
39512 2007-02-05  Bruno Haible  <bruno@clisp.org>
39513
39514         New module mbssep.
39515         * modules/mbssep: New file.
39516         * lib/mbssep.c: New file.
39517         * lib/string_.h (strsep): Add a conditional link warning.
39518         (mbssep): New declaration.
39519         * m4/mbssep.m4: New file.
39520         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39521         GNULIB_MBSSEP.
39522         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
39523         * MODULES.html.sh (Internationalization functions): Add mbssep.
39524
39525 2007-02-05  Bruno Haible  <bruno@clisp.org>
39526
39527         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
39528         Optimize search in case of 1 delimiter.
39529
39530 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
39531
39532         * lib/acl.h: Include sys/types.h before sys/acl.h.
39533
39534 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
39535
39536         Merge upstream fix for glibc bugzilla #3957:
39537
39538         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
39539
39540         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
39541         bit for RE_HAT_LISTS_NOT_NEWLINE.
39542         (build_charclass_op): Remove bogus comment.
39543
39544 2007-02-05  Simon Josefsson  <simon@josefsson.org>
39545
39546         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
39547
39548 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
39549
39550         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
39551         * lib/memmem.c [!defined _LIBC]: Include config.h.
39552
39553 2007-02-04  Bruno Haible  <bruno@clisp.org>
39554
39555         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
39556         warning message.
39557
39558 2007-02-04  Bruno Haible  <bruno@clisp.org>
39559
39560         New module mbstok_r.
39561         * modules/mbstok_r: New file.
39562         * lib/mbstok_r.c: New file.
39563         * lib/string_.h (strtok_r): Change argument names to match the
39564         comments. Add a conditional link warning.
39565         (mbstok_r): New declaration.
39566         * m4/mbstok_r.m4: New file.
39567         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39568         GNULIB_MBSTOK_R.
39569         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
39570         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
39571
39572 2007-02-04  Bruno Haible  <bruno@clisp.org>
39573
39574         New module mbsspn.
39575         * modules/mbsspn: New file.
39576         * lib/mbsspn.c: New file.
39577         * lib/string_.h (strspn): Add a conditional link warning.
39578         (mbsspn): New declaration.
39579         * m4/mbsspn.m4: New file.
39580         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39581         GNULIB_MBSSPN.
39582         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
39583         * MODULES.html.sh (Internationalization functions): Add mbsspn.
39584
39585 2007-02-04  Bruno Haible  <bruno@clisp.org>
39586
39587         New module mbspbrk.
39588         * modules/mbspbrk: New file.
39589         * lib/mbspbrk.c: New file.
39590         * lib/string_.h (strpbrk): Add a conditional link warning.
39591         (mbspbrk): New declaration.
39592         * m4/mbspbrk.m4: New file.
39593         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39594         GNULIB_MBSPBRK.
39595         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
39596         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
39597
39598 2007-02-04  Bruno Haible  <bruno@clisp.org>
39599
39600         New module mbscspn.
39601         * modules/mbscspn: New file.
39602         * lib/mbscspn.c: New file.
39603         * lib/string_.h (strcspn): Add a conditional link warning.
39604         (mbscspn): New declaration.
39605         * m4/mbscspn.m4: New file.
39606         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39607         GNULIB_MBSCSPN.
39608         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
39609         * MODULES.html.sh (Internationalization functions): Add mbscspn.
39610
39611 2007-02-04  Bruno Haible  <bruno@clisp.org>
39612
39613         New module mbscasestr, reduced goal of strcasestr.
39614         * modules/mbscasestr: New file.
39615         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
39616         (mbscasestr): Renamed from strcasestr.
39617         * lib/strcasestr.c: Don't include mbuiter.h.
39618         (strcasestr): Remove support for multibyte locales.
39619         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
39620         Change the conditional link warning.
39621         (mbscasestr): New declaration.
39622         * m4/mbscasestr.m4: New file.
39623         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
39624         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
39625         REPLACE_STRCASESTR.
39626         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
39627         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
39628         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
39629         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
39630         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
39631         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
39632         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
39633         (Depends-on): Remove mbuiter.
39634         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
39635
39636 2007-02-04  Bruno Haible  <bruno@clisp.org>
39637
39638         Simplify handling of strncasecmp.
39639         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
39640         the conditional link warning.
39641         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
39642         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
39643         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
39644         * modules/strcase (configure.ac): Don't invoke
39645         gl_STRING_MODULE_INDICATOR.
39646         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
39647
39648 2007-02-04  Bruno Haible  <bruno@clisp.org>
39649
39650         New module mbscasecmp, reduced goal of strcasecmp.
39651         * modules/mbscasecmp: New file.
39652         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
39653         (mbscasecmp): Renamed from strcasecmp.
39654         * lib/strcasecmp.c: Don't include mbuiter.h.
39655         (strcasecmp): Remove support for multibyte locales.
39656         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
39657         Change the conditional link warning.
39658         (mbscasecmp): New declaration.
39659         * m4/mbscasecmp.m4: New file.
39660         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
39661         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
39662         REPLACE_STRCASECMP.
39663         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
39664         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39665         GNULIB_MBSCASECMP.
39666         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
39667         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
39668         * modules/strcase (Files): Remove m4/mbrtowc.m4.
39669         (Depends-on): Remove mbuiter.
39670         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
39671
39672 2007-02-04  Bruno Haible  <bruno@clisp.org>
39673
39674         New module mbsstr. Remove module strstr.
39675         * modules/mbsstr: New file.
39676         * modules/strstr: Remove file.
39677         * lib/mbsstr.c: Renamed from lib/strstr.c.
39678         (mbsstr): Renamed from strstr.
39679         * lib/string_.h (strstr): Remove declaration. Change the conditional
39680         link warning.
39681         (mbsstr): New declaration.
39682         * m4/mbsstr.m4: New file.
39683         * m4/strstr.m4: Remove file.
39684         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
39685         REPLACE_STRSTR.
39686         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
39687         Don't initialize GNULIB_STRSTR.
39688         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
39689         substitute GNULIB_STRSTR and REPLACE_STRSTR.
39690         * MODULES.html.sh (Internationalization functions): Add mbsstr.
39691         (Support for systems lacking ANSI C 89): Remove strstr.
39692
39693 2007-02-04  Bruno Haible  <bruno@clisp.org>
39694
39695         New module mbsrchr.
39696         * modules/mbsrchr: New file.
39697         * lib/mbsrchr.c: New file.
39698         * lib/string_.h (strrchr): Add a conditional link warning.
39699         (mbsrchr): New declaration.
39700         * m4/mbsrchr.m4: New file.
39701         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39702         GNULIB_MBSRCHR.
39703         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
39704         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
39705
39706 2007-02-04  Bruno Haible  <bruno@clisp.org>
39707
39708         New module mbschr.
39709         * modules/mbschr: New file.
39710         * lib/mbschr.c: New file.
39711         * lib/string_.h (strchr): Add a conditional link warning.
39712         (mbschr): New declaration.
39713         * m4/mbschr.m4: New file.
39714         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
39715         GNULIB_MBSCHR.
39716         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
39717         * MODULES.html.sh (Internationalization functions): Add mbschr.
39718
39719 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
39720
39721         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
39722
39723         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
39724
39725 2007-02-04  Bruno Haible  <bruno@clisp.org>
39726
39727         New module description section 'configure.ac-early'.
39728         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
39729         (func_get_autoconf_early_snippet): New function.
39730         (func_import, func_create_testdir): Use it. Remove special cases for
39731         modules 'extensions' and 'lock'.
39732         * modules/extensions (configure.ac-early): Require
39733         gl_USE_SYSTEM_EXTENSIONS.
39734         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
39735
39736 2007-02-04  Bruno Haible  <bruno@clisp.org>
39737
39738         Make use of gcj-4.3's -fsource and -ftarget option.
39739         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
39740         and if so try the options -fsource and -ftarget.
39741         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
39742         source_version, ftarget_option, target_version arguments.
39743         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
39744         (is_envjavac_oldgcj_14_14_usable): Renamed from
39745         is_envjavac_gcj_14_14_usable.
39746         (is_envjavac_oldgcj_14_13_usable): Renamed from
39747         is_envjavac_gcj_14_13_usable.
39748         (is_gcj_present): Update.
39749         (is_gcj_43, is_gcj43_usable): New functions.
39750         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
39751         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
39752         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
39753         try the options -fsource and -ftarget.
39754
39755 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
39756
39757         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
39758         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
39759         larger value.
39760
39761 2007-02-03  Jim Meyering  <jim@meyering.net>
39762
39763         Give tools a better chance to allocate space for very large buffers.
39764         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
39765
39766         Make pwd and readlink work also when run with an unreadable parent dir
39767         on systems with openat support.
39768         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
39769         provided getcwd function, even when we have openat support.
39770         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
39771
39772 2007-02-02  Bruno Haible  <bruno@clisp.org>
39773
39774         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
39775         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
39776         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
39777         portability problems if one of these functions is only used on specific
39778         platforms.
39779         Reported by Paul Eggert.
39780
39781 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
39782
39783         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
39784         is causing more trouble than it's curing.
39785         * lib/regex_internal.h (__mempcpy): Remove.
39786         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
39787         (and make the code a tad smaller to boot).
39788         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
39789
39790 2007-02-02  Jim Meyering  <jim@meyering.net>
39791
39792         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
39793         section, not in the Makefile.am: one.
39794
39795 2007-02-02  Eric Blake  <ebb9@byu.net>
39796
39797         * lib/strchrnul.c: Always include config.h first.
39798
39799         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
39800         gnulib strstr is not necessary here.
39801
39802 2007-02-02  Simon Josefsson  <simon@josefsson.org>
39803
39804         * m4/socklen.m4: Fix typo.
39805
39806 2007-02-02  Eric Blake  <ebb9@byu.net>
39807
39808         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
39809         * modules/netinet_in (Makefile.am): Likewise.
39810
39811 2007-02-01  Bruno Haible  <bruno@clisp.org>
39812
39813         * lib/string_.h (GL_LINK_WARNING): New macro.
39814         (strcasecmp, strstr, strcasestr): If provided by the system,
39815         conditionally define as a macro that leads to a warning instead of to
39816         an error.
39817         (strncasecmp): Conditionally define as a macro that leads to a warning.
39818
39819 2007-02-01  Karl Berry  <karl@gnu.org>
39820
39821         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
39822
39823 2007-02-01  Bruno Haible  <bruno@clisp.org>
39824
39825         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
39826         renamings.
39827
39828 2007-02-01  Eric Blake  <ebb9@byu.net>
39829
39830         * modules/regex (Depends-on): Revert dependence on mempcpy.
39831         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
39832         module's definition of mempcpy.
39833         Reported by Paul Eggert.
39834
39835 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
39836
39837         * lib/string_.h: If the gnulib module XYZ is not present, undefine
39838         the symbol XYZ before redefining it.  This fixes a problem with
39839         programs that don't use XYZ, when compiled on systems that define
39840         XYZ to something else.
39841
39842 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
39843
39844         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
39845         occurs when "mkdir -m foo" creates a setgid directory that is (1)
39846         writeable to group or other and (2) is intended to have a special
39847         mode bit that is set or cleared.  In such a case, the directory
39848         should be neither group- nor other-writeable until the special
39849         mode bits are right.
39850
39851 2007-01-31  Eric Blake  <ebb9@byu.net>
39852
39853         * modules/mountlist (Depends-on): Add strstr.
39854
39855         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
39856         bug.
39857         * modules/string (Makefile.am): Remove redundant replacement.
39858         * modules/regex (Depends-on): Add mempcpy.
39859
39860 2007-01-31  Bruno Haible  <bruno@clisp.org>
39861
39862         New module description field 'Link'.
39863         * gnulib-tool (func_usage): Document --extract-link-directive.
39864         (sed_extract_prog): Recognize 'Link' directive.
39865         (func_get_link_directive): New function.
39866         (func_import): Show summary of link directives.
39867         Handle --extract-link-directive option.
39868         * modules/acl (Link): New section.
39869         * modules/clock-time (Link): New section.
39870         * modules/euidaccess (Link): New section.
39871         * modules/gettext (Link): New section.
39872         * modules/iconv (Link): New section.
39873         * modules/lock (Link): New section.
39874         * modules/nanosleep (Link): New section.
39875         * modules/readline (Link): New section.
39876
39877 2007-01-27  Bruno Haible  <bruno@clisp.org>
39878
39879         Enforce the use of gnulib modules for unportable <string.h> functions.
39880         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
39881         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
39882         (gl_HEADER_STRING_H_BODY): Require it.
39883         * lib/string_.h: If the gnulib module XYZ is not present, redefine
39884         the symbol XYZ to one that gives a link error.
39885         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
39886         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
39887         * modules/mempcpy (configure.ac): Likewise.
39888         * modules/memrchr (configure.ac): Likewise.
39889         * modules/stpcpy (configure.ac): Likewise.
39890         * modules/stpncpy (configure.ac): Likewise.
39891         * modules/strcase (configure.ac): Likewise.
39892         * modules/strcasestr (configure.ac): Likewise.
39893         * modules/strchrnul (configure.ac): Likewise.
39894         * modules/strdup (configure.ac): Likewise.
39895         * modules/strndup (configure.ac): Likewise.
39896         * modules/strnlen (configure.ac): Likewise.
39897         * modules/strpbrk (configure.ac): Likewise.
39898         * modules/strsep (configure.ac): Likewise.
39899         * modules/strstr (configure.ac): Likewise.
39900         * modules/strtok_r (configure.ac): Likewise.
39901
39902 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
39903
39904         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
39905
39906 2007-01-30  Jim Meyering  <jim@meyering.net>
39907
39908         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
39909
39910 2007-01-29  Bruno Haible  <bruno@clisp.org>
39911
39912         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
39913         * lib/execute.c: Likewise.
39914         * lib/pipe.c: Likewise.
39915         * lib/printf-args.h: Likewise.
39916         * lib/printf-args.c: Likewise.
39917         * lib/printf-parse.c: Likewise.
39918         * lib/vasnprintf.c: Likewise.
39919
39920 2007-01-29  Eric Blake  <ebb9@byu.net>
39921
39922         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
39923         declaration.
39924
39925 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
39926
39927         * lib/strptime.h (strptime): Use 'restrict' for args where
39928         POSIX requires this.
39929         * lib/strptime.c (strptime): Likewise.
39930         Change license notice from LGPL to GPL, since gnulib-tool will
39931         change this as needed.
39932         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
39933         defined.
39934         Include "strptime.h" first, to check interface.
39935         Do not #undef _LIBC and _NL_CURRENT.
39936         Do not include <stdlib.h>; no longer needed.
39937         Include "time_r.h" and declare ptime_locale_status
39938         only if _LIBC is not defined.
39939         (__P): Remove unused macro.
39940         (match_string): Bring back glibc version, but use it only if _LIBC
39941         is defined.
39942         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
39943         Remove unnecessary assertion and abort() call.
39944         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
39945         * m4/strptime.m4: Fix serial number comment.
39946         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
39947         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
39948         (Depends-on): Add time_r.
39949
39950 2007-01-29  Bruno Haible  <bruno@clisp.org>
39951
39952         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
39953         strptime.
39954         * modules/strptime (Depends-on): Add stdbool.
39955         * lib/strptime.h: Include <time.h> always. Add comments.
39956
39957 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
39958
39959         * modules/strptime: New file.
39960         * lib/strptime.h: New file.
39961         * lib/strptime.c: New file.
39962         * m4/strptime.m4: New file.
39963
39964 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
39965
39966         * MODULES.html.sh: New module mpsort.
39967         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
39968
39969         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
39970         a circularity problem with HP-UX ia64 reported by Bob Proulx in
39971         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
39972         All uses changed.
39973         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
39974         All uses changed.
39975         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
39976         to _Restrict_.
39977         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
39978         the parameter matches the prototype.
39979
39980 2007-01-28  Jim Meyering  <jim@meyering.net>
39981
39982         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
39983         sys/time.h here, reverting that part of the previous patch:
39984         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
39985
39986 2007-01-28  Bruno Haible  <bruno@clisp.org>
39987
39988         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
39989         value of $(SYS_TIME_H).
39990         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
39991         remove it conditionally, too. [added by Jim Meyering]
39992         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
39993         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
39994         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
39995         GETTIMEOFDAY_REPLACEMENT to 1.
39996
39997 2007-01-28  Bruno Haible  <bruno@clisp.org>
39998
39999         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
40000         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
40001         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
40002         Set UNISTD_H instead of UNISTD_H2.
40003         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
40004
40005 2007-01-28  Bruno Haible  <bruno@clisp.org>
40006
40007         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
40008         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
40009
40010 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
40011
40012         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
40013         (func_create_testdir): Ensure C locale for `grep' and `tr'
40014         character ranges.
40015         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
40016         ACLOCAL_AMFLAGS parsing state machine.
40017
40018 2007-01-27  Bruno Haible  <bruno@clisp.org>
40019
40020         * modules/unistr/base: Update.
40021
40022 2007-01-27  Bruno Haible  <bruno@clisp.org>
40023
40024         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
40025         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
40026         * modules/unistr/u32-mbtouc-unsafe: Renamed from
40027         modules/unistr/u32-mbtouc.
40028         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
40029         * lib/unistr.h: Update.
40030         * lib/linebreak.c: Update.
40031         * modules/unistr/u32-mbtouc: Renamed from
40032         modules/unistr/u32-mbtouc-safe.
40033         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
40034         * lib/unistr.h: Update.
40035         * lib/unistr/u32-to-u8.c: Update.
40036         * lib/unistr/u32-to-u16.c: Update.
40037
40038 2007-01-27  Bruno Haible  <bruno@clisp.org>
40039
40040         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
40041         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
40042         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
40043         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
40044         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
40045         * modules/unistr/u16-mbtouc-unsafe: Renamed from
40046         modules/unistr/u16-mbtouc.
40047         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
40048         * lib/unistr.h: Update.
40049         * lib/linebreak.c: Update.
40050         * modules/linebreak: Update.
40051         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
40052         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
40053         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
40054         * modules/unistr/u16-mbtouc: Renamed from
40055         modules/unistr/u16-mbtouc-safe.
40056         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
40057         * lib/unistr.h: Update.
40058         * lib/unistr/u16-to-u8.c: Update.
40059         * modules/unistr/u16-to-u8: Update.
40060         * lib/unistr/u16-to-u32.c: Update.
40061         * modules/unistr/u16-to-u32: Update.
40062
40063 2007-01-27  Bruno Haible  <bruno@clisp.org>
40064
40065         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
40066         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
40067         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
40068         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
40069         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
40070         * modules/unistr/u8-mbtouc-unsafe: Renamed from
40071         modules/unistr/u8-mbtouc.
40072         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
40073         * lib/unistr.h: Update.
40074         * lib/striconveh.c: Update.
40075         * modules/striconveh: Update.
40076         * lib/linebreak.c: Update.
40077         * modules/linebreak: Update.
40078         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
40079         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
40080         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
40081         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
40082         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
40083         * lib/unistr.h: Update.
40084         * lib/striconveh.c: Update.
40085         * modules/striconveh: Update.
40086         * lib/unistr/u8-to-u16.c: Update.
40087         * modules/unistr/u8-to-u16: Update.
40088         * lib/unistr/u8-to-u32.c: Update.
40089         * modules/unistr/u8-to-u32: Update.
40090
40091 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
40092
40093         Sync from Libtool.
40094         * lib/argz.c: Do not include strings.h nor memory.h, include
40095         string.h unconditionally.  Patch by Simon Josefsson.
40096
40097 2007-01-27  Bruno Haible  <bruno@clisp.org>
40098
40099         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
40100         from gl_HEADER_STRING_H_BODY.
40101         (gl_HEADER_STRING_H_BODY): Require it.
40102         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
40103         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
40104         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
40105         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
40106         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
40107         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
40108         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
40109         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
40110         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
40111         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
40112         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
40113         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
40114         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
40115         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
40116         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
40117
40118 2007-01-27  Bruno Haible  <bruno@clisp.org>
40119
40120         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
40121         check_PROGRAMS into noinst_PROGRAMS.
40122         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
40123         check_PROGRAMS in this case.
40124         (func_import): Set for_test to false.
40125         (func_create_testdir): Set for_test to true.
40126
40127 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
40128             Bruno Haible  <bruno@clisp.org>
40129
40130         * modules/strcasestr (Files): Remove lib/strcasestr.h.
40131         (Depends-on): Add string.
40132         (Includes): Use <string.h> instead of strcasestr.h.
40133         * modules/string (Makefile.am): Also substitute the value of
40134         REPLACE_STRCASESTR.
40135         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
40136         assume strcasestr is declared in <string.h> not <strings.h>. Also
40137         set REPLACE_STRCASESTR.
40138         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
40139         REPLACE_STRCASESTR.
40140         * lib/strcasestr.h: Remove file.
40141         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
40142         * lib/string_.h (strcasestr): New declaration.
40143
40144 2007-01-27  Bruno Haible  <bruno@clisp.org>
40145
40146         * lib/string_.h: Use 'extern'.
40147
40148 2007-01-27  Jim Meyering  <jim@meyering.net>
40149
40150         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
40151         of set-but-not-used local, "q".
40152
40153         * lib/mempcpy.c: Include <config.h> before <string.h>.
40154         This fixes a compilation error on HP-UX, due to the system's
40155         "restrict"-using mempcpy prototype.
40156
40157 2007-01-26  Bruno Haible  <bruno@clisp.org>
40158
40159         Small optimization.
40160         * lib/javacomp.c: Include c-strstr.h.
40161          (is_envjavac_gcj): Use c_strstr instead of strstr.
40162         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
40163
40164 2007-01-26  Bruno Haible  <bruno@clisp.org>
40165
40166         * MODULES.html.sh (Unicode string functions): Add the new modules.
40167
40168         * modules/uniconv/u32-strconv-to-locale: New file.
40169         * lib/uniconv/u32-strconv-to-locale.c: New file.
40170
40171         * modules/uniconv/u16-strconv-to-locale: New file.
40172         * lib/uniconv/u16-strconv-to-locale.c: New file.
40173
40174         * modules/uniconv/u8-strconv-to-locale: New file.
40175         * lib/uniconv/u8-strconv-to-locale.c: New file.
40176
40177         * modules/uniconv/u32-strconv-from-locale: New file.
40178         * lib/uniconv/u32-strconv-from-locale.c: New file.
40179
40180         * modules/uniconv/u16-strconv-from-locale: New file.
40181         * lib/uniconv/u16-strconv-from-locale.c: New file.
40182
40183         * modules/uniconv/u8-strconv-from-locale: New file.
40184         * lib/uniconv/u8-strconv-from-locale.c: New file.
40185
40186         * modules/uniconv/u32-strconv-to-enc: New file.
40187         * lib/uniconv/u32-strconv-to-enc.c: New file.
40188         * modules/uniconv/u32-strconv-to-enc-tests: New file.
40189         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
40190
40191         * modules/uniconv/u16-strconv-to-enc: New file.
40192         * lib/uniconv/u16-strconv-to-enc.c: New file.
40193         * lib/uniconv/u-strconv-to-enc.h: New file.
40194         * modules/uniconv/u16-strconv-to-enc-tests: New file.
40195         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
40196
40197         * modules/uniconv/u8-strconv-to-enc: New file.
40198         * lib/uniconv/u8-strconv-to-enc.c: New file.
40199         * modules/uniconv/u8-strconv-to-enc-tests: New file.
40200         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
40201
40202         * modules/uniconv/u32-strconv-from-enc: New file.
40203         * lib/uniconv/u32-strconv-from-enc.c: New file.
40204         * modules/uniconv/u32-strconv-from-enc-tests: New file.
40205         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
40206
40207         * modules/uniconv/u16-strconv-from-enc: New file.
40208         * lib/uniconv/u16-strconv-from-enc.c: New file.
40209         * modules/uniconv/u16-strconv-from-enc-tests: New file.
40210         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
40211
40212         * modules/uniconv/u8-strconv-from-enc: New file.
40213         * lib/uniconv/u8-strconv-from-enc.c: New file.
40214         * lib/uniconv/u-strconv-from-enc.h: New file.
40215         * modules/uniconv/u8-strconv-from-enc-tests: New file.
40216         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
40217
40218         * modules/uniconv/u32-conv-from-enc: New file.
40219         * lib/uniconv/u32-conv-from-enc.c: New file.
40220         * modules/uniconv/u32-conv-from-enc-tests: New file.
40221         * tests/uniconv/test-u32-conv-from-enc.c: New file.
40222
40223         * modules/uniconv/u16-conv-from-enc: New file.
40224         * lib/uniconv/u16-conv-from-enc.c: New file.
40225         * lib/uniconv/u-conv-from-enc.h: New file.
40226         * modules/uniconv/u16-conv-from-enc-tests: New file.
40227         * tests/uniconv/test-u16-conv-from-enc.c: New file.
40228
40229         * modules/uniconv/u8-conv-from-enc: New file.
40230         * lib/uniconv/u8-conv-from-enc.c: New file.
40231         * modules/uniconv/u8-conv-from-enc-tests: New file.
40232         * tests/uniconv/test-u8-conv-from-enc.c: New file.
40233
40234         * modules/uniconv/base: New file.
40235         * lib/uniconv.h: New file.
40236
40237 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
40238
40239         * doc/gnulib-tool.texi (Initial import): Update to match current
40240         behavior with strdup module.
40241         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
40242         * lib/memmem.h: Remove; all uses removed.  This is now done
40243         by <string.h>.
40244         * lib/mempcpy.h: Likewise.
40245         * lib/memrchr.h: Likewise.
40246         * lib/stpcpy.h: Likewise.
40247         * lib/stpncpy.h: Likewise.
40248         * lib/strcase.h: Likewise.
40249         * lib/strchrnul.h: Likewise.
40250         * lib/strdup.h: Likewise.
40251         * lib/strndup.h: Likewise.
40252         * lib/strnlen.h: Likewise.
40253         * lib/strpbrk.h: Likewise.
40254         * lib/strsep.h: Likewise.
40255         * lib/strstr.h: Likewise.
40256         * lib/strtok_r.h: Likewise.
40257         * lib/string_.h: New file.
40258         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
40259         Rely on <string.h> instead.
40260         * lib/canon-host.c: Likewise.
40261         * lib/chdir-long.c: Likewise.
40262         * lib/concatpath.c: Likewise.
40263         * lib/exclude.c: Likewise.
40264         * lib/fchdir.c: Likewise.
40265         * lib/getaddrinfo.c: Likewise.
40266         * lib/getcwd.c: Likewise.
40267         * lib/getsubopt.c: Likewise.
40268         * lib/glob.c: Likewise.
40269         * lib/hard-locale.c: Likewise.
40270         * lib/iconvme.c: Likewise.
40271         * lib/javacomp.c: Likewise.
40272         * lib/mempcpy.c: Likewise.
40273         * lib/memrchr.c: Likewise.
40274         * lib/regex_internal.h: Likewise.
40275         * lib/stpncpy.c: Likewise.
40276         * lib/strcasecmp.c: Likewise.
40277         * lib/strchrnul.c: Likewise.
40278         * lib/strdup.c: Likewise.
40279         * lib/striconv.c: Likewise.
40280         * lib/striconveh.c: Likewise.
40281         * lib/striconveha.c: Likewise.
40282         * lib/strncasecmp.c: Likewise.
40283         * lib/strndup.c: Likewise.
40284         * lib/strnlen.c: Likewise.
40285         * lib/strsep.c: Likewise.
40286         * lib/strstr.c: Likewise.
40287         * lib/strtok_r.c: Likewise.
40288         * lib/userspec.c: Likewise.
40289         * lib/w32spawn.h: Likewise.
40290         * lib/xstrndup.c: Likewise.
40291         * lib/mountlist.c (strstr): Remove decl.
40292         * m4/string_h.m4: New file.
40293         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
40294         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
40295         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
40296         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
40297         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
40298         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
40299         Set REPLACE_STRCASECMP if necessary.
40300         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
40301         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
40302         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
40303         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
40304         HAVE_DECL_STRDUP if necessary.
40305         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
40306         since gl_FUNC_STRNDUP does that now.
40307         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
40308         Check for decl here...
40309         (gl_PREREQ_STRNLEN): ... not here.
40310         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
40311         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
40312         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
40313         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
40314         necessary.
40315         * modules/string: New file.
40316         * modules/memmem (Files): Remove special-purpose include file.
40317         (Depends-on): Add string.
40318         (Include): Include <string.h>, not the removed file.
40319         * modules/mempcpy: Likewise.
40320         * modules/memrchr: Likewise.
40321         * modules/stpcpy: Likewise.
40322         * modules/stpncpy: Likewise.
40323         * modules/strcase: Likewise.
40324         * modules/strchrnul: Likewise.
40325         * modules/strdup: Likewise.
40326         * modules/strndup: Likewise.
40327         * modules/strnlen: Likewise.
40328         * modules/strpbrk: Likewise.
40329         * modules/strsep: Likewise.
40330         * modules/strstr: Likewise.
40331         * modules/strtok_r: Likewise.
40332         * tests/test-dirname.c: Don't include "strdup.h", since
40333         <string.h> now suffices.
40334         * tests/test-memmem.c: Don't include "memmem.h", since
40335         <string.h> now suffices.
40336
40337 2007-01-25  Bruno Haible  <bruno@clisp.org>
40338
40339         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
40340         *resultp is 0.
40341
40342         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
40343         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
40344         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
40345         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
40346
40347         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
40348         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
40349         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
40350         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
40351         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
40352         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
40353
40354 2007-01-24  Bruno Haible  <bruno@clisp.org>
40355
40356         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
40357         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
40358         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
40359         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
40360         gl_FUNC_FTS_CORE.
40361         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
40362         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
40363         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
40364         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
40365         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
40366         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
40367         gl_FUNC_FCHOWNAT.
40368         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
40369         gl_FUNC_STRFTIME.
40370         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
40371         Reported by Ralf Wildenhues.
40372
40373 2007-01-24  Bruno Haible  <bruno@clisp.org>
40374
40375         Drop AC_REQUIRE calls that are redundant with the module dependencies.
40376         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
40377         gl_GETADDRINFO.
40378         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
40379         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
40380         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
40381
40382 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
40383
40384         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
40385         Don't use 'exit'; just return from 'main'.
40386         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
40387
40388         * lib/fnmatch_.h: Readjust white space and comments to match
40389         glibc, to avoid spurious diffs.
40390
40391 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
40392
40393         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
40394         2004-12-01 change by Jakub Jelinek, since this code won't compile
40395         if !LIBC.  Problem reported by Bob Proulx.
40396
40397 2007-01-23  Bruno Haible  <bruno@clisp.org>
40398
40399         * lib/striconveh.c: Include c-strcaseeq.h.
40400         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
40401         * modules/striconveh (Depends-on): Add c-strcaseeq.
40402
40403 2007-01-23  Bruno Haible  <bruno@clisp.org>
40404
40405         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
40406
40407         * modules/c-strcaseeq: New file.
40408         * lib/c-strcaseeq.h: New file.
40409
40410         * modules/streq: New file.
40411         * lib/streq.h: New file.
40412
40413 2007-01-23  Bruno Haible  <bruno@clisp.org>
40414
40415         * modules/striconveha-tests: New file.
40416         * tests/test-striconveha.c: New file.
40417
40418         * lib/striconveha.h: Include <stdbool.h>.
40419         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
40420         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
40421         (mem_iconveha_notranslit): Renamed from mem_iconveha.
40422         (mem_iconveha): New function.
40423         (str_iconveha_notranslit): Renamed from str_iconveha.
40424         (str_iconveha): New function.
40425         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
40426         c-strcase.
40427
40428 2007-01-23  Bruno Haible  <bruno@clisp.org>
40429
40430         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
40431         encodings without forgiving before trying any encoding with handler.
40432         (str_iconveha): Try all encodings without forgiving before trying any
40433         encoding with handler.
40434
40435 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
40436
40437         Import the following changes from libc.
40438
40439         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
40440
40441         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
40442
40443         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
40444
40445         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
40446         normal_bracket label.
40447
40448         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
40449
40450         [BZ #361]
40451         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
40452         to normal_bracket after fetching the next character.
40453
40454 2007-01-22  Bruno Haible  <bruno@clisp.org>
40455
40456         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
40457         argument.
40458         * lib/striconveh.c (iconv_carefully_1): New function.
40459         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
40460         argument.
40461         (str_cd_iconveh): Update.
40462         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
40463         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
40464         * tests/test-striconveh.c (MAGIC): New macro.
40465         (new_offsets): New function.
40466         (main): Test call with and without offsets.
40467
40468 2007-01-22  Bruno Haible  <bruno@clisp.org>
40469
40470         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
40471         * modules/sys_select (Makefile.am): Likewise.
40472         * modules/sys_socket (Makefile.am): Likewise.
40473         * modules/sys_time (Makefile.am): Likewise.
40474
40475 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
40476
40477         * modules/gettimeofday (License): Change from GPL to LGPL, since
40478         gettimeofday is a library function.
40479
40480 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
40481
40482         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
40483
40484 2007-01-21  Bruno Haible  <bruno@clisp.org>
40485
40486         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
40487
40488 2007-01-21  Bruno Haible  <bruno@clisp.org>
40489
40490         * modules/striconveha: New file.
40491         * lib/striconveha.h: New file.
40492         * lib/striconveha.c: New file.
40493         * MODULES.html.sh (Internationalization functions): Add striconveha.
40494         * lib/striconv.c (str_iconv): Optimize the case of an empty input
40495         string.
40496         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
40497
40498 2007-01-21  Bruno Haible  <bruno@clisp.org>
40499
40500         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
40501         * lib/striconveh.c (str_iconveh): Likewise.
40502
40503 2007-01-21  Bruno Haible  <bruno@clisp.org>
40504
40505         * lib/striconveh.h (mem_iconveh): New declaration.
40506         * lib/striconveh.c (mem_iconveh): New function.
40507         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
40508
40509 2007-01-21  Bruno Haible  <bruno@clisp.org>
40510
40511         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
40512
40513         * lib/striconveh.h (mem_cd_iconveh): Change specification.
40514         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
40515         original result buffer.
40516         (str_cd_iconveh): Update.
40517         * tests/test-striconveh.c (main): Update.
40518
40519         * lib/striconv.h (mem_cd_iconv): Change specification.
40520         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
40521         result buffer.
40522         (str_cd_iconv): Update.
40523         * tests/test-striconv.c (main): Update.
40524
40525 2007-01-21  Bruno Haible  <bruno@clisp.org>
40526
40527         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
40528
40529 2007-01-20  Jim Meyering  <jim@meyering.net>
40530
40531         * lib/userspec.c (parse_with_separator): If a user or group string
40532         starts with "+", skip the corresponding name-to-ID look-up, since
40533         such a look-up must fail: user and group names may not include "+".
40534
40535 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
40536
40537         * lib/poll.c: Include sys/time.h and time.h unconditionally,
40538         since we now assume the sys_time module.
40539         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
40540         check for sys/time.h; no longer needed.
40541         * modules/poll (Depends-on): Depend on sys_time.
40542
40543 2007-01-18  Bruno Haible  <bruno@clisp.org>
40544
40545         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
40546         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
40547
40548         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
40549         gettimeofday.
40550
40551         * tests/test-gettimeofday.c: Include <time.h>.
40552         (dummy): Remove variable.
40553
40554         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
40555         gl_HEADER_SYS_TIME_H.
40556         (gl_HEADER_SYS_TIME_H): New macro.
40557
40558         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
40559         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40560         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
40561         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
40562         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40563         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
40564         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
40565         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40566         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
40567         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
40568         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40569
40570         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
40571         last change; it caused a compilation error when cross-compiling to
40572         Cygwin.
40573
40574 2007-01-18  Jim Meyering  <jim@meyering.net>
40575
40576         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
40577         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
40578         than the race-prone "test -d sys || mkdir sys".
40579         (configure.ac): Use AC_PROG_MKDIR_P.
40580         * modules/sys_select: Likewise.
40581         * modules/sys_socket: Likewise.
40582         * modules/sys_time: Likewise.
40583
40584 2007-01-18  Eric Blake  <ebb9@byu.net>
40585
40586         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
40587         replace gettimeofday.
40588         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
40589         name, to avoid infinite recursion.
40590
40591 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
40592
40593         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
40594         module sys_time.
40595         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
40596         assume timespec.h defines struct timeval.
40597         * lib/settime.c: Likewise.
40598         * lib/utimens.c: Likewise.
40599         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
40600         since we now assume the gettimeofday module.
40601         * lib/tempname.c (__gen_tempname): Likewise.
40602         * lib/gettimeofday.h: Remove.
40603         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
40604         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
40605         Include <time.h>, for 'time()'.
40606         (localtime_buffer_addr): Also use this workaround if
40607         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
40608         to simplify the uses.  All uses changed.
40609         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
40610         that #undef is inside {}, and 'const' follows type name consistently.
40611         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
40612         (gettimeofday): Do not use the maximum possible value for
40613         tv->tv_usec, since that might break usages other than ls.c.
40614         Instead, we'll leave ls.c alone.  This undoes today's patch
40615         by Bruno.  Add a compile-time warning for 1s-clock resolution;
40616         we've never observed the problem but might as well keep the
40617         canary.
40618         * lib/nanosleep.c: Include timespec.h first, for interface check.
40619         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
40620         now assume the sys_time module.
40621         * lib/tempname.c: Likewise.
40622         * lib/timespec.h: Likewise.
40623         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
40624         needed.
40625         * lib/strftime.c: Likewise.
40626         * lib/timespec.h: Likewise.
40627         * lib/posixtm.c: Include posixtm.h first, for interface check.
40628         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
40629         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
40630         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
40631         * lib/sys_time_.h: New file.
40632         * lib/timespec.h (struct timespec): Use long int, not long.
40633         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
40634         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
40635         Remove obsolescent call to AC_HEADER_TIME.
40636         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
40637         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
40638         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
40639         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
40640         Likewise.
40641         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
40642         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
40643         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
40644         into the sys_time module.  Check for gettimeofday just once.
40645         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
40646         for gettimeofday signature to just check the signature.  Merely
40647         compile it, since linking doesn't test signature.  Improve test for
40648         whether gettimeofday.o is actually needed.
40649         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
40650         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
40651         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
40652         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40653         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
40654         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
40655         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
40656         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
40657         than worrying about sys/time.h.
40658         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
40659         Don't bother worrying about TIME_WITH_SYS_TIME.
40660         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
40661         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
40662         * m4/sys_time_h.m4: New file.
40663         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
40664         Don't include sys/time.h.  Return from main rather than exiting.
40665         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
40666         all uses changed.
40667         * modules/gethrxtime (Depends-on): Add sys_time.
40668         * modules/gettime (Depends-on): Likewise.
40669         * modules/gettimeofday (Depends-on): Likewise.
40670         * modules/nanosleep (Depends-on): Likewise.
40671         * modules/settime (Depends-on): Likewise.
40672         * modules/tempname (Depends-on): Likewise.
40673         * modules/utimens (Depends-on): Likewise.
40674         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
40675         (Include:) Change back to <sys/time.h>.
40676         (Maintainer:) Add self.
40677         * modules/sys_time: New file.
40678         * modules/tempname (Depends-on): Add gettimeofday.
40679         * tests/test-gettimeofday.c: Include <sys/time.h>
40680         rather than gettimeofday.h.
40681
40682 2007-01-17  Bruno Haible  <bruno@clisp.org>
40683
40684         * gnulib-tool (func_get_license): Revert last patch. Instead, let
40685         the license default to GPL.
40686         (func_create_testdir): Don't complain if a module is LGPL and its
40687         tests module depends on GPLed modules.
40688
40689 2007-01-17  Bruno Haible  <bruno@clisp.org>
40690
40691         * lib/gettimeofday.c (gettimeofday): Add code for the case
40692         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
40693         maximum possible value for tv->tv_usec, rather than the minimum one.
40694
40695 2005-10-08  Martin Lambers  <marlam@marlam.de>
40696 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
40697 2007-01-16  Bruno Haible  <bruno@clisp.org>
40698
40699         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
40700         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
40701         gl_FUNC_GETTIMEOFDAY.
40702         (Include): Add gettimeofday.h.
40703         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
40704         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
40705         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
40706         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
40707         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
40708         * lib/gettimeofday.h: New file.
40709         * lib/gettimeofday.c: Include <sys/timeb.h>.
40710         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
40711         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
40712         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
40713         fall back on time().
40714
40715         * tests/test-gettimeofday.c: New file.
40716         * modules/gettimeofday-tests: New file.
40717
40718 2007-01-16  Eric Blake  <ebb9@byu.net>
40719
40720         * modules/fnmatch (Depends-on): Depend on wchar.
40721         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
40722         * m4/fnmatch.m4: Likewise.
40723         * modules/mbchar (Makefile.am): Assume <wchar.h>.
40724         * m4/mbchar.m4: Likewise.
40725         * modules/mbswidth (Depends-on): Depend on wchar.
40726         * lib/mbswidth.c: Assume <wchar.h>.
40727         * m4/mbswidth.m4: Likewise.
40728         * modules/quotearg (Depends-on): Depend on wchar.
40729         * lib/quotearg.c: Assume <wchar.h>.
40730         * m4/quotearg.m4: Likewise.
40731         * modules/regex (Depends-on): Depend on wchar.
40732         * lib/regex_internal.h: Assume <wchar.h>.
40733         * m4/regex.m4: Likewise.
40734         * modules/stdint (Depends-on): Depend on wchar.
40735         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
40736         * m4/stdint.m4: Likewise.
40737         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
40738         * modules/strftime (Depends-on): Depend on wchar.
40739         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
40740         * modules/strtol (Depends-on): Depend on wchar.
40741         * lib/strtol.c: Assume <wchar.h>.
40742         * modules/wcwidth (Depends-on): Depend on wchar.
40743         * lib/wcwidth.h: Assume <wchar.h>.
40744         * m4/wcwidth.m4: Likewise.
40745
40746 2007-01-16  Bruno Haible  <bruno@clisp.org>
40747
40748         * modules/csharpexec-script: New, created from...
40749         * modules/csharpexec: ... this.
40750
40751 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
40752
40753         * modules/javaexec-script: New, created from...
40754         * modules/javaexec: ... this.
40755
40756 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
40757
40758         * modules/poll (Dependencies): Add sys_select.
40759
40760 2007-01-15  Jim Meyering  <jim@meyering.net>
40761
40762         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
40763         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
40764         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
40765         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
40766
40767 2007-01-15  Bruno Haible  <bruno@clisp.org>
40768
40769         * modules/striconveh: New file.
40770         * lib/striconveh.h: New file.
40771         * lib/striconveh.c: New file.
40772         * MODULES.html.sh (Internationalization functions): Add striconveh.
40773
40774         * modules/striconveh-tests: New file.
40775         * tests/test-striconveh.c: New file.
40776
40777 2007-01-15  Bruno Haible  <bruno@clisp.org>
40778
40779         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
40780         not from GNU libiconv or GNU libc.
40781
40782 2007-01-15  Bruno Haible  <bruno@clisp.org>
40783
40784         * doc/gnulib-intro.texi (Copyright): Explain the different license
40785         terms for module descriptions, autoconf macros, tests, documentation.
40786
40787 2007-01-14  Bruno Haible  <bruno@clisp.org>
40788
40789         * modules/striconv-tests: New file.
40790         * tests/test-striconv.c: New file.
40791
40792 2007-01-14  Bruno Haible  <bruno@clisp.org>
40793
40794         * modules/iconv-tests: New file.
40795         * tests/test-iconv.c: New file.
40796
40797 2007-01-14  Bruno Haible  <bruno@clisp.org>
40798
40799         * gnulib-tool (func_get_license): For test modules, use the license of
40800         the main module.
40801
40802 2007-01-14  Bruno Haible  <bruno@clisp.org>
40803
40804         * modules/iconv (Include): Clarify that <iconv.h> can only be included
40805         if iconv is found to exist.
40806
40807 2007-01-14  Bruno Haible  <bruno@clisp.org>
40808
40809         * modules/c-ctype-tests: New file.
40810         * tests/test-c-ctype.c: New file.
40811
40812 2007-01-14  Bruno Haible  <bruno@clisp.org>
40813
40814         * modules/binary-io-tests: New file.
40815         * tests/test-binary-io.sh: New file.
40816         * tests/test-binary-io.c: New file.
40817
40818 2007-01-14  Bruno Haible  <bruno@clisp.org>
40819
40820         * modules/array-oset-tests: New file.
40821         * tests/test-array_oset.c: New file.
40822
40823 2007-01-14  Bruno Haible  <bruno@clisp.org>
40824
40825         * modules/array-list-tests: New file.
40826         * tests/test-array_list.c: New file.
40827
40828 2007-01-14  Bruno Haible  <bruno@clisp.org>
40829
40830         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
40831         and make.
40832         Reported by Simon Josefsson in
40833         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
40834
40835 2007-01-14  Bruno Haible  <bruno@clisp.org>
40836
40837         * modules/allocsa-tests: New file.
40838         * tests/test-allocsa.c: New file.
40839
40840 2007-01-14  Bruno Haible  <bruno@clisp.org>
40841
40842         * modules/fchdir (Depends-on): Add absolute-header.
40843         * modules/unistd (Depends-on): Likewise.
40844
40845 2006-12-30  Bruno Haible  <bruno@clisp.org>
40846
40847         * modules/fchdir: New file.
40848         * modules/unistd (Files): Add lib/unistd_.h.
40849         (Makefile.am): Generate unistd.h from unistd_.h.
40850         * lib/fchdir.c: New file.
40851         * lib/dirent_.h: New file.
40852         * lib/unistd_.h: New file.
40853         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
40854         * m4/fchdir.m4: New file.
40855         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
40856         (gl_HEADER_UNISTD): Invoke it.
40857         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
40858         function.
40859         * lib/backupfile.c (opendir, closedir): Undefine.
40860         * lib/chown.c (open, close): Undefine.
40861         * lib/clean-temp.c (open, close): Undefine.
40862         * lib/copy-file.c (open, close): Undefine.
40863         * lib/execute.c (open, close): Undefine.
40864         * lib/fsusage.c (open, close): Undefine.
40865         * lib/gc-gnulib.c (open, close): Undefine.
40866         * lib/getcwd.c (opendir, closedir): Undefine.
40867         * lib/glob.c (opendir, closedir): Undefine.
40868         * lib/javacomp.c (open, close): Undefine.
40869         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
40870         * lib/openat-proc.c (open, close): Undefine.
40871         * lib/pagealign_alloc.c (open, close): Undefine.
40872         * lib/pipe.c (open, close): Undefine.
40873         * lib/progreloc.c (open, close): Undefine.
40874         * lib/savedir.c (opendir, closedir): Undefine.
40875         * lib/utime.c (open, close): Undefine.
40876         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
40877
40878 2007-01-10  Bruno Haible  <bruno@clisp.org>
40879
40880         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
40881
40882 2007-01-12  Eric Blake  <ebb9@byu.net>
40883
40884         Provide a robust <wchar.h>.  Further simplifications are now
40885         possible in other modules, but not included here.
40886         * modules/wchar: New module.
40887         * m4/wchar.m4: New file.
40888         * lib/wchar_.h: Likewise.
40889         * modules/mbchar (Depends-on): Depend on wchar, as the first use
40890         of the new module.
40891         * MODULES.html.sh (Extended multibyte and wide character utilities):
40892         New section.
40893
40894 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
40895
40896         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
40897         to a reasonable default for memory allocation.
40898         (xreadlink): Don't allocate a huge buffer, to work around a buggy
40899         file system that reports garbage st_size values for symlinks.
40900         Problem reported by Liyang Hu.
40901
40902 2007-01-11  Simon Josefsson  <simon@josefsson.org>
40903
40904         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
40905         Emacs .#* auto-save files).
40906
40907 2007-01-11  Bruno Haible  <bruno@clisp.org>
40908
40909         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
40910         directory.
40911
40912 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
40913
40914         Use @...@ consistently in lib/wctype_.h.
40915         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
40916         on it being set to 1 or 0.
40917         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
40918         go back to AC_SUBSTing it.
40919         * modules/wctype (Makefile.am): Undo previous change.
40920
40921 2007-01-10  Eric Blake  <ebb9@byu.net>
40922
40923         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
40924         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
40925         * modules/wctype (Makefile.am): Likewise.
40926         Reported by Chris McGuire.
40927
40928 2007-01-10  Jim Meyering  <jim@meyering.net>
40929
40930         fts.c: a small readability/maintainability improvement
40931         * lib/fts.c (fts_read): Make this code slightly more readable and
40932         maintainable by hoisting the "sp->fts_cur = p" assignments to
40933         immediately follow the statements that set P.  Derived from
40934         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
40935
40936 2007-01-10  Eric Blake  <ebb9@byu.net>
40937
40938         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
40939         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
40940         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
40941         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
40942         Reported by Chris McGuire.
40943
40944 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
40945
40946         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
40947         in sed script.
40948
40949 2007-01-09  Bruno Haible  <bruno@clisp.org>
40950
40951         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
40952         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
40953         variables.
40954         (func_module): Use them.
40955
40956 2007-01-09  Bruno Haible  <bruno@clisp.org>
40957
40958         * modules/unistr/base: New file.
40959         * lib/unistr.h: New file.
40960
40961         * modules/unistr/u8-to-u16: New file.
40962         * lib/unistr/u8-to-u16.c: New file.
40963
40964         * modules/unistr/u8-to-u32: New file.
40965         * lib/unistr/u8-to-u32.c: New file.
40966
40967         * modules/unistr/u16-to-u8: New file.
40968         * lib/unistr/u16-to-u8.c: New file.
40969
40970         * modules/unistr/u16-to-u32: New file.
40971         * lib/unistr/u16-to-u32.c: New file.
40972
40973         * modules/unistr/u32-to-u8: New file.
40974         * lib/unistr/u32-to-u8.c: New file.
40975
40976         * modules/unistr/u32-to-u16: New file.
40977         * lib/unistr/u32-to-u16.c: New file.
40978
40979         * modules/unistr/u8-check: New file.
40980         * modules/unistr/u16-check: New file.
40981         * modules/unistr/u32-check: New file.
40982         * lib/unistr/u8-check.c: New file.
40983         * lib/unistr/u16-check.c: New file.
40984         * lib/unistr/u32-check.c: New file.
40985
40986         * modules/unistr/u8-chr: New file.
40987         * modules/unistr/u16-chr: New file.
40988         * modules/unistr/u32-chr: New file.
40989         * lib/unistr/u8-chr.c: New file.
40990         * lib/unistr/u16-chr.c: New file.
40991         * lib/unistr/u32-chr.c: New file.
40992
40993         * modules/unistr/u8-cmp: New file.
40994         * modules/unistr/u16-cmp: New file.
40995         * modules/unistr/u32-cmp: New file.
40996         * lib/unistr/u8-cmp.c: New file.
40997         * lib/unistr/u16-cmp.c: New file.
40998         * lib/unistr/u32-cmp.c: New file.
40999
41000         * modules/unistr/u8-cpy: New file.
41001         * modules/unistr/u16-cpy: New file.
41002         * modules/unistr/u32-cpy: New file.
41003         * lib/unistr/u8-cpy.c: New file.
41004         * lib/unistr/u16-cpy.c: New file.
41005         * lib/unistr/u32-cpy.c: New file.
41006         * lib/unistr/u-cpy.h: New file.
41007
41008         * modules/unistr/u8-cpy-alloc: New file.
41009         * modules/unistr/u16-cpy-alloc: New file.
41010         * modules/unistr/u32-cpy-alloc: New file.
41011         * lib/unistr/u8-cpy-alloc.c: New file.
41012         * lib/unistr/u16-cpy-alloc.c: New file.
41013         * lib/unistr/u32-cpy-alloc.c: New file.
41014         * lib/unistr/u-cpy-alloc.h: New file.
41015
41016         * modules/unistr/u8-endswith: New file.
41017         * modules/unistr/u16-endswith: New file.
41018         * modules/unistr/u32-endswith: New file.
41019         * lib/unistr/u8-endswith.c: New file.
41020         * lib/unistr/u16-endswith.c: New file.
41021         * lib/unistr/u32-endswith.c: New file.
41022         * lib/unistr/u-endswith.h: New file.
41023
41024         * modules/unistr/u8-mblen: New file.
41025         * modules/unistr/u16-mblen: New file.
41026         * modules/unistr/u32-mblen: New file.
41027         * lib/unistr/u8-mblen.c: New file.
41028         * lib/unistr/u16-mblen.c: New file.
41029         * lib/unistr/u32-mblen.c: New file.
41030
41031         * modules/unistr/u8-mbtouc: New file.
41032         * modules/unistr/u16-mbtouc: New file.
41033         * modules/unistr/u32-mbtouc: New file.
41034         * lib/unistr/u8-mbtouc.c: New file.
41035         * lib/unistr/u16-mbtouc.c: New file.
41036         * lib/unistr/u32-mbtouc.c: New file.
41037
41038         * modules/unistr/u8-mbtouc-safe: New file.
41039         * modules/unistr/u16-mbtouc-safe: New file.
41040         * modules/unistr/u32-mbtouc-safe: New file.
41041         * lib/unistr/u8-mbtouc-safe.c: New file.
41042         * lib/unistr/u16-mbtouc-safe.c: New file.
41043         * lib/unistr/u32-mbtouc-safe.c: New file.
41044
41045         * modules/unistr/u8-move: New file.
41046         * modules/unistr/u16-move: New file.
41047         * modules/unistr/u32-move: New file.
41048         * lib/unistr/u8-move.c: New file.
41049         * lib/unistr/u16-move.c: New file.
41050         * lib/unistr/u32-move.c: New file.
41051         * lib/unistr/u-move.h: New file.
41052
41053         * modules/unistr/u8-next: New file.
41054         * modules/unistr/u16-next: New file.
41055         * modules/unistr/u32-next: New file.
41056         * lib/unistr/u8-next.c: New file.
41057         * lib/unistr/u16-next.c: New file.
41058         * lib/unistr/u32-next.c: New file.
41059
41060         * modules/unistr/u8-prev: New file.
41061         * modules/unistr/u16-prev: New file.
41062         * modules/unistr/u32-prev: New file.
41063         * lib/unistr/u8-prev.c: New file.
41064         * lib/unistr/u16-prev.c: New file.
41065         * lib/unistr/u32-prev.c: New file.
41066
41067         * modules/unistr/u8-set: New file.
41068         * modules/unistr/u16-set: New file.
41069         * modules/unistr/u32-set: New file.
41070         * lib/unistr/u8-set.c: New file.
41071         * lib/unistr/u16-set.c: New file.
41072         * lib/unistr/u32-set.c: New file.
41073         * lib/unistr/u-set.h: New file.
41074
41075         * modules/unistr/u8-startswith: New file.
41076         * modules/unistr/u16-startswith: New file.
41077         * modules/unistr/u32-startswith: New file.
41078         * lib/unistr/u8-startswith.c: New file.
41079         * lib/unistr/u16-startswith.c: New file.
41080         * lib/unistr/u32-startswith.c: New file.
41081         * lib/unistr/u-startswith.h: New file.
41082
41083         * modules/unistr/u8-stpcpy: New file.
41084         * modules/unistr/u16-stpcpy: New file.
41085         * modules/unistr/u32-stpcpy: New file.
41086         * lib/unistr/u8-stpcpy.c: New file.
41087         * lib/unistr/u16-stpcpy.c: New file.
41088         * lib/unistr/u32-stpcpy.c: New file.
41089         * lib/unistr/u-stpcpy.h: New file.
41090
41091         * modules/unistr/u8-stpncpy: New file.
41092         * modules/unistr/u16-stpncpy: New file.
41093         * modules/unistr/u32-stpncpy: New file.
41094         * lib/unistr/u8-stpncpy.c: New file.
41095         * lib/unistr/u16-stpncpy.c: New file.
41096         * lib/unistr/u32-stpncpy.c: New file.
41097         * lib/unistr/u-stpncpy.h: New file.
41098
41099         * modules/unistr/u8-strcat: New file.
41100         * modules/unistr/u16-strcat: New file.
41101         * modules/unistr/u32-strcat: New file.
41102         * lib/unistr/u8-strcat.c: New file.
41103         * lib/unistr/u16-strcat.c: New file.
41104         * lib/unistr/u32-strcat.c: New file.
41105         * lib/unistr/u-strcat.h: New file.
41106
41107         * modules/unistr/u8-strchr: New file.
41108         * modules/unistr/u16-strchr: New file.
41109         * modules/unistr/u32-strchr: New file.
41110         * lib/unistr/u8-strchr.c: New file.
41111         * lib/unistr/u16-strchr.c: New file.
41112         * lib/unistr/u32-strchr.c: New file.
41113
41114         * modules/unistr/u8-strcmp: New file.
41115         * modules/unistr/u16-strcmp: New file.
41116         * modules/unistr/u32-strcmp: New file.
41117         * lib/unistr/u8-strcmp.c: New file.
41118         * lib/unistr/u16-strcmp.c: New file.
41119         * lib/unistr/u32-strcmp.c: New file.
41120
41121         * modules/unistr/u8-strcpy: New file.
41122         * modules/unistr/u16-strcpy: New file.
41123         * modules/unistr/u32-strcpy: New file.
41124         * lib/unistr/u8-strcpy.c: New file.
41125         * lib/unistr/u16-strcpy.c: New file.
41126         * lib/unistr/u32-strcpy.c: New file.
41127         * lib/unistr/u-strcpy.h: New file.
41128
41129         * modules/unistr/u8-strcspn: New file.
41130         * modules/unistr/u16-strcspn: New file.
41131         * modules/unistr/u32-strcspn: New file.
41132         * lib/unistr/u8-strcspn.c: New file.
41133         * lib/unistr/u16-strcspn.c: New file.
41134         * lib/unistr/u32-strcspn.c: New file.
41135         * lib/unistr/u-strcspn.h: New file.
41136
41137         * modules/unistr/u8-strdup: New file.
41138         * modules/unistr/u16-strdup: New file.
41139         * modules/unistr/u32-strdup: New file.
41140         * lib/unistr/u8-strdup.c: New file.
41141         * lib/unistr/u16-strdup.c: New file.
41142         * lib/unistr/u32-strdup.c: New file.
41143         * lib/unistr/u-strdup.h: New file.
41144
41145         * modules/unistr/u8-strlen: New file.
41146         * modules/unistr/u16-strlen: New file.
41147         * modules/unistr/u32-strlen: New file.
41148         * lib/unistr/u8-strlen.c: New file.
41149         * lib/unistr/u16-strlen.c: New file.
41150         * lib/unistr/u32-strlen.c: New file.
41151         * lib/unistr/u-strlen.h: New file.
41152
41153         * modules/unistr/u8-strmblen: New file.
41154         * modules/unistr/u16-strmblen: New file.
41155         * modules/unistr/u32-strmblen: New file.
41156         * lib/unistr/u8-strmblen.c: New file.
41157         * lib/unistr/u16-strmblen.c: New file.
41158         * lib/unistr/u32-strmblen.c: New file.
41159
41160         * modules/unistr/u8-strmbtouc: New file.
41161         * modules/unistr/u16-strmbtouc: New file.
41162         * modules/unistr/u32-strmbtouc: New file.
41163         * lib/unistr/u8-strmbtouc.c: New file.
41164         * lib/unistr/u16-strmbtouc.c: New file.
41165         * lib/unistr/u32-strmbtouc.c: New file.
41166
41167         * modules/unistr/u8-strncat: New file.
41168         * modules/unistr/u16-strncat: New file.
41169         * modules/unistr/u32-strncat: New file.
41170         * lib/unistr/u8-strncat.c: New file.
41171         * lib/unistr/u16-strncat.c: New file.
41172         * lib/unistr/u32-strncat.c: New file.
41173         * lib/unistr/u-strncat.h: New file.
41174
41175         * modules/unistr/u8-strncmp: New file.
41176         * modules/unistr/u16-strncmp: New file.
41177         * modules/unistr/u32-strncmp: New file.
41178         * lib/unistr/u8-strncmp.c: New file.
41179         * lib/unistr/u16-strncmp.c: New file.
41180         * lib/unistr/u32-strncmp.c: New file.
41181
41182         * modules/unistr/u8-strncpy: New file.
41183         * modules/unistr/u16-strncpy: New file.
41184         * modules/unistr/u32-strncpy: New file.
41185         * lib/unistr/u8-strncpy.c: New file.
41186         * lib/unistr/u16-strncpy.c: New file.
41187         * lib/unistr/u32-strncpy.c: New file.
41188         * lib/unistr/u-strncpy.h: New file.
41189
41190         * modules/unistr/u8-strnlen: New file.
41191         * modules/unistr/u16-strnlen: New file.
41192         * modules/unistr/u32-strnlen: New file.
41193         * lib/unistr/u8-strnlen.c: New file.
41194         * lib/unistr/u16-strnlen.c: New file.
41195         * lib/unistr/u32-strnlen.c: New file.
41196         * lib/unistr/u-strnlen.h: New file.
41197
41198         * modules/unistr/u8-strpbrk: New file.
41199         * modules/unistr/u16-strpbrk: New file.
41200         * modules/unistr/u32-strpbrk: New file.
41201         * lib/unistr/u8-strpbrk.c: New file.
41202         * lib/unistr/u16-strpbrk.c: New file.
41203         * lib/unistr/u32-strpbrk.c: New file.
41204         * lib/unistr/u-strpbrk.h: New file.
41205
41206         * modules/unistr/u8-strrchr: New file.
41207         * modules/unistr/u16-strrchr: New file.
41208         * modules/unistr/u32-strrchr: New file.
41209         * lib/unistr/u8-strrchr.c: New file.
41210         * lib/unistr/u16-strrchr.c: New file.
41211         * lib/unistr/u32-strrchr.c: New file.
41212
41213         * modules/unistr/u8-strspn: New file.
41214         * modules/unistr/u16-strspn: New file.
41215         * modules/unistr/u32-strspn: New file.
41216         * lib/unistr/u8-strspn.c: New file.
41217         * lib/unistr/u16-strspn.c: New file.
41218         * lib/unistr/u32-strspn.c: New file.
41219         * lib/unistr/u-strspn.h: New file.
41220
41221         * modules/unistr/u8-strstr: New file.
41222         * modules/unistr/u16-strstr: New file.
41223         * modules/unistr/u32-strstr: New file.
41224         * lib/unistr/u8-strstr.c: New file.
41225         * lib/unistr/u16-strstr.c: New file.
41226         * lib/unistr/u32-strstr.c: New file.
41227         * lib/unistr/u-strstr.h: New file.
41228
41229         * modules/unistr/u8-strtok: New file.
41230         * modules/unistr/u16-strtok: New file.
41231         * modules/unistr/u32-strtok: New file.
41232         * lib/unistr/u8-strtok.c: New file.
41233         * lib/unistr/u16-strtok.c: New file.
41234         * lib/unistr/u32-strtok.c: New file.
41235         * lib/unistr/u-strtok.h: New file.
41236
41237         * modules/unistr/u8-uctomb: New file.
41238         * modules/unistr/u16-uctomb: New file.
41239         * modules/unistr/u32-uctomb: New file.
41240         * lib/unistr/u8-uctomb.c: New file.
41241         * lib/unistr/u16-uctomb.c: New file.
41242         * lib/unistr/u32-uctomb.c: New file.
41243
41244         * MODULES.html.sh (Unicode string functions): Add the new modules.
41245
41246 2007-01-08  Bruno Haible  <bruno@clisp.org>
41247
41248         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
41249         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
41250         subdirectories.
41251
41252 2007-01-08  Karl Berry  <karl@gnu.org>
41253
41254         * doc/error.texi: mention that main() fns must set program_name
41255         when progname is used.
41256
41257 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
41258
41259         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
41260         WCTYPE_H is empty, for the benefit of builds from non-distclean
41261         directories.  Problem reported by Eric Blake in
41262         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
41263
41264 2007-01-08  Bruno Haible  <bruno@clisp.org>
41265
41266         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
41267         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
41268         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
41269         PROVIDE_CANONICALIZE_FILENAME_MODE.
41270         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
41271
41272 2007-01-08  Bruno Haible  <bruno@clisp.org>
41273
41274         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
41275         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
41276         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
41277         * lib/fts.c: Likewise.
41278         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
41279
41280 2006-12-25  Bruno Haible  <bruno@clisp.org>
41281
41282         * modules/utf8-ucs4-safe: New file.
41283         * lib/utf8-ucs4-safe.h: New file.
41284         * lib/unistr/utf8-ucs4-safe.c: New file.
41285
41286         * modules/utf16-ucs4-safe: New file.
41287         * lib/utf16-ucs4-safe.h: New file.
41288         * lib/unistr/utf16-ucs4-safe.c: New file.
41289
41290         * MODULES.html.sh (Unicode string functions): Add the new modules.
41291
41292 2007-01-08  Bruno Haible  <bruno@clisp.org>
41293
41294         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
41295         (Depends-on): Add unitypes.
41296         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
41297         (u8_mbtouc_aux): Move out to separate file.
41298         (u8_mbtouc): Use ucs4_t, uint8_t types.
41299         * lib/unistr/utf8-ucs4.c: New file.
41300
41301         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
41302         (Depends-on): Add unitypes.
41303         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
41304         (u16_mbtouc_aux): Move out to separate file.
41305         (u16_mbtouc): Use ucs4_t, uint16_t types.
41306         * lib/unistr/utf16-ucs4.c: New file.
41307
41308         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
41309         (Depends-on): Add unitypes.
41310         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
41311         (u8_uctomb_aux): Move out to separate file.
41312         (u8_uctomb): Use ucs4_t, uint8_t types.
41313         * lib/unistr/ucs4-utf8.c: New file.
41314
41315         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
41316         (Depends-on): Add unitypes.
41317         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
41318         (u16_uctomb_aux): Move out to separate file.
41319         (u16_uctomb): Use ucs4_t, uint16_t types.
41320         * lib/unistr/ucs4-utf16.c: New file.
41321
41322 2006-12-25  Bruno Haible  <bruno@clisp.org>
41323
41324         * modules/unitypes: New file.
41325         * lib/unitypes.h: New file.
41326         * MODULES.html.sh (func_all_modules): New section "Unicode string
41327         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
41328         this section. Add unitypes.
41329
41330 2007-01-08  Bruno Haible  <bruno@clisp.org>
41331
41332         Avoid variable names that conflict with those from libtool.
41333         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
41334         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
41335         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
41336         library_names_spec to acl_library_names_spec, hardcode_* to
41337         acl_hardcode_*.
41338         Reported by Ralf Wildenhues.
41339
41340 2007-01-08  Bruno Haible  <bruno@clisp.org>
41341
41342         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
41343         definition.
41344         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
41345         definition.
41346         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
41347         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
41348         definition.
41349         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
41350         definition.
41351         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
41352         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
41353         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
41354         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
41355         definition.
41356         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
41357         definition.
41358         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
41359         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
41360         GC_USE_<algorithm>.
41361         * lib/gc-libgcrypt.c: Likewise.
41362         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
41363         * modules/gc-arctwo (configure.ac): Likewise.
41364         * modules/gc-des (configure.ac): Likewise.
41365         * modules/gc-hmac-md5 (configure.ac): Likewise.
41366         * modules/gc-hmac-sha1 (configure.ac): Likewise.
41367         * modules/gc-md2 (configure.ac): Likewise.
41368         * modules/gc-md4 (configure.ac): Likewise.
41369         * modules/gc-md5 (configure.ac): Likewise.
41370         * modules/gc-random (configure.ac): Likewise.
41371         * modules/gc-rijndael (configure.ac): Likewise.
41372         * modules/gc-sha1 (configure.ac): Likewise.
41373
41374 2007-01-08  Bruno Haible  <bruno@clisp.org>
41375
41376         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
41377         macro definition.
41378         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
41379         definition.
41380         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
41381         definition.
41382         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
41383         * modules/fcntl-safer (configure.ac): Likewise.
41384         * modules/fopen-safer (configure.ac): Likewise.
41385         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
41386         GNULIB_FWRITEERROR macro definition.
41387
41388 2007-01-08  Bruno Haible  <bruno@clisp.org>
41389
41390         * m4/gnulib-common.m4: New file.
41391         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
41392         (func_get_filelist): Add m4/gnulib-common.m4.
41393
41394 2007-01-08  Bruno Haible  <bruno@clisp.org>
41395
41396         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
41397         command.
41398
41399 2007-01-08  Jim Meyering  <jim@meyering.net>
41400
41401         Use a more robust test for a "can't happen" condition.
41402         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
41403         narrowed the st_size value.  Presuming the "can't happen" condition
41404         is true, that narrowing could conceivably convert an invalid st_size
41405         value into a valid one.  Instead, use a change based on Matthew
41406         Woehlke's original patch.
41407
41408         Slight readability improvement: use an assert-like macro
41409         in place of literal "abort ()" uses.
41410         * lib/fts.c (fts_assert): Define.
41411         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
41412         Use this macro instead of a bare 'abort'.
41413
41414 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
41415
41416         Don't worry about using IRIX 5.3's wctype.h broken definitions;
41417         simply work around them.
41418         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
41419         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
41420         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
41421         declaring.
41422         Don't bother to define as macros, since the standard doesn't require it.
41423         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
41424         longer worry about IRIX 5.3.
41425         (HAVE_WCTYPE_CTMP_BUG): Remove.
41426
41427 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
41428
41429         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
41430         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
41431         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
41432         Problems reported by Georg Schwarz for IRIX 5.3.
41433
41434         * gnulib-tool (autoconf_minversion): Take the maximum version number
41435         found, not the minimum.  Problem reported by James Youngman.
41436
41437 2007-01-03  Karl Berry  <karl@gnu.org>
41438
41439         * doc/error.texi: new file, explaining interaction with progname.
41440         * doc/gnulib.texi: include it.  Update copyright.
41441
41442 2007-01-03  Simon Josefsson  <simon@josefsson.org>
41443
41444         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
41445         AC_CANONICAL_HOST, to improve autobuild outputs.
41446
41447 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
41448             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
41449
41450         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
41451         sockets, server sockets, and other file descriptors.  Count errors
41452         to compute the return value.  Reorder the code a bit to be easier
41453         to follow.  Don't set event bits that were not requested (except
41454         POLLERR and POLLHUP).
41455
41456 2007-01-01  Bruno Haible  <bruno@clisp.org>
41457
41458         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
41459
41460 2007-01-03  Jim Meyering  <jim@meyering.net>
41461
41462         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
41463
41464 2007-01-02  Bruno Haible  <bruno@clisp.org>
41465
41466         * modules/settime (Include): Require timespec.h.
41467         * modules/nanosleep (Include): Likewise.
41468
41469 2007-01-01  Bruno Haible  <bruno@clisp.org>
41470
41471         * gnulib-tool (func_emit_copyright_notice): Bump year.
41472         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
41473
41474 2007-01-01  Bruno Haible  <bruno@clisp.org>
41475
41476         Improve support for OpenBSD.
41477         * build-aux/config.rpath (libname_spec): Export.
41478         (library_names_spec): New variable. Export.
41479         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
41480         library_names_spec from the config.rpath output. Locate shared library
41481         through the name pattern in library_names_spec.
41482
41483 2007-01-01  Eric Blake  <ebb9@byu.net>
41484
41485         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
41486
41487 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
41488
41489         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
41490         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
41491         assume the C locale, and avoid an "eval" that could cause trouble.
41492         Problem with SORT reported by Bob Proulx.
41493
41494         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
41495         Define.  Trivial patch from Henning Nielsen Lund, originally
41496         sent to bug-grep@gnu.org today.
41497
41498 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
41499
41500         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
41501         struct stat.  Problem reported by Henning Nielsen Lund.
41502         * lib/acl.c: Include acl.h first, to check interface.  Don't
41503         bother to include sys/types.h and sys/stat.h again.
41504
41505 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
41506
41507         Import the following change from libc; problem reported by
41508         Sven Verdoolaege.
41509
41510         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
41511
41512         [BZ #1373]
41513         * lib/argp.h: Remove __NTH for __argp_usage inline function.
41514
41515 2006-12-28  Jim Meyering  <jim@meyering.net>
41516
41517         * build-aux/announce-gen: Do not assume that the package
41518         builds any of tar.gz, tar.bz2, and .xdelta files.
41519         Suggestion from Simon Josefsson.
41520
41521 2006-12-28  Simon Josefsson  <simon@josefsson.org>
41522
41523         * modules/announce-gen: New file.
41524
41525 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
41526
41527         * lib/mbchar.h: Just include <wctype.h>; the wctype module
41528         handles its gotchas now.
41529         * lib/mbswidth.c: Likewise.
41530         * lib/wcwidth.h: Likewise.
41531         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
41532         and iswcntrl; the wctype module does this stuff now.
41533         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
41534         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
41535         * modules/mbchar (Depends-on): Add wctype.
41536         * modules/mbswidth (Depends-on): Likewise.
41537         * modules/wcwidth (Depends-on): Likewise.
41538
41539 2006-12-27  Eric Blake  <ebb9@byu.net>
41540
41541         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
41542         module uses more than what <wctype.h> is required to provide.
41543
41544 2006-12-26  Eric Blake  <ebb9@byu.net>
41545
41546         * gnulib-tool (sed_extract_prog): Avoid space-tab.
41547
41548 2006-12-26  Eric Blake  <ebb9@byu.net>
41549
41550         * modules/absolute-header: New module.
41551         * modules/fcntl (Depends-on): Depend on it.
41552         * modules/inttypes (Depends-on): Likewise.
41553         * modules/stdint (Depends-on): Likewise.
41554         * modules/sys_stat (Depends-on): Likewise.
41555         * modules/wctype (Depends-on): Likewise.
41556         * MODULES.html.sh (Support for building libraries and
41557         executables): Document it.
41558
41559 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
41560
41561         * gnulib-tool (SED): Remove, undoing previous change.
41562         The problem was that it broke coreutils on Solaris, because
41563         "sed --posix" leaked into a makefile.
41564         (sed): New alias, if 'alias' and GNU sed.
41565
41566 2006-12-24  Jim Meyering  <jim@meyering.net>
41567
41568         Work around an fchownat bug in glibc-2.4:
41569         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
41570         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
41571         in spite of the -P option.
41572         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
41573         New macros.
41574         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
41575         * modules/openat (Files): Add lib/fchownat.c.
41576         * lib/openat.c (fchownat): Don't define here.  Move to...
41577         * lib/fchownat.c: ...this new file.
41578
41579 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
41580
41581         Fix bug reported by Bruno Haible in
41582         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
41583         where quotearg.c didn't compile on Mac OS X 10.2 because it
41584         lacks <wchar.h> and wint_t.
41585         * lib/wctype_.h (__wctype_wint_t): New type.
41586         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
41587         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
41588         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
41589         Arg is now of type __wctype_wint_t, not wint_t.
41590         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
41591         substitute HAVE_WINT_T.
41592         * modules/wctype (Files): Add m4/wint_t.m4.
41593         (wctype.h): Substitute HAVE_WINT_T.
41594
41595 2006-12-23  Bruno Haible  <bruno@clisp.org>
41596
41597         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
41598
41599 2006-12-23  Bruno Haible  <bruno@clisp.org>
41600
41601         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
41602         S_ISLNK.
41603         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
41604         mingw.
41605
41606 2006-12-22  Bruno Haible  <bruno@clisp.org>
41607
41608         * lib/copy-file.c: Include acl.h.
41609         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
41610         Close the file descriptors only after being done with copy_acl.
41611         * modules/copy-file (Depends-on): Add acl.
41612
41613 2006-12-22  Bruno Haible  <bruno@clisp.org>
41614
41615         * gnulib-tool (SED): New variable.
41616         Use $SED instead of sed everywhere.
41617
41618 2006-12-22  Bruno Haible  <bruno@clisp.org>
41619
41620         * modules/no-c++: New file.
41621         * m4/no-c++.m4: New file.
41622         * MODULES.html.sh (Support for building libraries and executables):
41623         Add no-c++.
41624
41625 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
41626
41627         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
41628         Include <limits.h>, and use its INT_MAX to rewrite the
41629         j loop so that it does not overflow 'int'.  Problem reported by
41630         Ralf Wildenhues in
41631         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
41632         Play it safe by shifting left by 1 rather than multiplying by 2,
41633         as GCC is less likely to optimize this away when the value
41634         is signed (when it assumes overflow leads to undefined behavior).
41635         Also, don't assume time_t uses two's complement.
41636
41637 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
41638
41639         * MODULES.html.sh: New module wctype.
41640         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
41641         * lib/fnmatch.c: Don't bother to include <wchar.h> before
41642         <wctype.h>, since the new wctype module should fix this.
41643         * lib/quotearg.c: Include <wctype.h> unconditionally, since
41644         the wctype module should arrange for it.
41645         * lib/regex_internal.h: Likewise.
41646         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
41647         since the wctype module should handle this now.
41648         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
41649         * modules/fnmatch (Depends-on): Add wctype.
41650         * modules/quotearg (Depends-on): Likewise.
41651         * modules/regex (Depends-on): Likewise.
41652
41653 2006-12-19  Bruno Haible  <bruno@clisp.org>
41654
41655         * lib/strdup.h [C++]: Wrap definitions in extern "C".
41656         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
41657
41658 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41659
41660         * modules/savewd (Depends-on): Fix dependency on fcntl.
41661
41662 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
41663
41664         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
41665         conforms to C99, rather than relying on the user's environment
41666         setting of STDINT_H.
41667
41668 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
41669         and Eric Blake  <ebb9@byu.net>
41670
41671         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
41672         This is more consistent with the other defines here.
41673         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
41674         Port to z/OS.  Problem reported by Paul Gilmartin.
41675         Change local vars to use gl_ prefix rather than ac_.
41676         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
41677         with other defines.
41678         * modules/double-slash-root: New module.
41679         * modules/dirname (Files): Remove m4/double-slash-root.m4.
41680         (Depends-on): Add double-slash-root.
41681         * MODULES.html.sh (File system functions): Mention new module.
41682
41683 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
41684
41685         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
41686         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
41687         This is for the benefit of gzip, which doesn't do i18n.
41688
41689 2006-12-12  Jim Meyering  <jim@meyering.net>
41690
41691         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
41692         Reported by Andreas Schwab <schwab@suse.de>.
41693
41694 2006-12-12  Bruno Haible  <bruno@clisp.org>
41695
41696         Merge these changes.
41697         2006-09-05  Bruno Haible  <bruno@clisp.org>
41698         * lib/iconvme.c (iconv_string): No need to save and restore errno when
41699         iconv_alloc succeeded.
41700         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
41701         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
41702         test for " && dest " at the end - dest is always != NULL there. Call
41703         iconv with 4xNULL arguments initially, to reset the state. Call iconv
41704         with 2xNULL arguments, also to flush the state storage. Handle the
41705         IRIX iconv behaviour. Realloc the final result, to throw away unused
41706         memory.
41707
41708 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
41709
41710         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
41711         and fchmodat unconditionally, since glibc 2.4 has them.
41712         Problem reported by Arkadiusz Miskiewicz.
41713
41714 2006-12-10  Bruno Haible  <bruno@clisp.org>
41715
41716         * gnulib-tool (func_import): Show the include files only for those
41717         modules that are copied and specified.
41718         Reported by Karl Berry.
41719
41720 2006-12-08  Jim Meyering  <jim@meyering.net>
41721
41722         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
41723         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
41724
41725         * build-aux/announce-gen: Add two new options, both optional:
41726         --bootstrap-tools=TOOL_LIST
41727               a comma-separated list of tools, e.g.,
41728               autoconf,automake,bison,gnulib
41729         --gnulib-snapshot-date=DATE
41730               if gnulib is in the bootstrap tool list,
41731               then report this as the snapshot date.
41732               If not specified, use the current date/time.
41733               If you specify a date here, be sure it's UTC.
41734
41735 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41736
41737         * tests/test-argp-2.sh: Fix test to match actual output.
41738         (func_compare): Fix sed script to be portable.
41739
41740 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
41741
41742         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
41743         workaround for this case.  It is not autoconfigured now; offhand
41744         it's hard to see how to autoconfigure it.
41745
41746 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
41747
41748         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
41749         a directory that is about to be chowned.  Such a directory's
41750         initial file permissions should permit the owner only and this
41751         should not be changed until after the chown, since the group and
41752         other bits would be incorrect if they granted permission before
41753         the chown.
41754
41755         Fix porting problem for iswctype reported by Georg Schwarz in:
41756         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
41757         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
41758         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
41759         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
41760         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
41761
41762 2006-12-03  Jim Meyering  <jim@meyering.net>
41763
41764         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
41765         p->fts_statp may not yet be defined.
41766         (fts_read): Instead, set it in the caller, once p->fts_statp is
41767         sure to be defined, and corresponds to a top-level directory.
41768         This bug made du -x fail.  Here's the coreutils test case:
41769         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
41770         Reported by Mike Frysinger.
41771
41772 2006-12-01  Jim Meyering  <jim@meyering.net>
41773
41774         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
41775         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
41776         Reported by Simon Josefsson.
41777
41778 2006-11-30  Jim Meyering  <jim@meyering.net>
41779
41780         * m4/warning.m4: Use the all-permissive copyright notice
41781         recommended by RMS (rather than LGPL).
41782         * m4/vararrays.m4: Likewise.
41783         * m4/flexmember.m4: Likewise.
41784
41785 2006-11-29  Bruno Haible  <bruno@clisp.org>
41786
41787         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
41788         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
41789         using +=.
41790         Reported by Simon Josefsson <simon@josefsson.org>.
41791
41792 2006-11-28  James Youngman <jay@gnu.org>
41793
41794         * README: Advise users that they might find the bug-gnulib@gnu.org
41795         and autotools-announce@gnu.org mailing lists useful.
41796
41797 2006-11-28  Bruno Haible  <bruno@clisp.org>
41798
41799         * m4/ptrdiff_max.m4: Remove file.
41800
41801 2006-11-21  Bruno Haible  <bruno@clisp.org>
41802
41803         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
41804         _AC_COMPUTE_INT.
41805         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
41806         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
41807         _AC_COMPUTE_INT.
41808         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
41809         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
41810         _AC_COMPUTE_INT.
41811         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
41812
41813 2006-11-28  Jim Meyering  <jim@meyering.net>
41814
41815         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
41816         warning from "gcc -Wshadow" about shadowing the builtin.
41817
41818 2006-11-27  Bruno Haible  <bruno@clisp.org>
41819
41820         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
41821         _AC_COMPUTE_INT.
41822         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
41823
41824 2006-11-27  Bruno Haible  <bruno@clisp.org>
41825             Paul Eggert  <eggert@cs.ucla.edu>
41826
41827         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
41828
41829 2006-11-26  Bruno Haible  <bruno@clisp.org>
41830
41831         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
41832         noinst_LTLIBRARIES.
41833
41834 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
41835             Bruno Haible  <bruno@clisp.org>
41836
41837         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
41838         if compiling with "gcc -ansi".
41839
41840 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
41841
41842         Fix some incompatibilities with gcc -ansi -pedantic.
41843         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
41844         if compiling pedantically with GCC, unless it's C99 or later.
41845         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
41846         it mishandles gcc -ansi -pedantic as well.
41847         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
41848         if gcc -pedantic.
41849         * lib/regexec.c (check_node_accept_bytes): Don't use auto
41850         initializers for struct if -pedantic, unless it's C99 or later.
41851
41852 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
41853
41854         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
41855         Don't close an fd more than once. Identical atimes indicate
41856         success, not failure.
41857
41858 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
41859
41860         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
41861
41862 2006-11-23  Jim Meyering  <jim@meyering.net>
41863
41864         * build-aux/announce-gen: New file.  From coreutils.
41865
41866 2006-11-22  Jim Meyering  <jim@meyering.net>
41867
41868         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
41869         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
41870         (fts_read): Use a temporary to narrow the overused st_size member
41871         before using it in a switch statement.  Reported by Matthew Woehlke.
41872
41873         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
41874         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
41875
41876 2006-11-20  Bruno Haible  <bruno@clisp.org>
41877
41878         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
41879         changequote instead of pairs of brackets.
41880         Reported by Andreas Schwab <schwab@suse.de>.
41881
41882 2006-11-21  Jim Meyering  <jim@meyering.net>
41883
41884         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
41885         so as to remain compatible with older compilers.
41886         Patch from Michael Deutschmann.
41887
41888 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
41889
41890         * MODULES.html.sh (File system functions): Add openat.
41891
41892         * lib/openat.h (rpl_fstatat): New macro, if
41893         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
41894         (fstatat): Define to rpl_fstatat under the same conditions,
41895         unless COMPILING_FSTATAT.
41896         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
41897         seems to have the bug.
41898         * lib/fstatat.c: New file.
41899         * modules/openat (Files): Add it.
41900
41901 2006-11-20  Bruno Haible  <bruno@clisp.org>
41902
41903         * Makefile: New file.
41904
41905 2006-11-20  Jim Meyering  <jim@meyering.net>
41906
41907         The beginnings of syntax-related checks for gnulib.
41908         * lib/Makefile: New file.
41909         * lib/t-idcache: New script.  Ensure that the two halves of
41910         idcache.c stay in sync.
41911
41912         * lib/idcache.c: Adjust comments in user- and group- portions to
41913         be more accurate, and to be consistent with one another.
41914
41915 2006-11-20  Jim Meyering  <jim@meyering.net>
41916
41917         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
41918         continue using the flexible array member (thus, this module performs
41919         half as many malloc calls), with the addition that...
41920         (getgroup, getuser): Consistently record a non-match via an empty
41921         "name" string, and map an empty string match to a NULL return value.
41922         * modules/idcache (Depends-on): Re-add flexmember.
41923
41924         * lib/idcache.c (getuser): Remove all uses of the register keyword.
41925         (getuidbyname, getgroup, getgidbyname): Likewise.
41926
41927         Use cleaner syntax: NULL rather than 0.
41928         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
41929
41930 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
41931
41932         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
41933         It mishandled the case where the group was missing.
41934         Problem reported by Greg Schafer.
41935         * modules/idcache: Likewise.
41936
41937 2006-11-18  Jim Meyering  <jim@meyering.net>
41938
41939         * check-module (%exempt_header): Add exception for some
41940         conditionally-included headers.
41941
41942         * modules/i-ring (Depends-on): Add verify.
41943         (License): Change to LGPL.
41944
41945 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
41946
41947         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
41948         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
41949         and inttostr.h.  Use snprintf rather than uinttostr, so that
41950         LGPLed code doesn't depend on GPLed.
41951
41952 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
41953
41954         * modules/inline (License): Change from GPL to LGPL.
41955
41956 2006-11-17  Jim Meyering  <jim@meyering.net>
41957
41958         * modules/d-type (License): Switch to LGPL.
41959
41960 2006-11-15  Bruno Haible  <bruno@clisp.org>
41961
41962         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
41963
41964 2006-11-15  Eric Blake  <ebb9@byu.net>
41965
41966         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
41967         the module dependency.
41968
41969 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
41970             Bruno Haible  <bruno@clisp.org>
41971
41972         * gnulib-tool (func_create_testdir): Add license consistency check.
41973
41974 2006-11-15  Eric Blake  <ebb9@byu.net>
41975
41976         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
41977         random "(cached)" in configure output.
41978
41979 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
41980
41981         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
41982         test for conforming inttypes.h is both announced and cached.
41983
41984         * MODULES.html.sh (seen_modules, seen_files): New variables.
41985         (func_module): Rewrite to use a few less gnulib-tool and sed
41986         invocations.  Avoid a couple of quadratic algorithms for ...
41987         (missed_modules, missed_files): ... these, with ...
41988         (func_append, func_tmpdir): ... these new functions, from
41989         gnulib-tool.  Analogously, install traps for cleanup.
41990
41991         * tests/test-gc.c (main): Remove unused variables.
41992         * tests/test-read-file.c: Include stdlib.h, for 'free'.
41993
41994 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
41995
41996         * modules/inttostr (License): Change to LGPL.
41997
41998 2006-11-14  Eric Blake  <ebb9@byu.net>
41999
42000         * modules/tempname (License): Change to LGPL.
42001
42002 2006-11-14  Eric Blake  <ebb9@byu.net>
42003
42004         * doc/functions.texi (Function Portability): *printf functions on
42005         Cygwin now understand all POSIX size specifiers.
42006
42007 2006-11-14  Bruno Haible  <bruno@clisp.org>
42008
42009         * modules/c-ctype (License): Change to LGPL.
42010
42011 2006-11-12  Bruno Haible  <bruno@clisp.org>
42012
42013         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
42014         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
42015         for GNOME libraries, for which the include files are installed in
42016         subdirectories of $prefix/include.
42017
42018 2006-11-12  Bruno Haible  <bruno@clisp.org>
42019
42020         * m4/lib-link.m4: Require at least autoconf-2.54.
42021         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
42022         name to underscores for the --with option.
42023
42024 2006-11-13  Bruno Haible  <bruno@clisp.org>
42025
42026         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
42027         the tests directory.
42028         Reported by Ralf Wildenhues.
42029
42030 2006-11-13  Bruno Haible  <bruno@clisp.org>
42031
42032         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
42033         (func_emit_initmacro_end): Undo the override here.
42034         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
42035         Works around the famous automake error in coreutils.
42036
42037 2006-11-13  Eric Blake  <ebb9@byu.net>
42038
42039         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
42040         element, not its node.
42041
42042 2006-11-12  Bruno Haible  <bruno@clisp.org>
42043
42044         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
42045         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
42046
42047 2006-11-12  Bruno Haible  <bruno@clisp.org>
42048
42049         * gnulib-tool: New option --local-symlink.
42050         (func_usage): Document it.
42051         (lsymbolic): New variable.
42052         (func_import, func_create_testdir): If --symlink was not specified,
42053         test whether --local-symlink was specified and the file comes from
42054         the local_gnulib_dir.
42055
42056 2006-11-12  Bruno Haible  <bruno@clisp.org>
42057
42058         * gnulib-tool (func_ln): New function.
42059         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
42060
42061 2006-11-12  Bruno Haible  <bruno@clisp.org>
42062
42063         Finish support for source files in subdirectories.
42064         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
42065         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
42066         AUTOMAKE_OPTIONS.
42067         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
42068
42069 2006-11-12  Bruno Haible  <bruno@clisp.org>
42070
42071         * gnulib-tool (func_get_automake_snippet): Synthesize also an
42072         EXTRA_lib_SOURCES augmentation.
42073         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
42074
42075 2006-11-12  Jim Meyering  <jim@meyering.net>
42076
42077         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
42078         file descriptors.  This also averts a failure on systems with
42079         native openat support when a traversed directory lacks "x" access.
42080         * lib/fts_.h: Include "i-ring.h"
42081         (struct FTS) [fts_fd_ring]: New member.
42082         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
42083         (FCHDIR): Add parentheses.
42084         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
42085         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
42086         When descending, rather than simply closing the previous
42087         fts_cwd_fd value, push that file descriptor onto the ring.
42088         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
42089         (fts_open): Initialize the new fd_ring member.
42090         (fts_close): Clear the ring.
42091         (fts_safe_changedir): When possible, use our new fd_ring to skip
42092         the diropen and fstat and dev/ino comparison that would normally
42093         accompany a virtual `chdir ("..")'.
42094
42095         * modules/fts (Depends-on): Add i-ring.
42096         * modules/i-ring: New module.
42097         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
42098         * m4/i-ring.m4: New file.
42099
42100 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42101
42102         * gnulib-tool (func_create_testdir): Fix replacement of
42103         `build-aux' in configure.ac.  Run autotools in gltests
42104         subdirectory.
42105         (func_create_testdir, func_create_megatestdir, test): There is
42106         no need for '--force' in most autotool invocations in a new
42107         tree.  Actually fail the whole test if any of the tools, or the
42108         configure or make stages fail.
42109
42110         Sync from Automake.
42111         * build-aux/gnupload: Revert last change.  Add pointer to upload
42112         instructions of the GNU Maintenance Instructions.
42113         Suggestion by Karl Berry.
42114
42115 2006-11-10  Jim Meyering  <jim@meyering.net>
42116
42117         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
42118
42119 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
42120
42121         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
42122         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
42123         (bind_textdomain_codeset) [! ENABLE_NLS]:
42124         Evaluate all the arguments.  That way, callers get compatible behavior
42125         if the arguments have side effects.  Also, it avoids some GCC
42126         diagnostics in some cases; Joel E. Denny reported problems when Bison
42127         was configured with --enable-gcc-warnigs.
42128
42129 2006-11-10  Jim Meyering  <jim@meyering.net>
42130
42131         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
42132         relevant options in CFLAGS (like -O, -fno-inline) are taken into
42133         account.
42134
42135 2006-11-10  Jim Meyering  <jim@meyering.net>
42136
42137         * modules/inline: New file/module.
42138         * modules/xalloc (Files): Remove m4/inline.m4.
42139         (Depends-on): Add inline, instead.
42140         * modules/oset: Likewise.
42141         * modules/list: Likewise.
42142
42143 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
42144
42145         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
42146         Problem reported by Matthew Woehlke.
42147
42148 2006-11-09  Bruno Haible  <bruno@clisp.org>
42149
42150         * lib/tempname.c (gen_tempname): Remove variant that invokes
42151         __gen_tempname.
42152         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
42153         __gen_tempname.
42154
42155 2006-11-08  Bruno Haible  <bruno@clisp.org>
42156
42157         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
42158         to 'yes' instead of 'cross-compiling'.
42159
42160 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
42161
42162         * lib/quotearg.h (quotearg_free): New decl.
42163         * lib/quotearg.c (quotearg_free): New function.
42164         (slot0, nslots, slotvec0, slotvec):
42165         Now file-scope so that quotearg_free can get at them.
42166
42167 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42168
42169         Sync from Automake.
42170         * build-aux/gnupload: Add missing 'gnu' to example URL.
42171         Report by Karl Berry.
42172
42173 2006-11-08  Bruno Haible  <bruno@clisp.org>
42174
42175         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
42176         Suggested by Paul Eggert.
42177
42178 2006-11-08  Jim Meyering  <jim@meyering.net>
42179
42180         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
42181         It's already included if !_LIBC.
42182         (fts_safe_changedir): Add a comment.
42183
42184 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
42185
42186         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
42187         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
42188         Matthew Woehlke.
42189
42190         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
42191         definitions up, to avoid colliding with change below.
42192         (static_inline) [HAVE_INLINE]: New macro.
42193         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
42194         Provide extern decls when !HAVE_INLINE.  Do not define unless
42195         static_inline is defined, either by us or by xmalloc.c.  Use
42196         static_inline rather than static inline.
42197         (XCALLOC): Optimize sizeof(T) = 1 case.
42198         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
42199
42200 2006-11-07  Bruno Haible  <bruno@clisp.org>
42201
42202         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
42203         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
42204         AC_C_INLINE.
42205         * modules/xalloc (Files): Add m4/inline.m4.
42206
42207 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42208
42209         * README: Fix typo.
42210         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
42211         (Miscellanous Notes): ...from this.
42212
42213 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
42214
42215         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
42216         Mention that offsetof should be used instead of sizeof.
42217         From Bruno Haible.
42218
42219 2006-11-07  Bruno Haible  <bruno@clisp.org>
42220
42221         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
42222
42223 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
42224
42225         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
42226         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
42227         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
42228         (gl_tree_add_before, gl_tree_add_after):
42229         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
42230         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
42231         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
42232         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
42233         (gl_linked_add_after, gl_linked_add_at): Likewise.
42234         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
42235         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
42236         (gl_tree_add_before, gl_tree_add_after): Likewise.
42237         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
42238         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
42239         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
42240
42241 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42242
42243         * lib/gl_oset.h: Use C comment style, not C++ comment style.
42244
42245 2006-11-06  Bruno Haible  <bruno@clisp.org>
42246
42247         * m4/inline.m4: New file.
42248         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
42249         * modules/list (Files): Add m4/inline.m4.
42250         * modules/oset (Files): Likewise.
42251
42252 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
42253
42254         * lib/idcache.c: Include <stddef.h>, for offsetof.
42255         (struct userid.name): Change from char * to a flexible array member.
42256         All uses changed.
42257         * modules/idcache (Depends-on): Add flexmember.
42258
42259         * MODULES.html.sh (Core language properties): New module flexmember.
42260         * modules/flexmember, m4/flexmember.m4: New files.
42261
42262         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
42263         inline functions that are identical with the old xnmalloc_inline,
42264         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
42265         that we can avoid some unnecessary integer multiplications and
42266         divisions in the common case where the element size is known at
42267         compile time.
42268         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
42269         needed.
42270         (xnboundedmalloc): Remove.
42271         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
42272         arguments, for consistency with rest of this header.
42273         (xcharalloc): Rewrite using XNMALLOC.
42274         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
42275         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
42276         versions have been moved to lib/xalloc.h and renamed to be the
42277         non-*_inline versions.
42278         (xmalloc, xrealloc): Implement without reference to the xnmalloc
42279         and xnrealloc functions, since those functions are now inline and
42280         now call us.
42281         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
42282         renaming described above.
42283         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
42284         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
42285         captures the dependency in AC_C_INLINE.
42286
42287         New module canonicalize-lgpl, proposed by Charles Wilson in
42288         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
42289         with a few small changes afterwards.
42290         * MODULES.html.sh (File system functions): New module
42291         canonicalize-lgpl.
42292         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
42293         and canonicalize_file_name.
42294         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
42295         * modules/canonicalize-lgpl: New files.
42296
42297 2006-11-05  Bruno Haible  <bruno@clisp.org>
42298
42299         * gnulib-tool (func_import, func_create_testdir): Create directories
42300         also for files in subdirectories of lib/.
42301
42302 2006-11-05  Bruno Haible  <bruno@clisp.org>
42303
42304         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
42305         ANSI C compliant.
42306
42307 2006-11-03  Bruno Haible  <bruno@clisp.org>
42308
42309         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
42310         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
42311         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
42312         (xnboundedmalloc): New inline function.
42313         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
42314         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
42315         xmalloc.
42316         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
42317         xmalloc.
42318         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
42319         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
42320         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
42321         xmalloc.
42322         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
42323         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
42324         xmalloc.
42325         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
42326         gl_tree_add_after): Use XMALLOC instead of xmalloc.
42327         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
42328         xmalloc.
42329         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
42330         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
42331         gl_tree_add_after): Use XMALLOC instead of xmalloc.
42332         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
42333         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
42334         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
42335         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
42336
42337 2006-11-03  Bruno Haible  <bruno@clisp.org>
42338
42339         * lib/c-ctype.h [C++]: Define functions without name mangling.
42340         * lib/fwriteerror.h [C++]: Likewise.
42341         * lib/gcd.h [C++]: Likewise.
42342         * lib/linebreak.h [C++]: Likewise.
42343
42344 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
42345
42346         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
42347         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
42348         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
42349         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
42350         Check for functions and headers just once.
42351         Check for declaration of canonicalize_file_name.
42352         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
42353
42354 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
42355
42356         * gnulib-tool (func_import): Fix typo in actioncmd.
42357
42358 2006-11-02  Bruno Haible  <bruno@clisp.org>
42359
42360         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
42361         newline sequence in the Makefile.am snippet as a space, like "make"
42362         does.
42363         Reported by Roger Persson <perrog@gmail.com>.
42364
42365 2006-11-01  Bruno Haible  <bruno@clisp.org>
42366
42367         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
42368         already declared in <string.h>.
42369         * lib/strcase.h (strncasecmp): Don't declare it if yes.
42370
42371 2006-11-01  Bruno Haible  <bruno@clisp.org>
42372
42373         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
42374         * lib/strcase.h: Include <string.h>.
42375         (strcasecmp): Define to rpl_strcasecmp here.
42376
42377 2006-11-01  Bruno Haible  <bruno@clisp.org>
42378
42379         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
42380
42381 2006-11-01  Eric Blake  <ebb9@byu.net>
42382
42383         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
42384
42385         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
42386
42387 2006-10-29  Bruno Haible  <bruno@clisp.org>
42388
42389         Make it compile in C++ mode.
42390         * lib/full-write.c (full_rw): Add a cast.
42391
42392 2006-11-01  Bruno Haible  <bruno@clisp.org>
42393
42394         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
42395         be POSIX compliant.
42396         Reported by Roger Persson <perrog@gmail.com>.
42397
42398 2006-11-01  Eric Blake  <ebb9@byu.net>
42399
42400         * lib/getopt_.h: Fix comments.
42401
42402 2006-10-31  Eric Blake  <ebb9@byu.net>
42403
42404         * modules/tmpdir (Depends-on): Add sys_stat.
42405         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
42406         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
42407         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
42408         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
42409         tempname.
42410
42411 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
42412
42413         Avoid some C++ diagnostics reported by Bruno Haible.
42414         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
42415         xmalloc.
42416         (quotearg_alloc): Use xcharalloc rather than xmalloc.
42417         (struct slotvec): Move to top level.
42418         (quotearg_n_options): Rewrite to avoid xmalloc.
42419         * lib/xalloc.h (xcharalloc): New function.
42420         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
42421         [defined __cplusplus]: Add function template that provides result
42422         type propagation.  This part of the change is from Bruno Haible.
42423
42424 2006-10-29  Bruno Haible  <bruno@clisp.org>
42425
42426         Make it compile in C++ mode.
42427         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
42428         * lib/strnlen1.c (strnlen1): Cast memchr result.
42429         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
42430         * lib/clean-temp.c (string_equals, string_hash): Add casts.
42431         (create_temp_dir): Rename local variable 'template'.
42432         (compile_csharp_using_sscli): Add cast.
42433         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
42434         * lib/findprog.c (find_in_path): Likewise.
42435         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
42436         * lib/wait-process.c (register_slave_subprocess): Likewise.
42437
42438 2006-10-22  Bruno Haible  <bruno@clisp.org>
42439
42440         * modules/tsearch: New file.
42441         * lib/tsearch.h: New file.
42442         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
42443         * m4/tsearch.m4: New file.
42444         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
42445
42446 2006-10-29  Eric Blake  <ebb9@byu.net>
42447
42448         * lib/arcfour.c: Assume config.h.
42449         * lib/arctwo.c: Likewise.
42450         * lib/base64.c: Likewise.
42451         * lib/check-version.c: Likewise.
42452         * lib/crc.c: Likewise.
42453         * lib/des.c: Likewise.
42454         * lib/gc-gnulib.c: Likewise.
42455         * lib/gc-libgcrypt.c: Likewise.
42456         * lib/gc-pbkdf2-sha1.c: Likewise.
42457         * lib/getaddrinfo.c: Likewise.
42458         * lib/getdelim.c: Likewise.
42459         * lib/getline.c: Likewise.
42460         * lib/hmac-md5.c: Likewise.
42461         * lib/hmac-sha1.c: Likewise.
42462         * lib/iconvme.c: Likewise.
42463         * lib/md2.c: Likewise.
42464         * lib/md4.c: Likewise.
42465         * lib/memxor.c: Likewise.
42466         * lib/read-file.c: Likewise.
42467         * lib/readline.c: Likewise.
42468         * lib/rijndael-alg-fst.c: Likewise.
42469         * lib/rijndael-api-fst.c: Likewise.
42470         * lib/xgetdomainname.c: Likewise.
42471
42472 2006-10-28  Eric Blake  <ebb9@byu.net>
42473
42474         * lib/xstrndup.c: Assume config.h.
42475
42476 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
42477
42478         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
42479         stat-macros.h is now for our own macros, whereas stat_h is for
42480         macros in the <sys/stat.h> name space.
42481         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
42482         (STAT_MACROS_H): Remove.
42483         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
42484         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
42485         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
42486         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
42487         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
42488         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
42489         Move these macros to ...
42490         * lib/stat_.h: here.  Don't include stat-macros.h.
42491         * lib/canonicalize.c: Don't include stat-macros.h.
42492         * lib/chown.c: Likewise.
42493         * lib/euidaccess.c: Likewise.
42494         * lib/file-type.c: Likewise.
42495         * lib/filemode.c: Likewise.
42496         * lib/glob.c: Likewise.
42497         * lib/isapipe.c: Likewise.
42498         * lib/lchown.c: Likewise.
42499         * lib/lstat.c: Likewise.
42500         * lib/mkdir-p.c: Likewise.
42501         * lib/rmdir.c: Likewise.
42502         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
42503         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
42504         unless mkdir isn't declared, to speed up 'configure'.
42505         Always create sys/stat.h, since it's unlikely any real sys/stat.h
42506         would define all the S_* symbols.
42507         * modules/canonicalize (Depends-on):
42508         Depend on sys_stat, not stat-macros.
42509         * modules/chown: Likewise.
42510         * modules/euidaccess: Likewise.
42511         * modules/filemode: Likewise.
42512         * modules/file-type: Likewise.
42513         * modules/glob: Likewise.
42514         * modules/isapipe: Likewise.
42515         * modules/lchown: Likewise.
42516         * modules/lstat: Likewise.
42517         * modules/mkancesdirs: Likewise.
42518         * modules/rmdir: Likewise.
42519         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
42520         * modules/modechange: Likewise.
42521         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
42522         (configure.ac): Remove gl_STAT_MACROS.
42523         * modules/sys_stat (Depends-on): Remove stat-macros.
42524
42525 2006-10-27  Bruno Haible  <bruno@clisp.org>
42526
42527         * m4/signed.m4: Remove file.
42528         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
42529         invocation.
42530         * modules/vasnprintf (Files): Remove m4/signed.m4.
42531
42532 2006-10-27  Bruno Haible  <bruno@clisp.org>
42533
42534         Update to GNU gettext 0.16.
42535         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
42536         m4/inttypes-h.m4, m4/signed.m4.
42537         * m4/gettext.m4: Update to GNU gettext 0.16.
42538         * m4/intl.m4: New file, from GNU gettext.
42539         * m4/intldir.m4: New file, from GNU gettext.
42540         * config/srclist.txt: Update
42541
42542 2006-10-27  Eric Blake  <ebb9@byu.net>
42543
42544         * MODULES.html.sh: Document tempname.
42545         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
42546         dependencies.
42547         (Files): Move lib/tempname.c...
42548         * modules/tempname: ...to this new module.
42549         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
42550         (gl_PREREQ_TEMPNAME): Move...
42551         * m4/tempname.m4: ...to this new file.
42552         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
42553         * modules/sys_stat (Depends-on): Add stat-macros.
42554         * lib/stat_.h (includes): Pick up stat macros.
42555         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
42556         if stat macros are broken.
42557         * lib/tempname.c (includes): No need to include "stat-macros.h".
42558         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
42559         (direxists, __path_search) [!_LIBC]: Don't compile these in
42560         gnulib; the tmpdir module covers that.
42561         * lib/tempname.h: New file.
42562
42563 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
42564
42565         * COPYING: Explain how gnulib-tool converts licence headers.
42566         Almost all wording by Eric Blake.
42567
42568 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
42569
42570         * lib/mbchar.h (is_basic_table): Make read-only.
42571         * lib/mbchar.c (is_basic_table): Likewise.
42572         Reported by John Darrington.
42573
42574 2006-10-25  Bruno Haible  <bruno@clisp.org>
42575
42576         * lib/progname.h (set_program_name): Undefine before defining.
42577
42578 2006-10-25  Bruno Haible  <bruno@clisp.org>
42579
42580         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
42581         false for non-gcc C++ compilers.
42582         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
42583
42584 2006-10-24  Bruno Haible  <bruno@clisp.org>
42585
42586         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
42587         iconv implementations like Irix iconv.
42588
42589 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
42590
42591         * modules/vararrays: New file.
42592         * m4/vararrays.m4: New file, taken from diffutils.
42593         * MODULES.html.sh: New module vararrays.
42594
42595 2006-10-24  Karl Berry  <karl@gnu.org>
42596
42597         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
42598         Don't call GNU Unix.
42599
42600 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42601
42602         * users.txt: Add Libtool.
42603
42604         Sync from Libtool:
42605
42606         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
42607
42608         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
42609         to gnulib's policy of including config.h unconditionally.
42610
42611 2006-10-24  Bruno Haible  <bruno@clisp.org>
42612
42613         * modules/wcwidth (Files): Add m4/wint_t.m4.
42614         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
42615         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
42616
42617 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
42618
42619         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
42620         to pacify GCC with some -W flags enabled.  Problem reported by
42621         Bruno Haible.
42622
42623 2006-10-24  Jim Meyering  <jim@meyering.net>
42624
42625         * MODULES.html.sh: Remove uinttostr.  It's not a module.
42626         Reported by Karl Berry.
42627
42628 2006-10-23  Bruno Haible  <bruno@clisp.org>
42629
42630         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
42631
42632 2006-10-24  Bruno Haible  <bruno@clisp.org>
42633
42634         * lib/gl_list.h: Use C comment style, not C++ comment style.
42635
42636 2006-10-23  Eric Blake  <ebb9@byu.net>
42637
42638         * lib/getaddrinfo.c (includes): Add missing include.
42639
42640 2006-10-23  Bruno Haible  <bruno@clisp.org>
42641             Paul Eggert  <eggert@cs.ucla.edu>
42642
42643         Ability to rename obstack_free.
42644         * lib/obstack.h (__obstack_free): New macro. Declare instead of
42645         obstack_free.
42646         (obstack_free): Invoke the __obstack_free macro.
42647         * lib/obstack.c (obstack_free): Use __obstack_free macro.
42648
42649 2006-10-23  Bruno Haible  <bruno@clisp.org>
42650             Paul Eggert  <eggert@cs.ucla.edu>
42651
42652         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
42653         __argc, __argv from the declaration. (They are defined as macros on
42654         mingw.)
42655
42656 2006-10-22  Bruno Haible  <bruno@clisp.org>
42657
42658         * doc/gnulib-intro.texi: New file.
42659         * doc/gnulib.texi: Include it.
42660
42661 2006-10-21  Bruno Haible  <bruno@clisp.org>
42662
42663         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
42664         "Introduction", "Miscellanous Notes", "Particular Modules".
42665
42666 2006-10-21  Bruno Haible  <bruno@clisp.org>
42667
42668         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
42669         Change mostlyclean-local rule to avoid sh syntax error from bash
42670         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
42671
42672 2006-10-23  Jim Meyering  <jim@meyering.net>
42673
42674         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
42675         in place of snprintf.
42676
42677         * modules/inttostr (Files): Add lib/uinttostr.c.
42678         * lib/uinttostr.c (inttostr): New file/function.
42679         * lib/inttostr.h (uinttostr): Declare.
42680         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
42681         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
42682         Add uinttostr.
42683         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
42684
42685 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
42686
42687         * lib/canonicalize.c (ELOOP): Define if not already defined.
42688         Problem reported by Bruno Haible in
42689         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
42690
42691 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
42692
42693         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
42694         Problem reported by Perry Smith and Ville Laurikari.
42695
42696         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
42697         uses.
42698
42699 2006-10-19  Bruno Haible  <bruno@clisp.org>
42700
42701         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
42702         for mingw.
42703
42704 2006-10-19  Bruno Haible  <bruno@clisp.org>
42705
42706         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
42707         Needed for mingw.
42708
42709 2006-10-19  Bruno Haible  <bruno@clisp.org>
42710
42711         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
42712
42713 2006-10-19  Bruno Haible  <bruno@clisp.org>
42714
42715         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
42716         it.
42717
42718 2006-10-19  Bruno Haible  <bruno@clisp.org>
42719
42720         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
42721         invocation.
42722
42723 2006-10-19  Bruno Haible  <bruno@clisp.org>
42724
42725         * gnulib-tool (func_create_testdir): Don't include ftruncate and
42726         mountlist by default.
42727
42728 2006-10-16  Bruno Haible  <bruno@clisp.org>
42729
42730         * lib/c-strstr.c: Include c-strstr.h.
42731
42732 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
42733
42734         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
42735         in a slash.
42736
42737 2006-10-18  Bruno Haible  <bruno@clisp.org>
42738
42739         * lib/lock.h [C++]: Wrap definitions in extern "C".
42740
42741 2006-10-18  Bruno Haible  <bruno@clisp.org>
42742
42743         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
42744         gl_LIBOBJS list.
42745
42746 2006-10-18  Bruno Haible  <bruno@clisp.org>
42747
42748         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
42749
42750 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
42751
42752         * lib/xstrtol.h: Include gettext.h.
42753         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
42754         Problem reported by Eric Blake.
42755         * modules/xstrtol (Depends-on): Add gettext-h.
42756
42757 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
42758
42759         * lib/strftime.c (advance): New macro.
42760         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
42761         incomplete type, so you can't add 0 to it.  Problem and patch
42762         reported by Eelco Dolstra for dietlibc.
42763
42764 2006-10-18  Jim Meyering  <jim@meyering.net>
42765
42766         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
42767         type for a local, and rename it: s/up/user_proc/.
42768
42769 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
42770
42771         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
42772         READ_UTMP_USER_PROCESS.
42773         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
42774
42775 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
42776
42777         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
42778         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
42779
42780 2006-10-17  Eric Blake  <ebb9@byu.net>
42781
42782         * lib/sigprocmask.c (sigprocmask): Fix typo.
42783
42784         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
42785
42786         * modules/clean-temp (Makefile.am): Don't add to make output...
42787         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
42788         config.h.
42789
42790 2006-10-17  Bruno Haible  <bruno@clisp.org>
42791
42792         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
42793         differently if DEFAULT_TEXT_DOMAIN is set.
42794
42795 2006-10-16  Bruno Haible  <bruno@clisp.org>
42796
42797         * lib/clean-temp.c: Include fwriteerror.h.
42798
42799 2006-10-16  Bruno Haible  <bruno@clisp.org>
42800
42801         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
42802
42803 2006-10-16  Bruno Haible  <bruno@clisp.org>
42804
42805         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
42806         * lib/sigprocmask.h: Include <sys/types.h>.
42807         (sigset_t): Use the system's definition if present.
42808
42809 2006-10-17  Eric Blake  <ebb9@byu.net>
42810
42811         * lib/xvasprintf.c (includes): Assume config.h.
42812         * lib/xasprintf.c (includes): Likewise.
42813
42814 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
42815
42816         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
42817         at least as wide as intmax_t.
42818
42819 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
42820
42821         (Imported from Automake.)
42822         * build-aux/gnupload: Update to version 1.1 of directive file.
42823
42824 2006-10-16  Eric Blake  <ebb9@byu.net>
42825
42826         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
42827         match Automake 1.10a.
42828
42829 2006-10-14  Bruno Haible  <bruno@clisp.org>
42830
42831         * modules/sigprocmask: New file.
42832         * lib/sigprocmask.h: New file.
42833         * lib/sigprocmask.c: New file.
42834         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
42835         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
42836         request sigprocmask.o.
42837         (gl_PREREQ_SIGPROCMASK): New macro.
42838         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
42839         (Depends-on): Add sigprocmask.
42840         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
42841         gt_SIGNALBLOCKING. Test for 'raise' only once.
42842         * lib/fatal-signal.c: Include sigprocmask.h.
42843         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
42844         unblock_fatal_signals): Define always.
42845         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
42846         sigprocmask.
42847
42848 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
42849
42850         Sync from Automake.
42851         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
42852         which incorrectly sets the mode of an existing destination
42853         directory.  In some cases the unpatched install-sh could do the
42854         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
42855         system.  We hope this is rare in practice, but it's clearly worth
42856         fixing.  Problem reported by Alex Unleashed in
42857         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
42858         Also, don't bother to check for -m bugs unless we're using -m;
42859         suggested by Stepan Kasal.
42860
42861 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
42862
42863         Sync from Automake.
42864         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
42865         `-c' flag, so they appear at the same position as in %FASTDEP%
42866         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
42867         which ignores unknown options only after the first non-option.
42868         Bug report against M4 by Nelson H. F. Beebe.
42869
42870 2006-10-13  Jim Meyering  <jim@meyering.net>
42871
42872         Fix a bug in yesterday's change.
42873         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
42874         p->fts_statp->st_dev would be used uninitialized.
42875         Ensures that we always call fts_stat on the very first entry.
42876         Miklos Szeredi reported that find -xdev stopped working.
42877
42878 2006-10-12  Bruno Haible  <bruno@clisp.org>
42879
42880         * gnulib-tool (func_get_automake_snippet): Append an automatically
42881         computed EXTRA_DIST augmentation.
42882         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
42883         * modules/alloca-opt (Makefile.am): Likewise.
42884         * modules/allocsa (Makefile.am): Likewise.
42885         * modules/arcfour (Makefile.am): Likewise.
42886         * modules/arctwo (Makefile.am): Likewise.
42887         * modules/argmatch (Makefile.am): Likewise.
42888         * modules/argz (Makefile.am): Likewise.
42889         * modules/atexit (Makefile.am): Likewise.
42890         * modules/backupfile (Makefile.am): Likewise.
42891         * modules/byteswap (Makefile.am): Likewise.
42892         * modules/c-strtod (Makefile.am): Likewise.
42893         * modules/c-strtold (Makefile.am): Likewise.
42894         * modules/calloc (Makefile.am): Likewise.
42895         * modules/canon-host (Makefile.am): Likewise.
42896         * modules/canonicalize (Makefile.am): Likewise.
42897         * modules/chdir-long (Makefile.am): Likewise.
42898         * modules/chdir-safer (Makefile.am): Likewise.
42899         * modules/check-version (Makefile.am): Likewise.
42900         * modules/chown (Makefile.am): Likewise.
42901         * modules/cloexec (Makefile.am): Likewise.
42902         * modules/close-stream (Makefile.am): Likewise.
42903         * modules/closeout (Makefile.am): Likewise.
42904         * modules/crc (Makefile.am): Likewise.
42905         * modules/csharpexec (Makefile.am): Likewise.
42906         * modules/cycle-check (Makefile.am): Likewise.
42907         * modules/des (Makefile.am): Likewise.
42908         * modules/dev-ino (Makefile.am): Likewise.
42909         * modules/dirfd (Makefile.am): Likewise.
42910         * modules/dirname (Makefile.am): Likewise.
42911         * modules/dup2 (Makefile.am): Likewise.
42912         * modules/eealloc (Makefile.am): Likewise.
42913         * modules/error (Makefile.am): Likewise.
42914         * modules/euidaccess (Makefile.am): Likewise.
42915         * modules/exclude (Makefile.am): Likewise.
42916         * modules/exitfail (Makefile.am): Likewise.
42917         * modules/fcntl-safer (Makefile.am): Likewise.
42918         * modules/fcntl (Makefile.am): Likewise.
42919         * modules/file-type (Makefile.am): Likewise.
42920         * modules/fileblocks (Makefile.am): Likewise.
42921         * modules/filemode (Makefile.am): Likewise.
42922         * modules/filenamecat (Makefile.am): Likewise.
42923         * modules/fnmatch (Makefile.am): Likewise.
42924         * modules/fopen-safer (Makefile.am): Likewise.
42925         * modules/fpending (Makefile.am): Likewise.
42926         * modules/fprintftime (Makefile.am): Likewise.
42927         * modules/free (Makefile.am): Likewise.
42928         * modules/fsusage (Makefile.am): Likewise.
42929         * modules/ftruncate (Makefile.am): Likewise.
42930         * modules/fts (Makefile.am): Likewise.
42931         * modules/gc-arcfour (Makefile.am): Likewise.
42932         * modules/gc-des (Makefile.am): Likewise.
42933         * modules/gc-hmac-md5 (Makefile.am): Likewise.
42934         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
42935         * modules/gc-md4 (Makefile.am): Likewise.
42936         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
42937         * modules/gc-sha1 (Makefile.am): Likewise.
42938         * modules/gc (Makefile.am): Likewise.
42939         * modules/getaddrinfo (Makefile.am): Likewise.
42940         * modules/getcwd (Makefile.am): Likewise.
42941         * modules/getdelim (Makefile.am): Likewise.
42942         * modules/getdomainname (Makefile.am): Likewise.
42943         * modules/getgroups (Makefile.am): Likewise.
42944         * modules/gethostname (Makefile.am): Likewise.
42945         * modules/gethrxtime (Makefile.am): Likewise.
42946         * modules/getline (Makefile.am): Likewise.
42947         * modules/getloadavg (Makefile.am): Likewise.
42948         * modules/getlogin_r (Makefile.am): Likewise.
42949         * modules/getndelim2 (Makefile.am): Likewise.
42950         * modules/getopt (Makefile.am): Likewise.
42951         * modules/getpagesize (Makefile.am): Likewise.
42952         * modules/getpass-gnu (Makefile.am): Likewise.
42953         * modules/getpass (Makefile.am): Likewise.
42954         * modules/getsubopt (Makefile.am): Likewise.
42955         * modules/gettime (Makefile.am): Likewise.
42956         * modules/gettimeofday (Makefile.am): Likewise.
42957         * modules/getugroups (Makefile.am): Likewise.
42958         * modules/getusershell (Makefile.am): Likewise.
42959         * modules/glob (Makefile.am): Likewise.
42960         * modules/group-member (Makefile.am): Likewise.
42961         * modules/hard-locale (Makefile.am): Likewise.
42962         * modules/hash (Makefile.am): Likewise.
42963         * modules/hmac-md5 (Makefile.am): Likewise.
42964         * modules/hmac-sha1 (Makefile.am): Likewise.
42965         * modules/human (Makefile.am): Likewise.
42966         * modules/idcache (Makefile.am): Likewise.
42967         * modules/imaxabs (Makefile.am): Likewise.
42968         * modules/imaxdiv (Makefile.am): Likewise.
42969         * modules/inet_ntop (Makefile.am): Likewise.
42970         * modules/inet_pton (Makefile.am): Likewise.
42971         * modules/intprops (Makefile.am): Likewise.
42972         * modules/inttostr (Makefile.am): Likewise.
42973         * modules/inttypes (Makefile.am): Likewise.
42974         * modules/isapipe (Makefile.am): Likewise.
42975         * modules/javaversion (Makefile.am): Likewise.
42976         * modules/lchmod (Makefile.am): Likewise.
42977         * modules/lchown (Makefile.am): Likewise.
42978         * modules/localcharset (Makefile.am): Likewise.
42979         * modules/long-options (Makefile.am): Likewise.
42980         * modules/lstat (Makefile.am): Likewise.
42981         * modules/malloc (Makefile.am): Likewise.
42982         * modules/mathl (Makefile.am): Likewise.
42983         * modules/mbchar (Makefile.am): Likewise.
42984         * modules/md2 (Makefile.am): Likewise.
42985         * modules/md4 (Makefile.am): Likewise.
42986         * modules/md5 (Makefile.am): Likewise.
42987         * modules/memcasecmp (Makefile.am): Likewise.
42988         * modules/memchr (Makefile.am): Likewise.
42989         * modules/memcmp (Makefile.am): Likewise.
42990         * modules/memcoll (Makefile.am): Likewise.
42991         * modules/memcpy (Makefile.am): Likewise.
42992         * modules/memmem (Makefile.am): Likewise.
42993         * modules/memmove (Makefile.am): Likewise.
42994         * modules/mempcpy (Makefile.am): Likewise.
42995         * modules/memrchr (Makefile.am): Likewise.
42996         * modules/memset (Makefile.am): Likewise.
42997         * modules/memxor (Makefile.am): Likewise.
42998         * modules/mkancesdirs (Makefile.am): Likewise.
42999         * modules/mkdir-p (Makefile.am): Likewise.
43000         * modules/mkdir (Makefile.am): Likewise.
43001         * modules/mkdtemp (Makefile.am): Likewise.
43002         * modules/mkstemp (Makefile.am): Likewise.
43003         * modules/mktime (Makefile.am): Likewise.
43004         * modules/modechange (Makefile.am): Likewise.
43005         * modules/mountlist (Makefile.am): Likewise.
43006         * modules/nanosleep (Makefile.am): Likewise.
43007         * modules/obstack (Makefile.am): Likewise.
43008         * modules/openat (Makefile.am): Likewise.
43009         * modules/pagealign_alloc (Makefile.am): Likewise.
43010         * modules/pathmax (Makefile.am): Likewise.
43011         * modules/physmem (Makefile.am): Likewise.
43012         * modules/poll (Makefile.am): Likewise.
43013         * modules/posixtm (Makefile.am): Likewise.
43014         * modules/posixver (Makefile.am): Likewise.
43015         * modules/putenv (Makefile.am): Likewise.
43016         * modules/quote (Makefile.am): Likewise.
43017         * modules/quotearg (Makefile.am): Likewise.
43018         * modules/raise (Makefile.am): Likewise.
43019         * modules/read-file (Makefile.am): Likewise.
43020         * modules/readline (Makefile.am): Likewise.
43021         * modules/readlink (Makefile.am): Likewise.
43022         * modules/readtokens (Makefile.am): Likewise.
43023         * modules/readutmp (Makefile.am): Likewise.
43024         * modules/realloc (Makefile.am): Likewise.
43025         * modules/regex (Makefile.am): Likewise.
43026         * modules/rename-dest-slash (Makefile.am): Likewise.
43027         * modules/rename (Makefile.am): Likewise.
43028         * modules/rijndael (Makefile.am): Likewise.
43029         * modules/rmdir (Makefile.am): Likewise.
43030         * modules/rpmatch (Makefile.am): Likewise.
43031         * modules/safe-read (Makefile.am): Likewise.
43032         * modules/safe-write (Makefile.am): Likewise.
43033         * modules/same-inode (Makefile.am): Likewise.
43034         * modules/same (Makefile.am): Likewise.
43035         * modules/save-cwd (Makefile.am): Likewise.
43036         * modules/savedir (Makefile.am): Likewise.
43037         * modules/setenv (Makefile.am): Likewise.
43038         * modules/settime (Makefile.am): Likewise.
43039         * modules/sha1 (Makefile.am): Likewise.
43040         * modules/sig2str (Makefile.am): Likewise.
43041         * modules/snprintf (Makefile.am): Likewise.
43042         * modules/stat-macros (Makefile.am): Likewise.
43043         * modules/stat-time (Makefile.am): Likewise.
43044         * modules/stdbool (Makefile.am): Likewise.
43045         * modules/stdint (Makefile.am): Likewise.
43046         * modules/stdlib-safer (Makefile.am): Likewise.
43047         * modules/stpcpy (Makefile.am): Likewise.
43048         * modules/stpncpy (Makefile.am): Likewise.
43049         * modules/strcase (Makefile.am): Likewise.
43050         * modules/strcasestr (Makefile.am): Likewise.
43051         * modules/strchrnul (Makefile.am): Likewise.
43052         * modules/strcspn (Makefile.am): Likewise.
43053         * modules/strdup (Makefile.am): Likewise.
43054         * modules/strerror (Makefile.am): Likewise.
43055         * modules/strftime (Makefile.am): Likewise.
43056         * modules/strndup (Makefile.am): Likewise.
43057         * modules/strnlen (Makefile.am): Likewise.
43058         * modules/strpbrk (Makefile.am): Likewise.
43059         * modules/strsep (Makefile.am): Likewise.
43060         * modules/strstr (Makefile.am): Likewise.
43061         * modules/strtod (Makefile.am): Likewise.
43062         * modules/strtoimax (Makefile.am): Likewise.
43063         * modules/strtok_r (Makefile.am): Likewise.
43064         * modules/strtol (Makefile.am): Likewise.
43065         * modules/strtoll (Makefile.am): Likewise.
43066         * modules/strtoul (Makefile.am): Likewise.
43067         * modules/strtoull (Makefile.am): Likewise.
43068         * modules/strtoumax (Makefile.am): Likewise.
43069         * modules/strverscmp (Makefile.am): Likewise.
43070         * modules/sys_socket (Makefile.am): Likewise.
43071         * modules/sys_stat (Makefile.am): Likewise.
43072         * modules/sysexits (Makefile.am): Likewise.
43073         * modules/time_r (Makefile.am): Likewise.
43074         * modules/timegm (Makefile.am): Likewise.
43075         * modules/timespec (Makefile.am): Likewise.
43076         * modules/tmpfile-safer (Makefile.am): Likewise.
43077         * modules/trim (Makefile.am): Likewise.
43078         * modules/unistd-safer (Makefile.am): Likewise.
43079         * modules/unlinkdir (Makefile.am): Likewise.
43080         * modules/unlocked-io (Makefile.am): Likewise.
43081         * modules/userspec (Makefile.am): Likewise.
43082         * modules/utime (Makefile.am): Likewise.
43083         * modules/utimecmp (Makefile.am): Likewise.
43084         * modules/utimens (Makefile.am): Likewise.
43085         * modules/vasnprintf (Makefile.am): Likewise.
43086         * modules/vasprintf (Makefile.am): Likewise.
43087         * modules/vsnprintf (Makefile.am): Likewise.
43088         * modules/xalloc (Makefile.am): Likewise.
43089         * modules/xgetcwd (Makefile.am): Likewise.
43090         * modules/xnanosleep (Makefile.am): Likewise.
43091         * modules/xreadlink (Makefile.am): Likewise.
43092         * modules/xstrtod (Makefile.am): Likewise.
43093         * modules/xstrtol (Makefile.am): Likewise.
43094         * modules/xstrtold (Makefile.am): Likewise.
43095         * modules/yesno (Makefile.am): Likewise.
43096         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
43097
43098 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
43099
43100         * modules/error (Makefile.am): Distribute files through
43101         EXTRA_DIST, not lib_SOURCES.
43102
43103 2006-10-12  Eric Blake  <ebb9@byu.net>
43104
43105         * modules/error (Makefile.am): Distribute files in /lib.
43106         * modules/obstack (Makefile.am): Likewise.
43107
43108 2006-10-12  Bruno Haible  <bruno@clisp.org>
43109
43110         * modules/acl (Makefile.am): Distribute all files in lib/ through
43111         EXTRA_DIST.
43112         * modules/arcfour (Makefile.am): Likewise.
43113         * modules/arctwo (Makefile.am): Likewise.
43114         * modules/argmatch (Makefile.am): Likewise.
43115         * modules/argz (Makefile.am): Likewise.
43116         * modules/atexit (Makefile.am): Likewise.
43117         * modules/backupfile (Makefile.am): Likewise.
43118         * modules/c-strtod (Makefile.am): Likewise.
43119         * modules/c-strtold (Makefile.am): Likewise.
43120         * modules/calloc (Makefile.am): Likewise.
43121         * modules/canon-host (Makefile.am): Likewise.
43122         * modules/canonicalize (Makefile.am): Likewise.
43123         * modules/chdir-long (Makefile.am): Likewise.
43124         * modules/chdir-safer (Makefile.am): Likewise.
43125         * modules/check-version (Makefile.am): Likewise.
43126         * modules/chown (Makefile.am): Likewise.
43127         * modules/cloexec (Makefile.am): Likewise.
43128         * modules/close-stream (Makefile.am): Likewise.
43129         * modules/closeout (Makefile.am): Likewise.
43130         * modules/crc (Makefile.am): Likewise.
43131         * modules/cycle-check (Makefile.am): Likewise.
43132         * modules/des (Makefile.am): Likewise.
43133         * modules/dirfd (Makefile.am): Likewise.
43134         * modules/dirname (Makefile.am): Likewise.
43135         * modules/dup2 (Makefile.am): Likewise.
43136         * modules/euidaccess (Makefile.am): Likewise.
43137         * modules/exclude (Makefile.am): Likewise.
43138         * modules/exitfail (Makefile.am): Likewise.
43139         * modules/fcntl-safer (Makefile.am): Likewise.
43140         * modules/file-type (Makefile.am): Likewise.
43141         * modules/fileblocks (Makefile.am): Likewise.
43142         * modules/filemode (Makefile.am): Likewise.
43143         * modules/filenamecat (Makefile.am): Likewise.
43144         * modules/fnmatch (Makefile.am): Likewise.
43145         * modules/fopen-safer (Makefile.am): Likewise.
43146         * modules/fpending (Makefile.am): Likewise.
43147         * modules/fprintftime (Makefile.am): Likewise.
43148         * modules/free (Makefile.am): Likewise.
43149         * modules/fsusage (Makefile.am): Likewise.
43150         * modules/ftruncate (Makefile.am): Likewise.
43151         * modules/fts (Makefile.am): Likewise.
43152         * modules/gc (Makefile.am): Likewise.
43153         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
43154         * modules/getaddrinfo (Makefile.am): Likewise.
43155         * modules/getcwd (Makefile.am): Likewise.
43156         * modules/getdelim (Makefile.am): Likewise.
43157         * modules/getdomainname (Makefile.am): Likewise.
43158         * modules/getgroups (Makefile.am): Likewise.
43159         * modules/gethostname (Makefile.am): Likewise.
43160         * modules/gethrxtime (Makefile.am): Likewise.
43161         * modules/getline (Makefile.am): Likewise.
43162         * modules/getloadavg (Makefile.am): Likewise.
43163         * modules/getlogin_r (Makefile.am): Likewise.
43164         * modules/getopt (Makefile.am): Likewise.
43165         * modules/getpass (Makefile.am): Likewise.
43166         * modules/getpass-gnu (Makefile.am): Likewise.
43167         * modules/getsubopt (Makefile.am): Likewise.
43168         * modules/gettime (Makefile.am): Likewise.
43169         * modules/gettimeofday (Makefile.am): Likewise.
43170         * modules/getugroups (Makefile.am): Likewise.
43171         * modules/getusershell (Makefile.am): Likewise.
43172         * modules/glob (Makefile.am): Likewise.
43173         * modules/group-member (Makefile.am): Likewise.
43174         * modules/hard-locale (Makefile.am): Likewise.
43175         * modules/hash (Makefile.am): Likewise.
43176         * modules/hmac-md5 (Makefile.am): Likewise.
43177         * modules/hmac-sha1 (Makefile.am): Likewise.
43178         * modules/human (Makefile.am): Likewise.
43179         * modules/idcache (Makefile.am): Likewise.
43180         * modules/imaxabs (Makefile.am): Likewise.
43181         * modules/imaxdiv (Makefile.am): Likewise.
43182         * modules/inet_ntop (Makefile.am): Likewise.
43183         * modules/inet_pton (Makefile.am): Likewise.
43184         * modules/inttostr (Makefile.am): Likewise.
43185         * modules/isapipe (Makefile.am): Likewise.
43186         * modules/lchown (Makefile.am): Likewise.
43187         * modules/long-options (Makefile.am): Likewise.
43188         * modules/lstat (Makefile.am): Likewise.
43189         * modules/malloc (Makefile.am): Likewise.
43190         * modules/mathl (Makefile.am): Likewise.
43191         * modules/mbchar (Makefile.am): Likewise.
43192         * modules/md2 (Makefile.am): Likewise.
43193         * modules/md4 (Makefile.am): Likewise.
43194         * modules/md5 (Makefile.am): Likewise.
43195         * modules/memcasecmp (Makefile.am): Likewise.
43196         * modules/memchr (Makefile.am): Likewise.
43197         * modules/memcmp (Makefile.am): Likewise.
43198         * modules/memcoll (Makefile.am): Likewise.
43199         * modules/memcpy (Makefile.am): Likewise.
43200         * modules/memmem (Makefile.am): Likewise.
43201         * modules/memmove (Makefile.am): Likewise.
43202         * modules/mempcpy (Makefile.am): Likewise.
43203         * modules/memrchr (Makefile.am): Likewise.
43204         * modules/memset (Makefile.am): Likewise.
43205         * modules/memxor (Makefile.am): Likewise.
43206         * modules/mkancesdirs (Makefile.am): Likewise.
43207         * modules/mkdir (Makefile.am): Likewise.
43208         * modules/mkdir-p (Makefile.am): Likewise.
43209         * modules/mkdtemp (Makefile.am): Likewise.
43210         * modules/mkstemp (Makefile.am): Likewise.
43211         * modules/mktime (Makefile.am): Likewise.
43212         * modules/modechange (Makefile.am): Likewise.
43213         * modules/mountlist (Makefile.am): Likewise.
43214         * modules/nanosleep (Makefile.am): Likewise.
43215         * modules/openat (Makefile.am): Likewise.
43216         * modules/pagealign_alloc (Makefile.am): Likewise.
43217         * modules/physmem (Makefile.am): Likewise.
43218         * modules/poll (Makefile.am): Likewise.
43219         * modules/posixtm (Makefile.am): Likewise.
43220         * modules/posixver (Makefile.am): Likewise.
43221         * modules/putenv (Makefile.am): Likewise.
43222         * modules/quote (Makefile.am): Likewise.
43223         * modules/quotearg (Makefile.am): Likewise.
43224         * modules/raise (Makefile.am): Likewise.
43225         * modules/read-file (Makefile.am): Likewise.
43226         * modules/readline (Makefile.am): Likewise.
43227         * modules/readlink (Makefile.am): Likewise.
43228         * modules/readtokens (Makefile.am): Likewise.
43229         * modules/readutmp (Makefile.am): Likewise.
43230         * modules/realloc (Makefile.am): Likewise.
43231         * modules/regex (Makefile.am): Likewise.
43232         * modules/rename (Makefile.am): Likewise.
43233         * modules/rename-dest-slash (Makefile.am): Likewise.
43234         * modules/rijndael (Makefile.am): Likewise.
43235         * modules/rmdir (Makefile.am): Likewise.
43236         * modules/rpmatch (Makefile.am): Likewise.
43237         * modules/safe-read (Makefile.am): Likewise.
43238         * modules/safe-write (Makefile.am): Likewise.
43239         * modules/same (Makefile.am): Likewise.
43240         * modules/save-cwd (Makefile.am): Likewise.
43241         * modules/savedir (Makefile.am): Likewise.
43242         * modules/setenv (Makefile.am): Likewise.
43243         * modules/settime (Makefile.am): Likewise.
43244         * modules/sha1 (Makefile.am): Likewise.
43245         * modules/sig2str (Makefile.am): Likewise.
43246         * modules/snprintf (Makefile.am): Likewise.
43247         * modules/stdlib-safer (Makefile.am): Likewise.
43248         * modules/stpcpy (Makefile.am): Likewise.
43249         * modules/stpncpy (Makefile.am): Likewise.
43250         * modules/strcase (Makefile.am): Likewise.
43251         * modules/strcasestr (Makefile.am): Likewise.
43252         * modules/strchrnul (Makefile.am): Likewise.
43253         * modules/strcspn (Makefile.am): Likewise.
43254         * modules/strdup (Makefile.am): Likewise.
43255         * modules/strerror (Makefile.am): Likewise.
43256         * modules/strftime (Makefile.am): Likewise.
43257         * modules/strndup (Makefile.am): Likewise.
43258         * modules/strnlen (Makefile.am): Likewise.
43259         * modules/strpbrk (Makefile.am): Likewise.
43260         * modules/strsep (Makefile.am): Likewise.
43261         * modules/strstr (Makefile.am): Likewise.
43262         * modules/strtod (Makefile.am): Likewise.
43263         * modules/strtoimax (Makefile.am): Likewise.
43264         * modules/strtok_r (Makefile.am): Likewise.
43265         * modules/strtol (Makefile.am): Likewise.
43266         * modules/strtoll (Makefile.am): Likewise.
43267         * modules/strtoul (Makefile.am): Likewise.
43268         * modules/strtoull (Makefile.am): Likewise.
43269         * modules/strtoumax (Makefile.am): Likewise.
43270         * modules/strverscmp (Makefile.am): Likewise.
43271         * modules/time_r (Makefile.am): Likewise.
43272         * modules/timegm (Makefile.am): Likewise.
43273         * modules/tmpfile-safer (Makefile.am): Likewise.
43274         * modules/unistd-safer (Makefile.am): Likewise.
43275         * modules/unlinkdir (Makefile.am): Likewise.
43276         * modules/userspec (Makefile.am): Likewise.
43277         * modules/utime (Makefile.am): Likewise.
43278         * modules/utimecmp (Makefile.am): Likewise.
43279         * modules/utimens (Makefile.am): Likewise.
43280         * modules/vasnprintf (Makefile.am): Likewise.
43281         * modules/vasprintf (Makefile.am): Likewise.
43282         * modules/vsnprintf (Makefile.am): Likewise.
43283         * modules/xalloc (Makefile.am): Likewise.
43284         * modules/xgetcwd (Makefile.am): Likewise.
43285         * modules/xnanosleep (Makefile.am): Likewise.
43286         * modules/xreadlink (Makefile.am): Likewise.
43287         * modules/xstrtod (Makefile.am): Likewise.
43288         * modules/xstrtol (Makefile.am): Likewise.
43289         * modules/xstrtold (Makefile.am): Likewise.
43290         * modules/yesno (Makefile.am): Likewise.
43291
43292 2006-10-12  Jim Meyering  <jim@meyering.net>
43293
43294         * m4/getloadavg.m4: Revert the change below.
43295
43296         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
43297         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
43298         fail with a symlink, which is what coreutils' ./bootstrap now
43299         creates by default.
43300
43301 2006-10-12  Bruno Haible  <bruno@clisp.org>
43302
43303         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
43304         mingw.
43305         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
43306         MSVC and mingw explicitly.
43307
43308 2006-10-11  Simon Josefsson  <jas@extundo.com>
43309             Bruno Haible  <bruno@clisp.org>
43310
43311         Add support for multiple gnulib-tool invocations in the scope of a
43312         single configure.ac file.
43313         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
43314         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
43315         with the same contents as the _LIBADD variable.
43316         (func_emit_initmacro_start, func_emit_initmacro_end,
43317         func_emit_initmacro_done): New functions.
43318         (func_import, func_create_testdir): Invoke them. Allow the identifiers
43319         gl_LIBOBJS and gl_LTLIBOBJS.
43320
43321 2006-10-11  Bruno Haible  <bruno@clisp.org>
43322
43323         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
43324         (func_create_testdir): Don't create po/Makefile.am, don't invoke
43325         autoreconf. Instead, invoke autopoint explicitly but move back the
43326         *.m4 files from gnulib.
43327
43328 2006-10-11  Bruno Haible  <bruno@clisp.org>
43329
43330         * gnulib-tool (func_usage): Make module names after --create-testdir
43331         optional.
43332         (func_create_testdir): If no module was specified, use nearly all
43333         modules.
43334
43335 2006-10-12  Jim Meyering  <jim@meyering.net>
43336
43337         Big performance improvement for fts-based tools that use FTS_NOSTAT.
43338         Avoid spurious inode-mismatch problems on non-POSIX file systems.
43339         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
43340         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
43341         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
43342         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
43343         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
43344         (fts_set_stat_required): New function.
43345         (fts_open): Defer the calls to fts_stat, if possible or requested.
43346         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
43347         into fts_stat itself.
43348         (fts_read): Perform any required (deferred) fts_stat call.
43349         (fts_build): Likewise, for the directory we're about to open and read.
43350         In the readdir loop, carefully decide whether each entry will require
43351         an eventual call to fts_stat, using dirent.d_type info if available.
43352         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
43353         a command line argument into this function.  Update all callers.
43354         Map a return value of FTS_DOT to FTS_D for a command line argument.
43355         * modules/fts (Depends-on): Add d-type.  Alphabetize.
43356         Thanks to Miklos Szeredi for his tenacity and for the initial
43357         bug report about "find" failing on a FUSE-based file system.
43358
43359         * lib/fts.c (fts_open): Use consistent indentation.
43360
43361 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
43362
43363         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
43364         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
43365         reported by Jim Meyering.  All uses of cache variables renamed
43366         to match Autoconf's.
43367         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
43368         the other one.
43369
43370         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
43371         Fix misspelling in diagnostic.
43372
43373 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
43374
43375         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
43376         defined.  Problem reported by Matthew Woehlke.
43377
43378         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
43379         Add support for Tandem NonStop R series.
43380         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
43381         Use new macro.
43382
43383         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
43384         (has_trailing_slash): Omit size arg; all callers changed.
43385         Omit 'inline', since it doesn't help performance and we'd
43386         need to configure it.
43387         Don't count //, ///, etc. as having a trailing slash.
43388         As a side effect, this removes a C99ism reported by Matthew Woehlke.
43389         (rpl_rename_dest_slash): On failure, use rename's errno rather
43390         than (in some cases) an incorrect or junk errno.
43391         Simplify code by removing need to compute length; this does
43392         cause it to make two passes instead of one over the file name,
43393         but it's worth it.
43394
43395         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
43396         change, since Autoconf's version may no longer be appropriate now
43397         that we are using CVS Autoconf's version.  Add support for Tandem.
43398
43399 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
43400             Bruno Haible  <bruno@clisp.org>
43401
43402         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
43403         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
43404         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
43405         gl_AC_TYPE_LONG_LONG.
43406
43407         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
43408         instead of HAVE_LONG_LONG.
43409         * lib/printf-args.c (printf_fetchargs): Likewise.
43410         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
43411         * lib/vasnprintf.c (VASNPRINTF): Likewise.
43412         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
43413         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
43414         gl_AC_TYPE_LONG_LONG.
43415
43416 2006-10-11  Bruno Haible  <bruno@clisp.org>
43417
43418         * m4/longlong.m4: Add comments.
43419         * m4/ulonglong.m4: Likewise.
43420
43421 2006-10-10  Bruno Haible  <bruno@clisp.org>
43422
43423         Make it possible to #define stpcpy, strdup to aliases.
43424         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
43425         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
43426
43427 2006-10-10  Bruno Haible  <bruno@clisp.org>
43428
43429         Make it possible to #define gcd to an alias.
43430         * lib/gcd.c: Include config.h.
43431
43432 2006-10-10  Bruno Haible  <bruno@clisp.org>
43433
43434         Make it possible to #define c_isascii to an alias.
43435         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
43436         defined. Undefine the macros before defining them, to avoid gcc
43437         warnings.
43438         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
43439         define NO_C_CTYPE_MACROS early.
43440
43441 2006-10-10  Bruno Haible  <bruno@clisp.org>
43442
43443         Make it possible to #define set_program_name to an alias.
43444         * lib/progname.c: Don't undefine set_program_name; instead, undefine
43445         ENABLE_RELOCATABLE early.
43446
43447 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
43448
43449         Port to Tandem NSK OSS, which has 64-bit signed int but at most
43450         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
43451         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
43452         More generally, don't assume that 64-bit signed int is available
43453         if unsigned int is, and vice versa.
43454         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
43455         unsigned symbols, not on their signed counterparts.
43456         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
43457         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
43458         (UINT64_C, UINTMAX_C):
43459         Likewise.
43460         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
43461         unsigned counterparts.
43462         (Have_long_long, Unsigned): New macros.
43463         (Int): Renamed from INT.
43464         (strtoimax): Use the new macros.
43465         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
43466         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
43467         * modules/inttypes (inttypes.h): Substitute
43468         HAVE_UNSIGNED_LONG_LONG_INT.
43469         * modules/stdint (stdint.h): Likewise.
43470         (Files): Add m4/ulonglong.m4.
43471
43472 2006-10-10  Bruno Haible  <bruno@clisp.org>
43473
43474         Fix a gcc -Wshadow warning.
43475         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
43476         to 'bucket'.
43477         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
43478         gl_linked_indexof_from_to): Likewise.
43479         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
43480         Likewise.
43481         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
43482         Likewise.
43483         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
43484         Reported by Eric Blake.
43485
43486 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
43487
43488         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
43489         for NetBSD.  Problem reported by Bruno Haible.
43490
43491 2006-10-09  Jim Meyering  <jim@meyering.net>
43492
43493         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
43494         Patch from Bruno Haible.
43495
43496 2006-10-09  Jim Meyering  <jim@meyering.net>
43497
43498         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
43499         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
43500         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
43501
43502 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
43503
43504         Don't include <config.h> twice; this doesn't work in some cases,
43505         e.g., when config.h has "#define intmax_t long long int" and
43506         we include <config.h>, <inttypes.h>, <config.h> in that order.
43507         Problem reported by Matthew Woehlke in:
43508         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
43509         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
43510         * lib/fts-cycle.c: Don't include config.h.
43511         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
43512         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
43513         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
43514         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
43515         inttypes.h.
43516         * lib/xstrtoumax.c: Likewise.
43517         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
43518         __strtol and the like, so that this module is more like its siblings.
43519         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
43520         Remove; no longer needed now that we assume gnulib inttypes.h.
43521
43522 2006-10-08  Bruno Haible  <bruno@clisp.org>
43523
43524         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
43525         option.
43526
43527 2006-10-07  Jim Meyering  <jim@meyering.net>
43528
43529         * modules/inttypes (inttypes.h): Revert what seems to have been
43530         an inadvertent part of today's change: use "|", not "/" in the
43531         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
43532
43533 2006-10-07  Bruno Haible  <bruno@clisp.org>
43534
43535         * modules/sublist: New file.
43536
43537 2006-10-07  Bruno Haible  <bruno@clisp.org>
43538
43539         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
43540         * modules/argz (argz.h): Likewise.
43541         * modules/arpa_inet (arpa/inet.h): Likewise.
43542         * modules/byteswap (byteswap.h): Likewise.
43543         * modules/configmake (configmake.h): Likewise.
43544         * modules/fcntl (fcntl.h): Likewise.
43545         * modules/fnmatch (fnmatch.h): Likewise.
43546         * modules/getopt (getopt.h): Likewise.
43547         * modules/glob (glob.h): Likewise.
43548         * modules/inttypes (inttypes.h): Likewise.
43549         * modules/netinet_in (netinet/in.h): Likewise.
43550         * modules/poll (poll.h): Likewise.
43551         * modules/stdbool (stdbool.h): Likewise.
43552         * modules/stdint (stdint.h): Likewise.
43553         * modules/sys_select (sys/select.h): Likewise.
43554         * modules/sys_socket (sys/socket.h): Likewise.
43555         * modules/sys_stat (sys/stat.h): Likewise.
43556         * modules/sysexits (sysexits.h): Likewise.
43557         * modules/unistd (unistd.h): Likewise.
43558         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
43559         Add a "DO NOT EDIT" comment to the generated file.
43560         (func_import): Likewise for gnulib-comp.m4.
43561
43562 2006-10-07  Bruno Haible  <bruno@clisp.org>
43563
43564         * lib/gl_sublist.h: New file.
43565         * lib/gl_sublist.c: New file.
43566
43567 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
43568
43569         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
43570         name (relative to the original working directory) and the file
43571         name component (relative to the temporary working directory).  All
43572         callers changed.
43573         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
43574         * lib/mkdir-p.c (make_dir_parents): Likewise.
43575         * lib/mkdir-p.h (make_dir_parents): Likewise.
43576
43577 2006-10-06  Eric Blake  <ebb9@byu.net>
43578
43579         Define several macros for use by the clean-temp module.
43580         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
43581         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
43582         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
43583
43584         * lib/clean-temp.h (close_stream_temp): New declaration.
43585         * lib/clean-temp.c (includes): Pull in headers according to what
43586         other modules are in use.
43587         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
43588
43589 2006-10-06  Bruno Haible  <bruno@clisp.org>
43590
43591         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
43592         instead of fopen, fwriteerror.
43593
43594 2006-10-06  Bruno Haible  <bruno@clisp.org>
43595
43596         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
43597         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
43598         int.
43599         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
43600         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
43601         Return an error indicator.
43602         Suggested by Eric Blake.
43603
43604 2006-10-06  Bruno Haible  <bruno@clisp.org>
43605
43606         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
43607         Reported by Eric Blake.
43608
43609 2006-10-06  Bruno Haible  <bruno@clisp.org>
43610
43611         * modules/closeout (Description): Mention stderr too.
43612
43613 2006-10-06  Bruno Haible  <bruno@clisp.org>
43614         and Paul Eggert  <eggert@cs.ucla.edu>
43615
43616         * lib/closeout.c (close_stdout): Also close stderr.
43617         * lib/closeout.h: Update comment.
43618
43619 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
43620
43621         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
43622         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
43623         * lib/dirchownmod.c: Include lchown.h.
43624         * lib/lchown.c: Don't include files that lchown.h now includes.
43625         Don't declare chown, since lchown.h now does that.
43626         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
43627         (lchown): Define to rpl_chown if lchown is declared but
43628         does not exist.  Declare using a prototype if lchown is not
43629         declared.  Add a copyright notice.
43630         * lib/mkstemp.h: Include <unistd.h>.
43631         * lib/openat.c: Include lchown.h.
43632
43633         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
43634         we now test for that separately.
43635         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
43636         rather than O_NOFOLLOW, when testing whether it's possible to
43637         avoid a race condition reliably.
43638         * lib/savewd.c (savewd_chdir): Likewise.
43639
43640         Remove macros that are no longer needed now that stdint.h is
43641         reliable.
43642         * lib/fsusage.c (UINTMAX_MAX): Remove.
43643         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
43644         * lib/utimecmp.c (SIZE_MAX): Remove.
43645
43646         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
43647
43648         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
43649         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
43650         O_NOATIME works.
43651
43652 2006-10-05  Bruno Haible  <bruno@clisp.org>
43653
43654         * lib/gl_list.h (gl_sortedlist_search_from_to,
43655         gl_sortedlist_indexof_from_to): New declarations.
43656         (gl_list_implementation): New fields sortedlist_search_from_to,
43657         sortedlist_indexof_from_to.
43658         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
43659         inline functions.
43660         * lib/gl_list.c (gl_sortedlist_search_from_to,
43661         gl_sortedlist_indexof_from_to): New functions.
43662         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
43663         function.
43664         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
43665         (gl_array_sortedlist_search_from_to): New function.
43666         (gl_array_list_implementation): Update.
43667         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
43668         function.
43669         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
43670         (gl_carray_sortedlist_search_from_to): New function.
43671         (gl_carray_list_implementation): Update.
43672         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
43673         gl_linked_sortedlist_indexof_from_to): New functions.
43674         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
43675         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
43676         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
43677         gl_tree_sortedlist_indexof_from_to): New functions.
43678         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
43679         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
43680         Update.
43681         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
43682         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
43683         Update.
43684
43685 2006-10-05  Bruno Haible  <bruno@clisp.org>
43686
43687         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
43688         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
43689         (struct gl_list_implementation): Add fields search_from_to,
43690         indexof_from_to. Remove fields search, indexof.
43691         (gl_list_search): Use the search_from_to method.
43692         (gl_list_search_from, gl_list_search_from_to): New functions.
43693         (gl_list_indexof): Use the indexof_from_to method.
43694         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
43695         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
43696         (gl_list_search_from, gl_list_search_from_to): New functions.
43697         (gl_list_indexof): Use the indexof_from_to method.
43698         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
43699         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
43700         gl_array_indexof. Add start_index, end_index arguments.
43701         (gl_array_search_from_to): Renamed from gl_array_search. Add
43702         start_index, end_index arguments.
43703         (gl_array_remove, gl_array_list_implementation): Update.
43704         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
43705         gl_carray_indexof. Add start_index, end_index arguments.
43706         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
43707         start_index, end_index arguments.
43708         (gl_carray_remove, gl_carray_list_implementation): Update.
43709         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
43710         gl_linked_search. Add start_index, end_index arguments.
43711         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
43712         start_index, end_index arguments.
43713         (gl_linked_remove): Update.
43714         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
43715         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
43716         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
43717         field to 'size_t'.
43718         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
43719         gl_tree_search. Add start_index, end_index arguments.
43720         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
43721         start_index, end_index arguments.
43722         (gl_tree_remove): Update.
43723         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
43724         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
43725         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
43726         function.
43727         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
43728         gl_tree_search. Add start_index, end_index arguments.
43729         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
43730         start_index, end_index arguments.
43731         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
43732         Update.
43733         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
43734
43735 2006-10-05  Bruno Haible  <bruno@clisp.org>
43736
43737         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
43738
43739         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
43740         fwriteerror_temp): New declarations.
43741         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
43742         (descriptors): New variable.
43743         (cleanup): First, close the descriptors.
43744         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
43745         fclose_temp, fwriteerror_temp): New functions.
43746
43747 2006-10-04  Jim Meyering  <jim@meyering.net>
43748
43749         * lib/fts.c (fts_open): Tiny comment change.
43750
43751 2006-10-04  Bruno Haible  <bruno@clisp.org>
43752
43753         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
43754         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
43755         gl_LOCK_BODY.
43756         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
43757         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
43758         gl_LOCK_EARLY_BODY.
43759         (gl_LOCK): Require gl_LOCK_BODY.
43760
43761 2006-10-04  Bruno Haible  <bruno@clisp.org>
43762
43763         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
43764         (gl_oset_search_atleast): New declaration.
43765         (struct gl_oset_implementation): Add field 'search_atleast'.
43766         (gl_oset_search_atleast): New inline function.
43767         * lib/gl_oset.c (gl_oset_search_atleast): New function.
43768         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
43769         (gl_array_oset_implementation): Update.
43770         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
43771         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
43772         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
43773
43774 2006-10-04  Bruno Haible  <bruno@clisp.org>
43775
43776         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
43777
43778 2006-10-03  Bruno Haible  <bruno@clisp.org>
43779
43780         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
43781         from gl_avltreehash_list_implementation.
43782
43783 2006-10-03  Bruno Haible  <bruno@clisp.org>
43784
43785         * lib/gl_oset.c (gl_oset_add): Fix return type.
43786
43787 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
43788
43789         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
43790
43791 2006-10-02  Eric Blake  <ebb9@byu.net>
43792
43793         * modules/strnlen (Depends-on): Add extensions.
43794
43795 2006-10-02  Eric Blake  <ebb9@byu.net>
43796
43797         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
43798         definition in 2.60+.
43799
43800 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
43801
43802         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
43803         checks.
43804
43805 2006-10-02  Bruno Haible  <bruno@clisp.org>
43806
43807         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
43808         to the AUTOMAKE_OPTIONS.
43809         Reported by Jim Meyering.
43810
43811 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
43812
43813         Work around bug in Solaris 10 /proc file system:
43814         /proc/self/fd/NNN/.. isn't the parent directory of
43815         the directory whose file descriptor is NNN.  This needs to
43816         be worked around at run time, not compile time, since a
43817         program might be built on Solaris 8, where things work, and
43818         run on Solaris 10.
43819         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
43820         to use the following interface instead:
43821         (OPENAT_BUFFER_SIZE): New macro.
43822         (openat_proc_name): New function.
43823         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
43824         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
43825         Likewise.
43826         * lib/openat-proc.c: New file.
43827         * modules/openat (Files): Add lib/openat-proc.c.
43828         (Depends-on): Add same-inode, stdbool.
43829         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
43830
43831 2006-09-29  Bruno Haible  <bruno@clisp.org>
43832
43833         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
43834         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
43835         argument. Set stdout_closed before testing for ferror, not after.
43836         (fwriteerror, fwriteerror_no_ebadf): New functions.
43837
43838 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43839
43840         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
43841
43842 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
43843
43844         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
43845         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
43846
43847 2006-09-28  Jim Meyering  <jim@meyering.net>
43848
43849         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
43850         Include <unistd.h>.
43851
43852 2006-09-28  Bruno Haible  <bruno@clisp.org>
43853
43854         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
43855         * modules/linkedhash-list (Depends-on): Likewise.
43856         * modules/rbtreehash-list (Depends-on): Likewise.
43857
43858 2006-09-28  Bruno Haible  <bruno@clisp.org>
43859
43860         * lib/strndup.h: Simplify the redefinition of strndup.
43861         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
43862         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
43863
43864 2006-09-28  Bruno Haible  <bruno@clisp.org>
43865
43866         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
43867         * lib/gl_linkedhash_list.c: Likewise.
43868         * lib/gl_rbtreehash_list.c: Likewise.
43869
43870 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
43871
43872         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
43873         getaddrinfo.
43874
43875         * lib/__fpending.h: Don't include <stdio_ext.h> unless
43876         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
43877         it causes <stdio_ext.h> to cause a compile-time error.
43878         Problem reported by Nelson H. F. Beebe.
43879         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
43880         of HAVE_DECL___PENDING.
43881
43882         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
43883         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
43884         declaration.
43885
43886 2006-09-27  Jim Meyering  <jim@meyering.net>
43887
43888         This file could end up with a definition for a function
43889         named __strndup, rather than rpl_strndup on a system with
43890         incomplete weak_alias support.
43891         * lib/strndup.c (strndup): Rename from __strndup.
43892         Remove #defines that used to map __strndup to strndup.
43893         Don't use K&R prototypes.
43894         Remove LIBC-related code, since this file is not sync'd with glibc.
43895         * lib/strndup.h: Revamp, accordingly.
43896         * m4/strndup.m4: Modernize.
43897
43898 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
43899
43900         * modules/savewd (Depends-on): Add 'raise'.
43901         * lib/savewd.c: Include <signal.h>, for 'raise'.
43902
43903 2006-09-26  Jim Meyering  <jim@meyering.net>
43904
43905         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
43906         when we detect Darwin 8.7.0's acl_get_file bug.
43907         Rearrange to perform the new (below) run-test while $LIBS
43908         contains any acl-related library.  Set USE_ACL at the end.
43909         (gl_ACL_GET_FILE): New function.
43910
43911 2006-09-26  Eric Blake  <ebb9@byu.net>
43912
43913         * lib/verror.c: Include <config.h> unconditionally.
43914
43915 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
43916
43917         * modules/clock-time (Maintainer): Add self.
43918         * modules/getlogin_r (Depends-on): Add extensions.
43919
43920 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43921
43922         * modules/clock-time: New module.
43923         * modules/nanosleep (Depends-on): Add clock-time.
43924         * modules/gethrxtime (Depends-on): Likewise.
43925         * modules/gettime (Depends-on): Likewise.
43926         * modules/settime (Depends-on): Likewise.
43927
43928         * modules/fts-lgpl: Depend on openat.
43929         * modules/mkancesdirs: Depend on savewd.
43930         * modules/mkdir-p: Likewise.
43931
43932 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43933
43934         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
43935
43936         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
43937         `gl_have_arbitrary_file_name_length_limit' to
43938         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
43939         actually works between configure runs.
43940
43941 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43942             Bruno Haible  <bruno@clisp.org>
43943
43944         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
43945
43946 2006-09-25  Jim Meyering  <jim@meyering.net>
43947
43948         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
43949         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
43950
43951 2006-09-25  Eric Blake  <ebb9@byu.net>
43952
43953         * gnulib-tool (func_import, func_create_testdir): Fix typos in
43954         exec's in 2006-09-18 patch when shuffling fds.
43955
43956 2006-09-25  Bruno Haible  <bruno@clisp.org>
43957
43958         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
43959         Reported by Jim Meyering.
43960
43961 2006-09-24  Jim Meyering  <jim@meyering.net>
43962
43963         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
43964         compare a pointer against a literal "0".  That caused failures with
43965         at least HP-UX's hpcc.
43966
43967 2006-09-22  Simon Josefsson  <jas@extundo.com>
43968
43969         * modules/gc-sha1:
43970         * modules/gc-md4:
43971         * modules/gc-hmac-sha1:
43972         * modules/gc-hmac-md5:
43973         * modules/gc-des:
43974         * modules/gc-arcfour: Distribute more files.
43975
43976 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43977
43978         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
43979         (gl_linked_iterator_from_to): Initialize struct completely.
43980         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
43981         (gl_tree_iterator_from_to): Likewise
43982         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
43983         * lib/gl_array_list.c [lint] (gl_array_iterator)
43984         (gl_array_iterator_from_to): Likewise.
43985         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
43986         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
43987         (gl_carray_iterator_from_to): Likewise.
43988
43989         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
43990         * lib/md4.c (md4_process_block): Remove unused variable.
43991         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
43992         parentheses for clarity.
43993
43994 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43995
43996         * modules/bison-i18n (Depends-on): Add gettext.
43997
43998 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
43999
44000         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
44001         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
44002         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
44003         also add missing comma that caused broken test.
44004         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
44005         stdlib.h, for `abort'.
44006         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
44007         variables.
44008         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
44009         include unistd.h if present, for `rmdir'.
44010         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
44011         variables.
44012         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
44013         in the process include standard headers for prototypes.
44014         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
44015         gets declared on GNU/Linux.
44016         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
44017         unistd.h, for `rmdir'.
44018         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
44019
44020         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
44021         always true.
44022         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
44023
44024         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
44025
44026 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44027
44028         * gnulib-tool (func_version): Create output all at once.  This
44029         may help avoid triggering unnecessary SIGPIPEs, and at any
44030         rate it doesn't hurt.
44031
44032 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44033             Bruno Haible  <bruno@clisp.org>
44034
44035         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
44036         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
44037         * m4/signed.m4 (bh_C_SIGNED): Likewise.
44038
44039         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
44040         (gl_FUNC_VASPRINTF): Invoke it.
44041
44042 2006-09-22  Bruno Haible  <bruno@clisp.org>
44043
44044         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
44045         getloadavg.c as first argument.
44046
44047 2006-09-22  Bruno Haible  <bruno@clisp.org>
44048
44049         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
44050         at the beginning of the gl_INIT macro.
44051         * modules/getloadavg (configure.ac): Pass $gl_source_base to
44052         gl_GETLOADAVG.
44053
44054 2006-09-22  Bruno Haible  <bruno@clisp.org>
44055
44056         * gnulib-tool (func_create_megatestdir): Don't include the config-h
44057         module.
44058         Suggested by Ralf Wildenhues.
44059
44060 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
44061
44062         Import this patch from libc:
44063
44064         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
44065
44066         * lib/regex_internal.c (re_string_reconstruct): Handle
44067         offset < pstr->valid_raw_len && pstr->offsets_needed case.
44068         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
44069         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
44070         re_string_context_at.
44071
44072         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
44073         now requires it.
44074         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
44075         gl_REGEX now does it for us.
44076         (gl_REGEX): Add test taken from
44077         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
44078
44079         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
44080         Check that large offsets work.  Modernize Autoconf usages.
44081         Prefer "yes" to mean a good thing rather than a bad.
44082         Don't put "#define mkstemp" in config.h, as this might interfere
44083         with standard system headers that "#define mkstemp mkstemp64".
44084
44085         * modules/mkstemp (Depends-on): Add extensions, so that
44086         mkstemp is visible on some platforms.
44087         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
44088         (Include): Change to "mkstemp.h" from <stdlib.h>.
44089         (Files): Add mkstemp.h.
44090
44091         * lib/mkstemp.h: New file, since some standard headers
44092         #define mkstemp.
44093         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
44094         Include "mkstemp.h".
44095         Make the _LIBC code resemble glibc original more,
44096         e.g., use K&R style.
44097         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
44098         (mkstemp): Remove, since mkstemp.h does this for us.
44099         * lib/stdlib--.h: Include mkstemp.h.
44100
44101         Import this patch from libc:
44102
44103         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
44104
44105         * lib/tempname.c (__gen_tempname): Change attempts_min
44106         into a macro.  Use preprocessor to decide how to initialize
44107         attempts [Coverity CID 67].
44108
44109 2006-09-20  Bruno Haible  <bruno@clisp.org>
44110
44111         * lib/mkdtemp.c: Import from libc.
44112         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
44113                 * sysdeps/posix/tempname.c (__gen_tempname): Change
44114                 attempts_min into a macro.  Use preprocessor to decide how to
44115                 initialize attempts [Coverity CID 67].
44116         2001-11-27  Paul Eggert  <eggert@twinsun.com>
44117                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
44118                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
44119
44120 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44121
44122         * gnulib-tool (func_exit): New function, to allow to pass the
44123         exit status portably through the trap.  Use everywhere.
44124         (--help, --version): Signal a write error.
44125         (trap): catch SIGPIPE, for write errors.
44126         Exit at the end of the trap, with the correct exit status.
44127
44128 2006-09-19  Karl Berry  <karl@gnu.org>
44129
44130         * doc/gnulib.texi: note about the license texinfo files.
44131
44132 2006-09-19  Eric Blake  <ebb9@byu.net>
44133
44134         * gnulib-tool: Avoid space-tab.
44135
44136 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
44137
44138         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
44139         that prevented coreutils 6.1 from building.  Problem reported
44140         by Petter Reinholdtsen.
44141
44142 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
44143
44144         * gnulib-tool (avoidlist): Fix typo that broke options like
44145         --avoid=lock that are used by coreutils bootstrap.
44146
44147 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
44148
44149         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
44150         more systematically.
44151
44152 2006-09-18  Jim Meyering  <jim@meyering.net>
44153
44154         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
44155
44156 2006-09-18  Bruno Haible  <bruno@clisp.org>
44157
44158         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
44159
44160 2006-09-18  Bruno Haible  <bruno@clisp.org>
44161
44162         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
44163         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
44164         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
44165         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
44166         * m4/gettext.m4: Require autoconf >= 2.52.
44167         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
44168         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
44169         of gl_cv_header_inttypes_h.
44170
44171 2006-09-18  Bruno Haible  <bruno@clisp.org>
44172
44173         * lib/javaversion.c: Include configmake.h.
44174
44175 2006-09-18  Bruno Haible  <bruno@clisp.org>
44176
44177         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
44178         avoid that the while loops be executed in a subshell.
44179
44180 2006-09-18  Bruno Haible  <bruno@clisp.org>
44181
44182         * MODULES.html.sh (func_module): Break long lines.
44183         Suggested by Bruce Korb <bkorb@gnu.org>.
44184
44185 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44186
44187         Speed up by a factor of 1.12.
44188         * gnulib-tool (nl): New variable.
44189         (func_import): Rewrite include directive extraction to only read each
44190         directive once.
44191
44192 2006-09-17  Bruno Haible  <bruno@clisp.org>
44193
44194         * modules/javaversion (Makefile.am): Remove DEFS setting.
44195         (Depends-on): Add configmake, for PKGDATADIR definition.
44196
44197 2006-09-17  Bruno Haible  <bruno@clisp.org>
44198
44199         * gnulib-tool (func_create_testdir): Rewrite all files at once.
44200
44201 2006-09-17  Bruno Haible  <bruno@clisp.org>
44202
44203         * gnulib-tool (func_append): New function, stolen from libtool.m4.
44204         (func_modules_transitive_closure, func_modules_add_dummy,
44205         func_modules_to_filelist, func_import, func_create_testdir,
44206         func_create_megatestdir, ...): Use it wherever possible.
44207         Suggested by Ralf Wildenhues.
44208
44209 2006-09-16  Karl Berry  <karl@gnu.org>
44210
44211         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
44212         to avoid sectioning errors.
44213         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
44214         [ifinfo]: blank line after @center-ed titles.
44215         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
44216         Spell FSF address consistently with others.
44217         (These changes approved by rms.)
44218
44219 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44220
44221         Speed up by a factor of 1.61.
44222         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
44223         already checked module names again.
44224
44225 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44226
44227         Speed up by a factor of 1.13.
44228         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
44229         for new_files, and the input to func_add_or_update.
44230
44231 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44232
44233         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
44234         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
44235
44236 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
44237
44238         * modules/mkancesdirs (Depends-on): Add fcntl.
44239         * modules/savewd: New file.
44240         * MODULES.html.sh (File system functions): Add savewd.
44241
44242         * modules/configmake (Makefile.am): Add support for the
44243         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
44244
44245 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
44246
44247         * m4/savewd.m4: New file.
44248
44249 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
44250
44251         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
44252         (dirchownmod): New arg FD.  All callers changed.
44253         Use FD rather than opening the directory ourself, as opening is
44254         now the caller's responsibility.
44255         * lib/dirchownmod.h: Likewise.
44256         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
44257         hosts that require <sys/types.h> before <sys/stat.h>.  Include
44258         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
44259         (test_dir): Remove.
44260         (mkancesdirs): Return length of prefix of FILE that has already
44261         been made, or -2 if there is a child doing the work.  Redo
44262         algorithm so that it is O(N) rather than O(N**2).  Optimize away
44263         ".", and treat ".." specially since it might stray back into
44264         already-created areas.  Use a subprocess if necessary.  New arg
44265         WD; all users changed.  MAKE_DIR function should now return 1
44266         if it creates a directory that is not readable.  Return -2 if
44267         a child process is spun off.
44268         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
44269         Adjust signature to match code.
44270         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
44271         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
44272         all users changed.
44273         * lib/savewd.c, lib/savewd.h: New files.
44274
44275 2006-09-15  Jim Meyering  <jim@meyering.net>
44276
44277         * modules/rename-dest-slash: New module.
44278         * MODULES.html.sh (posix_compat): Add it here.
44279
44280         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
44281
44282 2006-09-15  Jim Meyering  <jim@meyering.net>
44283
44284         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
44285         file.
44286
44287         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
44288
44289 2006-09-15  Jim Meyering  <jim@meyering.net>
44290
44291         * lib/rename-dest-slash.c (has_trailing_slash): Use
44292         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
44293         (rpl_rename_dest_slash): Perform the cheaper trailing slash
44294         test before testing whether SRC is a directory.
44295         Suggestions from Bruno Haible.
44296
44297         Avoid a warning about an unused variable.
44298         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
44299         into the #ifdef block where it's used.
44300
44301         * lib/rename-dest-slash.c: New file.
44302
44303 2006-09-14  Bruno Haible  <bruno@clisp.org>
44304
44305         * lib/allocsa.c: Include <config.h> unconditionally.
44306         * lib/asnprintf.c: Likewise.
44307         * lib/asprintf.c: Likewise.
44308         * lib/c-strcasecmp.c: Likewise.
44309         * lib/c-strcasestr.c: Likewise.
44310         * lib/c-strncasecmp.c: Likewise.
44311         * lib/c-strstr.c: Likewise.
44312         * lib/classpath.c: Likewise.
44313         * lib/clean-temp.c: Likewise.
44314         * lib/concatpath.c: Likewise.
44315         * lib/copy-file.c: Likewise.
44316         * lib/csharpcomp.c: Likewise.
44317         * lib/csharpexec.c: Likewise.
44318         * lib/execute.c: Likewise.
44319         * lib/fatal-signal.c: Likewise.
44320         * lib/findprog.c: Likewise.
44321         * lib/fwriteerror.c: Likewise.
44322         * lib/gl_array_list.c: Likewise.
44323         * lib/gl_array_oset.c: Likewise.
44324         * lib/gl_avltree_list.c: Likewise.
44325         * lib/gl_avltree_oset.c: Likewise.
44326         * lib/gl_avltreehash_list.c: Likewise.
44327         * lib/gl_carray_list.c: Likewise.
44328         * lib/gl_linked_list.c: Likewise.
44329         * lib/gl_linkedhash_list.c: Likewise.
44330         * lib/gl_list.c: Likewise.
44331         * lib/gl_oset.c: Likewise.
44332         * lib/gl_rbtree_list.c: Likewise.
44333         * lib/gl_rbtree_oset.c: Likewise.
44334         * lib/gl_rbtreehash_list.c: Likewise.
44335         * lib/imaxabs.c: Likewise.
44336         * lib/imaxdiv.c: Likewise.
44337         * lib/javacomp.c: Likewise.
44338         * lib/javaexec.c: Likewise.
44339         * lib/javaversion.c: Likewise.
44340         * lib/linebreak.c: Likewise.
44341         * lib/localcharset.c: Likewise.
44342         * lib/lock.c: Likewise.
44343         * lib/mbchar.c: Likewise.
44344         * lib/mbswidth.c: Likewise.
44345         * lib/mkdtemp.c: Likewise.
44346         * lib/pipe.c: Likewise.
44347         * lib/printf-args.c: Likewise.
44348         * lib/printf-parse.c: Likewise.
44349         * lib/progname.c: Likewise.
44350         * lib/progreloc.c: Likewise.
44351         * lib/readlink.c: Likewise.
44352         * lib/sh-quote.c: Likewise.
44353         * lib/stpcpy.c: Likewise.
44354         * lib/stpncpy.c: Likewise.
44355         * lib/strcasecmp.c: Likewise.
44356         * lib/strcasestr.c: Likewise.
44357         * lib/strcspn.c: Likewise.
44358         * lib/striconv.c: Likewise.
44359         * lib/strncasecmp.c: Likewise.
44360         * lib/strnlen1.c: Likewise.
44361         * lib/strstr.c: Likewise.
44362         * lib/strtok_r.c: Likewise.
44363         * lib/tls.c: Likewise.
44364         * lib/tmpdir.c: Likewise.
44365         * lib/unicodeio.c: Likewise.
44366         * lib/unsetenv.c: Likewise.
44367         * lib/vasnprintf.c: Likewise.
44368         * lib/vasprintf.c: Likewise.
44369         * lib/wait-process.c: Likewise.
44370         * lib/xallocsa.c: Likewise.
44371         * lib/xsetenv.c: Likewise.
44372         * lib/xstriconv.c: Likewise.
44373
44374 2006-09-13  Simon Josefsson  <jas@extundo.com>
44375
44376         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
44377         that internally, suggested by Ralf Wildenhues
44378         <Ralf.Wildenhues@gmx.de>.
44379
44380 2006-09-13  Simon Josefsson  <jas@extundo.com>
44381
44382         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
44383         @LIBOBJS@.
44384         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
44385
44386 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
44387
44388         * lib/_fpending.c: Include <config.h> unconditionally, since we no
44389         longer worry about uses that don't define HAVE_CONFIG_H.
44390         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
44391         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
44392         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
44393         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
44394         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
44395         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
44396         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
44397         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
44398         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
44399         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
44400         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
44401         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
44402         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
44403         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
44404         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
44405         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
44406         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
44407         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
44408         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
44409         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
44410         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
44411         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
44412         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
44413         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
44414         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
44415         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
44416         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
44417         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
44418         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
44419         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
44420         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
44421         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
44422         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
44423         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
44424         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
44425         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
44426         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
44427         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
44428         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
44429         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
44430         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
44431         Likewise.
44432
44433 2006-09-13  Eric Blake  <ebb9@byu.net>
44434
44435         * lib/getopt.c: Fix typo in last commit.
44436
44437 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
44438
44439         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
44440         dgettext.
44441
44442 2006-09-12  Jim Meyering  <jim@meyering.net>
44443
44444         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
44445         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
44446         Reported by Nelson H. F. Beebe.
44447
44448 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
44449
44450         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
44451         program_invocation_name and program_invocation_short_name are
44452         initialized.
44453         * lib/argp-namefrob.h: Move declarations of program_invocation_name
44454         and program_invocation_short_name to argp.h, so they are visible
44455         to user programs.
44456         * lib/argp.h: Likewise
44457
44458 2006-09-10  Bruno Haible  <bruno@clisp.org>
44459
44460         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
44461         m4/inttypes_h.m4, m4/uintmax_t.m4.
44462
44463 2006-09-10  Bruno Haible  <bruno@clisp.org>
44464
44465         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
44466         gl_AC_TYPE_UINTMAX_T.
44467
44468 2006-09-10  Bruno Haible  <bruno@clisp.org>
44469
44470         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
44471
44472 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
44473
44474         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
44475         convention.  Text proposed by Bruno Haible.
44476         (struct argp_option): Document the use of N_() wrappers.
44477
44478         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
44479         '\v', and translate the two parts separately, instead of feeding
44480         the whole string to gettext.  This allows to exclude
44481         '\v' from the strings visible to the translator by writing doc
44482         strings as N_("..") "\v" N_("..").
44483
44484 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
44485
44486         * config/srclist.txt: Undo latest change; the bug was fixed.
44487
44488 2006-09-09  Bruno Haible  <bruno@clisp.org>
44489
44490         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
44491         assignments if building a library without libtool.
44492         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
44493         in func_emit_lib_Makefile_am.
44494         (func_import): When building a static library libfoo.a, arrange to
44495         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
44496         (func_create_testdir): Likewise.
44497         * modules/gc (configure.ac, Makefile.am): If building statically,
44498         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
44499         * modules/iconvme (configure.ac, Makefile.am): Likewise.
44500         * modules/striconv (configure.ac, Makefile.am): Likewise.
44501         Based on a suggestion by Ralf Wildenhues.
44502
44503 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
44504
44505         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
44506         Check for unistd.h too, since Autoconf doesn't assume POSIX.
44507         Also:
44508
44509         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
44510         Add year_2050_test to catch glibc bug 2821
44511         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
44512
44513         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
44514         Prefer #ifdef to #if.
44515
44516         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
44517         Return from 'main' instead of calling 'exit'.
44518
44519 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
44520
44521         * lib/mktime.c (guess_time_tm): Fix bug where mktime
44522         returned the maximum time_t value rather than (time_t) -1.
44523         Problem originally reported by William Bardwell
44524         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
44525
44526         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
44527         Moved to here ...
44528         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
44529         ... from here.
44530
44531 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
44532
44533         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
44534         2821 is fixed.
44535
44536 2006-09-08  Jim Meyering  <jim@meyering.net>
44537
44538         Don't make generated files read-only.  That would bother too many
44539         people.  However, do retain the ability to work when targets are
44540         read-only: remove the destination and temporary files before writing
44541         them (when generated via sed or echo), or by using the -f option for
44542         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
44543         * modules/alloca-opt, modules/argz, modules/arpa_inet:
44544         * modules/byteswap, modules/configmake, modules/fcntl:
44545         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
44546         * modules/localcharset, modules/netinet_in, modules/poll:
44547         * modules/stdbool, modules/stdint, modules/sys_select:
44548         * modules/sys_socket, modules/sys_stat, modules/sysexits:
44549
44550 2006-09-08  Jim Meyering  <jim@meyering.net>
44551
44552         Avoid new build failure on FreeBSD 6.0.
44553         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
44554         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
44555         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
44556
44557 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44558
44559         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
44560
44561 2006-09-07  Jim Meyering  <jim@meyering.net>
44562
44563         Fix global typo in last change: use chmod u-w, not chmod u-x.
44564         Spotted by Paul Eggert and Bruce Korb.
44565         * modules/alloca-opt, modules/argz, modules/arpa_inet:
44566         * modules/byteswap, modules/configmake, modules/fcntl:
44567         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
44568         * modules/localcharset, modules/netinet_in, modules/poll:
44569         * modules/stdbool, modules/stdint, modules/sys_select:
44570         * modules/sys_socket, modules/sys_stat, modules/sysexits:
44571
44572 2006-09-06  Jim Meyering  <jim@meyering.net>
44573
44574         Make generated files be read-only.
44575         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
44576         Ensure that each generated file is now read-only.
44577         * modules/argz: Likewise.
44578         * modules/arpa_inet: Likewise.
44579         * modules/byteswap: Likewise.
44580         * modules/configmake: Likewise.
44581         * modules/fcntl: Likewise.
44582         * modules/fnmatch: Likewise.
44583         * modules/getopt: Likewise.
44584         * modules/glob: Likewise.
44585         * modules/inttypes: Likewise.
44586         * modules/netinet_in: Likewise.
44587         * modules/poll: Likewise.
44588         * modules/stdbool: Likewise.
44589         * modules/stdint: Likewise.
44590         * modules/sys_select: Likewise.
44591         * modules/sys_socket: Likewise.
44592         * modules/sys_stat: Likewise.
44593         * modules/sysexits: Likewise.
44594         * modules/localcharset: Same as above, but continue using temporary
44595         file named "t-$@" (why different?) rather than the "$@-t" used
44596         everywhere else.
44597
44598         * modules/sysexits (Makefile.am): Replace literal occurrences
44599         of "sysexit.h" more readable, and more consistent, "$@".
44600
44601 2006-09-06  Bruno Haible  <bruno@clisp.org>
44602
44603         * modules/striconv: New file.
44604         * modules/xstriconv: New file.
44605         * MODULES.html.sh (Internationalization functions): Add striconv,
44606         xstriconv.
44607
44608 2006-09-06  Bruno Haible  <bruno@clisp.org>
44609
44610         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
44611         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
44612         not using libtool correctly.
44613
44614 2006-09-06  Bruno Haible  <bruno@clisp.org>
44615
44616         * lib/striconv.h: New file.
44617         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
44618         iconvstring.c.
44619         * lib/xstriconv.h: New file.
44620         * lib/xstriconv.c: New file.
44621
44622 2006-09-06  Bruno Haible  <bruno@clisp.org>
44623
44624         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
44625         lib_..._LDFLAGS.
44626
44627 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44628
44629         * lib/argz_.h: Sync from Libtool.
44630
44631         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
44632                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
44633
44634         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
44635
44636 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
44637
44638         * modules/trim: New file.
44639
44640 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
44641
44642         * lib/trim.h: New file.
44643         * lib/trim.c: New file.
44644
44645 2006-09-05  Bruno Haible  <bruno@clisp.org>
44646
44647         * MODULES.html.sh (String handling): Add trim.
44648
44649 2006-09-04  Karl Berry  <karl@gnu.org>
44650
44651         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
44652         until next release.
44653
44654 2006-09-03  Bruno Haible  <bruno@clisp.org>
44655
44656         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
44657         correctly.
44658
44659 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
44660
44661         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
44662         not gl_GETLOADAVG.  Omit unneeded semicolons.
44663         Problems reported by Ralf Wildenhues in
44664         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
44665         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
44666         at the end, which is the usual gnulib style.
44667
44668         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
44669         of doing all the work ourselves.
44670         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
44671         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
44672
44673 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
44674
44675         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
44676         Problem reported by Ralf Wildenhues in
44677         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
44678
44679         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
44680         HAVE_STRUCT_STATFS_F_FSTYPENAME.
44681
44682 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
44683
44684         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
44685         yesterday's patch by changing test -n to test -z.
44686
44687 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
44688
44689         * modules/getloadavg (Files): Add m4/getloadavg.m4.
44690         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
44691         the former is now obsolescent.
44692
44693         * modules/chdir-long (Depends-on): Add fcntl.
44694
44695 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
44696
44697         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
44698         obsolescent, and programs should use gnulib instead.
44699         * m4/getloadavg.m4: New file, with contents taken from Autoconf
44700         but with prefixes changed.
44701
44702 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
44703
44704         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
44705         or stdbool.h, because they might not exist while configuring.
44706
44707         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
44708         Don't include unistd.h or limits.h; not needed, since chdir-long.h
44709         does that for us.
44710         (O_DIRECTORY): Remove.
44711
44712 2006-08-31  Eric Blake  <ebb9@byu.net>
44713
44714         * gnulib-tool: Don't let emacs change spaces to TAB.
44715
44716 2006-08-31  Bruno Haible  <bruno@clisp.org>
44717
44718         * gnulib-tool: When calling func_import more than once, do it in a
44719         subshell.
44720         Reported by Eric Blake <ebb9@byu.net>.
44721
44722 2006-08-31  Bruno Haible  <bruno@clisp.org>
44723
44724         * gnulib-tool (nl): Remove variable.
44725         (sed_transform_lib_file): Use more robust test for config-h module.
44726         (func_import): Fix typo in 2006-08-25 patch.
44727
44728 2006-08-31  Bruno Haible  <bruno@clisp.org>
44729
44730         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
44731         specified, augment Makefile.am variables instead of assigning them.
44732
44733 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
44734
44735         Work around a bug in both the Linux and SunOS 64-bit kernels:
44736         nanosleep mishandles sleeps for longer than 2**31 seconds.
44737         Problem reported by Frank v Waveren in
44738         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
44739         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
44740         Check for nanosleep bug.
44741         (LIB_NANOSLEEP): Append clock_gettime library if needed.
44742
44743 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
44744
44745         Work around a bug in both the Linux and SunOS 64-bit kernels:
44746         nanosleep mishandles sleeps for longer than 2**31 seconds.
44747         Problem reported by Frank v Waveren in
44748         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
44749         * lib/nanosleep.c (BILLION): New constant.
44750         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
44751         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
44752         implementation.
44753
44754 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
44755
44756         * modules/nanosleep (Depends-on): Add gettime.
44757
44758 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
44759         and Simon Josefsson  <jas@extundo.com>
44760         and Oskar Liljeblad  <oskar@osk.mine.nu>
44761
44762         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
44763         * gnulib-tool (func_import): New license type 'unmodifiable license
44764         text'.
44765         * modules/fdl: Use it.  Longer description.
44766         * module/gpl, module/lgpl: New files.
44767
44768 2006-08-30  Jim Meyering  <jim@meyering.net>
44769
44770         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
44771         shadowing the parameter.
44772
44773 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44774
44775         Sync from Libtool:
44776
44777         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
44778
44779         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
44780         sharing with gnulib.  Report by Eric Blake.
44781
44782 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
44783
44784         * modules/isapipe: New file.
44785         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
44786
44787 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
44788
44789         * modules/configmake (Makefile.am): Add a comment, and omit
44790         the CONFIGMAKE_ prefix from generated macro names.  Suggested
44791         by Bruno Haible.
44792
44793 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
44794
44795         * m4/isapipe.m4: New file.
44796
44797 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
44798
44799         * lib/isapipe.c, lib/isapipe.h: New files.
44800
44801 2006-08-29  Jim Meyering  <jim@meyering.net>
44802
44803         * modules/configmake (Makefile.am): Make configmake.h depend on
44804         Makefile.  Otherwise, a stale configmake.h could hang around.
44805
44806 2006-08-29  Eric Blake  <ebb9@byu.net>
44807
44808         * lib/error.c (error_at_line, print_errno_message): Match libc, after
44809         resolution of upstream bug 3044.
44810
44811 2006-08-29  Bruno Haible  <bruno@clisp.org>
44812
44813         * modules/localcharset (Depends-on): Add configmake.
44814         (Makefile.am): Remove setting of LIBDIR through DEFS.
44815
44816 2006-08-29  Bruno Haible  <bruno@clisp.org>
44817
44818         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
44819         defined.
44820
44821 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
44822
44823         * modules/fcntl: New file.
44824         * modules/chdir-safer (Depends-on): Add fcntl.
44825         * modules/fts: Likewise.
44826         * modules/mkdir-p: Likewise.
44827
44828         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
44829         This undoes the most recent change, since we're now addressing the
44830         problem in a different way.
44831
44832         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
44833         into output, since the output might be called Makefile.am even
44834         if $makefile_name is something different.
44835         (func_import): Use $makefile_am rather than
44836         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
44837         empty.
44838
44839         * modules/inttypes (Files): Add m4/inttypes-h.m4.
44840
44841 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
44842
44843         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
44844         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
44845         recent change to stdint.m4, since we're now addressing the problem in a
44846         different way.
44847
44848 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
44849
44850         * m4/fcntl_h.m4: New file.
44851
44852 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
44853
44854         * lib/fcntl_.h: New file.
44855         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
44856         the fcntl module.
44857         * lib/dirchownmod.c: Likewise.
44858         * lib/fts.c: Likewise.
44859
44860         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
44861         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
44862         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
44863         just before including <inttypes.h>, to avoid circular inclusion.
44864
44865 2006-08-28  Jim Meyering  <jim@meyering.net>
44866
44867         * doc/visibility.texi: Actually read and correct the grammar of the
44868         sentence affected by yesterday's change.
44869
44870 2006-08-28  Eric Blake  <ebb9@byu.net>
44871
44872         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
44873         needs wrapper.
44874
44875 2006-08-28  Eric Blake  <ebb9@byu.net>
44876
44877         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
44878
44879 2006-08-28  Eric Blake  <ebb9@byu.net>
44880
44881         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
44882
44883 2006-08-28  Bruno Haible  <bruno@clisp.org>
44884
44885         * modules/c-strstr: New file, from GNU gettext.
44886         * MODULES.html.sh (String handling): Add c-strstr.
44887
44888 2006-08-28  Bruno Haible  <bruno@clisp.org>
44889
44890         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
44891         macros.
44892         Reported by Eric Blake.
44893
44894 2006-08-28  Bruno Haible  <bruno@clisp.org>
44895
44896         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
44897         (VASNPRINTF): Return a string of length > INT_MAX without failing.
44898         * lib/vasprintf.c: Include errno.h, limits.h.
44899         (EOVERFLOW): New fallback definition.
44900         (vasprintf): Test here whether the string length is > INT_MAX.
44901         * lib/vsnprintf.c: Include errno.h, limits.h.
44902         (EOVERFLOW): New fallback definition.
44903         (vsnprintf): Fix bug when generated string was too long for the buffer.
44904         Test here whether the string length is > INT_MAX.
44905
44906 2006-08-28  Bruno Haible  <bruno@clisp.org>
44907
44908         * lib/inttypes_.h (SCNX*): Remove definitions.
44909         Reported by Eric Blake.
44910
44911 2006-08-28  Bruno Haible  <bruno@clisp.org>
44912
44913         * lib/c-strstr.h: New file, from GNU gettext.
44914         * lib/c-strstr.c: New file, from GNU gettext.
44915
44916 2006-08-28  Bruno Haible  <bruno@clisp.org>
44917
44918         * gnulib-tool: Reorder some statements.
44919
44920 2006-08-28  Bruno Haible  <bruno@clisp.org>
44921
44922         * gnulib-tool: New option --makefile-name.
44923         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
44924         $makefile_name.
44925         (func_import): Write $makefile_name to the cache file, and read it from
44926         there unless explicitly specified. Use $makefile_name as file name
44927         instead of Makefile.am. Adjust the recommendations accordingly.
44928
44929 2006-08-28  Bruno Haible  <bruno@clisp.org>
44930
44931         * gnulib-tool (func_verify_module): Check against misapplying patch.
44932
44933 2006-08-28  Bruno Haible  <bruno@clisp.org>
44934
44935         * gnulib-tool (func_relativize, func_relconcat): New functions.
44936         Give an error if --local-dir is given with --update.
44937         Remove trailing slashes from $local_gnulib_dir.
44938         (func_import): Store the relativized $local_gnulib_dir in
44939         gnulib-cache.m4, and read it from there if not specified explicitly.
44940
44941 2006-08-28  Bruno Haible  <bruno@clisp.org>
44942
44943         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
44944         is the current directory. Respect also $local_gnulib_dir.
44945
44946 2006-08-28  Bruno Haible  <bruno@clisp.org>
44947             Simon Josefsson  <jas@extundo.com>
44948
44949         BeOS portability.
44950         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
44951
44952 2006-08-27  Jim Meyering  <jim@meyering.net>
44953
44954         * doc/visibility.texi: Remove duplicate word: "pointer".
44955
44956 2006-08-26  Bruno Haible  <bruno@clisp.org>
44957
44958         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
44959         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
44960         (Makefile.am): Create inttypes.h from inttypes_.h.
44961         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
44962
44963         * modules/imaxabs: New file.
44964
44965         * modules/imaxdiv: New file.
44966
44967 2006-08-26  Bruno Haible  <bruno@clisp.org>
44968
44969         * m4/inttypes.m4: New file.
44970         * m4/_inttypes_h.m4: Remove file.
44971         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
44972         PRI_MACROS_BROKEN.
44973         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
44974
44975         * m4/imaxabs.m4: New file.
44976
44977         * m4/imaxdiv.m4: New file.
44978
44979 2006-08-26  Bruno Haible  <bruno@clisp.org>
44980
44981         * lib/inttypes_.h: New file.
44982         * lib/inttypes.h: Remove file.
44983         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
44984
44985         * lib/imaxabs.c: New file.
44986
44987         * lib/imaxdiv.c: New file.
44988
44989 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
44990
44991         New config-h module, so that "make" output needn't be cluttered
44992         by -DHAVE_CONFIG_H.
44993         * MODULES.html.sh (Support for building libraries and executables):
44994         Add config-h.
44995         * modules/config-h: New file.
44996         * gnulib-tool (nl, sed_transform_lib_file): New vars.
44997         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
44998         the config-h module is used.
44999
45000         New configmake module, so that "make" output needn't be cluttered
45001         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
45002         * MODULES.html.sh (Support for building libraries and executables):
45003         Add configmake.
45004         * modules/configmake: New file.
45005
45006 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
45007
45008         * m4/config-h.m4: New file.
45009
45010 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
45011
45012         * config/srclist.txt: Add elisp-comp.
45013
45014 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
45015
45016         * MODULES.html.sh (Support for building libraries and executables):
45017         Add elisp-comp.
45018         * build-aux/elisp-comp: New file.
45019         * modules/elisp-comp: New file.
45020
45021 2006-08-24  Bruno Haible  <bruno@clisp.org>
45022
45023         * gnulib-tool (func_create_testdir): Use non-default values of
45024         sourcebase and m4base.
45025
45026 2006-08-24  Bruno Haible  <bruno@clisp.org>
45027
45028         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
45029         HTML structure.
45030
45031 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
45032
45033         * modules/openat (Depends-on): Add lchown.
45034
45035 2006-08-23  Bruno Haible  <bruno@clisp.org>
45036
45037         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
45038         of gl_LOCK_EARLY instead of gl_LOCK.
45039
45040 2006-08-23  Bruno Haible  <bruno@clisp.org>
45041
45042         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
45043         on OSF/1 to no.
45044         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
45045
45046 2006-08-23  Bruno Haible  <bruno@clisp.org>
45047
45048         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
45049         as unusable.
45050
45051         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
45052         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
45053         (gl_LOCK): New macro.
45054
45055 2006-08-22  Simon Josefsson  <jas@extundo.com>
45056
45057         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
45058         to md5 module.
45059
45060 2006-08-22  Simon Josefsson  <jas@extundo.com>
45061
45062         * MODULES.html.sh: Add "Support for maintaining and release
45063         projects".
45064
45065         * build-aux/gnupload: New file, from coreutils.
45066
45067 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
45068
45069         Avoid the need for AC_LIBSOURCES in m4 macros.
45070         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
45071         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
45072         * modules/check-version (EXTRA_DIST): Add check-version.h.
45073         * modules/crc (EXTRA_DIST): Add crc.h.
45074         * modules/des (EXTRA_DIST): Add des.h.
45075         * modules/gc (EXTRA_DIST): Add gc.h.
45076         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
45077         * modules/getline (EXTRA_DIST): Add getline.h.
45078         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
45079         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
45080         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
45081         * modules/md2 (EXTRA_DIST): Add md2.h.
45082         * modules/md4 (EXTRA_DIST): Add md4.h.
45083         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
45084         * modules/read-file (EXTRA_DIST): Add read-file.h.
45085         * modules/readline (EXTRA_DIST): Add readline.h.
45086         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
45087         rijndael-api-fst.h.
45088
45089 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
45090
45091         * m4/rijndael.m4 (gl_ARCFOUR):
45092         * m4/arctwo.m4 (gl_ARCTWO):
45093         * m4/check-version.m4 (gl_CHECK_VERSION):
45094         * m4/crc.m4 (gl_CRC):
45095         * m4/des.m4 (gl_DES):
45096         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
45097         * m4/gc.m4 (gl_GC):
45098         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
45099         * m4/getline.m4 (gl_FUNC_GETLINE):
45100         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
45101         * m4/hmac-md5.m4 (gl_HMAC_MD5):
45102         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
45103         * m4/md2.m4 (gl_MD2):
45104         * m4/md4.m4 (gl_MD4):
45105         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
45106         * m4/read-file.m4 (gl_FUNC_READ_FILE):
45107         * m4/readline.m4 (gl_FUNC_READLINE):
45108         * m4/rijndael.m4 (gl_RIJNDAEL):
45109         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
45110         to get the necessary .h files and whatnot.
45111
45112 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
45113
45114         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
45115         gnulib rather than the other way around.
45116         * config/srclistvars.sh (COREUTILS): Remove.
45117
45118 2006-08-22  Jim Meyering  <jim@meyering.net>
45119
45120         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
45121
45122         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
45123
45124 2006-08-22  Eric Blake  <ebb9@byu.net>
45125
45126         * modules/regexprops-generic: New file.
45127         * MODULES.html.sh (Support for building documentation): List it.
45128
45129 2006-08-22  Eric Blake  <ebb9@byu.net>
45130
45131         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
45132         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
45133         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
45134         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
45135
45136 2006-08-22  Bruno Haible  <bruno@clisp.org>
45137
45138         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
45139         and lib_LTLIBRARIES like the other lib_* variables.
45140
45141 2006-08-22  Bruno Haible  <bruno@clisp.org>
45142
45143         * build-aux/x-to-1.in: New file, from GNU gettext.
45144
45145 2006-08-22  Bruno Haible  <bruno@clisp.org>
45146
45147         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
45148         <utmpx.h> exists.
45149
45150 2006-08-22  Bruno Haible  <bruno@clisp.org>
45151
45152         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
45153         <utmpx.h> exists.
45154
45155 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
45156
45157         BeOS portability.
45158         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
45159         exist.
45160         Problem reported by Bruno Haible.
45161
45162 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
45163
45164         Avoid the need for AC_LIBSOURCES in m4 macros.
45165         * modules/acl (EXTRA_DIST): Add acl.h.
45166         * modules/argmatch (Files): Add m4/argmatch.m4.
45167         (configure.ac): Add gl_ARGMATCH.
45168         (EXTRA_DIST): Renamed from lib_SOURCES, for
45169         consistency with the other modules.  Remove argmatch.c.
45170         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
45171         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
45172         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
45173         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
45174         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
45175         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
45176         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
45177         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
45178         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
45179         * modules/closeout (EXTRA_DIST): Add closeout.h.
45180         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
45181         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
45182         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
45183         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
45184         dirname.h; remove basename.c and stripslash.c.
45185         * modules/exclude (EXTRA_DIST): Add exclude.h.
45186         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
45187         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
45188         * modules/file-type (EXTRA_DIST): Add file-type.h.
45189         * modules/filemode (EXTRA_DIST): Add filemode.h.
45190         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
45191         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
45192         * modules/fpending (EXTRA_DIST): Add __fpending.h.
45193         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
45194         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
45195         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
45196         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
45197         * modules/getdate (EXTRA_DIST): Add getdate.c.
45198         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
45199         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
45200         * modules/getpass (EXTRA_DIST): Add getpass.h.
45201         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
45202         * modules/group-member (EXTRA_DIST): Add group-member.h.
45203         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
45204         * modules/hash (EXTRA_DIST): Add hash.h.
45205         * modules/human (EXTRA_DIST): Add human.h.
45206         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
45207         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
45208         * modules/lchown (EXTRA_DIST): Add lchown.h.
45209         * modules/long-options (EXTRA_DIST): Add long-options.h.
45210         * modules/lstat (EXTRA_DIST): Add lstat.h.
45211         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
45212         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
45213         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
45214         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
45215         * modules/memxor (EXTRA_DIST): Add memxor.h.
45216         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
45217         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
45218         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
45219         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
45220         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
45221         * modules/physmem (EXTRA_DIST): Add physmem.h.
45222         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
45223         * modules/posixver (EXTRA_DIST): Add posixver.h.
45224         * modules/quote (EXTRA_DIST): Add quote.h.
45225         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
45226         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
45227         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
45228         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
45229         regex_internal.h regexec.c.
45230         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
45231         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
45232         * modules/same (EXTRA_DIST): Add same.h.
45233         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
45234         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
45235         * modules/savedir (EXTRA_DIST): Add savedir.h.
45236         * modules/sha1 (EXTRA_DIST): Add sha1.h.
45237         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
45238         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
45239         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
45240         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
45241         * modules/strdup (EXTRA_DIST): Add strdup.h.
45242         * modules/strftime (EXTRA_DIST): Add strftime.h.
45243         * modules/strndup (EXTRA_DIST): Add strndup.h.
45244         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
45245         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
45246         * modules/time_r (EXTRA_DIST): Add time_r.h.
45247         * modules/timespec (EXTRA_DIST): Add timespec.h.
45248         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
45249         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
45250         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
45251         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
45252         * modules/userspec (EXTRA_DIST): Add userspec.h.
45253         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
45254         * modules/utimens (EXTRA_DIST): Add utimens.h.
45255         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
45256         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
45257         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
45258         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
45259         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
45260         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
45261         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
45262         * modules/yesno (EXTRA_DIST): Add yesno.h.
45263
45264 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
45265
45266         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
45267
45268         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
45269         * m4/dev-ino.m4, same-inode.m4: Remove.
45270
45271         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
45272         * m4/acl.m4 (AC_FUNC_ACL):
45273         * m4/backupfile.m4 (gl_BACKUPFILE):
45274         * m4/c-strtod.m4 (gl_C99_STRTOLD):
45275         * m4/canon-host.m4 (gl_CANON_HOST):
45276         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
45277         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
45278         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
45279         * m4/cloexec.m4 (gl_CLOEXEC):
45280         * m4/close-stream.m4 (gl_CLOSE_STREAM):
45281         * m4/closeout.m4 (gl_CLOSEOUT):
45282         * m4/dirfd.m4 (gl_FUNC_DIRFD):
45283         * m4/dirname.m4 (gl_DIRNAME):
45284         * m4/exclude.m4 (gl_EXCLUDE):
45285         * m4/exitfail.m4 (gl_EXITFAIL):
45286         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
45287         * m4/file-type.m4 (gl_FILE_TYPE):
45288         * m4/filemode.m4 (gl_FILEMODE):
45289         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
45290         * m4/fpending.m4 (gl_FUNC_FPENDING):
45291         * m4/fprintftime.m4 (gl_FPRINTFTIME):
45292         * m4/fts.m4 (gl_FUNC_FTS):
45293         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
45294         * m4/getdate.m4 (gl_GETDATE):
45295         * m4/gethrxtime.m4 (gl_GETHRXTIME):
45296         * m4/getpagesize.m4 (gl_GETPAGESIZE):
45297         * m4/getpass.m4 (gl_FUNC_GETPASS):
45298         * m4/gettime.m4 (gl_GETTIME):
45299         * m4/getugroups.m4 (gl_GETUGROUPS):
45300         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
45301         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
45302         * m4/hard-locale.m4 (gl_HARD_LOCALE):
45303         * m4/hash.m4 (gl_HASH):
45304         * m4/idcache.m4 (gl_IDCACHE):
45305         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
45306         * m4/lchown.m4 (gl_FUNC_LCHOWN):
45307         * m4/long-options.m4 (gl_LONG_OPTIONS):
45308         * m4/lstat.m4 (gl_FUNC_LSTAT):
45309         * m4/md5.m4 (gl_MD5):
45310         * m4/memcasecmp.m4 (gl_MEMCASECMP):
45311         * m4/memcoll.m4 (gl_MEMCOLL):
45312         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
45313         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
45314         * m4/memxor.m4 (gl_MEMXOR):
45315         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
45316         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
45317         * m4/modechange.m4 (gl_MODECHANGE):
45318         * m4/mountlist.m4 (gl_MOUNTLIST):
45319         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
45320         * m4/openat.m4 (gl_FUNC_OPENAT):
45321         * m4/pathmax.m4 (gl_PATHMAX):
45322         * m4/physmem.m4 (gl_PHYSMEM):
45323         * m4/posixtm.m4 (gl_POSIXTM):
45324         * m4/posixver.m4 (gl_POSIXVER):
45325         * m4/quote.m4 (gl_QUOTE):
45326         * m4/quotearg.m4 (gl_QUOTEARG):
45327         * m4/readtokens.m4 (gl_READTOKENS):
45328         * m4/readutmp.m4 (gl_READUTMP):
45329         * m4/regex.m4 (gl_REGEX):
45330         * m4/safe-read.m4 (gl_SAFE_READ):
45331         * m4/safe-write.m4 (gl_SAFE_WRITE):
45332         * m4/same.m4 (gl_SAME):
45333         * m4/save-cwd.m4 (gl_SAVE_CWD):
45334         * m4/savedir.m4 (gl_SAVEDIR):
45335         * m4/settime.m4 (gl_SETTIME):
45336         * m4/sha1.m4 (gl_SHA1):
45337         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
45338         * m4/stat-macros.m4 (gl_STAT_MACROS):
45339         * m4/stat-time.m4 (gl_STAT_TIME):
45340         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
45341         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
45342         * m4/strdup.m4 (gl_FUNC_STRDUP):
45343         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
45344         * m4/strndup.m4 (gl_FUNC_STRNDUP):
45345         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
45346         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
45347         * m4/time_r.m4 (gl_TIME_R):
45348         * m4/timespec.m4 (gl_TIMESPEC):
45349         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
45350         * m4/unlinkdir.m4 (gl_UNLINKDIR):
45351         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
45352         * m4/userspec.m4 (gl_USERSPEC):
45353         * m4/utimecmp.m4 (gl_UTIMECMP):
45354         * m4/utimens.m4 (gl_UTIMENS):
45355         * m4/xalloc.m4 (gl_XALLOC):
45356         * m4/xgetcwd.m4 (gl_XGETCWD):
45357         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
45358         * m4/xreadlink.m4 (gl_XREADLINK):
45359         * m4/xstrtod.m4 (gl_XSTRTOD):
45360         * m4/yesno.m4 (gl_YESNO):
45361         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
45362         to get the necessary .h files and whatnot.
45363
45364 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
45365             Bruno Haible  <bruno@clisp.org>
45366
45367         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
45368         /bin/sh understanding of '!' conditional negation.
45369
45370 2006-08-21  Jim Meyering  <jim@meyering.net>
45371
45372         * modules/openat (Depends-on): Really alphabetize.
45373
45374         * modules/acl (Depends-on): Add error and quote.
45375
45376         * check-module (find_included_lib_files): Add at-func.c to the
45377         ok-to-include-more-than-once white list.
45378
45379         * modules/openat (Depends-on): Add lstat.  Alphabetize.
45380
45381 2006-08-21  Bruno Haible  <bruno@clisp.org>
45382
45383         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
45384         Emit a pkgdata_DATA variable only if some snippets add contents to it.
45385         Reported by Martin Lambers <marlam@marlam.de>.
45386
45387 2006-08-21  Bruno Haible  <bruno@clisp.org>
45388
45389         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
45390         specify an installation location, don't emit a noinst_LIBRARIES or
45391         noinst_LTLIBRARIES assignment.
45392
45393 2006-08-21  Bruno Haible  <bruno@clisp.org>
45394
45395         BeOS portability.
45396         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
45397         BeOS has mbrtowc() but no <wctype.h>.
45398
45399 2006-08-21  Bruno Haible  <bruno@clisp.org>
45400
45401         BeOS portability.
45402         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
45403         exist.
45404
45405 2006-08-21  Bruno Haible  <bruno@clisp.org>
45406
45407         BeOS portability.
45408         * lib/mbchar.h: Include <wctype.h> only if it exists.
45409
45410 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
45411
45412         Remove files that are no longer needed by their respective modules.
45413         * m4/obstack.m4: Remove.
45414         * m4/strerror_r.m4: Remove.
45415         * m4/uint32_t.m4: Remove.
45416         * m4/uintptr_t.m4: Remove.
45417         * m4/ullong_max.m4: Remove.
45418         * m4/xstrtoimax.m4: Remove.
45419         * m4/xstrtoumax.m4: Remove.
45420
45421         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
45422         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
45423         dependencies now capture this.
45424
45425         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
45426         Do not use AC_LIBSOURCES, since gnulib modules now do this.
45427         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
45428         * m4/human.m4 (gl_HUMAN): Likewise.
45429         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
45430         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
45431
45432         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
45433
45434         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
45435         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
45436         stdint.
45437         * m4/human.m4 (gl_HUMAN): Likewise.
45438         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
45439         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
45440         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
45441         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
45442         * m4/xstrtol (gl_XSTRTOL): Likewise.
45443
45444         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
45445         AC_TYPE_LONG_LONG_INT.
45446         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
45447         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
45448         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
45449         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
45450
45451         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
45452         on stdbool.
45453
45454         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
45455         (gl_PREREQ_XSTRTOUL): Remove.
45456
45457         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
45458
45459         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
45460         mode.
45461
45462 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
45463
45464         Add and change modules to make it easier for coreutils to use
45465         gnulib-tool.
45466         * modules/backupfile (Files): Remove m4/d-ino.m4.
45467         (Depends-on): Add d-ino.
45468         * modules/cycle-check (Depends-on): Add stdint.
45469         (lib_SOURCES): Add cycle-check.h.
45470         * modules/d-ino: New module.
45471         * modules/d-type: New module.
45472         * modules/error (Files): Remove m4/strerror_r.m4.
45473         * modules/filemode (Files): Add m4/st_dm_mode.m4.
45474         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
45475         m4/inttypes_h.m4, m4/uintmax_t.m4.
45476         (Depends-on): Add stdint.
45477         (lib_SOURCES): Add fsusage.h.
45478         * modules/getcwd (Files): Remove d-ino.m4.
45479         (Depends-on): Add d-ino.
45480         * modules/getndelim2 (Depends-on): Add stdint.
45481         * modules/glob (Files): Remove m4/d-type.m4.
45482         (Depends-on): Add d-type.
45483         * modules/host-os: New module.
45484         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
45485         m4/inttypes_h.m4, m4/uintmax_t.m4.
45486         * Depends-on: Add stdint.
45487         (lib_SOURCES): Add human.h.
45488         * modules/inttostr (Files): Remove m4/intmax_t.m4,
45489         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
45490         m4/uintmax_t.m4, m4/ulonglong.m4.
45491         (Depends-on): Add stdint.
45492         (EXTRA_DIST): Add inttostr.h.
45493         * modules/lchmod: New module.
45494         * modules/link-follow: New module.
45495         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
45496         (Depends-on): Add lchmod.
45497         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
45498         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
45499         (Depends-on): Add stdint.
45500         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
45501         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
45502         (Depends-on): Add stdint.
45503         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
45504         * modules/perl: New module.
45505         * modules/regex (Depends-on): Add stdint.
45506         * modules/rmdir-errno: New module.
45507         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
45508         m4/intmax_t.m4.
45509         (Depends-on): Add stdint.
45510         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
45511         m4/uintmax_t.m4.
45512         (Depends-on): Add stdint.
45513         * modules/unlink-busy: New module.
45514         * modules/utimecmp (Depends-on): Add stdint.
45515         * modules/uptime: New module.
45516         * modules/winsz-ioctl: New module.
45517         * modules/winsz-termios: New module.
45518         * modules/xnanosleep (Depends-on): Add nanosleep.
45519         * modules/ullong_max: Remove.
45520         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
45521         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
45522         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
45523         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
45524         (Depends-on): Add inttypes.
45525         (lib_SOURCES): Add xstrtol.h.
45526         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
45527         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
45528         * MODULES.html.sh: Move 'assert' into the assert section.
45529         Move 'dummy' into the linking section.
45530         Remove ullong_max.
45531         Add section for compatibility checks for POSIX:2001 functions,
45532         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
45533         winsz-ioctl, and winsz-termios into it.
45534         Add lchmod.
45535         Add top-level Misc section and put host-os, perl, and uptime
45536         into it.
45537
45538 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
45539
45540         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
45541         now assume the stdint module.  Do not include inttypes.h.
45542         * lib/fsusage.h: Likewise.
45543         * lib/getndelim2.c: Likewise.
45544         * lib/human.h: Likewise.
45545         * lib/inttostr.h: Likewise.
45546         * lib/obstack.c: Likewise.
45547         * lib/regex_internal.h: Likewise.
45548         * lib/tempname.c: Likewise.
45549         * lib/utimecmp.c: Likewise.
45550         * lib/xstrtol.h: Likewise.
45551
45552         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
45553
45554         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
45555         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
45556         * lib/xtime.h: Likewise.
45557
45558 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
45559
45560         * modules/openat (Files): Add lib/fchmodat.c.
45561         Fixes problem reported by Jay Youngman.
45562
45563 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
45564
45565         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
45566         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
45567
45568 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
45569             Bruno Haible  <bruno@clisp.org>
45570
45571         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
45572         and is a script that invokes bison. Tighten the code. Add comments.
45573
45574 2006-08-18  Jim Meyering  <jim@meyering.net>
45575
45576         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
45577         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
45578         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
45579         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
45580
45581 2006-08-18  Bruno Haible  <bruno@clisp.org>
45582
45583         * modules/bison-i18n: New file.
45584         * MODULES.html.sh (Internationalization functions): Add it.
45585
45586 2006-08-18  Bruno Haible  <bruno@clisp.org>
45587
45588         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
45589         sys/statvfs.h. When getmntinfo was found, check its declaration and
45590         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
45591
45592 2006-08-18  Bruno Haible  <bruno@clisp.org>
45593
45594         * m4/bison-i18n.m4: New file, from bison.
45595
45596 2006-08-18  Bruno Haible  <bruno@clisp.org>
45597
45598         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
45599         (ME_DUMMY): Treat "kernfs" as a dummy.
45600         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
45601
45602 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
45603
45604         Update from coreutils.
45605
45606         2006-08-15  Jim Meyering  <jim@meyering.net>
45607
45608         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
45609
45610         2006-01-17  Jim Meyering  <jim@meyering.net>
45611
45612         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
45613
45614         2006-01-11  Jim Meyering  <jim@meyering.net>
45615
45616         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
45617         Check for the lchmod function.
45618
45619 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
45620
45621         Update from coreutils.
45622
45623         * lib/__fpending.h: Add copyright notice.
45624         * lib/fprintftime.h: Likewise.
45625         * lib/savedir.c: Use (C) in copyright notice.
45626         * lib/savedir.h: Likewise.
45627
45628         2006-08-15  Jim Meyering  <jim@meyering.net>
45629
45630         * lib/at-func.c: New file, with the logic of all emulated at-functions.
45631         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
45632         in support of the EXPECTED_ERRNO macro.
45633         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
45634         definitions.  Instead, define the appropriate symbols and include
45635         "at-func.c".
45636         * lib/mkdirat.c (mkdirat): Likewise.
45637         * lib/fchmodat.c (fchmodat): Likewise.
45638         (ENOSYS): Remove definition.
45639         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
45640         it.  Don't include "unistd--.h" -- it wasn't ever used.
45641
45642         2006-01-17  Jim Meyering  <jim@meyering.net>
45643
45644         Rewrite fts.c not to change the current working directory,
45645         by using openat, fstatat, fdopendir, etc..
45646
45647         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
45648         (HAVE_OPENAT_SUPPORT): Define.
45649         [_LIBC] (fchdir): Don't undef or define; no longer used.
45650         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
45651         Now, this `function' always succeeds, and consumes its file descriptor
45652         parameter -- so callers must not close such FDs.  Update callers.
45653         (diropen_fd, opendirat, cwd_advance_fd): New functions.
45654         (diropen): Add parameter, SP.  Adjust all callers.
45655         Implement using diropen_fd, rather than open.
45656         (fts_open): Initialize new member, fts_cwd_fd.
45657         Remove fts_rft-setting code.
45658         (fts_close): Close fts_cwd_fd, if necessary.
45659         (__opendir2): Define in terms of opendir or opendirat,
45660         depending on whether the FST_NOCHDIR flag is set.
45661         (fts_build): Since fts_safe_changedir consumes its FD, and since
45662         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
45663         and close the dup'd file descriptor upon failure.
45664         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
45665         (fts_safe_changedir): Tweak semantics to reflect that this function
45666         now calls cwd_advance_fd and hence consumes its FD argument.
45667         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
45668         [struct FTS] (fts_rft): Remove now-unused member.
45669         [struct FTS] (fts_cycle.state): Improve comment.
45670
45671         * lib/openat.c (openat_needs_fchdir): New function.
45672         * lib/openat.h (openat_needs_fchdir): Declare it.
45673
45674 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
45675
45676         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
45677         Problem and fix reported by Pádraig Brady in
45678         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
45679
45680 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
45681
45682         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
45683
45684 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
45685
45686         * lib/memcoll.c (memcoll): Optimize for the common case where the
45687         arguments are bytewise equal.
45688
45689 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
45690
45691         * doc/regexprops-generic.texi: Add a copyright notice.
45692
45693 2006-08-15  Bruno Haible  <bruno@clisp.org>
45694
45695         * modules/tmpdir (License): Change to LGPL.
45696
45697 2006-08-15  Bruno Haible  <bruno@clisp.org>
45698
45699         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
45700         module.
45701
45702 2006-08-14  Simon Josefsson  <jas@extundo.com>
45703
45704         * config/srclist.txt: Add gnupload.
45705
45706 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
45707
45708         Change copyright notice from LGPL 2 to GPL 2, since that's the
45709         standard form used in the gnulib repository.
45710         * tests/test-lock.c: Likewise.
45711         * tests/test-stdint.c: Likewise.
45712         * tests/test-tls.c: Likewise.
45713
45714         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
45715         prelude-manager.  User shorter URLs for GNU projects, without '?'.
45716         Add copyright notice.
45717
45718         * check-module: Add copyright notice.  Output a copyright
45719         notice if "--version" is specified.
45720         * modules/COPYING: New file.
45721         * tests/test-getaddrinfo.c: Add copyright notice.
45722         * tests/test-verify.c: Likewise.
45723
45724 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
45725
45726         Change copyright notice from LGPL 2 to GPL 2, since that's the
45727         standard form used in the gnulib repository.
45728         * lib/lock.c: LGPL -> GPL.
45729         * lib/lock.h: Likewise.
45730         * lib/strnlen1.c: Likewise.
45731         * lib/strnlen1.h: Likewise.
45732         * lib/tls.c: Likewise.
45733         * lib/tls.h: Likewise.
45734         * lib/tmpdir.c: Likewise.
45735
45736         * lib/TODO: Remove; this belongs only in coreutils.
45737
45738 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
45739
45740         Add copyright notices to long-enough files that lack them, since
45741         otherwise the files aren't clearly free.  Use the same notice that
45742         getdate.texi already uses.
45743         * doc/alloca-opt.texi: Add copyright notice.
45744         * doc/alloca.texi: Likewise.
45745         * doc/ctime.texi: Likewise.
45746         * doc/functions.texi: Likewise.
45747         * doc/gcd.texi: Likewise.
45748         * doc/gnulib-tool.texi: Likewise.
45749         * doc/inet_ntoa.texi: Likewise.
45750         * doc/visibility.texi: Likewise.
45751
45752         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
45753         * doc/quote.texi: Add copyright notice.
45754
45755         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
45756         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
45757         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
45758         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
45759         is now obsolete, and give a pointer to the Sun list.
45760         Add copyright notice.
45761
45762 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
45763
45764         * config/srclistvars.sh: Add copyright notice.
45765
45766 2006-08-14  Eric Blake  <ebb9@byu.net>
45767
45768         Import the following change from libc:
45769
45770         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
45771
45772         Upstream bug 2997.
45773         * lib/misc/error.c: Add space between program name and message if file
45774         name is missing.
45775
45776 2006-08-12  Karl Berry  <karl@gnu.org>
45777
45778         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
45779         remove, these originate in gnulib now.
45780
45781 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
45782
45783         * doc/Makefile (standards.info standards.html standards.dvi):
45784         Also depend on make-stds.texi.
45785
45786 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
45787
45788         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
45789         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
45790
45791         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
45792         in wchar_t.  Problem reported by Eric Blake.
45793
45794         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
45795         LEN is smaller than SIZE.  Suggested by Bruno Haible.
45796         Also, help the compiler to keep LEN in a register.
45797
45798 2006-08-11  Eric Blake  <ebb9@byu.net>
45799
45800         * users.txt: Sort.  Add tar.
45801
45802 2006-08-11  Bruno Haible  <bruno@clisp.org>
45803
45804         * users.txt: New file.
45805
45806 2006-08-11  Bruno Haible  <bruno@clisp.org>
45807
45808         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
45809         before <wchar.h>. Needed for OSF/1 and BSD/OS.
45810
45811 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
45812
45813         * modules/snprintf (Depends-on): Remove minmax.
45814         (Maintainer): Add self and Bruno.
45815
45816 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
45817
45818         * lib/.cppi-disable: Add snprintf.h, socket_.h.
45819         * lib/snprintf.c: Include <errno.h> and <limits.h>.
45820         (EOVERFLOW): Define if the system does not.
45821         Do not include "minmax.h"; it wasn't used.
45822         (snprintf): Don't assume size_t promotes to an unsigned type.
45823         Fix bug when generated string was too long for the buffer: the
45824         buffer's contents are supposed to be the initial prefix of the
45825         output.  Don't assume vasnprintf returns EOVERFLOW if the size
45826         exceeds INT_MAX; do the check ourselves.
45827
45828         Import the following changes from libc:
45829
45830         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
45831
45832         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
45833         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
45834         set wc to the byte which couldn't be converted.
45835         (re_string_reconstruct): Don't clear valid_raw_len before calling
45836         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
45837         tip_context using re_string_context_at.
45838
45839         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
45840
45841         * lib/posix/regex.h: g++ still cannot handled [restrict].
45842
45843         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
45844
45845         * lib/posix/regex.h: Remove special handling for VMS.
45846
45847 2006-08-10  Jim Meyering  <jim@meyering.net>
45848
45849         * modules/same-inode: New module.
45850         * modules/dev-ino: New module.
45851         * modules/cycle-check: Depend on these modules, rather than simply
45852         including their .h files.
45853         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
45854         required via m4/cycle-check.m4.
45855         * modules/same: Depend on new same-inode module, rather than
45856         including same-inode.h.
45857         * modules/chdir-safer: New file.
45858
45859         * modules/chown (Depends-on): Add stat-macros.
45860
45861 2006-08-10  Jim Meyering  <jim@meyering.net>
45862
45863         * m4/cycle-check.m4: New file.
45864         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
45865         * m4/dev-ino.m4, m4/same-inode.m4: New files.
45866
45867 2006-08-10  Eric Blake  <ebb9@byu.net>
45868
45869         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
45870         in from original proposal.
45871
45872 2006-08-10  Eric Blake  <ebb9@byu.net>
45873         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
45874
45875         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
45876         namespace.
45877
45878 2006-08-10  Bruno Haible  <bruno@clisp.org>
45879
45880         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
45881         as well.
45882
45883 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
45884
45885         Sync from coreutils.
45886
45887         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
45888
45889         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
45890         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
45891
45892 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
45893
45894         * modules/restrict: Remove; no longer needed now that we assume
45895         Autoconf 2.59 or later.
45896         * MODULES.html.sh: Remove 'restrict'.
45897         * modules/argp (Depends-on): Remove 'restrict'.
45898         * modules/base64 (Depends-on): Likewise.
45899         * modules/gc (Depends-on): Likewise.
45900         * modules/getaddrinfo (Depends-on): Likewise.
45901         * modules/glob (Depends-on): Likewise.
45902         * modules/inet_ntop (Depends-on): Likewise.
45903         * modules/inet_pton (Depends-on): Likewise.
45904         * modules/memxor (Depends-on): Likewise.
45905         * modules/regex (Depends-on): Likewise.
45906         * modules/strtok_r (Depends-on): Likewise.
45907         * modules/time_r (Depends-on): Likewise.
45908
45909 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
45910
45911         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
45912         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
45913         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
45914         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
45915         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
45916         * m4/memxor.m4 (gl_MEMXOR): Likewise.
45917         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
45918         gl_C_RESTRICT replaced by AC_C_RESTRICT.
45919
45920         Merge from coreutils.
45921         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
45922         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
45923         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
45924         * m4/time_r.m4 (gl_TIME_R): Likewise.
45925
45926 2006-08-09  Karl Berry  <karl@gnu.org>
45927
45928         * config/srclist.txt: no more gettext-tools, per Bruno.
45929
45930 2006-08-08  Eric Blake  <ebb9@byu.net>
45931
45932         * modules/verror: New module.
45933         * MODULES.html.sh: Document it.
45934
45935 2006-08-08  Eric Blake  <ebb9@byu.net>
45936
45937         * lib/verror.h, lib/verror.c: New files.
45938
45939 2006-08-08  Eric Blake  <ebb9@byu.net>
45940
45941         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
45942         verror_at_line output complies with GNU Coding Standards even when
45943         file is NULL.
45944
45945 2006-08-07  Bruno Haible  <bruno@clisp.org>
45946
45947         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
45948         versions of AIX.
45949         Reported by Ralf Wildenhues.
45950
45951 2006-08-07  Bruno Haible  <bruno@clisp.org>
45952
45953         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
45954         in an AC_DEFUN. Needed so that the autoconf snippets can use
45955         AC_REQUIRE.
45956
45957 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
45958
45959         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
45960         Initialize pkgdata_DATA.
45961         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
45962         overriding it.
45963
45964 2006-08-06  Eric Blake  <ebb9@byu.net>
45965
45966         * lib/error.h: Fold in some upstream changes from glibc.
45967         * lib/error.c: Likewise.
45968
45969 2006-08-04  Bruno Haible  <bruno@clisp.org>
45970
45971         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
45972         Make the mostlyclean-local rule depend on mostlyclean-generic.
45973         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
45974
45975 2006-07-31  Bruno Haible  <bruno@clisp.org>
45976
45977         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
45978         <stdlib.h>, <string.h>.
45979
45980 2006-07-30  Bruno Haible  <bruno@clisp.org>
45981
45982         * modules/readlink (License): Change to LGPL.
45983
45984 2006-07-30  Bruno Haible  <bruno@clisp.org>
45985
45986         * modules/javaversion (Makefile.am): Distribute javaversion.java and
45987         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
45988         set PKGDATADIR to point to it.
45989
45990 2006-07-30  Bruno Haible  <bruno@clisp.org>
45991
45992         * modules/csharpexec (configure.ac): Comment out macro invocation.
45993         * modules/javaexec (configure.ac): Likewise.
45994         * modules/javacomp-script (configure.ac): Likewise.
45995
45996         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
45997
45998 2006-07-30  Bruno Haible  <bruno@clisp.org>
45999
46000         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
46001         linked-list.
46002
46003 2006-07-30  Bruno Haible  <bruno@clisp.org>
46004
46005         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
46006
46007 2006-07-30  Bruno Haible  <bruno@clisp.org>
46008
46009         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
46010         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
46011         get removed.
46012
46013 2006-07-29  Bruno Haible  <bruno@clisp.org>
46014
46015         Make it possible for gnulib-tool to work with locally modified or
46016         augmented gnulib repositories.
46017         * gnulib-tool (func_usage): Document --local-dir option.
46018         (local_gnulib_dir): New variable.
46019         Handle --local-dir option.
46020         (func_lookup_file): New function.
46021         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
46022         (func_get_description, func_get_filelist, func_get_description,
46023         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
46024         func_get_automake_snippet, func_get_include_directive,
46025         func_get_license, func_get_maintainer): Use func_lookup_file.
46026         (func_import, func_create_testdir): Use func_lookup_file.
46027
46028 2006-07-29  Bruno Haible  <bruno@clisp.org>
46029
46030         * modules/setenv (Depends-on): Add unistd.
46031
46032 2006-07-29  Bruno Haible  <bruno@clisp.org>
46033
46034         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
46035
46036 2006-07-29  Bruno Haible  <bruno@clisp.org>
46037
46038         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
46039
46040 2006-07-29  Bruno Haible  <bruno@clisp.org>
46041
46042         * gnulib-tool (import, update): If there is no Makefile.am, look at
46043         aclocal.m4, instead of bailing out.
46044
46045 2006-07-29  Bruno Haible  <bruno@clisp.org>
46046
46047         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
46048         Categorize the options by when they are useful.
46049
46050 2006-07-29  Bruno Haible  <bruno@clisp.org>
46051
46052         * gnulib-tool (func_usage): Document option --no-libtool.
46053         Handle option --no-libtool.
46054         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
46055         for changed semantics of $libtool variable.
46056         (func_import): Likewise. If libtool is not used, show this through
46057         an option --no-libtool.
46058         (func_create_testdir): Update.
46059
46060 2006-07-29  Bruno Haible  <bruno@clisp.org>
46061
46062         * gnulib-tool (func_import): Extend error message about missing
46063         --doc-base.
46064
46065 2006-07-29  Bruno Haible  <bruno@clisp.org>
46066
46067         * gnulib-tool (func_import): Don't create the $docbase directory if
46068         there is no file to store there.
46069
46070 2006-07-29  Bruno Haible  <bruno@clisp.org>
46071
46072         * gnulib-tool (autoconf_minversion): If a --dir option is given and
46073         relevant, look for configure.ac there, not in the current directory.
46074         Also use a simple search for AC_PREREQ, not "autoconf --trace".
46075
46076 2006-07-29  Bruno Haible  <bruno@clisp.org>
46077
46078         * gnulib-tool (SORT): New variable.
46079         (func_usage): Undocument --assume-autoconf option.
46080         Remove --assume-autoconf option handling.
46081         (autoconf_minversion): Determine from the contents of configure.ac.
46082         (func_import): Remove autoconf_minversion handling.
46083         Suggested by Eric Blake.
46084
46085 2006-07-29  Bruno Haible  <bruno@clisp.org>
46086
46087         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
46088
46089 2006-07-29  Bruno Haible  <bruno@clisp.org>
46090
46091         * config/srclist.txt (*setenv.[ch]): Remove rules.
46092
46093 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
46094
46095         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
46096
46097 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
46098
46099         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
46100         arpa/inet.h.
46101
46102 2006-07-28  Simon Josefsson  <jas@extundo.com>
46103
46104         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
46105         * modules/inet_pton (Depends-on): Likewise.
46106
46107 2006-07-28  Simon Josefsson  <jas@extundo.com>
46108
46109         * m4/netinet_in_h.m4: New file.
46110
46111 2006-07-28  Simon Josefsson  <jas@extundo.com>
46112
46113         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
46114         #include's.
46115
46116 2006-07-28  Simon Josefsson  <jas@extundo.com>
46117
46118         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
46119         #include's.
46120
46121 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
46122
46123         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
46124         setgid on directories only if they set these bits.
46125         * lib/modechange.h: Remove obsolete comment about masks.
46126
46127 2006-07-28  Eric Blake  <ebb9@byu.net>
46128
46129         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
46130         macro expansion.
46131
46132 2006-07-28  Bruno Haible  <bruno@clisp.org>
46133
46134         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
46135
46136 2006-07-28  Bruno Haible  <bruno@clisp.org>
46137
46138         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
46139
46140 2006-07-28  Bruno Haible  <bruno@clisp.org>
46141
46142         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
46143         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
46144         Define fallbacks.
46145         Avoids link error on FreeBSD 4.x.
46146         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
46147
46148         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
46149         encoding.
46150         * lib/mbswidth.c (iswcntrl): Likewise.
46151
46152 2006-07-27  Bruno Haible  <bruno@clisp.org>
46153
46154         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
46155         test.
46156
46157 2006-07-27  Bruno Haible  <bruno@clisp.org>
46158
46159         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
46160         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
46161         defined.
46162
46163 2006-07-26  Eric Blake  <ebb9@byu.net>
46164
46165         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
46166
46167 2006-07-26  Eric Blake  <ebb9@byu.net>
46168
46169         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
46170         like mingw that lack mkstemp.
46171         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
46172         avoid compilation warning on mingw.
46173
46174 2006-07-26  Bruno Haible  <bruno@clisp.org>
46175
46176         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
46177         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
46178         INT_FAST*_MIN, INTPTR_MIN.
46179
46180 2006-07-25  Bruno Haible  <bruno@clisp.org>
46181
46182         * modules/version-etc (Depends-on): Add stdarg.
46183
46184 2006-07-25  Bruno Haible  <bruno@clisp.org>
46185
46186         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
46187         complex commands.
46188
46189 2006-07-25  Bruno Haible  <bruno@clisp.org>
46190
46191         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
46192         defined in <stdarg.h> or config.h.
46193
46194 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
46195
46196         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
46197         (gl_STDIO_SAFER): Remove.
46198
46199 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
46200
46201         * MODULES.html.sh (File stream based Input/Output):
46202         Add fopen-safer, tmpfile-safer; remove stdio-safer.
46203         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
46204         * modules/fopen-safer, modules/tmpfile-safer: New files.
46205         * modules/stdio-safer: Remove.
46206
46207 2006-07-24  Bruno Haible  <bruno@clisp.org>
46208
46209         * modules/tmpdir: New file.
46210         * MODULES.html.sh (File system functions): Add it.
46211
46212 2006-07-24  Bruno Haible  <bruno@clisp.org>
46213
46214         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
46215         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
46216
46217 2006-07-24  Bruno Haible  <bruno@clisp.org>
46218
46219         * modules/clean-temp: New file.
46220
46221 2006-07-24  Bruno Haible  <bruno@clisp.org>
46222
46223         * m4/tmpdir.m4: New file, from GNU gettext.
46224
46225 2006-07-24  Bruno Haible  <bruno@clisp.org>
46226
46227         * lib/tmpdir.h: New file, from GNU gettext.
46228         * lib/tmpdir.c: New file, from GNU gettext.
46229
46230 2006-07-24  Bruno Haible  <bruno@clisp.org>
46231
46232         * lib/clean-temp.h: New file, from GNU gettext.
46233         * lib/clean-temp.c: New file, from GNU gettext.
46234
46235 2006-07-23  Eric Blake  <ebb9@byu.net>
46236
46237         * modules/stdio-safer (Files): Add tmpfile-safer.c.
46238         (Depends-on): Add binary-io.
46239
46240 2006-07-23  Eric Blake  <ebb9@byu.net>
46241
46242         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
46243
46244 2006-07-23  Eric Blake  <ebb9@byu.net>
46245
46246         * lib/tmpfile-safer.c: New file.
46247         * lib/stdio-safer.h (fopen_safer): Add prototype.
46248         * lib/stdio--.h (tmpfile): Make safer.
46249
46250 2006-07-23  Bruno Haible  <bruno@clisp.org>
46251
46252         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
46253         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
46254         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
46255         gl_linked_remove_at): Use it.
46256
46257 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
46258         and Simon Josefsson <jas@extundo.com>
46259
46260         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
46261
46262         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
46263
46264 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
46265
46266         * modules/close-stream: New file.
46267         * modules/closeout (Description): Make it clear that it exits
46268         with a diagnostic on error.
46269         (Depends-on): Add close-stream.  Remove fpending, stdbool.
46270         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
46271
46272 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
46273
46274         * m4/close-stream.m4: New file.
46275
46276 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
46277
46278         * lib/close-stream.c, lib/close-stream.h: New files.
46279
46280 2006-07-22  Bruno Haible  <bruno@clisp.org>
46281
46282         Merge from GNU gettext 0.15.
46283
46284         2006-05-01  Bruno Haible  <bruno@clisp.org>
46285
46286                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
46287
46288         2006-07-22  Bruno Haible  <bruno@clisp.org>
46289
46290                 * modules/javaversion: New file.
46291                 * MODULES.html.sh (Java): Add javaversion.
46292
46293         2006-03-12  Bruno Haible  <bruno@clisp.org>
46294
46295                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
46296
46297         2005-12-04  Bruno Haible  <bruno@clisp.org>
46298
46299                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
46300                 (untested).
46301
46302         2006-06-21  Bruno Haible  <bruno@clisp.org>
46303
46304                 Avoid warnings from recent versions of mcs.
46305                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
46306                 -o, -L, -r any more. Use options documented since mcs-1.0
46307                 instead. Similarly for -g.
46308
46309         2005-12-04  Bruno Haible  <bruno@clisp.org>
46310
46311                 * build-aux/csharpcomp.sh.in: Suffix for resources is
46312                 .resources, not .resource.
46313
46314         2005-07-09  Bruno Haible  <bruno@clisp.org>
46315
46316                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
46317                 add a .dll suffix.
46318                 Reported by Mark Junker <mjscod@gmx.de>.
46319
46320         2006-07-22  Bruno Haible  <bruno@clisp.org>
46321
46322                 * modules/gettext: Upgrade to gettext-0.15.
46323                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
46324                 m4/visibility.m4.
46325                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
46326
46327 2006-07-22  Bruno Haible  <bruno@clisp.org>
46328
46329         Merge from GNU gettext 0.15.
46330
46331         2006-03-25  Bruno Haible  <bruno@clisp.org>
46332
46333                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
46334
46335         2006-07-21  Bruno Haible  <bruno@clisp.org>
46336
46337                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
46338                 "1.1".
46339
46340         2006-05-09  Bruno Haible  <bruno@clisp.org>
46341
46342                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
46343                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
46344                 for the conftestver execution.
46345
46346         2006-05-01  Bruno Haible  <bruno@clisp.org>
46347
46348                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
46349                 optional target-version argument. Verify that the compiler
46350                 groks source of the specified source-version, or add -source
46351                 option as necessary. Verify that the compiler produces
46352                 bytecode in the specified target-version, or add -target and
46353                 -source options as necessary. Make the result of the test
46354                 available as variable CONF_JAVAC. Also log error output in
46355                 config.log.
46356
46357         2006-03-11  Bruno Haible  <bruno@clisp.org>
46358
46359                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
46360
46361         2006-05-09  Bruno Haible  <bruno@clisp.org>
46362
46363                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
46364                 CLASSPATH_SEPARATOR to a semicolon.
46365
46366         2006-03-12  Bruno Haible  <bruno@clisp.org>
46367
46368                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
46369                 available as variable CONF_JAVA, for subsequent autoconf
46370                 tests. Also log error output in config.log.
46371
46372         2006-07-19  Bruno Haible  <bruno@clisp.org>
46373
46374                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
46375                 that getline works on glibc2 systems. Needed to avoid trouble
46376                 in relocatable.c.
46377                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
46378
46379         2005-12-04  Bruno Haible  <bruno@clisp.org>
46380
46381                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
46382                 launcher (untested).
46383
46384         2005-12-04  Bruno Haible  <bruno@clisp.org>
46385
46386                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
46387
46388         2006-07-22  Bruno Haible  <bruno@clisp.org>
46389
46390                 * gettext.m4: Update from GNU gettext-0.15.
46391                 * nls.m4: Likewise.
46392                 * po.m4: Likewise.
46393                 * inttypes-pri.m4: Likewise.
46394                 * inttypes-h.m4: Renamed from inttypes.m4.
46395                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
46396
46397 2006-07-22  Bruno Haible  <bruno@clisp.org>
46398
46399         Merge from GNU gettext 0.15.
46400
46401         2005-07-05  Bruno Haible  <bruno@clisp.org>
46402
46403                 * printf-args.c (printf_fetchargs): Work around broken
46404                 definition of wint_t on mingw.
46405
46406         2005-02-12  Bruno Haible  <bruno@clisp.org>
46407
46408                 * xallocsa.h: Add extern "C" for C++.
46409
46410         2006-05-17  Bruno Haible  <bruno@clisp.org>
46411
46412                 Cygwin portability.
46413                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
46414
46415         2006-04-30  Bruno Haible  <bruno@clisp.org>
46416
46417                 * progreloc.c: Include <mach-o/dyld.h> if available.
46418                 (find_executable): Use _NSGetExecutablePath when possible.
46419
46420         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
46421
46422                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
46423                 function.
46424
46425         2005-12-29  Bruno Haible  <bruno@clisp.org>
46426
46427                 * progreloc.c (set_program_name_and_installdir): Fix
46428                 compilation error.
46429
46430         2005-12-04  Bruno Haible  <bruno@clisp.org>
46431
46432                 Cygwin portability.
46433                 * progreloc.c: Include <windows.h> also on Cygwin.
46434                 (find_executable): Add support for Cygwin.
46435                 (set_program_name_and_installdir): Handle also platforms with
46436                 nonempty EXEEXT.
46437
46438         2006-07-11  Bruno Haible  <bruno@clisp.org>
46439
46440                 * javacomp.c: Fix a comment.
46441                 Reported by Jim Meyering.
46442
46443         2006-04-30  Bruno Haible  <bruno@clisp.org>
46444
46445                 * javacomp.h (compile_java_class): Add source_version,
46446                 target_version arguments.
46447                 * javacomp.c: Rewritten to choose only a compiler that
46448                 respects the specified source_version and target_version.
46449
46450         2006-06-27  Bruno Haible  <bruno@clisp.org>
46451
46452                 Assume correct S_ISDIR macro.
46453                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
46454
46455         2006-07-22  Bruno Haible  <bruno@clisp.org>
46456
46457                 * javaversion.h: New file, from GNU gettext.
46458                 * javaversion.c: New file, from GNU gettext.
46459                 * javaversion.java: New file, from GNU gettext.
46460                 * javaversion.class: New file, from GNU gettext.
46461
46462         2006-05-17  Bruno Haible  <bruno@clisp.org>
46463
46464                 Cygwin portability.
46465                 * javaexec.c (execute_java_class): Test for jview program
46466                 also on Cygwin.
46467
46468         2006-04-09  Bruno Haible  <bruno@clisp.org>
46469
46470                 * fatal-signal.c: Don't include string.h.
46471                 (at_fatal_signal): Use a copying loop instead of memcpy.
46472
46473         2005-12-04  Bruno Haible  <bruno@clisp.org>
46474
46475                 * csharpexec.c: Add support for 'clix' launcher (untested).
46476                 (execute_csharp_using_sscli): New function.
46477                 (execute_csharp_program): Call it.
46478
46479         2006-06-21  Bruno Haible  <bruno@clisp.org>
46480
46481                 Avoid warnings from recent versions of mcs.
46482                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
46483                 -o, -L, -r any more. Use options documented since mcs-1.0
46484                 instead. Similarly for -g.
46485
46486         2005-07-09  Bruno Haible  <bruno@clisp.org>
46487
46488                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
46489                 add a .dll suffix.
46490                 Reported by Mark Junker <mjscod@gmx.de>.
46491
46492         2006-06-17  Bruno Haible  <bruno@clisp.org>
46493
46494                 * config.charset: Update for NetBSD 3.0.
46495
46496         2006-05-17  Bruno Haible  <bruno@clisp.org>
46497
46498                 Cygwin portability.
46499                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
46500
46501         2006-05-16  Bruno Haible  <bruno@clisp.org>
46502
46503                 * localcharset.c [CYGWIN]: Include <windows.h>.
46504                 (get_charset_aliases): For Cygwin, return the same CPxxx
46505                 aliases list as under WIN32.
46506                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
46507                 the environment variables. Fall back to GetACP().
46508
46509         2006-04-05  Bruno Haible  <bruno@clisp.org>
46510
46511                 * config.charset: Update Juan Manuel Guerrero's address.
46512
46513         2005-02-12  Bruno Haible  <bruno@clisp.org>
46514
46515                 * allocsa.h: Add extern "C" for C++.
46516
46517         2005-02-10  Bruno Haible  <bruno@clisp.org>
46518
46519                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
46520                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
46521
46522         2006-07-22  Bruno Haible  <bruno@clisp.org>
46523
46524                 * gettext.h: Update to GNU gettext-0.15.
46525
46526 2006-07-22  Bruno Haible  <bruno@clisp.org>
46527
46528         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
46529         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
46530         lib-prefix.m4, longdouble.m4, ssize_t.m4.
46531
46532 2006-07-21  Eric Blake  <ebb9@byu.net>
46533
46534         * modules/stdlib-safer: New file.
46535         * MODULES.html.sh (File stream based Input/Output): Add
46536         stdlib-safer.
46537
46538 2006-07-21  Eric Blake  <ebb9@byu.net>
46539
46540         * lib/stdlib-safer.h: New file from coreutils, required by
46541         stdlib--.h.
46542
46543 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
46544
46545         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
46546
46547 2006-07-20  Bruno Haible  <bruno@clisp.org>
46548
46549         * gnulib-tool: Recognize new option --assume-autoconf.
46550         (autoconf_minversion): New variable.
46551         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
46552
46553 2006-07-20  Bruno Haible  <bruno@clisp.org>
46554
46555         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
46556
46557 2006-07-19  Derek R. Price  <derek@ximbiot.com>
46558
46559         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
46560         Reindent and repaginate.
46561
46562 2006-07-19  Derek Price  <derek@ximbiot.com>
46563
46564         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
46565         Correct grammar.
46566
46567 2006-07-17  Bruno Haible  <bruno@clisp.org>
46568
46569         * modules/list: New file.
46570         * modules/array-list: New file.
46571         * modules/carray-list, modules/carray-list-tests: New files.
46572         * modules/linked-list, modules/linked-list-tests: New files.
46573         * modules/avltree-list, modules/avltree-list-tests: New files.
46574         * modules/rbtree-list, modules/rbtree-list-tests: New files.
46575         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
46576         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
46577         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
46578         * modules/oset: New file.
46579         * modules/array-oset: New file.
46580         * modules/avltree-oset, modules/avltree-oset-tests: New files.
46581         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
46582         * tests/test-carray_list.c: New file.
46583         * tests/test-linked_list.c: New file.
46584         * tests/test-avltree_list.c: New file.
46585         * tests/test-rbtree_list.c: New file.
46586         * tests/test-linkedhash_list.c: New file.
46587         * tests/test-avltreehash_list.c: New file.
46588         * tests/test-rbtreehash_list.c: New file.
46589         * tests/test-avltree_oset.c: New file.
46590         * tests/test-rbtree_oset.c: New file.
46591         * MODULES.html.sh (Container data structures): New section.
46592
46593 2006-07-17  Bruno Haible  <bruno@clisp.org>
46594
46595         * m4/gl_list.m4: New file.
46596
46597 2006-07-17  Bruno Haible  <bruno@clisp.org>
46598
46599         * lib/gl_list.h: New file.
46600         * lib/gl_list.c: New file.
46601         * lib/gl_array_list.h: New file.
46602         * lib/gl_array_list.c: New file.
46603         * lib/gl_carray_list.h: New file.
46604         * lib/gl_carray_list.c: New file.
46605         * lib/gl_linked_list.h: New file.
46606         * lib/gl_linked_list.c: New file.
46607         * lib/gl_anylinked_list1.h: New file.
46608         * lib/gl_anylinked_list2.h: New file.
46609         * lib/gl_avltree_list.h: New file.
46610         * lib/gl_avltree_list.c: New file.
46611         * lib/gl_anyavltree_list1.h: New file.
46612         * lib/gl_anyavltree_list2.h: New file.
46613         * lib/gl_rbtree_list.h: New file.
46614         * lib/gl_rbtree_list.c: New file.
46615         * lib/gl_anyrbtree_list1.h: New file.
46616         * lib/gl_anyrbtree_list2.h: New file.
46617         * lib/gl_anytree_list1.h: New file.
46618         * lib/gl_anytree_list2.h: New file.
46619         * lib/gl_linkedhash_list.h: New file.
46620         * lib/gl_linkedhash_list.c: New file.
46621         * lib/gl_anyhash_list1.h: New file.
46622         * lib/gl_anyhash_list2.h: New file.
46623         * lib/gl_avltreehash_list.h: New file.
46624         * lib/gl_avltreehash_list.c: New file.
46625         * lib/gl_rbtreehash_list.h: New file.
46626         * lib/gl_rbtreehash_list.c: New file.
46627         * lib/gl_anytreehash_list1.h: New file.
46628         * lib/gl_anytreehash_list2.h: New file.
46629
46630         * lib/gl_oset.h: New file.
46631         * lib/gl_oset.c: New file.
46632         * lib/gl_array_oset.h: New file.
46633         * lib/gl_array_oset.c: New file.
46634         * lib/gl_avltree_oset.h: New file.
46635         * lib/gl_avltree_oset.c: New file.
46636         * lib/gl_rbtree_oset.h: New file.
46637         * lib/gl_rbtree_oset.c: New file.
46638         * lib/gl_anytree_oset.h: New file.
46639
46640 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
46641
46642         * m4/mkancesdirs.m4: New file.
46643         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
46644         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
46645         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
46646         it.
46647
46648 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
46649
46650         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
46651         * lib/mkancesdirs.h: New files.
46652         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
46653         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
46654         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
46655         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
46656         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
46657         callers changed.  Revamp internals significantly, by not
46658         attempting to create directories that are temporarily more
46659         permissive than the final results.  Do not attempt to use
46660         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
46661         This removes some race conditions, fixes some bugs, and simplifies
46662         things.  Use new dirchownmod function to do owner and mode changes.
46663         * lib/mkdir-p.h: Likewise.
46664         * lib/modechange.c (octal_to_mode): New function.
46665         (struct mode_change): New member mentioned.
46666         (make_node_op_equals): New arg mentioned.  All callers changed.
46667         (mode_compile): Keep track of which mode bits the user has explicitly
46668         mentioned.
46669         (mode_adjust): New arg DIR, so that we implement the X op correctly.
46670         New arg PMODE_BITS, to keep track of which mode bits the user
46671         mentioned; it treats S_ISUID and S_ISGID speciall.
46672         All callers changed.
46673         * lib/modechange.h: Likewise.
46674
46675 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
46676
46677         * MODULES.html.sh: Add mkancestors.
46678         * modules/mkancesdirs: New module.
46679         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
46680         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
46681         The chdir-safer and afs files are now orphans; I'll remove them
46682         unless someone speaks up.
46683         Add lib/dirchownmod.c, lib/dirchownmod.h.
46684         (Depends-on): Remove alloca, chown, save-cwd, dirname.
46685         Add lchown, mkancesdirs.
46686         (Maintainer): Add self.
46687
46688 2006-07-15  Karl Berry  <karl@gnu.org>
46689
46690         * gnulib-tool: help message wording/arrangement.
46691
46692 2006-07-14  Simon Josefsson  <jas@extundo.com>
46693
46694         * doc/gnulib.texi (Libtool and Windows): New section.
46695
46696 2006-07-12  Simon Josefsson  <jas@extundo.com>
46697
46698         * modules/gendocs (License): Fix license, approved by Karl.
46699
46700 2006-07-12  Eric Blake  <ebb9@byu.net>
46701
46702         * MODULES.html.sh: Add gendocs.
46703
46704 2006-07-11  Eric Blake  <ebb9@byu.net>
46705
46706         * modules/fdl: New module, to install doc/fdl.texi.
46707         * MODULES.html.sh: Add new section for documentation modules.
46708         * gnulib-tool: Avoid space-tab.
46709         (--doc-base): New option, to manage files from doc.
46710
46711 2006-07-11  Eric Blake  <ebb9@byu.net>
46712
46713         * m4/absolute-header.m4: Fix comments to match recent change.
46714
46715 2006-07-11  Eric Blake  <ebb9@byu.net>
46716
46717         * gnulib-tool: List --doc-base before --tests-base.
46718
46719 2006-07-11  Derek R. Price  <derek@ximbiot.com>
46720
46721         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
46722
46723 2006-07-11  Bruno Haible  <bruno@clisp.org>
46724
46725         * README: Mention where to put documentation.
46726
46727 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
46728
46729         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
46730
46731 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
46732
46733         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
46734         to stdint.m4.
46735
46736 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
46737
46738         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
46739         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
46740         "no/such/file/stdint.h" when there is no such file, so that
46741         the resulting C code can be parsed by dodgy compilers.
46742         Problems reported by Bob Proulx.
46743
46744 2006-07-10  Derek R. Price  <derek@ximbiot.com>
46745
46746         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
46747         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
46748         macros into the GNU _D_EXACT_NAMLEN.
46749         * lib/savedir.c:  Likewise.
46750         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
46751
46752 2006-07-10  Derek R. Price  <derek@ximbiot.com>
46753         and Paul Eggert  <eggert@cs.ucla.edu>
46754
46755         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
46756         * m4/savedir.m4:
46757         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
46758         macros into the GNU _D_EXACT_NAMLEN.
46759
46760 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
46761
46762         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
46763         around the absolute name, to work around a problem with the HP-UX
46764         11.23 native C compiler, reported by Bob Proulx.
46765
46766 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
46767
46768         * doc/maintain.texi, make-stds.texi: Sync from
46769         <http://savannah.gnu.org/projects/gnustandards>.
46770
46771 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
46772
46773         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
46774
46775 2006-07-09  Jim Meyering  <jim@meyering.net>
46776
46777         * m4/glob.m4: Remove a doubled word in a comment.
46778
46779 2006-07-09  Jim Meyering  <jim@meyering.net>
46780
46781         * lib/argp-pv.c: Remove a doubled word in a comment.
46782         * lib/check-version.c (check_version): Likewise.
46783         * lib/javacomp.c (compile_java_class): Likewise.
46784
46785 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
46786
46787         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
46788         for the benefit of people using Autoconf 2.60.  If you want to
46789         support older Autoconf versions you can copy m4/onceonly_2_57.m4
46790         (or m4/onceonly.m4, if pre-2.57) manually.
46791
46792 2006-07-08  Jim Meyering  <jim@meyering.net>
46793
46794         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
46795         comment.
46796         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
46797         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
46798         comment.
46799
46800 2006-07-08  Jim Meyering  <jim@meyering.net>
46801
46802         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
46803
46804 2006-07-07  Simon Josefsson  <jas@extundo.com>
46805
46806         * tests/test-crc.c: Change expected crc value, the test vector
46807         were probably computed using the old broken crc.c?
46808
46809 2006-07-06  Simon Josefsson  <jas@extundo.com>
46810
46811         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
46812         now the canonical place for the M4 file).
46813
46814         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
46815         from the sys_socket dependency now.
46816
46817         * modules/inet_pton (Files): Ditto.
46818
46819         * modules/inet_ntop (Files): Ditto.
46820
46821 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
46822
46823         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
46824         not gl_PREREQ_GETUSERSHELL.
46825
46826 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
46827
46828         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
46829         with only one argument, for Autoconf 2.60.
46830         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
46831         expand to nothing, so add a shell command to avoid syntax error.
46832         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
46833
46834 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
46835
46836         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
46837
46838 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
46839
46840         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
46841         no longer needed.  Check for isblank decl.
46842         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
46843         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
46844         of existence.
46845
46846 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
46847
46848         * lib/getloadavg.c: Use __VMS, not VMS.
46849         * lib/getopt.c: Likewise.
46850         * lib/getpagesize.h: Likewise.
46851         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
46852         and probably does not work.
46853
46854 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
46855
46856         * lib/.cppi-disable: Add wcwidth.
46857         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
46858         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
46859         (ISGRAPH): Remove.  All uses changed to isgraph.
46860         (FOLD) [!defined _LIBC]: Remove special case.
46861         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
46862         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
46863         HAVE_ISBLANK.
46864         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
46865         case.
46866
46867 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
46868
46869         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
46870         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
46871         brackets.  Other minor changes to suppress some compiler
46872         warnings.
46873
46874 2006-07-06  Derek R. Price  <derek@ximbiot.com>
46875         and Paul Eggert  <eggert@cs.ucla.edu>
46876
46877         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
46878         of invoking obsolescent AC_HEADER_DIRENT macro.
46879         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
46880         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
46881         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
46882         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
46883         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
46884         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
46885         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
46886         * m4/readdir.m4: Remove; no longer needed.
46887
46888 2006-07-06  Derek R. Price  <derek@ximbiot.com>
46889         and Paul Eggert  <eggert@cs.ucla.edu>
46890
46891         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
46892         Don't worry about this obsolete case any more.
46893         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
46894         directories.
46895         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
46896         worry about this obsolete case any more.
46897         * lib/fts.c: Likewise.
46898         * lib/getcwd.c: Likewise.
46899         * lib/glob.h: Likewise.
46900         * lib/savedir.c: Likewise.
46901
46902 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
46903
46904         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
46905         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
46906         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
46907         needed.
46908         All uses removed.
46909         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
46910         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
46911         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
46912         needed.
46913         * m4/getdate.m4 (gl_GETDATE): Likewise.
46914         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
46915         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
46916         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
46917         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
46918         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
46919         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
46920         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
46921         needed.
46922
46923 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
46924
46925         * lib/memcasecmp.c: Include <limits.h>.
46926         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
46927         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
46928         Don't assume isdigit succeeds only on '0' through '9'.
46929
46930 2006-07-05  Eric Blake  <ebb9@byu.net>
46931
46932         * modules/getaddrinfo (Depends-on): Add snprintf.
46933
46934 2006-07-05  Eric Blake  <ebb9@byu.net>
46935
46936         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
46937         to avoid 'header present but could not be compiled' on cygwin.
46938
46939 2006-07-05  Eric Blake  <ebb9@byu.net>
46940
46941         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
46942         missing from netdb.h.
46943         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
46944
46945 2006-07-05  Derek R. Price  <derek@ximbiot.com>
46946
46947         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
46948         no longer needed.
46949         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
46950         * m4/getdate.m4 (gl_GETDATE): Likewise.
46951         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
46952         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
46953         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
46954         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
46955         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
46956
46957 2006-07-05  Derek R. Price  <derek@ximbiot.com>
46958
46959         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
46960         All uses of is_space replaced by isspace.
46961         * lib/exit.h: Don't talk about STDC_HEADERS.
46962         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
46963         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
46964         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
46965         replaced by isprint etc.
46966         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
46967         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
46968         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
46969         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
46970         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
46971         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
46972
46973 2006-07-05  Bruno Haible  <bruno@clisp.org>
46974
46975         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
46976         the function exists, before testing against AIX.
46977         Reported by Martin Lambers <marlam@marlam.de>.
46978
46979 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
46980
46981         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
46982         From Mark D. Baushke.
46983
46984 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
46985
46986         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
46987         to the absolute name, not just one, to bypass Sun C 5.8's
46988         "warning: #include of /usr/include/... may be non-portable".
46989
46990 2006-07-04  Eric Blake  <ebb9@byu.net>
46991
46992         * modules/dirname-tests: New test module.
46993         * tests/test-dirname.c: New file, replacing dirname.c
46994         TEST_DIRNAME section that was recently deleted.
46995
46996 2006-07-04  Bruno Haible  <bruno@clisp.org>
46997
46998         Assume ANSI C header files and <ctype.h> functions.
46999         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
47000         (mbsnwidth): Use isprint, iscntrl instead.
47001
47002 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47003
47004         Merge from coreutils.
47005         * MODULES.html.sh: Add xstrtold.
47006         * modules/xstrtold: New file.
47007         * modules/cycle-check (Files): Add lib/same-inode.h.
47008         * modules/dirname (Files): Add m4/double-slash-root.m4.
47009         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
47010         * modules/mkdir-p (Files): Add lib/same-inode.h.
47011         * modules/same (Files): Add lib/same-inode.h.
47012
47013 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47014
47015         * m4/absolute-header.m4: Renamed from full-header-path.m4.
47016         This is to keep the terminology clean; POSIX talks about
47017         "absolute pathnames", not "full pathnames", but the GNU
47018         Coding Standards say to use "path" for something else;
47019         so use "absolute" to keep both sides happy.
47020         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
47021         Set gl_absolute_header, not gl_full_header_path.
47022         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
47023         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
47024         All uses changed.
47025
47026         Merge from coreutils.
47027
47028         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
47029
47030         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
47031         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
47032         want to require the building of c-strtod.o.
47033         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
47034         needs -lm directly.
47035         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
47036
47037         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
47038
47039         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
47040         --as-needed option if available.  Problem reported by Albert Chin in
47041         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
47042         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
47043         cc merely issues a bunch of annoying warnings for --as-needed
47044         (this problem was reported by Bob Proulx).  Also, try linking with
47045         -lm to detect a bug in binutils 2.16 (this problem was reported
47046         by Ralf Wildenhues).
47047
47048         2006-06-18  Jim Meyering  <jim@meyering.net>
47049
47050         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
47051         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
47052         macro.
47053         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
47054         also check for glibc-2.4's abort-inducing bug.
47055
47056         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
47057         Low-probability clean-up should be to use rmdir to get rid of
47058         the just-created directory, not unlink.
47059
47060         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
47061         configure fail, and request a bug report to inform us about it.
47062         Add a comment that, barring reports to the contrary, in 2007 we'll
47063         assume ftruncate is universally available.
47064
47065         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
47066
47067         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
47068
47069         2006-03-12  Jim Meyering  <jim@meyering.net>
47070
47071         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
47072         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
47073         * m4/same.m4 (gl_SAME): Likewise.
47074         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
47075
47076         2006-03-11  Eric Blake  <ebb9@byu.net>
47077
47078         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
47079         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
47080         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
47081         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
47082
47083 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
47084
47085         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
47086         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
47087         reported by Mark D. Baushke, one in
47088         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
47089
47090         Merge from coreutils.
47091
47092         * lib/.cppi-disable: Add stdint_.h.
47093         * lib/.cvsignore: Add stdint.h.
47094
47095         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
47096
47097         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
47098         both double and long double versions.
47099         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
47100         * lib/xstrtold.c: New file.
47101         * lib/xstrtod.h (xstrtold): New decl.
47102
47103         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
47104
47105         * lib/filemode.c (setst): Remove.
47106         (strmode): Rewrite to avoid setst.  This makes the code shorter,
47107         (arguably) clearer, and the generated code is a bit smaller on my
47108         Debian GNU/Linux stable x86 host.
47109
47110         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
47111
47112         * lib/filemode.c: Include "filemode.h" first, to test the interface.
47113         Assume that filemode.h includes sys/types.h and sys/stat.h.
47114         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
47115         (ftypelet): Reorder to put common cases first, for efficiency.
47116         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
47117         to do 'M'.
47118         (strmode): Renamed from mode_string, and now stores 12 bytes instead
47119         of 10, for compatibility with FreeBSD.  All callers changed.
47120         (filemodestring): Now stores 12 bytes instead of 10, and sets file
47121         types that can't be deduced solely from st_mode.  First arg is now a
47122         const pointer.
47123         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
47124         (strmode): Renamed from mode_string.
47125         (filemodestring): New decl.
47126         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
47127         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
47128         needed.
47129         (S_ISPORT, S_ISWHT): New macros, if not already defined.
47130
47131         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
47132
47133         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
47134         fsusage.h now does that.  Include fsusage.h first, to test interface.
47135         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
47136         at most one method (the old code could have generated decls that
47137         didn't conform to C89, not that this was ever exercised).
47138         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
47139
47140         2006-03-19  Jim Meyering  <jim@meyering.net>
47141
47142         Work even in a chroot where d_ino values for entries in "/"
47143         don't match the stat.st_ino values for the same names.
47144         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
47145         number, iterate through all entries again, using lstat instead.
47146         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
47147         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
47148
47149         * lib/getcwd.c (__getcwd): Clarify a comment.
47150         Use memcpy in place of a call to strcpy.
47151
47152         2006-03-12  Jim Meyering  <jim@meyering.net>
47153
47154         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
47155         matches that of the current directory (which we're about to chdir ".."
47156         out of), then save the dev-ino of the parent, instead.
47157
47158         * lib/same-inode.h (SAME_INODE): New file/macro.
47159         * lib/chdir-safer.c (SAME_INODE): Remove definition.
47160         Include "same-inode.h", instead.
47161         * lib/same.c: Likewise.
47162         * lib/cycle-check.h: Include "same-inode.h".
47163         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
47164         * lib/cycle-check.c (SAME_INODE): Remove definition.
47165         * lib/root-dev-ino.h: Include "same-inode.h".
47166
47167         2006-03-11  Eric Blake  <ebb9@byu.net>
47168
47169         * lib/same.c (same_name): s/base_name/last_component/
47170         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
47171         * lib/filenamecat.c (file_name_concat): Likewise.
47172
47173         2006-03-11  Eric Blake  <ebb9@byu.net>,
47174                     Paul Eggert  <eggert@cs.ucla.edu>
47175
47176         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
47177         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
47178         drive prefix.
47179         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
47180         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
47181         (last_component): New method.
47182         * lib/dirname.c (dir_len): Determine when drive letters need a
47183         subsequent slash.  Preserve // when it is special.
47184         (dir_name): Don't append dot when drive letter is absolute.
47185         [TEST_DIRNAME]: Move into a full-blown gnulib test.
47186         * lib/basename.c (base_name): New semantics - malloc the result.
47187         Preserve // when it is special.  Preserve relative files that look
47188         like drive letters.
47189         (base_len): Preserve // when it is special.
47190         (last_component): New method, similar to old base_name semantics.
47191         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
47192         base_name.  Strip redundant slashes from ///.
47193
47194 2006-07-03  Jim Meyering  <jim@meyering.net>
47195
47196         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
47197         macro is used before the first cycle_check call.
47198
47199 2006-07-03  Eric Blake  <ebb9@byu.net>
47200
47201         * modules/dirname (Depends-on): Add xstrndup.
47202
47203 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
47204
47205         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
47206         test cases, so that config.log is a bit easier to follow.
47207
47208 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
47209
47210         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
47211         both are 64 bits, since this seems to be the tradition, and this
47212         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
47213         we ever run into a host that prefers long long to long in this
47214         case, we'll need another configure-time test.  Problem reported by
47215         Jim Meyering.
47216
47217 2006-07-02  Eric Blake  <ebb9@byu.net>
47218
47219         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
47220
47221 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47222
47223         * modules/inttypes (Depends-on): No longer depends on stdint.
47224         * modules/stdint (Description): Say more about assumptions.
47225         Say that the fast types might differ.  Say macros are used.
47226         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
47227         (Makefile.am): Revise list of substituted symbols to match
47228         new stdint.m4.
47229         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
47230         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
47231         * tests/test-stdint.c (verify_same_types)
47232         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
47233         the code conforms to C99/C89.
47234         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
47235         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
47236
47237 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47238
47239         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
47240         but fix a bug, by requiring at least 64 bits.
47241         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
47242         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
47243         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
47244         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
47245
47246         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
47247         changes.  Make 2.59 a prerequisite.  Check and substitute for
47248         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
47249         inttypes.h.  Do not use special include files; just use the
47250         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
47251         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
47252         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
47253         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
47254         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
47255         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
47256         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
47257         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
47258         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
47259         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
47260         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
47261         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
47262         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
47263         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
47264         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
47265         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
47266         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
47267         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
47268         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
47269         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
47270         WINT_MAX.  Check for C99 conformance more strictly, by detecting
47271         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
47272         not check for things that C99 does not require, e.g., int8_t.  If
47273         a test isn't needed unless <stdint.h> isn't working, and is
47274         unlikely to be needed for any other reason, then don't do it
47275         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
47276         size_t, since we assume C89 freestanding at least.  Do not check
47277         for sig_atomic_t, wchar_t, or wint_t, since the code now does
47278         the right thing even if the types are not defined.  Instead use:
47279         (gl_STDINT_TYPE_PROPERTIES): New macro.
47280         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
47281         testing whether <sys/types.h> clashes, as Autoconf does this for
47282         us now.  All uses removed.
47283         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
47284         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
47285         (gl_CHECK_TYPE_SAME):
47286         Remove; no longer needed.
47287         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
47288         exists, since we'll return 0 anyway in that case.
47289         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
47290
47291 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
47292
47293         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
47294         possible collision with system files.
47295         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
47296         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
47297         WCHAR_MIN and WCHAR_MAX in this case.
47298         (<stddef.h>): Do not include; no longer needed.
47299         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
47300         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
47301         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
47302         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
47303         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
47304         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
47305         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
47306         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
47307         !defined(__c99))]: Include in this case too, since it's harmless
47308         now.
47309         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
47310         dangerous to do so.
47311         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
47312         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
47313         (_STDINT_MIN, _STDINT_MAX): New macros.
47314         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
47315         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
47316         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
47317         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
47318         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
47319         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
47320         macros, not typedefs; this simplifies things quite a bit.
47321         Use long int for all types narrower than int64_t.
47322         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
47323         Define in terms of long long int or int64_t or long int,
47324         not int64_t or int32_t.  This saves some compile-time testing.
47325         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
47326         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
47327         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
47328         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
47329         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
47330         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
47331         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
47332         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
47333         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
47334         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
47335         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
47336         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
47337         undef any previous version and define our own version, for
47338         simplicity and consistency with the new macros for types.
47339         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
47340         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
47341         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
47342         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
47343         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
47344         @WINT_T_SUFFIX@ to keep things simple here.
47345         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
47346         Simplify by assuming typical 8/16/32/64 host, since we're
47347         already doing that elsewhere anyway.
47348         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
47349         and assume long long int is 64 bits if available.  This
47350         speeds up 'configure'.
47351
47352 2006-07-01  Eric Blake  <ebb9@byu.net>
47353
47354         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
47355         Reported by Andreas Buening.
47356
47357 2006-07-01  Eric Blake  <ebb9@byu.net>
47358
47359         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
47360
47361 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
47362
47363         * lib/getaddrinfo.c: fixed typo
47364
47365 2006-06-29  Jim Meyering  <jim@meyering.net>
47366
47367         * modules/strftime (Maintainer): Add my name, since with the
47368         FPRINTFTIME changes strftime.c has forked from glibc.
47369
47370 2006-06-29  Eric Blake  <ebb9@byu.net>
47371
47372         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
47373
47374 2006-06-29  Eric Blake  <ebb9@byu.net>
47375
47376         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
47377
47378 2006-06-29  Eric Blake  <ebb9@byu.net>
47379
47380         * lib/stat_.h: New file.
47381
47382 2006-06-29  Eric Blake  <ebb9@byu.net>
47383
47384         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
47385         unused static function.
47386
47387 2006-06-29  Eric Blake  <ebb9@byu.net>
47388
47389         * doc/functions.texi (Function Portability): Document missing lstat
47390         on mingw.
47391
47392 2006-06-29  Eric Blake  <ebb9@byu.net>
47393
47394         * MODULES.html.sh: Add sys_stat.
47395         * modules/sys_stat: New module.
47396         * modules/mkstemp (Depends-on): Add sys_stat.
47397
47398 2006-06-29  Derek R. Price  <derek@ximbiot.com>
47399
47400         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
47401
47402 2006-06-29  Derek R. Price  <derek@ximbiot.com>
47403
47404         * m4/c-bs-a.m4: Removed.
47405
47406 2006-06-29  Derek R. Price  <derek@ximbiot.com>
47407
47408         * lib/strftime.c: Assume strftime() exists.
47409
47410 2006-06-29  Derek Price  <derek@ximbiot.com>
47411
47412         * modules/c-bs-a: Removed - \a is C89.
47413         * MODULES.html.sh: Remove c-bs-a.
47414
47415 2006-06-29  Bruno Haible  <bruno@clisp.org>
47416
47417         * modules/wcwidth (License): Change to LGPL.
47418
47419 2006-06-28  Simon Josefsson  <jas@extundo.com>
47420
47421         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
47422         on _WIN32.
47423
47424         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
47425         getnameinfo.
47426
47427 2006-06-28  Simon Josefsson  <jas@extundo.com>
47428
47429         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
47430
47431 2006-06-28  Simon Josefsson  <jas@extundo.com>
47432
47433         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
47434         functions there.  It will succeed on Windows XP, but on Windows
47435         2000 and (presumably) earlier, it will fail, and use the internal
47436         re-implementation.
47437         (use_win32_p): New function.
47438         (getaddrinfo): Use strtoul on servname, to support numeric ports.
47439         Support AI_NUMERICSERV to disable getservbyname.
47440         (getnameinfo): New function, only supports
47441         NI_NUMERICHOST|NI_NUMERICSERV for now.
47442
47443         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
47444         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
47445         getnameinfo.
47446
47447 2006-06-28  Eric Blake  <ebb9@byu.net>
47448
47449         * modules/wcwidth: New file.
47450         * modules/mbchar (Depends-on): Add wcwidth.
47451         * modules/mbswidth (Depends-on): Add wcwidth.
47452         * MODULES.html.sh: Add wcwidth.
47453
47454 2006-06-28  Eric Blake  <ebb9@byu.net>
47455
47456         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
47457         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
47458
47459 2006-06-28  Eric Blake  <ebb9@byu.net>
47460
47461         * lib/xvasprintf.h: Fix comments.
47462
47463 2006-06-28  Eric Blake  <ebb9@byu.net>
47464
47465         * lib/mbchar.h (wcwidth): Include wcwidth.h.
47466         * lib/mbswidth.c (wcwidth): Move from here...
47467         * lib/wcwidth.h: ...to this new file.
47468
47469 2006-06-28  Derek R. Price  <derek@ximbiot.com>
47470
47471         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
47472
47473         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
47474         it's obsolete.
47475         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
47476
47477 2006-06-28  Derek R. Price  <derek@ximbiot.com>
47478
47479         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
47480         Autoconf 2.60 says this stuff was obsolete.
47481
47482 2006-06-28  Bruno Haible  <bruno@clisp.org>
47483
47484         * modules/wcwidth (Files): Add m4/wchar_t.m4.
47485
47486 2006-06-28  Bruno Haible  <bruno@clisp.org>
47487
47488         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
47489         gt_TYPE_WCHAR_T.
47490
47491 2006-06-28  Bruno Haible  <bruno@clisp.org>
47492
47493         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
47494         declaration for wcwidth.
47495         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
47496
47497 2006-06-28  Bruno Haible  <bruno@clisp.org>
47498
47499         * lib/mkdtemp.c [MINGW]: Include <io.h>.
47500         (mkdir): Define using _mkdir.
47501
47502 2006-06-28  Bruno Haible  <bruno@clisp.org>
47503
47504         * lib/getaddrinfo.h: Fix POSIX URL.
47505         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
47506         _WIN32.
47507         (use_win32_p): Make static.
47508         (getaddrinfo): Reject service name if it is empty or does not consist
47509         solely of decimal digits, or if its value is > 65535.
47510         (getnameinfo): Remove useless casts.
47511
47512 2006-06-27  Simon Josefsson  <jas@extundo.com>
47513
47514         * modules/sys_select: New file, suggested by Bruno Haible, Paul
47515         Eggert and Martin Lambers.
47516
47517 2006-06-27  Simon Josefsson  <jas@extundo.com>
47518
47519         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
47520         Eggert and Martin Lambers.
47521
47522 2006-06-27  Bruno Haible  <bruno@clisp.org>
47523
47524         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
47525         result to 0, not to empty.
47526         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
47527
47528 2006-06-27  Bruno Haible  <bruno@clisp.org>
47529
47530         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
47531
47532 2006-06-26  Simon Josefsson  <jas@extundo.com>
47533
47534         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
47535         present.
47536
47537 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
47538
47539         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
47540         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
47541         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
47542
47543 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
47544
47545         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
47546
47547 2006-06-26  Bruno Haible  <bruno@clisp.org>
47548
47549         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
47550
47551 2006-06-26  Bruno Haible  <bruno@clisp.org>
47552
47553         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
47554
47555 2006-06-26  Bruno Haible  <bruno@clisp.org>
47556
47557         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
47558         SGI C compiler in pre-C99 mode.
47559         Suggested by Mark D. Baushke and Larry Jones.
47560
47561 2006-06-26  Bruno Haible  <bruno@clisp.org>
47562
47563         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
47564         WCHAR_MAX.
47565         Reported by Mark D. Baushke and Larry Jones.
47566
47567 2006-06-26  Bruno Haible  <bruno@clisp.org>
47568
47569         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
47570         in pre-C99 mode.
47571         Suggested by Mark D. Baushke and Larry Jones.
47572
47573 2006-06-23  Simon Josefsson  <jas@extundo.com>
47574             Bruno Haible  <bruno@clisp.org>
47575
47576         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
47577         Emit mostlyclean-local rule.
47578         (func_emit_tests_Makefile_am): Likewise.
47579         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
47580
47581 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
47582
47583         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
47584
47585 2006-06-23  Bruno Haible  <bruno@clisp.org>
47586
47587         * tests/test-stdint.c: Update to match ISO C 99 Technical
47588         Corrigendum 1.
47589
47590 2006-06-23  Bruno Haible  <bruno@clisp.org>
47591
47592         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
47593
47594 2006-06-23  Bruno Haible  <bruno@clisp.org>
47595
47596         * lib/stdint_.h: Treat IRIX like OpenBSD.
47597
47598 2006-06-23  Bruno Haible  <bruno@clisp.org>
47599
47600         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
47601         ISO C 99 Technical Corrigendum 1.
47602
47603 2006-06-22  Simon Josefsson  <jas@extundo.com>
47604
47605         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
47606         MinGW.
47607
47608 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
47609
47610         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
47611         needed.  Some compiler complained about some of them.  Problem reported
47612         by Larry Jones in
47613         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
47614
47615 2006-06-21  Simon Josefsson  <jas@extundo.com>
47616
47617         * tests/test-getaddrinfo.c: New file.
47618
47619         * modules/getaddrinfo-tests: New file.
47620
47621         * MODULES.html.sh: Add inet_pton.
47622
47623         * modules/inet_pton: New file.
47624
47625 2006-06-21  Simon Josefsson  <jas@extundo.com>
47626
47627         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
47628         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
47629         of using the (limited) gnulib implementation on Windows XP.
47630
47631         * m4/inet_pton.m4: New file.
47632
47633 2006-06-21  Simon Josefsson  <jas@extundo.com>
47634
47635         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
47636         variable.
47637
47638         * lib/socket_.h: Don't define WINVER.
47639
47640         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
47641         slightly modified to work in gnulib.
47642
47643 2006-06-21  Simon Josefsson  <jas@extundo.com>
47644
47645         * doc/gnulib.texi (Windows sockets): Add.
47646
47647 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
47648
47649         * lib/read-file.c (fread_file): Start with buffer allocation of
47650         0 bytes rather than 1 byte; this simplifies the code.
47651         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
47652         code to free buffer and save/restore errno.
47653         (internal_read_file): Remove unused local.
47654
47655 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
47656
47657         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
47658         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
47659         Problem reported by Denis Excoffier in
47660         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
47661
47662 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
47663
47664         * modules/sys_socket, modules/socklen: Include sys/types since
47665         FreeBSD 4.x's sys/socket.h needs it.
47666
47667 2006-06-19  Simon Josefsson  <jas@extundo.com>
47668
47669         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
47670
47671 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
47672
47673         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
47674
47675 2006-06-19  Bruno Haible  <bruno@clisp.org>
47676
47677         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
47678         and FULL_PATH_INTTYPES_H in angle brackets.
47679         Reported by Mark D. Baushke <mdb@gnu.org>.
47680
47681 2006-06-17  Eric Blake  <ebb9@byu.net>
47682
47683         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
47684         errno.
47685
47686 2006-06-17  Bruno Haible  <bruno@clisp.org>
47687
47688         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
47689         <sys/inttypes.h>.
47690
47691 2006-06-17  Bruno Haible  <bruno@clisp.org>
47692
47693         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
47694         whether errno is declared. Assume <errno.h> declares errno.
47695
47696 2006-06-17  Bruno Haible  <bruno@clisp.org>
47697
47698         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
47699
47700 2006-06-17  Bruno Haible  <bruno@clisp.org>
47701
47702         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
47703         problem on Solaris 2.5.1.
47704
47705 2006-06-16  Eric Blake  <ebb9@byu.net>
47706
47707         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
47708         * lib/unicodeio.c [!defined errno]: Likewise.
47709         * lib/strtol.c [!defined errno]: Likewise.
47710         * lib/strtod.c [!defined errno]: Likewise.
47711
47712 2006-06-15  Eric Blake  <ebb9@byu.net>
47713
47714         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
47715
47716 2006-06-15  Eric Blake  <ebb9@byu.net>
47717
47718         * config/srclist.txt (ssize_t.m4): Lose sync.
47719
47720 2006-06-15  Bruno Haible  <bruno@clisp.org>
47721
47722         * modules/stdint (Files): Include m4/full-header-path.m4,
47723         m4/size_max.m4, m4/wchar_t.m4.
47724         (Makefile.am): Many more substitutions.
47725         * modules/stdint-tests: New file.
47726         * tests/test-stdint.c: New file.
47727
47728 2006-06-15  Bruno Haible  <bruno@clisp.org>
47729
47730         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
47731         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
47732         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
47733         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
47734         gl_CHECK_TYPE_SAME): New macros.
47735
47736 2006-06-15  Bruno Haible  <bruno@clisp.org>
47737
47738         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
47739
47740 2006-06-15  Bruno Haible  <bruno@clisp.org>
47741
47742         * lib/stdint_.h: Rewritten to be fully auto-configured.
47743         Fixes bug on HP-UX/IA64.
47744
47745 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
47746
47747         * lib/getdate.y (__attribute__): Don't define if already defined.
47748         Problem reported by Larry Jones.
47749         * lib/utimens.c (__attribute__): Likewise.
47750
47751 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
47752
47753         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
47754         reported by Andreas Schwab.
47755
47756 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
47757             Bruno Haible  <bruno@clisp.org>
47758
47759         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
47760         check for the declaration of strnlen and a run test that exposes the
47761         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
47762         rpl_strndup.
47763
47764 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
47765             Bruno Haible  <bruno@clisp.org>
47766
47767         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
47768
47769 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
47770
47771         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
47772         compile test, for Tru64 4.0D.
47773
47774 2006-05-28  Karl Berry  <karl@gnu.org>
47775
47776         * config/srclist.txt (printf-args.c): lose sync.
47777
47778 2006-05-26  Martin Lambers  <marlam@marlam.de>
47779
47780         * lib/getpass.c: Updates the test for the native W32 API, and adds
47781         missing includes, thus fixing compilation warnings.
47782
47783 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
47784
47785         * lib/exclude.c (exclude_fnmatch): New function.
47786         (excluded_file_name): Call exclude_fnmatch.
47787         * lib/exclude.h (excluded_file_name): New prototype
47788
47789 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
47790
47791         * lib/tempname.c (small_open, large_open): New macros.
47792         (__open, __open64) [!_LIBC]: Remove.
47793         (__gen_tempname): Use small_open and large_open instead of __open
47794         and __open64.  This fixes a portability bug on HP-UX 11.11i
47795         reported by Simon Wing-Tang in
47796         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
47797
47798 2006-05-24  Bruno Haible  <bruno@clisp.org>
47799
47800         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
47801         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
47802         Reported by Thorsten Maerz <torte@netztorte.de> via
47803         Aaron Stone <aaron@serendipity.cx>.
47804
47805 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
47806
47807         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
47808         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
47809         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
47810         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
47811         not really conditional on the cache.
47812         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
47813
47814 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
47815
47816         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
47817         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
47818         (my_usleep): Don't mishandle maximum value.
47819
47820 2006-05-19  Jim Meyering  <jim@meyering.net>
47821
47822         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
47823
47824 2006-05-17  Bruno Haible  <bruno@clisp.org>
47825
47826         Cygwin portability.
47827         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
47828
47829 2006-05-17  Bruno Haible  <bruno@clisp.org>
47830
47831         * lib/stdint_.h: Fix recognition of Cygwin.
47832
47833 2006-05-15  Bruno Haible  <bruno@clisp.org>
47834
47835         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
47836         on libtool patch by Ralf Wildenhues.
47837
47838 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
47839
47840         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
47841         test for C99 conformance; (bool) 0.5 is an integer constant
47842         expression, but (bool) -0.5 is not.  Problem reported by Fedor
47843         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
47844
47845 2006-05-11  Simon Josefsson  <jas@extundo.com>
47846
47847         * m4/xvasprintf.m4: Fix obvious typo.
47848
47849 2006-05-11  Jim Meyering  <jim@meyering.net>
47850
47851         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
47852         James Lemley.
47853
47854 2006-05-10  Simon Josefsson  <jas@extundo.com>
47855
47856         * lib/md4.c: Typo fix, update copyright years.
47857         (K1, K2): Don't use L because it turn computations into 64-bit on
47858         64-bit platforms.
47859
47860 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
47861
47862         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
47863         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
47864         unwanted sign propagation, e.g., on hosts with 64-bit int.
47865         There still are some problems with reeelly weird theoretical hosts
47866         (e.g., 33-bit int) but it's not worth worrying about now.
47867         * lib/sha1.c (rol): Likewise.
47868         (K1, K2, K3, K4): Remove unnecessary L suffix.
47869
47870 2006-05-10  Bruno Haible  <bruno@clisp.org>
47871
47872         * lib/des.c: Cast to avoid warnings.
47873
47874 2006-05-09  Bruno Haible  <bruno@clisp.org>
47875
47876         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
47877         (Depends-on): Depend also on xsize, stdarg.
47878         (configure.ac): Add gl_XVASPRINTF.
47879
47880 2006-05-09  Bruno Haible  <bruno@clisp.org>
47881
47882         * m4/xvasprintf.m4: New file.
47883
47884 2006-05-09  Bruno Haible  <bruno@clisp.org>
47885
47886         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
47887         (EOVERFLOW): Define fallback value.
47888         (xstrcat): New function.
47889         (xvasprintf): Recognize the special case of a string concatenation.
47890
47891 2006-05-08  Eric Blake  <ebb9@byu.net>
47892
47893         * gnulib-tool (func_version): Base copyright year on CVS date.
47894         (func_emit_copyright_notice): New function.
47895         (func_emit_lib_Makefile_am): Use it.
47896         (func_emit_tests_Makefile_am): Likewise.
47897         (func_import): Likewise.
47898
47899 2006-05-08  Bruno Haible  <bruno@clisp.org>
47900
47901         * modules/stdarg: New file.
47902         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
47903
47904 2006-05-08  Bruno Haible  <bruno@clisp.org>
47905
47906         * m4/stdarg.m4: New file, from GNU gettext.
47907
47908 2006-05-08  Bruno Haible  <bruno@clisp.org>
47909
47910         * config/srclist.txt (build-aux/config.rpath): different from latest
47911         release.
47912
47913 2006-05-08  Bruno Haible  <bruno@clisp.org>
47914
47915         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
47916
47917 2006-05-05  Jim Meyering  <jim@meyering.net>
47918
47919         * m4/warning.m4: New file, derived from bison's file by the same name.
47920
47921 2006-05-03  Bruno Haible  <bruno@clisp.org>
47922
47923         * lib/stdint_.h: Shorter URL.
47924         * lib/inttypes.h: Likewise.
47925
47926 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
47927
47928         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
47929
47930 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
47931
47932         * lib/verify.h: Document the internals better.  Most of this change
47933         was written by Bruno Haible.
47934
47935 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
47936
47937         * doc/verify.texi: New file, partly based on a proposal by
47938         Bruno Haible.
47939
47940 2006-05-02  Bruno Haible  <bruno@clisp.org>
47941
47942         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
47943         test from here...
47944         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
47945
47946 2006-04-29  Bruno Haible  <bruno@clisp.org>
47947
47948         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
47949         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
47950
47951 2006-04-29  Bruno Haible  <bruno@clisp.org>
47952
47953         * gnulib-tool: Make --update option actually work.
47954
47955 2006-04-29  Bruno Haible  <bruno@clisp.org>
47956
47957         * doc/gcd.texi: New file.
47958         * doc/gnulib.texi: Include it.
47959
47960 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
47961
47962         * lib/getdate.y (get_date): When adding relative date, start with the
47963         initial time, not with the result of the first mktime call.
47964
47965 2006-04-25  Bruno Haible  <bruno@clisp.org>
47966
47967         * gnulib-tool (func_import): Output the include directives in three
47968         blocks, sorted separately.
47969         Reported by Ben Pfaff <blp@cs.stanford.edu>.
47970
47971 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
47972
47973         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
47974         to define main with arguments, for C++.  Reported by Eric Blake.
47975         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
47976         Prefer 'int main ()' to 'int main (void)', for C++.
47977         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
47978         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
47979         for 'main', for C99 and C++.
47980
47981 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
47982
47983         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
47984         Don't assume that exit status -1 is valid.
47985         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
47986         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
47987         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
47988         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
47989         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
47990         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
47991         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
47992         functions can be used without declaring them, or that you can
47993         exit with status -1.
47994         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
47995
47996 2006-04-24  Karl Berry  <karl@gnu.org>
47997
47998         * config/srclist.txt (longdouble.m4): sync lost.
47999
48000 2006-04-24  Eric Blake  <ebb9@byu.net>
48001
48002         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
48003
48004 2006-04-24  Bruno Haible  <bruno@clisp.org>
48005
48006         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
48007         poll() implementation in AIX.
48008         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
48009
48010 2006-04-24  Bruno Haible  <bruno@clisp.org>
48011
48012         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
48013         assigned exactly once.
48014
48015 2006-04-23  Claudio Fontana  <claudio@gnu.org>
48016             Bruno Haible  <bruno@clisp.org>
48017
48018         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
48019         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
48020         for AM_CPPFLAGS.
48021
48022 2006-04-23  Bruno Haible  <bruno@clisp.org>
48023
48024         * modules/copy-file: Depend on unistd.
48025         * modules/execute: Likewise.
48026         * modules/fatal-signal: Likewise.
48027         * modules/findprog: Likewise.
48028         * modules/mkdtemp : Likewise.
48029         * modules/pipe: Likewise.
48030         * modules/wait-process: Likewise.
48031
48032 2006-04-23  Bruno Haible  <bruno@clisp.org>
48033
48034         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
48035         condition was already detected.
48036         Reported by Ben Pfaff <blp@cs.stanford.edu>.
48037
48038 2006-04-23  Bruno Haible  <bruno@clisp.org>
48039
48040         * lib/copy-file.c: Include <unistd.h> unconditionally.
48041         * lib/execute.c: Likewise.
48042         * lib/fatal-signal.c: Likewise.
48043         * lib/findprog.c: Likewise.
48044         * lib/mkdtemp.c: Likewise.
48045         * lib/pipe.h: Likewise.
48046         * lib/pipe.c: Likewise.
48047         * lib/wait-process.h: Likewise.
48048
48049 2006-04-23  Bruno Haible  <bruno@clisp.org>
48050
48051         * gnulib-tool (func_usage): Fix --import description. Document
48052         --update.
48053         (func_import): Create temporary file in a temporary directory, if
48054         --dry-run is specified. Silence errors from 'grep' when there are no
48055         m4 files in $m4dir.
48056         (func_create_testdir): Silence errors from 'grep' when there are no
48057         m4 files in $m4dir.
48058         Reported by Karl Berry <karl@freefriends.org>.
48059
48060 2006-04-20  Bruno Haible  <bruno@clisp.org>
48061
48062         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
48063         one argument, so that the code will be portable to Autoconf 2.60.
48064         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
48065         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
48066         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
48067
48068 2006-04-19  Derek Price  <derek@ximbiot.com>
48069             Eric Blake  <ebb9@byu.net>
48070
48071         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
48072         rather than "/full/path.h".  Update comment to match.  Shorten &
48073         generalize m4_translit call via AS_TR_CPP.
48074
48075 2006-04-19  Derek Price  <derek@ximbiot.com>
48076             Eric Blake  <ebb9@byu.net>
48077
48078         * lib/inttypes.h: Correct grammar in comment.
48079
48080 2006-04-18  Derek Price  <derek@ximbiot.com>
48081             Paul Eggert  <eggert@cs.ucla.edu>
48082
48083         * modules/inttypes: New file.
48084         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
48085
48086 2006-04-18  Derek Price  <derek@ximbiot.com>
48087             Paul Eggert  <eggert@cs.ucla.edu>
48088
48089         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
48090         New files.
48091
48092 2006-04-18  Derek Price  <derek@ximbiot.com>
48093             Paul Eggert  <eggert@cs.ucla.edu>
48094
48095         * lib/inttypes.h: New file.
48096         * lib/strtoimax.c: Assume <inttypes.h>.
48097
48098 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
48099
48100         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
48101         isn't mounted.  Problem reported by Kir Kolyshkin.
48102
48103 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
48104
48105         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
48106         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
48107         Derek R. Price.
48108         * lib/regex.h (RE_DUP_MAX): Update comment to match current
48109         implementation.
48110
48111 2006-04-12  Eric Blake  <ebb9@byu.net>
48112
48113         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
48114         is now done automatically by the corresponding Autoconf macro.
48115
48116 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
48117
48118         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
48119         time_r.h.
48120
48121 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
48122
48123         Merge regex changes from libc, removing some of our
48124         POSIX-conformance changes that were rejected and redoing them in a
48125         less-intrusive way.
48126
48127         * lib/regcomp.c (re_compile_internal, init_dfa):
48128         Length arg is now size_t, not Idx.  All uses changed.
48129         (peek_token): Forward decl now says internal_function.
48130         (__re_error_msgid, __re_error_msgid_idx):
48131         Now static rather than extern with attribute_hidden.
48132         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
48133         For some reason libc prefers K&R style defns for external functions.
48134         (regerror) [!defined _LIBC]: Likewise.
48135         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
48136         (seek_collating_symbol_entry, lookup_collation_sequence_value):
48137         (build_range_exp, build_collating_symbol):
48138         Use K&R-style defn.
48139         (re_compile_fastmap): Use '\0' to memset, not 0.
48140         (utf8_sb_map): Make the calculations more obvious.
48141         (init_dfa, parse_bracket_exp, build_charclass_op):
48142         Call calloc and cast result, as glibc does.
48143         (init_word_char, fetch_token, peek_token, peek_token_bracket):
48144         (build_range_exp, build_collating_symbol):
48145         Now internal functions.
48146
48147         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
48148
48149         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
48150         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
48151         Don't depend on VMS; depend on __VMS instead, for POSIX
48152         namespace cleanness.
48153         (regoff_t): Define to ssize_t, not long int.
48154
48155         Remove the REG_ macros named below.  Instead, make the old names
48156         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
48157         __USE_GNU_REGEX.
48158         (REG_BACKSLASH_ESCAPE_IN_LISTS):
48159         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
48160         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
48161         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
48162         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
48163         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
48164         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
48165         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
48166         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
48167         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
48168         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
48169         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
48170         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
48171         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
48172         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
48173         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
48174         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
48175         (REG_NREGS):
48176         Remove.  All uses replaced by the old RE_* names.
48177         (RE_BACKSLASH_ESCAPE_IN_LISTS):
48178         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
48179         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
48180         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
48181         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
48182         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
48183         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
48184         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
48185         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
48186         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
48187         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
48188         Don't bother having these macros be independent of each others'
48189         values, since they no longer exist in the POSIX name space.
48190
48191         Rename the following member names back to their old names,
48192         unless !__USE_GNU_REGEX.  All uses changed back.
48193         (buffer): Renamed from re_buffer.
48194         (allocated): Renamed from re_allocated.
48195         (used): Renamed from re_used.
48196         (syntax): Renamed from re_syntax.
48197         (fastmap): Renamed from re_fastmap.
48198         (translate): Renamed from re_translate.
48199         (can_be_null): Renamed from re_can_be_null.
48200         (regs_allocated): Renamed from re_regs_allocated.
48201         (fastmap_accurate): Renamed from re_fastmap_accurate.
48202         (no_sub): Renamed from re_no_sub.
48203         (not_bol): Renamed from re_not_bol.
48204         (not_eol): Renamed from re_not_eol.
48205         (newline_anchor): Renamed from re_newline_anchor.
48206         (num_regs): Renamed from rm_num_regs.
48207         (start): Renamed from rm_start.
48208         (end): Renamed from rm_end.
48209
48210         (free_state): Move up a bit.
48211
48212         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
48213         #define to be empty.
48214         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
48215         when that is what is intended.
48216         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
48217         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
48218         (MAX): New macro.
48219         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
48220         All uses changed back to re_malloc, etc.  It's now the caller's
48221         responsibility to check for overflow; all callers changed.
48222         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
48223         (re_x2nrealloc): Remove.
48224         (free_state): Remove decl.
48225
48226         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
48227         (re_set_registers, re_exec):
48228         Use K&R-style defn.
48229
48230         2006-01-31  Roland McGrath  <roland@redhat.com>
48231
48232         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
48233         Reported by Mike Frysinger <vapier@gentoo.org>.
48234
48235         2006-01-15  Andreas Jaeger  <aj@suse.de>
48236
48237         [BZ #1950]
48238         * lib/regex_internal.c (re_string_reconstruct): Adjust for
48239         build_wcs_upper_buffer change.
48240         (build_wcs_upper_buffer): Change return type.
48241
48242         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
48243
48244         * lib/regex_internal.h: Include <stdint.h> if available.
48245
48246         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
48247
48248         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
48249
48250         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
48251
48252         * lib/regcomp.c: Adjust for changed secondary hash function.
48253
48254         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
48255
48256         * lib/regex.h: Pretty printing.
48257         Clean up namespace a bit.
48258
48259         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
48260
48261         * lib/regexec.c (update_cur_sifted_state, check_arrival,
48262         check_arrival_add_next_nodes): Avoid using uninitialized variable.
48263
48264         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
48265                     Ulrich Drepper  <drepper@redhat.com>
48266
48267         [BZ #1302]
48268         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
48269         changed.
48270         (bitset_word_t): Renamed from bitset_word.  All uses changed.
48271
48272         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
48273
48274         [BZ #281]
48275         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
48276         * lib/regcomp.c: Remove unnecessary uses of
48277         unsigned RE_TRANSLATE_TYPE.
48278         * lib/regex_internal.h: Likewise.
48279         * lib/regex_internal.c: Likewise.
48280         * lib/regexec.c: Likewise.
48281         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
48282
48283         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
48284
48285         * lib/regexec.c (find_recover_state): Remove unnecessary
48286         initialization.
48287         (transit_state_bkref): Make DFA a const pointer.
48288         (get_subexp): Likewise.
48289         (check_arrival): Likewise.
48290         (update_cur_sifted_state): Likewise.
48291         (re_search_internal): Likewise.
48292         (prune_impossible_nodes): Likewise.
48293         (acquire_init_state_context): Likewise.
48294         (proceed_next_node): Likewise.
48295         (set_regs): Likewise.
48296         (free_fail_stack_return): Likewise.
48297         (check_arrival_expand_ecl): Mark DFA parameter as const.
48298         (check_arrival_expand_ecl_sub): Likewise.
48299         (check_subexp_limits): Likewise.
48300         (sub_epsilon_src_nodes):  Likewise.
48301         (add_epsilon_src_nodes):  Likewise.
48302         (merge_state_array): Likewise.
48303         (update_regs): Likewise.
48304         (build_trtable): Likewise.
48305         (sift_states_backward): Mark MCTX parameter as const.
48306         (build_sifted_states): Likewise.
48307         (update_cur_sifted_state): Likewise.
48308         (sift_states_mkref): Likewise.
48309         (check_arrival_expand_ecl): Mark eclosure as const.
48310         (check_dst_limits_calc_pos_1): Likewise.
48311         * lib/regex_internal.h (re_match_context_t): Make dfa a const
48312         pointer.
48313
48314         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
48315
48316         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
48317         (transit_state_sb): Likewise.
48318         (transit_state_mb): Likewise.
48319         (sift_states_iter_mb): Likewise.
48320         (check_arrival_add_next_nodes): Likewise.
48321         (check_node_accept_bytes): Change first parameter to pointer-to-const.
48322         [_LIBC] (re_search_2_stub): Use mempcpy.
48323
48324         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
48325         mbrtowc for very simple UTF-8 case.
48326
48327         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
48328         a pointer-to-const.
48329         (re_acquire_state_context): Likewise.
48330         * lib/regex_internal.h: Adjust prototypes.
48331
48332         * lib/regex.c: Prevent using C++ compilers.
48333
48334         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
48335         (re_acquire_state_context): Likewise.
48336
48337 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
48338
48339         * modules/regex (Depends-on): Add ssize_t.
48340
48341 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
48342
48343         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
48344         translation table.
48345
48346 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
48347
48348         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
48349
48350 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
48351             Bruno Haible  <bruno@clisp.org>
48352
48353         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
48354         <sys/types.h> and <inttypes.h>.
48355
48356 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
48357
48358         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
48359         `__error_t_defined', so argp.h will not typedef the former.
48360
48361 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
48362
48363         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
48364         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
48365         glibc names.  Even if glibc is changed to conform to POSIX, the
48366         traditional names will be available anyway, since regex depends on
48367         the extensions module.  Also, fix a longstanding typo in the
48368         implementation of Spencer ERE test #75 from grep 2.3.  Problems
48369         reported by Emanuele Giaquinta.  Also, change sense of cached
48370         variable, so that the message makes sense.
48371
48372 2006-03-24  Simon Josefsson  <jas@extundo.com>
48373
48374         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
48375         including some doc fixes.
48376         (base64_encode_alloc): Fix +1 bug on allocation failures.
48377
48378 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
48379
48380         * lib/base64.c (base64_encode): Do not read past end of array with
48381         unsanitized input on systems with CHAR_BIT > 8.
48382
48383 2006-03-24  Eric Blake  <ebb9@byu.net>
48384
48385         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
48386
48387 2006-03-22  Karl Berry  <karl@gnu.org>
48388
48389         * config/srclist.txt (*setenv.[ch]): get from coreutils.
48390         * config/srclistvars.sh (COREUTILS): new var.
48391
48392 2006-03-17  Jim Meyering  <jim@meyering.net>
48393
48394         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
48395         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
48396
48397 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
48398
48399         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
48400         no longer needs it.  Instead, check that regoff_t is as least
48401         as wide as ptrdiff_t.
48402
48403         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
48404         so that our regex.h stays compatible with the installed regex.
48405         This is helpful for installers who configure --without-included-regex.
48406         Problem reported by Emanuele Giaquinta.
48407
48408 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
48409
48410         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
48411         Typedef to long int, not to off_, as POSIX will likely change
48412         in that direction.
48413
48414 2006-03-15  Eric Blake  <ebb9@byu.net>
48415
48416         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
48417
48418 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
48419
48420         * lib/argp-help.c (validate_uparams): Fix typo
48421         * lib/argp-parse.c (argp_default_options): Consistently begin help
48422         messages with a lowercase letter.
48423
48424 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
48425
48426         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
48427         overrun buffers and shouldn't be used (much as gets shouldn't be
48428         used).
48429         * lib/time_r.c (asctime_r, ctime_r): Likewise.
48430
48431 2006-03-08  Simon Josefsson  <jas@extundo.com>
48432
48433         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
48434         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
48435
48436 2006-03-08  Simon Josefsson  <jas@extundo.com>
48437
48438         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
48439         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
48440
48441 2006-03-08  Simon Josefsson  <jas@extundo.com>
48442
48443         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
48444         signal that configure disabled the device.
48445
48446 2006-03-08  Simon Josefsson  <jas@extundo.com>
48447
48448         * build-aux/maint.mk: Fix refresh-po, to handle no translated
48449         languages.
48450
48451 2006-03-07  Simon Josefsson  <jas@extundo.com>
48452
48453         * modules/getopt (Depends-on): Add unistd.
48454
48455         * modules/unistd: New file.
48456
48457 2006-03-07  Simon Josefsson  <jas@extundo.com>
48458
48459         * modules/gc-random: New file.
48460
48461 2006-03-07  Simon Josefsson  <jas@extundo.com>
48462
48463         * m4/unistd_h.m4: New file.
48464
48465 2006-03-07  Simon Josefsson  <jas@extundo.com>
48466
48467         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
48468         test to be side-effect free by storing the result in the cache
48469         variable gl_cv_lib_readline, and moving the assignment of
48470         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
48471         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
48472
48473 2006-03-07  Simon Josefsson  <jas@extundo.com>
48474
48475         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
48476         error on missing devices (the functions will return an error).
48477
48478         * m4/gc.m4: Move random stuff to gc-random.m4
48479
48480 2006-03-07  Simon Josefsson  <jas@extundo.com>
48481
48482         * lib/unistd_.h: New file.
48483
48484 2006-03-07  Simon Josefsson  <jas@extundo.com>
48485
48486         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
48487
48488 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
48489
48490         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
48491         Problem reported by Juan Manuel Guerrero.
48492
48493 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
48494
48495         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
48496         the unistd module.
48497         * lib/getlogin_r.c: Likewise.
48498         * lib/getlogin_r.h: Likewise.
48499         * lib/glob.c: Likewise.
48500         * lib/pagealign_alloc.c: Likewise.
48501         * lib/unistd_.h: Remove; no longer needed.
48502
48503 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
48504
48505         * MODULES.html.sh (Support for systems lacking POSIX:2001):
48506         Add unistd.
48507         * modules/c-stack (Depends-on): Add unistd.
48508         * modules/getlogin_r: Likewise.
48509         * modules/glob: Likewise.
48510         * modules/pagealign_alloc: Likewise.
48511         * modules/unistd (Files): Remove lib/unistd_.h.
48512         (EXTRA_DIST): Remove.
48513         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
48514         need unistd_.h.
48515         (MOSTLYCLEANFILES): Remove unistd.h-t.
48516
48517 2006-03-03  Simon Josefsson  <jas@extundo.com>
48518
48519         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
48520
48521 2006-03-03  Simon Josefsson  <jas@extundo.com>
48522
48523         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
48524         libidn and bison.
48525
48526 2006-03-03  Simon Josefsson  <jas@extundo.com>
48527
48528         * build-aux/maint.mk: Add indent target.
48529
48530 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
48531
48532         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
48533         our replacement poll.h in any case, to avoid a differing
48534         declaration from a system header.  Seen on AIX.
48535
48536 2006-03-01  Simon Josefsson  <jas@extundo.com>
48537
48538         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
48539         <kasal@ucw.cz>.
48540
48541 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
48542
48543         * modules/gettime (Depends-on): Add extensions module.
48544         * modules/nanosleep (Depends-on): Likewise.
48545         * modules/settime (Depends-on): Likewise.
48546
48547 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
48548
48549         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
48550         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
48551         pedantically.
48552         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
48553         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
48554
48555         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
48556         not "==".  Reported by Ralf Wildenhues.
48557
48558 2006-03-01  Karl Berry  <karl@gnu.org>
48559
48560         * doc/Copyright/request-*: new files, synced from gnuorg.
48561
48562 2006-03-01  Karl Berry  <karl@gnu.org>
48563
48564         * config/srclist.txt (Copyright/*): new entries.
48565
48566 2006-02-28  Simon Josefsson  <jas@extundo.com>
48567
48568         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
48569
48570 2006-02-27  Simon Josefsson  <jas@extundo.com>
48571
48572         * lib/base64.h: Indent #define's.  From Jim Meyering
48573         <jim@meyering.net>.
48574
48575 2006-02-27  Jim Meyering  <jim@meyering.net>
48576
48577         Revert the change of 2006-02-24, so these files can continue
48578         to be sync'd from gettext.
48579         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
48580         of `config.h'.
48581
48582 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
48583
48584         * modules/intprops: New file.
48585         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
48586         Add intprops.
48587         * modules/getloadavg (Files): Remove lib/intprops.h.
48588         (Depends-on): Add intprops.
48589         * modules/human: Likewise.
48590         * modules/inttostr: Likewise.
48591         * modules/openat: Likewise.
48592         * modules/sig2str: Likewise.
48593         * modules/userspec: Likewise.
48594         * modules/utimecmp: Likewise.
48595         * modules/xnanosleep: Likewise.
48596         * modules/xstrtol: Likewise.
48597
48598 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
48599
48600         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
48601         * modules/lock-tests (TESTS): Use $(EXEEXT).
48602         * modules/tls-tests: Likewise.
48603         * modules/argp-tests: Likewise.
48604         (check_PROGRAMS): New var, replacing...
48605         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
48606
48607 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
48608
48609         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
48610         `config.h'.
48611
48612 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
48613
48614         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
48615
48616 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
48617
48618         Sync from coreutils.
48619         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
48620         gl_CHDIR_SAFER.
48621
48622 2006-02-22  Jim Meyering  <jim@meyering.net>
48623
48624         Sync from coreutils.
48625         * m4/chdir-safer.m4: New file.
48626
48627 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
48628
48629         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
48630         AT_FDCWD exceeds INT_MAX.
48631         * lib/openat.h (AT_FDCWD): Likewise.
48632
48633 2006-02-17  Eric Blake  <address@hidden>
48634
48635         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
48636
48637 2006-02-16  Simon Josefsson  <jas@extundo.com>
48638
48639         * modules/getaddrinfo (Depends-on): Add sys_socket.
48640
48641 2006-02-15  Simon Josefsson  <jas@extundo.com>
48642
48643         * build-aux/maint.mk: Add dsyntax-check rule.
48644
48645 2006-02-15  Eric Blake  <ebb9@byu.net>
48646
48647         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
48648         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
48649         'present but cannot compile' warnings on cygwin.
48650         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
48651         use ws2tcpip.h if sys/socket.h works.
48652         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
48653         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
48654
48655 2006-02-14  Simon Josefsson  <jas@extundo.com>
48656
48657         * modules/maintainer-makefile (Files): Rename.
48658
48659         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
48660         and (the local) Makefile.cfg to maint-cfg.mk.
48661
48662         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
48663         to the latter.
48664
48665         * modules/maintainer-makefile: New module.
48666
48667         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
48668         severaly stripped to make it possible to build it up from scratch
48669         with reliable tests.
48670
48671         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
48672         fixes to permit overriding the default actions when configure and
48673         makefile are not available.
48674
48675 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
48676
48677         Sync from coreutils.
48678         * modules/lstat (Depends-on): Don't depend on xalloc.
48679         (License): Change from GPL to LGPL, since this is now simply a
48680         replacement for a libc function.
48681
48682 2006-02-14  Jim Meyering  <jim@meyering.net>
48683
48684         Sync from coreutils.
48685
48686         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
48687         failure on deficient systems, and simplify gnulib lgpl dependencies.
48688         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
48689         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
48690
48691         * lib/xalloc-die.c: Remove unused definition of N_.
48692
48693 2006-02-14  Jim Meyering  <jim@meyering.net>
48694
48695         Sync from coreutils.
48696         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
48697         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
48698         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
48699         double-quote uses of that variable, to accommodate the rare case in
48700         which getmntent is available in none of the libraries checked.  This
48701         happens at least on FreeBSD 5.0.
48702
48703 2006-02-13  Simon Josefsson  <jas@extundo.com>
48704
48705         * gnulib-tool (Usage): Fix --import, from
48706         karl@freefriends.org (Karl Berry).
48707
48708 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
48709
48710         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
48711
48712 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
48713
48714         * lib/argp-namefrob.h: Restore changes accidentally lost during the
48715         "autoupdate" on 2005-12-12.
48716
48717 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
48718
48719         * modules/closeout (Depends-on): Remove atexit.
48720
48721 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
48722
48723         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
48724         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
48725
48726 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
48727
48728         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
48729         __EXTENSIONS__ if this causes compilation to fail.  Problem
48730         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
48731         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
48732
48733 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
48734
48735         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
48736         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
48737         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
48738         All uses changed.
48739
48740 2006-01-26  Simon Josefsson  <jas@extundo.com>
48741
48742         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
48743         prototype is visible on mingw32.
48744
48745         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
48746         for mingw32.
48747
48748         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
48749         mingw32).
48750
48751 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
48752
48753         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
48754         attempt to open for write; this always fails, at least on POSIX
48755         hosts.  This reinstates the 2006-01-09 change, which was
48756         inadvertently removed.
48757
48758 2006-01-26  Bruno Haible  <bruno@clisp.org>
48759
48760         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
48761         Reported by Paul Eggert.
48762
48763 2006-01-26  Bruno Haible  <bruno@clisp.org>
48764             Paul Eggert  <eggert@cs.ucla.edu>
48765
48766         * lib/stdbool_.h (_Bool)
48767         [(! (defined __cplusplus || defined __BEOS__)
48768           && !defined __GNUC__
48769           && !(defined __HP_cc || defined __xlc__
48770                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
48771                || defined __sgi))]:
48772         #define to signed char in these cases too; this simplifies
48773         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
48774         etc., separately) and makes it more conservative.
48775
48776 2006-01-25  Simon Josefsson  <jas@extundo.com>
48777
48778         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
48779         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
48780         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
48781
48782 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
48783
48784         * lib/argp-namefrob.h: Bugfix. Remove stray #
48785
48786 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
48787
48788         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
48789         so that we test the test.
48790         Check for yet another HP-UX cc bug involving *bool |= bool.
48791
48792 2006-01-25  Karl Berry  <karl@gnu.org>
48793
48794         * config/srclist.txt (vasnprintf.c): sync lost.
48795
48796 2006-01-25  Jim Meyering  <jim@meyering.net>
48797
48798         Sync from the stable (b5) branch of coreutils:
48799
48800         * lib/fts.c (fts_children): Don't let close() clobber errno from
48801         failed fchdir().
48802
48803         * lib/fts.c (fts_stat): When following a symlink-to-directory,
48804         don't necessarily interpret stat-fails+lstat-succeeds as indicating
48805         a dangling symlink.  That can also happen at least for ELOOP.
48806         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
48807         FYI, this bug predates the inclusion of fts.c in coreutils.
48808
48809         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
48810         in their own block, so pre-c99 compilers don't object.
48811
48812         Avoid the double-free (first in fts_read, second in fts_close) that
48813         would occur when an `active' directory is made inaccessible (e.g.,
48814         via chmod a-x) during a traversal.
48815         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
48816         before returning.  Reproduce this failure by
48817         mkdir -p a/b; cd a; chmod a-x . b
48818         Reported by Stavros Passas.
48819
48820 2006-01-25  Jim Meyering  <jim@meyering.net>
48821
48822         * lib/fileblocks.c: Remove more useless parentheses.
48823         * lib/readutmp.h: Likewise.
48824
48825 2006-01-25  Bruno Haible  <bruno@clisp.org>
48826
48827         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
48828         warnings.
48829         Reported by Paul Eggert.
48830
48831 2006-01-25  Bruno Haible  <bruno@clisp.org>
48832
48833         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
48834         rid of a trap command. For Solaris sh.
48835         Reported by Mark D. Baushke <mdb@gnu.org>.
48836
48837 2006-01-24  Simon Josefsson  <jas@extundo.com>
48838
48839         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
48840         Bruno.
48841
48842 2006-01-24  Karl Berry  <karl@gnu.org>
48843
48844         * config/srclist.txt (argp-namefrob.h): sync lost.
48845
48846 2006-01-24  Jim Meyering  <jim@meyering.net>
48847
48848         * modules/openat (Files): Add lib/intprops.h.
48849         From Mark D. Baushke.
48850
48851 2006-01-24  Jim Meyering  <jim@meyering.net>
48852
48853         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
48854         Reported by Mark D. Baushke.
48855
48856 2006-01-24  Jim Meyering  <jim@meyering.net>
48857
48858         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
48859
48860 2006-01-24  Bruno Haible  <bruno@clisp.org>
48861
48862         * modules/strnlen (Maintainer): Change from glibc to all.
48863
48864 2006-01-24  Bruno Haible  <bruno@clisp.org>
48865
48866         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
48867         Patch by Paul Eggert.
48868
48869 2006-01-24  Bruno Haible  <bruno@clisp.org>
48870
48871         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
48872         already has it.
48873         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
48874         2005-11-26.
48875
48876         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
48877         'signed char' to avoid problems with the built-in _Bool type.
48878         Reported by Paul Eggert on 2005-11-26.
48879
48880 2006-01-24  Bruno Haible  <bruno@clisp.org>
48881
48882         * gnulib-tool (func_import): Avoid constructing complicated sed
48883         expressions inside backquote.
48884         Report and solution by Mark D. Baushke <mdb@gnu.org>.
48885
48886 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
48887
48888         These changes imported from libc.
48889         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
48890         test and two separate function calls.
48891         * lib/strndup.c (__strndup): Add libc_hidden_def.
48892
48893 2006-01-23  Simon Josefsson  <jas@extundo.com>
48894
48895         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
48896         Remove the test_*_SOURCES variable: automake infers it by default.
48897         * modules/tls-tests: Likewise.
48898
48899 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
48900
48901         Work around porting bugs reported by Dieter in
48902         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
48903         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
48904         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
48905         Include "getopt.h" first, to check interface.
48906         (getenv): Declare only if defined HAVE_DECL_GETENV &&
48907         !HAVE_DECL_GETENV.
48908         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
48909         (__strndup): Revert to K&R-style function dfns, the glibc style.
48910         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
48911         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
48912         Include strnlen.h first, to get prototype properly.
48913         (strnlen): Renamed from __strnlen.
48914         Remove weak alias.
48915
48916 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
48917
48918         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
48919
48920 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
48921
48922         * config/srclist.txt: Adjust to reflect glibc reorganization.
48923         This affects only comments.
48924
48925 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
48926
48927          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
48928          Reported by Bruce Korb <bkorb@gnu.org>.
48929
48930 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
48931
48932         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
48933         to pacify gcc -Wswitch-default.
48934
48935 2006-01-22  Bruno Haible  <bruno@clisp.org>
48936
48937         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
48938         temporary buffer for sprintf, take into account the precision also
48939         for 'd', 'i', 'u', 'o', 'x', 'X'.
48940
48941 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
48942
48943         * modules/argp-tests: New module
48944         * tests/test-argp.c: New file
48945         * tests/test-argp-2.sh: New file
48946
48947 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
48948
48949         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
48950         (__argp_base_name): Removed
48951         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
48952         typo.
48953         (__argp_base_name): Provide macro definition or extern declaration
48954         depending on the configuration
48955
48956 2006-01-20  Simon Josefsson  <jas@extundo.com>
48957
48958         * modules/inet_ntop (Depends-on): Depend on sys_socket.
48959
48960 2006-01-20  Simon Josefsson  <jas@extundo.com>
48961
48962         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
48963
48964 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
48965
48966         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
48967         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
48968         Suggested by Bruno Haible.
48969
48970 2006-01-20  Karl Berry  <karl@gnu.org>
48971
48972         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
48973         until changes propagate, I guess.
48974
48975 2006-01-19  Simon Josefsson  <jas@extundo.com>
48976
48977         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
48978
48979 2006-01-19  Simon Josefsson  <jas@extundo.com>
48980
48981         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
48982
48983 2006-01-19  Simon Josefsson  <jas@extundo.com>
48984
48985         * gnulib-tool: Set check_PROGRAMS.
48986
48987         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
48988         modules/des-tests, modules/gc-arcfour-tests,
48989         modules/gc-arctwo-tests, modules/gc-des-tests,
48990         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
48991         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
48992         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
48993         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
48994         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
48995         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
48996         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
48997         test_*_SOURCES.
48998
48999 2006-01-18  Simon Josefsson  <jas@extundo.com>
49000
49001         * modules/socklen (Depends-on): Depend on sys_socket.
49002
49003 2006-01-18  Simon Josefsson  <jas@extundo.com>
49004
49005         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
49006         modules/des-tests, modules/gc-arcfour-tests,
49007         modules/gc-arctwo-tests, modules/gc-des-tests,
49008         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
49009         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
49010         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
49011         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
49012         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
49013         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
49014         $(EXEEXT) to automake TESTS variable, for mingw32.
49015
49016 2006-01-17  Simon Josefsson  <jas@extundo.com>
49017
49018         * modules/socklen (Include): Need sys/socket.h.
49019
49020 2006-01-17  Bruno Haible  <bruno@clisp.org>
49021
49022         * modules/ssize_t (Include): Add <sys/types.h>.
49023
49024 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
49025
49026         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
49027         it's not portable and it doesn't work with cross-compiles.
49028         Problem reported by Bruno Haible.  Fix missing-$ typo in
49029         'test "gl_cv_ignore_unused_libraries" ...' that prevented
49030         -zignore from being used with Sun's C compiler.
49031
49032 2006-01-12  Simon Josefsson  <jas@extundo.com>
49033
49034         * lib/base64.c: Fix warning, reported by Bruno Haible
49035         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
49036
49037 2006-01-12  Bruno Haible  <bruno@clisp.org>
49038
49039         * modules/ldd: New file.
49040         * build-aux/ldd.sh.in: New file.
49041         * MODULES.html.sh (Support for building libraries and executables): Add
49042         ldd.
49043
49044 2006-01-12  Bruno Haible  <bruno@clisp.org>
49045
49046         * m4/ldd.m4: New file.
49047
49048 2006-01-12  Bruno Haible  <bruno@clisp.org>
49049
49050         * gnulib-tool (func_import, func_create_testdir): Don't go into an
49051         endless loop while replacing $auxdir with build-aux.
49052
49053 2006-01-11  Simon Josefsson  <jas@extundo.com>
49054
49055         * lib/stdint_.h (SIZE_MAX): Add missing (.
49056
49057 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
49058
49059         Sync from coreutils.
49060         * lib/md5.c: Fix commentary typos.
49061         (alignof, UNALIGNED_P): No need for a GCC-specific version.
49062         * lib/md5.h (__attribute__): Remove; unused.
49063         * lib/sha1.c: Fix commentary to match md5 better.
49064         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
49065         so that we don't need to worry about alignment.  All uses changed.
49066         This merges the 2005-10-28 md5 change into sha1.
49067
49068 2006-01-11  Jim Meyering  <jim@meyering.net>
49069
49070         Sync from coreutils.
49071         * lib/md5.c (OP): Fix spacing.
49072
49073 2006-01-11  Bruno Haible  <bruno@clisp.org>
49074
49075         Ensure automatic ordering between gl_LOCK and gl_ARGP.
49076         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
49077         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
49078
49079 2006-01-11  Bruno Haible  <bruno@clisp.org>
49080
49081         Ensure automatic ordering between gl_LOCK and gl_ARGP.
49082         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
49083         the "early" section as well.
49084
49085 2006-01-11  Bruno Haible  <bruno@clisp.org>
49086
49087         Avoid "ar: no archive members specified" error on MacOS X.
49088         * gnulib-tool (func_modules_add_dummy): New function.
49089         (func_import, func_create_testdir): Invoke it.
49090
49091 2006-01-11  Bruno Haible  <bruno@clisp.org>
49092
49093         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
49094         with $auxdir in AC_CONFIG_FILES statements.
49095
49096 2006-01-11  Bruno Haible  <bruno@clisp.org>
49097
49098         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
49099         Initialize also noinst_HEADERS to empty.
49100
49101 2006-01-11  Bruno Haible  <bruno@clisp.org>
49102
49103         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
49104         variables.
49105         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
49106         autoreconf.
49107
49108 2006-01-11  Bruno Haible  <bruno@clisp.org>
49109
49110         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
49111         overridable by the user.
49112         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
49113
49114 2006-01-10  Simon Josefsson  <jas@extundo.com>
49115
49116         * modules/sys_socket: New file.
49117
49118 2006-01-10  Simon Josefsson  <jas@extundo.com>
49119
49120         * m4/sys_socket_h.m4: New file.
49121
49122 2006-01-10  Simon Josefsson  <jas@extundo.com>
49123
49124         * lib/socket_.h: New file.
49125
49126 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
49127
49128         * modules/readutmp (Maintainer): Add myself.
49129
49130 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
49131
49132         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
49133         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
49134         People who are still concerned with buggy memcmp implementations
49135         can invoke gl_FUNC_MEMCMP themselves.
49136
49137 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
49138
49139         * lib/regex_internal.h (BITSET_WORD_BITS):
49140         Work around a bug in 64-bit PGC (before version 6.1-2), where the
49141         preprocessor mishandles large unsigned values as if they were signed.
49142         Problem reported by Claudio Fontana in
49143         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
49144
49145 2006-01-10  Jim Meyering  <jim@meyering.net>
49146
49147         Avoid the double-free (first in fts_read, second in fts_close) that
49148         would occur when an `active' directory is made inaccessible (e.g.,
49149         via chmod a-x) during a traversal.
49150         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
49151         before returning.  Reproduce this failure by
49152         mkdir -p a/b; cd a; chmod a-x . b
49153         Reported by Stavros Passas.
49154
49155         Sync from coreutils.
49156         * lib/sha1.c: Tweak grammar in a comment.
49157
49158 2006-01-10  Jim Meyering  <jim@meyering.net>
49159
49160         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
49161         Patch by Joerg Sonnenberger.
49162
49163 2006-01-10  Bruno Haible  <bruno@clisp.org>
49164
49165         * modules/readutmp: Depend on module free.
49166         * modules/strtok_r: Depend on module restrict.
49167
49168 2006-01-10  Bruno Haible  <bruno@clisp.org>
49169
49170         * modules/gettext (configure.ac): Add an invocation of
49171         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
49172
49173 2006-01-10  Bruno Haible  <bruno@clisp.org>
49174
49175         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
49176         Reported by Werner Lemberg <wl@gnu.org>.
49177
49178 2006-01-10  Bruno Haible  <bruno@clisp.org>
49179
49180         * lib/localcharset.c: Update from GNU gettext.
49181
49182 2006-01-10  Bruno Haible  <bruno@clisp.org>
49183
49184         * lib/argp.h (__const): Remove macro. Use const instead.
49185         * lib/argp-fmtstream.h (__const): Likewise.
49186         * lib/glob_.h (__const): Remove macro.
49187         * lib/glob-libc.h: Use const instead of __const.
49188
49189 2006-01-10  Bruno Haible  <bruno@clisp.org>
49190
49191         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
49192         variable.
49193         Needed to avoid an automake error regarding the 'gettext' module.
49194
49195 2006-01-09  Simon Josefsson  <jas@extundo.com>
49196
49197         * modules/inet_ntop (Depends-on): Add restrict.
49198
49199 2006-01-09  Simon Josefsson  <jas@extundo.com>
49200
49201         * modules/gc-rijndael-tests (License): Put under LGPL.
49202
49203         * modules/gc-des-tests (License): Likewise.
49204
49205         * modules/gc-arcfour-tests (License): Likewise.
49206
49207         * modules/gc-arctwo-tests (License): Likewise.
49208
49209         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
49210
49211         * modules/gc-hmac-sha1-tests (Files): Likewise.
49212
49213         * modules/gc-hmac-md5-tests (License): Likewise.
49214
49215         * modules/gc-sha1-tests (License): Likewise.
49216
49217         * modules/gc-md5-tests (License): Likewise.
49218
49219         * modules/gc-md4-tests (License): Likewise.
49220
49221         * modules/gc-md2-tests (License): Likewise.
49222
49223         * modules/gc-tests (License): Likewise.
49224
49225         * modules/des-tests (License): Likewise.
49226
49227         * modules/md4-tests (License): Likewise.
49228
49229         * modules/md2-tests (License): Likewise.
49230
49231 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
49232
49233         Sync from coreutils:
49234
49235         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
49236         * modules/lib-ignore: New file.
49237         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
49238         chdir-safer.m4, lchmod.m4.
49239         * modules/openat: Add mkdirat.c, openat-priv.h.
49240
49241 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
49242
49243         Sync from coreutils.
49244         * m4/lib-ignore.m4: New file.
49245         * m4/lchmod.m4: New file.
49246
49247 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
49248
49249         Sync from coreutils.
49250         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
49251         for write access: POSIX says that must fail.
49252         * lib/fts.c (diropen): Likewise.
49253         * lib/save-cwd.c (save_cwd): Likewise.
49254         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
49255         well, for minor improvements on hosts that lack O_DIRECTORY.
49256         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
49257         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
49258         Fall back on chown if open failed with EACCES.
49259
49260         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
49261         Report an error at compile-time if only a 1-second nominal clock
49262         resolution is found.
49263
49264         * lib/lchmod.h: New file.
49265         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
49266         (make_dir_parents): Use lchown rather than chown, and
49267         lchmod rather than chmod.
49268
49269         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
49270         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
49271         "proc" reported by n0dalus.
49272
49273         * lib/mountlist.c: Include <limits.h>.
49274         (dev_from_mount_options)
49275         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
49276         New function.  It no longer assumes "dev=" has the System V meaning
49277         on Linux (since it doesn't).  It also parses "dev=" more carefully.
49278         (read_file_system_list)
49279         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
49280         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
49281         dev= in that case.
49282
49283         * lib/posixtm.h (PDS_PRE_2000): New macro.
49284         * lib/posixtm.c (year): Arg is now syntax_bits rather than
49285         allow_century.  All usages changed.  Reject dates outside the range
49286         1969-1999 if PDS_PRE_2000 is used.
49287
49288 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
49289
49290         Sync from coreutils.
49291         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
49292         (Time of day items): Mention the possibility of leap seconds.
49293         Problem reported by Dr. David Alan Gilbert.
49294
49295 2006-01-09  Jim Meyering  <jim@meyering.net>
49296
49297         Sync from coreutils.
49298
49299         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
49300
49301         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
49302
49303         * lib/modechange.c (mode_compile): Reject an invalid mode string
49304         that starts with an octal digit.  From Andreas Gruenbacher.
49305
49306         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
49307         and dup to open_safer and dup_safer, respectively.
49308         (openat_permissive): Fix typo in comment.
49309
49310         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
49311         "gettext.h"; either no longer needed or are guaranteed by openat.h.
49312         (_): Remove; no longer needed.
49313         (openat): Renamed from rpl_openat; no need for rpl_openat
49314         since openat.h renames openat for us.
49315         Replace most of the body with a call to openat_permissive,
49316         to avoid duplicate code.
49317         Port to (probably hypothetical) environments were mode_t is
49318         wider than int.
49319         (openat_permissive): Require mode arg, so that we can check
49320         types better.  Put it just after flags.  Change cwd failure
49321         indicator from pointer-to-bool to pointer-to-errno-value.
49322         All callers changed.
49323         Invoke openat_save_fail and/or openat_restore_fail if
49324         cwd_errno is null, so that openat can call us.
49325         (openat_permissive, fdopendir, fstatat, unlinkat):
49326         Simplify errno handling to avoid some duplicate code,
49327         as it's OK to set errno on success.
49328         * lib/openat.h: Revamp code so that function macros depend on
49329         __OPENAT_PREFIX only, not also on AT_FDCWD.
49330         (openat_ro): Remove.  Caller changed to use openat_permissive.
49331         (openat_permissive): Now a macro, if not a function.
49332         (openat_restore_fail, openat_save_fail): Now always functions,
49333         since mkdirat needs them even if __OPENAT_PREFIX is defined.
49334
49335         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
49336         and openat.c.
49337         * lib/mkdirat.c: Include openat-priv.h.
49338         Remove definitions of macros defined therein.
49339         * lib/openat.c: Likewise.
49340
49341         * lib/mkdirat.c (mkdirat): New file and function.
49342         * lib/openat.h (mkdirat): Declare.
49343
49344         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
49345
49346         * lib/openat.h (openat_permissive): Declare.
49347         (openat_ro): Define.
49348
49349         * lib/openat.c (EXPECTED_ERRNO): New macro.
49350         (openat_permissive): New function -- used in remove.c rewrite.
49351         (all functions): Set errno just before returning, only if there
49352         was an actual failure.
49353         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
49354
49355         Emulate openat-family functions using Linux's procfs, if possible.
49356         Idea and some code based on Ulrich Drepper's glibc changes.
49357
49358         * lib/openat.c: (BUILD_PROC_NAME): New macro.
49359         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
49360         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
49361         before falling back on save_cwd and restore_cwd.
49362         (fdopendir, fstatat, unlinkat): Likewise.
49363
49364         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
49365         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
49366
49367         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
49368         as second argument to va_arg.  Otherwise, some versions of gcc
49369         warn that `if this code is reached, the program will abort'.
49370
49371 2006-01-09  Jim Meyering  <jim@meyering.net>
49372
49373         Sync from coreutils.
49374         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
49375         Require openat-priv.h.
49376
49377 2006-01-09  Bruno Haible  <bruno@clisp.org>
49378
49379         * modules/strnlen (Include): Use strnlen.h.
49380
49381 2006-01-09  Bruno Haible  <bruno@clisp.org>
49382
49383         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
49384
49385 2006-01-09  Bruno Haible  <bruno@clisp.org>
49386
49387         * lib/sysexit_.h (EX_OK): New macro.
49388         Suggested by Martin Lambers <marlam@marlam.de>.
49389
49390 2006-01-09  Bruno Haible  <bruno@clisp.org>
49391
49392         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
49393         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
49394
49395 2006-01-09  Bruno Haible  <bruno@clisp.org>
49396
49397         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
49398         numbers.
49399
49400 2006-01-09  Bruno Haible  <bruno@clisp.org>
49401
49402         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
49403         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
49404         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
49405         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
49406
49407 2006-01-09  Bruno Haible  <bruno@clisp.org>
49408
49409         * build-aux/javacomp.sh.in: New file, moved from lib/.
49410         * modules/javacomp-script (Files): Update.
49411         (configure.ac): Add AC_CONFIG_FILES invocation.
49412         (EXTRA_DIST): Remove variable.
49413
49414         * build-aux/javaexec.sh.in: New file, moved from lib/.
49415         * modules/javaexec (Files): Update.
49416         (configure.ac): Add AC_CONFIG_FILES invocation.
49417         (EXTRA_DIST): Remove javaexec.sh.in.
49418
49419         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
49420         * modules/csharpcomp-script (Files): Update.
49421         (configure.ac): Add AC_CONFIG_FILES invocation.
49422         (EXTRA_DIST): Remove variable.
49423
49424         * build-aux/csharpexec.sh.in: New file, moved from lib/.
49425         * modules/csharpexec (Files): Update.
49426         (configure.ac): Add AC_CONFIG_FILES invocation.
49427         (EXTRA_DIST): Remove csharpexec.sh.in.
49428
49429 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
49430
49431         Sync from coreutils.
49432
49433         Add POSIX ACL support
49434         * lib/acl.h (copy_acl, set_acl): Add declarations.
49435         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
49436         systems other than Linux.
49437         (chmod_or_fchmod): New function: use fchmod when possible,
49438         and chmod otherwise.
49439         (file_has_acl): Add a POSIX ACL implementation, with a
49440         Linux-specific subcase.
49441         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
49442         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
49443         acls are unsupported.
49444         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
49445         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
49446         are unsupported.
49447
49448 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
49449
49450         Sync from coreutils.
49451         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
49452
49453 2006-01-07  Bruno Haible  <bruno@clisp.org>
49454
49455         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
49456         gl_EARLY.
49457
49458 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
49459
49460         * lib/strftime.c (tzname): Don't declare if it is already #defined.
49461         Problem reported for Mingw by Mark Junker.
49462
49463 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
49464
49465         * README: Gnulib normally doesn't generate a tarball.
49466
49467 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
49468
49469         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
49470         long int, not int, for nanosecond counts, so that people who are
49471         used to POSIX struct timespec won't be surprised.  Reported by Jim
49472         Meyering.
49473
49474 2005-12-28  Bruno Haible  <bruno@clisp.org>
49475
49476         * build-aux/config.rpath: Update from GNU gettext.
49477
49478 2005-12-16  Jim Meyering  <jim@meyering.net>
49479
49480         * modules/fprintftime: New module.
49481         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
49482
49483 2005-12-16  Jim Meyering  <jim@meyering.net>
49484
49485         * m4/fprintftime.m4: New file.
49486
49487 2005-12-16  Jim Meyering  <jim@meyering.net>
49488
49489         * lib/fprintftime.c, lib/fprintftime.h: New files.
49490
49491 2005-12-15  Simon Josefsson  <jas@extundo.com>
49492
49493         * modules/socklen (configure.ac): Fix M4 macro name, to align with
49494         new m4/socklen.m4.
49495
49496 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
49497
49498         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
49499         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
49500
49501 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
49502
49503         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
49504         * lib/argp-help.c (fill_in_uparams): Check if the constructed
49505         struct uparams is valid. Fall back to the default values if it is
49506         not.
49507
49508 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
49509
49510         * modules/argp (Files): Add argp-pin.c
49511         (Depends-on): dirname
49512         (lib_SOURCES): Add argp-pin.c
49513
49514 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
49515
49516         * m4/argp.m4:  Check if program_invocation_name and
49517         program_invocation_short_name are declared and define appropriate
49518         macros if they are not.
49519
49520 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
49521
49522         * lib/argp-help.c (__argp_base_name): New function
49523         (__argp_short_program_name): Rewrite using __argp_base_name
49524         * lib/argp-namefrob.h: Define program_invocation_name and
49525         program_invocation_short_name if requested
49526         (__argp_base_name): Add prototype
49527         * lib/argp-parse.c (argp_def): Use gettext wrappers
49528         (argp_default_parser): Use __argp_base_name
49529         * lib/argp-pin.c: New file. Defines program_invocation_name and
49530         program_invocation_short_name on systems that lack them.
49531
49532 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
49533
49534         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
49535         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
49536         porting problem reported by Georg Schwarz in
49537         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
49538
49539 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
49540
49541         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
49542         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
49543         porting problem reported by Georg Schwarz in
49544         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
49545
49546 2005-12-05  Bruno Haible  <bruno@clisp.org>
49547
49548         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
49549         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
49550         Reported by Mark Junker <mjscod@gmx.de>.
49551
49552 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
49553
49554         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
49555         Use implementation from Albert Chin, with some
49556         comments/corrections by Stepan Kasal and myself.
49557
49558 2005-12-02  Bruno Haible  <bruno@clisp.org>
49559
49560         * gnulib-tool (func_import): Accept GPLed build tool modules when
49561         --lgpl is given.
49562         * modules/csharpcomp-script: New file.
49563         * modules/csharpcomp: Depend on it.
49564         * modules/javacomp-script: New file.
49565         * modules/javacomp: Depend on it.
49566         Suggested by Simon Josefsson.
49567
49568 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
49569
49570         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
49571         statement, to work around an HP-UX 10.20 compiler bug reported by
49572         Peter O'Gorman.
49573
49574 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
49575
49576         * modules/savedir (Depends-on): Add openat.
49577
49578 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
49579
49580         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
49581         (uintmax_t) [defined uintmax_t]: Do not declare.
49582         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
49583         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
49584         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
49585         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
49586         sake of portability to weird hosts that C allows (though we don't
49587         know of any practical examples).
49588
49589         * lib/savedir.h (fdsavedir): New decl.
49590         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
49591         contains most of the former guts of savedir.
49592         (savedir): Use savedirstream.
49593         Include "openat.h".
49594
49595 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
49596
49597         * modules/obstack (Files): Add m4/ulonglong.m4.
49598         Problem reported by Davide Angelocola.
49599
49600 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
49601
49602         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
49603         coreutils no longer futzes with rounding modes.
49604
49605 2005-11-14  Jim Meyering  <jim@meyering.net>
49606
49607         * lib/mkstemp-safer.c: Include <config.h>, required for possible
49608         replacement of mkstemp.
49609
49610 2005-11-10  Simon Josefsson  <jas@extundo.com>
49611
49612         * lib/readline.c: Remove EOL.
49613
49614 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
49615
49616         * modules/gethrxtime (Depends-on): Add gettime.
49617
49618 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
49619
49620         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
49621         or gettimeofday; no longer needed.
49622
49623 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
49624
49625         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
49626         time business.
49627         (gethrxtime) [! (HAVE_NANOUPTIME
49628         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
49629         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
49630         our own approximation.
49631
49632 2005-11-08  Eric Blake  <ebb9@byu.net>
49633
49634         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
49635
49636 2005-11-08  Eric Blake  <ebb9@byu.net>
49637
49638         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
49639
49640 2005-11-04  Bruno Haible  <bruno@clisp.org>
49641
49642         * gnulib-tool: Implement --update mode.
49643
49644 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
49645
49646         Fix porting problem reported by Theodoros V. Kalamatianos.
49647         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
49648         Don't assume that futimes failing means we must fail.
49649
49650 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
49651
49652         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
49653         variables to suggest the intended function of the PATH_MAX check.
49654
49655 2005-10-30  Kean Johnston  <jkj@sco.com>
49656
49657         Trivial changes to support SCO systems.
49658         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
49659         as PATH_MAX.
49660         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
49661         where __ptr is null when no I/O is pending.
49662
49663 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
49664
49665         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
49666         leave errno alone.  Problem reported by Dmitry V. Levin.
49667
49668 2005-10-28  Simon Josefsson  <jas@extundo.com>
49669
49670         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
49671         Test more.
49672
49673         * tests/test-gc-md2.c, tests/test-md2.c: New files.
49674
49675         * modules/md2, modules/md2-tests: New files.
49676
49677 2005-10-28  Simon Josefsson  <jas@extundo.com>
49678
49679         * m4/inet_ntop.m4: More tests.
49680
49681         * m4/gc-md2.m4, md2.m4: New file.
49682
49683 2005-10-28  Simon Josefsson  <jas@extundo.com>
49684
49685         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
49686         "restrict" keywords, as per POSIX.  Protect the function
49687         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
49688         Don't use K&R prototypes.  Check the sprintf return values.
49689         Re-define EAFNOSUPPORT if not present.  Indent.
49690
49691         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
49692         suggested by Bruno Haible <bruno@clisp.org>.
49693
49694         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
49695
49696         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
49697
49698         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
49699         libgcrypt).
49700
49701         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
49702
49703         * lib/md2.h, lib/md2.c: New files.
49704
49705 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
49706
49707         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
49708         errno alone.  Problem reported by Frederic Jolliton.
49709
49710 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
49711
49712         * modules/verify (License): Change from GPL to LGPL.  This is a
49713         tiny module and there are apparently near-equivalents that are
49714         under the BSD license.
49715
49716 2005-10-24  Simon Josefsson  <jas@extundo.com>
49717
49718         * modules/sha1: Relicense to LGPL.
49719
49720 2005-10-24  Simon Josefsson  <jas@extundo.com>
49721
49722         * lib/md4.h: Shrink buffer size, now that we changed the type.
49723
49724 2005-10-23  Simon Josefsson  <jas@extundo.com>
49725
49726         * gnulib-tool (func_import): Fix --tests-base.
49727
49728 2005-10-22  Simon Josefsson  <jas@extundo.com>
49729
49730         * modules/arcfour (Depends-on): Need stdint.
49731
49732 2005-10-22  Simon Josefsson  <jas@extundo.com>
49733
49734         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
49735         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
49736
49737 2005-10-22  Simon Josefsson  <jas@extundo.com>
49738
49739         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
49740         suggested by Bruno Haible <bruno@clisp.org>.
49741
49742 2005-10-22  Simon Josefsson  <jas@extundo.com>
49743
49744         * lib/crc.h: Include stddef.h, for size_t.
49745
49746 2005-10-22  Simon Josefsson  <jas@extundo.com>
49747
49748         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
49749         arcfour_context struct (simplify test vector testing in GNU
49750         Shishi).
49751
49752 2005-10-21  Simon Josefsson  <jas@extundo.com>
49753
49754         * modules/des, modules/des-tests: New files.
49755
49756         * modules/gc-des, modules/gc-des-tests: New files.
49757
49758         * tests/test-des.c, tests/test-gc-des.c: New file.
49759
49760 2005-10-21  Simon Josefsson  <jas@extundo.com>
49761
49762         * modules/arctwo, modules/arctwo-tests: New files.
49763
49764         * tests/test-arctwo.c: New file.
49765
49766         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
49767
49768         * tests/test-gc-arctwo.c: New file.
49769
49770 2005-10-21  Simon Josefsson  <jas@extundo.com>
49771
49772         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
49773         Bruno Haible <bruno@clisp.org>.
49774
49775         * m4/gc-des.m4: New file.
49776
49777 2005-10-21  Simon Josefsson  <jas@extundo.com>
49778
49779         * m4/arctwo.m4: New file.
49780
49781         * m4/gc-arctwo.m4: New file.
49782
49783 2005-10-21  Simon Josefsson  <jas@extundo.com>
49784
49785         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
49786         block.
49787
49788 2005-10-21  Simon Josefsson  <jas@extundo.com>
49789
49790         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
49791         <bruno@clisp.org>.
49792
49793         * lib/hmac-sha1.c (hmac_sha1): Likewise.
49794
49795         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
49796         Bruno Haible <bruno@clisp.org>.
49797
49798         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
49799         <bruno@clisp.org>.
49800
49801 2005-10-21  Simon Josefsson  <jas@extundo.com>
49802
49803         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
49804
49805 2005-10-21  Simon Josefsson  <jas@extundo.com>
49806
49807         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
49808
49809 2005-10-21  Simon Josefsson  <jas@extundo.com>
49810
49811         * lib/des.h, lib/des.c: New files.
49812
49813         * lib/gc-gnulib.c: Support DES.c
49814
49815 2005-10-21  Simon Josefsson  <jas@extundo.com>
49816
49817         * lib/arctwo.h, lib/arctwo.c: New files.
49818
49819         * lib/gc-gnulib.c: Support ARCTWO.
49820
49821 2005-10-21  Simon Josefsson  <jas@extundo.com>
49822
49823         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
49824         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
49825
49826 2005-10-21  Simon Josefsson  <jas@extundo.com>
49827
49828         * gnulib-tool (func_import, func_create_testdir): Define automake
49829         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
49830         Makefile.am snippet),
49831         suggested by Bruno Haible <bruno@clisp.org>.
49832
49833         * modules/gc (Makefile.am): Use it.
49834
49835 2005-10-21  Bruno Haible  <bruno@clisp.org>
49836
49837         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
49838         patch.
49839
49840 2005-10-19  Simon Josefsson  <jas@extundo.com>
49841
49842         * tests/test-gc-rijndael.c: New file.
49843
49844         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
49845
49846 2005-10-19  Simon Josefsson  <jas@extundo.com>
49847
49848         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
49849         interface too.
49850
49851 2005-10-19  Simon Josefsson  <jas@extundo.com>
49852
49853         * tests/test-gc-arcfour.c: New file.
49854
49855         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
49856
49857 2005-10-19  Simon Josefsson  <jas@extundo.com>
49858
49859         * modules/gc-md4, modules/gc-md4-tests: New file.
49860
49861         * tests/test-gc-md4.c: New file.
49862
49863 2005-10-19  Simon Josefsson  <jas@extundo.com>
49864
49865         * m4/gc-md4.m4: New file.
49866
49867 2005-10-19  Simon Josefsson  <jas@extundo.com>
49868
49869         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
49870         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
49871         <kasal@ucw.cz>.
49872
49873 2005-10-19  Simon Josefsson  <jas@extundo.com>
49874
49875         * m4/gc-arcfour.m4: New file.
49876
49877         * m4/gc-rijndael.m4: New file.
49878
49879 2005-10-19  Simon Josefsson  <jas@extundo.com>
49880
49881         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
49882
49883 2005-10-19  Simon Josefsson  <jas@extundo.com>
49884
49885         * lib/gc-gnulib.c: Support ARCFOUR.
49886
49887 2005-10-19  Simon Josefsson  <jas@extundo.com>
49888
49889         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
49890         support.
49891
49892         * lib/gc.h: Add ECB enum type.
49893
49894         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
49895
49896 2005-10-18  Simon Josefsson  <jas@extundo.com>
49897
49898         * tests/test-md5.c: New file.
49899
49900         * modules/md5-tests: New file.
49901
49902 2005-10-18  Simon Josefsson  <jas@extundo.com>
49903
49904         * tests/test-md4.c: New file.
49905
49906         * modules/md4, modules/md4-tests: New files.
49907
49908 2005-10-18  Simon Josefsson  <jas@extundo.com>
49909
49910         * m4/md4.m4: New file.
49911
49912 2005-10-18  Simon Josefsson  <jas@extundo.com>
49913
49914         * lib/md4.h, lib/md4.c: New files, based on md5.?.
49915
49916 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
49917
49918         * gnulib-tool (func_create_testdir): Omit the second check whether
49919         BUILT_SOURCES in nonempty.
49920
49921 2005-10-17  Simon Josefsson  <jas@extundo.com>
49922
49923         * tests/test-rijndael.c: New file.
49924
49925 2005-10-17  Simon Josefsson  <jas@extundo.com>
49926
49927         * modules/sha1: Depend on stdint instead of md5.
49928
49929         * modules/md5: Depend on stdint, remove uint32_t.
49930
49931 2005-10-17  Simon Josefsson  <jas@extundo.com>
49932
49933         * modules/gc-sha1-tests: New file.
49934
49935         * tests/test-gc-sha1.c: New file.
49936
49937 2005-10-17  Simon Josefsson  <jas@extundo.com>
49938
49939         * m4/md5.m4: Remove call to uint32_t.m4.
49940
49941 2005-10-17  Simon Josefsson  <jas@extundo.com>
49942
49943         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
49944
49945         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
49946         md5.h.
49947
49948         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
49949
49950         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
49951
49952 2005-10-17  Simon Josefsson  <jas@extundo.com>
49953
49954         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
49955
49956 2005-10-17  Simon Josefsson  <jas@extundo.com>
49957
49958         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
49959
49960 2005-10-17  Simon Josefsson  <jas@extundo.com>
49961
49962         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
49963
49964         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
49965
49966 2005-10-17  Bruno Haible  <bruno@clisp.org>
49967
49968         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
49969         that it can also be used in a test.
49970
49971 2005-10-16  Bruno Haible  <bruno@clisp.org>
49972
49973         * gnulib-tool (func_emit_tests_Makefile_am): Also define
49974         TESTS_ENVIRONMENT, so that individual tests can augment it.
49975
49976         * gnulib-tool (func_create_testdir): Use an intermediate target for
49977         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
49978         macros, like $(ALLOCA_H), which cannot be passed through the command
49979         line.
49980
49981 2005-10-15  Simon Josefsson  <jas@extundo.com>
49982
49983         * modules/rijndael-tests: New file.
49984
49985         * modules/rijndael: New file.
49986
49987 2005-10-15  Simon Josefsson  <jas@extundo.com>
49988
49989         * m4/rijndael.m4: New file.
49990
49991 2005-10-15  Simon Josefsson  <jas@extundo.com>
49992
49993         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
49994
49995         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
49996
49997 2005-10-14  Simon Josefsson  <jas@extundo.com>
49998
49999         * tests/test-arcfour.c: New file.
50000
50001         * modules/arcfour, modules/arcfour-tests: New files.
50002
50003 2005-10-14  Simon Josefsson  <jas@extundo.com>
50004
50005         * m4/arcfour.m4: New file.
50006
50007 2005-10-14  Simon Josefsson  <jas@extundo.com>
50008
50009         * lib/arcfour.h, lib/arcfour.c: New files.
50010
50011 2005-10-14  Roland McGrath  <roland@redhat.com>
50012
50013         Import from libc.  [BZ #1331]
50014         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
50015         macro argument.
50016         Reported by Matej Vela <vela@debian.org>.
50017
50018 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
50019
50020         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
50021         include <wchar.h>; no longer needed.
50022
50023 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
50024
50025         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
50026
50027 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
50028         and  Ulrich Drepper  <drepper@redhat.com>
50029
50030         Import from libc.
50031         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
50032         instead of inline stream orientation test and two separate
50033         function calls.  Pay no attention to USE_IN_LIBIO.
50034
50035 2005-10-13  Simon Josefsson  <jas@extundo.com>
50036
50037         * modules/gc-hmac-md5-tests: New file.
50038
50039         * tests/test-gc-hmac-sha1.c: New file.
50040
50041         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
50042
50043         * modules/gc-hmac-md5-tests: New file.
50044
50045         * tests/test-gc-md5.c: New file.
50046
50047         * modules/gc-md5-tests: New file.
50048
50049 2005-10-13  Simon Josefsson  <jas@extundo.com>
50050
50051         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
50052         Move memory allocation outside of loop.
50053
50054 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
50055
50056         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
50057         intermediate directory is in a read-only file system.  Problem
50058         reported by Eric Blake.
50059
50060 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
50061
50062         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
50063
50064 2005-10-12  Simon Josefsson  <jas@extundo.com>
50065
50066         * tests/test-hmac-sha1.c: New file.
50067
50068         * modules/hmac-sha1-tests: New file.
50069
50070         * modules/hmac-sha1: New file.
50071
50072 2005-10-12  Simon Josefsson  <jas@extundo.com>
50073
50074         * modules/gc-sha1: New file.
50075
50076 2005-10-12  Simon Josefsson  <jas@extundo.com>
50077
50078         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
50079
50080         * tests/test-gc-pbkdf2-sha1.c: New file.
50081
50082 2005-10-12  Simon Josefsson  <jas@extundo.com>
50083
50084         * modules/gc-md5, modules/gc-hmac-md5: New files.
50085
50086         * modules/gc (Files): Remove md5, memxor and hmac files.
50087
50088 2005-10-12  Simon Josefsson  <jas@extundo.com>
50089
50090         * m4/gc-pbkdf2-sha1.m4: New file.
50091
50092         * m4/gc-hmac-sha1.m4: New file.
50093
50094         * m4/gc-sha1: New file.
50095
50096         * m4/hmac-sha1.m4: New file.
50097
50098 2005-10-12  Simon Josefsson  <jas@extundo.com>
50099
50100         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
50101
50102         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
50103
50104 2005-10-12  Simon Josefsson  <jas@extundo.com>
50105
50106         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
50107         suggested by Bruno Haible <bruno@clisp.org>.
50108
50109 2005-10-12  Simon Josefsson  <jas@extundo.com>
50110
50111         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
50112
50113 2005-10-12  Simon Josefsson  <jas@extundo.com>
50114
50115         * lib/gc-pbkdf2-sha1.c: New file.
50116
50117         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
50118
50119 2005-10-12  Simon Josefsson  <jas@extundo.com>
50120
50121         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
50122
50123         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
50124
50125 2005-10-12  Simon Josefsson  <jas@extundo.com>
50126
50127         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
50128         GC_USE_HMAC_MD5, respectively.
50129
50130         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
50131         (gc_md5): Fix typo.
50132
50133         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
50134
50135         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
50136
50137         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
50138
50139 2005-10-12  Bruno Haible  <bruno@clisp.org>
50140
50141         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
50142         Reported by Stepan Kasal <kasal@ucw.cz>.
50143
50144 2005-10-11  Simon Josefsson  <jas@extundo.com>
50145
50146         * tests/test-crc.c: New file.
50147
50148         * modules/crc, modules/crc-tests: New files.
50149
50150 2005-10-11  Simon Josefsson  <jas@extundo.com>
50151
50152         * m4/crc.m4: New file.
50153
50154 2005-10-11  Simon Josefsson  <jas@extundo.com>
50155
50156         * lib/gc.h: Add gc_hash and gc_hash_buffer.
50157
50158         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
50159
50160         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
50161
50162 2005-10-11  Simon Josefsson  <jas@extundo.com>
50163
50164         * lib/crc.h, lib/crc.c: New files.
50165
50166         * lib/gc.h (gc_hash_buffer): Add doc.
50167
50168 2005-10-11  Bruno Haible  <bruno@clisp.org>
50169
50170         * modules/c-strcasestr: New file.
50171         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
50172
50173 2005-10-11  Bruno Haible  <bruno@clisp.org>
50174
50175         * modules/c-strcase: New file.
50176         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
50177
50178 2005-10-11  Bruno Haible  <bruno@clisp.org>
50179
50180         * lib/strcasecmp.c: Include limits.h.
50181         (strcasecmp): Avoid integer overflow on exotic platforms.
50182         * lib/strncasecmp.c: Include limits.h.
50183         (strncasecmp): Avoid integer overflow on exotic platforms.
50184         Reported by Paul Eggert.
50185
50186 2005-10-11  Bruno Haible  <bruno@clisp.org>
50187
50188         * lib/c-strcasestr.h: New file, from GNU gettext.
50189         * lib/c-strcasestr.c: New file, from GNU gettext.
50190
50191 2005-10-11  Bruno Haible  <bruno@clisp.org>
50192
50193         * lib/c-strcase.h: New file, from GNU gettext.
50194         * lib/c-strcasecmp.c: New file, from GNU gettext.
50195         * lib/c-strncasecmp.c: New file, from GNU gettext.
50196
50197 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
50198
50199         * modules/mempcpy (License): GPL -> LGPL.
50200         * modules/strchrnul (License): Likewise.
50201         * modules/sysexits (License): Likewise.
50202
50203 2005-10-08  Simon Josefsson  <jas@extundo.com>
50204
50205         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
50206
50207 2005-10-07  Simon Josefsson  <jas@extundo.com>
50208
50209         * m4/memxor.m4: Remove gl_C_RESTRICT call.
50210
50211 2005-10-06  Simon Josefsson  <jas@extundo.com>
50212
50213         * tests/test-hmac-md5.c: New file.
50214
50215         * modules/hmac-md5-tests: New file.
50216
50217         * modules/hmac-md5: New file.
50218
50219 2005-10-06  Simon Josefsson  <jas@extundo.com>
50220
50221         * m4/hmac-md5.m4: New file.
50222
50223         * m4/memxor.m4: Require gl_C_RESTRICT.
50224
50225 2005-10-06  Simon Josefsson  <jas@extundo.com>
50226
50227         * lib/memxor.c (memxor): Avoid casts and warnings.
50228
50229 2005-10-06  Simon Josefsson  <jas@extundo.com>
50230
50231         * lib/hmac-md5.c: New file.
50232
50233         * lib/hmac.h: New file.
50234
50235 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
50236
50237         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
50238         promotes to int, not unsigned int, to catch the AIX 5.3
50239         compiler bug.
50240
50241 2005-10-05  Simon Josefsson  <jas@extundo.com>
50242
50243         * modules/memxor: New file.
50244
50245         * modules/iconv (Files): Move config.rpath to havelib, it is used
50246         there.
50247
50248         * modules/havelib (Files): Add config.rpath.
50249
50250 2005-10-05  Simon Josefsson  <jas@extundo.com>
50251
50252         * m4/memxor.m4: New file.
50253
50254 2005-10-05  Simon Josefsson  <jas@extundo.com>
50255
50256         * lib/memxor.c (memxor): Fix compiler error.
50257
50258         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
50259         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
50260
50261         * lib/memxor.h, lib/memxor.c: New files.
50262
50263         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
50264         we assume all systems have it, suggested by Jim Meyering
50265         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
50266         any systems lack sys/socket.h; mingw32 is known to lack it, but we
50267         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
50268         same reasons.
50269
50270 2005-10-05  Simon Josefsson  <jas@extundo.com>
50271
50272         * config/srclist.txt: Add glibc bug 1423 for md5.h.
50273
50274 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
50275
50276         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
50277         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
50278         needed, since the source code now assumes these .h files.
50279
50280 2005-10-05  Derek Price  <derek@ximbiot.com>
50281
50282         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
50283
50284 2005-10-05  Bruno Haible  <bruno@clisp.org>
50285
50286         * modules/stdint (License): Change to LGPL.
50287
50288 2005-10-04  Simon Josefsson  <jas@extundo.com>
50289
50290         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
50291         D. Baushke" <mdb@gnu.org>.
50292
50293 2005-10-04  Bruno Haible  <bruno@clisp.org>
50294
50295         * lib/verify.h (verify_true): Provide alternative definition for C++.
50296
50297 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
50298
50299         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
50300         (SSIZE_MAX): New macro, if not already defined.
50301         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
50302         than 2 GiB.
50303
50304 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
50305
50306         Sync from coreutils.
50307         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
50308         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
50309         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
50310         ULLONG_MAX doesn't work with 2.7.2.1.
50311
50312 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
50313
50314         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
50315         From Ben Pfaff.
50316
50317         * modules/exclude (Depends-on): Depend on verify.
50318         * modules/strtoimax (Depends-on): Likewise.
50319         * modules/utimecmp (Depends-on): Likewise.
50320
50321 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
50322
50323         * lib/exclude.c: Include verify.h.
50324         (verify): Remove.  All callers changed to use verify.h's version.
50325         * lib/strtoimax.c: Likewise.
50326         * lib/utimecmp.c: Likewis.e
50327
50328         Sync from coreutils.
50329         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
50330         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
50331         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
50332         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
50333         bother returning ENOSYS if settimeofday or stime fails; just let
50334         them return whatever errno they want to return.
50335         * lib/utimens.c: Include unistd.h, for dup2.
50336         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
50337         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
50338
50339 2005-10-02  Jim Meyering  <jim@meyering.net>
50340
50341         Sync from coreutils.
50342         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
50343         from glibc-2.2.5 that fails for read-only files.
50344
50345 2005-10-02  Jim Meyering  <jim@meyering.net>
50346
50347         Sync from coreutils.
50348         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
50349         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
50350         `#if HAVE_CONFIG_H'.
50351         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
50352         Remove AT_FDCWD test.
50353         Do not consume the fd unless successful.
50354         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
50355         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
50356         block, so that we don't even try to compile it if settimeofday is
50357         available.  This works around a compilation failure on OSF1 V5.1,
50358         due to stime requiring a `long int*' while tv_sec is `int'.
50359
50360 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
50361
50362         Sync from coreutils.
50363         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
50364         against `yes', rather than just testing for nonempty.
50365
50366 2005-10-01  Simon Josefsson  <jas@extundo.com>
50367
50368         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
50369         and Darwin.
50370
50371         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
50372         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
50373         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
50374         freeaddrinfo and gai_strerror are declared by the POSIX headers.
50375         Check if struct addrinfo is declared.
50376
50377 2005-10-01  Simon Josefsson  <jas@extundo.com>
50378
50379         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
50380         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
50381         AI_* and EAI_* definitions.  Protect function declarations.
50382
50383 2005-10-01  Jim Meyering  <jim@meyering.net>
50384
50385         Sync from coreutils.
50386
50387         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
50388         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
50389         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
50390         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
50391         in the inet and nsl libraries.  Required on Solaris 5.7.
50392
50393 2005-10-01  Jim Meyering  <jim@meyering.net>
50394
50395         Sync from coreutils.
50396         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
50397         in the inet and nsl libraries.  Required on Solaris 5.7.
50398
50399 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
50400
50401         * lib/getdelim.c (getdelim): Remove unused variables.
50402
50403 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
50404
50405         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
50406         so that the code works even with ancient cpp.  Portability problem
50407         with GCC 2.7.2.1 reported by Thomas M.Ott.
50408
50409 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
50410
50411         * modules/regex (Depends-on): Add strcase.
50412
50413         * modules/gethostname (Licence): Change from GPL to LGPL, since
50414         gethostname.c is a trivial implementation of a standard library
50415         function.
50416         * modules/poll (License): Change from GPL to LGPL, since it's
50417         derived from LGPL code.
50418
50419 2005-09-27  Jim Meyering  <jim@meyering.net>
50420
50421         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
50422         HAVE_CONFIG_H.
50423
50424         * lib/intprops.h (signed_type_or_expr__): Define.
50425         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
50426         for unsigned types.
50427
50428 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
50429
50430         * lib/verify.h (verify_expr): Remove, replacing with:
50431         (verify_true): New macro that returns true instead of void.
50432         (verify_type__): Remove.
50433         (verify): Use verify_true rather than verify_type__.
50434
50435 2005-09-26  Bruno Haible  <bruno@clisp.org>
50436
50437         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
50438         is necessary.
50439         (lib_SOURCES): Remove mbchar.c.
50440         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
50441         (Files): Add m4/mbrtowc.m4.
50442         * modules/mbiter: Likewise.
50443         * modules/mbuiter: Likewise.
50444
50445 2005-09-26  Bruno Haible  <bruno@clisp.org>
50446
50447         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
50448         compile mbchar.c if they are not both present.
50449         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
50450         * m4/mbiter.m4 (gl_MBITER): Likewise.
50451         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
50452         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
50453         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
50454
50455 2005-09-25  Jim Meyering  <jim@meyering.net>
50456
50457         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
50458         also uses socklen_t.
50459
50460 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
50461
50462         * lib/utimens.c (ENOSYS): Define if not already defined.
50463         (futimens): Support having a null PATH if the file descriptor
50464         is nonnegative.
50465
50466         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
50467         Remove.
50468         (__attribute): Define to empty unless GCC 3.1 or later.
50469         This works around a core dump on OpenBSD 3.4, which has GCC
50470         2.95.3, which dumps core when given __attribute__(()).  It also
50471         simplifies other tests, since we really don't want to bother with
50472         worrying about which ancient version of GCC supported what.
50473         Original problem reported by Yoann Vandoorselaere, with part of
50474         the fix suggested by Derek Price.
50475
50476 2005-09-24  Jim Meyering  <jim@meyering.net>
50477
50478         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
50479         so we can once again use a positive bitfield width of 1 -- now we
50480         don't have to explain why we were using a bitfield width of 2.
50481
50482 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
50483
50484         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
50485         and similarly for the other external symbols.  Problem reported
50486         by James Gallager.
50487
50488         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
50489         bug reported by Jim Meyering.
50490
50491         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
50492         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
50493         not needed, since socklen is a prerequisite module.
50494
50495 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
50496
50497         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
50498         Problem reported by Eric Blake.
50499         (getaddrinfo): Initialize se so that it's not garbage.
50500         Redo internal storage allocation so that it doesn't make unportable
50501         assumptions about alignment.
50502         Fix a memory leak.
50503
50504         * lib/utimens.c (futimens): Use futimesat if available.
50505         Prefer it to futimes since it doesn't have the futimes bug.
50506
50507         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
50508         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
50509         Instead, declare a function that returns a pointer to an array,
50510         and use verify_type__ to declare the size of the array.
50511         Problem and germ of a solution reported by Bruno Haible.
50512         (verify_type__): Use 2, not 1, for bitfield size, to avoid
50513         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
50514
50515 2005-09-23  Jim Meyering  <jim@meyering.net>
50516
50517         Sync from coreutils.
50518         Correct build failure (socklen_t not defined) on at least
50519         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
50520         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
50521
50522 2005-09-23  Jim Meyering  <jim@meyering.net>
50523
50524         * modules/getaddrinfo (Depends-on): Add socklen.
50525
50526 2005-09-23  Bruno Haible  <bruno@clisp.org>
50527
50528         * tests/test-verify.c: New file.
50529
50530 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
50531
50532         Sync from coreutils.
50533
50534         * modules/argmatch (Depends-on): Add verify.
50535         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
50536         unistd-safer.
50537         * modules/save-cwd (Depends-on): Likewise.
50538
50539         * modules/openat (Files): Add lib/openat-die.c.
50540         (Depends-on): Remove error, exitfail.
50541         Add dirname.
50542
50543         * modules/verify: New file.
50544         * MODULES.html.sh (Diagnostics <assert.h>): New section,
50545         with "verify" module.
50546
50547 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
50548
50549         Sync from coreutils.
50550
50551         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
50552         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
50553         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
50554         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
50555         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
50556         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
50557         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
50558         Don't bother checking for string.h, stdlib.h, unistd.h.
50559         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
50560         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
50561         module's job.
50562         * m4/jm-macros.m4 (gl_MACROS): Likewise.
50563         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
50564
50565         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
50566         (gl_GETDATE): Use it.
50567
50568         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
50569
50570 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
50571
50572         Sync from coreutils.
50573
50574         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
50575         stat-time.h.
50576         * lib/argmatch.h: Include verify.h
50577         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
50578         (ARGMATCH_ASSERT): Remove; unused.
50579         * lib/canonicalize.c: Assume STDC_HEADERS.
50580         * lib/exclude.c: Include "strcase.h".
50581         * lib/regex_internal.h [!defined _LIBC]: Likewise.
50582         * lib/getusershell.c: Include stdio--.h rather than stdio.h
50583         and stdio-safer.h.
50584         (getusershell): Call fopen, not fopen_safer.
50585         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
50586         Do not include unistd-safer.h.
50587         (save_cwd): Don't call fd_safer; no longer needed
50588         now that we include fcntl--.h.
50589
50590         * lib/getdate.y (relative_time): New type.
50591         (RELATIVE_TIME_0): New constant.
50592         (parser_control): Use relative_time instead of doing it ourselves.
50593         (%union): Add new relative_time rel member.
50594         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
50595         Now typeless.
50596         (relunit, relunit_snumber): Now of type rel.
50597         (zone, rel, relunit, get_date): Adjust to above changes.
50598
50599         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
50600         Do not include unistd-safer.h.
50601         (getloadavg): Don't call fd_safer; no longer needed
50602         now that we include fcntl--.h.
50603
50604         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
50605         (make_dir_parents): Treat ENOSYS like EEXIST.
50606
50607         Improve quality of diagnostics on restore_cwd failure.
50608         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
50609         (make_dir_parents): Last arg is now int * (for errno), not bool *.
50610         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
50611         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
50612         each time through the loop.  Do not diagnose restore_cwd failure;
50613         that is the caller's job (and perhaps the caller does not care).
50614
50615         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
50616         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
50617         If the file already exists but is not a directory, don't bother
50618         to try to make its parents.
50619         Close potential file descriptor leak if we can't chdir("/") (!).
50620         Don't always return true if chdir($PWD) fails; return true only
50621         if the requested action was done successfully (except for the
50622         chdir($PWD)).
50623         Don't log final directory unless we actually made it.
50624         Refactor to avoid duplicate code to fix up permissions.
50625         Don't attempt to fix up parent permissions if chdir($PWD) fails.
50626
50627         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
50628         to make it a bit faster and (I hope) clearer.
50629         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
50630         Fix bug in formats like %2N.
50631
50632         * lib/verify.h: New file.
50633
50634 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
50635
50636         Sync from coreutils.
50637         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
50638
50639 2005-09-22  Jim Meyering  <jim@meyering.net>
50640
50641         Sync from coreutils.
50642
50643         * m4/lstat.m4 (gl_FUNC_LSTAT):
50644         Use AC_LIBSOURCES to require lstat.c and lstat.h.
50645         Remove obsolete comment.
50646         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
50647         * m4/xstrtod.m4: Likewise.
50648
50649         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
50650
50651 2005-09-22  Jim Meyering  <jim@meyering.net>
50652
50653         Sync from coreutils.
50654
50655         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
50656
50657         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
50658         the .tm_year member, since otherwise gcc-4.0 would now warn about
50659         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
50660
50661         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
50662         order to avoid an unsuppressible warning from gcc on 64-bit systems.
50663
50664         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
50665         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
50666         when run in a time zone for which daylight savings time is in effect
50667         for the starting date.
50668
50669         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
50670         stop us from restricting permissions of just-created absolute-named
50671         directories.
50672         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
50673         to restore initial working directory.
50674         * lib/mkdir-p.c (make_dir_parents): New parameter:
50675         different_working_dir, to tell caller if/when we change the working
50676         directory and are unable to return to the initial one.
50677         * lib/mkdir-p.h (make_dir_parents): Update prototype.
50678         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
50679         `return false'.  This fixes a bug introduced on 2004-07-30.
50680
50681         * lib/openat.c (fdopendir): Be sure to close the supplied
50682         file descriptor before returning.  This makes our replacement
50683         implementation a little closer to Solaris's, where fdopendir
50684         ties the file descriptor to the returned DIR* pointer.
50685         * lib/openat.c (unlinkat): New function.
50686         * lib/openat.h (unlinkat): Add prototype.
50687         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
50688         (openat_restore_fail): Rename from openat_restore_die.
50689         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
50690
50691         Provide an alternative to exiting immediately upon save_cwd or
50692         restore_cwd failure.  Now, an application can arrange e.g.,
50693         to perform a longjump in that case.
50694         * lib/openat.c: Include dirname.h.
50695         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
50696         (rpl_openat, fdopendir, fstatat): Call openat_save_die
50697         and openat_restore_die rather than calling error directly.
50698         Don't include "error.h" or "exitfail.h"; they're no longer needed.
50699
50700         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
50701         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
50702         define.
50703
50704         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
50705         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
50706                             int utc, int nanoseconds);
50707         Background:
50708         date should not have to allocate a megabyte of virtual memory to
50709         handle a format argument like +%1048575T.  When implemented with
50710         strftime, it must allocate such a buffer, use strftime to fill it
50711         in, print it, then free it.
50712         With fprintftime, it simply prints everything and exits.
50713         With no need for memory allocation, that's one fewer way to fail.
50714         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
50715         optional field width, not before, so we accept %9:z, not %:9z.
50716         (my_strftime): Be sure to use L_('x') for literals.
50717
50718         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
50719         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
50720         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
50721         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
50722         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
50723         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
50724         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
50725         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
50726         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
50727         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
50728         * lib/xgethostname.c, lib/xreadlink.c:
50729         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
50730
50731         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
50732         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
50733         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
50734         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
50735         and don't include <sys/file.h>).
50736
50737 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
50738
50739         Sync from coreutils.
50740
50741         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
50742         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
50743         [!LDAV_DONE]: Avoid unused variable warning.
50744
50745 2005-09-21  Bruno Haible  <bruno@clisp.org>
50746
50747         * lib/unicodeio.h (unicode_to_mb): New declaration.
50748
50749 2005-09-20  Derek Price  <derek@ximbiot.com>
50750
50751         * lib/getaddrinfo.c: Don't include <netdb.h> included from
50752         getaddrinfo.h.
50753
50754 2005-09-20  Bruno Haible  <bruno@clisp.org>
50755
50756         * gnulib-tool: Remove trailing slashes from the values specified for
50757         --source-base, --m4-base, --tests-base, --aux-dir.
50758         Suggested by Simon Josefsson <jas@extundo.com>.
50759
50760 2005-09-20  Bruno Haible  <bruno@clisp.org>
50761
50762         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
50763         func_modules_to_filelist, func_import, func_create_testdir): Make all
50764         sorting results locale-independent, so that gnulib-cache.m4 doesn't
50765         change when gnulib-tool is invoked in a different locale.
50766
50767 2005-09-19  Simon Josefsson  <jas@extundo.com>
50768
50769         * m4/socklen.m4: Fix typo.
50770
50771 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
50772
50773         Use a consistent style for including <config.h>.
50774         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
50775         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
50776         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
50777         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
50778         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
50779         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
50780         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
50781         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
50782         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
50783         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
50784         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
50785         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
50786         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
50787         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
50788         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
50789         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
50790         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
50791         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
50792         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
50793         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
50794         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
50795         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
50796         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
50797         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
50798         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
50799         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
50800         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
50801         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
50802         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
50803         lib/xstrtoumax.c, lib/yesno.c:
50804         Standardize inclusion of config.h.
50805         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
50806         lib/inttostr.h:  Removed inclusion of config.h from header files.
50807         * lib/inttostr.c:  Adjusted in-tree users.
50808         * lib/timespec.h: Remove superfluous warning to include config.h.
50809         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
50810         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
50811         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
50812         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
50813         config.h with HAVE_CONFIG_H.
50814
50815 2005-09-19  Jim Meyering  <jim@meyering.net>
50816
50817         * modules/pathmax (License): Change to LGPL.
50818
50819 2005-09-19  Derek Price  <derek@ximbiot.com>
50820
50821         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
50822
50823 2005-09-19  Bruno Haible  <bruno@clisp.org>
50824
50825         * gnulib-tool (import): Provide default for --tests-base.
50826
50827 2005-09-19  Bruno Haible  <bruno@clisp.org>
50828
50829         * doc/quote.texi: New file, extracted from gnulib.texi.
50830         * doc/ctime.texi: New file, extracted from gnulib.texi.
50831         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
50832         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
50833         * doc/gnulib.texi: Include them.
50834
50835 2005-09-18  Bruno Haible  <bruno@clisp.org>
50836
50837         Portability fix.
50838         * gnulib-tool (func_readlink): New function.
50839         (func_ln_if_changed): Use it.
50840
50841 2005-09-18  Bruno Haible  <bruno@clisp.org>
50842
50843         * gnulib-tool: Support --with-tests also with --import.
50844         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
50845         (func_import): Use variables $testsbase and $inctests. Emit a
50846         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
50847         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
50848         SUBDIRS += $testsdir.
50849         (func_create_testdir): Update.
50850
50851 2005-09-18  Bruno Haible  <bruno@clisp.org>
50852
50853         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
50854         instead of $dry_run.
50855         (func_cp_if_changed, func_mv_if_changed): Remove functions.
50856         (func_ln_if_changed): Don't handle dry-run here.
50857         (func_import): In dry-run mode, detect more precisely which actions
50858         would be performed, and don't use "...ing" verbs.
50859
50860 2005-09-18  Bruno Haible  <bruno@clisp.org>
50861
50862         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
50863         (func_import): Use join on two temporary files instead of three nested
50864         loops, in order to determine which files are new or old.
50865
50866 2005-09-18  Bruno Haible  <bruno@clisp.org>
50867
50868         * gnulib-tool (func_import): Comment out code that spits out the
50869         new files with --dry-run.
50870
50871 2005-09-18  Bruno Haible  <bruno@clisp.org>
50872
50873         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
50874
50875 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
50876
50877         * lib/stat-time.h: New file.
50878         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
50879         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
50880         in a different way.
50881         (timespec_cmp): New function.
50882         * lib/utimecmp.c: Include stat-time.h.
50883         (SYSCALL_RESOLUTION): Depend on whether various struct stat
50884         members exist, not on the obsolescent ST_MTIM_NSEC.
50885         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
50886
50887 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
50888
50889         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
50890
50891 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
50892
50893         * MODULES.html.sh (File system functions): Add stat-time.
50894         * modules/stat-time: New file.
50895         * modules/timespec (Files): Remove m4/st_mtim.m4; this
50896         is now done in a different way, by the stat-time module.
50897         * modules/utimecmp (Depends-on): Add stat-time.
50898
50899 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
50900
50901         * m4/st_mtim.m4: Remove.  Superseded by...
50902         * m4/stat-time.m4: New file.
50903         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
50904         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
50905
50906 2005-09-15  Derek Price  <derek@ximbiot.com>
50907
50908         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
50909
50910 2005-09-15  Derek Price  <derek@ximbiot.com>
50911
50912         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
50913         * lib/regex_internal.c: Ditto, using this...
50914         (__GNUC_PREREQ): ...new macro.
50915         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
50916         using...
50917         (__GNUC_PREREQ): ...this new macro.
50918
50919         * lib/strstr.h: Include string.h. Define strstr as a macro here.
50920
50921 2005-09-15  Derek Price  <derek@ximbiot.com>
50922             Paul Eggert  <eggert@cs.ucla.edu>
50923
50924         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
50925         changes, consolidating in...
50926         * lib/regex_internal.h: ...this file.
50927
50928 2005-09-13  Jim Meyering  <jim@meyering.net>
50929
50930         * lib/canon-host.c: Filter through gnu indent and reword comments
50931         slightly.
50932         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
50933
50934 2005-09-13  Derek Price  <derek@ximbiot.com>
50935
50936         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
50937         failure.
50938         Reported by Jim Meyering  <jim@meyering.net>.
50939
50940 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
50941
50942         * lib/base64.c: Typo.
50943         (base64_encode): Put b64str in initialized data section.
50944
50945 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
50946
50947         Merge glibc and coreutils changes into gnulib, plus a few
50948         extra fixes.
50949         * lib/md5.c: Use #error rather than a string.
50950         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
50951         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
50952         (__attribute__): Define to empty for non recent-GCC.
50953         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
50954         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
50955         Renamed from their non-__ counterparts, with new macros replacing
50956         them if not _LIBC.  Add __THROW attribute.
50957         (rol): Remove.
50958         (struct md5_ctx): Align buffer if using GCC.
50959         * lib/sha1.h (struct sha1_ctx): Likewise.
50960         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
50961         The old name was backwards.
50962         (NOTSWAP): Remove; not used.
50963         (rol): New macro, moved here from md5.h.
50964         (sha1_process_block): Remove a FIXME that doesn't make sense.
50965
50966 2005-09-12  Derek Price  <derek@ximbiot.com>
50967
50968         Return usable errors from canon-host.
50969         * lib/canon-host.h: New file.
50970         * lib/canon-host.c (canon_host): Wrap...
50971         (canon_host_r): ...this new function, which now relies exclusively on
50972         getaddrinfo.
50973         (ch_strerror): New function.
50974         (last_cherror): New global.
50975         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
50976         interface.
50977         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
50978         void *.
50979         (freeaddrinfo): Free ai->ai_canonname when set.
50980
50981 2005-09-12  Derek Price  <derek@ximbiot.com>
50982
50983         Make canon-host require getaddrinfo.
50984         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
50985         AC_LIBSOURCE canon-host.h.  Call...
50986         (gl_PREREQ_CANON_HOST): ...this new function, which requires
50987         gl_GETADDRINFO.
50988         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
50989
50990 2005-09-12  Derek Price  <derek@ximbiot.com>
50991
50992         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
50993         LGPL.
50994         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
50995
50996 2005-09-12  Derek Price  <derek@ximbiot.com>
50997
50998         * lib/gai_strerror.c: Include config.h when available.  Include
50999         getaddrinfo.h before other headers to test interface.
51000         Reported by Larry Jones <lawrence.jones@ugs.com>.
51001
51002 2005-09-12  Derek Price  <derek@ximbiot.com>
51003             Paul Eggert  <eggert@cs.ucla.edu>
51004
51005         * modules/glob (Files): Add glob-libc.h.
51006
51007 2005-09-12  Derek Price  <derek@ximbiot.com>
51008             Paul Eggert  <eggert@cs.ucla.edu>
51009
51010         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
51011         glob_.h, glob-libc.h.
51012         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
51013
51014 2005-09-12  Derek Price  <derek@ximbiot.com>
51015             Paul Eggert  <eggert@cs.ucla.edu>
51016
51017         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
51018         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
51019         protecting things that should be done only in gnulib contexts.
51020         * lib/glob_.h: New file, containing only the glob things needed for
51021         gnulib.
51022         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
51023         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
51024         (glob, globfree, glob_pattern_p): Now defined simply in terms of
51025         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
51026         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
51027         and to respect the namespace rules better.
51028
51029 2005-09-08  Simon Josefsson  <jas@extundo.com>
51030
51031         * modules/socklen: New file.
51032
51033 2005-09-08  Simon Josefsson  <jas@extundo.com>
51034
51035         * m4/socklen.m4: New file.
51036
51037 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
51038
51039         * modules/utimens (Files): Add m4/utimbuf.m4, since
51040         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
51041         Reported by Sergey Poznyakoff.
51042
51043 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
51044
51045         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
51046         definitions, since that's the preferred style in glibc.
51047         Fix a minor spacing issue, and update copyright notice to match
51048         glibc's.
51049
51050 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
51051
51052         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
51053
51054 2005-09-06  Simon Josefsson  <jas@extundo.com>
51055
51056         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
51057         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
51058
51059 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
51060
51061         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
51062         warning.
51063
51064 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
51065
51066         * config/srclist.txt: Add glibc bug 1302.
51067
51068 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
51069
51070         Change bitset word type from unsigned int to unsigned long int,
51071         as this has better performance on typical 64-bit hosts.
51072         Port bitset code to hosts with unusual word sizes.
51073         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
51074         (build_collating_symbol):
51075         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
51076         argument is a bitset.  This is merely a style issue, but it makes
51077         it clearer that an entire array is expected.
51078         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
51079         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
51080         Port to the case where bitset_word is not the same as unsigned int.
51081         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
51082         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
51083         Likewise.
51084         * lib/regexec.c (check_dst_limits_calc_pos_1,
51085         check_subexp_matching_top):
51086         (build_trtable, group_nodes_into_DFAstates):
51087         Likewise.
51088         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
51089         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
51090         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
51091         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
51092         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
51093         * lib/regcomp.c (optimize_subexps, lower_subexp):
51094         Work even if bitset_word has holes in its bitwise representation.
51095         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
51096         * lib/regexec.c (check_dst_limits_calc_pos_1,
51097         check_subexp_matching_top):
51098         Likewise.
51099         * lib/regex_internal.c (re_string_reconstruct):
51100         Don't assume UCHAR_MAX == 255.
51101         * lib/regex_internal.h (bitset_set_all): Likewise.
51102         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
51103         All uses changed.
51104         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
51105         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
51106         All uses changed.
51107         (BITSET_WORD_MAX): New macro.
51108         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
51109         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
51110         (bitset_empty, bitset_copy):
51111         Prefer sizeof (bitset) to multiplying it out ourselves.
51112         (bitset_not_merge): Remove; unused.
51113         (bitset_contain): Return bool, not unsigned int with one bit on.
51114         All callers changed.
51115         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
51116         alignment than re_node_set; do this by defining a new internal
51117         type struct dests_alloc and using it to allocate memory.
51118
51119 2005-09-05  Bruno Haible  <bruno@clisp.org>
51120
51121         * gnulib-tool (func_import): Fix comparison in handling of symbolic
51122         links.
51123
51124 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
51125
51126         * modules/size_max (Makefile.am): Add size_max.h
51127
51128 2005-09-04  Derek Price  <derek@ximbiot.com>
51129
51130         * gnulib-tool (func_import): Fix reversed $symbolic logic.
51131
51132 2005-09-03  Simon Josefsson  <jas@extundo.com>
51133
51134         * gnulib-tool: Fix typo.
51135
51136 2005-09-03  Simon Josefsson  <jas@extundo.com>
51137
51138         * config/srclist.txt: Add glibc bug 1293.
51139
51140 2005-09-03  Derek Price  <derek@ximbiot.com>
51141
51142         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
51143         From Larry Jones <lawrence.jones@ugs.com>.
51144
51145 2005-09-02  Simon Josefsson  <jas@extundo.com>
51146
51147         * modules/socklen: New file.
51148
51149 2005-09-02  Simon Josefsson  <jas@extundo.com>
51150
51151         * modules/havelib: New module.
51152
51153         * modules/gettext, modules/iconv, modules/lock, modules/readline:
51154         Use havelib.
51155
51156 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
51157
51158         Check for arithmetic overflow when calculating sizes, to prevent
51159         some buffer-overflow issues.  These patches are conservative, in the
51160         sense that when I couldn't determine whether an overflow was possible,
51161         I inserted a run-time check.
51162         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
51163         macros.
51164         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
51165         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
51166         (re_xnrealloc, re_x2nrealloc): New inline functions.
51167         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
51168         parse_bracket_exp):
51169         (build_equiv_class, build_charclass): Check for arithmetic overflow
51170         in size expression calculations.
51171         * lib/regex_internal.c (re_string_realloc_buffers):
51172         (build_wcs_upper_buffer, re_node_set_add_intersect):
51173         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
51174         (re_dfa_add_node, register_state): Likewise.
51175         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
51176         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
51177         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
51178         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
51179
51180 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
51181
51182         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
51183         m4/ulonglong.m4.  Problem reported by Martin Lambers.
51184
51185 2005-09-02  Bruno Haible  <bruno@clisp.org>
51186
51187         Support for lib vs. lib64 distinction on biarch platforms.
51188         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
51189         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
51190         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
51191
51192 2005-09-02  Bruno Haible  <bruno@clisp.org>
51193
51194         * gnulib-tool (import): In the other first-use case, provide defaults
51195         as well.
51196
51197 2005-09-02  Bruno Haible  <bruno@clisp.org>
51198
51199         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
51200         patches not yet found in the latest gettext release.
51201
51202 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
51203
51204         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
51205         to avoid a collision with bits/local_lim.h in glibc.
51206         All uses changed.  Problem reported by Dmitry V. Levin in
51207         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
51208
51209         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
51210         bugs in int versus size_t comparisons.
51211         (re_string_context_at): Fix bug where the code assumed that
51212         Idx is signed.
51213
51214         Use bool where appropriate.
51215         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
51216         All callers changed.
51217         (calc_eclosure_iter): Likewise, for ROOT arg.
51218         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
51219         (build_charclass_op): Likewise, for NON_MATCH arg.
51220         * lib/regex_internal.c (re_string_allocate, re_string_construct):
51221         (re_string_construct_common): Likewise, for ICASE arg.
51222         * lib/regexec.c (re_search_2_stub, re_search_stub):
51223         Likewise, for RET_LEN arg.
51224         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
51225         (set_regs): Likewise, for FL_BACKTRACK arg.
51226         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
51227         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
51228         (calc_eclosure_iter, parse_bracket_exp):
51229         Use bool for internal variables that are booleans.
51230         * lib/regexec.c (re_search_internal, check_matching,
51231         proceed_next_node):
51232         (set_regs, build_sifted_states, sift_states_bkref):
51233         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
51234         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
51235         (find_collation_sequence_value):
51236         Likewise.
51237         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
51238         (re_node_set_compare):
51239         Return bool, not int. All callers changed.
51240         * lib/regexec.c (check_halt_node_context, check_dst_limits):
51241         (build_trtable, check_node_accept): Likewise.
51242         * lib/regex_internal.h: Include stdbool.h.
51243
51244         Fix bugs uncovered when converting to bool.
51245         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
51246         failure instead of charging ahead blindly.
51247         * lib/regex_internal.c (register_state): Likewise.
51248         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
51249         for freeing internal storage.
51250         (group_nodes_into_DFA_states): Use unsigned int, not int, for
51251         bitset pieces used as boolean, to avoid undefined behavior
51252         on hosts that do int overflow checking.
51253
51254 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
51255
51256         * config/srclist.txt: Add glibc bugs 1285-1287.
51257
51258 2005-09-01  Jim Meyering  <jim@meyering.net>
51259
51260         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
51261         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
51262         Require gl_STAT_MACROS, too.
51263
51264 2005-09-01  Bruno Haible  <bruno@clisp.org>
51265
51266         * gnulib-tool (import): In the first-use case, provide defaults.
51267
51268 2005-09-01  Bruno Haible  <bruno@clisp.org>
51269
51270         * gnulib-tool (func_import): Remove the .tmp files.
51271
51272 2005-09-01  Bruno Haible  <bruno@clisp.org>
51273
51274         * gnulib-tool (func_import): Fix handling of symbolic links.
51275
51276 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
51277
51278         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
51279         old glibc regex code mishandles strings longer than 2**31 bytes.
51280         This patch fixes this when the regex code is used in gnulib
51281         (i.e., outside glibc).
51282
51283         This patch should not affect the use of the regex code inside
51284         glibc.  No doubt this problem also needs to be handled for glibc
51285         as well, but the result will be an incompatible change to the
51286         glibc ABI, and the old ABI will have to be supported too.  That
51287         can be the the subject for another patch.
51288
51289         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
51290         governing whether the rest of this patch is active.  By default,
51291         the macro is disabled and the patch has no effect.
51292         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
51293         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
51294         (struct re_pattern_buffer, re_search, re_search_2, re_match):
51295         (re_match_2, re_set_registers): Use the new types.
51296         * lib/regex_internal.h (Idx, re_hashval_t): New types.
51297         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
51298         New macros.
51299         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
51300         (re_string_context_at, bin_tree_t, re_dfastate_t):
51301         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
51302         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
51303         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
51304         (re_string_char_size_at, re_string_wchar_at):
51305         (re_string_elem_size_at):
51306         Use the new types and macros to port to 64-bit hosts.
51307         Use unsigned types for internal values, so that the code
51308         mostly works even for arrays larger than SSIZE_MAX.
51309         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
51310         (search_duplicated_node, calc_eclosure_iter, fetch_number):
51311         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
51312         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
51313         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
51314         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
51315         (calc_inveclosure, parse_dup_op, build_range_exp):
51316         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
51317         (fetch_number, create_token_tree, mark_opt_subexp):
51318         Likewise.
51319         * lib/regex_internal.c (re_string_construct_common,
51320         create_ci_newstate):
51321         (create_cd_newstate, re_string_allocate, re_string_construct):
51322         (re_string_realloc_buffers, build_wcs_upper_buffer):
51323         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
51324         (re_string_reconstruct, re_string_peek_byte_case):
51325         (re_string_fetch_byte_case, re_string_context_at):
51326         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
51327         (re_node_set_init_copy, re_node_set_add_intersect):
51328         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
51329         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
51330         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
51331         (re_acquire_state, re_acquire_state_context, register_state):
51332         Likewise.
51333         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
51334         search_cur_bkref_entry):
51335         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
51336         (re_search_internal, re_search_2_stub, re_search_stub)
51337         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
51338         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
51339         (update_cur_sifted_state, check_dst_limits):
51340         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
51341         (check_subexp_limits, sift_states_bkref, merge_state_array):
51342         (check_subexp_matching_top, get_subexp, get_subexp_sub):
51343         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
51344         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
51345         (expand_bkref_cache, check_node_accept_bytes):
51346         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
51347         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
51348         (acquire_init_state_context, check_halt_node_context):
51349         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
51350         (sift_states_backward, clean_state_log_if_needed):
51351         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
51352         (find_recover_state, transit_state_sb, transit_state_mb):
51353         (transit_state_bkref, build_trtable, match_ctx_clean):
51354         Likewise.
51355         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
51356         to work around an assumption that REG_MISSING is negative.
51357
51358         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
51359         (seek_collating_symbol_entry) [defined _LIBC]:
51360         (lookup_collation_sequence_value) [defined _LIBC]:
51361         (build_range_exp, build_collating_symbol) [defined _LIBC]:
51362         Use prototypes rather than old-style function definitions.
51363         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
51364         (transit_state_sb) [0]:
51365         (find_collation_sequence_value) [defined _LIBC]: Likewise.
51366
51367         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
51368         rm_eo.
51369
51370         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
51371         (optimize_subexps, lower_subexp):
51372         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
51373         since the signed shift might overflow.  Use 1u<<31 instead.
51374         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
51375         Likewise.
51376         * lib/regexec.c (check_dst_limits_calc_pos_1,
51377         check_subexp_matching_top): Likewise.
51378
51379         * lib/regcomp.c (optimize_subexps, lower_subexp):
51380         Use CHAR_BIT rather than 8, for clarity.
51381         * lib/regexec.c (check_dst_limits_calc_pos_1):
51382         (check_subexp_matching_top): Likewise.
51383         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
51384         have to worry about portability issues when shifting it left.
51385         Remove no-longer-needed test for table_size > 0.
51386         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
51387         in a word, as the resulting behavior is undefined.
51388         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
51389         in one case, a <= should have been an <, and in another case the
51390         whole test was missing.
51391         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
51392         the standard name CHAR_BIT.
51393         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
51394         this is not true on one's complement and signed-magnitude hosts.
51395
51396         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
51397         next_last_offset.
51398         (struct re_dfa_t): Remove unused member states_alloc.
51399         * lib/regcomp.c (init_dfa): Don't initialize unused members.
51400
51401 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
51402
51403         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
51404         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
51405         and large-file glibc and in 32-bit large-file Solaris.
51406
51407 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
51408
51409         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
51410         lengths fit in regoff_t; this isn't true if regoff_t is the same
51411         width as size_t.
51412         * lib/regex.c (re_search_internal): 5th arg is LAST_START
51413         (= START + RANGE) instead of RANGE.  This avoids overflow
51414         problems when regoff_t is the same width as size_t.
51415         All callers changed.
51416         (re_search_2_stub): Check for overflow when adding the
51417         sizes of the two strings.
51418         (re_search_stub): Check for overflow when adding START
51419         to RANGE; if it occurs, substitute the extreme value.
51420
51421 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
51422
51423         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
51424
51425 2005-08-31  Jim Meyering  <jim@meyering.net>
51426
51427         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
51428         a pointer-to-const.
51429         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
51430         (register_state): Likewise.
51431         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
51432         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
51433         (group_nodes_into_DFAstates): Likewise.
51434
51435 2005-08-31  Jim Meyering  <jim@meyering.net>
51436
51437         * check-module: Add a FIXME comment.
51438
51439 2005-08-31  Eric Blake  <ebb9@byu.net>
51440
51441         * modules/unistd-safer (Files): Add unistd--.h.
51442         * modules/stdio-safer (Files): Add stdio--.h.
51443
51444 2005-08-31  Derek Price  <derek@ximbiot.com>
51445
51446         * lib/getdelim.c (getdelim): Return EOF on EOF.
51447         Reported by Larry Jones <lawrence.jones@ugs.com>.
51448
51449 2005-08-31  Bruno Haible  <bruno@clisp.org>
51450
51451         Avoid unnecessary diffs in the generated lib/Makefile.am.
51452         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
51453         the generated files.
51454         (func_import): Don't set cmd.
51455
51456 2005-08-31  Bruno Haible  <bruno@clisp.org>
51457
51458         * lib/strstr.c: Include <stddef.h>, for NULL.
51459         * lib/strcasestr.c: Likewise.
51460         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
51461
51462 2005-08-31  Bruno Haible  <bruno@clisp.org>
51463
51464         * gnulib-tool: New option --macro-prefix.
51465         (func_import): Use macro_prefix.
51466         (import): Handle option --macro-prefix.
51467
51468 2005-08-31  Bruno Haible  <bruno@clisp.org>
51469
51470         * gnulib-tool (import): Rename most ac_* variables to cached_*.
51471         Also use new variables cached_lgpl, cached_libtool.
51472
51473 2005-08-31  Bruno Haible  <bruno@clisp.org>
51474
51475         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
51476         always instantiating them.
51477
51478 2005-08-31  Bruno Haible  <bruno@clisp.org>
51479
51480         * gnulib-tool (func_import): Read the previous cached settings
51481         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
51482         earlier added by gnulib but are now dropped. Warn when a gnulib file
51483         overwrites a non-gnulib file.
51484
51485 2005-08-31  Bruno Haible  <bruno@clisp.org>
51486
51487         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
51488         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
51489         projects that don't keep autogenerated files in CVS. Put into
51490         actioncmd only the specified modules, not the transitive closure.
51491
51492 2005-08-31  Bruno Haible  <bruno@clisp.org>
51493
51494         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
51495         Create directories that shall be filled.
51496         (import): Don't look for gl_* macros in configure.ac. Recurse across
51497         all directories containing a gnulib-cache.m4 files, if meaningful.
51498
51499 2005-08-31  Bruno Haible  <bruno@clisp.org>
51500
51501         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
51502         (import): Set seen_libtool when we see gl_LIBTOOL.
51503
51504 2005-08-31  Bruno Haible  <bruno@clisp.org>
51505
51506         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
51507         declaration macro definitions from generated gnulib.m4.
51508
51509 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
51510
51511         * lib/iconvme.h: Add prototype for iconv_alloc.
51512
51513 2005-08-29  Simon Josefsson  <jas@extundo.com>
51514
51515         * lib/iconvme.c: Fix errno.
51516
51517 2005-08-29  Bruno Haible  <bruno@clisp.org>
51518
51519         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
51520         that it works when the directory contains spaces.
51521
51522 2005-08-29  Bruno Haible  <bruno@clisp.org>
51523
51524         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
51525
51526 2005-08-29  Bruno Haible  <bruno@clisp.org>
51527
51528         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
51529         Emit more advice.
51530
51531 2005-08-29  Bruno Haible  <bruno@clisp.org>
51532         and Stepan Kasal  <kasal@ucw.cz>
51533
51534         * check-module: If more parameters are given, check each of them
51535         separately; add more exceptions, as noted by Jim Meyering.
51536         (check_module): New procedure.
51537         (%exempt_header): Now contains all exceptions.
51538
51539 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
51540
51541         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
51542
51543 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
51544
51545         * lib/iconvme.c: Split iconv_string into iconv_alloc.
51546
51547 2005-08-28  Bruno Haible  <bruno@clisp.org>
51548
51549         * m4/gnulib-tool.m4: New file.
51550
51551 2005-08-27  Jim Meyering  <jim@meyering.net>
51552
51553         * modules/unistd-safer (Files): Add pipe-safer.c.
51554         * modules/fcntl-safer (Files): Add creat-safer.c.
51555
51556 2005-08-27  Jim Meyering  <jim@meyering.net>
51557
51558         * m4/stdlib-safer.m4: New file.  From coreutils.
51559         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
51560         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
51561         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
51562         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
51563         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
51564
51565 2005-08-27  Jim Meyering  <jim@meyering.net>
51566
51567         * lib/fopen-safer.c: Merge minor changes from coreutils.
51568         * lib/dup-safer.c: Likewise.
51569         * lib/fd-safer.c: Likewise.
51570
51571         Merge from coreutils.
51572         * lib/stdio--.h: New file.
51573         * lib/stdlib--.h: New file.
51574         * lib/mkstemp-safer.c: New file.
51575
51576         GNU tar needs these.
51577         * lib/pipe-safer.c: New file.
51578         * lib/creat-safer.c: New file.
51579         * lib/fcntl--.h (creat): Define to creat_safer.
51580         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
51581         * lib/unistd--.h (pipe): Define to pipe_safer.
51582         * lib/unistd-safer.h: Declare pipe_safer.
51583
51584 2005-08-26  Simon Josefsson  <jas@extundo.com>
51585
51586         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
51587         Haible <bruno@clisp.org>.
51588
51589 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
51590
51591         * lib/regex_internal.h: Remove all references to
51592         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
51593         or better.
51594         (bitset_not, bitset_merge, bitset_not_merge):
51595         (bitset_mask, re_string_allocate, re_string_construct):
51596         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
51597         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
51598         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
51599         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
51600         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
51601         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
51602         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
51603         (re_acquire_state_context):
51604         Remove unnecessary forward decls.
51605         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
51606         Put __attribute at function definition,
51607         now that the function decl has been removed.
51608         * lib/regex_internal.c (re_string_peek_byte_case):
51609         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
51610         Likewise.
51611
51612 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
51613
51614         * m4/regex.m4: Add AC_PREREQ(2.50).
51615         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
51616
51617 2005-08-25  Simon Josefsson  <jas@extundo.com>
51618
51619         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
51620         __fsetlocking.
51621
51622 2005-08-25  Simon Josefsson  <jas@extundo.com>
51623
51624         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
51625         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
51626         GLIBC specific code.
51627
51628 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
51629
51630         Make regex safe for g++.  This fixes one real bug (an "err"
51631         that should have been "*err").  g++ problem reported by
51632         Sam Steingold.
51633         * lib/regex_internal.h (re_calloc): New macro, consistent with
51634         re_malloc etc.  All callers of calloc changed to use re_calloc.
51635         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
51636         not int.  All callers changed.
51637         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
51638         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
51639         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
51640         (find_recover_state): Change "err" to "*err"; this fixes what
51641         appears to be a real bug.
51642         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
51643         versus int.
51644
51645 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
51646
51647         * modules/regex (Depends-on): Add malloc, since the code
51648         assumes that !malloc(0) means failure.
51649
51650 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
51651
51652         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
51653
51654         alloca modernization/simplification for regex.
51655         * lib/regex.c: Remove portability cruft for alloca.  This no longer
51656         needs to be at the start of the file, and can be moved into
51657         regex_internal.h and simplified.
51658         * lib/regex_internal.h: Include <alloca.h>.
51659         (__libc_use_alloca) [!defined _LIBC]: New macro.
51660         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
51661         now works outside glibc.
51662
51663 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
51664
51665         * config/srclist.txt: Add glibc bugs 1241, 1245.
51666
51667 2005-08-25  Jim Meyering  <jim@meyering.net>
51668
51669         * lib/open-safer.c: Include <config.h>.
51670         Otherwise, we'd lose LARGEFILE support in any file using
51671         e.g. "fcntl--.h"
51672
51673 2005-08-25  Bruno Haible  <bruno@clisp.org>
51674
51675         * m4/minmax.m4: Require autoconf 2.52.
51676         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
51677         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
51678         alternatives of translit over the alphabet.
51679         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
51680
51681 2005-08-24  Simon Josefsson  <jas@extundo.com>
51682
51683         * tests/test-getpass.c: New file.
51684
51685 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
51686
51687         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
51688         for GNU regex features.
51689
51690 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
51691
51692         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
51693         * lib/regex.h (regerror): Likewise.
51694
51695         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
51696         requires this.  (The code never needed it.)
51697
51698         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
51699         All uses of recently-renamed identifiers changed to use the new,
51700         POSIX-compliant names.  The code will build and run just fine
51701         without these changes, but it's better to eat our own dog food
51702         and use the standard-conforming names.
51703
51704         * lib/regex.h: Fix a multitude of POSIX name space violations.
51705         These changes have an effect only for programs that define
51706         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
51707         do not change anything for programs compiled in the normal way.
51708         Also, there is no effect on the ABI.
51709
51710         (_REGEX_SOURCE): New macro.
51711         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
51712         defined and _GNU_SOURCE is not; this fixes a name space violation.
51713
51714         Rename the following macros to obey POSIX requirements.
51715         The old names are still visible as macros if _REGEX_SOURCE is defined.
51716         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
51717         RE_BACKSLASH_ESCAPE_IN_LISTS.
51718         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
51719         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
51720         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
51721         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
51722         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
51723         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
51724         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
51725         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
51726         (REG_INTERVALS): renamed from RE_INTERVALS.
51727         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
51728         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
51729         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
51730         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
51731         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
51732         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
51733         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
51734         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
51735         RE_UNMATCHED_RIGHT_PAREN_ORD.
51736         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
51737         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
51738         (REG_DEBUG): renamed from RE_DEBUG.
51739         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
51740         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
51741         unusual, since we can't clash with the POSIX REG_ICASE.
51742         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
51743         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
51744         (REG_NO_SUB): renamed from RE_NO_SUB.
51745         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
51746         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
51747         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
51748         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
51749         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
51750         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
51751         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
51752         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
51753         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
51754         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
51755         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
51756         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
51757         RE_SYNTAX_POSIX_MINIMAL_BASIC.
51758         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
51759         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
51760         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
51761         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
51762         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
51763         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
51764         (REG_FIXED): Renamed from REGS_FIXED.
51765         (REG_NREGS): Renamed from RE_NREGS.
51766
51767         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
51768         of other REG_* macros, since POSIX says the user is allowed to
51769         #undef these macros selectively.
51770
51771         (reg_errcode_t): Update comment stating what other tables need
51772         to be consistent.
51773
51774         Rename the following enum values to obey POSIX requirements.
51775         The old names are still visible as macros.
51776         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
51777         is not defined, since GNU is supposed to be a superset of POSIX as
51778         much as possible, and since we want reg_errcode_t to be a signed
51779         type for implementation consistency.
51780         (_REG_NOERROR): Renamed from REG_NOERROR.
51781         (_REG_NOMATCH): Renamed from REG_NOMATCH.
51782         (_REG_BADPAT): Renamed from REG_BADPAT.
51783         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
51784         (_REG_ECTYPE): Renamed from REG_ECTYPE.
51785         (_REG_EESCAPE): Renamed from REG_EESCAPE.
51786         (_REG_ESUBREG): Renamed from REG_ESUBREG.
51787         (_REG_EBRACK): Renamed from REG_EBRACK.
51788         (_REG_EPAREN): Renamed from REG_EPAREN.
51789         (_REG_EBRACE): Renamed from REG_EBRACE.
51790         (_REG_BADBR): Renamed from REG_BADBR.
51791         (_REG_ERANGE): Renamed from REG_ERANGE.
51792         (_REG_ESPACE): Renamed from REG_ESPACE.
51793         (_REG_BADRPT): Renamed from REG_BADRPT.
51794         (_REG_EEND): Renamed from REG_EEND.
51795         (_REG_ESIZE): Renamed from REG_ESIZE.
51796         (_REG_ERPAREN): Renamed from REG_ERPAREN.
51797         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
51798         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
51799         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
51800         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
51801
51802         (_REG_RE_NAME, _REG_RM_NAME): New macros.
51803         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
51804         changed.  But support the old name if the new one is not defined
51805         and if _REGEX_SOURCE.
51806
51807         Change the following member names in struct re_pattern_buffer.
51808         The old names are still supported if !_REGEX_SOURCE.
51809         The new names are always supported, regardless of _REGEX_SOURCE.
51810         (re_buffer): Renamed from buffer.
51811         (re_allocated): Renamed from allocated.
51812         (re_used): Renamed from used.
51813         (re_syntax): Renamed from syntax.
51814         (re_fastmap): Renamed from fastmap.
51815         (re_translate): Renamed from translate.
51816         (re_can_be_null): Renamed from can_be_null.
51817         (re_regs_allocated): Renamed from regs_allocated.
51818         (re_fastmap_accurate): Renamed from fastmap_accurate.
51819         (re_no_sub): Renamed from no_sub.
51820         (re_not_bol): Renamed from not_bol.
51821         (re_not_eol): Renamed from not_eol.
51822         (re_newline_anchor): Renamed from newline_anchor.
51823
51824         Change the following member names in struct re_registers.
51825         The old names are still supported if !_REGEX_SOURCE.
51826         The new names are always supported, regardless of _REGEX_SOURCE.
51827         (rm_num_regs): Renamed from num_regs.
51828         (rm_start): Renamed from start.
51829         (rm_end): Renamed from end.
51830
51831         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
51832         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
51833         Prepend __ to parameter names.
51834
51835         Undo yesterday's changes.
51836
51837 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
51838
51839         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
51840         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
51841         lib/regex.c.
51842
51843 2005-08-24  Jim Meyering  <jim@meyering.net>
51844
51845         Sync from coreutils.
51846         * m4/fcntl-safer.m4: New file.
51847
51848         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
51849         and object files for this module.
51850
51851 2005-08-24  Jim Meyering  <jim@meyering.net>
51852
51853         Sync from coreutils.
51854         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
51855
51856 2005-08-24  Jim Meyering  <jim@meyering.net>
51857
51858         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
51859         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
51860
51861 2005-08-24  Jim Meyering  <jim@meyering.net>
51862
51863         * modules/fcntl-safer: New module.
51864         * modules/fts (Depends-on): Add fcntl-safer.
51865         * MODULES.html.sh (File descriptor based Input/Output):
51866         Add fcntl-safer.
51867
51868 2005-08-24  Bruno Haible  <bruno@clisp.org>
51869
51870         Support for unit test modules.
51871         * modules/README: Mention tests modules.
51872         * modules/TEMPLATE-TESTS: New file.
51873         * gnulib-tool: New options --extract-tests-module, --with-tests and
51874         --tests-base (unused for the moment).
51875         (testsbase, inctests): New variables.
51876         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
51877         (func_verify_module): Exclude TEMPLATE-TESTS.
51878         (func_verify_nontests_module, func_verify_tests_module): New functions.
51879         (func_get_dependencies): Add implicit dependency for tests modules.
51880         (func_get_tests_module): New function.
51881         (func_modules_transitive_closure): When --with-tests was specified,
51882         include the unit tests as well, unless explicitly avoided.
51883         (func_emit_lib_Makefile_am): Ignore the tests modules here.
51884         (func_emit_tests_Makefile_am): New function.
51885         (func_create_testdir): When --with-tests was specified, emit a
51886         tests/ directory.
51887         * MODULES.html.sh (Future developments): Update.
51888
51889 2005-08-24  Bruno Haible  <bruno@clisp.org>
51890
51891         * modules/tls-tests: New file.
51892         * tests/test-tls.c: New file, from GNU gettext.
51893
51894 2005-08-24  Bruno Haible  <bruno@clisp.org>
51895
51896         * modules/lock-tests: New file.
51897         * tests/test-lock.c: New file, from GNU gettext.
51898
51899 2005-08-24  Bruno Haible  <bruno@clisp.org>
51900
51901         * lib/lock.h: Add multiple inclusion guard.
51902         * lib/tls.h: Add multiple inclusion guard.
51903
51904 2005-08-24  Bruno Haible  <bruno@clisp.org>
51905
51906         * gnulib-tool: Add support for the --aux-dir option to
51907         --create-testdir, --create-megatestdir, --test, --megatest.
51908         (func_create_testdir, func_create_megatestdir): Optionally emit a
51909         AC_CONFIG_AUX_DIR directive.
51910         (create-testdir, create-megatestdir, test, megatest): Provide a
51911         default value for $auxdir.
51912
51913 2005-08-24  Bruno Haible  <bruno@clisp.org>
51914
51915         * gnulib-tool (import): Use compound statement instead of subshell
51916         where possible.
51917
51918 2005-08-24  Bruno Haible  <bruno@clisp.org>
51919
51920         * gnulib-tool (import): Change --aux-dir default to "build-aux".
51921
51922 2005-08-24  Bruno Haible  <bruno@clisp.org>
51923
51924         * gnulib-tool (func_version): Update.
51925
51926 2005-08-24  Bruno Haible  <bruno@clisp.org>
51927
51928         * gnulib-tool (func_import, func_create_testdir,
51929         func_create_megatestdir): Quote all autoconf macro arguments.
51930
51931 2005-08-24  Bruno Haible  <bruno@clisp.org>
51932
51933         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
51934         option --force, because --force causes the aclocal.m4 of each
51935         subdirectory to be newer than the corresponding config.h.in.
51936
51937 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
51938
51939         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
51940         All contents moved to gl_REGEX.
51941         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
51942         assume that it does.
51943
51944 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
51945
51946         * lib/regex.h (REG_NOSYS)
51947         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
51948         Define, since POSIX requires it as of 2001.
51949         (_REG_ENOSYS)
51950         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
51951         New private symbol, used to keep the enum signed in all cases.
51952         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
51953         Youngman in
51954         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
51955
51956         * lib/regex_internal.c (re_string_skip_chars, register_state):
51957         (calc_state_hash):
51958         Remove forward decls; no longer needed now that we use prototypes.
51959         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
51960         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
51961         (clean_state_log_if_needed): Likewise.
51962
51963 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
51964
51965         * config/srclist.txt: Add glibc bugs 1231-1233.
51966
51967 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
51968
51969         Fix problems reported by Sam Steingold in
51970         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
51971         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
51972         assumed that reg_errcode_t is a signed type, which is not
51973         necessarily true if _XOPEN_SOURCE is not defined.
51974         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
51975         since some compilers warn about it otherwise.
51976
51977 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
51978
51979         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
51980         (init_word_char, create_initial_state, duplicate_node_closure):
51981         (fetch_token, peek_token_bracket, build_range_exp):
51982         (build_collating_symbol): Remove forward decls; no longer needed
51983         now that we use prototypes.
51984
51985         * lib/regcomp.c:
51986         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
51987         (re_compile_fastmap_iter, regcomp, regerror, regfree):
51988         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
51989         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
51990         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
51991         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
51992         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
51993         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
51994         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
51995         (build_range_exp, build_collating_symbol, parse_bracket_exp):
51996         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
51997         (build_charclass, build_charclass_op, fetch_number, create_tree):
51998         (create_token_tree, mark_opt_subexp, duplicate_tree):
51999         Use prototypes rather than old-style definitions.
52000
52001         * lib/regex_internal.c:
52002         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
52003         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
52004         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
52005         (re_string_reconstruct, re_string_peek_byte_case):
52006         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
52007         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
52008         (re_node_set_init_copy, re_node_set_add_intersect):
52009         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
52010         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
52011         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
52012         (re_acquire_state, re_acquire_state_context, register_state):
52013         (create_ci_newstate, create_cd_newstate, free_state):
52014         Likewise.
52015         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
52016         re_search_2):
52017         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
52018         (re_search_internal, prune_impossible_nodes):
52019         (acquire_init_state_context, check_matching, static):
52020         (check_halt_node_context, check_halt_state_context, proceed_next_node):
52021         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
52022         (update_regs, sift_states_backward, build_sifted_states):
52023         (clean_state_log_if_needed, merge_state_array):
52024         (update_cur_sifted_state, add_epsilon_src_nodes):
52025         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
52026         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
52027         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
52028         (find_recover_state, check_subexp_matching_top, transit_state_mb):
52029         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
52030         (check_arrival, check_arrival_add_next_nodes):
52031         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
52032         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
52033         (check_node_accept_bytes, check_node_accept, extend_buffers):
52034         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
52035         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
52036         (sift_ctx_init):
52037         Likewise.
52038
52039         * lib/regex_internal.h:
52040         (re_string_allocate, re_string_construct, re_string_reconstruct):
52041         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
52042         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
52043         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
52044         (re_string_context_at, re_string_peek_byte_case):
52045         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
52046         is defined, since we now use prototypes always.
52047
52048         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
52049         C89 or better.  All uses removed.
52050
52051 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
52052
52053         * config/srclist.txt: Add glibc bugs 1220-1227.
52054
52055 2005-08-20  Jim Meyering  <jim@meyering.net>
52056
52057         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
52058         of unused local, dfa.
52059
52060 2005-08-20  Bruno Haible  <bruno@clisp.org>
52061
52062         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
52063
52064 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
52065
52066         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
52067         (re_node_set_insert_last, re_dfa_add_node):
52068         Rename local variables to avoid GCC shadowing warnings.
52069
52070 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
52071
52072         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
52073         [defined lint]: Suppress bogus uninitialized-variable warnings.
52074
52075         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
52076         and let the caller return REG_ESPACE if out of space.  This
52077         removes an uninitialied-variable warning with GCC 4.0.1, and also
52078         avoids taking the address of a local variable.  All callers
52079         changed.
52080
52081 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
52082
52083         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
52084         $LIBCSRC/posix/regexec.c.
52085         Add glibc bug 1217 for regcomp.c.
52086
52087 2005-08-19  Jim Meyering  <jim@meyering.net>
52088
52089         * lib/regexec.c (proceed_next_node): Redo local variables to
52090         avoid GCC shadowing warnings.
52091
52092 2005-08-18  Bruno Haible  <bruno@clisp.org>
52093
52094         * lib/strstr.c (strstr): Fix return value in multibyte case.
52095         * lib/strcasestr.c (strcasestr): Likewise.
52096
52097 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
52098
52099         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
52100
52101 2005-08-17  Jim Meyering  <jim@meyering.net>
52102
52103         Make the %s format (seconds since the epoch) work for a negative
52104         number and when used with a zero-padded field width, e.g. %015s.
52105
52106         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
52107         label so that it precedes the code to set `digits'.  Otherwise,
52108         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
52109         print `00-22'.  Now, it prints `-0022', as it should.
52110
52111 2005-08-17  Bruno Haible  <bruno@clisp.org>
52112
52113         * modules/strstr (Files): Add m4/mbrtowc.m4.
52114         (Depends-on): Add mbuiter.
52115
52116 2005-08-17  Bruno Haible  <bruno@clisp.org>
52117
52118         * modules/strcasestr: New file.
52119         * MODULES.html.sh (String handling, based on ANSI C 89): Add
52120         strcasestr.
52121
52122 2005-08-17  Bruno Haible  <bruno@clisp.org>
52123
52124         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
52125
52126 2005-08-17  Bruno Haible  <bruno@clisp.org>
52127
52128         * modules/mbuiter: New file.
52129         * MODULES.html.sh (Extended multibyte and wide character utilities):
52130         Add mbuiter.
52131
52132 2005-08-17  Bruno Haible  <bruno@clisp.org>
52133
52134         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
52135         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
52136
52137 2005-08-17  Bruno Haible  <bruno@clisp.org>
52138
52139         * m4/strcasestr.m4: New file.
52140
52141 2005-08-17  Bruno Haible  <bruno@clisp.org>
52142
52143         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
52144         * lib/strstr.c: Completely rewritten, with multibyte locale support.
52145
52146 2005-08-17  Bruno Haible  <bruno@clisp.org>
52147
52148         * lib/strcasestr.h: New file.
52149         * lib/strcasestr.c: New file.
52150
52151 2005-08-17  Bruno Haible  <bruno@clisp.org>
52152
52153         * lib/strcasecmp.c: Use mbuiter.h.
52154
52155 2005-08-17  Bruno Haible  <bruno@clisp.org>
52156
52157         * lib/mbuiter.h: New file.
52158
52159 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
52160
52161         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
52162         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
52163         and gl_GETOPT are both invoked via different paths (as happens
52164         with GNU tar CVS because it uses both argp and getopt), the former
52165         wins.
52166
52167 2005-08-16  Bruno Haible  <bruno@clisp.org>
52168
52169         * modules/tls: New file.
52170         * MODULES.html.sh (Multithreading): Add tls.
52171
52172 2005-08-16  Bruno Haible  <bruno@clisp.org>
52173
52174         * modules/strnlen1: New file.
52175         * MODULES.html.sh (String handling): Add strnlen1.
52176
52177 2005-08-16  Bruno Haible  <bruno@clisp.org>
52178
52179         * modules/strcase (Files): Add m4/mbrtowc.m4.
52180         (Depends-on): Add strnlen1, mbchar.
52181
52182 2005-08-16  Bruno Haible  <bruno@clisp.org>
52183
52184         * modules/mbiter: New file.
52185         * MODULES.html.sh (Extended multibyte and wide character utilities):
52186         Add mbiter.
52187
52188 2005-08-16  Bruno Haible  <bruno@clisp.org>
52189
52190         * modules/mbfile: New file.
52191         * MODULES.html.sh (Extended multibyte and wide character utilities):
52192         Add mbfile.
52193
52194 2005-08-16  Bruno Haible  <bruno@clisp.org>
52195
52196         * modules/mbchar: New file.
52197         * MODULES.html.sh (Extended multibyte and wide character utilities):
52198         New section.
52199
52200 2005-08-16  Bruno Haible  <bruno@clisp.org>
52201
52202         * m4/tls.m4: New file, from GNU gettext.
52203
52204 2005-08-16  Bruno Haible  <bruno@clisp.org>
52205
52206         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
52207         always.
52208         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
52209
52210 2005-08-16  Bruno Haible  <bruno@clisp.org>
52211
52212         * m4/mbiter.m4: New file.
52213
52214 2005-08-16  Bruno Haible  <bruno@clisp.org>
52215
52216         * m4/mbfile.m4: New file.
52217
52218 2005-08-16  Bruno Haible  <bruno@clisp.org>
52219
52220         * m4/mbchar.m4: New file.
52221
52222 2005-08-16  Bruno Haible  <bruno@clisp.org>
52223
52224         * lib/tls.h: New file, from GNU gettext.
52225         * lib/tls.c: New file, from GNU gettext.
52226
52227 2005-08-16  Bruno Haible  <bruno@clisp.org>
52228
52229         * lib/strnlen1.h: New file.
52230         * lib/strnlen1.c: New file.
52231
52232 2005-08-16  Bruno Haible  <bruno@clisp.org>
52233
52234         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
52235         (mbi_init): Update.
52236         (mbi_avail, mbi_advance): Let the iteration end before the terminating
52237         NUL byte, not after it.
52238
52239 2005-08-16  Bruno Haible  <bruno@clisp.org>
52240
52241         * lib/strcase.h (strcasecmp): Add note in comments.
52242         * lib/strncasecmp.c: Use code from strcasecmp.c.
52243         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
52244         (strcasecmp): Work correctly in multibyte locales.
52245
52246 2005-08-16  Bruno Haible  <bruno@clisp.org>
52247
52248         * lib/mbiter.h: New file.
52249
52250 2005-08-16  Bruno Haible  <bruno@clisp.org>
52251
52252         * lib/mbfile.h: New file.
52253
52254 2005-08-16  Bruno Haible  <bruno@clisp.org>
52255
52256         * lib/mbchar.h: New file.
52257         * lib/mbchar.c: New file.
52258
52259 2005-08-16  Bruno Haible  <bruno@clisp.org>
52260
52261         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
52262         the valid ones. Makes the comparison operations transitive:
52263         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
52264         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
52265
52266 2005-08-15  Simon Josefsson  <jas@extundo.com>
52267
52268         * modules/ssize_t (License): Change to 'unlimited'.
52269
52270         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
52271
52272 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
52273
52274         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
52275         Add comments for each pending glibc patch.
52276
52277 2005-08-15  Bruno Haible  <bruno@clisp.org>
52278
52279         * lib/regex.h (__restrict_arr): Don't define to __restrict if
52280         __cplusplus is defined.
52281
52282 2005-08-14  Jim Meyering  <jim@meyering.net>
52283
52284         Sync from coreutils.
52285
52286         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
52287         Use the hash-table-based cycle-detection code not just when
52288         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
52289         Reported by James Youngman in
52290         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
52291         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
52292         FTS_TIGHT_CYCLE_CHECK.
52293         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
52294         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
52295         once again.
52296         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
52297         * lib/fts.c (fd_safer): Remove decl.
52298         Include fcntl--.h rather than unistd-safer.h
52299         (fts_safe_changedir): Don't call fd_safer; no longer needed
52300         now that we include fcntl--.h.
52301
52302 2005-08-12  Simon Josefsson  <jas@extundo.com>
52303
52304         * modules/getndelim2: Use ssize_t module.
52305         * modules/getnline: Likewise.
52306         * modules/safe-read: Likewise.
52307         * modules/xreadlink: Likewise.
52308
52309         * modules/ssize_t: New file.
52310
52311 2005-08-12  Simon Josefsson  <jas@extundo.com>
52312
52313         * m4/readline.m4: Look for termcap, curses or ncurses if required.
52314
52315 2005-08-12  Simon Josefsson  <jas@extundo.com>
52316
52317         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
52318         ssize_t.
52319
52320 2005-08-12  Simon Josefsson  <jas@extundo.com>
52321
52322         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
52323         readline, getdelim and check_version.
52324         (Support for systems lacking ISO C 99: Sizes of integer types):
52325         Add size_max.
52326
52327 2005-08-12  Bruno Haible  <bruno@clisp.org>
52328
52329         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
52330
52331 2005-08-11  Simon Josefsson  <jas@extundo.com>
52332
52333         * modules/readline: New file.
52334
52335         * modules/strnlen (Files): Add strnlen.h.
52336
52337 2005-08-11  Simon Josefsson  <jas@extundo.com>
52338
52339         * m4/readline.m4: New file.
52340
52341 2005-08-11  Simon Josefsson  <jas@extundo.com>
52342
52343         * lib/readline.h, readline.c: New file.
52344
52345 2005-08-11  Simon Josefsson  <jas@extundo.com>
52346
52347         * doc/gnulib.texi (Initial import, Finishing touches): Mention
52348         gl_AVOID.
52349
52350 2005-08-11  Bruno Haible  <bruno@clisp.org>
52351
52352         * lib/strnlen.h (strnlen): Change parameter name to match comment.
52353
52354 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
52355
52356         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
52357
52358 2005-08-10  Simon Josefsson  <jas@extundo.com>
52359
52360         * tests/test-iconvme.c: New file.
52361
52362 2005-08-10  Simon Josefsson  <jas@extundo.com>
52363
52364         * m4/strnlen.m4: New file.
52365
52366         * m4/strndup.m4: Don't check for strnlen declaration, done in
52367         strnlen.m4.
52368
52369 2005-08-10  Simon Josefsson  <jas@extundo.com>
52370
52371         * lib/strndup.c: Use strnlen.h.
52372
52373         * lib/strnlen.h: New file.
52374
52375 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
52376
52377         * README: Typos.
52378
52379 2005-08-02  Simon Josefsson  <jas@extundo.com>
52380
52381         * modules/readline: New file.
52382
52383 2005-08-02  Simon Josefsson  <jas@extundo.com>
52384
52385         * modules/getdelim: New file.
52386
52387         * modules/getline: Rewrite, don't use getndelim2.
52388
52389 2005-08-02  Simon Josefsson  <jas@extundo.com>
52390
52391         * m4/getline.m4: Separate out getdelim stuff into separate module.
52392
52393         * m4/getdelim.m4: New file.
52394
52395 2005-08-02  Simon Josefsson  <jas@extundo.com>
52396
52397         * lib/getline.h, getline.c: Rewrite.
52398
52399         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
52400
52401 2005-07-31  Bruno Haible  <bruno@clisp.org>
52402
52403         * lib/lock.h (gl_lock_initializer): New macro.
52404         (gl_lock_define_initialized): Use it.
52405         (gl_rwlock_initializer): New macro.
52406         (gl_rwlock_define_initialized): Use it.
52407         (gl_recursive_lock_initializer): New macro.
52408         (gl_recursive_lock_define_initialized): Use it.
52409
52410 2005-07-30  Karl Berry  <karl@gnu.org>
52411
52412         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
52413         Report from Ben Pfaff, regarding getopt.
52414
52415 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
52416
52417         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
52418         normal way.
52419         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
52420         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
52421         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
52422         (gl_GETOPT): Use the new macros.  Most of the implementation
52423         is moved to the new macros.  This is for programs like Emacs
52424         that don't want all the functionality of gl_GETOPT.
52425
52426 2005-07-26  Bruno Haible  <bruno@clisp.org>
52427
52428         * m4/lock.m4: Update from GNU gettext.
52429
52430 2005-07-26  Bruno Haible  <bruno@clisp.org>
52431
52432         * lib/lock.h: Update from GNU gettext.
52433         * lib/lock.c: Update from GNU gettext.
52434
52435 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
52436
52437         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
52438         obsolescent AC_TRY_RUN.  Include the default includes files, for
52439         'exit'.
52440
52441 2005-07-24  Bruno Haible  <bruno@clisp.org>
52442
52443         * modules/visibility: New file.
52444         * MODULES.html.sh (Misc): Add visibility.
52445
52446 2005-07-24  Bruno Haible  <bruno@clisp.org>
52447
52448         * m4/visibility.m4: New file.
52449
52450 2005-07-24  Bruno Haible  <bruno@clisp.org>
52451
52452         * doc/visibility.texi: New file.
52453
52454 2005-07-22  Bruno Haible  <bruno@clisp.org>
52455
52456         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
52457         $(ALLOCA_H), redundant through BUILT_SOURCES.
52458         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
52459         redundant through BUILT_SOURCES.
52460         * modules/byteswap (Makefile.am): Remove explicit dependency on
52461         $(BYTESWAP_H), redundant through BUILT_SOURCES.
52462         * modules/fnmatch (Makefile.am): Remove explicit dependency on
52463         $(FNMATCH_H), redundant through BUILT_SOURCES.
52464         * modules/getopt (Makefile.am): Remove explicit dependency on
52465         $(GETOPT_H), redundant through BUILT_SOURCES.
52466         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
52467         redundant through BUILT_SOURCES.
52468         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
52469         redundant through BUILT_SOURCES.
52470         * modules/stdbool (Makefile.am): Remove explicit dependency on
52471         $(STDBOOL_H), redundant through BUILT_SOURCES.
52472         * modules/stdint (Makefile.am): Remove explicit dependency on
52473         $(STDINT_H), redundant through BUILT_SOURCES.
52474         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
52475         Remove explicit dependency on $(SYSEXITS_H).
52476         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
52477
52478 2005-07-18  Simon Josefsson  <jas@extundo.com>
52479
52480         * lib/check-version.c (check_version): Accept identical versions too.
52481
52482 2005-07-18  Bruno Haible  <bruno@clisp.org>
52483
52484         * modules/lock: New file.
52485         * MODULES.html.sh (Multithreading): New section.
52486
52487 2005-07-18  Bruno Haible  <bruno@clisp.org>
52488
52489         * m4/lock.m4: New file, from GNU gettext.
52490
52491 2005-07-18  Bruno Haible  <bruno@clisp.org>
52492
52493         * lib/lock.h: New file, from GNU gettext.
52494         * lib/lock.c: New file, from GNU gettext.
52495
52496 2005-07-18  Bruno Haible  <bruno@clisp.org>
52497
52498         * lib/lock.h (gl_once_t): New type.
52499         (gl_once_define, gl_once): New macros.
52500         * lib/lock.c (fresh_once): New variable.
52501         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
52502         functions.
52503
52504 2005-07-16  Simon Josefsson  <jas@extundo.com>
52505
52506         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
52507         workaround, suggested by Bruno.
52508
52509 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
52510
52511         * modules/xalloc (Depends-on): Add xalloc-die.
52512         * modules/xvasprintf (Depends-on): Add xalloc-die.
52513
52514 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
52515
52516         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
52517         with a minor change.
52518
52519 2005-07-15  Bruno Haible  <bruno@clisp.org>
52520
52521         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
52522         When using lib/poll.c, define poll as rpl_poll.
52523
52524 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
52525
52526         * modules/argp (Depends-on): Remove unlocked-io.
52527
52528 2005-07-14  Derek Price  <derek@ximbiot.com>
52529
52530         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
52531         for glob symlink bug.
52532
52533 2005-07-14  Bruno Haible  <bruno@clisp.org>
52534
52535         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
52536         Instead, test for *_unlocked function declarations directly.
52537
52538 2005-07-11  Simon Josefsson  <jas@extundo.com>
52539
52540         * modules/size_max: New file.
52541
52542         * modules/xsize: Depend on size_max module for size_max.m4.
52543
52544 2005-07-11  Simon Josefsson  <jas@extundo.com>
52545
52546         * lib/size_max.h: New file.
52547
52548 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
52549
52550         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
52551         copyright symbol and the year.
52552         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
52553         (version_etc_va): Use parameterized copyright notice.
52554         Reword to conform to the current GNU coding standards.
52555
52556 2005-07-11  Karl Berry  <karl@gnu.org>
52557
52558         * doc/gnulib.texi (Quoting): new node.
52559         (Initial import): more info, from Patrice.
52560
52561 2005-07-11  Bruno Haible  <bruno@clisp.org>
52562
52563         * gnulib-tool (func_usage): Document option --avoid.
52564         (Command line options): Handle --avoid.
52565         (func_acceptable): New function.
52566         (func_modules_transitive_closure): Use it.
52567
52568 2005-07-11  Bruno Haible  <bruno@clisp.org>
52569
52570         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
52571         Reported by Jim Meyering.
52572
52573 2005-07-10  Bruno Haible  <bruno@clisp.org>
52574
52575         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
52576         Needed when size_t is smaller than 'unsigned int'.
52577         Reported by Paul Eggert.
52578
52579 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
52580
52581         * modules/argp (Depends-on): Add unlocked-io
52582
52583 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
52584
52585         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
52586         block of defines.
52587
52588 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
52589
52590         * config/srclist.txt: Comment out regcomp.c, since we have a porting
52591         fix now.
52592
52593 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
52594         and Paul Eggert  <eggert@cs.ucla.edu>
52595
52596         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
52597         in wint_t, not wchar_t.  Remove now-unnecessary cast.
52598
52599 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
52600
52601         * modules/regex (Files): Add lib/regex_internal.c,
52602         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
52603         (Depends-on): Add extensions.
52604         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
52605
52606 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
52607
52608         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
52609         pathconf.
52610         * m4/same.m4 (gl_SAME): Likewise.
52611         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
52612
52613         * m4/regex.m4: Adjust to new libc regex implementation.
52614         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
52615         all the .c and .h parts of (the new) regex.
52616         Quote the m4 stuff better.
52617         Check for RE_ICASE bug of old gnulib.
52618         Check for REG_STARTEND of recent libc.
52619         Rename local variables from jm_* to gl_*.
52620         Quote operand of "test -f".
52621         Say "recent enough" version of libc, not "version 2".
52622         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
52623         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
52624         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
52625         Remove check for btowc, isascii.
52626         Require AM_LANGINFO_CODESET.
52627
52628 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
52629
52630         * lib/regex.c, regex.h: Sync from libc.
52631         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
52632         * lib/regexec.c:
52633         New files, synced from libc, except that regex_internal.h
52634         currently has a small porting fix.
52635
52636 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
52637
52638         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
52639         regex_internal.c, regexec.c.
52640         Add regex_internal.h too, but as a comment, since the libc version
52641         is currently broken in gnulib mode.
52642
52643 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
52644
52645         Support programs like Emacs that use gnulib but not gettext.
52646         * MODULES.html.sh (Internationalization functions): Add gettext-h.
52647         * modules/gettext-h: New file.
52648         * modules/gettext (Files): Remove lib/gettext.h.
52649         (Depends-on): Add gettext-h.
52650         (Makefile.am): Remove lib_SOURCES.
52651         * modules/argmatch, modules/c-stack, modules/closeout:
52652         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
52653         * modules/execute, modules/file-type, modules/getaddrinfo:
52654         * modules/getopt, modules/human, modules/javacomp:
52655         * modules/javaexec, modules/mkdir-p, modules/obstack:
52656         * modules/openat, modules/pagealign_alloc, modules/pipe:
52657         * modules/quotearg, modules/regex, modules/rpmatch:
52658         * modules/unicodeio, modules/userspec, modules/version-etc:
52659         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
52660         * modules/xsetenv:
52661         Depend on gettext-h, not gettext.
52662
52663 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
52664
52665         * gnulib-tool (func_import): Add support for 'public domain' license.
52666         * modules/alloca, modules/atexit, modules/memmove:
52667         Now public domain, not GPL.
52668         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
52669         * modules/realloc, modules/strerror, modules/strtod:
52670         Now LGPL, not GPL.
52671
52672 2005-07-05  Bruno Haible  <bruno@clisp.org>
52673
52674         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
52675         autoconf CVS. Needed for mingw.
52676
52677 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
52678
52679         Remove the dependency of the strftime module on the tzset module.
52680         * modules/strftime (Depends-on): Remove dependency on tzset.
52681
52682 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
52683
52684         Remove the dependency of the strftime module on the tzset module.
52685         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
52686         gl_FUNC_TZSET_CLOBBER.
52687
52688 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
52689
52690         Remove the dependency of the strftime module on the tzset module.
52691         * lib/strftime.c (my_strftime)
52692         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
52693         Copy the input structure, to work around some of the bug with
52694         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
52695         Solaris releases, you should also use the tzset module, but we won't
52696         require it as a dependency any more since we don't want LGPLed code
52697         to depend on GPLed code.
52698
52699 2005-07-02  Jim Meyering  <jim@meyering.net>
52700
52701         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
52702         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
52703         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
52704         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
52705
52706 2005-07-02  Jim Meyering  <jim@meyering.net>
52707
52708         * lib/backupfile.c (backup_args): Change a `0' to NULL.
52709
52710 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
52711
52712         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
52713         declares only 'struct timespec;' (!).
52714
52715 2005-07-01  Jim Meyering  <jim@meyering.net>
52716
52717         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
52718         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
52719         * lib/save-cwd.c, tempname.c:
52720         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
52721         and don't include <sys/file.h>).
52722
52723 2005-06-29  Jim Meyering  <jim@meyering.net>
52724
52725         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
52726         type name.  Use the variable name instead.
52727         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
52728         Likewise.
52729
52730 2005-06-28  Simon Josefsson  <jas@extundo.com>
52731
52732         * modules/check-version (Files): Add check-version.m4.
52733
52734 2005-06-28  Simon Josefsson  <jas@extundo.com>
52735
52736         * m4/check-version.m4: New file, suggested by Jim Meyering
52737         <jim@meyering.net>.
52738
52739 2005-06-28  Simon Josefsson  <jas@extundo.com>
52740
52741         * lib/check-version.h, lib/check-version.c: New files.
52742
52743 2005-06-28  Simon Josefsson  <jas@extundo.com>
52744
52745         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
52746         collision with global variable.  Better indentation.  Don't
52747         increment buffer pointer beyond buffer end.  Based on comments
52748         from Paul Eggert <eggert@cs.ucla.edu>.
52749
52750         * lib/base64.h: Indent.
52751
52752 2005-06-28  Simon Josefsson  <jas@extundo.com>
52753
52754         * doc/gnulib.texi (Library version handling): New section.
52755
52756 2005-06-28  Jim Meyering  <jim@meyering.net>
52757
52758         * check-module (find_included_lib_files): Hard-code another
52759         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
52760         but modules/fts-lgpl (correctly) does not list those files.
52761
52762         * modules/canonicalize (Files): Add lib/pathmax.h.
52763
52764 2005-06-25  Simon Josefsson  <jas@extundo.com>
52765
52766         * modules/check-version: New file.
52767
52768 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
52769
52770         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
52771         initializer of struct addrinfo, as an indication that we don't
52772         care how many members the structure has.
52773
52774 2005-06-24  Derek Price  <derek@ximbiot.com>
52775         and Bruno Haible  <bruno@clisp.org>
52776
52777         Remove stat module & update lstat.
52778         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
52779         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
52780         * m4/stat.m4: Remove this file.
52781
52782 2005-06-24  Derek Price  <derek@ximbiot.com>
52783         and Bruno Haible  <bruno@clisp.org>
52784
52785         Remove stat module & update lstat.
52786         * lib/stat.c: Remove this file...
52787         (slash_aware_lstat): ...moving this content and its support...
52788         * lib/lstat.c (rpl_lstat): ...into here.
52789         * lib/lstat.h: New file.
52790
52791 2005-06-24  Derek Price  <derek@ximbiot.com>
52792         and Bruno Haible  <bruno@clisp.org>
52793
52794         Remove stat module & update lstat.
52795         * config/srclist.txt (libc sources): Remove stat.
52796
52797 2005-06-24  Derek Price  <derek@ximbiot.com>
52798         and Bruno Haible  <bruno@clisp.org>
52799
52800         Remove stat module & update lstat.
52801         * MODULES.html.sh (stat): Remove.
52802         * MODULES.html: Regenerated.
52803         * modules/lstat (Description): Correct function name.
52804         (Files): Add "lstat.h".
52805         (Depends-on): Remove stat, add xalloc, stat-macros.
52806         * modules/stat: Remove this file.
52807         (Include): Add "lstat.h", remove <sys/stat.h>.
52808
52809 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
52810
52811         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
52812         (ranged_convert): Don't save conversion in a temporary struct.
52813         This causes a warning with GCC 4.0.0, and anyway in the typical
52814         case it's not worth the extra 100 bytes or so of code.
52815         (ranged_convert, __mktime_internal): When calling a function via a
52816         pointer P, use P () rather than (*P) (), as we now assume C89 or
52817         better.
52818
52819 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
52820
52821         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
52822         "who -r" failed to give output.  Problem reported by Tim Waugh.
52823
52824         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
52825         (xcalloc): Use it to avoid needless tests.
52826         Problem reported by Jim Meyering.
52827
52828 2005-06-20  Derek Price  <derek@ximbiot.com>
52829
52830         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
52831         unnecessary for Autoconfs > 2.59c.
52832
52833 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
52834
52835         * lib/argp.h (__option_is_short): Check upper limit of
52836         __key. Isprint() requires its argument to have the value
52837         of an unsigned char or EOF.
52838
52839 2005-06-16  Jim Meyering  <jim@meyering.net>
52840
52841         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
52842         when either N or S is zero.
52843
52844 2005-06-16  Derek Price  <derek@ximbiot.com>
52845
52846         * m4/bison.m4: Declare YACC & YFLAGS precious.
52847
52848 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
52849
52850         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
52851         multibyte string or pattern, fall back on unibyte matching.
52852         Problem reported by James Youngman.
52853
52854 2005-06-08  Bruno Haible  <bruno@clisp.org>
52855
52856         * modules/csharpcomp: New file.
52857         * MODULES.html.sh (C#): Add csharpcomp.
52858
52859 2005-06-08  Bruno Haible  <bruno@clisp.org>
52860
52861         * m4/csharpcomp.m4: New file, from GNU gettext.
52862
52863 2005-06-08  Bruno Haible  <bruno@clisp.org>
52864
52865         * lib/csharpcomp.h: New file, from GNU gettext.
52866         * lib/csharpcomp.c: New file, from GNU gettext.
52867         * lib/csharpcomp.sh.in: New file, from GNU gettext.
52868
52869 2005-06-08  Bruno Haible  <bruno@clisp.org>
52870
52871         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
52872         warning on mingw.
52873
52874 2005-06-07  Derek Price  <derek@ximbiot.com>
52875
52876         Sync from CVS.
52877         * lib/glob_.h: Indent nested #ifdef.
52878
52879 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
52880
52881         Sync from coreutils.
52882         Use "file name" when talking about file names, instead of "filename"
52883         or "path", as per the GNU coding standards.
52884         * lib/mkdir-p.c: Renamed from makepath.c.
52885         (make_dir_parents): Renamed from make_path.  All callers changed.
52886         * lib/mkdir-p.h: Likewise.  All includers changed.
52887         * lib/filenamecat.c: Renamed from path-concat.c.
52888         (file_name_concat): Renamed from path_concat.  All callers changed.
52889         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
52890         * lib/filenamecat.h: Likewise.  All includers changed.
52891         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
52892         in comments or local variable names.
52893         * lib/basename.c: Likewise.
52894         * lib/canonicalize.c, canonicalize.h: Likewise.
52895         * lib/dirname.c, dirname.h: Likewise.
52896         * lib/euidaccess.c: Likewise.
52897         * lib/exclude.c: Likewise
52898         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
52899         * lib/fsusage.c, fsuage.h: Likewise.
52900         * lib/fts.c, fts_.h: Likewise.
52901         * lib/getcwd.c: Likewise.
52902         * lib/getloadavg.c: Likewise.
52903         * lib/mkstemp.c: Likewise.
52904         * lib/mountlist.c, mountlist.h: Likewise.
52905         * lib/openat.c, openat.h: Likewise.
52906         * lib/readlink-stub.c: Likewise.
52907         * lib/readutmp.c, readutmp.h: Likewise.
52908         * lib/rename.c: Likewise.
52909         * lib/rmdir.c: Likewise.
52910         * lib/same.c: Likewise.
52911         * lib/savedir.c: Likewise.
52912         * lib/stripslash.c: Likewise.
52913         * lib/tempname.c: Likewise.
52914         * lib/xreadlink.c: Likewise.
52915         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
52916         All uses changed.
52917         * lib/exclude.h: Likewise.
52918
52919         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
52920         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
52921         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
52922         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
52923         * lib/pathmax.h: Include <limits.h> unconditionally, since other
52924         files have been getting away with it for years (MORE/BSD 4.3
52925         is extinct now).
52926         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
52927         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
52928
52929         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
52930         Define to 256, not 255, as per modern POSIX.
52931
52932 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
52933
52934         Sync from coreutils.
52935         Use "file name" when talking about file names, instead of "filename"
52936         or "path", as per the GNU coding standards.
52937         * MODULES.html.sh: mkdir-p renamed from makepath.
52938         filenamecat renamed from path-concat.
52939         * modules/filenamecat: Renamed from modules/path-concat.
52940         (Files): filenamecat.h and filenamecat.c renamed from
52941         path-concat.h and path-concat.c.
52942         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
52943         (Include): filenamecat.h, not path-concat.h.
52944         * modules/mkdir-p: Renamed from modules/makepath.
52945         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
52946         makepath.c.
52947         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
52948         (Include): mkdir-p.h, not makepath.h.
52949
52950 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
52951
52952         Sync from coreutils.
52953         * m4/mkdir-p.m4: Renamed from makepath.m4.
52954         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
52955         Rename files from makepath.c to mkdir-p.c, and from
52956         makepath.h to mkdir-p.h.
52957         * m4/filenamecat.m4: Renamed from path-concat.m4.
52958         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
52959         Rename files from path-concat.c to filenamecat.c,
52960         and from path-concat.h to filenamecat.h.
52961         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
52962         "file name" in local variables or comments.
52963         * m4/rename.m4: Likewise.
52964
52965 2005-06-01  Bruno Haible  <bruno@clisp.org>
52966
52967         * modules/csharpexec: New file.
52968         * MODULES.html.sh (C#): New section.
52969
52970 2005-06-01  Bruno Haible  <bruno@clisp.org>
52971
52972         * m4/csharp.m4: New file, from GNU gettext.
52973         * m4/csharpexec.m4: New file, from GNU gettext.
52974
52975 2005-06-01  Bruno Haible  <bruno@clisp.org>
52976
52977         * lib/csharpexec.h: New file, from GNU gettext.
52978         * lib/csharpexec.c: New file, from GNU gettext.
52979         * lib/csharpexec.sh.in: New file, from GNU gettext.
52980
52981 2005-05-31  Derek Price  <derek@ximbiot.com>
52982             Paul Eggert  <eggert@cs.ucla.edu>
52983
52984         Sync from cvs.
52985         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
52986
52987 2005-05-31  Derek Price  <derek@ximbiot.com>
52988             Paul Eggert  <eggert@cs.ucla.edu>
52989
52990         Sync from cvs.
52991         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
52992
52993 2005-05-29  Derek Price  <derek@ximbiot.com>
52994
52995         * config/srclist.txt (glob_.h, glob.c): Add these files.
52996
52997 2005-05-29  Derek Price  <derek@ximbiot.com>
52998
52999         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
53000         * modules/glob: New file.
53001         * modules/getlogin_r: Add link to POSIX spec in description.
53002
53003 2005-05-29  Derek Price  <derek@ximbiot.com>
53004             Paul Eggert  <eggert@cs.ucla.edu>
53005
53006         * m4/glob.m4: New file.
53007
53008 2005-05-29  Derek Price  <derek@ximbiot.com>
53009             Paul Eggert  <eggert@cs.ucla.edu>
53010
53011         * lib/glob_.h, lib/glob.c: New files.
53012
53013 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
53014
53015         * modules/fts (Files): Remove m4/inttypes-pri.m4.
53016         * modules/fts-lgpl (Depends-on): Remove gettext.
53017
53018 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
53019
53020         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
53021         and don't require gt_INTTYPES_PRI.
53022
53023 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
53024
53025         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
53026
53027         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
53028         the configuration hassle isn't worth it.
53029         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
53030         (LONGEST_MODIFIER, PRIuMAX): Remove.
53031
53032 2005-05-27  Bruno Haible  <bruno@clisp.org>
53033
53034         * lib/getlogin_r.h: Remove second include of <stddef.h>.
53035
53036 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
53037
53038         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
53039         _POSIX_PTHREAD_SEMANTICS for Solaris.
53040
53041 2005-05-25  Derek Price  <derek@ximbiot.com>
53042
53043         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
53044
53045 2005-05-25  Derek Price  <derek@ximbiot.com>
53046             Paul Eggert  <eggert@cs.ucla.edu>
53047
53048         * modules/getlogin_r, m4/getlogin_r.m4: New files.
53049         * lib/getlogin_r.c, getlogin_r.h: New files.
53050
53051 2005-05-25  Bruno Haible  <bruno@clisp.org>
53052             Derek Price  <derek@ximbiot.com>
53053
53054         * lib/getlogin_r.h: Simplify API documentation.
53055
53056 2005-05-23  Derek Price  <derek@ximbiot.com>
53057
53058         * modules/minmax (Files): Add m4/minmax.m4.
53059         (configure.ac): Add gl_MINMAX.
53060
53061 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
53062
53063         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
53064         so that unistd-safer.h (GPL'ed code) need not be included.
53065
53066 2005-05-22  Bruno Haible  <bruno@clisp.org>
53067
53068         * m4/minmax.m4: New file.
53069         Based on a patch by Derek Price <derek@ximbiot.com>.
53070
53071 2005-05-22  Bruno Haible  <bruno@clisp.org>
53072
53073         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
53074         (INT64_MIN): Fix definition.
53075         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
53076
53077         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
53078         NEED_SIGNED_INT_TYPES.
53079
53080         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
53081         HAVE_SYSTEM_INTTYPES.
53082
53083 2005-05-22  Bruno Haible  <bruno@clisp.org>
53084
53085         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
53086         Also include <sys/param.h> if it defines MIN, MAX.
53087         Based on a patch by Derek Price <derek@ximbiot.com>.
53088
53089 2005-05-21  Jim Meyering  <jim@meyering.net>
53090
53091         * modules/fts (Files): Add m4/inttypes-pri.m4.
53092         (Depends-on): Add lstat and remove gettext.  Alphabetize.
53093
53094 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
53095
53096         New fts module.
53097         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
53098         (setup_dir, free_dir): New functions.
53099         (enter_dir, leave_dir): Define trivial
53100         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
53101         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
53102         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
53103         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
53104         Move to fts-cycle.c.
53105         (fts_open): Use setup_dir.
53106         (fts_close): Use free_dir.
53107         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
53108         This adds a label and some gotos, but the alternatives were messier.
53109         Check for memory allocation failure when entering a dir.
53110         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
53111         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
53112         (FTS): New member fts_cycle, that is a union that contains the
53113         old active_dir_ht and cycle_state.  All uses changed to mention
53114         fts_cycle.ht and fts_cycle.state.
53115         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
53116         fts.c, with the following changes:
53117         (setup_dir, free_dir): New functions.
53118         (enter_dir): Now returns bool.  Return true if successful, false
53119         if memory exhausted.  All callers changed.
53120         Do not bother partly cleaning up on
53121         memory allocation failure; that is free_dir's job.
53122         However, free ad if hash_insert fails, to avoid memory leak.
53123         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
53124         fts->fts_options to see which union member to use.
53125
53126 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
53127
53128         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
53129         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
53130
53131 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
53132
53133         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
53134
53135 2005-05-20  Jim Meyering  <jim@meyering.net>
53136
53137         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
53138         Now a macro, to pacify GCC.
53139
53140 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
53141
53142         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
53143         of -1.
53144
53145 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
53146
53147         * lib/chown.c (rpl_chown): Return -1 on failure.
53148
53149 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
53150
53151         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
53152         Don't check for stddef.h.
53153         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
53154         don't use its results.
53155         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
53156         since we include them unconditionally.  Don't require
53157         AM_STDBOOL_H, since stdbool is a prerequisite.
53158         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
53159         since we assume C89 or better.
53160         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
53161         as we don't use their results.
53162         Don't check for fchdir, memmove, memset, strrchr, as we use
53163         them unconditionally.
53164         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
53165         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
53166
53167 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
53168
53169         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
53170         Include <stddef.h> unconditionally, since we assume C89 now.
53171         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
53172         * lib/fts.c: Include fts_.h first, to check interface.
53173         Do not include intprops.h; no longer needed.
53174         Include cycle-check.h and hash.h, since fts_.h no longer does.
53175         Remove unnecessary casts of closedir to void.
53176         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
53177         decide whether to decrement nlinks.
53178         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
53179         (FTS): Use struct hash_table * instead of Hash_table, so that
53180         we no longer need to include hash.h here.
53181
53182 2005-05-18  Jim Meyering  <jim@meyering.net>
53183
53184         * modules/dirfd (License): Change to LGPL.  Most of the code
53185         is already in the public domain.
53186
53187 2005-05-18  Jim Meyering  <jim@meyering.net>
53188
53189         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
53190         Reported by Yoann Vandoorselaere.
53191
53192 2005-05-17  Jim Meyering  <jim@meyering.net>
53193
53194         * m4/fts.m4: New file, from coreutils.
53195
53196 2005-05-17  Jim Meyering  <jim@meyering.net>
53197
53198         * lib/fts.c, lib/fts_.h: New files, from coreutils.
53199
53200 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
53201
53202         Sync from coreutils.
53203         * m4/unlinkdir.m4: New file.
53204
53205 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
53206
53207         Sync from coreutils.
53208         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
53209         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
53210         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
53211         White space changes only.
53212         * lib/makepath.c (make_path): Port to hosts where leading "//" is
53213         special.
53214         * lib/yesno.c: Include getline.h, not ctype.h.
53215         (yesno): Don't remove leading white space; POSIX doesn't allow it.
53216         Use getline to remove arbitrary restriction on response length.
53217
53218 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
53219
53220         * config/srclist-update: Spell out "Street" in FSF postal
53221         mail address; this is the style the FSF seems to prefer.
53222
53223         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
53224         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
53225         this updates FSF postal mail address.
53226
53227         Sync from coreutils.
53228         * modules/unlinkdir: New file.
53229         * modules/yesno (Depends-on): Add getline.
53230         * MODULES.html.sh (File system functions): Add unlinkdir.
53231
53232 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
53233
53234         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
53235         lib/strsep.h:
53236         Change the initial comment to refer to GPL, not LGPL.
53237         gnulib-tool will change it to LGPL as needed.
53238
53239         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
53240         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
53241         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
53242         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
53243         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
53244         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
53245         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
53246         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
53247         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
53248         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
53249         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
53250         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
53251         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
53252         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
53253         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
53254         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
53255         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
53256         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
53257         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
53258         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
53259         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
53260         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
53261         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
53262         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
53263         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
53264         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
53265         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
53266         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
53267         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
53268         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
53269         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
53270         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
53271         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
53272         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
53273         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
53274         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
53275         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
53276         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
53277         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
53278         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
53279         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
53280         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
53281         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
53282         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
53283         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
53284         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
53285         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
53286         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
53287         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
53288         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
53289         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
53290         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
53291         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
53292         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
53293         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
53294         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
53295         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
53296         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
53297         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
53298         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
53299         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
53300         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
53301         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
53302         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
53303         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
53304         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
53305         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
53306         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
53307         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
53308         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
53309         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
53310         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
53311         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
53312         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
53313         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
53314         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
53315         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
53316         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
53317         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
53318         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
53319         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
53320         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
53321         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
53322         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
53323         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
53324         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
53325         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
53326         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
53327         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
53328         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
53329         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
53330         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
53331         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
53332         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
53333         lib/yesno.c, lib/yesno.h:
53334         Update FSF postal mail address.
53335
53336 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
53337
53338         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
53339         tests/test-memmem.c, tests/test-stpncpy.c:
53340         Update FSF postal mail address.
53341
53342 2005-05-13  Bruno Haible  <bruno@clisp.org>
53343
53344         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
53345         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
53346         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
53347         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
53348         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
53349         Add support for 64-bit integers in the MSVC compiler.
53350
53351 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
53352
53353         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
53354
53355 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
53356
53357         * gnulib-tool (func_import): Sort and uniquify recommended includes.
53358
53359 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
53360
53361         * doc/getdate.texi (General date syntax): Don't say that date
53362         date --iso-8601=ns generates acceptable dates; it doesn't yet.
53363         Problem reported by Nic Ferrier.
53364
53365 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
53366
53367         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
53368         specified in ai_socktype. Fix invalid ai_protocol
53369         check. ai_protocol is usually set to 0 or depending on
53370         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
53371         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
53372         ai_socktype / ai_protocol in the returned addrinfo structure.
53373
53374 2005-05-10  Simon Josefsson  <jas@extundo.com>
53375
53376         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
53377         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
53378
53379 2005-05-10  Karl Berry  <karl@gnu.org>
53380
53381         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
53382         (from http://www.gnu.org/licenses).
53383         * doc/COPYING.LIB: also rename to COPYING.LESSER.
53384         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
53385         fdl.texi suffices.
53386
53387 2005-05-10  Karl Berry  <karl@gnu.org>
53388
53389         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
53390         (COPYING.DOC): remove.
53391
53392         * config/srclist-update: new FSF address.
53393
53394 2005-05-10  Derek Price  <derek@ximbiot.com>
53395
53396         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
53397         possible.
53398
53399 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
53400             Bruno Haible  <bruno@clisp.org>
53401
53402         * modules/inet_ntop: New file.
53403         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
53404         inet_ntop.
53405
53406 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
53407             Bruno Haible  <bruno@clisp.org>
53408
53409         * m4/inet_ntop.m4: New file.
53410
53411 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
53412             Bruno Haible  <bruno@clisp.org>
53413
53414         * lib/inet_ntop.h: New file.
53415         * lib/inet_ntop.c: New file, from glibc with modifications.
53416
53417 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
53418
53419         * modules/time_r (License): Change to LGPL.
53420         * modules/extensions (License): Change to LGPL.  Actually,
53421         the license is more permissive than that, but currently gnulib-tool
53422         doesn't know how to handle more-permissive licenses.
53423
53424         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
53425         Problem reported by Dave Love.
53426
53427 2005-05-08  Jim Meyering  <jim@meyering.net>
53428
53429         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
53430         blank.
53431
53432 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
53433
53434         * modules/argmatch (Depends-on): Add stdbool.
53435         * modules/backupfile (Depends-on): Likewise.
53436         * modules/chdir-long (Depends-on): Likewise.
53437         * modules/closeout (Depends-on): Likewise.
53438         * modules/cycle-check (Depends-on): Likewise.
53439         * modules/dirname (Depends-on): Likewise.
53440         * modules/fnmatch (Depends-on): Likewise.
53441         * modules/fsusage (Depends-on): Likewise.
53442         * modules/fwriteerror (Depends-on): Likewise.
53443         * modules/getcwd (Depends-on): Likewise.
53444         * modules/getloadavg (Depends-on): Likewise.
53445         * modules/hard-locale (Depends-on): Likewise.
53446         * modules/makepath (Depends-on): Likewise.
53447         * modules/mountlist (Depends-on): Likewise.
53448         * modules/nanosleep (Depends-on): Likewise.
53449         * modules/posixtm (Depends-on): Likewise.
53450         * modules/quotearg (Depends-on): Likewise.
53451         * modules/readtokens (Depends-on): Likewise.
53452         * modules/readtokens0 (Depends-on): Likewise.
53453         * modules/readutmp (Depends-on): Likewise.
53454         * modules/save-cwd (Depends-on): Likewise.
53455         * modules/strftime (Depends-on): Likewise.
53456         * modules/userspec (Depends-on): Likewise.
53457         * modules/utimecmp (Depends-on): Likewise.
53458         * modules/xgetcwd (Depends-on): Likewise.
53459         * modules/xnanosleep (Depends-on): Likewise.
53460         * modules/xstrtod (Depends-on): Likewise.
53461         * modules/yesno (Depends-on): Likewise.
53462
53463 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
53464
53465         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
53466         needless checks.
53467
53468 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
53469
53470         Merge from coreutils.  Among other things,
53471         add bulletproofing for cases where stdin, stdout, or stderr are closed.
53472         * lib/fd-safer.c: New file.
53473         * lib/fcntl-safer.h, open-safer.c: Remove.
53474         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
53475         * lib/dup-safer.c: Include unistd-safer.h first.
53476         Don't include errno.h.
53477         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
53478         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
53479         * lib/file-type.c: Rely on file-type.h change.
53480         * lib/getloadavg.c: Include unistd-safer.h.
53481         (getloadavg): Use safer open.
53482         * lib/getusershell.c: Include "stdio-safer.h".
53483         (getusershell): Use safer fopen.
53484         * lib/long-options.c (long_options): Use NULL rather than 0.
53485         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
53486         'free'.
53487         * lib/modechange.c: Likewise.
53488         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
53489         (MODE_DONE): New constant.
53490         (struct mode_change): Remove 'next' member.
53491         (make_node_op_equals): New function; like the old one of the
53492         same name, except it allocates an array.
53493         (mode_compile, mode_create_from_ref): Use it.
53494         (mode_compile): Allocate result as an array, not a linked list.
53495         Parse octal string ourself, so that we catch mistakes like "+0".
53496         (mode_adjust): Arg is an array, not a linked list.
53497         * lib/modechange.c: Include stat-macros.h, xalloc.h.
53498         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
53499         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
53500         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
53501         Remove.  This is now stat-macros.h's job.
53502         (talloc): Remove.  All callers replaced by xalloc, so that
53503         our invokers don't have to worry about reporting memory failures.
53504         (make_node_op_equals): Remove.
53505         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
53506         New constants.
53507         (struct mode_change): Moved here from modechange.h.
53508         (mode_append_entry): Remove.
53509         (mode_compile): Remove MASKED_OPS arg, since it encouraged
53510         apps to have incorrect behavior.  Use simpler algorithm for head
53511         and tail.  Don't futz with umask; that's now the job of mode_adjust.
53512         Detect more invalid usages rather than having somewhat-random behavior.
53513         Don't insert an "a=" action, as that leads to incorrect behavior.
53514         (mode_compile, mode_create_from_ref): Return NULL on error instead
53515         of an enum, since now there's only one way to have an error.  All
53516         callers changed.
53517         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
53518         at the correct time.  Simplify calculation of "+u" and its ilk.
53519         Don't mishandle "+X".
53520         (mode_free): Remove "register" and localize decls.
53521         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
53522         (struct mode_change): Move to modechange.c; callers don't
53523         need to see this stuff.
53524         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
53525         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
53526         (mode_change, mode_adjust): Reflect the new signatures noted above.
53527         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
53528         that might redefine system include files.
53529         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
53530         (my_usleep): Use NULL rather than (void *) 0.
53531         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
53532         Use siginterrupt to specify that system calls should be interrupted.
53533         (rpl_nanosleep): Move initialization of suspended closer to call of
53534         my_usleep.
53535         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
53536         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
53537         (desirable_utmp_entry): New function.
53538         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
53539         using x2nrealloc, to simplify logic.
53540         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
53541         size calculation.  Do not assume utmp file is a regular file.
53542         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
53543         (READ_UTMP_CHECK_PIDS): New constant.
53544         * lib/save-cwd.c: Include unistd-safer.h.
53545         (save_cwd): Use fd_safer.
53546         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
53547         [!_LIBC] Include "stat-macros.h" instead.
53548         * lib/unistd-safer.h (fd_safer): New decl.
53549
53550 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
53551
53552         * modules/getloadavg (Depends-on): Add unistd-safer.
53553         * modules/getusershell (Depends-on): Add stdio-safer.
53554         * modules/lstat (Depends-on): Remove xalloc.
53555         * modules/mkstemp (Depends-on): Add stat-macros.
53556         * modules/modechange (Depends-on): Remove xstrtol.
53557         Add stat-macros, xalloc.
53558         * modules/save-cwd (Depends-on): Add unistd-safer.
53559         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
53560         * modules/unistd-safer (Files): Add lib/fd-safer.c
53561         (Makefile.am): Remove lib_SOURCES.
53562
53563         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
53564         Remove fcntl-safer; unistd-safer supersedes it.
53565
53566 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
53567
53568         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
53569         AC_HEADER_STAT.
53570         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
53571         (gl_PREREQ_CHOWN): Remove.
53572         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
53573         it.  Don't require AC_HEADER_STAT.
53574         (gl_PREREQ_LSTAT): Remove.
53575         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
53576         Don't require AC_HEADER_STAT.
53577         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
53578         (gl_PREREQ_RMDIR): Remove.
53579         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
53580         mention stat-macros.h or AC_HEADER_STAT, since we'll make
53581         the stat-macros module a prerequisite.
53582         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
53583         * m4/filemode.m4 (gl_FILEMODE): Likewise.
53584         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
53585         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
53586         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
53587         variable names.
53588         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
53589         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
53590         variable prefixes.
53591         * m4/fcntl-safer.m4: Remove.
53592         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
53593         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
53594         Invoke gl_PREREQ_FD_SAFER.
53595         (gl_PREREQ_FD_SAFER): New macro.
53596         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
53597         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
53598         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
53599         Remove duplicate call to AC_LIBOBJ(readutmp).
53600         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
53601
53602         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
53603         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
53604
53605 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
53606
53607         * MODULES.html.sh (Misc): Add byteswap.
53608
53609 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
53610
53611         * modules/getcwd (Depends-on): Add extensions.
53612         * modules/openat (Depends-on): Likewise.
53613
53614 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
53615
53616         * modules/byteswap: New file.
53617
53618 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
53619
53620         * m4/byteswap.m4: New file.
53621
53622 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
53623
53624         * lib/byteswap_.h: New file.
53625
53626 2005-04-25  Karl Berry  <karl@gnu.org>
53627
53628         * m4/gettext.m4: Update from GNU gettext 0.14.4.
53629
53630 2005-04-25  Albert Chin  <china@thewrittenword.com>
53631
53632         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
53633         Toolkit C bug.
53634
53635 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
53636
53637         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
53638         (func_ln_if_changed) Remove forcibly for no error message
53639         in case file does not exist.
53640
53641 2005-04-19  Simon Josefsson  <jas@extundo.com>
53642
53643         * gnulib-tool (Options): Make --symlink mean --symbolic.
53644
53645 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
53646
53647         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
53648
53649 2005-04-16  Simon Josefsson  <jas@extundo.com>
53650
53651         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
53652
53653 2005-04-15  Simon Josefsson  <jas@extundo.com>
53654
53655         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
53656
53657 2005-04-15  Simon Josefsson  <jas@extundo.com>
53658
53659         * gnulib-tool: Rename --symlink to --symbolic.
53660
53661 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
53662
53663         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
53664         symbolic links to files instead of copying/moving.  Add --aux-dir,
53665         specifying directory relative --dir where auxiliary build tools
53666         are placed.
53667
53668 2005-04-14  Bruno Haible  <bruno@clisp.org>
53669
53670         * modules/allocsa (License): Change to LGPL.
53671         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
53672
53673 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
53674
53675         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
53676         that "UTC +1 second" continues to work.  Problem reported
53677         by Dmitry V. Levin.
53678         (relunit_snumber): New rule.
53679         (relunit): Use it.
53680
53681 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
53682
53683         * lib/getdate.y (universal_time_zone_table): New constant.
53684         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
53685         universal_time_zone_table.
53686         (lookup_zone): Prefer universal_time_zone_table to
53687         local_time_zone_table, so that "GMT" time stamps are allowed in
53688         London during the summer.  Problem reported by Ian Abbott.
53689
53690 2005-04-12  Jim Meyering  <jim@meyering.net>
53691
53692         * lib/human.c (humblock): Set *options even when returning due to
53693         xstrtoumax conversion failure.  Thanks to a used-uninitialized
53694         warning from gcc-4.
53695
53696 2005-04-09  Jim Meyering  <jim@meyering.net>
53697
53698         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
53699         -Wuninitialized: initialize tm0.tm_year.
53700
53701 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
53702
53703         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
53704         count, since there's no maximum.  All uses changed.
53705         Add member dsts_seen.
53706         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
53707         not being INT_MAX.
53708         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
53709         Use pc_rels_seen to decide whther a date is absolute.
53710
53711         * lib/getdate.y (number): Don't overwrite year.
53712         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
53713         check.
53714
53715 2005-04-02  Simon Josefsson  <jas@extundo.com>
53716
53717         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
53718         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
53719
53720 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
53721
53722         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
53723         where no absolute path name can be longer than PATH_MAX.
53724
53725 2005-03-27  Jim Meyering  <jim@meyering.net>
53726
53727         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
53728
53729 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
53730
53731         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
53732         "one's complement" -> "ones' complement" in comment, as per Knuth.
53733         "value of type" -> "type or expression" in comment.
53734         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
53735
53736 2005-03-26  Jim Meyering  <jim@meyering.net>
53737
53738         Comment nits.
53739         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
53740         Correct typos: s/or/of/.
53741
53742 2005-03-26  Jim Meyering  <jim@meyering.net>
53743
53744         * modules/check-include-files: Move to ../ and rename to...
53745         * check-module: ...this.
53746
53747 2005-03-25  Jim Meyering  <jim@meyering.net>
53748
53749         * modules/xvasprintf (Files): Add xalloc.h.
53750
53751 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
53752
53753         * modules/gettext (Files): config/config.rpath ->
53754         build-aux/config.rpath
53755         * modules/iconv (Files): Likewise.
53756         Problem reported by Oskar Liljeblad.
53757
53758 2005-03-23  Jim Meyering  <jim@meyering.net>
53759
53760         * modules/check-include-files: New script to check for
53761         missing dependencies, multiple includes, etc.
53762
53763         * modules/c-strtold (Depends-on): Add xalloc.
53764         * modules/c-strtod (Depends-on): Add xalloc.
53765         * modules/hash (Depends-on): Add xalloc.
53766         (Files): Remove lib/xalloc.h.
53767
53768         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
53769         * modules/userspec (Files): Add lib/inttostr.h.
53770
53771 2005-03-23  Jim Meyering  <jim@meyering.net>
53772
53773         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
53774
53775 2005-03-22  Jim Meyering  <jim@meyering.net>
53776
53777         * modules/stat-macros: New module.
53778         * modules/canonicalize, modules/euidaccess, modules/file-type,
53779         * modules/filemode, modules/lchown, modules/makepath,
53780         * modules/rmdir, modules/stat: Depend on new stat-macros module
53781         rather than listing lib/stat-macros.h manually.
53782         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
53783
53784 2005-03-22  Jim Meyering  <jim@meyering.net>
53785
53786         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
53787
53788 2005-03-22  Bruno Haible  <bruno@clisp.org>
53789
53790         * config/srclist.txt: Replace target directory 'config' with
53791         'build-aux'.
53792         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
53793         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
53794         ../build-aux/.
53795
53796 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
53797
53798         * modules/chdir-long (Depends-on): Add mempcpy.
53799
53800         * modules/acl, modules/backupfile, modules/c-strtod,
53801         modules/c-strtold, modules/canon-host, modules/canonicalize,
53802         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
53803         modules/exclude, modules/exitfail, modules/file-type,
53804         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
53805         modules/getdate, modules/getline, modules/getpagesize,
53806         modules/getpass, modules/getugroups, modules/group-member,
53807         modules/hard-locale, modules/hash, modules/human, modules/idcache,
53808         modules/inttostr, modules/long-options, modules/makepath,
53809         modules/md5, modules/memcasecmp, modules/memcoll,
53810         modules/modechange, modules/mountlist, modules/path-concat,
53811         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
53812         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
53813         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
53814         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
53815         modules/strftime, modules/strndup, modules/strverscmp,
53816         modules/timespec, modules/unlocked-io, modules/userspec,
53817         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
53818         modules/yesno:
53819         Remove lib_SOURCES line from Makefile.am section, as this is now
53820         done automatically by the corresponding Autoconf macro.
53821
53822 2005-03-21  Jim Meyering  <jim@meyering.net>
53823
53824         Changes imported from coreutils.
53825
53826         * lib/cycle-check.c: Don't include xalloc.h.
53827
53828         * lib/path-concat.c: Don't include assert.h.
53829         (path_concat): Remove assertion that would have triggered
53830         for ABASE starting with more than one slash.
53831         Reported by Andreas Schwab.
53832
53833         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
53834         properly when ABASE is an absolute file name.
53835         Correct the description of this function.
53836         Include <assert.h>.
53837         Add an assertion and a test driver.
53838         This fixes a bug introduced on 2004-07-02.
53839         Andreas Schwab reported the resulting failure of cp --parents:
53840         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
53841
53842 2005-03-21  Jim Meyering  <jim@meyering.net>
53843
53844         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
53845         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
53846
53847 2005-03-21  Jim Meyering  <jim@meyering.net>
53848         and  Paul Eggert  <eggert@cs.ucla.edu>
53849
53850         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
53851         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
53852         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
53853         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
53854         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
53855         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
53856         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
53857         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
53858         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
53859         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
53860         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
53861         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
53862         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
53863         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
53864         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
53865         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
53866         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
53867         for these modules.
53868
53869 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
53870
53871         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
53872         (which shouldn't happen), generate nothing instead of returning 0
53873         immediately, so that nstrftime (NULL, ...) doesn't return 0.
53874
53875 2005-03-16  Bruno Haible  <bruno@clisp.org>
53876
53877         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
53878         HAVE_LONGLONG_64BIT.
53879
53880 2005-03-16  Bruno Haible  <bruno@clisp.org>
53881
53882         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
53883         HAVE_LONGLONG_64BIT.
53884
53885 2005-03-16  Bruno Haible  <bruno@clisp.org>
53886
53887         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
53888         HAVE_LONGLONG_64BIT.
53889
53890 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
53891
53892         * lib/strftime.c (my_strftime): Prepend space to format so that we can
53893         reliably distinguish strftime failure from empty output on POSIX
53894         hosts.
53895
53896 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
53897
53898         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
53899         (iconv_string): Don't guess a size-zero buffer, as that might cause
53900         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
53901         result would be 'too large', where 'too large' is (heuristically)
53902         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
53903         overflow concerns.  This will prevent some unwanted malloc failures
53904         when the inputs are very large.
53905
53906 2005-03-15  Karl Berry  <karl@gnu.org>
53907
53908         * config/srclist.txt (config.rpath): from gettext.
53909         * config/config.rpath: update.
53910
53911 2005-03-15  Bruno Haible  <bruno@clisp.org>
53912
53913         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
53914         to 'negate'.
53915
53916         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
53917         variable.
53918
53919         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
53920         results.
53921
53922 2005-03-14  Simon Josefsson  <jas@extundo.com>
53923
53924         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
53925         <fx@gnu.org>.
53926
53927 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
53928
53929         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
53930         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
53931         intprops.h.
53932         * lib/strtol.c: Likewise.
53933
53934 2005-03-14  Jim Meyering  <jim@meyering.net>
53935
53936         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
53937         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
53938         to be nonzero so that we (and caller) can detect the difference
53939         between a valid zero-length expansion and an error return, even
53940         when the underlying strftime fails before writing anything into
53941         that location.
53942
53943 2005-03-14  Bruno Haible  <bruno@clisp.org>
53944
53945         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
53946         Update from GNU gettext 0.14.3.
53947
53948 2005-03-10  Jim Meyering  <jim@meyering.net>
53949
53950         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
53951
53952 2005-03-10  Jim Meyering  <jim@meyering.net>
53953
53954         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
53955         so that this module works on systems without fchdir.
53956
53957 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
53958
53959         Factor int-properties macros into a single file, except for
53960         glibc-related files.
53961         * lib/intprops.h: New file.
53962         * lib/getloadavg.c: Include it instead of limits.h.
53963         (INT_STRLEN_BOUND): Remove.
53964         * lib/human.c: Include intprops.h.
53965         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
53966         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
53967         302/1000.
53968         * lib/inttostr.h: Include intprops.h instead of limits.h.
53969         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
53970         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
53971         for consistency with intprops.h.
53972         (time_t_is_integer, twos_complement_arithmetic): Use them.
53973         * lib/sig2str.h: Include <signal.h>, intprops.h.
53974         (INT_STRLEN_BOUND): Remove.
53975         * lib/strftime.c (TYPE_SIGNED): Remove.
53976         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
53977         * lib/strtol.c: Adjust comments to match intprops.h.
53978         * lib/userspec.c: Include intprops.h.
53979         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
53980         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
53981         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
53982         instead of rolling our own expressions.
53983         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
53984
53985         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
53986         instead of int.
53987         (my_strftime): Do not mishandle years close to INT_MAX, by doing
53988         the right thing even if adding 1900 would overflow.  Similarly
53989         for tm_mon + 1 and tm_yday + 1.
53990         Make %Y always equivalent to %C%y, and similarly for %G and %g.
53991         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
53992         (DO_SIGNED_NUMBER): New macro.
53993         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
53994
53995 2005-03-07  Bruno Haible  <bruno@clisp.org>
53996
53997         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
53998
53999 2005-03-07  Bruno Haible  <bruno@clisp.org>
54000
54001         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
54002
54003 2005-03-04  Derek R. Price  <derek@ximbiot.com>
54004
54005         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
54006         (func_import): Only replace files via --import when they have actually
54007         changed.
54008
54009 2005-03-03  Derek R. Price  <derek@ximbiot.com>
54010
54011         * m4/mmap-anon.m4: New file.
54012         * m4/pagealign_alloc.m4: New file.
54013
54014 2005-03-03  Derek R. Price  <derek@ximbiot.com>
54015             Bruno Haible  <bruno@clisp.org>
54016
54017         * modules/pagealign_alloc: New file.
54018         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
54019
54020 2005-03-03  Derek R. Price  <derek@ximbiot.com>
54021             Bruno Haible  <bruno@clisp.org>
54022
54023         * lib/pagealign_alloc.h: New file.
54024         * lib/pagealign_alloc.c: New file.
54025
54026 2005-03-03  Bruno Haible  <bruno@clisp.org>
54027
54028         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
54029         Use an all-permissive copyright notice, recommended by RMS.
54030
54031 2005-03-02  Bruno Haible  <bruno@clisp.org>
54032
54033         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
54034         of AIX, the replacement has to be done only after <string.h> is
54035         included, therefore not in config.h. stpncpy.h does the replacement,
54036         and stpncpy.c uses it.
54037
54038 2005-03-02  Bruno Haible  <bruno@clisp.org>
54039
54040         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
54041         stpncpy.c uses it.
54042
54043 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
54044
54045         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
54046         The workaround isn't strictly needed for POSIX conformance, and
54047         it's too much of a pain to configure and maintain.  We'll ask
54048         people to fix their kernels instead.
54049         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
54050         (NANOSLEEP_BUG_WORKAROUND): Remove.
54051         (xnanosleep): Remove the workaround.
54052
54053 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
54054
54055         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
54056         Reported by Derek Price.
54057         (Include): Add "timespec.h".
54058
54059         * modules/xnanosleep (Depends-on): Remove gethrxtime.
54060
54061 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
54062
54063         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
54064         to detect nanosleep bug.
54065
54066 2005-03-01  Bruno Haible  <bruno@clisp.org>
54067
54068         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
54069
54070 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
54071
54072         * modules/gethrxtime: New file.
54073         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
54074         (Depends-on): Add gethrxtime.
54075         (configure.ac): Add gl_XNANOSLEEP.
54076         (Makefile.am): Remove lib_SOURCES line.
54077
54078 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
54079
54080         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
54081         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
54082
54083 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
54084
54085         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
54086         * lib/timespec.h (gettime): Return void, since it always
54087         succeeds now.  All uses changed.
54088         * lib/gettime.c (gettime) Likewise.
54089         [HAVE_NANOTIME]: Prefer nanotime.
54090         Assume gettimeofday succeeds, as POSIX requires.
54091         Assime time () succeeds, since other code already does.
54092         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
54093         (timespec_subtract): Remove.
54094         (NANOSLEEP_BUG_WORKAROUND): New constant.
54095         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
54096         things considerably.  Use it only on GNU/Linux hosts, since the
54097         workaround shouldn't be needed elsewhere.
54098
54099 2005-02-24  Bruno Haible  <bruno@clisp.org>
54100
54101         * modules/gettext (Files): Add m4/glibc2.m4.
54102
54103 2005-02-24  Bruno Haible  <bruno@clisp.org>
54104
54105         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
54106         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
54107         * m4/progtest.m4:
54108         Update from GNU gettext 0.14.2.
54109         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
54110
54111 2005-02-24  Bruno Haible  <bruno@clisp.org>
54112
54113         * lib/localcharset.c: Update from GNU gettext 0.14.2.
54114         * lib/config.charset: Update from GNU gettext 0.14.2.
54115
54116 2005-02-24  Bruno Haible  <bruno@clisp.org>
54117
54118         * lib/gettext.h: Update from GNU gettext 0.14.2.
54119
54120 2005-02-23  Simon Josefsson  <jas@extundo.com>
54121
54122         * m4/iconvme.m4: New file.
54123
54124 2005-02-23  Jim Meyering  <jim@meyering.net>
54125
54126         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
54127         change.
54128         Thanks to Bruno Haible for catching it.
54129
54130 2005-02-22  Simon Josefsson  <jas@extundo.com>
54131
54132         * modules/iconvme: New file.
54133
54134         * MODULES.html.sh: Add iconvme.
54135
54136 2005-02-22  Simon Josefsson  <jas@extundo.com>
54137
54138         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
54139
54140 2005-02-22  Simon Josefsson  <jas@extundo.com>
54141
54142         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
54143
54144 2005-02-22  Jim Meyering  <jim@meyering.net>
54145
54146         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
54147         s/ifndef/ifdef/.
54148
54149 2005-02-20  Neil Conway  <neilc@samurai.com>
54150
54151         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
54152         returned by OSX/Darwin if the specified buffer is not large
54153         enough for the hostname.
54154
54155 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54156
54157         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
54158         pass it to _help, otherwise the latter coredumps trying to
54159         dereference state.root_argp.
54160
54161 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
54162
54163         * modules/chdir-long (Depends-on): Add memrchr.
54164         * modules/memrchr (Files): Add lib/memrchr.h.
54165         (Include): "memrchr.h".
54166
54167 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
54168
54169         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
54170
54171 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
54172
54173         * lib/memrchr.h: New file.
54174         * lib/chdir-long.c: Include it.
54175         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
54176         Don't bother including stddef.h.
54177
54178 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
54179
54180         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
54181         inclusion.
54182         Include <sys/types.h>, for dev_t.
54183         (ME_DUMMY, ME_REMOTE): Move from here....
54184         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
54185         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
54186         Dmitry V. Levin.
54187         Include mountlist.h first, to test the interface.
54188
54189 2005-01-29  Bruno Haible  <bruno@clisp.org>
54190
54191         * lib/progname.c (program_name): Initialize.
54192         Needed when linking statically on MacOS X.
54193
54194 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
54195
54196         Sync from coreutils.
54197         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
54198         (Depends-on): Add c-strtod.
54199         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
54200
54201 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
54202
54203         Sync from coreutils.
54204         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
54205
54206         Remove files that are specific to coreutils.
54207         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
54208
54209 2005-01-28  Bruno Haible  <bruno@clisp.org>
54210
54211         * modules/javacomp: New file.
54212         * MODULES.html.sh (Java): Add javacomp.
54213
54214 2005-01-28  Bruno Haible  <bruno@clisp.org>
54215
54216         * m4/javacomp.m4: New file, from GNU gettext.
54217
54218 2005-01-28  Bruno Haible  <bruno@clisp.org>
54219
54220         * lib/javacomp.sh.in: New file, from GNU gettext.
54221         * lib/javacomp.h: New file, from GNU gettext.
54222         * lib/javacomp.c: New file, from GNU gettext.
54223
54224 2005-01-26  Simon Josefsson  <jas@extundo.com>
54225
54226         * lib/gai_strerror.c: Use GPL in header.
54227
54228 2005-01-26  Bruno Haible  <bruno@clisp.org>
54229
54230         * modules/javaexec: New file.
54231         * MODULES.html.sh (Java): Add javaexec.
54232
54233 2005-01-26  Bruno Haible  <bruno@clisp.org>
54234
54235         * m4/javaexec.m4: New file, from GNU gettext.
54236
54237 2005-01-26  Bruno Haible  <bruno@clisp.org>
54238
54239         * lib/javaexec.sh.in: New file, from GNU gettext.
54240         * lib/javaexec.h: New file, from GNU gettext.
54241         * lib/javaexec.c: New file, from GNU gettext.
54242
54243 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54244
54245         * modules/lchown (Depends-on): Remove lchown.h
54246
54247 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54248
54249         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
54250         must be defined if the header file was not found, in order
54251         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
54252
54253 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54254
54255         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
54256         initializers for struct pentry_state.
54257         (__argp_error): Check return value of __asprintf
54258         (__argp_failure): Translate error message
54259
54260         * lib/argp-parse.c: Removed braces around the expansion of N_()
54261
54262 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
54263
54264         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
54265         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
54266         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
54267         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
54268         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
54269         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
54270         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
54271         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
54272         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
54273         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
54274         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
54275         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
54276         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
54277         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
54278         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
54279         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
54280         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
54281         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
54282         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
54283         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
54284         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
54285         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
54286         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
54287         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
54288         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
54289         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
54290         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
54291         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
54292         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
54293         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
54294         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
54295         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
54296         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
54297         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
54298         xstrtol.m4, xstrtoumax.m4, yesno.m4:
54299         Use an all-permissive copyright notice, recommended by RMS.
54300
54301 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
54302
54303         * modules/chdir-long (Depends-on): Remove mempcpy.
54304
54305 2005-01-21  Jim Meyering  <jim@meyering.net>
54306
54307         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
54308         same value as for Solaris 9.
54309
54310         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
54311         component length.  This included changing the parameter to be
54312         of type `char *' rather than `char const *'.
54313         * lib/chdir-long.h (chdir_long): Update prototype.
54314
54315         * lib/openat.c (fdopendir, fstatat): New functions.
54316         * lib/openat.h: Include headers required for use of DIR and struct
54317         stat.
54318         [AT_SYMLINK_NOFOLLOW]: Define.
54319         (fdopendir, fstatat): Add prototypes.
54320
54321 2005-01-21  Bruno Haible  <bruno@clisp.org>
54322
54323         * modules/classpath: New file.
54324         * MODULES.html.sh (Java): Add classpath.
54325
54326 2005-01-21  Bruno Haible  <bruno@clisp.org>
54327
54328         * lib/classpath.h: New file, from GNU gettext.
54329         * lib/classpath.c: New file, from GNU gettext.
54330
54331 2005-01-20  Simon Josefsson  <jas@extundo.com>
54332
54333         * modules/version-etc-fsf: New file.
54334
54335 2005-01-20  Simon Josefsson  <jas@extundo.com>
54336
54337         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
54338         * lib/version-etc.c: Remove version_etc_copyright.
54339         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
54340         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
54341
54342 2005-01-20  Simon Josefsson  <jas@extundo.com>
54343
54344         * lib/base64.h (isbase64): Add.
54345
54346         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
54347         using a unsigned prototype, don't inline.
54348         (base64_decode): Use it.
54349
54350 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
54351
54352         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
54353         it.
54354
54355 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
54356
54357         * lib/save-cwd.c (save_cwd): Remove code to support the case
54358         where fchdir is missing or flaky.
54359
54360 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
54361
54362         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
54363
54364 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
54365
54366         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
54367         AC_LIBSOURCES now does this.
54368         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
54369         with new ullong_max module.
54370
54371 2005-01-19  Bruno Haible  <bruno@clisp.org>
54372
54373         * modules/sh-quote: New file.
54374         * MODULES.html.sh (Executing programs): Add sh-quote.
54375
54376 2005-01-19  Bruno Haible  <bruno@clisp.org>
54377
54378         * lib/sh-quote.h: New file, from GNU gettext.
54379         * lib/sh-quote.c: New file, from GNU gettext.
54380
54381 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
54382
54383         Merge from coreutils.
54384         * m4/ullong_max.m4: New file.
54385         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
54386         (gl_MACROS): Assume localeconv exists.
54387
54388 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
54389
54390         Merge changes from coreutils, as described below in several
54391         changelogs dated today.
54392
54393         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
54394         (O_DIRECTORY): Remove; not needed here, since "." must be
54395         a directory.  All uses removed.
54396         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
54397         universal on Suns, and we also need to test for IRIX.
54398         Revamp code to use 'if' rather than '#if'.
54399         Avoid unnecessary comparison of cwd->desc to 0.
54400
54401         * lib/utimens.c (futimens): Robustify the previous patch, by checking
54402         for known valid error numbers rather than observed invalid ones.
54403
54404 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
54405
54406         * modules/ullong_max: New file.
54407
54408         * modules/chdir-long, modules/openat: New files.
54409         * modules/save-cwd (Depends-on): Depend on chdir-long.
54410         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
54411
54412 2005-01-18  Jim Meyering  <jim@meyering.net>
54413
54414         Merge from coreutils.
54415         * m4/chdir-long.m4, m4/openat.m4: New files.
54416         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
54417         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
54418         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
54419         is sane and DOES follow symlinks.  Besides, testing 20 different
54420         systems found no broken chown implementations.
54421         Prompted by a change in rsync's copy of this macro.
54422         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
54423
54424         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
54425
54426         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
54427         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
54428         NULL-means-set-to-current-time semantics.
54429         Remove temporary file immediately, rather than waiting
54430         for configure's at-exit trap code to do it.
54431
54432 2005-01-18  Jim Meyering  <jim@meyering.net>
54433
54434         * lib/version-etc.c (version_etc_copyright): Update copyright date.
54435
54436         * lib/utimens.c (futimens): Account for the fact that futimes
54437         can also fail with errno == ENOSYS or errno == ENOENT.
54438         Patch from Dmitry V. Levin.
54439
54440         Change the name of the robust chdir function from chdir to chdir_long.
54441         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
54442         (restore_cwd): Use chdir_long, not chdir.
54443         * lib/chdir-long.c: Renamed from chdir.c.
54444         * lib/chdir-long.h: Renamed from chdir.h.
54445         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
54446         Hurd.
54447
54448 2005-01-18  Bruno Haible  <bruno@clisp.org>
54449
54450         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
54451         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
54452         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
54453         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
54454         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
54455         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
54456         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
54457         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
54458         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
54459         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
54460         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
54461         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
54462         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
54463         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
54464         Use an all-permissive copyright notice, recommended by RMS.
54465
54466 2005-01-18  Bob Proulx  <bob@proulx.com>
54467
54468         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
54469         simplify offsetof() macro construct to avoid compile failure with
54470         native HP-UX 11.0 ANSI C compiler.
54471
54472 2005-01-17  Bruno Haible  <bruno@clisp.org>
54473
54474         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
54475         redundant because stpncpy.m4 takes care of it.
54476
54477 2005-01-17  Bruno Haible  <bruno@clisp.org>
54478
54479         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
54480
54481 2005-01-17  Bruno Haible  <bruno@clisp.org>
54482
54483         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
54484         used.
54485
54486 2005-01-17  Bruno Haible  <bruno@clisp.org>
54487
54488         * lib/fwriteerror.h (fwriteerror): Change specification to include
54489         fclose.
54490         * lib/fwriteerror.c: Include <stdbool.h>.
54491         (fwriteerror): At the end, close the file stream. Record whether
54492         stdout was already closed.
54493
54494 2005-01-17  Bruno Haible  <bruno@clisp.org>
54495
54496         * lib/execute.c (environ): Declare if needed.
54497         * lib/pipe.c (environ): Likewise.
54498         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
54499
54500 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54501
54502         * modules/argp: Depend on vsnprintf
54503
54504 2005-01-10  Jim Meyering  <jim@meyering.net>
54505
54506         * modules/closeout (Depends-on): Add atexit.
54507
54508 2005-01-06  Bruno Haible  <bruno@clisp.org>
54509
54510         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
54511
54512 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
54513
54514         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
54515         definitions to be after all include files, to avoid collisions.
54516         Problem reported by Bob Proulx.
54517
54518 2005-01-04  Jim Meyering  <jim@meyering.net>
54519
54520         Changes imported from coreutils.
54521         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
54522         as the mkstemp template, use a temporary directory and an
54523         8.3-friendly template to avoid trouble on systems like DJGPP.
54524         Reported by Juan M. Guerrero via Stepan Kasal.
54525         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
54526         close. Remove the temporary directory right away, rather than waiting
54527         for configure's at-exit trap code to do it.
54528         Suggestion from Stepan Kasal.
54529
54530 2005-01-01  Simon Josefsson  <jas@extundo.com>
54531
54532         * gnulib-tool: Print #include directives when --import'ing.
54533
54534 2004-12-28  Simon Josefsson  <jas@extundo.com>
54535
54536         * tests/test-base64.c: Include required header files.  Remove
54537         unused variables.
54538
54539 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
54540
54541         * modules/error (Depends-on): Remove gettext.
54542
54543 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
54544
54545         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
54546         not needed.  This removes a dependency on the gettext module.
54547         [defined _LIBC]: Do not include <libintl.h>; not needed.
54548
54549 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
54550
54551         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
54552         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
54553
54554 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
54555
54556         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
54557         HAVE_DECL_STRTOLD.
54558
54559 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
54560
54561         * modules/getdate (Depends-on): Remove alloca-opt.
54562
54563 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
54564
54565         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
54566
54567 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
54568
54569         * lib/argp-parse.c: Include <stddef.h>.
54570         (alignof, alignto): New macros.
54571         (parser_init): Don't assume that void * is aligned sufficiently
54572         for struct option.
54573
54574         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
54575         need to extend the stack.
54576         (YYINITDEPTH): New macro, so that the initial stack isn't overly
54577         large.
54578
54579 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54580
54581         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
54582
54583 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
54584
54585         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
54586         (2004-10-24) change.  Apparently this was a false alarm.
54587
54588         * modules/getdate: Depend on alloca-opt, not alloca.
54589
54590 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
54591
54592         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
54593         Remove now-obsolete comment about AIX.
54594         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
54595         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
54596         (YYMAXDEPTH): New macro.
54597
54598 2004-12-18  Simon Josefsson  <jas@extundo.com>
54599
54600         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
54601
54602 2004-12-18  Bruno Haible  <bruno@clisp.org>
54603
54604         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
54605
54606 2004-12-18  Bruno Haible  <bruno@clisp.org>
54607
54608         * lib/fatal-signal.c (fatal_signals): Make non-const.
54609         (init_fatal_signals): New function.
54610         (uninstall_handlers, install_handlers): Ignore signals that were set to
54611         SIG_IGN.
54612         (at_fatal_signal): Call init_fatal_signals.
54613         (init_fatal_signal_set): Likewise. Ignore signals that were set to
54614         SIG_IGN.
54615         Reported by Paul Eggert.
54616
54617 2004-12-18  Bruno Haible  <bruno@clisp.org>
54618
54619         * doc/alloca.texi: New file.
54620         * doc/alloca-opt.texi: New file.
54621
54622 2004-12-17  Jim Meyering  <jim@meyering.net>
54623
54624         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
54625         Otherwise, install-sh could exit with improper exit status when
54626         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
54627
54628 2004-12-16  Simon Josefsson  <jas@extundo.com>
54629
54630         * tests/test-base64.c: Add license.
54631
54632 2004-12-15  Stepan Kasal  <address@hidden>
54633
54634         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
54635
54636 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
54637
54638         * modules/getcwd (Files): Add m4/d-ino.m4.
54639         Suggested by Mark D. Baushke.
54640
54641 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
54642
54643         * lib/getdate.y (textint): New member "negative".
54644         (time_zone_hhmm): New function.
54645         Expect 14 shift-reduce conflicts, not 13.
54646         (o_colon_minutes): New rule.
54647         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
54648         (yylex): Set the "negative" member of signed numbers.
54649
54650 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
54651
54652         * doc/getdate.texi (Time of day items, Time zone items):
54653         Describe new formats +00:00, UTC+00:00.
54654
54655 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
54656
54657         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
54658         spurious "-l"s.  Problem reported by Stepan Kasal.
54659
54660 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
54661
54662         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
54663         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
54664
54665 2004-12-04  Simon Josefsson  <jas@extundo.com>
54666
54667         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
54668         Vandoorselaere <yoann@prelude-ids.org>.
54669
54670 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
54671
54672         Changes imported from coreutils.
54673         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
54674         exist.
54675         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
54676
54677 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
54678
54679         Changes imported from coreutils.
54680         * lib/hard-locale.c: Assume <locale.h> exists.
54681         Include "strdup.h".
54682         (GLIBC_VERSION): New macro.
54683         (hard_locale): Assume setlocale exists.
54684         Rewrite to avoid #ifdef.
54685         Use strdup rather than malloc + strcpy.
54686         * lib/human.c: Assume <locale.h> exists.
54687         (human_readable): Assume localeconv exists.
54688
54689 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
54690
54691         * modules/hard-locale (Depends-on): Add strdup.
54692
54693 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
54694
54695         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
54696         convert T2, not T.  (Imported from libc.)
54697
54698 2004-11-30  Simon Josefsson  <jas@extundo.com>
54699
54700         * modules/restrict (License): Change to LGPL.
54701
54702 2004-11-30  Simon Josefsson  <jas@extundo.com>
54703
54704         * m4/restrict.m4: Add copyright and copying conditions.
54705
54706 2004-11-30  Simon Josefsson  <jas@extundo.com>
54707
54708         * m4/base64.m4: New file.
54709
54710 2004-11-30  Simon Josefsson  <jas@extundo.com>
54711
54712         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
54713         base64.
54714
54715         * tests/test-base64.c: New file.
54716
54717         * modules/base64: New file.
54718
54719 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
54720
54721         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
54722         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
54723
54724         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
54725
54726 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
54727
54728         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
54729         (__getcwd.c): Don't restore errno; glibc doesn't.
54730         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
54731         first, falling back to our code only if its results look suspicious.
54732         Ensure that the resulting buffer is only as large as necessary.
54733
54734         * lib/readutmp.c: Include readutmp.h first.
54735         Include <errno.h>, since readutmp.h no longer does that.
54736         * lib/readutmp.h: Don't include <errno.h>,
54737         <sys/param.h>, <time.h>; not needed to establish interface.
54738         (errno): Remove decl.
54739         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
54740         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
54741         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
54742
54743 2004-11-28  Simon Josefsson  <jas@extundo.com>
54744
54745         * lib/base64.h, base64.c: New file.
54746
54747 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
54748
54749         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
54750
54751 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
54752
54753         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
54754         (Depends-on): Remove pathmax, same.  Add mempcpy.
54755         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
54756         (Makefile.am): Append getcwd.h to lib_SOURCES.
54757         (Include): Add getcwd.h.
54758         (Maintainer): Change from Jim Meyering to "all, glibc",
54759         since getdate now uses intended-for-glibc code.
54760         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
54761         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
54762
54763 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
54764
54765         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
54766         HP's ANSI C compiler.
54767         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
54768         Declaring int functions causes warnings on some modern systems and
54769         shouldn't be needed to compile on ancient ones.
54770         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
54771         defined.
54772
54773         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
54774         with the following changes.
54775         (__set_errno): Parenthesize properly.
54776         Include <stdbool.h>.
54777         (MIN, MAX, MATCHING_INO): New macros.
54778         (__getcwd): Define with prototype, not K&R form.
54779         Use heuristics to allocate default buffer on stack if possible.
54780         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
54781         behavior, and to avoid the PATH_MAX limit when computing
54782         ../../../../...
54783         Use MATCHING_INO to compare inode number to file.
54784         Check for arithmetic overflow in size calculations.
54785         Fix bug in reallocation of dot array that caused getcwd to fail
54786         on directories nested deeper than 75.
54787         Be more careful about saving errno on error.
54788         Do not use realloc; use only free+malloc, as this is a bit
54789         more flexible and avoids a needless copy operation.
54790         Do not inspect st_dev and st_ino for symbolic links; POSIX
54791         doesn't specify the latter.
54792         Check for closedir errors.
54793         Avoid needless casts.
54794         Use "#ifdef weak_alias" around weak_alias, to be like other
54795         glibc code.
54796         The following changes to getcwd.c have effect only when used in
54797         gnulib; they have no effect inside glibc proper.
54798         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
54799         as alloca isn't used.
54800         (alloca, __alloca): Likewise.
54801         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
54802         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
54803         unconditionally, as gnulib assumes C89 or better.
54804         Do not include <sys/param.h>.
54805         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
54806         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
54807         better.
54808         (NULL) [!defined NULL]: Remove; we assume C89 or better.
54809         Include <dirent.h> in a way that is compatible with modern Autoconf.
54810         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
54811         New macros, if not already defined.
54812         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
54813         Use "_LIBC", not "defined _LIBC", for consistency.
54814         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
54815         a mempcpy module.
54816         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
54817         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
54818         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
54819         credit only to Jim Meyering and adjust the copyright dates.
54820         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
54821         <stdlib.h>, <unistd.h>, "pathmax.h".
54822         Instead, include "xgetcwd.h" (first) and "getcwd.h".
54823         (INITIAL_BUFFER_SIZE): Remove.
54824         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
54825
54826 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
54827
54828         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
54829         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
54830         Use the _ONCE methods, for efficiency.
54831         Check for fcntl.h.  In test program, include <errno.h>
54832         and <fcntl.h> if available.  Remove old K&R cruft from
54833         test program.  Check for common errors in GNU/Linux,
54834         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
54835         don't do AC_LIBOBJ, as that's getcwd.m4's job.
54836         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
54837         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
54838         name accordingly.
54839         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
54840         accommodate new getcwd.c.
54841         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
54842         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
54843         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
54844         that's all we need now.
54845
54846 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54847
54848         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
54849         argp-parse.c depends on getopt internals, that means we should
54850         always use our getopt, to be on the safe side.
54851         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
54852         order not to spoil the result of an eventual previous invocation
54853         of gl_GETOPT_SUBSTITUTE.
54854
54855 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
54856
54857         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
54858         redefinition warnings. To avoid them, include the defines
54859         in `#if !defined __need_getopt ... #endif'. The only place
54860         where __getopt_argv_const is used is in definitions
54861         of getopt_long and getopt_long_only below, which are as well
54862         protected by `#ifndef __need_getopt'.
54863         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
54864         __need_getopt after including <stdio.h> and <unistd.h> These
54865         headers might have defined it.
54866
54867 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
54868
54869         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
54870
54871 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
54872
54873         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
54874         (futimens): New function, which uses futimes if available.
54875         (futimens, utimens): Support timespec==NULL, with same semantics
54876         as utime and utimens.
54877         * lib/utimens.h (futimens): New decl.
54878
54879 2004-11-23  Jim Meyering  <jim@meyering.net>
54880
54881         * lib/getopt_.h: Remove trailing blanks.
54882
54883 2004-11-23  Jim Meyering  <jim@meyering.net>
54884
54885         * lib/__fpending.c: Add comment.
54886
54887 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
54888
54889         * modules/canonicalize (Depends-on): Add xreadlink.
54890         Problem reported by James Youngman.
54891
54892 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
54893
54894         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
54895         New macros.
54896         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
54897         optopt): Use them instead of invoking ## directly; otherwise, the
54898         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
54899
54900 2004-11-19  Bruno Haible  <bruno@clisp.org>
54901
54902         * lib/strtok_r.c: Move comments from here...
54903         * lib/strtok_r.h: ... to here.
54904
54905 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
54906
54907         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
54908         implementations that mishandle size_t overflow.
54909
54910 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
54911
54912         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
54913         might fail.  Problem reported by Yoann Vandoorselaere.
54914         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
54915         implementations that mishandle size_t overflow.
54916
54917 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
54918
54919         * modules/canon-host (Depends-on): Add strdup.
54920
54921 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
54922
54923         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
54924
54925 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
54926
54927         * lib/canon-host.c: Include "strdup.h".
54928         (canon_host): Use getaddrinfo if available, so that IPv6 works.
54929         Use strdup instead of malloc/strcpy to duplicate strings.
54930
54931         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
54932         (human_space_before_unit): New constant.
54933         * lib/human.c (human_readable): Support it.
54934
54935         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
54936         (xgetcwd): Set errno correctly when failing.
54937         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
54938         the failure is actually due to a PATH_MAX problem.
54939
54940         Further getopt changes to make it more likely that glibc will
54941         buy the changes back.
54942         * lib/getopt.c (POSIXLY_CORRECT): New constant.
54943         (getopt): Use it, so to preserve glibc semantic
54944         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
54945         when compiling for libc.
54946         * lib/getopt_.h (__getopt_argv_const): Bring it back.
54947         (getopt_long, getopt_long_only): Use it.
54948
54949         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
54950         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
54951         (getopt): Argv is now char * const *, as per standard.
54952         (_getopt_internal_r, _getopt_internal): Argv is now char **,
54953         not char *__getopt_argv_const *.
54954         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
54955         _getopt_long_only_r): Likewise.
54956         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
54957         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
54958         _getopt_long_r, _getopt_long_only_r): Likewise.
54959         * lib/getopt_.h (__getopt_argv_const): Remove.
54960         (getopt): Argv is now char * const *, as per standard.
54961
54962         * lib/getdate.y (tORDINAL): New token.
54963         (day, relunit): Allow it for relative times.
54964         (relative_time_table): Use tORDINAL for ordinals.
54965
54966 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
54967
54968         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
54969         Document that "second" isn't allowed as an ordinal number.
54970
54971 2004-11-16  Jim Meyering  <jim@meyering.net>
54972
54973         * modules/closeout (Depends-on): Add fpending.
54974
54975 2004-11-15  Jim Meyering  <jim@meyering.net>
54976
54977         * lib/closeout.c: Include "__fpending.h" once again.
54978         Include <stdbool.h>.
54979         (close_stdout): Don't fail just because stdout was closed initially,
54980         since some programs don't write to stdout in the normal course of
54981         operation (other than --version and --help), and we don't want this
54982         function to make e.g. `touch file >&-' fail.
54983         But do fail if it was closed and someone has tried to write to it.
54984         E.g., `printf foo >&-' must fail.
54985
54986 2004-11-13  Jim Meyering  <jim@meyering.net>
54987
54988         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
54989
54990 2004-11-12  Simon Josefsson  <jas@extundo.com>
54991
54992         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
54993         small doc fix is still pending.
54994
54995 2004-11-11  Simon Josefsson  <jas@extundo.com>
54996
54997         * modules/strtok_r: New file.
54998
54999         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
55000         strtok_r.
55001
55002 2004-11-11  Simon Josefsson  <jas@extundo.com>
55003
55004         * m4/strtok_r.m4: New file.
55005
55006         * m4/getopt.m4: Replace opterr.
55007
55008 2004-11-11  Simon Josefsson  <jas@extundo.com>
55009
55010         * lib/strtok_r.h, strtok_r.c: New file.
55011
55012 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
55013
55014         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
55015         of replacing opterr, getopt, etc.  This should handle the
55016         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
55017
55018 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
55019
55020         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
55021         we can stop lying to compilers about the constness of argv when we
55022         are compiled outside glibc.
55023         (getopt, getopt_long, getopt_long_only): Use it.
55024         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
55025         _getopt_internal, getopt): Likewise.
55026         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
55027         _getopt_long_only_r): Likewise.
55028         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
55029         _getopt_long_r, _getopt_long_only_r): Likewise.
55030
55031         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
55032         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
55033         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
55034         the other external symbols.
55035         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
55036         declaration, since the above renaming now works around collisions.
55037
55038 2004-11-11  Jim Meyering  <jim@meyering.net>
55039
55040         * lib/linebreak.c: Remove trailing blanks.
55041         * lib/alloca_.h: Likewise.
55042         * lib/acosl.c: Likewise.
55043         * lib/euidaccess.c: Likewise.
55044         * lib/allocsa.h: Likewise.
55045
55046 2004-11-10  Simon Josefsson  <jas@extundo.com>
55047
55048         * m4/getaddrinfo.m4: New file.
55049
55050 2004-11-10  Simon Josefsson  <jas@extundo.com>
55051
55052         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
55053
55054 2004-11-10  Simon Josefsson  <jas@extundo.com>
55055
55056         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
55057         getaddrinfo.
55058
55059         * modules/getaddrinfo: New file.
55060
55061 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
55062
55063         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
55064
55065 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
55066
55067         * lib/mktime.c (SHR): New macro, which is a portable
55068         substitute for >> that should work even on Crays.
55069         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
55070         Problem reported by Mark D. Baushke in
55071         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
55072         * lib/getdate.y (SHR): Likewise.
55073         (tm_diff): Use it.
55074         * lib/strftime.c (SHR): Likewise.
55075         (tm_diff): Use it.
55076         * lib/quotearg.c (struct quoting_options): Use unsigned int for
55077         quote_these_too, so that right shifts are well defined.  All uses
55078         changed.
55079
55080 2004-11-10  Jim Meyering  <jim@meyering.net>
55081
55082         Ensure that no close failure goes unreported.
55083         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
55084         return early when it seems there's nothing to flush.
55085         Don't include __fpending.h.
55086
55087 2004-11-10  Jim Meyering  <jim@meyering.net>
55088
55089         * modules/closeout (Depends-on): Remove fpending.
55090
55091 2004-11-10  Jim Meyering  <jim@meyering.net>
55092
55093         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
55094
55095 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
55096
55097         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
55098         gl_FUNC_STRFTIME.
55099         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
55100         and AC_REQUIRE when possible, to avoid duplicate checks.
55101         Check for <wchar.h>.
55102
55103 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
55104
55105         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
55106
55107 2004-11-09  Bruno Haible  <bruno@clisp.org>
55108
55109         * m4/sockpfaf.m4: New file.
55110
55111 2004-11-05  Bruno Haible  <bruno@clisp.org>
55112
55113         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
55114         Reported by Mark D. Baushke <mdb@cvshome.org>.
55115
55116 2004-11-04  Bruno Haible  <bruno@clisp.org>
55117
55118         2004-09-11  Bruno Haible  <bruno@clisp.org>
55119                 * allocsa.valgrind: New file.
55120         2004-02-06  Bruno Haible  <bruno@clisp.org>
55121                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
55122                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
55123                 Reported by Christopher Seip <chris.seip@hp.com>.
55124
55125 2004-11-04  Bruno Haible  <bruno@clisp.org>
55126
55127         * modules/allocsa (Files): Add lib/allocsa.valgrind.
55128         (Makefile.am): Distribute it.
55129
55130 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
55131
55132         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
55133         with errno == ERANGE if the buffer is too small.
55134         Problem reported by Mark D. Baushke.
55135
55136 2004-11-03  Albert Chin  <china@thewrittenword.com>
55137             Paul Eggert  <eggert@cs.ucla.edu>
55138
55139         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
55140         equivalent, substitute $ac_type for equivalent type rather than
55141         blindly using uint32_t *always* which won't work if uint32_t is not
55142         available.  Define _UINT32_T to work around typedef of uint32_t if
55143         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
55144         2.5.1.
55145
55146 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
55147
55148         * m4/jm-macros.m4: Sync from coreutils.
55149         (gl_MACROS): Check for mbrlen, for pathchk.
55150         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
55151
55152 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
55153
55154         * lib/xreadlink.c (MAXSIZE): New macro.
55155         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
55156         size does not exceed MAXSIZE.  Avoid cast.
55157         As suggested by Mark D. Baushke in
55158         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
55159         if readlink fails with buffer size just under MAXSIZE, try again
55160         with MAXSIZE.
55161
55162 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
55163
55164         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
55165
55166 2004-11-02  Derek R. Price  <derek@ximbiot.com>
55167         and  Paul Eggert  <eggert@cs.ucla.edu>
55168
55169         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
55170         (get_date): Overparenthesize to avoid GCC warning.
55171
55172 2004-11-02  Bruno Haible  <bruno@clisp.org>
55173
55174         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
55175         returns void.
55176
55177 2004-11-02  Bruno Haible  <bruno@clisp.org>
55178
55179         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
55180         function returns void.
55181
55182 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
55183
55184         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
55185         fflush_unlocked, flockfile, funlockfile, funlockfile,
55186         fputs_unlocked, putc_unlocked.
55187
55188 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
55189
55190         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
55191         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
55192         already declared.
55193
55194 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
55195
55196         * modules/getdate (Files): Add doc/getdate.texi.
55197         (Depends-on): Add setenv, xalloc.
55198
55199 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
55200
55201         * lib/getdate.y: Add support for TZ="foo" within a date string.
55202         Fix some bugs near time_t boundaries.  Reject dates with
55203         out-of-range components, e.g., "Sept 31".
55204         Include <stdlib.h>, "setenv.h", "xalloc.h".
55205         (ISDIGIT_LOCALE): Remove; unused.
55206         Note that the TZ and time functions used here are not reentrant.
55207         (mktime_ok, get_tz): New functions.
55208         (TZBUFSIZE): New constant.
55209         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
55210         This requires that we sometimes generate our own TZ="XXX..." setting.
55211
55212 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
55213
55214         * doc/getdate.texi: New file, from coreutils with modifications for
55215         the new TZ parsing.
55216
55217 2004-10-27  Derek R. Price  <derek@ximbiot.com>
55218
55219         * lib/mktime.c (not_equal_tm): Remove redundant check.
55220
55221 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
55222
55223         * modules/regex (lib_SOURCES): Add regex.c.
55224         Reported by James Youngman in
55225         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
55226
55227 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
55228
55229         * lib/getdate.y: Use Bison 1.875 features, and some minor
55230         code cleanups.  This change does not affect semantics.
55231         Don't include <stdlib.h>; no longer needed.
55232         Don't include unlocked-io.h; only the "#if TEST" code uses
55233         stdio, and performance isn't crucial there.
55234         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
55235         Bison 1.875 features as described below.
55236         All uses of "PC." replaced by "pc->".
55237         (YYSTYPE): Add a forward declaration.
55238         (yylex, yyerror): Use full prototypes in forward decls.
55239         Use "%pure-parser" rather than obsolescent "%pure_parser".
55240         Use %parse-param and %lex-param instead of obsolescent
55241         YYPARSE_PARAM and YYLEX_PARAM.
55242         (meridian_table, month_and_day_table, time_units_table,
55243         relative_time_table, time_zone_table, military_table,
55244         lookup_zone, lookup_word, get_date):
55245         Use NULL instead of 0 where appropriate.
55246         (to_hour): Avoid abort (), to avoid a dependency on
55247         stdlib.h.
55248         (yyerror, yylex): Now accepts parser_control * arg.
55249         (main) [TEST]: Use '\0' rather than 0 for char.
55250
55251 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
55252
55253         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
55254
55255 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
55256
55257         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
55258         It's now the caller's responsibility to handle the case where
55259         !HAVE_GETPAGESIZE && !defined getpagesize.
55260
55261         * lib/mktime.c (leapyear): Arg is long int, not int.
55262
55263 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
55264
55265         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
55266
55267 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
55268
55269         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
55270         missing.  Problem reported by James Youngman.
55271
55272 2004-10-16  Simon Josefsson  <jas@extundo.com>
55273
55274         * gnulib-tool: Fix comments.  Fix parse problem.
55275         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
55276
55277 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
55278
55279         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
55280         implementation of getopt_long.  Problem reported by Alexander Taler in:
55281         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
55282
55283 2004-10-15  Bruno Haible  <bruno@clisp.org>
55284
55285         * gnulib-tool: Untabify. Initialize supplied_libname.
55286         (func_usage): More homogenous output.
55287         (func_modules_transitive_closure, func_modules_to_filelist,
55288         func_emit_lib_Makefile_am): New functions.
55289         (func_import): New function, extracted from big case statement. Use
55290         func_get_license, func_modules_transitive_closure,
55291         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
55292         opt_lgpl. Don't use test -a, as it's not portable.
55293         (func_create_testdir): Use func_modules_transitive_closure,
55294         func_modules_to_filelist, func_emit_lib_Makefile_am.
55295
55296 2004-10-15  Bruno Haible  <bruno@clisp.org>
55297
55298         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
55299
55300 2004-10-15  Bruno Haible  <bruno@clisp.org>
55301
55302         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
55303         the portions belonging to each module.
55304         Suggested by Derek Robert Price <derek@ximbiot.com>.
55305
55306 2004-10-12  Simon Josefsson  <jas@extundo.com>
55307
55308         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
55309         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
55310         to real functions.
55311
55312 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55313
55314         * modules/vsnprintf: New file.
55315
55316 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55317
55318         * m4/vsnprintf.m4: New file.
55319
55320 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55321
55322         * lib/vsnprintf.h: New file.
55323         * lib/vsnprintf.c: New file.
55324
55325 2004-10-11  Bruno Haible  <bruno@clisp.org>
55326
55327         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
55328         vsnprintf.
55329
55330 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
55331
55332         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
55333
55334 2004-10-07  Bruno Haible  <bruno@clisp.org>
55335
55336         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
55337         fits into the provided buffer.
55338
55339 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
55340
55341         * lib/diacrit.c, diacrit.h: Add GPL notice.
55342
55343         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
55344         notice.
55345         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
55346         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
55347         This avoids a potential constant-folding bug.
55348
55349 2004-10-05  Bruno Haible  <bruno@clisp.org>
55350
55351         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
55352         for the declaration of strsep.
55353
55354 2004-10-05  Bruno Haible  <bruno@clisp.org>
55355
55356         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
55357
55358 2004-10-04  Simon Josefsson  <jas@extundo.com>
55359
55360         * modules/memmem: New file.
55361         * tests/test-memmem.c: New file.
55362         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
55363
55364 2004-10-04  Simon Josefsson  <jas@extundo.com>
55365
55366         * m4/memmem.m4: New file.
55367
55368 2004-10-04  Simon Josefsson  <jas@extundo.com>
55369
55370         * lib/memmem.h: New file.
55371         * lib/memmem.c: New file, taken from glibc.
55372
55373 2004-10-04  Simon Josefsson  <jas@extundo.com>
55374
55375         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
55376         '#ifdef USE_UNLOCKED_IO'.
55377
55378 2004-10-04  Simon Josefsson  <jas@extundo.com>
55379
55380         * config/srclist.txt: Add memmem from glibc.
55381
55382 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
55383
55384         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
55385
55386         * modules/argmatch, modules/argp, modules/closeout, modules/error,
55387         modules/exclude, modules/getdate, modules/getline,
55388         modules/getndelim2, modules/getpass, modules/getpass-gnu,
55389         modules/getusershell, modules/linebuffer, modules/md5,
55390         modules/mountlist, modules/posixtm, modules/readtokens,
55391         modules/readutmp, modules/regex, modules/sha1,
55392         modules/version-etc, modules/yesno:
55393         Remove dependency on unlocked-io.
55394
55395 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
55396
55397         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
55398
55399         * m4/unlocked-io.m4: Add copyright notice.
55400         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
55401
55402 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
55403
55404         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
55405         * lib/xmalloc.c (xmemdup): Likewise.
55406         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
55407         XFREE): Remove these long-obsolescent macros.
55408         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
55409         * lib/xstrdup.c: Remove.
55410
55411         * lib/regex.c (re_comp): Cast gettext return value to char *,
55412         Problem reported by Martin Neitzel via Mark D. Baushke.
55413
55414 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
55415
55416         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
55417         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
55418         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
55419         regex.c, sha1.c, version-etc.c, yesno.c:
55420         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
55421         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
55422         the includer's responsibility.
55423
55424         Sync from coreutils.
55425
55426         * lib/modechange.c (mode_compile): Don't decrement a pointer that
55427         points to the start of a string, as the C Standard says the
55428         resulting behavior is undefined.
55429
55430         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
55431         simple -> simple_backups, numbered_existing ->
55432         numbered_existing_backups, numbered -> numbered_backups
55433         to avoid shadowing problems.  All uses changed.
55434         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
55435         * lib/backupfile.c (check_extension, numbered_backup):
55436         Rename locals to avoid shadowing 'basename'.
55437         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
55438         once.
55439
55440         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
55441         * lib/.cvsignore: Add getopt.h.
55442
55443 2004-10-04  Bruno Haible  <bruno@clisp.org>
55444
55445         * modules/README: New file.
55446         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
55447         not a module.
55448
55449 2004-10-02  Jim Meyering  <jim@meyering.net>
55450
55451         * lib/dirfd.h, getpagesize.h: Add copyright notice.
55452
55453 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55454
55455         * modules/strsep: New file.
55456
55457 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55458
55459         * m4/strsep.m4: New file.
55460
55461 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
55462
55463         * lib/strsep.h: New file.
55464         * lib/strsep.c: New file.
55465
55466 2004-10-01  Simon Josefsson  <jas@extundo.com>
55467
55468         * lib/snprintf.c (snprintf): Handle size==0.
55469
55470 2004-10-01  Simon Josefsson  <jas@extundo.com>
55471             Bruno Haible  <bruno@clisp.org>
55472
55473         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
55474         (snprintf): Declare 'args'.
55475
55476 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
55477
55478         * lib/snprintf.c: Remove comments as to why each header is needed.
55479
55480 2004-10-01  Bruno Haible  <bruno@clisp.org>
55481
55482         * MODULES.html.sh: Add strsep.
55483
55484 2004-09-30  Simon Josefsson  <jas@extundo.com>
55485
55486         * modules/snprintf: New file.
55487
55488 2004-09-30  Simon Josefsson  <jas@extundo.com>
55489
55490         * m4/snprintf.m4: New file.
55491
55492 2004-09-30  Simon Josefsson  <jas@extundo.com>
55493
55494         * lib/snprintf.h, lib/snprintf.c: New files.
55495
55496 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
55497
55498         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
55499         (hol_entry_help): Never translate an empty string.
55500         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
55501         * lib/argp.h (OPTION_NO_TRANS): New option.
55502
55503 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
55504
55505         * modules/argp (Maintainer): Replace Simon Josefsson
55506         by Sergey Poznyakoff.
55507
55508 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
55509
55510         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
55511         changes merged back into glibc.
55512
55513 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
55514
55515         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
55516
55517 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
55518
55519         * lib/xvasprintf.c: Include xalloc.h.
55520         (xvasprintf): Use xalloc_die, not xmalloc_die.
55521
55522 2004-09-29  Bruno Haible  <bruno@clisp.org>
55523
55524         * modules/alloca-opt: New file, derived from modules/alloca.
55525         * modules/allocsa: Depend on alloca-opt instead of alloca.
55526         * modules/setenv: Likewise.
55527         * modules/vasnprintf: Likewise.
55528         * MODULES.html.sh: Add alloca-opt.
55529
55530 2004-09-28  Simon Josefsson  <jas@extundo.com>
55531
55532         * gnulib-tool: New parameter --lgpl, to asseert that modules are
55533         LGPL, and to replace license template from GPL to LGPL.
55534
55535 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
55536
55537         * modules/dummy: Change license to LGPL.
55538
55539 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
55540
55541         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
55542
55543 2004-09-24  Simon Josefsson  <jas@extundo.com>
55544
55545         * modules/minmax (License): Change from GPL to LGPL.
55546
55547 2004-09-23  Simon Josefsson  <jas@extundo.com>
55548
55549         * gnulib-tool (--import): Typo.
55550
55551 2004-09-23  Simon Josefsson  <jas@extundo.com>
55552
55553         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
55554
55555 2004-09-22  Bruno Haible  <bruno@clisp.org>
55556
55557         * modules/*: Add 'License' field.
55558         * gnulib-tool: Accept --extract-license option.
55559         (func_get_license): New function.
55560
55561 2004-09-21  Bruno Haible  <bruno@clisp.org>
55562
55563         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
55564         Reported by Simon Josefsson.
55565
55566 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
55567
55568         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
55569         gl_AC_TYPE_LONG_LONG.
55570
55571 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
55572
55573         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
55574
55575 2004-09-18  Simon Josefsson  <jas@extundo.com>
55576         and  Paul Eggert  <eggert@cs.ucla.edu>
55577
55578         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
55579         calls with autoreconf.  Define GL_LIB.
55580
55581 2004-09-14  Karl Berry  <karl@gnu.org>
55582
55583         * config/srclist.txt: unsync setenv.c, sigh.
55584
55585 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
55586
55587         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
55588         Problem reported by Bruno Haible in:
55589         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
55590
55591 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
55592
55593         * config/srclist.txt: Comment out argp-pvh.c.
55594
55595 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
55596
55597         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
55598         in case some system header has #define'd it.  Problem reported by
55599         Soeren D. Schulze in
55600         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
55601
55602 2004-09-09  Karl Berry  <karl@gnu.org>
55603
55604         * regex.[ch]: delete from the root.  These were supposed to be
55605                 synced with emacs cvs, but this has not happened for about
55606                 a year, and anyway nothing else uses emacs regex.[ch].
55607                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
55608                 lib/regex[.ch] is untouched.
55609
55610 2004-09-09  Bruno Haible  <bruno@clisp.org>
55611
55612         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
55613
55614 2004-09-09  Bruno Haible  <bruno@clisp.org>
55615
55616         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
55617         modifications.
55618         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
55619
55620 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
55621
55622         * modules/xvasprintf: New file.
55623         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
55624
55625 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
55626
55627         * lib/xvasprintf.h: New file.
55628         * lib/xvasprintf.c: New file.
55629         * lib/xasprintf.c: New file.
55630
55631 2004-09-08  Bruno Haible  <bruno@clisp.org>
55632
55633         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
55634
55635 2004-09-08  Bruno Haible  <bruno@clisp.org>
55636
55637         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
55638         length is > INT_MAX.
55639         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
55640         more.
55641
55642 2004-09-08  Bruno Haible  <bruno@clisp.org>
55643
55644         * lib/stdint_.h: New file, taken from GNU clisp.
55645
55646 2004-09-08  Bruno Haible  <bruno@clisp.org>
55647             Oskar Liljeblad  <oskar@osk.mine.nu>
55648
55649         * modules/stdint: New file.
55650         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
55651
55652 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
55653
55654         Import from coreutils.
55655         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
55656         strings on unbounded length.  alloca's performance benefits aren't
55657         that important here.
55658         (V_STRDUP): Remove.
55659         (parse_with_separator): New function, with most of the internals
55660         of the old parse_user_spec.  Allow user to omit both user and group,
55661         for compatibility with FreeBSD.
55662         Clone only the user name, not the entire spec.
55663         Do not set *uid, *gid unless entirely successful.
55664         Avoid memory leak in some failing cases.
55665         Fix regression for USER.GROUP reported by Dmitry V. Levin in
55666         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
55667         (parse_user_spec): Rewrite to use parse_with_separator.
55668
55669 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
55670
55671         * modules/userspec: Don't depend on alloca.
55672
55673 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
55674
55675         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
55676
55677 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
55678
55679         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
55680         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
55681         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
55682
55683 2004-08-16  Simon Josefsson  <jas@extundo.com>
55684
55685         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
55686         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
55687         Add --dry-run for --import.
55688         Let user provided command line parameters override configure.ac
55689         settings.
55690
55691 2004-08-12  Simon Josefsson  <jas@extundo.com>
55692
55693         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
55694         as discussed with Paul Eggert in threads rooted at
55695         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
55696         and
55697         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
55698         Before, the test was empty, and relied on ELIDE_CODE in source
55699         code.)
55700         (gl_PREREQ_GETOPT): New macro.
55701         (gl_GETOPT): Use them.
55702
55703 2004-08-12  Simon Josefsson  <jas@extundo.com>
55704
55705         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
55706         * lib/getopt_.h: Renamed from getopt.h.
55707
55708 2004-08-12  Simon Josefsson  <jas@extundo.com>
55709
55710         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
55711         Change default library name from libfoo to libgnu.
55712         Now, if you have a configure.ac that says:
55713                 gl_SOURCE_BASE(gl)
55714                 gl_M4_BASE(gl/m4)
55715                 gl_MODULES(error getopt etcetera)
55716                 gl_INIT
55717         you can import all you need by running:
55718                 ../gnulib/gnulib-tool --import
55719
55720         * modules/getopt (Files): Rename getopt.h to getopt_.h.
55721         (Makefile.am): Rewrite, use logic from argz.
55722         (Include): Use <getopt.h> instead of "getopt.h".
55723
55724 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
55725
55726         * modules/argp (Files): Add m4/unlocked-io.m4.
55727         (Depends-on): Add extensions.
55728
55729 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
55730
55731         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
55732         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
55733         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
55734         Check for program_invocation_name, program_invocation_short_name,
55735         flockfile, funlockfile, features.h, _getopt_long_only_r.
55736
55737 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
55738
55739         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
55740         its complicated substitute.
55741         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
55742         and program_invocation_name.
55743         (__argp_basename) [!_LIBC]: Remove; the only use was
55744         replaced by its body.
55745         (__argp_short_program_name): Change condition from
55746         !defined __argp_short_program_name to
55747         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
55748         to match argp-namefrob.h.
55749         (__argp_failure): Don't assume strerror_r returns char *.
55750         * lib/argp-parse.c (N_): Define unconditionally.
55751         (argp_default_options): Fill out initializers with 0 to avoid
55752         gcc warnings.
55753
55754 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
55755
55756         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
55757         getopt1.c.
55758
55759 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
55760
55761         Merge from coreutils.
55762
55763         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
55764
55765         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
55766         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
55767
55768 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
55769
55770         Merge from coreutils.
55771
55772         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
55773         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
55774         for Reliant Unix 5.43.
55775
55776         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
55777         (union fooround): Use uintmax_t, not long int.
55778         The rest is a merge from libc:
55779         [defined _LIBC]: Include <shlib-compat.h>.
55780         (_obstack) [defined _LIBC]: Remove after 2.3.4.
55781
55782         * lib/settime.c (settime): Recode to avoid warning with
55783         Sun Forte C 6U2.
55784
55785         * lib/strverscmp.c: Convert to UTF-8.
55786
55787 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
55788
55789         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
55790         m4/uintmax_t.m4.
55791
55792 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
55793
55794         * modules/xalloc-die: New file.
55795         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
55796
55797         * modules/md5 (Files): Add m4/uint32_t.m4.
55798         * modules/sha1: Renamed from modules/sha.
55799         (Files):
55800         Rename lib/sha.h to lib/sha1.h.
55801         Rename lib/sha.c to lib/sha1.c.
55802         Rename m4/sha.m4 to m4/sha1.m4.
55803         (lib_SOURCES): Likewise.
55804         (configure.ac): Rename gl_SHA to gl_SHA1.
55805         (Include): sha.h -> sha1.h.
55806
55807 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
55808
55809         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
55810         * m4/sha1.m4: Renamed from sha.m4.
55811         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
55812
55813 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
55814
55815         * lib/obstack.h (obstack_empty_p):
55816         Don't assume that chunk->contents is suitably aligned.
55817         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
55818         Likewise. Problem reported by Benno in
55819         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
55820
55821         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
55822         readable.  This could be improved further but it'd take some work.
55823
55824 2004-08-08  Simon Josefsson  <jas@extundo.com>
55825
55826         * modules/xgethostname (Depends-on): Remove exit and error (not
55827         used).
55828
55829         * modules/getpass-gnu: Add getpass.h.
55830         (Depends-on): Add stdbool.
55831         * modules/getpass: Add getpass.h.
55832
55833 2004-08-08  Simon Josefsson  <jas@extundo.com>
55834
55835         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
55836         Check getpass declaration.
55837
55838 2004-08-08  Simon Josefsson  <jas@extundo.com>
55839
55840         * lib/xgethostname.c: Don't include error.h (not used).
55841
55842         * lib/getpass.h: Add.
55843         * lib/getpass.c: Include getpass.h first.
55844
55845 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
55846
55847         * lib/xalloc-die.c: New file.
55848         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
55849         All uses removed.
55850         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
55851         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
55852         xalloc-die.c.
55853         (_, N_, xalloc_die): Move to xalloc-die.c.
55854         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
55855         so that we needn't mess with xalloc_msg_memory_exhausted.
55856
55857         * lib/sha1.h: Renamed from sha.h.
55858         (SHA1_H): Renamed from _SHA_H.
55859         (sha1_ctx): Renamed from sha_ctx.
55860         (sha1_init_ctx): Renamed from sha_init_ctx.
55861         (sha1_process_block): Renamed from sha_process_block.
55862         (sha1_process_bytes): Renamed from sha_process_bytes.
55863         (sha1_finish_ctx): Renamed from sha_finish_ctx.
55864         (sha1_read_ctx): Renamed from sha_read_ctx.
55865         (sha1_stream): Renamed from sha_stream.
55866         (sha1_buffer): Renamed from sha_buffer.
55867         * lib/sha1.c: Likewise; renamed from sha.c.
55868         Do not include <sys/types.h>.
55869         Include <stddef.h> rather than <stdlib.h>.
55870
55871 2004-08-08  Bruno Haible  <bruno@clisp.org>
55872
55873         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
55874         FILESYSTEM_PREFIX_LEN.
55875         * lib/progreloc.c: Likewise.
55876         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
55877
55878 2004-08-06  Simon Josefsson  <jas@extundo.com>
55879
55880         * modules/progname (Depends-on): Don't depend on stdbool.
55881
55882 2004-08-06  Simon Josefsson  <jas@extundo.com>
55883
55884         * modules/getsubopt: New file.
55885         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
55886         getsubopt.
55887
55888 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
55889
55890         More merge from coreutils.
55891
55892         * m4/utimens.m4, m4/utimecmp.m4: New files.
55893         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
55894         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
55895         prereq.m4, sha.m4: Import changes from coreutils.
55896
55897 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
55898
55899         More merge from coreutils.
55900         * modules/raise, modules/readtokens0, modules/utimens:
55901         * modules/utimecmp, module/xnanosleep: New files.
55902         * modules/strftime: Add lib/strftime.h.
55903         Change include from <time.h> to "strftime.h".
55904         * modules/yesno: Add lib/yesno.h.
55905         * modules/backupfile: Remove lib/addext.c.
55906         * modules/euidaccess: Add stat-macros.h.
55907         * modules/canonicalize, modules/euidaccess,
55908         modules/filemode, modules/lchown, modules/makepath,
55909         modules/rmdir, modules/stat: Likewise.
55910
55911 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
55912
55913         Merge from tar.
55914         * lib/argp-help.c (make_hol, hol_append): Don't assume that
55915         SIZE_MAX is a valid preprocessor constant.
55916         (__argp_basename): Change from "#ifndef _LIBC"
55917         to "#ifndef __argp_short_program_name", so that
55918         we don't compile these functions for tar.
55919
55920         More merges from coreutils.
55921         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
55922         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
55923         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
55924         * lib/addext.c: Remove; no longer needed.
55925         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
55926         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
55927         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
55928         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
55929         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
55930         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
55931         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
55932         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
55933         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
55934         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
55935         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
55936         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
55937         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
55938         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
55939         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
55940         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
55941         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
55942         Import changes from coreutils.
55943
55944 2004-08-05  Simon Josefsson  <jas@extundo.com>
55945
55946         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
55947
55948 2004-08-05  Simon Josefsson  <jas@extundo.com>
55949
55950         * m4/getsubopt.m4: New file.
55951
55952 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
55953
55954         Merge from coreutils.
55955
55956         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
55957         * m4/getcwd-path-max.m4: New files.
55958
55959         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
55960         FILESYSTEM_PREFIX_LEN ->
55961         FILE_SYSTEM_PREFIX_LEN.
55962         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
55963         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
55964         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
55965         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
55966
55967         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
55968         prerequisite modules now handle the DOS stuff.
55969         Don't check for unistd.h.
55970
55971 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
55972
55973         Merge from coreutils.
55974
55975         * lib/.gdb-history: Remove; this doesn't belong here.
55976
55977         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
55978         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
55979         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
55980         * lib/getcwd.c: New files.
55981
55982         * lib/dirname.h: Include <stdbool.h>.
55983         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
55984         for consistency with POSIX terminology.  All uses changed.
55985         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
55986         (strip_trailing_slashes): Use bool for booleans.
55987         * lib/stripslash.c (strip_trailing_slashes): Likewise.
55988
55989         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
55990         sometimes returns a positive errno value even when it succeeds.
55991         (print_errno_message) [!LIBC]: Fall back on strerror if
55992         __strerror_r fails.
55993
55994         * lib/path-concat.c (mempcpy): Don't define if a system header defines
55995         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
55996         (longest_relative_suffix): New function.
55997         (path_concat): Use it.  Assume first argument is not NULL.
55998         Port to DOS.  Omit redundant separators.
55999         Report an error instead of returning NULL.
56000         Use mempcpy instead of memcpy.
56001         (xpath_concat): Remove: not declared or used.
56002
56003         * lib/same.h: Include <stdbool.h>
56004         (same_name): Return bool, not int.
56005         * lib/same.c (same_name): Likewise.
56006         (errno): Don't declare; we assume C89 or better now.
56007
56008         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
56009         if not already defined.
56010
56011         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
56012         * lib/dup-safer.c (errno): Likewise.
56013
56014 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
56015
56016         Merge from coreutils.
56017         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
56018         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
56019         * modules/path-concat: Don't depend on strdup.
56020
56021 2004-08-03  Simon Josefsson  <jas@extundo.com>
56022
56023         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
56024         * lib/progname.h: Don't include stdbool.h.
56025
56026 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
56027
56028         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
56029         * MODULES.html.sh (func_all_modules): Remove fatal.
56030
56031 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
56032
56033         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
56034
56035 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
56036
56037         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
56038         working.
56039
56040 2004-08-02  Simon Josefsson  <jas@extundo.com>
56041
56042         * lib/getsubopt.h: New file, with comments from Bruno Haible.
56043         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
56044         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
56045
56046 2004-08-01  Simon Josefsson  <jas@extundo.com>
56047
56048         * lib/xgetdomainname.c: Include stdlib.h, for free().
56049
56050 2004-07-19  Bruno Haible  <bruno@clisp.org>
56051
56052         * MODULES.html.sh (func_all_modules): Add dummy.
56053
56054 2004-07-16  Simon Josefsson  <jas@extundo.com>
56055
56056         * modules/dummy: New file.
56057
56058 2004-07-16  Simon Josefsson  <jas@extundo.com>
56059
56060         * lib/dummy.c: New file.
56061
56062 2004-07-16  Bruno Haible  <bruno@clisp.org>
56063
56064         * lib/backupfile.h: Add extern "C" for C++.
56065         * lib/closeout.h: Likewise.
56066         * lib/copy-file.h: Likewise.
56067         * lib/findprog.h: Likewise.
56068         * lib/full-write.h: Likewise.
56069         * lib/pathname.h: Likewise.
56070         * lib/progname.h: Likewise.
56071         * lib/stpcpy.h: Likewise.
56072         * lib/stpncpy.h: Likewise.
56073         * lib/strcase.h: Likewise.
56074         * lib/strstr.h: Likewise.
56075         * lib/xalloc.h: Likewise.
56076
56077         * lib/mbswidth.h: Add extern "C" for C++.
56078         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
56079
56080 2004-07-13  Robert Millan  <robertmh@gnu.org>
56081
56082         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
56083
56084 2004-07-09  Simon Josefsson  <jas@extundo.com>
56085
56086         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
56087         failed without this.)
56088
56089 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
56090
56091         * modules/chown (Files): Add lib/fchown-stub.c, since
56092         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
56093
56094 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
56095
56096         * lib/fchown-stub.c: New file.
56097
56098 2004-06-24  Jim Meyering  <jim@meyering.net>
56099
56100         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
56101
56102 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
56103
56104         * modules/argz: Omit "#include".
56105
56106         * MODULES.html.sh (func_all_modules): Add calloc, to match
56107         2004-06-01 addition of calloc module.
56108
56109 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
56110
56111         * m4/argz.m4: New file, which is autoupdated from libtool.
56112
56113 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
56114
56115         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
56116         libtool.
56117
56118 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
56119
56120         * config/srclist-update: Don't insist on "USA." before the
56121         close-comment, as libtool omits the period and puts the */ on a
56122         separate line.
56123         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
56124         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
56125
56126 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
56127
56128         * modules/argz: New file.
56129         * MODULES.html.sh (func_all_modules): Add argz.
56130
56131 2004-06-12  Jim Meyering  <jim@meyering.net>
56132         and  Paul Eggert  <eggert@cs.ucla.edu>
56133
56134         * modules/hash (Files): Add lib/xalloc.h.
56135         * modules/pipe (Depends-on): Add wait-process.
56136         * modules/stat (Depends-on): Add xalloc.
56137         * modules/userspec (Files): Add lib/userspec.h.
56138         * modules/xstrto
56139
56140         Upgrade from gettext-0.13.
56141         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
56142         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
56143         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
56144
56145 2004-06-10  Jim Meyering  <jim@meyering.net>
56146
56147         * lib/calloc.c: New file.
56148
56149 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
56150
56151         * lib/getdate.y (yylex): Allow space between sign and number.
56152         Problem reported by Dan Jacobson.
56153
56154 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
56155
56156         Merge from coreutils CVS.
56157
56158         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
56159         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
56160         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
56161         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
56162         xstrtol.m4: Fix copyright date and/or serial number.
56163
56164         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
56165         See if we need an fchown replacement.
56166         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
56167         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
56168         and use the replacement function if we detect either defect.
56169
56170         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
56171         gl_UTIMECMP.
56172
56173 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
56174         and  Jim Meyering  <jim@meyering.net>
56175
56176         Merge from coreutils CVS.
56177
56178         * lib/stat-macros.h: New file, with contents from file-type.h
56179         and coreutils' system.h.
56180         * lib/file-type.c: Include "stat-macros.h".
56181         * lib/file-type.h (file_type): Move all macro definitions to new file,
56182         stat-macros.h.
56183
56184         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
56185         Wrap old code with this conditional.
56186         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
56187         function that does not dereference symlinks.
56188         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
56189
56190         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
56191         dependency problems.
56192         (xreadlink): Accept new arg SIZE, for efficiency.
56193         All decls and uses changed.
56194         * lib/xreadlink.h: Include <stddef.h>, for size_t.
56195
56196         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
56197         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
56198
56199         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
56200         sysexits.h.
56201
56202 2004-06-01  Jim Meyering  <jim@meyering.net>
56203
56204         * m4/calloc.m4: New file.
56205
56206 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
56207
56208         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
56209         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
56210         Also, fix a typo in a diagnostic.
56211
56212 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
56213
56214         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
56215         or AC_FUNC_REALLOC.
56216
56217 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
56218
56219         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
56220         macros to be defined.
56221         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
56222         the allocator returns NULL because the requested size is zero.
56223
56224 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
56225
56226         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
56227         var.  Add comment explaining why libc still defines it.  This
56228         merges the following patch from glibc:
56229         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
56230
56231 2004-05-20  Andreas Schwab  <schwab@suse.de>
56232
56233         * m4/free.m4: Replace free if it not known to work, not the other
56234         way round.
56235
56236 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
56237
56238         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
56239         present in glibc since revision 1.1 of this file.
56240         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
56241         obstack_alignment_mask, obstack_alloc, obstack_base,
56242         obstack_blank, obstack_blank_fast, obstack_chunk_size,
56243         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
56244         obstack_grow0, obstack_init, obstack_int_grow,
56245         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
56246         obstack_next_free, obstack_object_size, obstack_ptr_grow,
56247         obstack_ptr_grow_fast, obstack_room): Remove declarations of
56248         nonexistent functions.
56249
56250 2004-05-18  Karl Berry  <karl@gnu.org>
56251
56252         * config/srclist.txt: break link for vasnprintf.c.
56253
56254 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
56255
56256         Port obstack to the AS/400, where pointers are 16 bytes wide and
56257         you cannot cast an integer to a valid pointer.  This patch is
56258         currently waiting to be integrated into glibc; see
56259         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
56260
56261         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
56262         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
56263         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
56264         (struct obstack): temp member is now a union of a pointer and
56265         an integer, instead of an integer.  All integer uses changed.
56266         This does not affect the physical layout of struct obstack,
56267         except on hosts (like the AS/400) where the size or alignment of
56268         void * is greater than that of ptrdiff_t.
56269         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
56270         __STDC__)]: Store temporary in pointer member of union, not
56271         integer member.
56272         * lib/obstack.c: Include <stddef.h>, for offsetof.
56273         (struct fooalign): Remove; it doesn't need a name.
56274         (union fooround): Change double to long double, and add void *.
56275         (DEFAULT_ALIGNMENT): Use offsetof to compute.
56276         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
56277         not a macro.  Hence the values are always int; so remove all
56278         casts-to-int in uses.
56279
56280 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
56281
56282         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
56283         we can get this patch merged into glibc.
56284
56285 2004-05-17  Derek R. Price  <derek@ximbiot.com>
56286             Paul Eggert  <eggert@cs.ucla.edu>
56287
56288         * m4/argp: Depend on alloca.
56289
56290 2004-05-17  Derek R. Price  <derek@ximbiot.com>
56291             Paul Eggert  <eggert@cs.ucla.edu>
56292
56293         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
56294         freecoding.
56295
56296 2004-05-17  Bruno Haible  <bruno@clisp.org>
56297
56298         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
56299         precision that consists of a '.' followed by an empty digit string.
56300         Patch by Tor Lillqvist <tml@iki.fi>.
56301
56302 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
56303
56304         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
56305         for backward compatibility with older code.  We need our own
56306         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
56307         it under some other name, and our alloca.h will define it.
56308
56309 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
56310             Derek Price  <derek@ximbiot.com>
56311
56312         * lib/alloca.c: Include <alloca.h>, to get our interface.
56313         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
56314         include <alloca.h> first.  Use C89 prototype for alloca; this
56315         requires including <stddef.h> for size_t.  Use extern "C" if C++.
56316         Use #elif for simplicity, since we can assume C89 now.
56317         Don't try to source the system alloca.h since it will not be found
56318         and to prevent recursively including its replacement.
56319         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
56320         * lib/regex.c: Likewise.
56321
56322 2004-05-16  Derek Price  <derek@ximbiot.com>
56323             Paul Eggert  <eggert@cs.ucla.edu>
56324
56325         getline cleanup.  This changes the getndelim2 API: both order of
56326         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
56327         no delimiter).
56328
56329         * lib/getline.c: Don't include stddef.h or stdio.h, since our
56330         interface does that.
56331         (getline): Always use getdelim, so that we don't have two
56332         copies of this code.
56333         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
56334         if available.
56335         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
56336         (GETNDELIM2_MAXIMUM): New macro.
56337         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
56338         instead of the old practice of delim2==0.  All callers changed.
56339         Return -1 on overflow, instead of returning junk.
56340         Do not set *linesize unless allocation succeeds.
56341         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
56342         that we include sys/types.h.
56343         * lib/getnline.h: Likewise.
56344         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
56345         (getndelim2): Reorder arguments.
56346         * lib/getnline.c (getnline, getndelim):
56347         Don't discard the NMAX argument.
56348         (getnline): Invoke getndelim, to avoid code duplication.
56349         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
56350         of (size_t) -1 by callers of the getnline family.
56351
56352 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
56353
56354         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
56355         Check for gettimeofday.
56356         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
56357         Check for settimeofday, stime.
56358
56359 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
56360
56361         * lib/nanosleep.c (suspended): Change its type from int to
56362         sig_atomic_t volatile.
56363         (first_call): Make it private to rpl_nanosleep, and have it
56364         be zero initially as that's a bit faster.
56365         (my_usleep): Round up fractional times instead of truncating them,
56366         as this is the usual meaning for 'sleep'.
56367
56368         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
56369         doesn't work.
56370         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
56371         (ENOSYS): Define if not defined.
56372         (settime): Fall back on stime if it exists and settimeofday fails.
56373         But don't bother with fallbacks if a method fails with errno == EPERM.
56374
56375 2004-05-11  Jim Meyering  <jim@meyering.net>
56376
56377         Prior to this change, the save_cwd caller required read access to the
56378         current directory on most systems (ones with the fchdir function).
56379
56380         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
56381         fails, try write-only, and finally, resort to using xgetcwd.
56382
56383 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
56384
56385         * lib/obstack.c, obstack.h: Import changes from libc.
56386
56387 2004-04-28  Bruno Haible  <bruno@clisp.org>
56388
56389         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
56390         also implicitly appends .exe to executables.
56391         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
56392         accepts Windows pathnames.
56393         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
56394         Treat Cygwin like Windows, since it now accepts Windows pathnames.
56395         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
56396         Treat Cygwin like Windows, since it now accepts Windows pathnames.
56397         Reported by Derek Robert Price <derek@ximbiot.com>.
56398
56399 2004-04-21  Karl Berry  <karl@gnu.org>
56400
56401         * config/srclist.txt (localcharset.c): break sync.
56402
56403 2004-04-20  Paul Eggert  <eggert@twinsun.com>
56404
56405         * m4/host-os.m4: Add a copyright notice.
56406
56407 2004-04-20  Jim Meyering  <jim@meyering.net>
56408
56409         Change UTILS_ to gl_ in AC_DEFINE'd names.
56410         Change utils_- and jm_-prefixed variables, too.
56411         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
56412         UTILS_FUNC_MKDIR_TRAILING_SLASH.
56413         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
56414
56415         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
56416         Don't emit trailing blanks.
56417         Also rename jm_-prefixed variables to have gl_ prefix.
56418
56419         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
56420         Also rename jm_-prefixed variables to have gl_ prefix.
56421
56422         * m4/jm-macros.m4: Reflect the renamings.
56423         * m4/prereq.m4: Likewise.
56424
56425 2004-04-20  Jim Meyering  <jim@meyering.net>
56426
56427         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
56428         memory.
56429
56430 2004-04-20  Jim Meyering  <jim@meyering.net>
56431             Bruno Haible  <bruno@clisp.org>
56432
56433         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
56434         memory when realloc fails.
56435
56436 2004-04-19  Jim Meyering  <jim@meyering.net>
56437
56438         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
56439         now that readutmp.c may call `free (0)'.
56440
56441 2004-04-19  Bruno Haible  <bruno@clisp.org>
56442
56443         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
56444         * m4/inttypes_h.m4: Likewise.
56445         * m4/stdint_h.m4: Likewise.
56446         * m4/intmax_t.m4: Likewise.
56447         * m4/uintmax_t.m4: Likewise.
56448
56449 2004-04-18  Jim Meyering  <jim@meyering.net>
56450
56451         * m4/prereq.m4: Don't forbid jm_ prefix.
56452
56453         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
56454         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
56455         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
56456         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
56457         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
56458         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
56459         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
56460         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
56461         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
56462         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
56463         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
56464         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
56465         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
56466         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
56467         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
56468         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
56469         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
56470         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
56471         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
56472
56473 2004-04-18  Jim Meyering  <jim@meyering.net>
56474
56475         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
56476         failure, don't leak memory and do call END_UTMP_ENT.
56477
56478 2004-04-16  Jim Meyering  <jim@meyering.net>
56479
56480         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
56481         coreutils' stat program.
56482         (gl_PREREQ): Don't require jm_PREREQ_STAT.
56483
56484 2004-04-11  Paul Eggert  <eggert@twinsun.com>
56485
56486         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
56487         C89.
56488         (CHAR_BIT): Remove, since we assume C89.
56489         Include <stdint.h> if available, as per current Autoconf CVS advice.
56490
56491 2004-03-31  Jim Meyering  <jim@meyering.net>
56492
56493         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
56494         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
56495         * m4/xalloc.m4: Likewise.
56496
56497 2004-03-30  Paul Eggert  <eggert@twinsun.com>
56498
56499         Merge from coreutils.
56500
56501         * m4/inttostr.m4: New file.
56502         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
56503         Require AM_STDBOOL_H and gl_TIMESPEC instead.
56504         Require gl_CLOCK_TIME.
56505         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
56506
56507 2004-03-30  Paul Eggert  <eggert@twinsun.com>
56508
56509         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
56510         not bool, to be more consistent with Unix conventions.
56511         Suggested by Bruno Haible.
56512
56513         Merge from coreutils.
56514
56515         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
56516         * lib/umaxtostr.c: New files.
56517
56518         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
56519         the usual <time.h> dance.
56520         (get_date): Change signature to support fractional time stamps.
56521         All callers changed.
56522         * lib/getdate.y: Include "getdate.h" first, as we can now
56523         assume C89 and don't need to worry about 'const'.
56524         Similarly, include "unlocked-io.h" near start, not in middle.
56525         Include <limits.h>.
56526         (textint.value): Use long int rather than int.
56527         (textint.digits): Use size_t rather than int.
56528         (BILLION, LOG10_BILLION): New constants.
56529         (parser_control): New member rel_ns.  Members day_ordinal,
56530         time_zone, month, day, hour, minutes, rel_year, rel_month,
56531         rel_day, rel_hour, rel_minutes, rel_seconds
56532         are now long int, not int.  Member seconds is now struct timespec,
56533         not int.  New member timespec_seen.  Members dates_seen, days_seen,
56534         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
56535         not int.
56536         (%union.intval): Now long int, not int.
56537         New member timespec.
56538         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
56539         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
56540         (spec): Now is a timespec or an item list.
56541         (timespec, items): New nonterminals.
56542         (time, rel, relunit, number, get_date):
56543         Add support for fractional seconds.
56544         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
56545         (gmtime, localtime, mktime): Remove decls; not needed with C89.
56546         (to_hour): First arg is now long int, not int.
56547         (to_year): Returns long int, not int.
56548         Don't treat year -70 like 70.
56549         (tm_diff): Returns long int, not int.
56550         (lookup_word): Use bool instead of int when appropriate.
56551         (yylex): Use size_t for count, not int.
56552         Detect overflow when parsing large integer constants.
56553         Add support for fractions.
56554         (get_date): Make pointers 'const' if possible.
56555         Use more-portable code to detect integer overflow.
56556         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
56557         Don't use ctime; it's not reliable if the year has >4 digits.
56558
56559         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
56560         This is for compatibility with BSD.
56561
56562         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
56563         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
56564         From coreutils' system.h.
56565
56566         * lib/userspec.c: Don't include "posixver.h".
56567         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
56568         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
56569         compatible extension.  Simplify code by removing a boolean int
56570         that was always nonzero if a string was nonnull.
56571
56572 2004-03-30  Jim Meyering  <jim@meyering.net>
56573
56574         Merge from coreutils.
56575
56576         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
56577         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
56578         on some systems one must include <grp.h> before it.
56579         Reported by Christian Krackowizer.
56580
56581 2004-03-30  Jim Meyering  <jim@meyering.net>
56582
56583         Merge from coreutils.
56584
56585         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
56586
56587         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
56588         an empty input stream.
56589
56590         * lib/readtokens.c: Include <stdbool.h>.
56591         (readtoken): Use `size_t' rather than int/long.
56592         All callers adjusted.
56593         Use `bool' rather than `int' where appropriate.
56594         Use memset rather than an explicit loop.
56595         Use x2nrealloc rather than xrealloc.
56596         Allow the use of `\0' as a delimiter.
56597         (readtokens): Likewise.
56598         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
56599
56600 2004-03-30  Jim Meyering  <jim@meyering.net>
56601
56602         * m4/realloc.m4: Remove file, since now it does no more than
56603         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
56604         the `configure.ac' section of module/realloc.
56605         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
56606
56607 2004-03-30  Bruno Haible  <bruno@clisp.org>
56608
56609         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
56610         nonnull.
56611
56612 2004-03-29  Paul Eggert  <eggert@twinsun.com>
56613
56614         Merge changes to getloadavg.c from coreutils and Emacs.
56615
56616         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
56617         Define to an expression, not to the empty string.
56618         Include cloexec.h and xalloc.h.
56619         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
56620         Use set_cloexec_flag rather than rolling our own.
56621         * lib/cloexec.c, lib/cloexec.h: New files.
56622
56623 2004-03-29  Paul Eggert  <eggert@twinsun.com>
56624
56625         * m4/cloexec.m4: New file.
56626
56627 2004-03-18  Paul Eggert  <eggert@twinsun.com>
56628
56629         * lib/getopt.h: Sync with libc CVS.
56630
56631 2004-03-18  Paul Eggert  <eggert@twinsun.com>
56632             Bruno Haible  <bruno@clisp.org>
56633
56634         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
56635         mbswidth.
56636
56637 2004-03-18  Paul Eggert  <eggert@twinsun.com>
56638             Bruno Haible  <bruno@clisp.org>
56639
56640         * lib/mbswidth.h: Include <wchar.h> only if
56641         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
56642         <wchar.h>.
56643         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
56644
56645 2004-03-09  Paul Eggert  <eggert@twinsun.com>
56646
56647         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
56648         Sync with libc CVS.
56649         * lib/getopt_int.h: New file, also synced from libc.
56650
56651 2004-03-09  Paul Eggert  <eggert@twinsun.com>
56652
56653         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
56654         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
56655         Bring back getopt.c, getopt.h, getopt1.c.
56656
56657 2004-03-07  Paul Eggert  <eggert@twinsun.com>
56658
56659         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
56660         All uses changed.  Check for sa_sigaction member; this fixes
56661         a bug first reported by Jason Andrade in
56662         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
56663
56664 2004-03-07  Paul Eggert  <eggert@twinsun.com>
56665
56666         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
56667         '#if' expressions.  Unlike the code it replaces, it does not
56668         depend on (defined _SC_PAGESIZE).  However, it does depend on
56669         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
56670         first reported by Jason Andrade in
56671         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
56672
56673 2004-02-25  Simon Josefsson  <jas@extundo.com>
56674
56675         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
56676
56677 2004-02-25  Simon Josefsson  <jas@extundo.com>
56678
56679         * lib/strdup.h: New file.
56680         * lib/strdup.c: Include it.
56681         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
56682         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
56683
56684 2004-02-23  Karl Berry  <karl@gnu.org>
56685
56686         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
56687         (from fencepost.gnu.org:/gd/gnuorg).
56688
56689 2004-02-23  Karl Berry  <karl@gnu.org>
56690
56691         * config/srclistvars.sh (GNUORG) [karl]: redefine.
56692         * config/srclist.txt: add maintain/standards documents.
56693
56694 2004-02-18  Bruno Haible  <bruno@clisp.org>
56695
56696         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
56697         Reported by Derek Robert Price <derek@ximbiot.com>.
56698
56699 2004-02-16  Karl Berry  <karl@gnu.org>
56700
56701         * config/mkinstalldirs, install-sh: update from automake.
56702
56703 2004-02-06  Karl Berry  <karl@gnu.org>
56704
56705         * m4/po.m4: update from gettext 0.14.1.
56706
56707 2004-02-06  Karl Berry  <karl@gnu.org>
56708
56709         * lib/config.charset: update from gettext 0.14.1.
56710
56711 2004-02-05  Paul Eggert  <eggert@twinsun.com>
56712
56713         Add comments and code, prompted by suggestions from Bruno Haible
56714         for sh-quote.
56715         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
56716         describing the enum quoting_style values.
56717         * lib/quotearg.c (quotearg_alloc): New function.
56718         (quotearg_buffer_restyled): Treat lone { and } as special.
56719         Treat = as special.  Work around bug with older shells
56720         that "see" a '\' that is really the 2nd byte of a multibyte char.
56721         Quote empty string with shell_quoting_style.
56722
56723 2004-02-03  Bruno Haible  <bruno@clisp.org>
56724
56725         * m4/pipe.m4: New file, from GNU gettext.
56726
56727 2004-02-03  Bruno Haible  <bruno@clisp.org>
56728
56729         * lib/pipe.h: New file, from GNU gettext.
56730         * lib/pipe.c: New file, from GNU gettext.
56731
56732 2004-01-27  Bruno Haible  <bruno@clisp.org>
56733
56734         * m4/execute.m4: New file, from GNU gettext.
56735
56736 2004-01-27  Bruno Haible  <bruno@clisp.org>
56737
56738         * lib/execute.h: New file, from GNU gettext.
56739         * lib/execute.c: New file, from GNU gettext.
56740         * lib/w32spawn.h: New file, from GNU gettext.
56741
56742 2004-01-24  Paul Eggert  <eggert@twinsun.com>
56743
56744         Merge from diffutils.
56745
56746         * lib/file-type.c (file_type): Add typed memory objects.
56747         * lib/file-type.h (S_TYPEISTMO): New macro.
56748
56749         * lib/c-stack.h (c_stack_action): Remove argv argument.
56750         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
56751         (die): Don't calculate message unless segv_action returns.
56752         (get_stack_location, min_address_from_argv, max_address_from_argv,
56753         volatile stack_base, volatile_stack_size): Remove.
56754         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
56755         that every segmentation violation is a stack overflow.  (Ouch!)
56756         See Debian bug 136249 (still outstanding) for more info about why
56757         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
56758
56759 2004-01-24  Paul Eggert  <eggert@twinsun.com>
56760
56761         Exit-status fix from coreutils.
56762
56763         Use exit_failure consistently in place of EXIT_FAILURE,
56764         so that program exit statuses are consistent on failure.
56765
56766         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
56767         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
56768         * lib/argmatch.h: Comment fix to match the above.
56769         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
56770         Now a macro referring to exit_failure, instead of a separate
56771         variable.  Include "exitfail.h" to get it.
56772         * lib/xstrtol.h: Include "exitfail.h".
56773         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
56774
56775         * lib/long-options.c (parse_long_options): Use prototype
56776         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
56777         for clarity.
56778
56779 2004-01-21  Jim Meyering  <jim@meyering.net>
56780
56781         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
56782         so as not to conflict with a different-sized __mktime_internal
56783         function in GNU libc.
56784         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
56785         Problem building statically-linked `ls' reported by Michael Brunnbauer.
56786
56787 2004-01-20  Karl Berry  <karl@gnu.org>
56788
56789         * config/config.guess: update from config.
56790
56791         * config/srclistvars.sh: GNUWWWLICENSES for karl.
56792
56793 2004-01-20  Bruno Haible  <bruno@clisp.org>
56794
56795         Safer stack allocation.
56796         * lib/setenv.c: Include allocsa.h.
56797         (alloca): Remove fallback definition.
56798         (freea): Remove macro.
56799         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
56800         instead of freea.
56801
56802 2004-01-20  Bruno Haible  <bruno@clisp.org>
56803
56804         * m4/eealloc.m4: New file, from GNU gettext.
56805
56806 2004-01-20  Bruno Haible  <bruno@clisp.org>
56807
56808         * m4/allocsa.m4: New file, from GNU gettext.
56809
56810 2004-01-20  Bruno Haible  <bruno@clisp.org>
56811
56812         * lib/xallocsa.h: New file, from GNU gettext.
56813         * lib/xallocsa.c: New file, from GNU gettext.
56814
56815 2004-01-20  Bruno Haible  <bruno@clisp.org>
56816
56817         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
56818
56819 2004-01-20  Bruno Haible  <bruno@clisp.org>
56820
56821         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
56822         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
56823         specially.
56824
56825 2004-01-20  Bruno Haible  <bruno@clisp.org>
56826
56827         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
56828         patch.
56829
56830 2004-01-20  Bruno Haible  <bruno@clisp.org>
56831
56832         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
56833
56834 2004-01-20  Bruno Haible  <bruno@clisp.org>
56835
56836         * lib/eealloc.h: New file.
56837
56838 2004-01-20  Bruno Haible  <bruno@clisp.org>
56839
56840         * lib/binary-io.h: Avoid warnings on Cygwin.
56841
56842 2004-01-20  Bruno Haible  <bruno@clisp.org>
56843
56844         * lib/allocsa.h: New file, from GNU gettext.
56845         * lib/allocsa.c: New file, from GNU gettext.
56846
56847 2004-01-18  Karl Berry  <karl@gnu.org>
56848
56849         * doc/gpl.texi, doc/lgpl.texi: new files.
56850
56851 2004-01-18  Karl Berry  <karl@gnu.org>
56852
56853         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
56854         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
56855
56856 2004-01-15  Paul Eggert  <eggert@twinsun.com>
56857
56858         Merge from coreutils.
56859
56860         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
56861         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
56862         (gl_DEFAULT_POSIX2_VERSION): Move
56863         the documentation from 'configure' into 'config.hin',
56864         so that 'configure --help' isn't burdened by it and
56865         we don't have to worry about its formatting there.
56866         Reword the documentation so that it's more succinct
56867         and can be run together into a single paragraph.
56868         * m4/same.m4 (gl_SAME): Check for pathconf.
56869
56870 2004-01-15  Paul Eggert  <eggert@twinsun.com>
56871
56872         Merge from coreutils.
56873
56874         * lib/posixver.c: Include posixver.h.
56875
56876         * lib/same.c: Include <stdbool.h>, <limits.h>.
56877         (_POSIX_NAME_MAX): Define if not defined.
56878         (MIN): New macro.
56879         (same_name): If file names are silently truncated, report
56880         that the file names are the same if they are the same after
56881         the silent truncation.
56882
56883         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
56884         conversion function.
56885         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
56886         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
56887         longer needed.
56888
56889 2004-01-15  Jim Meyering  <jim@meyering.net>
56890
56891         Merge from coreutils.
56892
56893         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
56894         if no library is required.
56895         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
56896         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
56897         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
56898         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
56899         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
56900         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
56901         value, $ac_cv_search_crypt, if it's "none required".
56902         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
56903         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
56904         not gl_FUNC_GETLOADAVG.
56905         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
56906         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
56907
56908 2004-01-15  Jim Meyering  <jim@meyering.net>
56909
56910         Merge from coreutils.
56911
56912         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
56913         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
56914         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
56915
56916         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
56917         optional configure-time default.
56918
56919         * lib/version-etc.c (version_etc_copyright): Update copyright date.
56920
56921         * lib/xreadlink.c (xreadlink): Correct outdated comment.
56922
56923 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
56924
56925         Merge from coreutils.
56926
56927         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
56928         value, $ac_cv_search_nanosleep, if it's "none required".
56929
56930 2004-01-14  Paul Eggert  <eggert@twinsun.com>
56931
56932         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
56933         with like-named macro in fnmatch.c.
56934         (EXT): Use an internal constant instead.
56935
56936         Merge fnmatch patches from glibc.
56937         * lib/fnmatch.c (mbsinit): Remove define.
56938         Add libc_hidden_ver (__fnmatch, fnmatch).
56939         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
56940         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
56941
56942 2004-01-14  Karl Berry  <karl@gnu.org>
56943
56944         * config/install-sh: update from automake.
56945
56946 2004-01-13  Karl Berry  <karl@gnu.org>
56947
56948         * config/install-sh: update from automake.
56949
56950 2004-01-09  Karl Berry  <karl@gnu.org>
56951
56952         * config/install-sh: update from automake.
56953
56954 2004-01-05  Karl Berry  <karl@gnu.org>
56955
56956         * config/config.{sub,guess}: update from config.
56957
56958 2003-12-31  Karl Berry  <karl@gnu.org>
56959
56960         * config/depcomp: update from automake.
56961
56962 2003-12-14  Karl Berry  <karl@gnu.org>
56963
56964         * lib/config.charset: update from gettext-runtime.
56965
56966 2003-12-03  Paul Eggert  <eggert@twinsun.com>
56967
56968         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
56969         Bug reported by Alfred M. Szmidt.
56970
56971 2003-12-03  Bruno Haible  <bruno@clisp.org>
56972
56973         * m4/gettext.m4: Upgrade from gettext-0.13.
56974         * m4/po.m4: Upgrade from gettext-0.13.
56975         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
56976         * m4/intmax.m4: New file, from gettext-0.13.
56977         * m4/printf-posix.m4: New file, from gettext-0.13.
56978
56979 2003-11-29  Karl Berry  <karl@gnu.org>
56980
56981         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
56982
56983 2003-11-25  Paul Eggert  <eggert@twinsun.com>
56984             Bruno Haible  <bruno@clisp.org>
56985
56986         * lib/printf-parse.h: Don't include sys/types.h.
56987         (ARG_NONE): New macro.
56988         (char_directive): Change type of *arg_index fields to size_t.
56989         * lib/printf-parse.c: Don't include sys/types.h.
56990         (SSIZE_MAX): Remove macro.
56991         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
56992         Remove unnecessary overflow check.
56993         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
56994         fields.
56995
56996 2003-11-25  Bruno Haible  <bruno@clisp.org>
56997
56998         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
56999
57000 2003-11-25  Bruno Haible  <bruno@clisp.org>
57001
57002         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
57003         gt_TYPE_SSIZE_T.
57004
57005 2003-11-24  Paul Eggert  <eggert@twinsun.com>
57006
57007         * modules/alloca: Remove dependency on xalloc.
57008
57009 2003-11-24  Paul Eggert  <eggert@twinsun.com>
57010
57011         * lib/alloca.c: Remove dependency on xalloc module.
57012         (xalloc_die): Remove.
57013         (memory_full) [!defined emacs]: New macro.
57014         [!defined emacs]: Don't include xalloc.h.
57015         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
57016         address arithmetic overflows.  Change datatypes a bit to avoid
57017         unnecessary casts.
57018
57019 2003-11-22  Jim Meyering  <jim@meyering.net>
57020
57021         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
57022         s/size/size_t/.
57023
57024 2003-11-21  Karl Berry  <karl@gnu.org>
57025
57026         * config/config.{sub,guess}: update from config.
57027
57028 2003-11-18  Karl Berry  <karl@gnu.org>
57029
57030         * config/config.{sub,guess}: update from config.
57031
57032         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
57033
57034 2003-11-17  Paul Eggert  <eggert@twinsun.com>
57035
57036         * README: Mention that S+T cannot overflow if S is the size of
57037         an existing object and T is sufficiently small.
57038
57039 2003-11-17  Jim Meyering  <jim@meyering.net>
57040
57041         On systems without utime and without a utimes function capable of
57042         dealing with a NULL struct utimbuf* argument, this utime replacement
57043         could -- in unusual circumstances -- leak a file descriptor.
57044         * lib/utime.c: Include <unistd.h> and <errno.h>.
57045         (utime_null): Be sure to close `fd' and to preserve errno.
57046         Reported by Geoff Collyer via Arnold Robbins.
57047
57048 2003-11-17  Bruno Haible  <bruno@clisp.org>
57049
57050         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
57051         (Depends-on): Add xsize.
57052
57053 2003-11-17  Bruno Haible  <bruno@clisp.org>
57054
57055         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
57056
57057 2003-11-17  Bruno Haible  <bruno@clisp.org>
57058
57059         * lib/vasnprintf.c (alloca): Remove fallback definition.
57060         (freea): Remove definition.
57061         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
57062         Reported by Paul Eggert.
57063
57064 2003-11-16  Paul Eggert  <eggert@twinsun.com>
57065             Bruno Haible  <bruno@clisp.org>
57066
57067         Protect against address arithmetic overflow.
57068         * lib/printf-args.h: Include stddef.h.
57069         (arguments): Change type of field 'count' to size_t.
57070         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
57071         'unsigned int' where appropriate.
57072         * lib/printf-parse.h: Include sys/types.h.
57073         (char_directive): Change type of *arg_index fields to ssize_t.
57074         (char_directives): Change type of fields 'count', max_*_length to
57075         size_t.
57076         * lib/printf-parse.c: Include sys/types.h and xsize.h.
57077         (SSIZE_MAX): Define fallback value.
57078         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
57079         instead of 'int' where appropriate. Check a_allocated, d_allocated
57080         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
57081         * lib/vasnprintf.c: Include xsize.h.
57082         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
57083         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
57084         overflow. Avoid wraparound when converting a width or precision from
57085         decimal to binary.
57086
57087 2003-11-16  Bruno Haible  <bruno@clisp.org>
57088
57089         Update from GNU gettext.
57090         * lib/printf-parse.c: Generalize to it can be compiled for wide
57091         strings.
57092         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
57093         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
57094         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
57095         SNPRINTF): New macros.
57096         Don't include <alloca.h> if the file is used inside libintl.
57097         (local_wcslen): New function, for Solaris 2.5.1.
57098         (VASNPRINTF): Use it instead of wcslen.
57099
57100 2003-11-16  Bruno Haible  <bruno@clisp.org>
57101
57102         * lib/xsize.h (xmax): New function.
57103         (xsum, xsum3, xsum4): Declare as "pure" functions.
57104
57105 2003-11-12  Paul Eggert  <eggert@twinsun.com>
57106
57107         * modules/xalloc (Files): Undo latest change, since xalloc.h
57108         no longer needs SIZE_MAX or PTRDIFF_MAX.
57109
57110 2003-11-12  Paul Eggert  <eggert@twinsun.com>
57111
57112         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
57113         gl_PTRDIFF_MAX.
57114
57115 2003-11-12  Paul Eggert  <eggert@twinsun.com>
57116
57117         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
57118         "return", to pacify some unknown compiler.  Problem reported
57119         by Joerg Schilling.
57120
57121 2003-11-12  Paul Eggert  <eggert@twinsun.com>
57122
57123         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
57124         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
57125         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
57126         heuristic is just as accurate as far as we know, and it removes a
57127         dependency on size_max.m4 and ptrdiff_max.m4.
57128
57129 2003-11-11  Bruno Haible  <bruno@clisp.org>
57130
57131         * modules/xsize (Files): Add m4/size_max.m4.
57132         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
57133
57134 2003-11-11  Bruno Haible  <bruno@clisp.org>
57135
57136         * m4/size_max.m4: New file.
57137         * m4/ptrdiff_max.m4: New file.
57138         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
57139         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
57140         (gl_XALLOC): Invoke it.
57141
57142 2003-11-11  Bruno Haible  <bruno@clisp.org>
57143
57144         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
57145         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
57146         defined.
57147
57148 2003-11-10  Paul Eggert  <eggert@twinsun.com>
57149
57150         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
57151         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
57152         rejected some allocations of exactly SIZE_MAX - 2 bytes.
57153         From Bruno Haible.
57154         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
57155         not (size_t) -1, since it's defined here.
57156
57157 2003-11-09  Karl Berry  <karl@gnu.org>
57158
57159         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
57160
57161 2003-11-06  Paul Eggert  <eggert@twinsun.com>
57162
57163         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
57164         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
57165         Reject sizes of exactly SIZE_MAX bytes.
57166         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
57167         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
57168
57169 2003-11-05  Bruno Haible  <bruno@clisp.org>
57170
57171         * lib/xsize.h: Include limits.h, to avoid a possible collision with
57172         SIZE_MAX defined in <limits.h> on Solaris.
57173
57174 2003-11-04  Jim Meyering  <jim@meyering.net>
57175
57176         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
57177         variable names, rather than @VAR@.
57178         * modules/poll: Likewise.
57179
57180 2003-11-04  Bruno Haible  <bruno@clisp.org>
57181
57182         * modules/xsize: New file.
57183         * modules/linebreak: Depend on xsize.
57184         * MODULES.html.sh (func_all_modules): Add xsize.
57185
57186 2003-11-04  Bruno Haible  <bruno@clisp.org>
57187
57188         * m4/xsize.m4: New file.
57189
57190 2003-11-04  Bruno Haible  <bruno@clisp.org>
57191
57192         * lib/xsize.h: New file.
57193         * lib/linebreak.c: Include xsize.h.
57194         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
57195         argument for overflow.
57196         Suggested by Paul Eggert.
57197
57198 2003-11-03  Karl Berry  <karl@gnu.org>
57199
57200         * config/config.{guess,sub}: update from config.
57201
57202 2003-11-03  Jim Meyering  <jim@meyering.net>
57203
57204         * modules/userspec (lib_SOURCES): Add userspec.h.
57205         (Include): Add "userspec.h".
57206         Improve description.
57207
57208 2003-11-03  Jim Meyering  <jim@meyering.net>
57209
57210         * lib/userspec.c: Include "userspec.h".
57211         * lib/userspec.h: New file.
57212
57213 2003-11-03  Bruno Haible  <bruno@clisp.org>
57214
57215         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
57216
57217 2003-11-03  Bruno Haible  <bruno@clisp.org>
57218
57219         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
57220         available, to avoid (extremely rare) race condition.
57221         Suggested by Paul Eggert.
57222
57223 2003-11-02  Karl Berry  <karl@gnu.org>
57224
57225         * config/srclist.txt (vasprintf.c): sync broken, sigh.
57226
57227 2003-10-31  Paul Eggert  <eggert@twinsun.com>
57228
57229         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
57230         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
57231         (read_filesystem_list): Set and use me_type_malloced.
57232         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
57233         whatever the type happens to be), for brevity and consistency.
57234         Check for size calculation overflow on Alphas running OSF/1.
57235
57236 2003-10-31  Jim Meyering  <jim@meyering.net>
57237
57238         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
57239
57240         * lib/linebuffer.c: Include <string.h> for declaration of memset.
57241
57242 2003-10-30  Paul Eggert  <eggert@twinsun.com>
57243             Bruno Haible  <bruno@clisp.org>
57244
57245         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
57246         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
57247
57248 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
57249
57250         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
57251         netbsd*-gnu*.  Suggested by Robert Millan.
57252
57253 2003-10-29  Paul Eggert  <eggert@twinsun.com>
57254
57255         * modules/group-member: Depend on stdbool.
57256
57257 2003-10-29  Paul Eggert  <eggert@twinsun.com>
57258
57259         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
57260
57261 2003-10-29  Paul Eggert  <eggert@twinsun.com>
57262
57263         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
57264         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
57265         after the 'gnu' in these cases.  This fixes some bugs in the
57266         previous change, and is based on suggestions by Robert Millan.
57267
57268 2003-10-29  Paul Eggert  <eggert@twinsun.com>
57269
57270         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
57271         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
57272         no longer needed.
57273         * lib/quotearg.c (quotearg_n_options): Use it.
57274         * lib/group-member.c: Include <stdbool.h>.
57275         (free_group_info): Arg is now const *; don't free arg.
57276         (get_group_info): Now returns bool and accepts struct group_info *,
57277         rather than returning a malloc'ed struct group_info *.
57278         All uses changed.  Check for overflow in internal size calculation.
57279
57280         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
57281         rather than xmalloc/xrealloc.
57282         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
57283         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
57284         conformance bug: the old code used a pointer after freeing the
57285         storage that it addressed.
57286         * lib/hash.c (hash_initialize): Simplify the code by using
57287         xalloc_oversized rather than doing it by hand.
57288         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
57289         the buffer preserved.  Use free and xmalloc instead.
57290         * lib/quotearg.c (quotearg_n_options): Likewise.
57291         Use a simpler test for size overflow.  Don't use xalloc_oversized
57292         because unsigned int might be wider than size_t (!); this suggests
57293         that we should switch from unsigned int to size_t for slot numbers.
57294
57295 2003-10-28  Paul Eggert  <eggert@twinsun.com>
57296
57297         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
57298         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
57299         NetBSD kernels.  Requested by Richard Stallman.
57300
57301 2003-10-27  Paul Eggert  <eggert@twinsun.com>
57302
57303         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
57304         to allocate the returned structure.  Do not allocate a subarray,
57305         as x2nrealloc will do that.
57306         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
57307         instead of xnrealloc.
57308         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
57309
57310 2003-10-27  Bruno Haible  <bruno@clisp.org>
57311
57312         * lib/stdbool_.h: Better support for BeOS.
57313
57314 2003-10-26  Paul Eggert  <eggert@twinsun.com>
57315
57316         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
57317         now uses inline.
57318
57319 2003-10-26  Paul Eggert  <eggert@twinsun.com>
57320
57321         * lib/xalloc.h (xalloc_oversized): New static inline function, for
57322         callers that want to do their own size-overflow checking.  Include
57323         <stdbool.h>, since xalloc_oversized returns bool.
57324         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
57325         to use xalloc_oversized.
57326
57327         Add two functions x2realloc, x2nrealloc, for programs that grow
57328         arrays dynamically by doubling their sizes.
57329         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
57330         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
57331         New functions.
57332
57333         Port to C99 semantics for 'inline' of external functions.
57334         Bug reported by Bruno Haible.
57335         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
57336         with the old contents of xnmalloc.
57337         (xnmalloc, xmalloc): Use it.
57338         (xnrealloc_inline): New static inline function,
57339         with the old contents of xnrealloc.
57340         (xnrealloc, xrealloc): Use it.
57341
57342         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
57343         that.
57344
57345 2003-10-26  Karl Berry  <karl@gnu.org>
57346
57347         * config/srclist.txt (COPYING.DOC): no longer available from
57348         /gd/gnuorg; don't know where the ultimate source is.
57349
57350 2003-10-25  Paul Eggert  <eggert@twinsun.com>
57351
57352         Fix several address-calculation bugs in the hash modules,
57353         plus some minor code cleanup.
57354
57355         * lib/hash.h: Include <stdbool.h>, for bool.
57356         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
57357         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
57358         hash_get_n_entries, hash_get_max_bucket_length,
57359         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
57360         hash_rehash): Use size_t rather than unsigned.
57361         * lib/hash.c (struct hash_table, hash_get_n_buckets,
57362         hash_get_n_buckets_used, hash_get_n_entries,
57363         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
57364         hash_get_entries, hash_do_for_each, hash_string, is_prime,
57365         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
57366         Likewise.
57367         (SIZE_MAX): Define if not defined.
57368         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
57369         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
57370         hash_print):
57371         Use const * when possible.
57372         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
57373         (check_tuning): Fix bug: if tuning parameters were very close to
57374         0 or 1, rounding errors could have caused subscript violations.
57375         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
57376         (hash_initialize): Add 'fail:' label
57377         to free table and return NULL, and use it to simplify code.
57378         Use calloc rather than clearing the storage ourself.
57379         (hash_initialize, hash_rehash): Check for arithmetic overflow in
57380         buffer size calculations.
57381         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
57382         Include <stddef.h>, for size_t.
57383         * lib/hash-pjw.c (hash_pjw): Likewise.
57384         Switch to method described by Bruno Haible.
57385         Include <limits.h>, for CHAR_BIT.
57386         (SIZE_BITS): New macro.
57387
57388 2003-10-23  Paul Eggert  <eggert@twinsun.com>
57389
57390         * m4/getline.m4 (AM_FUNC_GETLINE):
57391         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
57392         hosts.  Problem reported by Derek Robert Price in
57393         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
57394         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
57395         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
57396
57397 2003-10-21  Paul Eggert  <eggert@twinsun.com>
57398
57399         * lib/getndelim2.c (getndelim2): When size calculation overflows,
57400         ceiling the allocation at NMAX bytes rather than silently
57401         discarding input bytes before NMAX is reached.  This makes
57402         a difference only if NMAX exceeds SIZE_MAX / 2.
57403
57404         * lib/obstack.c: Merge from glibc.
57405         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
57406         Add libc_hidden_def (_obstack_newchunk).
57407         (_obstack_free) [! defined _LIBC]: Remove.
57408         [defined _LIBC]: Make a strong alias from obstack_free, rather than
57409         a clone of the function body.
57410         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
57411         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
57412
57413         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
57414         glibc.
57415         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
57416         arg to memcpy.
57417
57418         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
57419         (obstack_ptr_grow_fast, obstack_int_grow_fast):
57420         Don't use lvalue casts, as GCC plans to remove support for them
57421         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
57422         was also present in the non-GCC version, indicating that this
57423         code had always been buggy and had never been widely used.
57424         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
57425         Use the fast variant of each macro, rather than copying the
57426         definiens of the fast variant; that way, we'll be more likely to
57427         catch future bugs in the fast variants.
57428
57429 2003-10-20  Bruno Haible  <bruno@clisp.org>
57430
57431         * modules/wait-process: New file.
57432         * MODULES.html.sh (func_all_modules): Add wait-process.
57433
57434 2003-10-20  Bruno Haible  <bruno@clisp.org>
57435
57436         * m4/wait-process.m4: New file.
57437
57438 2003-10-20  Bruno Haible  <bruno@clisp.org>
57439
57440         * lib/wait-process.h: New file, from GNU gettext.
57441         * lib/wait-process.c: New file, from GNU gettext.
57442
57443 2003-10-19  Jim Meyering  <jim@meyering.net>
57444
57445         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
57446         HPUX 10.20.
57447
57448 2003-10-18  Karl Berry  <karl@gnu.org>
57449
57450         * config/config.guess: update from config.
57451
57452 2003-10-16  Paul Eggert  <eggert@twinsun.com>
57453
57454         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
57455         (getgroups): First arg is int, not size_t.
57456         Don't let 'free' mangle errno.
57457
57458 2003-10-16  Paul Eggert  <eggert@twinsun.com>
57459
57460         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
57461
57462 2003-10-16  Karl Berry  <karl@gnu.org>
57463
57464         * config/config.{guess,sub}: update from config.
57465
57466 2003-10-16  Jim Meyering  <jim@meyering.net>
57467
57468         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
57469         memcpy.
57470
57471 2003-10-15  Paul Eggert  <eggert@twinsun.com>
57472
57473         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
57474         (SIZE_MAX): Remove.
57475         (new_exclude, add_exclude_file): Initial size no longer needs to
57476         be a power of 2.
57477         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
57478         our own address arithmetic overflow checking.
57479
57480         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
57481         (fnmatch): Do not alloca more than 2000 wide characters;
57482         instead, use malloc for large buffers.
57483         Check for address arithmetic overflow, and return -1
57484         with errno set to ENOMEM in that case.
57485         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
57486         (NEW_PATTERN): Do not alloca more than 8000 bytes;
57487         instead, return -1.  Check for address arithmetic overflow.
57488
57489 2003-10-14  Paul Eggert  <eggert@twinsun.com>
57490
57491         Handle invalid suffixes and overflow independently, so that
57492         callers can treat them independently as needed.  Fix some bugs in
57493         suffix handling, e.g., "100k@" was not diagnosed as an invalid
57494         suffix for a human-readable blocksize.  The major caller-visible
57495         change is the addition of a new
57496         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
57497         that both overflow and suffix chars were found.
57498
57499         * lib/human.c (humblock): Don't check separately for invalid suffix
57500         char; that is xstrtoumax's job (now that its bug is fixed).
57501         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
57502         INTMAX_MAX]: New macros.
57503         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
57504         TYPE_MAXIMUM): New macros.
57505         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
57506         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
57507         if overflow occurs, as it's what __strtol does and it's more useful
57508         in practice.
57509         (__xstrtol): If __strtol reports some error other than ERANGE,
57510         reflect it to the caller as LONGINT_INVALID.  If it reports
57511         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
57512         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
57513         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
57514         value.
57515         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
57516         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
57517         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
57518         [defined UINTMAX_MAX]: New macros.
57519
57520 2003-10-14  Bruno Haible  <bruno@clisp.org>
57521
57522         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
57523
57524 2003-10-14  Bruno Haible  <bruno@clisp.org>
57525
57526         * m4/sig_atomic_t: New file, from GNU gettext.
57527         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
57528
57529 2003-10-14  Bruno Haible  <bruno@clisp.org>
57530
57531         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
57532         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
57533         Also use volatile where needed.
57534
57535 2003-10-12  Paul Eggert  <eggert@twinsun.com>
57536
57537         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
57538         Change maintainer from Bruno Haible to 'all'.
57539
57540 2003-10-12  Paul Eggert  <eggert@twinsun.com>
57541
57542         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
57543
57544 2003-10-12  Paul Eggert  <eggert@twinsun.com>
57545
57546         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
57547         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
57548         and define in terms of the other primitives.
57549         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
57550         (SIZE_MAX): Define if not already defined.
57551         (array_size_overflow): New function.
57552         (xalloc_die): Abort instead of exiting if 'error' returns.
57553         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
57554         (xmalloc, xrealloc): Use them.
57555         (xcalloc): Check for address arithmetic overflow.
57556         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
57557         a bit faster than strcpy.
57558
57559 2003-10-10  Simon Josefsson  <jas@extundo.com>
57560
57561         * modules/argp (Depends-on): Add restrict and strcase.
57562
57563 2003-10-10  Simon Josefsson  <jas@extundo.com>
57564
57565         * m4/argp.m4: Add AC_C_INLINE.
57566
57567 2003-10-08  Paul Eggert  <eggert@twinsun.com>
57568
57569         Merge getpass from libc, plus a few fixes.
57570
57571         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
57572         Include <stdbool.h>.
57573         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
57574         __fsetlocking to empty.
57575         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
57576         do include <bits/libc-lock.h>.
57577         Do not include <fcntl.h>; not needed.
57578         [_LIBC]: Include <wchar.h>.
57579         (NOTCANCEL_MODE): New macro.
57580         (flockfile, funlockfile) [_LIBC]: New macros.
57581         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
57582         [!_LIBC]: New macros.
57583         (call_fclose): New function.
57584         (getpass): Use it.  Save tty stream separately; this simplifies the
57585         code and makes it more reliable if stdin happens to equal stdout.
57586         Invoke __fsetlocking on tty.
57587         Handle thread cancellation if needed.
57588         Namespace cleanup (use __tcgetattr, __getline).
57589         Use bool for Booleans.
57590         [USE_IN_LIBIO]: Handle wide streams.
57591         [!_LIBC]: Unconditionally do the fseek, since we don't know what
57592         stream might go where.
57593
57594         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
57595         doesn't have to include <stdio.h> before us.
57596         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
57597         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
57598         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
57599         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
57600         if not declared, so that we can use getpass.c code from libc without
57601         rewriting it.
57602         (flockfile, ftrylockfile, funlockfile): New macros.
57603
57604 2003-10-08  Paul Eggert  <eggert@twinsun.com>
57605
57606         * modules/getpass: Depend on stdbool.
57607
57608 2003-10-08  Paul Eggert  <eggert@twinsun.com>
57609
57610         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
57611
57612 2003-10-07  Karl Berry  <karl@gnu.org>
57613
57614         * config/config.{guess,sub}: update from config.
57615
57616 2003-10-06  Jim Meyering  <jim@meyering.net>
57617             Bruno Haible  <bruno@clisp.org>
57618
57619         This lets translators provide better translations for the
57620         "Written by ..." part of --version output.
57621         * lib/version-etc.h: Include stdarg.h.
57622         (version_etc_copyright): Declare as readonly.
57623         (version_etc): Make this function variadic with a NULL-terminated list
57624         of author name strings.
57625         (version_etc_va): New declaration.
57626         * lib/version-etc.c: Include stdarg.h, stdlib.h.
57627         (version_etc_copyright): Declare as readonly.
57628         (version_etc_va): New function. Provide a different translatable string
57629         for each possible number of authors < 10. Abbreviate when there are 10
57630         authors or more.
57631         (version_etc): Make this function variadic. Call version_etc_va.
57632         Suggestion from Gary V. Vaughan.
57633
57634         * lib/long-options.h (parse_long_options): Change prototype: the
57635         authors string is moved to the end and becomes variadic.
57636         * lib/long-options.c: Include stdarg.h.
57637         (parse_long_options): Make this function variadic, too.
57638         Call version_etc_va, not version_etc.
57639
57640 2003-10-06  Bruno Haible  <bruno@clisp.org>
57641
57642         * modules/version-etc-2: Remove file.
57643         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
57644
57645 2003-10-06  Bruno Haible  <bruno@clisp.org>
57646
57647         * modules/fatal-signal: New file.
57648         * MODULES.html.sh (func_all_modules): Add fatal-signal.
57649
57650 2003-10-06  Bruno Haible  <bruno@clisp.org>
57651
57652         * m4/fatal-signal.m4: New file.
57653         * m4/signalblocking.m4: New file, from GNU gettext.
57654
57655 2003-10-06  Bruno Haible  <bruno@clisp.org>
57656
57657         * lib/version-etc-2.h: Remove file.
57658         * lib/version-etc-2.c: Remove file.
57659
57660 2003-10-06  Bruno Haible  <bruno@clisp.org>
57661
57662         * lib/fatal-signal.h: New file, from GNU gettext.
57663         * lib/fatal-signal.c: New file, from GNU gettext.
57664
57665 2003-10-05  Paul Eggert  <eggert@twinsun.com>
57666
57667         * README: Rework advice for preventing empty .o files.
57668         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
57669         not <sys/types.h>.
57670
57671 2003-10-04  Karl Berry  <karl@gnu.org>
57672
57673         * lib/argp*: update from libc.
57674
57675 2003-10-04  Karl Berry  <karl@gnu.org>
57676
57677         * config/config.{guess,sub}: update from config.
57678
57679 2003-10-02  Bruno Haible  <bruno@clisp.org>
57680
57681         * modules/lchown (Include): Add lchown.h.
57682         * modules/time_r (Include): Use "..." syntax.
57683         * modules/xgetdomainname (Include): Add xgetdomainname.h.
57684
57685 2003-10-01  Simon Josefsson  <jas@extundo.com>
57686
57687         * MODULES.html.sh (func_all_modules): Move gethostname from section
57688         'based on' to section 'lacking' POSIX:2001.
57689
57690 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
57691
57692         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
57693         to output mode on the same stream.
57694
57695 2003-09-29  Paul Eggert  <eggert@twinsun.com>
57696
57697         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
57698         Fix arg typo in previous patch.
57699
57700 2003-09-28  Jim Meyering  <jim@meyering.net>
57701
57702         * lib/error.c: Correct cpp indentation.
57703
57704 2003-09-27  Paul Eggert  <eggert@twinsun.com>
57705
57706         * modules/free: New file.
57707
57708 2003-09-27  Paul Eggert  <eggert@twinsun.com>
57709
57710         * m4/free.m4: New file.
57711
57712 2003-09-27  Paul Eggert  <eggert@twinsun.com>
57713
57714         * lib/minmax.h (MIN, MAX)
57715         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
57716         Omit the special code that used __typeof__, since we worry that
57717         it could be more trouble than it's worth.  See:
57718         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
57719         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
57720
57721         * lib/free.c: New file.
57722
57723 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
57724
57725         Trivial fixes to Makefile.am parts of module listings.
57726         * modules/strstr: Append strstr.h to lib_SOURCES.
57727         * modules/strcase: Likewise, for strcase.h.
57728
57729 2003-09-27  Karl Berry  <karl@gnu.org>
57730
57731         * config/mkinstalldirs: update from automake.
57732
57733 2003-09-26  Paul Eggert  <eggert@twinsun.com>
57734
57735         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
57736         (error_tail): Do not loop, reallocating temporary buffer, since
57737         the output cannot contain more wide characters than the input
57738         contains bytes, the size must be big enough already.  This avoids
57739         one potential size overflow calculation.  Check for size overflow
57740         when calculating temporary buffer size.  Free temporary buffer
57741         when done, if it was allocated with malloc; this plugs a memory
57742         leak.  Remove casts from void * to pointers, that are no longer
57743         needed now that we're assuming C89 or better.
57744
57745         Merge error changes from glibc.
57746
57747         * lib/error.c, error.h: Update copyright notice header to match glibc.
57748         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
57749         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
57750         Disable cancellation while printing error.
57751         * lib/error.h: Prepend __ to parameter names.
57752
57753 2003-09-26  Jim Meyering  <jim@meyering.net>
57754
57755         * lib/error.c (error_tail): Move some declarations
57756         into inner scope where the local variables are used.
57757
57758 2003-09-26  Bruno Haible  <bruno@clisp.org>
57759
57760         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
57761         stpncpy().
57762         Don't define stpncpy through config.h; it's now done through stpncpy.h.
57763
57764 2003-09-26  Bruno Haible  <bruno@clisp.org>
57765
57766         * lib/stpncpy.h (gnu_stpncpy): New declaration.
57767         (stpncpy): Define as alias for gnu_stpncpy.
57768         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
57769
57770 2003-09-25  Simon Josefsson  <jas@extundo.com>
57771
57772         * lib/xgetdomainname.h: New file.
57773         * lib/xgetdomainname.c: New file.
57774
57775 2003-09-25  Simon Josefsson  <jas@extundo.com>
57776             Bruno Haible  <bruno@clisp.org>
57777
57778         * modules/getdomainname: New file.
57779         * modules/xgetdomainname: New file.
57780         * MODULES.html.sh (func_all_modules): Add getdomainname,
57781         xgetdomainname.
57782
57783 2003-09-25  Simon Josefsson  <jas@extundo.com>
57784             Bruno Haible  <bruno@clisp.org>
57785
57786         * m4/getdomainname.m4: New file.
57787
57788 2003-09-25  Simon Josefsson  <jas@extundo.com>
57789             Bruno Haible  <bruno@clisp.org>
57790
57791         * lib/getdomainname.h: New file.
57792         * lib/getdomainname.c: New file.
57793
57794 2003-09-25  Karl Berry  <karl@gnu.org>
57795
57796         * lib/argp-fmtstream.c, argp-help.c: update from libc.
57797
57798 2003-09-25  Karl Berry  <karl@gnu.org>
57799
57800         * config/install-sh: update from automake.
57801
57802 2003-09-25  Bruno Haible  <bruno@clisp.org>
57803
57804         * modules/version-etc-2: New file, from modules/version-etc with
57805         modifications.
57806         * MODULES.html.sh (func_all_modules): Add version-etc-2.
57807
57808 2003-09-25  Bruno Haible  <bruno@clisp.org>
57809
57810         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
57811         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
57812
57813 2003-09-24  Simon Josefsson  <jas@extundo.com>
57814
57815         * modules/xgethostname: Add xgethostname.h.
57816
57817 2003-09-24  Paul Eggert  <eggert@twinsun.com>
57818
57819         * lib/linebuffer.c (freebuffer): Don't free the argument, just
57820         the buffer associated with the argument.  Bug reported by
57821         Simon Josefsson.
57822
57823 2003-09-24  Paul Eggert  <eggert@twinsun.com>
57824
57825         * README: Document assumptions that 'int' is at least 32 bits
57826         wide, that integer arithmetic is 2's complement without overflow,
57827         that there are no holes in integer values, that adding sizes of
57828         two nonoverlapping objects can't overflow, and that all-bits-zero
57829         yields scalar zero.  Fix spelling and capitalization typos.
57830
57831 2003-09-19  Karl Berry  <karl@gnu.org>
57832
57833         * lib/argp.h: update from libc.
57834
57835 2003-09-17  Paul Eggert  <eggert@twinsun.com>
57836
57837         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
57838         to avoid spurious warnings like "AC_RUN_IFELSE was called before
57839         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
57840
57841 2003-09-17  Paul Eggert  <eggert@twinsun.com>
57842
57843         * gnulib-tool: Use "test -h", not "test -L", for portability
57844         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
57845         (tags_regexp): Remove, since \| doesn't conform to POSIX.
57846         (sed_extract_prog): Issue s commands one-by-one, rather than
57847         using \| in one s command.
57848
57849 2003-09-16  Paul Eggert  <eggert@twinsun.com>
57850
57851         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
57852         input error, instead of returning NULL the next time we are called
57853         (and therefore losing track of errno).
57854
57855 2003-09-16  Bruno Haible  <bruno@clisp.org>
57856
57857         * gnulib-tool (func_create_testdir): Warn about duplicated
57858         dependencies.
57859
57860 2003-09-15  Paul Eggert  <eggert@twinsun.com>
57861
57862         * modules/argmatch, modules/fatal, modules/obstack,
57863         modules/xalloc, modules/xgethostname: Sort dependencies by
57864         importance, not alphabetically.
57865
57866 2003-09-15  Paul Eggert  <eggert@twinsun.com>
57867
57868         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
57869         fails, so that the caller gets the proper errno.
57870
57871         * lib/readutmp.c (read_utmp): Likewise.
57872         Check for fstat error.  Close stream and free storage
57873         when failing.
57874
57875 2003-09-14  Karl Berry  <karl@gnu.org>
57876
57877         * config/srclist.txt (strdup.c): disable for c89 changes.
57878
57879 2003-09-14  Jim Meyering  <jim@meyering.net>
57880
57881         * lib/getloadavg.c: Correct cpp indentation.
57882         * lib/strdup.c: Likewise.
57883         * lib/vasnprintf.c: Likewise.
57884
57885 2003-09-14  Bruno Haible  <bruno@clisp.org>
57886
57887         * modules/fwriteerror: New file.
57888         * MODULES.html.sh (func_all_modules): Add fwriteerror.
57889
57890 2003-09-14  Bruno Haible  <bruno@clisp.org>
57891
57892         * lib/fwriteerror.h: New file.
57893         * lib/fwriteerror.c: New file.
57894
57895 2003-09-12  Paul Eggert  <eggert@twinsun.com>
57896
57897         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
57898         modules/xgethostname, modules/xalloc: Depend on exit.
57899
57900 2003-09-12  Paul Eggert  <eggert@twinsun.com>
57901
57902         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
57903
57904         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
57905         and AC_MINIX, too, so that their extensions are available.
57906
57907         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
57908         This macro has been superseded by gl_BACKUPFILE.
57909
57910         More patches to assume C89 or better.
57911
57912         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
57913
57914         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
57915         unconditionally.
57916         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
57917         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
57918         Include <string.h>, <stdlib.h> unconditionally.
57919         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
57920         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
57921         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
57922         headers or for string.h.
57923         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
57924         or strtoul.
57925
57926         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
57927         headers.
57928         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
57929         * m4/userspec.m4 (gl_USERSPEC): Likewise.
57930         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
57931         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
57932         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
57933         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
57934         memcpy, memset.
57935         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
57936         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
57937         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
57938         strtol.
57939         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
57940         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
57941         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
57942         strtoul.
57943
57944 2003-09-12  Paul Eggert  <eggert@twinsun.com>
57945
57946         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
57947         * lib/obstack.c [!defined _LIBC]: Likewise.
57948         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
57949         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
57950         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
57951
57952         More changes to assume C89 or better.
57953
57954         * lib/error.c (error_tail): Assume vprintf.
57955
57956         * lib/argmatch.c (getenv): Remove decl.
57957         * lib/progreloc.c (get_full_program_name): Define via prototype.
57958         * lib/setenv.c (clearenv): Likewise.
57959         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
57960         needed.
57961         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
57962         (malloc, memcpy): Remove decls.
57963         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
57964         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
57965         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
57966         (memcpy): Remove macro.
57967         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
57968         (__P): Remove.  All uses removed.
57969         (PTR): Remove.  All uses changed to void *.
57970         (CHAR_BIT, NULL): Remove.
57971         (spaces, zeros, memset_space, memset_zero)
57972         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
57973         Remove.
57974         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
57975         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
57976         Define with prototype.
57977         Remove now-unnecessary prototype decl.
57978         (extra_args_spec): Assume ANSI C.  All uses changed.
57979         (extra_args_spec_iso): Remove.
57980         (my_strftime, emacs_strftimeu): Define via prototype.
57981         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
57982         unconditionally.
57983         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
57984         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
57985         (strtoul, strtol): Remove decls.
57986         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
57987         LONG_MAX): Remove.
57988         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
57989         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
57990         (LOCALE_PARAM_PROTO): New macro.
57991         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
57992         (INTERNAL (strtol), strtol): Define with a prototype.
57993         (PARAMS): Remove.  All uses removed.
57994         * lib/tempname.c: Include <string.h> unconditionally.
57995         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
57996         * lib/xgethostname.c (main): Define with a prototype.
57997         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
57998         Include <stdlib.h> unconditionally.
57999         (calloc, malloc, realloc, free): Remove decls.
58000         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
58001         Include <stdlib.h> unconditionally.  Sort include file names.
58002         (strtod): Remove.
58003         (xstrtod): Define with a prototype.
58004         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
58005         (strtol, strtoul): Remove decls.
58006
58007 2003-09-11  Paul Eggert  <eggert@twinsun.com>
58008
58009         More patches to assume C89 or better.
58010         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
58011         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
58012         string.h, memchr, STDC_HEADERS.
58013
58014 2003-09-11  Paul Eggert  <eggert@twinsun.com>
58015
58016         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
58017         Include <stdlib.h>, <string.h> unconditionally.
58018         Remove now-unnecessary cast to char *.
58019         * lib/strnlen.c: Include <string.h> unconditionally.
58020         * lib/yesno.c (yesno): Define with a prototype.
58021
58022 2003-09-11  Bruno Haible  <bruno@clisp.org>
58023
58024         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
58025
58026 2003-09-10  Jim Meyering  <jim@meyering.net>
58027
58028         * lib/error.c: Correct indentation of cpp directives.
58029
58030 2003-09-10  Bruno Haible  <bruno@clisp.org>
58031
58032         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
58033         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
58034         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
58035         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
58036         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
58037         <stdlib.h> and <string.h> checks.
58038         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
58039         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
58040
58041 2003-09-10  Bruno Haible  <bruno@clisp.org>
58042
58043         * lib/strcspn.c: Include <string.h> unconditionally.
58044         * lib/strpbrk.c: Include <string.h> unconditionally.
58045         * lib/strstr.c: Include <string.h> unconditionally.
58046         * lib/unicodeio.c: Include <string.h> unconditionally.
58047         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
58048         * lib/unsetenv.c: Likewise.
58049         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
58050         * lib/yesno.c: Include <stdlib.h> unconditionally.
58051         (rpmatch): Add prototype.
58052
58053 2003-09-09  Paul Eggert  <eggert@twinsun.com>
58054
58055         More patches to assume C89 or better.
58056         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
58057         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
58058         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
58059         or for string.h.
58060         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
58061         stdlib.h.
58062         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
58063         C headers.
58064         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
58065         string.h.
58066         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
58067         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
58068         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
58069         or for string.h.
58070         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
58071         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
58072         C headers.
58073         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
58074         memcpy.
58075         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
58076         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
58077         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
58078         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
58079         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
58080         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
58081         string.h, free.
58082         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
58083         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
58084         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
58085         C headers, or for string.h.
58086         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
58087         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
58088         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
58089         headers, memory.h, stdlib.h, string.h, strings.h.
58090         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
58091         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
58092         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
58093         strchr.
58094         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
58095         headers, memory.h, string.h.
58096         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
58097         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
58098         free.
58099         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
58100         headers.
58101         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
58102         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
58103         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
58104         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
58105         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
58106
58107 2003-09-09  Paul Eggert  <eggert@twinsun.com>
58108
58109         More K&R removal.
58110
58111         * lib/acosl.c (main): Use a prototype.
58112         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
58113         tanl.c: Likewise.
58114
58115         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
58116
58117         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
58118         (getopt, etopt_long, getopt_long_only, _getopt_internal)
58119         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
58120         with a prototype.
58121         * lib/getopt.c (const): Remove macro.
58122         Include <string.h> unconditionally.
58123         (my_index): Remove; all uses changed to strchr.
58124         (strlen): Remove decl.
58125         (exchange): Remove forward decl; no longer needed.
58126         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
58127         Define with prototype.
58128         * lib/getopt1.c (const): Remove macro.
58129         (getopt_long, getopt_long_only, main): Define with prototype.
58130
58131         * lib/getugroups.c: Include <string.h> unconditionally.
58132
58133         * lib/getusershell.c: Include <stdlib.h> unconditionally.
58134         (getusershell, setusershell, endusershell, readname, main):
58135         Define with prototypes.
58136
58137         * lib/group-member.c: Include group-member.h first.
58138         Include <stdlib.h> unconditionally.
58139
58140         * lib/hard-locale.c: Include hard-locale.h first.
58141         Include <stdlib.h>, <string.h> unconditionally.
58142
58143         * lib/hash.c (free, malloc): Remove decls.
58144         Include <stdlib.h> unconditionally.
58145
58146         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
58147         (getenv): Do not declare.
58148
58149         * lib/idcache.c: Include <string.h> unconditionally.
58150
58151         * lib/long-options.c: Include long-options.h first, to test interface.
58152         Include <stdlib.h> unconditionally.
58153
58154         * lib/makepath.c: Include makepath.h first, to test interface.
58155         Include <stdlib.h> and <string.h> unconditionally.
58156
58157         * lib/linebuffer.c: Include <stdlib.h>.
58158         (free): Remove decl.
58159
58160         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
58161         stddef.h. rpl_malloc returns void *, not char *.
58162         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
58163         prototype.
58164
58165         * lib/md5.h: Include <limits.h> unconditionally.
58166         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
58167         (__P): Remove; all uses removed.
58168         * lib/md5.c: Include "md5.h" first.
58169         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
58170         md5_buffer, md5_process_bytes, md5_process_block):
58171         Define with prototypes.
58172         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
58173         * lib/sha.c: Include "sha.h" first.
58174         Include <stdlib.h>, <string.h> unconditionally.
58175
58176         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
58177         * lib/memcmp.c (__ptr_t): Likewise.
58178         * lib/memrchr.c (__ptr_t): Likewise.
58179         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
58180         Include <string.h> unconditionally.
58181         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
58182         * lib/memchr.c: Include <stdlib.h> unconditionally.
58183         * lib/memchr.c (LONG_MAX): Remove.
58184         * lib/memrchr.c (LONG_MAX): Likewise.
58185         * lib/memchr.c (__memchr): Define via a prototype.
58186         * lib/memrchr.c (__memrchr): Likewise.
58187         * lib/memcmp.c (__P): Remove, and remove all uses.
58188         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
58189         Remove forward decls; no longer needed.
58190         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
58191         Use types required by C89 in prototype.
58192
58193         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
58194         * lib/savedir.c: Likewise.
58195         * lib/mkdir.c (free): Remove decl.
58196         * lib/rmdir.c (rmdir): Define with a prototype.
58197         * lib/savedir.c: Include savedir.h first, to test interface.
58198
58199         * lib/mktime.c (STDC_HEADERS): Remove.
58200         Include <stdlib.h>, <string.h> unconditionally.
58201
58202         * lib/modechange.c: Include <stdlib.h> unconditionally.
58203         (malloc): Remove decl.
58204
58205         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
58206         (free): Remove decl.
58207
58208         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
58209         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
58210         (This type really should be intptr_t, but that's a C99ism.)
58211         (_obstack_memcpy): Remove: all uses changed to memcpy.
58212         Include <string.h> unconditionally.
58213         (struct obstack): Assume __STDC__ for types of members
58214         chunkfun, freefun, extra_arg.
58215         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
58216         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
58217         obstack_begin, obstack_specify_allocation,
58218         obstack_specify_allocation_with_arg, obstack_chunkfun,
58219         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
58220         Remove unprototyped decls and the macros that use them.
58221         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
58222         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
58223         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
58224         (defined __STDC__ && __STDC__)]:
58225         Remove nonprototyped code.
58226         Include <stdlib.h> unconditionally.
58227         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
58228         _obstack_allocated_p, _obstack_free, obstack_free,
58229         _obstack_memory_used, print_and_abort):
58230         Define using prototypes.
58231         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
58232         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
58233         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
58234         obstack_next_free, obstack_object_size, obstack_room) [0]:
58235         Remove unused, unprototyped code.
58236
58237         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
58238
58239         * lib/physmem.c (physmem_total, physmem_available, main): Define
58240         with prototypes.
58241
58242         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
58243         (main): Define with a prototype.
58244
58245         * lib/posixver.c (getenv): Remove decl.
58246
58247         * lib/putenv.c (malloc): Returns void *, not char *.
58248         Include <string.h> unconditionally.
58249         (strchr, memcpy, NULL): Do not define.
58250
58251         * lib/readtokens.c: Include readtokens.h first, to test interface.
58252         Include <stdlib.h>, <string.h> unconditionally.
58253         (init_tokenbuffer): Define with a prototype.
58254
58255         * lib/regex.c (PARAMS): Remove.  All uses removed.
58256         All uses of _RE_ARGS removed, too.
58257         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
58258         unconditionally.
58259         (bzero): Assume memset exists.
58260         (memcmp, memcpy, NULL): Remove.
58261         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
58262         char, or assignments to local vars of type signed char.
58263         (init_syntax_once, PREFIX(extract_number_and_incr),
58264         PREFIX(print_partial_compiled_pattern),
58265         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
58266         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
58267         PREFIX(regex_grow_registers), PREFIX(regex_compile),
58268         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
58269         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
58270         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
58271         wcs_compile_range, byte_compile_range, truncate_wchar,
58272         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
58273         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
58274         count_mbs_length, wcs_re_match_2_internal,
58275         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
58276         PREFIX(alt_match_null_string_p),
58277         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
58278         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
58279         regfree, PREFIX(extract_number)): Define with prototype.  Remove
58280         now-unnecessary declaration, if any.
58281         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
58282         regcomp, regexec):
58283         Remove now-unnecessary casts among pointer types.
58284         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
58285
58286         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
58287         (free): Remove decl.
58288
58289         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
58290
58291         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
58292         (free): Remove decl.
58293
58294         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
58295         * lib/xgetcwd.c: Likewise.
58296
58297         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
58298         (free): Remove decl.
58299
58300         * lib/strchrnul.c (strchrnul): Define with a prototype.
58301         Fix bug: c_in was not converted to char before searching.
58302
58303         The following changes are not K&R related:
58304
58305         * lib/group-member.h: Include <sys/types.h>, so that this file is
58306         self-contained.
58307         * lib/makepath.h: Likewise.
58308
58309         * lib/getusershell.c (readname, default_index, line_size, readname):
58310         Use size_t, not int, for sizes.
58311         (readname): If the size overflows, report an error instead of
58312         looping forever.
58313
58314 2003-09-09  Paul Eggert  <eggert@twinsun.com>
58315
58316         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
58317         libc.
58318
58319 2003-09-09  Paul Eggert  <eggert@twinsun.com>
58320
58321         * README: New section: portability guidelines.
58322
58323 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
58324
58325         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
58326         C89 spec.
58327
58328 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
58329
58330         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
58331
58332 2003-09-08  Paul Eggert  <eggert@twinsun.com>
58333
58334         Assume C89 or better; remove K&R cruft.
58335         A few of these changes were first proposed by Derek Robert Price
58336         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
58337
58338         * lib/addext.c: Include <string.h> unconditionally.
58339         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
58340         Don't declare getenv or malloc.
58341
58342         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
58343         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
58344         (NULL): Remove.
58345         (find_stack_direction, alloca): Use prototypes.
58346
58347         * lib/atexit.c (atexit): Define using a prototype.
58348
58349         * lib/basename.c, dirname.c, stripslash.c:
58350         Include <string.h> unconditionally.
58351
58352         * lib/bcopy.c: Include <stddef.h>.
58353         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
58354
58355         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
58356
58357         * lib/error.h (error, error_at_line, error_print_progname)
58358         [! (defined (__STDC__) && __STDC__)]: Remove decls.
58359         * lib/error.c: Include error.h first, to check interface.
58360         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
58361         (VA_START): Remove; all uses changeed to va_start.
58362         (exit, strerror): Remove decls.
58363         (error_print_progname): Prototype uncondionally.
58364         Don't include <errno.h>; no longer needed.
58365         (private_strerror): Remove.
58366         (error_tail): Always define.
58367         (error, error_at_line): Assume C89 or better; always use prototypes.
58368         * lib/fatal.c: Include "fatal.h" first, to test interface.
58369         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
58370         (VA_START): Remove; all uses changed to va_start.
58371         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
58372         this case.
58373         (exit): Remove decl.
58374         (fatal): Prototype unconditionally.  Assume va_start works.
58375         Abort at end, to pacify gcc.
58376
58377         * lib/euidaccess.c (main): Define with a prototype.
58378
58379         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
58380
58381         * lib/exitfail.c: Include <stdlib.h> unconditionally.
58382
58383         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
58384         prototypes.
58385         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
58386         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
58387         (getenv): Remove decl.
58388         (fnmatch): Define using a prototype.
58389         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
58390         (FCT): Define using a prototype.
58391
58392         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
58393
58394         * lib/gethostname.c: Include <stddef.h>.
58395         (gethostname): Define with prototype.  Length is size_t, not int.
58396
58397 2003-09-08  Paul Eggert  <eggert@twinsun.com>
58398
58399         Assume C89 or better; remove K&R cruft.
58400         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
58401         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
58402         string.h, getenv, malloc.
58403         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
58404         headers.
58405         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
58406         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
58407         do not check for strerror.
58408         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
58409         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
58410         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
58411         do not check for doprnt or vprintf.
58412         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
58413         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
58414
58415 2003-09-08  Paul Eggert  <eggert@twinsun.com>
58416
58417         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
58418         getversion.c should have been removed then, but was accidentally
58419         preserved.
58420
58421         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
58422         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
58423
58424 2003-09-08  Karl Berry  <karl@gnu.org>
58425
58426         * config/config.sub, config.guess, srclistvars.sh: update from savannah
58427                 config, forget about prep.
58428
58429         * config/depcomp, missing: update from automake.
58430
58431 2003-09-07  Paul Eggert  <eggert@twinsun.com>
58432
58433         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
58434         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
58435
58436 2003-09-07  Paul Eggert  <eggert@twinsun.com>
58437
58438         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
58439         copy_tm_result.  Bug reported by Simon Josefsson in
58440         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
58441
58442 2003-09-06  Paul Eggert  <eggert@twinsun.com>
58443
58444         * m4/time_r.m4: New file.
58445         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
58446         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
58447         is. Check for timegm declaration.
58448         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
58449         Do not check for gmtime_r.
58450         Replace mktime if __mktime_internal does not exist and if mktime
58451         hasn't been replaced already.
58452
58453 2003-09-06  Paul Eggert  <eggert@twinsun.com>
58454
58455         * lib/time_r.c, lib/time_r.h: New files.
58456
58457         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
58458         __localtime_r.
58459         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
58460         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
58461
58462         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
58463         __gmtime_r.
58464         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
58465         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
58466         Include <time_r.h>.
58467
58468         * lib/timegm.c: Switch to glibc implementation, with the following
58469         changes:
58470         [defined HAVE_CONFIG_H]: Include <config.h>.
58471         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
58472         (__mktime_internal) [!defined _LIBC]: New decl.
58473         (__gmtime_r) [!defined _LIBC]: New macro and function.
58474         (timegm): Use a prototype, since gnulib assumes C89.
58475         Do not bother declaring tmp to be const, as it's not really usefu.
58476         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
58477         (timegm): Declare only if HAVE_DECL_TIMEGM.
58478
58479 2003-09-06  Paul Eggert  <eggert@twinsun.com>
58480
58481         * MODULES.html.sh (func_all_modules): Add time_r.
58482         * modules/time_r: New file.
58483         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
58484         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
58485
58486 2003-09-03  Paul Eggert  <eggert@twinsun.com>
58487
58488         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
58489         Bug reported by Lute Kamstra in
58490         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
58491
58492         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
58493         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
58494         course with correspondingly smaller numbers for tomorrow and
58495         yesterday.  From Tadayoshi Funaba.  Originally installed into
58496         sh-utils on 1999-08-07, but the patch got lost (I guess during the
58497         coreutils merge?).
58498
58499 2003-08-31  Simon Josefsson  <jas@extundo.com>
58500
58501         * modules/timegm: New file.
58502         * MODULES.html.sh (func_all_modules): Add timegm.
58503
58504 2003-08-31  Simon Josefsson  <jas@extundo.com>
58505
58506         * m4/timegm.m4: New file.
58507
58508 2003-08-31  Simon Josefsson  <jas@extundo.com>
58509
58510         * lib/timegm.h: New file.
58511         * lib/timegm.c: New file.  Based on
58512         wget-1.8.2/src/http.c:mktime_from_utc.
58513
58514 2003-08-31  Karl Berry  <karl@gnu.org>
58515
58516         * lib/argp.h: update from libc.
58517
58518 2003-08-28  Bruno Haible  <bruno@clisp.org>
58519
58520         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
58521         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
58522         followed by '#define fnmatch fnmatch_posix' gives an error.
58523
58524 2003-08-28  Bruno Haible  <bruno@clisp.org>
58525
58526         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
58527         warning on QNX, which defines O_BINARY to 000000.
58528
58529 2003-08-27  Jim Meyering  <jim@meyering.net>
58530
58531         * m4/mkstemp.m4: Require that the system mkstemp be able to create
58532         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
58533         would fail after 32.  Reported by Danny Levinson.  Details here:
58534         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
58535
58536 2003-08-24  Bruno Haible  <bruno@clisp.org>
58537
58538         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
58539         MSVC7 <stdio.h> is included later.
58540
58541 2003-08-22  Simon Josefsson  <jas@extundo.com>
58542
58543         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
58544
58545 2003-08-20  Karl Berry  <karl@gnu.org>
58546
58547         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
58548
58549 2003-08-20  Bruno Haible  <bruno@clisp.org>
58550
58551         * modules/progname: New file.
58552         * MODULES.html.sh (func_all_modules): Add progname.
58553
58554 2003-08-20  Bruno Haible  <bruno@clisp.org>
58555
58556         * lib/progname.h: New file, from GNU gettext.
58557         * lib/progname.c: New file, from GNU gettext.
58558         * lib/progreloc.c: New file, from GNU gettext.
58559
58560 2003-08-19  Jim Meyering  <jim@meyering.net>
58561
58562         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
58563         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
58564
58565 2003-08-19  Bruno Haible  <bruno@clisp.org>
58566
58567         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
58568         more.
58569
58570 2003-08-19  Bruno Haible  <bruno@clisp.org>
58571
58572         * lib/xstrdup.c: Assume <string.h> exists.
58573
58574 2003-08-18  Paul Eggert  <eggert@twinsun.com>
58575
58576         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
58577         in makefile rules.
58578
58579 2003-08-18  Jim Meyering  <jim@meyering.net>
58580
58581         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
58582         * m4/lib-ld.m4: Likewise.
58583
58584 2003-08-18  Jim Meyering  <jim@meyering.net>
58585
58586         * lib/setenv.h: Indent nested cpp directive.
58587         * lib/vasnprintf.c: Remove trailing blanks.
58588
58589 2003-08-17  Simon Josefsson  <jas@extundo.com>
58590
58591         * modules/xstrndup: New file.
58592         * MODULES.html.sh (func_all_modules): Add xstrndup.
58593
58594 2003-08-17  Simon Josefsson  <jas@extundo.com>
58595
58596         * modules/argp: Fix autoconf macro name. Add more dependencies.
58597
58598 2003-08-17  Simon Josefsson  <jas@extundo.com>
58599
58600         * m4/xstrndup.m4: New file.
58601
58602 2003-08-17  Simon Josefsson  <jas@extundo.com>
58603
58604         * m4/argp.m4: New file.
58605
58606 2003-08-17  Simon Josefsson  <jas@extundo.com>
58607             Bruno Haible  <bruno@clisp.org>
58608
58609         * lib/xstrndup.h: New file.
58610         * lib/xstrndup.c: New file.
58611
58612 2003-08-17  Bruno Haible  <bruno@clisp.org>
58613
58614         * modules/strndup (Files, Include): Add lib/strndup.h.
58615
58616 2003-08-17  Bruno Haible  <bruno@clisp.org>
58617
58618         * modules/euidaccess (Files): Add lib/euidaccess.h.
58619
58620 2003-08-17  Bruno Haible  <bruno@clisp.org>
58621
58622         * lib/strndup.h: New file.
58623
58624 2003-08-17  Bruno Haible  <bruno@clisp.org>
58625
58626         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
58627         like AC_GNU_SOURCE.
58628         * modules/extensions (configure.ac): Comment out the invocation of
58629         gl_USE_SYSTEM_EXTENSIONS.
58630
58631 2003-08-16  Paul Eggert  <eggert@twinsun.com>
58632
58633         Merges from coreutils, etc.
58634         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
58635         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
58636         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
58637         fixing a typo.
58638         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
58639         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
58640
58641 2003-08-16  Paul Eggert  <eggert@twinsun.com>
58642
58643         Document merge from coreutils.
58644         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
58645         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
58646         * modules/utime: Add m4/utimes-null.m4.
58647
58648 2003-08-16  Paul Eggert  <eggert@twinsun.com>
58649
58650         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
58651         space, undoing this 2003-08-12 change:
58652         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
58653
58654 2003-08-16  Paul Eggert  <eggert@twinsun.com>
58655
58656         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
58657         strtoul.c from libc, undoing this 2003-08-12 change:
58658         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
58659
58660 2003-08-16  Jim Meyering  <jim@meyering.net>
58661
58662         Merges from coreutils.
58663         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
58664         prefix.  Adjust cache variables similarly.  Create 500 rather than
58665         just 300 files, to exercise bug on Darwin6.5, too.
58666         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
58667         $missing_dir.
58668         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
58669         AM_SYS_POSIX_TERMIOS.
58670         Reported by mkc@mathdogs.com.
58671         Also change use of $am_cv_sys_posix_termios
58672         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
58673         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
58674         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
58675         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
58676         in /proc/mounts until it finds one with matching device number.  This
58677         is unnecessary when the FILE argument *is* a mount point.  No stat call
58678         is necessary in that case.  So, disable the statvfs-testing code on
58679         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
58680         as RedHat bug# 84846.
58681         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
58682         to 1MB, so as not to render systems with no stack size limit (e.g.,
58683         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
58684         Include <unistd.h>.  On some systems,
58685         it is required for the definition of _SC_PAGESIZE.
58686
58687 2003-08-16  Jim Meyering  <jim@meyering.net>
58688
58689         Merge from coreutils.
58690         * lib/xstrtoimax.c: #else #if -> #elif.
58691         * lib/xstrtoumax.c: Likewise.
58692
58693 2003-08-16  Jim Meyering  <jim@meyering.net>
58694
58695         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
58696         * m4/utimes.m4: Removed.
58697         * m4/utimes-null.m4: Renamed from utimes.m4.
58698
58699         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
58700         to 1MB, so as not to render systems with no stack size limit (e.g.,
58701         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
58702         Include <unistd.h>.  On some systems,
58703         it is required for the definition of _SC_PAGESIZE.
58704
58705 2003-08-16  Jim Meyering  <jim@meyering.net>
58706         and Paul Eggert  <eggert@cs.ucla.edu>
58707
58708         Merges from coreutils, etc.
58709
58710         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
58711         using the latest version from cvs.  This avoids problems with #line
58712         directives using a vendor (Sun) compiler.
58713         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
58714         Don't set GETGROUPS_LIB here; now it's
58715         done via getgroups.m4's wrapper function.
58716         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
58717         rather than just in sh-util/configure.in, so that the
58718         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
58719         same.
58720         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
58721         AC_FUNC_GETLOADAVG where to find getloadavg.c.
58722         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
58723         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
58724         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
58725         Remove code that is now done by the newly-required macros.
58726         Append $(EXEEXT) to DF_PROG.
58727         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
58728         Do not invoke or require the following here,
58729         since prereq.m4 or some gnulib .m4 now does this for us:
58730         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
58731         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
58732         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
58733         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
58734         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
58735         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
58736         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
58737         AC_FUNC_OBSTACK.
58738         Do not replace the following functions, as this is now the job
58739         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
58740         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
58741         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
58742         atexit getpass, strdup, getpagesize.
58743         Replace 'raise'.
58744         Do not check for the following functions, as this is now the job
58745         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
58746         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
58747         setregid.
58748         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
58749         Check for sys/sysctl.h.
58750         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
58751         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
58752         of checking for ssize_t ourselves.
58753
58754         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
58755         Require every macro that gnulib/modules/* suggests for us.
58756         (jm_PREREQ_ADDEXT): New macro.
58757         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
58758         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
58759
58760         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
58761         (gl_PHYSMEM): Use it.
58762         Also check for `table' function.
58763         Check for new headers and functions.
58764         Add check for sys/sysmp.h.
58765         With suggestions from Kaveh Ghazi.
58766         Ignore headers that are present but cannot be compiled.  This
58767         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
58768         C 5.4.
58769
58770 2003-08-15  Paul Eggert  <eggert@twinsun.com>
58771
58772         Document merge from coreutils.
58773         * modules/userspec: Depend on posixver.
58774         * modules/strftime: Depend on tzset.
58775
58776 2003-08-15  Paul Eggert  <eggert@twinsun.com>
58777
58778         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
58779         rather than tab, after '#' in shell-script copyright notices.
58780         Suggested by Bruno Haible.
58781
58782 2003-08-15  Paul Eggert  <eggert@twinsun.com>
58783
58784         * config/srclist-update: Use three spaces, rather than tab, after '#'
58785         in shell-script copyright notices.  Suggested by Bruno Haible.
58786         Remove unnecessary parenthesization in regular expression.
58787
58788 2003-08-15  Jim Meyering  <jim@meyering.net>
58789
58790         Merge from coreutils.
58791         * lib/xgethostname.c: Include <stdlib.h>.
58792         (xghostname): Don't exit for anything other than memory-related
58793         failure; just return NULL.
58794         * lib/userspec.c: Include "posixver.h".
58795         (parse_user_spec): Accept `.' as a separator only
58796         in pre-POSIX-200112 mode.
58797         * lib/strtoimax.c: Use #elif rather than #else #if.
58798         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
58799         Remove function, now that we can rely on a working tzset function.
58800         [!_LIBC]: Ensure that the required autoconf test has been run.
58801         [!defined _NL_CURRENT && HAVE_STRFTIME]:
58802         Use underlying_strftime for %r.
58803         * lib/sha.c: Merge in some clean-up and optimization changes from
58804         glibc.
58805         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
58806         Ensure that it is a multiple of 64.
58807         Rearrange loop exit tests so as to avoid performing an
58808         additional fread after encountering an error or EOF.
58809         * lib/realloc.c: Update copyright date.
58810
58811 2003-08-15  Jim Meyering  <jim@meyering.net>
58812         and Paul Eggert  <eggert@twinsun.com>
58813
58814         Merge from coreutils.
58815         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
58816         member but strut utmpx does not.  Needed for AIX 4.3.3.
58817         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
58818
58819 2003-08-15  Jim Meyering  <jim@meyering.net>
58820         and Paul Eggert  <eggert@cs.ucla.edu>
58821
58822         Merges from coreutils, etc.
58823         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
58824         Require gl_FUNC_TZSET_CLOBBER.
58825         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
58826         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
58827         members.
58828
58829 2003-08-14  Paul Eggert  <eggert@twinsun.com>
58830
58831         Help the merge from coreutils.
58832         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
58833         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
58834         * m4/tzset.m4: Use it too.
58835
58836 2003-08-14  Paul Eggert  <eggert@twinsun.com>
58837
58838         * modules/tzset: New file.
58839
58840 2003-08-14  Jim Meyering  <jim@meyering.net>
58841
58842         Merges from coreutils.
58843         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
58844         variable names, rather than @FNMATCH_H@.
58845         * modules/alloca: Likewise for $(ALLOCA_H).
58846
58847         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
58848         the three copies of the literal target, `fnmatch.h'.
58849         * modules/alloca (alloca.h): Likewise.
58850
58851 2003-08-14  Jim Meyering  <jim@meyering.net>
58852
58853         Merge from coreutils.
58854         * m4/tzset.m4: New file.
58855         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
58856         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
58857         otherwise, AIX 5.1 systems would end up using the latter.
58858         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
58859         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
58860         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
58861         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
58862
58863 2003-08-14  Jim Meyering  <jim@meyering.net>
58864
58865         Merge from coreutils.
58866         * lib/obstack.h: Whitespace changes.
58867         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
58868         and xcalloc return values.
58869         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
58870         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
58871         hang on OSF/1 5.1 for DIR on both local and remote file systems.
58872         Reported by (and fix confirmed by) Nelson H. F. Beebe.
58873         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
58874         error from mntctl.
58875         Use mntctl's return value to drive the entry-processing loop, since
58876         we can't rely on the value of the vmt_length member in the last
58877         entry.  On some systems doing so could result in exhausting
58878         virtual memory.  Based in part on a patch from Mike Jetzer.
58879
58880 2003-08-14  Jim Meyering  <jim@meyering.net>
58881         and Paul Eggert  <eggert@twinsun.com>
58882
58883         Merges from coreutils, plus other fixes.
58884         * lib/physmem.c: Merge in portability changes from gcc/libiberty
58885         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
58886         for credits and details.  Thanks to Kaveh Ghazi for helping
58887         to keep these files in sync.
58888         (ARRAY_SIZE): Define it.
58889         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
58890         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
58891         (memcasecmp): Don't assume size_t fits in unsigned int.
58892         Remove casts and duplicate code.
58893         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
58894         (memcpy): Remove definition.
58895         Merge in some clean-up and optimization changes from glibc.
58896         [BLOCKSIZE]: Move definition to top of file.
58897         Ensure that it is a multiple of 64.
58898         Rearrange loop exit tests so as to avoid performing an
58899         additional fread after encountering an error or EOF.
58900         * lib/md5.h (md5_uintptr): Define.
58901         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
58902         return to the initial working directory.  Preserve errno
58903         for caller.
58904         * lib/idcache.c: Include "xalloc.h".
58905         (xmalloc, xrealloc): Remove decls.
58906         (getuser): Remove casts no longer required in C89.
58907         * lib/human.c: Include stdio.h, for sprintf.
58908         * lib/group-member.c: Include "xalloc.h".
58909         (xmalloc, xrealloc): Remove decls.
58910         (get_group_info): Remove casts no longer required in C89.
58911         * lib/getusershell.c (readname): Remove casts no longer required in
58912         C89.
58913         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
58914         * lib/getline.c: Whitespace fix, from coreutils.
58915
58916 2003-08-13  Paul Eggert  <eggert@twinsun.com>
58917
58918         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
58919         Check for isascii.
58920
58921         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
58922         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
58923         Undo previous (whitespace-only) change.
58924
58925 2003-08-13  Paul Eggert  <eggert@twinsun.com>
58926
58927         * lib/exclude.c: Include <ctype.h>
58928         (IN_CTYPE_DOMAIN): New macro.
58929         (is_space): New fn.
58930         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
58931         and empty lines.
58932
58933         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
58934         Undo previous (whitespace-only) change.
58935
58936 2003-08-13  Paul Eggert  <eggert@twinsun.com>
58937
58938         * config/srclist-update: Change update back to the old behavior,
58939         leaving whitespace alone.  Use one 'sed' command rather than a
58940         pipeline.
58941         (fixlicense): Now a variable, not a function.
58942         (remove_trailing_blanks): Remove.
58943         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
58944         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
58945         Undo previous (whitespace-only) change.
58946
58947 2003-08-12  Paul Eggert  <eggert@twinsun.com>
58948
58949         Merge from coreutils.
58950         * modules/euidaccess: Add lib_SOURCES, include for new
58951         file euidaccess.h
58952
58953 2003-08-12  Paul Eggert  <eggert@twinsun.com>
58954
58955         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
58956         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
58957         Normalize leading white space and remove trailing white space.
58958
58959         Merge from coreutils
58960         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
58961
58962         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
58963         0.12.1.  These files are now being upgraded automatically by
58964         ../config/srclist-update.
58965
58966 2003-08-12  Paul Eggert  <eggert@twinsun.com>
58967
58968         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
58969         Normalize leading white space and remove trailing white space.
58970         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
58971         notice, as per ../config/srclist-update.
58972
58973         Merge from coreutils.
58974         * lib/euidaccess.h: New file.
58975         * lib/euidaccess.c: Include it.
58976         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
58977         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
58978         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
58979
58980 2003-08-12  Paul Eggert  <eggert@twinsun.com>
58981
58982         * config/srclist-update: Add copyright notice.
58983         (remove_id_lines, remove_trailing_blanks): New constants.
58984         (fixfile): Use them to normalize spacing a bit in copied files.
58985         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
58986         Normalize leading white space and remove trailing white space.
58987
58988         * config/texinfo.tex: Sync with texinfo.
58989
58990         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
58991         strtoul.c from libc, to merge coreutils whitespace changes.
58992
58993         * config/srclist.txt: Get the following m4 files from gettext:
58994         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
58995         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
58996         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
58997         wint_t.m4.
58998
58999 2003-08-12  Karl Berry  <karl@gnu.org>
59000
59001         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
59002         been made.
59003
59004 2003-08-11  Paul Eggert  <eggert@twinsun.com>
59005
59006         * modules/gnu-source, m4/gnu-source.m4:
59007         Remove; we're assuming Autoconf 2.54 or later now.
59008         Suggested by Bruno Haible.
59009         * MODULES.html.sh (func_all_modules): Remove gnu-source.
59010
59011 2003-08-11  Bruno Haible  <bruno@clisp.org>
59012
59013         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
59014
59015 2003-08-11  Bruno Haible  <bruno@clisp.org>
59016
59017         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
59018         (vasnprintf): Use it instead of wcslen.
59019
59020 2003-08-11  Bruno Haible  <bruno@clisp.org>
59021
59022         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
59023         value to ensure that _Bool promotes to int. Use #define for _Bool when
59024         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
59025
59026 2003-08-10  Karl Berry  <karl@gnu.org>
59027
59028         * lib/regex.h: update from libc (whitespace fix).
59029
59030 2003-08-09  Paul Eggert  <eggert@twinsun.com>
59031
59032         Merge some files from coreutils.  These changes were
59033         originally made by Jim Meyering.
59034         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
59035         many older Unixes require this.
59036         * lib/alloca.c (alloca): Remove cast to argument of free;
59037         no longer needed in C89.
59038         * lib/alloca_.h, regex.h: Fix white space to match
59039         what GNU indent does.
59040
59041 2003-08-09  Paul Eggert  <eggert@twinsun.com>
59042
59043         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
59044         apparently Emacs's Unicode mode got confused before my 2003-08-05
59045         checkin.
59046
59047 2003-08-08  Paul Eggert  <eggert@twinsun.com>
59048
59049         * m4/extensions.m4: New file.
59050         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
59051         Require gl_USE_SYSTEM_EXTENSIONS.
59052         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
59053         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
59054
59055 2003-08-08  Paul Eggert  <eggert@twinsun.com>
59056
59057         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
59058         * modules/extensions, modules/gnu-source: New files.
59059         * modules/timespec, modules/unlocked-io: Depend on extensions.
59060
59061 2003-08-07  Paul Eggert  <eggert@twinsun.com>
59062
59063         * modules/restrict: New file.
59064         * MODULES.html.sh (func_all_modules): Add restrict.
59065         * modules/regex: Depend on restrict.
59066
59067 2003-08-07  Paul Eggert  <eggert@twinsun.com>
59068
59069         * m4/restrict.m4: New file.
59070         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
59071
59072 2003-08-07  Bruno Haible  <bruno@clisp.org>
59073
59074         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
59075         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
59076
59077 2003-08-07  Bruno Haible  <bruno@clisp.org>
59078
59079         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
59080         makes the module 'getndelim2' compatible with the module 'getline'.
59081
59082 2003-08-05  Paul Eggert  <eggert@twinsun.com>
59083
59084         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
59085         byte with "\201" to avoid glitches when editing that source file
59086         with multi-gnome-terminal.
59087
59088 2003-08-05  Paul Eggert  <eggert@twinsun.com>
59089
59090         * lib/bumpalloc.h: Remove.
59091
59092 2003-08-05  Paul Eggert  <eggert@twinsun.com>
59093
59094         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
59095         * modules/bumpalloc: Remove.
59096
59097 2003-08-04  Paul Eggert  <eggert@twinsun.com>
59098
59099         * lib/getloadavg.c: Change copyright notice and spacing to conform to
59100         GNU coding style.
59101
59102         Merge from coreutils.
59103         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
59104         1. From glibc.
59105         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
59106         from Karl Berry, implemented by Jim Meyering.
59107         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
59108         from Dmitry V. Levin.
59109         Remove anachronistic cast of xrealloc.
59110         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
59111         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
59112         type. Otherwise, it wouldn't compile with at least /bin/cc on
59113         ymp-cray-unicos9.0.2.X.
59114         Combine two mostly-identical uses of alloca into one.
59115         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
59116
59117 2003-08-04  Dave Love  <d.love@dl.ac.uk>
59118
59119         [From Emacs.]
59120
59121         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
59122         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
59123         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
59124         obsolete NLIST_NAME_UNION.
59125         [__GNU__]: Undef BSD and FSCALE.
59126         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
59127
59128 2003-08-03  Paul Eggert  <eggert@twinsun.com>
59129
59130         * lib/stdbool_.h (_Bool): Make it signed char, instead of
59131         an enum type, so that it's guaranteed to promote to int.  See:
59132         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
59133
59134 2003-08-03  Karl Berry  <karl@gnu.org>
59135
59136         * config/depcomp: update from automake.
59137
59138 2003-07-31  Paul Eggert  <eggert@twinsun.com>
59139
59140         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
59141         (strerror): Don't assume that a printable int fits in 14 bytes.
59142
59143 2003-07-31  Bruno Haible  <bruno@clisp.org>
59144
59145         * modules/getpass-gnu: New file.
59146         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
59147
59148 2003-07-31  Bruno Haible  <bruno@clisp.org>
59149
59150         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
59151
59152 2003-07-24  Karl Berry  <karl@gnu.org>
59153
59154         * config/missing: update from automake.
59155
59156 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
59157             Bruno Haible  <bruno@clisp.org>
59158
59159         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
59160         * lib/getline.c (getline, getdelim): Likewise.
59161         Remove _GNU_SOURCE define; now it's defined in config.h through
59162         m4/getline.m4.
59163
59164 2003-07-23  Karl Berry  <karl@gnu.org>
59165
59166         * config/config.sub: update from prep.
59167
59168 2003-07-22  Paul Eggert  <eggert@twinsun.com>
59169
59170         * modules/xalloc (Depends-on): Add exitfail.
59171         * modules/xmemcoll: Likewise.
59172
59173 2003-07-22  Paul Eggert  <eggert@twinsun.com>
59174
59175         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
59176         over-parenthesization in macros.
59177
59178         Sync with coreutils.
59179
59180         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
59181         required by C99.
59182
59183         Use `exit_failure' for xalloc and xmemcoll instead of their own
59184         private exit-failure variables.
59185         * lib/xalloc.h (xalloc_exit_failure): Remove.
59186         * lib/xmalloc.c: Likewise.  Include exitfail.h.
59187         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
59188         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
59189         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
59190         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
59191
59192 2003-07-20  Jim Meyering  <jim@meyering.net>
59193
59194         * modules/closeout (Depends-on): Add exitfail.
59195         Suggestion from Bruno Haible.
59196
59197 2003-07-19  Karl Berry  <karl@gnu.org>
59198
59199         * config/config.sub: update from prep.
59200
59201 2003-07-18  Paul Eggert  <eggert@twinsun.com>
59202
59203         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
59204         Remove.
59205         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
59206         to test that it can stand by itself.  Include "exitfail.h".
59207         Clients should set exit_failure instead.
59208         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
59209
59210 2003-07-18  Bruno Haible  <bruno@clisp.org>
59211
59212         * modules/getndelim2: New file.
59213         * modules/getline: Share files with module getndelim2.
59214         * modules/getnline: Depend on getndelim2 instead of sharing files with
59215         it. Add getnline.c to lib_SOURCES.
59216         * MODULES.html.sh (func_all_modules): Add getndelim2.
59217
59218 2003-07-18  Bruno Haible  <bruno@clisp.org>
59219
59220         * m4/getndelim2.m4: New file.
59221         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
59222         invoke gl_PREREQ_GETNDELIM2.
59223         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
59224         gl_PREREQ_GETNDELIM2.
59225         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
59226         gl_GETNDELIM2.
59227
59228 2003-07-18  Bruno Haible  <bruno@clisp.org>
59229
59230         * lib/getndelim2.h: New file.
59231         * lib/getndelim2.c: Make into a module of its own. Include config.h,
59232         getndelim2.h.
59233         (getndelim2): Make non-static. Change return type to ssize_t.
59234         * lib/getline.h: Change argument names.
59235         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
59236         * lib/getnline.c: Include getndelim2.h.
59237
59238 2003-07-18  Andreas Schwab  <schwab@suse.de>
59239
59240         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
59241
59242 2003-07-17  Karl Berry  <karl@gnu.org>
59243
59244         * config/config.sub: update from prep.
59245
59246 2003-07-17  Bruno Haible  <bruno@clisp.org>
59247
59248         * modules/getnline: New file.
59249         * modules/getline: Add lib/getndelim2.c to source file list.
59250         * MODULES.html.sh (func_all_modules): Add getnline.
59251
59252 2003-07-17  Bruno Haible  <bruno@clisp.org>
59253
59254         * m4/getnline.m4: New file.
59255
59256 2003-07-17  Bruno Haible  <bruno@clisp.org>
59257
59258         * m4/Makefile.am.in: Remove file.
59259         * m4/Makefile.am: Remove file.
59260         * m4/Makefile.in: Remove file.
59261
59262 2003-07-17  Bruno Haible  <bruno@clisp.org>
59263
59264         * lib/getnline.h: New file.
59265         * lib/getnline.c: New file.
59266         * lib/getndelim2.c: New file, extracted from getline.c.
59267         (getndelim2): Renamed from getdelim2, with added nmax argument.
59268         * lib/getline.c: Include getndelim2.c.
59269         (getdelim2): Moved out to getndelim2.c.
59270         (getline, getdelim): Update.
59271
59272 2003-07-17  Bruno Haible  <bruno@clisp.org>
59273
59274         * lib/Makefile.am: Remove file.
59275         * lib/Makefile.in: Remove file.
59276
59277 2003-07-17  Bruno Haible  <bruno@clisp.org>
59278
59279         * configure.in: Remove file.
59280         * Makefile.in: Remove file.
59281
59282 2003-07-17  Bruno Haible  <bruno@clisp.org>
59283
59284         * MODULES.html.sh: Put the </BODY> right before </HTML>.
59285
59286 2003-07-16  Karl Berry  <karl@gnu.org>
59287
59288         * config/srclist-update: was running fixlicense twice, which caused
59289                 texinfo.tex to be nullified for some reason.  Simplify,
59290                 $gplsrc is no longer needed as far as I can see?
59291
59292 2003-07-16  Jim Meyering  <jim@meyering.net>
59293
59294         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
59295
59296 2003-07-15  Paul Eggert  <eggert@twinsun.com>
59297
59298         * config/srclist.txt: Get the following files from gettext-runtime/intl
59299         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
59300         ref-del.sin.  From Bruno Haible.
59301         * config/srclist-update (fixfile): Change grep pattern again, since the
59302         previous fix didn't work (there was another trailing $).  Use
59303         '[$]' to escape the $s.
59304
59305 2003-07-15  Karl Berry  <karl@gnu.org>
59306
59307         * lib/vasnprintf.c: update from gettext.
59308
59309 2003-07-15  Karl Berry  <karl@gnu.org>
59310
59311         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
59312         gets expanded when surrounded by '$'.
59313
59314 2003-07-15  Jim Meyering  <jim@meyering.net>
59315
59316         * modules/save-cwd: Don't depend on error.  From Derek Price.
59317
59318 2003-07-15  Jim Meyering  <jim@meyering.net>
59319
59320         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
59321
59322 2003-07-14  Simon Josefsson  <jas@extundo.com>
59323
59324         * modules/mempcpy: New file.
59325         * MODULES.html.sh (func_all_modules): Add mempcpy.
59326
59327 2003-07-14  Simon Josefsson  <jas@extundo.com>
59328
59329         * m4/mempcpy.m4: New file.
59330
59331 2003-07-14  Simon Josefsson  <jas@extundo.com>
59332
59333         * lib/mempcpy.h: New file.
59334         * lib/mempcpy.c: New file.
59335
59336 2003-07-14  Paul Eggert  <eggert@twinsun.com>
59337
59338         * modules/getdate, modules/posixtm: Depend on mktime.
59339
59340 2003-07-14  Paul Eggert  <eggert@twinsun.com>
59341
59342         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
59343         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
59344         unicodeio.c, unicodeio.h, unlocked-io.h:
59345         Switch from LGPL to GPL.
59346
59347 2003-07-14  Paul Eggert  <eggert@twinsun.com>
59348
59349         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
59350         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
59351         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
59352         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
59353         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
59354         updated automatically by ../config/srclist-update.  This changes
59355         their license from LPGL to GPL.
59356
59357 2003-07-14  Paul Eggert  <eggert@twinsun.com>
59358
59359         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
59360         assumed to refer to the root of the most recent stable gettext version.
59361         * config/srclistvars.sh: Add defaults for eggert.
59362         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
59363         Match "This program" as well as "The program".  This is needed
59364         for gettext.
59365
59366 2003-07-14  Jim Meyering  <jim@meyering.net>
59367
59368         Don't emit diagnostics.  Let callers do that.
59369         * lib/save-cwd.c: Don't include "error.h".
59370         (save_cwd): Don't call error.  Ensure that errno is valid
59371         when returning nonzero.
59372
59373         * lib/save-cwd.h (restore_cwd): Update prototype.
59374         * lib/save-cwd.c (restore_cwd): Remove two parameters.
59375         Simplify.  Don't call error upon failure.  Let callers do that.
59376         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
59377         when auditing is enabled.  But don't bother updating the #if.
59378
59379 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
59380
59381         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
59382         it breaks C++ compilation.
59383         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
59384
59385 2003-07-10  Simon Josefsson  <jas@extundo.com>
59386
59387         * modules/strchrnul (Makefile.am): Add strchrnul.h.
59388
59389 2003-07-10  Jim Meyering  <jim@meyering.net>
59390
59391         * m4/clock_time.m4: Remove trailing blank.
59392         * m4/intmax_t.m4: Likewise.
59393
59394 2003-07-10  Jim Meyering  <jim@meyering.net>
59395
59396         * lib/vasnprintf.c: Remove trailing blanks.
59397         Make cpp indentation consistent.
59398
59399 2003-07-09  Paul Eggert  <eggert@twinsun.com>
59400
59401         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
59402         posixver.c, strftime.c, strnlen.c, strverscmp.c:
59403         Switch from LGPL to GPL.
59404
59405 2003-07-09  Paul Eggert  <eggert@twinsun.com>
59406
59407         * config/srclist.txt: Sort sublists.  Add
59408         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
59409         that differ from gnulib for one reason or another; we'd like this list
59410         to be smaller but for now let's document what we have.
59411
59412 2003-07-08  Paul Eggert  <eggert@twinsun.com>
59413
59414         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
59415         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
59416         and sweeter "eval x=$x".
59417         * config/srclist.txt: Get lib/argp* from glibc.
59418
59419 2003-07-07  Paul Eggert  <eggert@twinsun.com>
59420
59421         * lib/mktime.c: Fix some boundary cases and remove need for floating
59422         point.
59423
59424         Issue a compile-time diagnostic if time_t is floating point, or if
59425         two's complement arithmetic is not in effect, or if arithmetic
59426         right shift does not propagate the sign.  These assumptions were
59427         all in the original code but they weren't checked.
59428
59429         (TIME_T_MIDPOINT, verify): New macros.
59430         (__isleap): Remove; it has integer overflow problems.
59431         (leapyear): New function, without those problems.
59432         (ydhms_tm_diff): Remove; splitting into two parts.
59433         (ydhms_diff): New function, containing the arithmetic part of
59434         the old ydhms_tm_diff function.  Issue a compile-time
59435         diagnostic if we are not using C99 integer division.
59436         Avoid casts when possible.
59437         (guess_time_tm): New function, containing the checking part of
59438         the old ydhms_tm_diff function.  Return the new value, rather than
59439         the difference between it and the old.  Accept a new argument T
59440         so that *T specifies the old value.  Check for overflow in the result.
59441
59442         (__mktime_internal): Use a time_t offset, not a long int offset.
59443         This undoes the 2003-06-04 change, which is no longer needed now
59444         that we have better overflow checking.
59445         (localtime_offset): Likewise.
59446
59447         (__mktime_internal): Avoid harmful overflow on hosts where time_t
59448         and long are 64-bit but int is only 32-bit.
59449         (ydhms_diff): Use long int to store year1 and yday1.
59450         Issue a compile-time diagnostic if long int is not wide enough.
59451
59452         (__mktime_internal): Use long int to store adjusted year and yday.
59453         Use plain C rather than preprocessor commands, if that doesn't
59454         affect efficiency.
59455         Check for overflow (and try to repair) after each probe
59456         rather than checking only at the very end.  This avoids some bugs
59457         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
59458         does not equal GMT offset at maximum time).
59459         Use integer to check for overflow rather than floating point; this
59460         is more portable to non-IEEE hosts, and is a tad faster.
59461         When we detect that we are oscillating between two values,
59462         don't check whether tm_isdst has the requested value, since
59463         we already know the answer.  When tm_isdst has the wrong value,
59464         use a different heuristic to find the right one, based on the
59465         extreme values actually observed in practice in tz2003a,
59466         rather than the (overly optimistic) "previous 3 calendar quarters".
59467
59468         (not_equal_tm, print_tm, check_result): Use "const T" rather than
59469         "T const" to accommodate glibc style.
59470         (check_result): Use less-confusing report format.  "long" -> "long int.
59471         (main): Likewise.
59472         Don't loop if the iteration overflows time_t.
59473         Allow a negative step in the iteration.
59474
59475 2003-07-06  Karl Berry  <karl@gnu.org>
59476
59477         * config/depcomp: update from automake.
59478         * config/config.sub: update from prep.
59479
59480 2003-07-03  Karl Berry  <karl@gnu.org>
59481
59482         * config/config.guess: update from prep.
59483
59484 2003-07-01  Paul Eggert  <eggert@twinsun.com>
59485
59486         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
59487         xreadlink.c now includes it unconditionally.
59488
59489 2003-07-01  Paul Eggert  <eggert@twinsun.com>
59490
59491         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
59492         having it depend on HAVE_SYS_TYPES_H.
59493
59494 2003-07-01  Bruno Haible  <bruno@clisp.org>
59495
59496         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
59497         <sys/types.h> should be sufficient.
59498         Reported by Paul Eggert.
59499
59500 2003-06-26  Karl Berry  <karl@gnu.org>
59501
59502         * config/depcomp: update from automake.
59503
59504 2003-06-26  Bruno Haible  <bruno@clisp.org>
59505
59506         * modules/human: Depend on module stdbool.
59507
59508 2003-06-25  Bruno Haible  <bruno@clisp.org>
59509
59510         * modules/readlink: New file.
59511         * modules/xreadlink: Depend on it.
59512         * MODULES.html.sh (func_all_modules): Add readlink.
59513
59514 2003-06-25  Bruno Haible  <bruno@clisp.org>
59515
59516         * m4/readlink.m4: New file.
59517
59518 2003-06-25  Bruno Haible  <bruno@clisp.org>
59519
59520         * lib/readlink.c: New file.
59521
59522 2003-06-22  Karl Berry  <karl@gnu.org>
59523
59524         * config/srclist.txt: update mkinstalldirs from automake.
59525         * config/mkinstalldirs: update.
59526
59527 2003-06-22  Bruno Haible  <bruno@clisp.org>
59528
59529         Portability to mingw32.
59530         * m4/ssize_t.m4: New file, from GNU gettext.
59531         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
59532         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
59533
59534 2003-06-22  Bruno Haible  <bruno@clisp.org>
59535
59536         * modules/safe-read: Add m4/ssize_t.m4.
59537         * modules/xreadlink: Add m4/ssize_t.m4.
59538
59539 2003-06-20  Bruno Haible  <bruno@clisp.org>
59540
59541         Assume C89, so PARAMS isn't needed.
59542         * lib/unicodeio.h (PARAMS): Remove.
59543         * lib/unicodeio.c: Don't use PARAMS.
59544
59545 2003-06-18  Karl Berry  <karl@gnu.org>
59546
59547         * config/config.{guess,sub}: update from prep.
59548
59549 2003-06-18  Jim Meyering  <jim@meyering.net>
59550
59551         Merge changes from coreutils.
59552         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
59553         Remove explicit declarations of xmalloc and realloc.
59554         Include xalloc.h.
59555         (read_utmp): Remove anachronistic cast of xmalloc.
59556
59557 2003-06-17  Paul Eggert  <eggert@twinsun.com>
59558
59559         Assume C89, so PARAMS isn't needed.
59560         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
59561         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
59562         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
59563         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
59564         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
59565         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
59566         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
59567         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
59568         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
59569         lib/xstrtod.h, lib/xstrtol.h: Likewise.
59570         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
59571         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
59572         no longer needed. Anyway, config.h should always be included before any
59573         other file.
59574
59575 2003-06-11  Simon Josefsson  <jas@extundo.com>
59576
59577         * modules/sysexits: New file.
59578         * MODULES.html.sh (func_all_modules): Add sysexits.
59579
59580 2003-06-11  Simon Josefsson  <jas@extundo.com>
59581
59582         * lib/sysexit_.h: New file.
59583
59584 2003-06-11  Derek Price  <derek@ximbiot.com>
59585
59586         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
59587         necessary.
59588
59589 2003-06-11  Bruno Haible  <bruno@clisp.org>
59590
59591         * m4/sysexits.m4: New file.
59592
59593 2003-06-10  Simon Josefsson  <jas@extundo.com>
59594
59595         * lib/argp.h: New file, from glibc.
59596         * lib/argp-ba.c: New file, from glibc.
59597         * lib/argp-eexst.c: New file, from glibc.
59598         * lib/argp-fmtstream.c: New file, from glibc.
59599         * lib/argp-fmtstream.h: New file, from glibc.
59600         * lib/argp-fs-xinl.c: New file, from glibc.
59601         * lib/argp-help.c: New file, from glibc.
59602         * lib/argp-namefrob.h: New file, from glibc.
59603         * lib/argp-parse.c: New file, from glibc.
59604         * lib/argp-pv.c: New file, from glibc.
59605         * lib/argp-pvh.c: New file, from glibc.
59606         * lib/argp-xinl.c: New file, from glibc.
59607
59608 2003-06-10  Simon Josefsson  <jas@extundo.com>
59609
59610         * modules/strchrnul: New file.
59611
59612 2003-06-10  Simon Josefsson  <jas@extundo.com>
59613
59614         * modules/argp: New file.
59615
59616 2003-06-10  Simon Josefsson  <jas@extundo.com>
59617
59618         * m4/strchrnul.m4: New file.
59619
59620 2003-06-10  Simon Josefsson  <jas@extundo.com>
59621
59622         * lib/strchrnul.h: New file.
59623         * lib/strchrnul.c: New file.
59624
59625 2003-06-10  Bruno Haible  <bruno@clisp.org>
59626
59627         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
59628
59629 2003-06-07  Karl Berry  <karl@gnu.org>
59630
59631         * config/config.{guess,sub}: update from prep.
59632
59633 2003-06-07  Jim Meyering  <jim@meyering.net>
59634
59635         * modules/strtod: Use $(...) notation, not @...@ for
59636         AC_REPLACE'd variables.
59637         * modules/localcharset: Likewise.
59638
59639 2003-06-07  Jim Meyering  <jim@meyering.net>
59640
59641         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
59642         in place of my name in the copyright comment.
59643         Remove definition and uses of __P.
59644
59645         From coreutils.
59646         * lib/stat.c: Don't declare xmalloc explicitly.
59647         Instead, include "xalloc.h".
59648         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
59649         xrealloc, and xcalloc return values.
59650         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
59651         Improve comment.
59652         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
59653
59654 2003-06-07  Bruno Haible  <bruno@clisp.org>
59655
59656         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
59657         avoid AC_CONFIG_LINKS.
59658         * modules/fnmatch (Makefile.am): Use explicit creation rule for
59659         fnmatch.h, to avoid AC_CONFIG_LINKS.
59660         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
59661
59662 2003-06-07  Bruno Haible  <bruno@clisp.org>
59663
59664         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
59665         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
59666         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
59667         directory.
59668         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
59669         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
59670         directory.
59671
59672 2003-06-06  Jim Meyering  <jim@meyering.net>
59673
59674         Merge from coreutils.
59675         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
59676         Consolidate declarations and initializations of *_base* locals.
59677
59678         Merge from coreutils.
59679         This avoids a core dump on systems without GNU putenv,
59680         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
59681         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
59682         (unsetenv): New static function, from GNU libc.
59683         (rpl_putenv): Use it.
59684
59685         * lib/modechange.c: Remove trailing blanks.
59686
59687         Merge from coreutils.
59688         * lib/fsusage.c: Remove declaration of statfs.
59689         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
59690
59691         * lib/posixtm.c: Include <stdbool.h> unconditionally.
59692
59693 2003-06-06  Jim Meyering  <jim@meyering.net>
59694
59695         * lib/stdbool_.h: Renamed from stdbool.h.in.
59696
59697 2003-06-06  Jim Meyering  <jim@meyering.net>
59698             Bruno Haible  <bruno@clisp.org>
59699
59700         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
59701         Adjust Makefile.am snippet not to redirect directly to target.
59702         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
59703
59704 2003-06-05  Paul Eggert  <eggert@twinsun.com>
59705
59706         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
59707         mismatch, look in future quarters as well as past.  This fixes a
59708         bug when processing fall-backwards gaps immediately after a long
59709         period of daylight-saving time.
59710
59711         * lib/mktime.c: Assume freestanding C89 or better.
59712         (HAVE_LIMITS_H): Remove.  Assume it's 1.
59713         (__P): Remove; not used.
59714         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
59715         (mktime, not_equal_tm, print_tm, check_result,
59716         main): Use prototypes.  Use const * where appropriate.
59717         (main): Fix typo in testing code that uncovered by above changes.
59718         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
59719
59720 2003-06-04  Paul Eggert  <eggert@twinsun.com>
59721
59722         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
59723         locale.h, localeconv.  This merges changes from coreutils.
59724
59725         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
59726         It can be removed after the next Autoconf is released.
59727         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
59728         needed.
59729
59730 2003-06-04  Paul Eggert  <eggert@twinsun.com>
59731
59732         * lib/mktime.c: Fix Debian bug 177940
59733         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
59734         (localtime_offset): Now long int, not time_t, because we want it
59735         to be guaranteed to be signed.  All uses changed.
59736         (__mktime_internal): If overflow would occur when adding offset,
59737         don't add it.
59738
59739         Merge 'human' changes from coreutils.  Rewrite to support
59740         locale-specific notations like thousands separators.
59741         * lib/human.c: Simplify authorship notice.
59742         Include human.h immediately after config.h.
59743         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
59744         <limits.h>: Do not include, since human.h does.
59745         (SIZE_MAX, UINTMAX_MAX): New macros.
59746         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
59747         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
59748         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
59749         (power_letter): Renamed from suffixes.
59750         (generate_suffix_backwards): Remove.
59751         (adjust_value): Now takes int style (because of human.h changes)
59752         and long double value (for greater precision on some platforms).
59753         (group_number): New function.
59754         (human_readable): Use it.  Use integer options, not enum.
59755         Put the options before the sizes in the arg list.
59756         Support all the new options.
59757         The old human_readable function has been removed;
59758         use inttostr.h instead.
59759         (human_readable, default_block_size, humblock):
59760         Use uintmax_t, not int, for block sizes.
59761         (human_readable_inexact, block_size_types): Remove.
59762         (block_size_opts): New constant.
59763         (human_options): Renamed from human_block_size, with new signature
59764         that allows block sizes up to UINTMAX_MAX.  All callers changed.
59765         * lib/human.h: Add copyright and authorship notice.
59766         Include <limits.h> and <stdbool.h> unconditionally.
59767         (PARAMS): Remove.  All uses removed.
59768         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
59769         (enum human_inexact_style): Remove tag; now a nameless enum.
59770         (human_floor, human_ceiling, human_round_to_even): Now have
59771         values 2, 0, 1 rather than -1, 1, 0.
59772         (human_group_digits, human_suppress_point_zero, human_autoscale,
59773         human_base_1024, human_SI, human_B): New constants.
59774         (human_readable_inexact, human_block_size): Remove.
59775         (human_readable): Size args are now uintmax_t, not int.
59776         (human_options): New decl.
59777
59778         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
59779         unnecessary now that we assume C89 or better.  This change
59780         imported from coreutils.
59781
59782         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
59783         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
59784         in the 2003-05-30 sync from glibc.
59785
59786         .h files should stand alone, but we shouldn't include <sys/types.h>
59787         if we can get away with just <stddef.h>.
59788
59789         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
59790         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
59791         rather than <sys/types.h>, as we merely need size_t.
59792         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
59793         to get size_t.
59794         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
59795         Include <stdio.h>, to get FILE.
59796         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
59797         memcasecmp.h has included <stddef.h> and all we need is size_t.
59798         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
59799         our interface, instead of including <sys/types.h>
59800
59801 2003-06-04  Paul Eggert  <eggert@twinsun.com>
59802
59803         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
59804         now, as glibc mktime is buggy on non-glibc systems.
59805
59806 2003-06-03  Karl Berry  <karl@gnu.org>
59807
59808         * config/config.sub: update from prep.
59809
59810 2003-06-02  Paul Eggert  <eggert@twinsun.com>
59811
59812         [from coreutils]
59813         Fix some minor time-related bugs with POSIX time arguments.
59814         Some valid time stamps were being rejected (notably -1, and
59815         time stamps before 1900 on 64-bit hosts).  And some invalid
59816         time stamps were being accepted, e.g. September 31.
59817
59818         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
59819         that we can return (time_t) -1 successfully.
59820         * lib/posixtm.c: Likewise.
59821         [HAVE_STDBOOL_H]: Include <stdbool.h>.
59822         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
59823         (t): Remove static var.
59824         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
59825         of static var.  All uses changed.
59826         (year): Do not reject years before 1900; they can occur with
59827         64-bit time_t.
59828         (posix_time_parse): Do not check for out-of-range components;
59829         that is now the caller's responsibility, since our checks were
59830         only approximations.
59831         (posixtime): Use mktime to check for out-of-range components,
59832         since it knows them exactly.
59833         If mktime returns (time_t) -1, check whether an error actually occurred
59834         by invoking localtime on -1.
59835         (main) [TEST_POSIXTIME]: Check for input data errors, and report
59836         posixtime failures better.
59837         Improve the test data (in comments only).
59838
59839 2003-06-02  Karl Berry  <karl@gnu.org>
59840
59841         * config/mkinstalldirs (version): new variable.
59842         (--version): new option.
59843         (usage): improve message.
59844
59845 2003-05-30  Karl Berry  <karl@gnu.org>
59846
59847         * lib/mktime.c: update from libc.
59848
59849 2003-05-30  Bruno Haible  <bruno@clisp.org>
59850
59851         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
59852         * config/config.rpath: Upgrade to gettext-0.12.1.
59853
59854 2003-05-30  Bruno Haible  <bruno@clisp.org>
59855
59856         * m4/gettext.m4: Upgrade to gettext-0.12.1.
59857         * m4/nls.m4: New file, from gettext-0.12.1.
59858         * m4/po.m4: New file, from gettext-0.12.1.
59859         * m4/progtest.m4: Upgrade to gettext-0.12.1.
59860
59861 2003-05-30  Bruno Haible  <bruno@clisp.org>
59862
59863         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
59864         * lib/localcharset.h: Likewise.
59865         * lib/localcharset.c: Likewise.
59866
59867 2003-05-29  Karl Berry  <karl@gnu.org>
59868
59869         * config/config.rpath: update from gettext.
59870
59871 2003-05-28  Paul Eggert  <eggert@twinsun.com>
59872
59873         Assume the headers required for C89 freestanding compilers.
59874         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
59875         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
59876         * m4/human.m4 (gl_HUMAN): Likewise.
59877         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
59878         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
59879         * m4/userspec.m4 (gl_USERSPEC): Likewise.
59880         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
59881         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
59882         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
59883
59884 2003-05-28  Paul Eggert  <eggert@twinsun.com>
59885
59886         Assume the headers required for C89 freestanding compilers.
59887         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
59888         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
59889         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
59890         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
59891         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
59892         define, since <limits.h> is guaranteed to do that.
59893         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
59894         * lib/exclude.c: Include <stdbool.h> unconditionally.
59895         * lib/tempname.c: Include <stddef.h> unconditionally.
59896         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
59897         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
59898         <stddef.h> does that.
59899         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
59900         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
59901         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
59902         needed.
59903         * lib/xstrtol.c: Likewise.
59904         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
59905         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
59906
59907         * lib/addext.c (addext): Use assignment rather than cast, to avoid
59908         warnings on some platforms.
59909
59910         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
59911         arbitrarily.
59912
59913 2003-05-26  Jim Meyering  <jim@meyering.net>
59914
59915         Merge in a change from coreutils:
59916         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
59917         that is guaranteed to be `no'.  Use `no_such_member' to indicate
59918         that condition, rather than `-1' which is slightly misleading.
59919         Change the name of the cache variable to have the gl_ prefix.
59920         Prompted by a patch from Richard Dawe for DJGPP.
59921
59922 2003-05-24  Karl Berry  <karl@gnu.org>
59923
59924         * config/config.guess: update from prep.
59925
59926 2003-05-22  Karl Berry  <karl@gnu.org>
59927
59928         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
59929
59930 2003-05-20  Karl Berry  <karl@gnu.org>
59931
59932         * config/config.guess: update from prep.
59933
59934 2003-05-18  Karl Berry  <karl@gnu.org>
59935
59936         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
59937         might actually be set by the user.
59938
59939         * config/depcomp, install-sh, mdate-sh: update from automake.
59940
59941 2003-05-17  Bruno Haible  <bruno@clisp.org>
59942
59943         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
59944         invalid expansion for AC_EGREP_CPP.
59945         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
59946         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
59947         Suggested by Akim Demaille <akim@epita.fr> in
59948         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
59949
59950 2003-05-12  Jim Meyering  <jim@meyering.net>
59951
59952         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
59953         the space-padded-by-default conversion specifiers, %e, %k, %l.
59954
59955 2003-05-12  Bruno Haible  <bruno@clisp.org>
59956
59957         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
59958         the string is longer than 4 KB.
59959
59960 2003-05-11  Karl Berry  <karl@gnu.org>
59961
59962         * config/config.{guess,sub}: update from prep.
59963
59964 2003-05-09  Bruno Haible  <bruno@clisp.org>
59965
59966         * modules/error: Add m4/strerror_r.m4 to file list.
59967
59968 2003-05-03  Bruno Haible  <bruno@clisp.org>
59969
59970         Upgrade to Unicode-4.0.
59971         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
59972         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
59973         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
59974         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
59975         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
59976         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
59977         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
59978         Change width of U+E0100..U+E01EF from 1 to 0.
59979
59980 2003-04-25  Jim Meyering  <jim@meyering.net>
59981
59982         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
59983         of type size_t, not int.
59984
59985 2003-04-25  Bruno Haible  <bruno@clisp.org>
59986
59987         * lib/copy-file.c: Include <stddef.h>, for size_t.
59988
59989 2003-04-21  Paul Eggert  <eggert@twinsun.com>
59990
59991         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
59992         code which expansion is under static control.  Patch imported from
59993         Akim Demaille's patch to Bison; see
59994         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
59995
59996 2003-04-14  Bruno Haible  <bruno@clisp.org>
59997
59998         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
59999
60000 2003-04-11  Jim Meyering  <jim@meyering.net>
60001
60002         Merge changes from Coreutils.
60003
60004         2003-03-22  Jim Meyering  <jim@meyering.net>
60005
60006         * lib/strftime.c (widen): Cast alloca return value to proper type.
60007
60008         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
60009
60010         From GNU libc.
60011         * lib/strftime.c (my_strftime): Handle very large width
60012         specifications for numeric values correctly.  Improve checks for
60013         overflow.
60014
60015         2003-01-19  Jim Meyering  <jim@meyering.net>
60016
60017         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
60018         definitions.
60019         (nl_get_alt_digit) [! defined my_strftime]: Define.
60020         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
60021         _nl_get_alt_digit and _nl_get_walt_digit.
60022
60023         * lib/strftime.c (my_strftime): Merge in locale-related changes from
60024         libc. These changes have no effect outside of _LIBC.
60025
60026 2003-04-10  Bruno Haible  <bruno@clisp.org>
60027
60028         * modules/findprog: New file.
60029         * MODULES.html.sh (func_all_modules): Add it.
60030
60031 2003-04-10  Bruno Haible  <bruno@clisp.org>
60032
60033         * m4/findprog.m4: New file.
60034         * m4/eaccess.m4: New file.
60035
60036 2003-04-10  Bruno Haible  <bruno@clisp.org>
60037
60038         * lib/findprog.h: New file, from GNU gettext.
60039         * lib/findprog.c: New file, from GNU gettext.
60040
60041 2003-04-05  Jim Meyering  <jim@meyering.net>
60042
60043         Merge changes from Coreutils.
60044
60045         * lib/exclude.h (PARAMS): Remove definition and uses.
60046         * lib/exclude.c: Remove uses of `PARAMS'.
60047
60048         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
60049         Add test-cases for DOS filenames. Declare program_name.
60050         (main): Set up program_name.  Patch by Rich Dawe.
60051
60052         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
60053         error from mntctl.
60054         Use mntctl's return value to drive the entry-processing loop, since
60055         we can't rely on the value of the vmt_length member in the last
60056         entry.  On some systems doing so could result in exhausting
60057         virtual memory.  Based in part on a patch from Mike Jetzer.
60058
60059 2003-04-04  Bruno Haible  <bruno@clisp.org>
60060
60061         * modules/linebreak: New file.
60062         * MODULES.html.sh (func_all_modules): Add it.
60063
60064 2003-04-04  Bruno Haible  <bruno@clisp.org>
60065
60066         * m4/linebreak.m4: New file.
60067
60068 2003-04-04  Bruno Haible  <bruno@clisp.org>
60069
60070         * lib/linebreak.h: New file, from GNU gettext.
60071         * lib/linebreak.c: New file, from GNU gettext with slight
60072         modifications.
60073         * lib/lbrkprop.h: New file, from GNU gettext.
60074
60075 2003-04-03  Bruno Haible  <bruno@clisp.org>
60076
60077         * modules/utf8-ucs4: New file.
60078         * modules/utf16-ucs4: New file.
60079         * modules/ucs4-utf8: New file.
60080         * modules/ucs4-utf16: New file.
60081         * MODULES.html.sh (func_all_modules): Add them.
60082
60083 2003-04-03  Bruno Haible  <bruno@clisp.org>
60084
60085         * m4/utf-ucs4.m4: New file.
60086         * m4/ucs4-utf.m4: New file.
60087
60088 2003-04-03  Bruno Haible  <bruno@clisp.org>
60089
60090         * lib/utf8-ucs4.h: New file, from GNU gettext.
60091         * lib/utf16-ucs4.h: New file, from GNU gettext.
60092         * lib/ucs4-utf8.h: New file, from GNU gettext.
60093         * lib/ucs4-utf16.h: New file, from GNU gettext.
60094
60095 2003-04-02  Bruno Haible  <bruno@clisp.org>
60096
60097         * modules/binary-io: New file.
60098         * MODULES.html.sh (func_all_modules): Add it.
60099
60100 2003-04-02  Bruno Haible  <bruno@clisp.org>
60101
60102         * lib/binary-io.h: New file, from GNU gettext.
60103
60104 2003-04-01  Bruno Haible  <bruno@clisp.org>
60105
60106         * modules/pathname: New file.
60107         * MODULES.html.sh (func_all_modules): Add it.
60108
60109 2003-04-01  Bruno Haible  <bruno@clisp.org>
60110
60111         * lib/pathname.h: New file, from GNU gettext.
60112         * lib/concatpath.c: New file, from GNU gettext.
60113
60114 2003-03-30  Bruno Haible  <bruno@clisp.org>
60115
60116         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
60117
60118 2003-03-30  Bruno Haible  <bruno@clisp.org>
60119
60120         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
60121         function chown() doesn't exist.
60122
60123 2003-03-28  Bruno Haible  <bruno@clisp.org>
60124
60125         * modules/copy-file: New file.
60126         * MODULES.html.sh (func_all_modules): Add it.
60127
60128 2003-03-28  Bruno Haible  <bruno@clisp.org>
60129
60130         * m4/copy-file.m4: New file.
60131
60132 2003-03-28  Bruno Haible  <bruno@clisp.org>
60133
60134         * lib/copy-file.h: New file, from GNU gettext.
60135         * lib/copy-file.c: New file, from GNU gettext.
60136
60137 2003-03-18  Jim Meyering  <jim@meyering.net>
60138
60139         * lib/quote.c (quote_n): Fix typo in comment.
60140
60141 2003-03-18  Bruno Haible  <bruno@clisp.org>
60142
60143         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
60144         checking.
60145         * m4/onceonly_2_57.m4: Likewise.
60146
60147 2003-03-17  Bruno Haible  <bruno@clisp.org>
60148
60149         * m4/onceonly.m4: Require autoconf 2.54 or newer.
60150         (m4_quote): Remove macro.
60151         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
60152
60153 2003-03-14  Jim Meyering  <jim@meyering.net>
60154
60155         Merge changes from Coreutils.
60156         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
60157         to be const, in order to avoid warnings.
60158         (obstack_room): Likewise.
60159         (obstack_empty_p): Likewise.
60160
60161 2003-03-14  Bruno Haible  <bruno@clisp.org>
60162
60163         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
60164         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
60165
60166 2003-03-13  Paul Eggert  <eggert@twinsun.com>
60167
60168         Merge changes from Bison.
60169         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
60170         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
60171         when compiling Bison 1.875's `bitset bset = obstack_alloc
60172         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
60173         * lib/hash.c: Include <stdbool.h> unconditionally.
60174
60175 2003-03-13  Paul Eggert  <eggert@twinsun.com>
60176
60177         * m4/onceonly.m4 (m4_quote): New macro.
60178         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
60179         Quote AC_FOREACH variable-expansions properly.
60180
60181 2003-03-13  Paul Eggert  <eggert@twinsun.com>
60182
60183         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
60184
60185 2003-03-09  Paul Eggert  <eggert@twinsun.com>
60186
60187         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
60188         Reported by Bruce Becker; see:
60189         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
60190
60191 2003-03-03  Paul Eggert  <eggert@twinsun.com>
60192             Bruno Haible  <bruno@clisp.org>
60193
60194         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
60195         Reported by John Hughes, see
60196         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
60197
60198 2003-02-20  Bruno Haible  <bruno@clisp.org>
60199
60200         * MODULES.html.sh (func_all_modules): Add poll.
60201
60202 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
60203
60204         * modules/poll: New file.
60205
60206 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
60207
60208         * lib/poll_.h: New file.
60209         * lib/poll.c: New file.
60210
60211 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
60212
60213         * m4/poll.m4: New file.
60214
60215 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
60216
60217         * modules/mathl: New file.
60218
60219 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
60220
60221         * lib/mathl.h: New file.
60222         * lib/acosl.c: New file.
60223         * lib/asinl.c: New file.
60224         * lib/atanl.c: New file.
60225         * lib/ceill.c: New file.
60226         * lib/cosl.c: New file.
60227         * lib/expl.c: New file.
60228         * lib/floorl.c: New file.
60229         * lib/frexpl.c: New file.
60230         * lib/ldexpl.c: New file.
60231         * lib/logl.c: New file.
60232         * lib/sincosl.c: New file.
60233         * lib/sinl.c: New file.
60234         * lib/sqrtl.c: New file.
60235         * lib/tanl.c: New file.
60236         * lib/trigl.c: New file.
60237         * lib/trigl.h: New file.
60238
60239 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
60240
60241         * m4/mathl.m4: New file.
60242
60243 2003-02-18  Bruno Haible  <bruno@clisp.org>
60244
60245         * MODULES.html.sh (func_all_modules): Add mathl.
60246
60247 2003-02-17  Bruno Haible  <bruno@clisp.org>
60248
60249         * modules/mkdtemp: New module.
60250         * MODULES.html.sh (func_all_modules): Add it.
60251
60252 2003-02-17  Bruno Haible  <bruno@clisp.org>
60253
60254         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
60255
60256 2003-02-17  Bruno Haible  <bruno@clisp.org>
60257
60258         * lib/mkdtemp.h: New file, from GNU gettext.
60259         * lib/mkdtemp.c: New file, from GNU gettext.
60260
60261 2003-02-02  Jim Meyering  <jim@meyering.net>
60262
60263         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
60264         e.g. glibc-2.2.93.
60265
60266 2003-01-31  Bruno Haible  <bruno@clisp.org>
60267
60268         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
60269         'rpl_rename'.
60270         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
60271         'rpl_strnlen'.
60272         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
60273         'rpl_strtod'.
60274         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
60275         'rpl_utime'.
60276
60277 2003-01-31  Bruno Haible  <bruno@clisp.org>
60278
60279         * lib/rename.c: #undef rename before defining rpl_rename.
60280         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
60281
60282 2003-01-30  Bruno Haible  <bruno@clisp.org>
60283
60284         * modules/vasnprintf, modules/vasprintf: New modules.
60285         * MODULES.html.sh (func_all_modules): Add them.
60286
60287 2003-01-30  Bruno Haible  <bruno@clisp.org>
60288
60289         * m4/signed.m4: New file, from GNU gettext.
60290         * m4/longdouble.m4: New file, from GNU gettext.
60291         * m4/wchar_t.m4: New file, from GNU gettext.
60292         * m4/wint_t.m4: New file, from GNU gettext.
60293         * m4/vasnprintf.m4: New file.
60294         * m4/vasprintf.m4: New file.
60295
60296 2003-01-30  Bruno Haible  <bruno@clisp.org>
60297
60298         * lib/printf-args.h: New file, from GNU gettext.
60299         * lib/printf-args.c: New file, from GNU gettext.
60300         * lib/printf-parse.h: New file, from GNU gettext.
60301         * lib/printf-parse.c: New file, from GNU gettext.
60302         * lib/vasnprintf.h: New file, from GNU gettext.
60303         * lib/vasnprintf.c: New file, from GNU gettext.
60304         * lib/asnprintf.c: New file, from GNU gettext.
60305         * lib/vasprintf.h: New file, from GNU gettext with modifications.
60306         * lib/vasprintf.c: New file, from GNU gettext.
60307         * lib/asprintf.c: New file, from GNU gettext.
60308
60309 2003-01-29  Bruno Haible  <bruno@clisp.org>
60310
60311         * modules/stpncpy: New module.
60312         * MODULES.html.sh (func_all_modules): Add it.
60313
60314 2003-01-29  Bruno Haible  <bruno@clisp.org>
60315
60316         * m4/stpncpy.m4: New file.
60317
60318 2003-01-29  Bruno Haible  <bruno@clisp.org>
60319
60320         * lib/stpncpy.h: New file, from GNU gettext with modifications.
60321         * lib/stpncpy.c: New file, from GNU gettext with modifications.
60322
60323 2003-01-28  Bruno Haible  <bruno@clisp.org>
60324
60325         * modules/c-ctype: New module.
60326         * MODULES.html.sh (func_all_modules): Add it.
60327
60328 2003-01-28  Bruno Haible  <bruno@clisp.org>
60329
60330         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
60331         Paul Eggert.
60332         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
60333         Paul Eggert.
60334
60335 2003-01-27  Bruno Haible  <bruno@clisp.org>
60336
60337         * modules/xsetenv: New module.
60338         * MODULES.html.sh (func_all_modules): Add it.
60339
60340 2003-01-27  Bruno Haible  <bruno@clisp.org>
60341
60342         * lib/xsetenv.h: New file, from GNU gettext.
60343         * lib/xsetenv.c: New file, from GNU gettext.
60344
60345 2003-01-23  Jim Meyering  <jim@meyering.net>
60346
60347         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
60348         from working on systems without dirfd (at least Irix and OSF1/Tru64).
60349
60350 2003-01-23  Bruno Haible  <bruno@clisp.org>
60351
60352         * modules/minmax: New module.
60353         * MODULES.html.sh (func_all_modules): Add it.
60354
60355 2003-01-23  Bruno Haible  <bruno@clisp.org>
60356
60357         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
60358         Eggert.
60359
60360 2003-01-22  Bruno Haible  <bruno@clisp.org>
60361
60362         * modules/exit: New module.
60363         * MODULES.html.sh (func_all_modules): Add it.
60364
60365 2003-01-22  Bruno Haible  <bruno@clisp.org>
60366
60367         * lib/exit.h: New file, from GNU gettext.
60368
60369 2003-01-19  Bruno Haible  <bruno@clisp.org>
60370
60371         * gnulib-tool: Recognize option --extract-maintainer.
60372         (func_get_maintainer): New function.
60373         * modules/*: Add Maintainer entry.
60374
60375 2003-01-16  Jim Meyering  <jim@meyering.net>
60376
60377         * m4/regex.m4: The `regex' struct is both input and output.
60378         Initialize it before each use.  Patch by Tim Waugh.
60379
60380 2003-01-16  Bruno Haible  <bruno@clisp.org>
60381
60382         * MODULES.html.sh: Add a table of contents. Add the module name as
60383         leftmost column. Add hyperlinks.
60384
60385 2003-01-15  Bruno Haible  <bruno@clisp.org>
60386
60387         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
60388
60389 2003-01-15  Bruno Haible  <bruno@clisp.org>
60390
60391         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
60392         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
60393         suffix.
60394
60395 2003-01-15  Bruno Haible  <bruno@clisp.org>
60396
60397         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
60398
60399 2003-01-15  Bruno Haible  <bruno@clisp.org>
60400
60401         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
60402         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
60403
60404 2003-01-14  Jim Meyering  <jim@meyering.net>
60405
60406         * lib/same.c (same_name): Tweak a comment.
60407
60408 2003-01-14  Bruno Haible  <bruno@clisp.org>
60409
60410         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
60411         when a string comparison is sufficient.
60412
60413 2003-01-14  Bruno Haible  <bruno@clisp.org>
60414
60415         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
60416         'unsigned int'.
60417
60418 2003-01-14  Bruno Haible  <bruno@clisp.org>
60419
60420         * lib/hash-pjw.c: Add comment about low quality of this function.
60421
60422 2003-01-13  Bruno Haible  <bruno@clisp.org>
60423
60424         * modules/stpcpy: Distribute lib/stpcpy.h.
60425         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
60426
60427 2003-01-13  Bruno Haible  <bruno@clisp.org>
60428
60429         * modules/*: Add a description.
60430         * modules/strpbrk: Fix Makefile.am snippet.
60431         * modules/strtoimax: Fix dependencies.
60432         * modules/strtoumax: Likewise.
60433
60434 2003-01-13  Bruno Haible  <bruno@clisp.org>
60435
60436         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
60437         * modules/alloca (Makefile.am): All object files depend on alloca.h.
60438         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
60439
60440 2003-01-13  Bruno Haible  <bruno@clisp.org>
60441
60442         * gnulib-tool (func_create_testdir): Store config/* files in the main
60443         directory.
60444         * config.rpath: Move to ...
60445         * config/config.rpath: ... here.
60446         * modules/gettext: Contains config/config.rpath, not config.rpath.
60447         * modules/iconv: Likewise.
60448
60449 2003-01-12  Paul Eggert  <eggert@twinsun.com>
60450
60451         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
60452         to avoid collisions with libcurses and libreadline.
60453
60454         * m4/getstr.m4: Remove.
60455         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
60456
60457 2003-01-12  Paul Eggert  <eggert@twinsun.com>
60458
60459         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
60460         to avoid collisions with libcurses and libreadline.
60461
60462         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
60463         * lib/getstr.h, getstr.c: Remove.
60464         * lib/getline.c: Include "getline.h", to check interface.
60465         Move body of old getstr.c here: this defines MIN_CHUNK and
60466         declares getdelim2, which is renamed from getstr.
60467         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
60468
60469         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
60470         All uses changed.
60471         * lib/linebuffer.h: Likewise.
60472         (readline): Remove backward-compatibility macro.
60473
60474 2003-01-12  Paul Eggert  <eggert@twinsun.com>
60475
60476         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
60477         to avoid collisions with libcurses and libreadline.
60478         * getstr: Remove.
60479         * MODULES.html.sh: Remove getstr.
60480         * modules/getline: Depend on unlocked-io, not getstr.
60481
60482 2003-01-12  Jim Meyering  <jim@meyering.net>
60483
60484         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
60485
60486 2003-01-10  Bruno Haible  <bruno@clisp.org>
60487
60488         * modules/alloca: Change Makefile.am requirements. Simplify Include
60489         requirements. Add lib/alloca_.h to file list.
60490
60491 2003-01-10  Bruno Haible  <bruno@clisp.org>
60492
60493         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
60494
60495 2003-01-10  Bruno Haible  <bruno@clisp.org>
60496
60497         * lib/alloca_.h: New file.
60498         * lib/getdate.y: Unconditionally include alloca.h.
60499         * lib/makepath.c: Likewise.
60500         * lib/setenv.c: Likewise.
60501         * lib/userspec.c: Likewise.
60502
60503 2003-01-09  Karl Berry  <karl@gnu.org>
60504
60505         * MODULES.html.sh: include `dirname $0` in PATH, to find
60506         gnulib-tool.
60507
60508 2003-01-09  Bruno Haible  <bruno@clisp.org>
60509
60510         * modules/stdbool: Change configure.ac, Makefile.am requirements.
60511         Simplify Include requirements. Add lib/stdbool.h.in to file list.
60512
60513 2003-01-09  Bruno Haible  <bruno@clisp.org>
60514
60515         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
60516
60517 2003-01-09  Bruno Haible  <bruno@clisp.org>
60518
60519         * lib/stdbool.h.in: New file.
60520
60521 2003-01-09  Bruno Haible  <bruno@clisp.org>
60522
60523         * gnulib-tool (func_all_modules): Ignore files ending in ~.
60524         * MODULES.html.sh: Likewise.
60525
60526 2003-01-08  Jim Meyering  <jim@meyering.net>
60527
60528         * lib/full-write.c: Undefine and define-away `const' after inclusion
60529         of errno.h, not before.  Suggestion from Bruno Haible.
60530
60531 2003-01-08  Bruno Haible  <bruno@clisp.org>
60532
60533         * modules/full-read: Depend on full-write.
60534
60535 2003-01-08  Bruno Haible  <bruno@clisp.org>
60536
60537         * lib/safe-read.c: Include specification header first, to ensure its
60538         selfcontainedness.
60539         * lib/full-write.c: Likewise.
60540
60541 2003-01-07  Jim Meyering  <jim@meyering.net>
60542
60543         * lib/full-write.c: Rework so that it may serve to define full_read,
60544         too.
60545         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
60546
60547 2003-01-07  Bruno Haible  <bruno@clisp.org>
60548
60549         * lib/strtoimax.c: Include <stdint.h> as an alternative to
60550         <inttypes.h>.
60551         * lib/xstrtol.h: Likewise.
60552         * lib/xstrtoimax.c: Likewise.
60553         * lib/xstrtoumax.c: Likewise.
60554         * lib/human.h: Likewise.
60555
60556         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
60557         on systems that have <inttypes.h> but not <stdint.h>.
60558
60559 2003-01-07  Bruno Haible  <bruno@clisp.org>
60560
60561         * MODULES.html.sh: Add copyright notice.
60562         (missed_files): Omit CVS directory entries.
60563         (func_module): Make it work with sed-3.02.
60564         * MODULES.txt: Remove file.
60565
60566 2003-01-06  Jim Meyering  <jim@meyering.net>
60567
60568         * lib/version-etc.c: Update year in translatable copyright string.
60569
60570 2003-01-03  Karl Berry  <karl@gnu.org>
60571
60572         * config/config.{guess,sub}: update from prep.
60573
60574 2003-01-02  Karl Berry  <karl@gnu.org>
60575
60576         * doc/COPYING.DOC: belatedly updated to 1.2.
60577
60578 2003-01-01  Karl Berry  <karl@gnu.org>
60579
60580         * gnulib-tool (func_verify_module): report module name $module in
60581         error message, not $1.
60582         * gnulib-tool (create-testdir): don't complain if destdir couldn't
60583         be created, only if it doesn't exist.
60584         * gnulib-tool (last_checkin_date): don't expand the $Date here.
60585
60586 2002-12-31  Paul Eggert  <eggert@twinsun.com>
60587
60588         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
60589
60590 2002-12-31  Paul Eggert  <eggert@twinsun.com>
60591
60592         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
60593         memcmp if strcoll doesn't work.
60594
60595 2002-12-31  Bruno Haible  <bruno@clisp.org>
60596
60597         * lib/utime.c (utime_null): No need to call ftruncate if the file was
60598         nonempty.
60599
60600 2002-12-31  Bruno Haible  <bruno@clisp.org>
60601
60602         * lib/memcoll.c (STRCOLL): New macro.
60603         (memcoll): Use it.
60604
60605 2002-12-31  Bruno Haible  <bruno@clisp.org>
60606
60607         * lib/localcharset.h: New file.
60608         * lib/localcharset.c: Include it.
60609         * lib/unicodeio.c: Likewise.
60610
60611 2002-12-31  Bruno Haible  <bruno@clisp.org>
60612
60613         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
60614         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
60615
60616 2002-12-31  Bruno Haible  <bruno@clisp.org>
60617
60618         * lib/getline.h: Include <stddef.h>, for size_t.
60619
60620         * lib/unicodeio.h: Include <stddef.h>, for size_t.
60621         * lib/unicodeio.c: Don't include <stddef.h>.
60622
60623 2002-12-31  Bruno Haible  <bruno@clisp.org>
60624
60625         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
60626         HAVE_TM_ZONE.
60627
60628 2002-12-24  Karl Berry  <karl@gnu.org>
60629
60630         * config/config.guess: update from prep.
60631
60632 2002-12-24  Bruno Haible  <bruno@clisp.org>
60633
60634         General infrasructure.
60635         * m4/README: Rewritten.
60636         * m4/onceonly.m4: New file.
60637         * m4/onceonly_2_57.m4: New file.
60638
60639         Module atexit.
60640         * m4/atexit.m4: New file.
60641
60642         Module strtod.
60643         * m4/strtod.m4: New file.
60644
60645         Module strtol.
60646         * m4/strtol.m4: New file.
60647
60648         Module strtoul.
60649         * m4/strtoul.m4: New file.
60650
60651         Module memchr.
60652         * m4/memchr.m4: New file.
60653
60654         Module memcmp.
60655         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
60656         (jm_FUNC_MEMCMP): Invoke it.
60657
60658         Module memcpy.
60659         * m4/memcpy.m4: New file.
60660
60661         Module memmove.
60662         * m4/memmove.m4: New file.
60663
60664         Module memset.
60665         * m4/memset.m4: New file.
60666
60667         Module strcspn.
60668         * m4/strcspn.m4: New file.
60669
60670         Module strpbrk.
60671         * m4/strpbrk.m4: New file.
60672
60673         Module strstr.
60674         * m4/strstr.m4: New file.
60675
60676         Module strerror.
60677         * m4/strerror.m4: New file.
60678
60679         Module mktime.
60680         * m4/mktime.m4: Renamed from jm-mktime.m4.
60681         (gl_PREREQ_MKTIME): New macro.
60682         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
60683
60684         Module malloc.
60685         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
60686         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
60687         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
60688
60689         Module realloc.
60690         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
60691         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
60692         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
60693
60694         Module strftime.
60695         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
60696         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
60697         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
60698         gl_TM_GMTOFF.
60699         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
60700
60701         Module xalloc.
60702         * m4/xalloc.m4: New file.
60703
60704         Module alloca.
60705         * m4/alloca.m4: New file.
60706
60707         Module putenv.
60708         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
60709         (jm_FUNC_PUTENV): Invoke it.
60710
60711         Module setenv.
60712         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
60713         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
60714         when invoked twice.
60715         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
60716         gt_FUNC_SETENV.
60717
60718         Module memrchr.
60719         * m4/memrchr.m4: New file.
60720
60721         Module stpcpy.
60722         * m4/stpcpy.m4: New file.
60723
60724         Module strcase.
60725         * m4/strcase.m4: New file.
60726
60727         Module strdup.
60728         * m4/strdup.m4: New file.
60729
60730         Module strnlen.
60731         * m4/strnlen.m4: New file.
60732
60733         Module strndup.
60734         * m4/strndup.m4: New file.
60735
60736         Module xstrtod.
60737         * m4/xstrtod.m4: New file.
60738
60739         Module xstrtol.
60740         * m4/xstrtol.m4: New file.
60741
60742         Module getdate.
60743         * m4/getdate.m4: New file.
60744
60745         Module unlocked-io.
60746         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
60747         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
60748         * m4/jm-glibc-io.m4n: Remove file.
60749
60750         Module long-options.
60751         * m4/long-options.m4: New file.
60752
60753         Module md5.
60754         * m4/md5.m4: New file.
60755
60756         Module sha.
60757         * m4/sha.m4: New file.
60758
60759         Module getstr.
60760         * m4/getstr.m4: New file.
60761
60762         Module getline.
60763         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
60764         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
60765         <sys/types.h>, for size_t. Use the function name gnu_getline, not
60766         simply getline. Infoke gl_PREREQ_GETLINE.
60767
60768         Module obstack.
60769         * m4/obstack.m4: New file.
60770
60771         Module hash.
60772         * m4/hash.m4: New file.
60773
60774         Module readtokens.
60775         * m4/readtokens.m4: New file.
60776
60777         Module strverscmp.
60778         * m4/strverscmp.m4: New file.
60779
60780         Module stdbool.
60781         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
60782         OSF/1.
60783
60784         Module strtoll.
60785         * m4/strtoll.m4: New file.
60786
60787         Module strtoull.
60788         * m4/strtoull.m4: New file.
60789
60790         Module strtoimax.
60791         * m4/strtoimax.m4: New file.
60792
60793         Module strtoumax.
60794         * m4/strtoumax.m4: New file.
60795
60796         Module xstrtoimax.
60797         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
60798         jm_AC_PREREQ_XSTRTOIMAX.
60799         Moved the strtol prerequisites to strtol.m4.
60800         Moved the strtoll prerequisites to strtoll.m4.
60801         Moved the strtoimax prerequisites to strtoimax.m4.
60802
60803         Module xstrtoumax.
60804         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
60805         jm_AC_PREREQ_XSTRTOUMAX.
60806         Moved the strtoul prerequisites to strtoul.m4.
60807         Moved the strtoull prerequisites to strtoull.m4.
60808         Moved the strtoumax prerequisites to strtoumax.m4.
60809
60810         Module chown.
60811         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
60812         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
60813
60814         Module dup2.
60815         * m4/dup2.m4: New file.
60816
60817         Module ftruncate.
60818         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
60819         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
60820
60821         Module getgroups.
60822         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
60823         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
60824
60825         Module gettimeofday.
60826         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
60827         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
60828         gl_PREREQ_GETTIMEOFDAY.
60829
60830         Module mkdir.
60831         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
60832         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
60833
60834         Module mkstemp.
60835         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
60836         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
60837         jm_AC_TYPE_UINTMAX_T.
60838         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
60839
60840         Module stat.
60841         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
60842         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
60843
60844         Module lstat.
60845         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
60846         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
60847
60848         Module timespec.
60849         * m4/timespec.m4 (gl_TIMESPEC): New macro.
60850         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
60851         * m4/st_mtim.m4: Indentation.
60852
60853         Module nanosleep.
60854         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
60855         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
60856         gl_PREREQ_NANOSLEEP.
60857
60858         Module regex.
60859         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
60860         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
60861         (gl_REGEX): New macro.
60862
60863         Module rename.
60864         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
60865         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
60866
60867         Module rmdir.
60868         * m4/rmdir.m4: New file.
60869
60870         Module utime.
60871         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
60872         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
60873         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
60874
60875         Module dirname.
60876         * m4/dirname.m4: New file.
60877
60878         Module getopt.
60879         * m4/getopt.m4: New file.
60880
60881         Module unistd-safer.
60882         * m4/unistd-safer.m4: New file.
60883
60884         Module fnmatch.
60885         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
60886         declaration.
60887         (gl_PREREQ_FNMATCH_EXTRA): New macro.
60888         (gl_FUNC_FNMATCH_POSIX): New macro.
60889         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
60890         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
60891         simply fnmatch.
60892
60893         Module exclude.
60894         * m4/exclude.m4: New file.
60895
60896         Module human.
60897         * m4/human.m4: New file.
60898
60899         Module acl.
60900         * m4/acl.m4: Nop.
60901
60902         Module backupfile.
60903         * m4/backupfile.m4: New file.
60904         * m4/d-ino.m4: Indentation.
60905
60906         Module fsusage.
60907         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
60908         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
60909         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
60910
60911         Module dirfd.
60912         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
60913         requirements.
60914
60915         Module euidaccess.
60916         * m4/euidaccess.m4: New file.
60917
60918         Module file-type.
60919         * m4/file-type.m4: New file.
60920
60921         Module fileblocks.
60922         * m4/fileblocks.m4: New file.
60923
60924         Module filemode.
60925         * m4/filemode.m4: New file.
60926
60927         Module isdir.
60928         * m4/isdir.m4: New file.
60929
60930         Module lchown.
60931         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
60932         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
60933
60934         Module makepath.
60935         * m4/makepath.m4: New file.
60936
60937         Module modechange.
60938         * m4/modechange.m4: New file.
60939
60940         Module mountlist.
60941         * m4/mountlist.m4: New file.
60942         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
60943         Indentation.
60944
60945         Module path-concat.
60946         * m4/path-concat.m4: New file.
60947
60948         Module pathmax.
60949         * m4/pathmax.m4: New file.
60950
60951         Module same.
60952         * m4/same.m4: New file.
60953
60954         Module save-cwd.
60955         * m4/save-cwd.m4: New file.
60956
60957         Module savedir.
60958         * m4/savedir.m4: New file.
60959
60960         Module xgetcwd.
60961         * m4/xgetcwd.m4: New file.
60962         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
60963
60964         Module xreadlink.
60965         * m4/xreadlink.m4: New file.
60966
60967         Module safe-read.
60968         * m4/safe-read.m4: New file.
60969
60970         Module safe-write.
60971         * m4/safe-write.m4: New file.
60972
60973         Module closeout.
60974         * m4/closeout.m4: New file.
60975
60976         Module stdio-safer.
60977         * m4/stdio-safer.m4: New file.
60978
60979         Module getpass.
60980         * m4/getpass.m4: New file.
60981
60982         Module getugroups.
60983         * m4/getugroups.m4: New file.
60984
60985         Module group-member.
60986         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
60987         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
60988
60989         Module idcache.
60990         * m4/idcache.m4: New file.
60991
60992         Module userspec.
60993         * m4/userspec.m4: New file.
60994
60995         Module gettime.
60996         * m4/clock_time.m4: New file.
60997         * m4/gettime.m4: New file.
60998
60999         Module settime.
61000         * m4/settime.m4: New file.
61001
61002         Module posixtm.
61003         * m4/posixtm.m4: New file.
61004
61005         Module gethostname.
61006         * m4/gethostname.m4: New file.
61007
61008         Module canon-host.
61009         * m4/canon-host.m4: New file.
61010
61011         Module gettext.
61012         * m4/codeset.m4: New file, from gettext-0.11.5.
61013         * m4/gettext.m4: New file, from gettext-0.11.5.
61014         * m4/glibc21.m4: New file, from gettext-0.11.5.
61015         * m4/iconv.m4: New file, from gettext-0.11.5.
61016         * m4/intdiv0.m4: New file, from gettext-0.11.5.
61017         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
61018         * m4/inttypes.m4: New file, from gettext-0.11.5.
61019         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
61020         * m4/isc-posix.m4: New file, from gettext-0.11.5.
61021         * m4/lcmessage.m4: New file, from gettext-0.11.5.
61022         * m4/lib-ld.m4: New file, from gettext-0.11.5.
61023         * m4/lib-link.m4: New file, from gettext-0.11.5.
61024         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
61025         * m4/progtest.m4: New file, from gettext-0.11.5.
61026         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
61027         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
61028         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
61029
61030         Module localcharset.
61031         * m4/localcharset.m4: New file.
61032
61033         Module hard-locale.
61034         * m4/hard-locale.m4: New file.
61035
61036         Module mbswidth.
61037         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
61038         onceonly macros.
61039         * m4/mbrtowc.m4: Add comment.
61040
61041         Module memcasecmp.
61042         * m4/memcasecmp.m4: New file.
61043
61044         Module memcoll.
61045         * m4/memcoll.m4: New file.
61046
61047         Module unicodeio.
61048         * m4/unicodeio.m4: New file.
61049
61050         Module rpmatch.
61051         * m4/rpmatch.m4: New file.
61052
61053         Module yesno.
61054         * m4/yesno.m4: New file.
61055
61056         Module exitfail.
61057         * m4/exitfail.m4: New file.
61058
61059         Module c-stack.
61060         * m4/c-stack.m4 (gl_C_STACK): New macro.
61061         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
61062
61063         Module error.
61064         * m4/error.m4 (gl_ERROR): New macro.
61065         (jm_PREREQ_ERROR): Use onceonly macros.
61066
61067         Module fatal.
61068         * m4/fatal.m4: New file.
61069
61070         Module getloadavg.
61071         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
61072         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
61073
61074         Module getpagesize.
61075         * m4/getpagesize.m4: New file.
61076
61077         Module getusershell.
61078         * m4/getusershell.m4: New file.
61079
61080         Module physmem.
61081         * m4/physmem.m4: New file.
61082
61083         Module posixver.
61084         * m4/posixver.m4: New file.
61085
61086         Module quotearg.
61087         * m4/quotearg.m4: New file.
61088
61089         Module quote.
61090         * m4/quote.m4: New file.
61091
61092         Module readutmp.
61093         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
61094
61095         Module sig2str.
61096         * m4/sig2str.m4: New file.
61097
61098         Other.
61099         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
61100         ulonglong.m4.
61101         * m4/intmax_t.m4: New file.
61102         * m4/d-type.m4: Indentation.
61103         * m4/jm-macros.m4: Update.
61104         * m4/prereq.m4 (jm_PREREQ): Update.
61105         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
61106         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
61107         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
61108         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
61109         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
61110         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
61111         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
61112         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
61113         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
61114         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
61115         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
61116         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
61117         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
61118         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
61119         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
61120         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
61121         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
61122         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
61123         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
61124
61125 2002-12-24  Bruno Haible  <bruno@clisp.org>
61126
61127         * MODULES.txt: Update according to m4/ changes.
61128
61129         Module gettext.
61130         * config.rpath: New file, from gettext-0.11.5.
61131
61132         * modules/*: New module descriptions.
61133         * gnulib-tool: New file.
61134         * MODULES.html.sh: New file.
61135
61136 2002-12-21  Karl Berry  <karl@gnu.org>
61137
61138         * doc/fdl.texi: update to version 1.2.
61139
61140 2002-12-19  Karl Berry  <karl@gnu.org>
61141
61142         * config/config.guess: update from prep.
61143
61144 2002-12-18  Bruno Haible  <bruno@clisp.org>
61145
61146         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
61147         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
61148
61149 2002-12-17  Bruno Haible  <bruno@clisp.org>
61150
61151         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
61152         stdlib.h, string.h.
61153
61154 2002-12-17  Bruno Haible  <bruno@clisp.org>
61155
61156         * lib/canon-host.c (strdup): Remove unused declaration.
61157
61158         * lib/fsusage.c: Include full_read.h.
61159         (get_fs_usage): Use full_read instead of safe_read.
61160
61161         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
61162
61163 2002-12-12  Karl Berry  <karl@gnu.org>
61164
61165         * config/config.guess: update from prep.
61166
61167 2002-12-11  Bruno Haible  <bruno@clisp.org>
61168
61169         * m4/setenv.m4: New file, from gettext-0.11.5.
61170
61171 2002-12-11  Bruno Haible  <bruno@clisp.org>
61172
61173         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
61174         not unsetenv().
61175         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
61176         modifications:
61177
61178         2002-12-11  Bruno Haible  <bruno@clisp.org>
61179
61180                 * setenv.c (alloca): Fall back to malloc.
61181                 (freea): New macro.
61182                 (setenv): Use freea() to free memory allocated with alloca().
61183
61184         2002-11-13  Bruno Haible  <bruno@clisp.org>
61185
61186                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
61187                 function declarations.
61188                 * unsetenv.c (unsetenv): Likewise.
61189
61190         2002-03-04  Bruno Haible  <bruno@clisp.org>
61191
61192                 Portability to AIX 4.3.3.
61193                 * unsetenv.c: New file, extracted from setenv.c.
61194                 * setenv.c: Move the unsetenv() function to unsetenv.c.
61195
61196         2001-12-20  Bruno Haible  <bruno@clisp.org>
61197
61198                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
61199                 use malloc instead. For SunOS 4.
61200
61201         2001-12-11  Bruno Haible  <bruno@clisp.org>
61202
61203                 * setenv.c: Declare alloca.
61204                 (compar_fn_t): New typedef.
61205                 (KNOWN_VALUE, STORE_VALUE): Use it.
61206
61207         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
61208         setenv.h.
61209
61210 2002-12-10  Paul Eggert  <eggert@twinsun.com>
61211
61212         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
61213         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
61214         Choose values that are less likely to collide with system fnmatch
61215         options.
61216         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
61217         defined (e.g., a pure POSIX system).
61218         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
61219         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
61220
61221 2002-12-06  Paul Eggert  <eggert@twinsun.com>
61222
61223         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
61224         a pain in practice to deal with generated m4 files.  This change
61225         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
61226
61227         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
61228         and jm-glibc-io.m4, as they are no longer a special case.
61229         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
61230         kludge and the auto-generation stuff.  Check only whether the
61231         functions are declared, not whether they exist, since older hosts
61232         that don't declare the functions can't use the optimization anyway.
61233
61234 2002-12-06  Jim Meyering  <jim@meyering.net>
61235
61236         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
61237
61238         Merge in changes from libc's misc/error.c, in preparation
61239         for the merge of gnulib's changes back into libc.
61240
61241         * lib/error.c (_): Define only if not already defined.
61242         Move definition to follow all #include directives.
61243         Include unlocked-io.h only if !_LIBC.
61244         [_LIBC]: Include <libio/libioP.h>.
61245         [USE_IN_LIBIO]: Include <libio/iolibio.h>
61246         (fflush): Tweak definition to use INTUSE.
61247         (putc): Define.
61248
61249 2002-12-05  Paul Eggert  <eggert@twinsun.com>
61250
61251         * lib/alloca.c [defined emacs]: Include "lisp.h".
61252         (xalloc_die) [defined emacs]: New macro.
61253         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
61254         [! defined emacs]: Include <xalloc.h>.
61255         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
61256         (pointer): Typedef to POINTER_TYPE *.
61257         (malloc): Remove decl; we now always use xmalloc.
61258         (alloca): Use old-style definition, since Emacs needs this.
61259         Check for arithmetic overflow when computing combined size.
61260
61261 2002-12-04  Paul Eggert  <eggert@twinsun.com>
61262
61263         Do not generate unlocked-io.h automatically, since it's easier to
61264         maintain it by hand.
61265
61266         * lib/unlocked-io.h: New file, from GNU diffutils,
61267         but with proper copyright notice and attribution.
61268         * lib/gen-uio: Remove.
61269         * lib/Makefile.am: Add copyright notice.
61270         (libfetish_a_SOURCES): Add unlocked-io.h.
61271         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
61272         (DISTCLEANFILES, io_functions): Remove macros.
61273         (EXTRA_DIST): Remove gen_uio.
61274         (unlocked-io.h): Remove rule.
61275
61276 2002-12-04  Jim Meyering  <jim@meyering.net>
61277
61278         Reflect the fact that stat.c and lstat.c are no longer generated.
61279         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
61280         (DISTCLEANFILES): Likewise.
61281         (EXTRA_DIST): Likewise.
61282         (all_local): Don't depend on stat.c or lstat.c.
61283         (stat.c, lstat.c): Remove rules.
61284         (EXTRA_DIST): Remove xstat.in.
61285
61286         * lib/xstat.in: Remove file.  Contents moved into stat.c.
61287         * lib/stat.c: New file.  Contents mostly from xstat.in.
61288         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
61289         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
61290
61291         * lib/safe-read.c: Rework so that it may serve to define safe_write,
61292         too.
61293         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
61294
61295 2002-12-03  Jim Meyering  <jim@meyering.net>
61296
61297         * lib/safe-read.c, safe-write.c: Change variable names and comments,
61298         but not semantics, to minimize the differences between these two files.
61299         (safe_read): Change comment to mention SAFE_READ_ERROR.
61300
61301         * lib/safe-read.c (IS_EINTR): Define.
61302         (safe_read): Use IS_EINTR in place of in-function cpp directives.
61303
61304 2002-12-02  Jim Meyering  <jim@meyering.net>
61305
61306         * lib/safe-read.c (EINTR): Define.
61307         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
61308         (INT_MAX): Provide fallback.
61309         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
61310
61311         * lib/safe-read.h (SAFE_READ_ERROR): Define.
61312
61313 2002-12-02  Bruno Haible  <bruno@clisp.org>
61314
61315         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
61316         Define, taken from safe-read.c.
61317         (INT_MAX): Provide fallback.
61318         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
61319         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
61320
61321         * lib/safe-read.c (EINTR): Remove definition.
61322         (safe_read): Don't use EINTR if it is absent.
61323
61324 2002-12-01  Jim Meyering  <jim@meyering.net>
61325
61326         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
61327         zero.
61328         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
61329
61330 2002-11-27  Paul Eggert  <eggert@twinsun.com>
61331
61332         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
61333         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
61334         with `if (! (value < limit)) abort ();', for readability.
61335
61336 2002-11-26  Karl Berry  <karl@gnu.org>
61337
61338         * lib/strdup.c: copy from libc again, with jim's ok.
61339         * lib/.cppi-disable: re-add strdup.c
61340
61341 2002-11-25  Karl Berry  <karl@gnu.org>
61342
61343         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
61344         instead of "strtol.c".
61345
61346 2002-11-25  Karl Berry  <karl@gnu.org>
61347
61348         * config/install-sh: update from automake for variable quoting, $0 in
61349         error msgs, etc.
61350
61351         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
61352         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
61353         entry.
61354
61355 2002-11-25  Jim Meyering  <jim@meyering.net>
61356
61357         * lib/mktime.c: Sync from libc, now that it has the latest fix.
61358
61359 2002-11-24  Karl Berry  <karl@gnu.org>
61360
61361         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
61362         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
61363
61364 2002-11-24  Jim Meyering  <jim@meyering.net>
61365
61366         Update from coreutils:
61367
61368         * lib/mktime.c: Merge in changes from libc.
61369
61370         Avoid a link-time failure on some Linux systems.
61371         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
61372         (otherwise).
61373         (__mon_yday): Declare with the STATIC attribute.
61374         (__mktime_internal): Likewise.
61375         Based on a report from Greg Schafer.
61376
61377 2002-11-23  Jim Meyering  <jim@meyering.net>
61378
61379         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
61380         Use `unsigned', not `int', as type of index.
61381
61382         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
61383
61384         * lib/fsusage.c: Remove unneeded parentheses around operands of
61385         `defined'.
61386
61387 2002-11-22  Paul Eggert  <eggert@twinsun.com>
61388
61389         * lib/quotearg.h: Allow multiple inclusion by surrounding with
61390         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
61391         so that we can be included first.
61392         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
61393         * lib/quotearg.c: Include quotearg.h immediately after config.h.
61394         No need to include stddef.h or sys/types.h any more.
61395         Surround local include files with "", not "<>".
61396         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
61397         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
61398         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
61399         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
61400         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
61401         (ISPRINT): Remove; no longer needed now that we assume C89.
61402
61403         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
61404         Preserve errno.
61405
61406         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
61407         quotearg_char): Use SIZE_MAX rather than
61408         (size_t) -1 when we are talking about "infinity".
61409
61410         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
61411
61412 2002-11-22  Paul Eggert  <eggert@twinsun.com>
61413
61414         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
61415         hint that one should use `if (! x) abort ();' rather than `assert
61416         (x);', and anyway it's one less thing to worry about configuring.
61417         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
61418         hash_rehash, hash_insert): Use abort rather than assert.
61419
61420 2002-11-22  Bruno Haible  <bruno@clisp.org>
61421
61422         * lib/safe-read.h: Assume C89. Add comments.
61423         (safe_read): Change return type to size_t.
61424         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
61425         byte counts > SSIZE_MAX correctly.
61426         * lib/safe-write.h: New file.
61427         * lib/safe-write.c: New file.
61428         * lib/full-read.h: New file.
61429         * lib/full-read.c: New file.
61430         * lib/full-write.h: Assume C89. Add comments.
61431         * lib/full-write.c: Include safe-write.h.
61432         (full_write): Rewritten to use safe_write.
61433         Suggested by Jim Meyering and Paul Eggert.
61434
61435 2002-11-21  Jim Meyering  <jim@meyering.net>
61436
61437         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
61438
61439         Merge in changes from the coreutils.
61440
61441         2002-09-25  Paul Eggert  <eggert@twinsun.com>
61442         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
61443         <stdint.h>.
61444         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
61445         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
61446         int.  Work more efficiently if X is the same width as uintmax_t.
61447         Do not compare X to -1, to avoid bogus compiler warning.
61448         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
61449         Don't assume that f_frsize and f_bsize are the same type.
61450
61451         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
61452         warning on FreeBSD.
61453
61454         * lib/makepath.c (make_path): Restore umask *before* creating the final
61455         component.
61456         (make_path): Minor reformatting.
61457
61458         * lib/xmalloc.c: Adjust to work with new autoconf macros,
61459         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
61460         HAVE_MALLOC/HAVE_REALLOC.
61461
61462         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
61463         dummy ones.  At least on GNU/Linux systems, `auto' means something
61464         else.
61465         From Michael Stone.
61466
61467 2002-11-21  Bruno Haible  <bruno@clisp.org>
61468
61469         Remove case insensitive option matching.
61470         * lib/argmatch.h (argcasematch): Remove declaration.
61471         (ARGCASEMATCH): Remove macro.
61472         (__xargmatch_internal): Remove case_sensitive argument.
61473         (XARGMATCH): Update.
61474         (XARGCASEMATCH): Remove macro.
61475         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
61476         case_sensitive argument.
61477         (argcasematch): Remove function.
61478         (__xargmatch_internal): Remove case_sensitive argument.
61479         (main): Use XARGMATCH instead of XARGCASEMATCH.
61480
61481         * lib/xmalloc.c: Change compile-time error message. Add comment about
61482         required autoconf version.
61483
61484 2002-11-20  Paul Eggert  <eggert@twinsun.com>
61485
61486         Merge argmatch cleanups from Bison.  Assume C89.
61487
61488         * lib/argmatch.c: Include config.h here, not in argmatch.h.
61489         Include stdlib.h, for EXIT_FAILURE.
61490         Always include <string.h>, since we assume C89.
61491         (EXIT_FAILURE): Remove pre-C89 bug workaround.
61492         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
61493         Include <stddef.h> instead, since it's all we need for size_t.
61494         (PARAMS): Remove.  All uses removed.
61495         (ARRAY_CARDINALITY): Do not bother to #undef.
61496         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
61497         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
61498         Remove unnecessary parentheses.
61499         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
61500         Insert necessary parentheses.
61501         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
61502         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
61503
61504 2002-11-19  Bruno Haible  <bruno@clisp.org>
61505
61506         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
61507         * lib/mbswidth.h: Include <stddef.h>, for size_t.
61508
61509         * lib/mbswidth.h (PARAMS): Remove macro.
61510         (mbswidth, mbsnwidth): Use ANSI C function declarations.
61511         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
61512
61513         * lib/gcd.h (PARAMS): Remove macro.
61514         (gcd): Use ANSI C function declarations.
61515         * lib/gcd.c (gcd): Likewise.
61516
61517 2002-11-15  Bruno Haible  <bruno@clisp.org>
61518
61519         * lib/strcspn.c: Include <stddef.h>.
61520         (strcspn): Use ANSI C function declaration. Change return type to
61521         size_t. Use NULL.
61522         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
61523         (strpbrk): Use NULL.
61524         * lib/strpbrk.h (PARAMS): Remove macro.
61525         (strpbrk): Use ANSI C function declaration.
61526         * lib/strstr.c: Don't include <sys/types.h>.
61527         * lib/strstr.h (PARAMS): Remove macro.
61528         (strstr): Use ANSI C function declarations.
61529
61530 2002-11-14  Karl Berry  <karl@gnu.org>
61531
61532         * config/mkinstalldirs: `do' on separate line, instead of
61533         `for var; do'.
61534
61535 2002-11-06  Bruno Haible  <bruno@clisp.org>
61536
61537         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
61538         * lib/gcd.c (gcd): Likewise.
61539
61540 2002-11-05  Bruno Haible  <bruno@clisp.org>
61541
61542         * lib/gcd.h: New file, from gettext-0.11.5.
61543         * lib/gcd.c: New file, from gettext-0.11.5.
61544
61545 2002-11-05  Bruno Haible  <bruno@clisp.org>
61546
61547         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
61548         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
61549         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
61550         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
61551
61552         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
61553         <libintl.h>.
61554         * lib/makepath.c: Include gettext.h instead of <locale.h> and
61555         <libintl.h>.
61556
61557         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
61558         * lib/human.c: Include gettext.h instead of <libintl.h>.
61559         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
61560         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
61561         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
61562         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
61563         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
61564         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
61565         (textdomain): Remove definition.
61566         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
61567
61568         * lib/long-options.c: Remove include of <libintl.h> and definition of
61569         _.
61570         * lib/same.c: Remove include of <libintl.h> and definition of _.
61571
61572 2002-11-04  Owen Taylor  <otaylor@redhat.com>
61573
61574         * lib/config.charset: A few additions for Solaris.
61575
61576 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
61577
61578         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
61579         * lib/localcharset.c (locale_charset): Declare as extern "C".
61580
61581 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
61582
61583         * lib/config.charset: msdos in uk_UA uses CP1125.
61584
61585 2002-11-04  Bruno Haible  <bruno@clisp.org>
61586
61587         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
61588         * lib/strcase.h: New file, from GNU gettext-0.11.5.
61589         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
61590         * lib/strstr.h: New file, from GNU gettext-0.11.5.
61591         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
61592
61593 2002-11-04  Bruno Haible  <bruno@clisp.org>
61594
61595         * lib/localcharset.c (locale_charset): Don't return an empty string.
61596
61597 2002-11-04  Bruno Haible  <bruno@clisp.org>
61598
61599         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
61600         aliases.
61601
61602 2002-11-04  Bruno Haible  <bruno@clisp.org>
61603
61604         * lib/config.charset: Update for newest glibc. Add canonical names
61605         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
61606
61607 2002-11-04  Bruno Haible  <bruno@clisp.org>
61608
61609         * lib/config.charset: Add support for NetBSD.
61610
61611 2002-11-04  Bruno Haible  <bruno@clisp.org>
61612
61613         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
61614
61615 2002-11-01  Bruno Haible  <bruno@clisp.org>
61616
61617         * configure.in: Add AC_CONFIG_AUX_DIR call.
61618         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
61619         test/Makefile.
61620         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
61621
61622 2002-09-28  Karl Berry  <karl@gnu.org>
61623
61624         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
61625         installed automake until the next release, since changes have been
61626         made.
61627
61628 2002-09-25  Karl Berry  <karl@gnu.org>
61629
61630         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
61631         * lib/getopt*: copy from libc/posix.
61632         * lib/gettext.h: copy from gettext.
61633         * lib/.cppi-disable: add strdup.c, gettext.h.
61634
61635 2002-09-25  Karl Berry  <karl@gnu.org>
61636
61637         * config/srclist.txt: enable gettext.h check.
61638         * config/config.{guess,sub}: update from prep.
61639         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
61640                 from automake 1.6.3.
61641         See srclist*.
61642
61643 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
61644
61645         * regex.c (PATFETCH): Remove the translating fetch.
61646         (PATFETCH_RAW): Rename to PATFETCH.
61647         (set_image_of_range): New fun.
61648         (SET_RANGE_TABLE_WORK_AREA): Use it.
61649         (regex_compile): Don't translate the pattern chars so eagerly.
61650         Only do it when inserting an `exactn' bytecode or when handling
61651         a char-range.
61652         (mutually_exclusive_p): Avoid empty statement.
61653
61654 2002-07-06  Jim Meyering  <meyering@lucent.com>
61655
61656         * m4/README: Don't mention Makefile.am.in.
61657         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
61658
61659 2002-07-01  Jim Meyering  <meyering@lucent.com>
61660
61661         * lib/c-stack.c: Include sys/time.h.
61662         From Volker Borchert.
61663
61664 2002-06-26  Paul Eggert  <eggert@twinsun.com>
61665
61666         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
61667
61668 2002-06-26  Paul Eggert  <eggert@twinsun.com>
61669
61670         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
61671         New macro.  Use it uniformly instead of
61672         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
61673         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
61674         reported by Vin Shelton.
61675
61676 2002-06-22  Paul Eggert  <eggert@twinsun.com>
61677
61678         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
61679         Do not assume SA_SIGINFO behavior.
61680         Bug reported by Jim Meyering on NetBSD 1.5.2.
61681
61682 2002-06-22  Jim Meyering  <meyering@lucent.com>
61683
61684         * m4/c-stack.m4: New file, from diffutils-2.8.2.
61685         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
61686
61687         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
61688         now that configure.ac uses AC_GNU_SOURCE.
61689         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
61690         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
61691
61692         Update to latest tools.  Suggestions from Paul Eggert.
61693         * m4/stdbool.m4: New file, from diffutils-2.8.2.
61694         * m4/gnu-source.m4: Update from diffutils-2.8.2.
61695         * m4/fnmatch.m4: Likewise.
61696         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
61697         to AC_HEADER_STDBOOL
61698
61699 2002-06-22  Jim Meyering  <meyering@lucent.com>
61700
61701         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
61702         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
61703
61704 2002-06-22  Jim Meyering  <meyering@lucent.com>
61705
61706         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
61707
61708         * lib/exitfail.c, exitfail.h: Likewise.
61709         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
61710
61711         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
61712         of fnmatch.h.
61713         (EXTRA_DIST): Add fnmatch_loop.c.
61714         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
61715
61716         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
61717         * lib/fnmatch.c: Update from diffutils-2.8.2.
61718         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
61719         * lib/fnmatch.h: Remove file.
61720
61721 2002-06-21  Jim Meyering  <meyering@lucent.com>
61722
61723         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
61724         * m4/mbrtowc.m4: Likewise.
61725
61726         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
61727         * m4/mbswidth.m4: Reflect name change:
61728         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
61729         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
61730
61731         * m4/lib-link.m4: Update from gettext-0.11.2.
61732         * m4/gettext.m4: Likewise.
61733
61734         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
61735         From Alfred M. Szmidt.
61736
61737 2002-06-18  Paul Eggert  <eggert@twinsun.com>
61738
61739         * lib/file-type.h: Report an error if neither S_ISREG nor
61740         S_IFREG is defined, instead of using a test specific to glibc
61741         2.2.  This should be safe, since POSIX requires S_ISREG and
61742         Unix Version 7 had S_IFREG.  We don't need to check for
61743         <sys/types.h> since we don't use any symbols that it defines.
61744
61745 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
61746
61747         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
61748         $@-t, so that each temporary file name is unique and valid in the first
61749         8 characters, for operation under DOS.
61750
61751 2002-06-15  Paul Eggert  <eggert@twinsun.com>
61752
61753         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
61754
61755 2002-06-15  Jim Meyering  <meyering@lucent.com>
61756
61757         Work even with DJGPP 2.03, which lacks support for symlinks.
61758         From Richard Dawe.
61759         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
61760         is defined.
61761         * lib/lchown.c (S_ISLNK): Likewise.
61762
61763 2002-06-15  Jim Meyering  <meyering@lucent.com>
61764
61765         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
61766         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
61767         have been included before this file.
61768
61769 2002-06-14  Jim Meyering  <meyering@lucent.com>
61770
61771         * lib/file-type.h: Use the version from diffutils-2.8.2.
61772         * lib/file-type.c: Likewise.
61773
61774 2002-06-07  Jim Meyering  <meyering@lucent.com>
61775
61776         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
61777         They're needed at least for NetBSD 1.5.2.
61778         ($statxfs_includes): Include those same headers.
61779         ($statxfs_includes): Include sys/vfs.h if available.
61780         ($statxfs_includes): Likewise for sys/statvfs.h.
61781         Check for the following members in both structs statfs and statvfs:
61782         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
61783
61784 2002-06-01  Jim Meyering  <meyering@lucent.com>
61785
61786         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
61787         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
61788
61789 2002-05-28  Jim Meyering  <meyering@lucent.com>
61790
61791         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
61792         Reported by Volker Borchert.
61793
61794 2002-05-27  Jim Meyering  <meyering@lucent.com>
61795
61796         Fix a problem seen only on nonconforming systems whereby ls.c's
61797         use of localtime, and then of gettimeofday would cause trouble:
61798         the localtime call used to initialize rpl_gettimeofday's save
61799         mechanism would clobber ls's current local time information so
61800         that in any long listing the first file would always be listed
61801         with date 1970-01-01.  Analysis by Volker Borchert.
61802
61803         * lib/gettimeofday.c (localtime): Undefine.
61804         (rpl_localtime): New function.
61805
61806 2002-05-27  Jim Meyering  <meyering@lucent.com>
61807
61808         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
61809         localtime.
61810
61811         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
61812         use the replacement function; it wouldn't resolve at link time.
61813         Reported by Volker Borchert.
61814
61815 2002-05-22  Jim Meyering  <meyering@lucent.com>
61816
61817         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
61818         file-type.h.
61819         * lib/file-type.h: New file.
61820         * lib/file-type.c (file_type): New file/function.  Extracted from
61821         diffutils.
61822
61823 2002-04-30  Jim Meyering  <meyering@lucent.com>
61824
61825         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
61826
61827 2002-04-29  Paul Eggert  <eggert@twinsun.com>
61828
61829         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
61830
61831 2002-04-29  Paul Eggert  <eggert@twinsun.com>
61832
61833         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
61834         Do not check for alloca.h (no longer used) or stdbool.h (was never
61835         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
61836
61837 2002-04-29  Paul Eggert  <eggert@twinsun.com>
61838
61839         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
61840
61841 2002-04-29  Jim Meyering  <meyering@lucent.com>
61842
61843         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
61844         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
61845         Use AC_FUNC_STRNLEN here instead.
61846
61847         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
61848         With autoconf-2.53a, it's part of AC_PROG_CC.
61849
61850 2002-04-28  Paul Eggert  <eggert@twinsun.com>
61851
61852         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
61853         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
61854
61855 2002-04-28  Paul Eggert  <eggert@twinsun.com>
61856
61857         * lib/sig2str.h, lib/sig2str.c: New files.
61858         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
61859
61860 2002-04-28  Paul Eggert  <eggert@twinsun.com>
61861
61862         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
61863         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
61864         of 127, since 64 is the largest conceivable number for ancient
61865         nonstandard hosts.
61866         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
61867
61868 2002-04-28  Jim Meyering  <meyering@lucent.com>
61869
61870         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
61871
61872 2002-04-24  Jim Meyering  <meyering@lucent.com>
61873
61874         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
61875         (jm_PREREQ): Use it.
61876
61877         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
61878         mach/mach.h fcntl.h.
61879         Check for this function: setlocale.
61880
61881 2002-04-24  Jim Meyering  <meyering@lucent.com>
61882
61883         * lib/gettext.h: New file, from Gettext.
61884         * lib/Makefile.am (INCLUDES): Remove -I../intl.
61885         (libfetish_a_SOURCES): Add gettext.h.
61886
61887 2002-04-16  Jim Meyering  <meyering@lucent.com>
61888
61889         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
61890         ut_pid, ut_id, ut_exit.
61891
61892 2002-04-16  Jim Meyering  <meyering@lucent.com>
61893
61894         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
61895         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
61896         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
61897
61898 2002-04-12  Jim Meyering  <meyering@lucent.com>
61899
61900         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
61901         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
61902         existence of the getmntinfo function.  Needed for Darwin 5.3.
61903
61904         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
61905         This is necessary at least on Darwin 5.3.
61906
61907         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
61908         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
61909         strnlen.o in the library, and that makes some versions of ranlib
61910         object.
61911
61912 2002-04-12  Jim Meyering  <meyering@lucent.com>
61913
61914         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
61915
61916 2002-04-09  Jim Meyering  <meyering@lucent.com>
61917
61918         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
61919         to be more precise.  Rather than saying we're checking whether the
61920         function `works', say what we're testing.
61921         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
61922         Reported by Bruno Haible.
61923
61924 2002-03-10  Jim Meyering  <meyering@lucent.com>
61925
61926         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
61927         Suggestion from Santiago Vila.
61928
61929 2002-03-08  Jim Meyering  <meyering@lucent.com>
61930
61931         * lib/rename.c: Mention that this wrapper is needed also on
61932         mips-dec-ultrix4.4 systems.
61933
61934 2002-03-02  Jim Meyering  <meyering@lucent.com>
61935
61936         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
61937         not HAVE_CLOCK_SETTIME.
61938
61939 2002-02-27  Paul Eggert  <eggert@twinsun.com>
61940
61941         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
61942         Check for clock_settime.
61943
61944 2002-02-27  Paul Eggert  <eggert@twinsun.com>
61945
61946         * lib/nanosleep.h: Rename to....
61947         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
61948
61949         * lib/gettime.c: New file.
61950         * lib/settime.c: New file.
61951         * lib/stime.c: Remove.
61952
61953         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
61954         timespec.h.  Remove nanosleep.h.
61955
61956 2002-02-25  Paul Eggert  <eggert@twinsun.com>
61957
61958         * m4/acl.m4: New file.
61959         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
61960         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
61961
61962 2002-02-25  Paul Eggert  <eggert@twinsun.com>
61963
61964         * lib/acl.c, lib/acl.h: New files.
61965         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
61966
61967 2002-02-24  Jim Meyering  <meyering@lucent.com>
61968
61969         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
61970         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
61971         cause trouble.  Reported by Nelson Beebe.
61972
61973 2002-02-23  Paul Eggert  <eggert@twinsun.com>
61974
61975         * lib/path-concat.c (xpath_concat): Reorder code to pacify
61976         compilers that don't know that xalloc_die never returns.
61977
61978 2002-02-20  Jim Meyering  <meyering@lucent.com>
61979
61980         * lib/getdate.c: Regenerate using bison-1.33.
61981
61982 2002-02-17  Jim Meyering  <meyering@lucent.com>
61983
61984         * config/config.guess (main): Don't use `head -1'; it's no longer
61985         portable. Use `sed 1q' instead.
61986
61987 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
61988
61989         * m4/codeset.m4: Upgrade to gettext-0.11.
61990         * m4/gettext.m4: Upgrade to gettext-0.11.
61991         * m4/glibc21.m4: Upgrade to gettext-0.11.
61992         * m4/iconv.m4: Upgrade to gettext-0.11.
61993         * m4/isc-posix.m4: Upgrade to gettext-0.11.
61994         * m4/lcmessage.m4: Upgrade to gettext-0.11.
61995         * m4/lib-ld.m4: New file, from gettext-0.11.
61996         * m4/lib-link.m4: New file, from gettext-0.11.
61997         * m4/lib-prefix.m4: New file, from gettext-0.11.
61998         * m4/progtest.m4: Upgrade to gettext-0.11.
61999
62000 2002-02-15  Paul Eggert  <eggert@twinsun.com>
62001
62002         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
62003         (jm_PREREQ): Use it.
62004
62005 2002-02-15  Paul Eggert  <eggert@twinsun.com>
62006
62007         * lib/posixver.c, lib/posixver.h: New files.
62008         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
62009
62010 2002-02-02  Paul Eggert  <eggert@twinsun.com>
62011             Bruno Haible  <bruno@clisp.org>
62012
62013         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
62014         (fwrite_success_callback): New declaration.
62015         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
62016         print_unicode_char. Call failure callback instead of error.
62017         (fwrite_success_callback): New function.
62018         (exit_failure_callback): New function.
62019         (fallback_failure_callback): New function.
62020         (print_unicode_char): Call unicode_to_mb.
62021
62022 2002-01-26  Jim Meyering  <meyering@lucent.com>
62023
62024         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
62025         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
62026
62027 2002-01-26  Jim Meyering  <meyering@lucent.com>
62028
62029         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
62030
62031 2002-01-22  Paul Eggert  <eggert@twinsun.com>
62032
62033         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
62034
62035 2002-01-22  Jim Meyering  <meyering@lucent.com>
62036
62037         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
62038         Otherwise, some versions of automake would omit the rule that makes
62039         Makefile from Makefile.in.
62040
62041 2002-01-21  Paul Eggert  <eggert@twinsun.com>
62042
62043         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
62044         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
62045         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
62046         (memcoll): Set errno to zero if there is no error.
62047
62048         * lib/quotearg.c (quotearg_buffer_restyled):
62049         Fix bug with quoting buffers containing NUL when backslashing escapes.
62050         This bug was exposed by the other changes in this patch.
62051         (quotearg_n_options): New arg ARGSIZE.
62052         All callers changed.
62053         (quoting_options_from_style): New function.
62054         (quotearg_n_style): Use it.
62055         (quotearg_n_style_mem): New function.
62056
62057         * lib/quotearg.h (quotearg_n_style_mem): New function.
62058
62059 2002-01-19  Jim Meyering  <meyering@lucent.com>
62060
62061         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
62062         Remove useless quotes: DF_PROG="df".
62063         * m4/strnlen.m4: New file.
62064
62065 2002-01-16  Paul Eggert  <eggert@twinsun.com>
62066
62067         * lib/backupfile.c (ISDIGIT): Comment fix.
62068         * lib/getdate.y (ISDIGIT): Likewise.
62069         * lib/posixtm.c (ISDIGIT, year): Likewise.
62070         * lib/strverscmp.c (ISDIGIT): Likewise.
62071         * lib/userspec.c (ISDIGIT): Likewise.
62072
62073 2002-01-16  Jim Meyering  <meyering@lucent.com>
62074
62075         * lib/getdate.y: Add three semicolons, each just before a closing
62076         brace. Bison (as of version 1.31) no longer papers over that mistake.
62077
62078 2002-01-05  Jim Meyering  <meyering@lucent.com>
62079
62080         * lib/version-etc.c (version_etc_copyright): Update copyright year.
62081
62082 2001-12-19  Paul Eggert  <eggert@twinsun.com>
62083
62084         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
62085         not silently exit merely because the output buffer happens to
62086         have nothing pending.
62087
62088 2001-12-18  Paul Eggert  <eggert@twinsun.com>
62089
62090         See the big note in ../ChangeLog.
62091         * lib/human.c (suffixes): Prefer K to k for 1024.
62092         (generate_suffix_backwards): New function.
62093         (human_readable_inexact): Use it.
62094         * lib/xstrtol.c (__xstrtol): If there is no number but there
62095         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
62096         Accept 'K' as well as 'k'.
62097
62098 2001-12-15  Jim Meyering  <meyering@lucent.com>
62099
62100         * lib/regex.h (__restrict_arr): Update from libc.
62101
62102         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
62103         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
62104         (STREQ): Define.
62105
62106 2001-12-14  Jim Meyering  <meyering@lucent.com>
62107
62108         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
62109         Suggestion from Bruno Haible.
62110
62111 2001-12-10  Jim Meyering  <meyering@lucent.com>
62112
62113         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
62114         xrealloc, Instead, include "xalloc.h".
62115         (initbuffer): Don't cast xmalloc return value to char*.
62116         (readline): Reword comment.
62117         Don't cast xrealloc return value to char*
62118         Return NULL, not 0.
62119
62120 2001-12-09  Jim Meyering  <meyering@lucent.com>
62121
62122         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
62123         about `signed and unsigned type in conditional expression'.
62124         * lib/posixtm.c (posix_time_parse): Likewise.
62125
62126         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
62127
62128         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
62129         to avoid a pedantic warning.
62130
62131         * lib/getstr.c: Don't include assert.h.
62132         (getstr): Remove warning-evoking assertions.
62133         Return -1 if offset parameter is out of bounds.
62134         Change the type of a local from int to size_t.
62135
62136         * lib/strftime.c (my_strftime_localtime_r): Include this function
62137         definition in the `#if ! HAVE_TM_GMTOFF' block.
62138
62139         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
62140         Include xalloc.h instead.
62141
62142 2001-12-02  Jim Meyering  <meyering@lucent.com>
62143
62144         * lib/tempname.c: Don't declare getenv, thus reverting the change of
62145         2001-11-18.  It's no longer necessary, now that stdlib.h is always
62146         included.
62147
62148         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
62149         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
62150
62151 2001-11-30  Akim Demaille  <akim@epita.fr>
62152
62153         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
62154         before being defined.
62155
62156 2001-11-27  Paul Eggert  <eggert@twinsun.com>
62157
62158         * lib/quotearg.h (quotearg_n, quotearg_n_style):
62159         First arg is int, not unsigned.
62160         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
62161         (SIZE_MAX, UINT_MAX): New macros.
62162         (quotearg_n_options): Abort if N is negative.
62163         Avoid overflow check on hosts where size_t is 64 bits and int
62164         is 32 bits, as overflow is impossible there.
62165         Fix off-by-one typo that caused unnecessary reallocation.
62166
62167 2001-11-27  Jim Meyering  <meyering@lucent.com>
62168
62169         * lib/tempname.c: Merge with version from libc.
62170         * lib/regex.c: Likewise.
62171
62172         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
62173         systems for which STDC_HEADERS is 0, it was not included, resulting in
62174         a warning about an integer-to-pointer conversion problem with getenv.
62175         Reported by Volker Borchert.
62176
62177 2001-11-26  Jim Meyering  <meyering@lucent.com>
62178
62179         * lib/gtod.h: Remove file.
62180         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
62181         * lib/gettimeofday.c: Don't include gtod.h.
62182         (GTOD_init): Remove function.
62183         (rpl_gettimeofday): Do its job here instead, rather than aborting.
62184         Suggestion from Volker Borchert.
62185
62186 2001-11-23  Jim Meyering  <meyering@lucent.com>
62187
62188         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
62189         it.
62190         * lib/hash.c (struct hash_table): Define it here instead.
62191
62192 2001-11-22  Jim Meyering  <meyering@lucent.com>
62193
62194         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
62195
62196 2001-11-20  Jim Meyering  <meyering@lucent.com>
62197
62198         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
62199         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
62200
62201 2001-11-19  Jim Meyering  <meyering@lucent.com>
62202
62203         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
62204         directory.  Use "conftestXXXXXX" as the template.
62205         Suggestion from Paul Eggert.
62206
62207         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
62208         immediately, so the test doesn't mistakenly hit the max-open-files
62209         limit.
62210
62211 2001-11-18  Paul Eggert  <eggert@twinsun.com>
62212
62213         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
62214         (TEMPORARIES): New macro.
62215         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
62216         removes an artificial limitation (e.g. HP-UX 10.20, where
62217         TMP_MAX is 17576).
62218
62219 2001-11-18  Jim Meyering  <meyering@lucent.com>
62220
62221         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
62222
62223 2001-11-18  Jim Meyering  <meyering@lucent.com>
62224
62225         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
62226         on SunOS 4.
62227
62228         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
62229         files will be created before anything else.
62230
62231 2001-11-17  Paul Eggert  <eggert@twinsun.com>
62232
62233         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
62234         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
62235
62236 2001-11-17  Jim Meyering  <meyering@lucent.com>
62237
62238         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
62239         Prompted by a report from Bob Proulx.
62240
62241         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
62242         Instead, require UTILS_FUNC_MKSTEMP.
62243
62244 2001-11-17  Jim Meyering  <meyering@lucent.com>
62245
62246         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
62247         Now, that's done as part of AC_FUNC_STRTOD.
62248
62249 2001-11-17  Jim Meyering  <meyering@lucent.com>
62250
62251         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
62252         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
62253         rather than group writable.  Patch by Juan F. Codagnone.
62254
62255         * lib/readtokens.c: Remove explicit declarations of xmalloc and
62256         xrealloc, Instead, include "xalloc.h".
62257
62258         * lib/mountlist.c: Include unlocked-io.h after all system headers.
62259         Remove explicit declarations of xmalloc, xrealloc,
62260         and xstrdup.  Instead, include "xalloc.h".
62261
62262         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
62263         unlocked-io.h.
62264         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
62265         Likewise.
62266         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
62267
62268         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
62269         Reported by Padraig Brady.
62270
62271         * lib/mkstemp.c: #undef mkstemp.
62272         Include config.h.
62273         (rpl_mkstemp): Rename from mkstemp.
62274         Protoize.
62275
62276 2001-11-16  Jim Meyering  <meyering@lucent.com>
62277
62278         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
62279         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
62280         determine the amount of total physical memory, use pstat_getstatic.
62281         HPUX-11 doesn't define _SC_PHYS_PAGES.
62282         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
62283         If sysconf couldn't be used to determine the amount of available
62284         physical memory, use both pstat_getstatic and pstat_getdynamic.
62285         Based on a patch from Bob Proulx.
62286
62287 2001-11-10  Jim Meyering  <meyering@lucent.com>
62288
62289         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
62290         (jm_PREREQ): Use it.
62291
62292 2001-11-09  Jim Meyering  <meyering@lucent.com>
62293
62294         * m4/jm-macros.m4: Require autoconf-2.52f.
62295         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
62296         Use these AC_-prefixed names, not the AM_-prefixed ones.
62297
62298         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
62299
62300 2001-11-05  Jim Meyering  <meyering@lucent.com>
62301
62302         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
62303
62304 2001-11-04  Jim Meyering  <meyering@lucent.com>
62305
62306         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
62307         $DEFS.
62308
62309 2001-11-03  Jim Meyering  <meyering@lucent.com>
62310
62311         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
62312         of AC_DEFUN.
62313
62314         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
62315         know the name of the variable in the macro definition.
62316
62317 2001-11-03  Jim Meyering  <meyering@lucent.com>
62318
62319         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
62320         in argmatch_to_argument call.
62321
62322         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
62323         argument.
62324
62325         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
62326         e.g., a fault due to an attempt to free a NULL pointer.
62327
62328 2001-11-01  Jim Meyering  <meyering@lucent.com>
62329
62330         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
62331         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
62332
62333 2001-11-01  Jim Meyering  <meyering@lucent.com>
62334
62335         * lib/dirfd.c, lib/dirfd.h: New files.
62336         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
62337
62338         * lib/hash.c (hash_print) [TESTING]: Clean up.
62339
62340 2001-10-22  Paul Eggert  <eggert@twinsun.com>
62341
62342         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
62343         to avoid a warning if -Wall.
62344
62345 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
62346
62347         * README: New file
62348         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
62349         (per RMS's instructions, this is now the canonical source)
62350         * lgpl/, gpl/: New directories.
62351
62352 2001-10-21  Paul Eggert  <eggert@twinsun.com>
62353
62354         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
62355
62356 2001-10-21  Jim Meyering  <meyering@lucent.com>
62357
62358         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
62359         this code would end up calling gettext even in packages built
62360         with --disable-nls.
62361         * lib/getopt.c (_): Likewise.
62362         * lib/regex.c (_): Likewise.
62363
62364 2001-10-20  Paul Eggert  <eggert@twinsun.com>
62365
62366         * m4/error.m4 (jm_PREREQ_ERROR):
62367         Do not invoke AC_CHECK_FUNCS with strerror_r, as
62368         AC_FUNC_STRERROR_R does that.
62369         Check for strerror declaration.
62370
62371         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
62372         are supposed to have them these days.
62373         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
62374         Merge changes from latest Autoconf CVS.
62375         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
62376         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
62377         POSIX decided to standardize on the int flavor of strerror_r.
62378
62379 2001-10-20  Paul Eggert  <eggert@twinsun.com>
62380
62381         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
62382         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
62383         Use strerror_r that is only a macro, even if it is not a function.
62384         (strerror): Check for HAVE_DECL_STRERROR before declaring.
62385         (private_strerror): Use prototypes, not old-style function definition.
62386         (print_errno_message): New function.
62387         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
62388         char*-flavored one.
62389         (error_tail, error, error_at_line): Use it.
62390
62391 2001-10-11  Jim Meyering  <meyering@lucent.com>
62392
62393         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
62394         and quote_n (1, ... to avoid clobbering a buffer.
62395
62396 2001-10-05  Jim Meyering  <meyering@lucent.com>
62397
62398         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
62399         hash-pjw.h.
62400         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
62401         * lib/hash-pjw.h: New file.
62402
62403 2001-09-30  Jim Meyering  <meyering@lucent.com>
62404
62405         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
62406         `struct fsstat' has the `f_fstypename' member.
62407         Use that to define FS_TYPE, which is now used to make
62408         the getfsstat link test tighter.
62409
62410 2001-09-30  Jim Meyering  <meyering@lucent.com>
62411
62412         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
62413         Include <sys/ucred.h>, for Apple Darwin.
62414         Include sys/mount.h and sys/fs_types.h only if available.
62415         (FS_TYPE): Define.
62416         (read_filesystem_list): Use FS_TYPE.
62417
62418 2001-09-29  Paul Eggert  <eggert@twinsun.com>
62419
62420         * lib/exclude.c (excluded_filename): 0 -> false, since it's
62421         a boolean context.
62422
62423 2001-09-29  Jim Meyering  <meyering@lucent.com>
62424
62425         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
62426         [one-argument getmntent function]): Include stdio.h before mntent.h.
62427         SunOS 4.1.x needs it for the declaration of `FILE'.
62428         Patch by Volker Borchert.
62429
62430         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
62431         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
62432         sys/fs_types.h, and make the link-test for getfsstat guard #include
62433         directives with appropriate #if HAVE_*_H tests so that we can
62434         detect getfsstat on Apple Darwin1.3.7 systems.
62435         Reported by Nelson Beebe.
62436         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
62437
62438 2001-09-28  Paul Eggert  <eggert@twinsun.com>
62439
62440         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
62441         #defines strtoimax.  Also treat the other strto* functions
62442         like strtoimax.
62443
62444         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
62445         Check for strtoul and strtoumax,
62446         as those declarations are made even in the signed case.
62447         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
62448         Likewise, for strtol and strtoimax.
62449
62450 2001-09-28  Paul Eggert  <eggert@twinsun.com>
62451
62452         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
62453         #defines strtoimax.  Also treat the other strto* functions
62454         like strtoimax.
62455
62456         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
62457         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
62458         (strtoimax, strtoumax): Do not declare if already defined as a macro.
62459
62460 2001-09-26  Jim Meyering  <meyering@lucent.com>
62461
62462         Most macros in unlocked-io.h had the wrong number of arguments.
62463         * lib/gen-uio: New script.
62464         (USE_UNLOCKED_IO): Define to 1 if not already defined.
62465         * lib/unlocked-io.hin: Remove file.
62466         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
62467         rather than trying to embed it here.
62468         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
62469         Reported by Padraig Brady.
62470
62471 2001-09-25  Volker Borchert  <bt@teknon.de>
62472
62473         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
62474         `result'.
62475
62476 2001-09-24  Jim Meyering  <meyering@lucent.com>
62477
62478         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
62479
62480 2001-09-23  Jim Meyering  <meyering@lucent.com>
62481
62482         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
62483         instead of the mere test for existence of mntent.h.  The latter
62484         would get a false-positive on AIX 3.4 systems.
62485         In the outer getmntent if-block, don't die if neither of the getmntent
62486         tests succeeds.  Instead, just fall through and continue with the
62487         remaining tests.
62488
62489 2001-09-23  Jim Meyering  <meyering@lucent.com>
62490
62491         * lib/mountlist.c: Remove useless parentheses in #if directives.
62492         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
62493         the deprecated MOUNTED symbol is no longer defined in mntent.h.
62494
62495 2001-09-22  Jim Meyering  <meyering@lucent.com>
62496
62497         * m4/gettext.m4: New file.  From gettext.
62498         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
62499         * m4/progtest.m4: Likewise
62500         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
62501         * m4/glibc21.m4: Likewise.
62502
62503         * m4/libintl.m4: Remove.  No longer used.
62504
62505 2001-09-22  Jim Meyering  <meyering@lucent.com>
62506
62507         * lib/localcharset.c: Update from latest gettext.
62508         * lib/config.charset: Likewise.
62509
62510 2001-09-20  Jim Meyering  <meyering@lucent.com>
62511
62512         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
62513         strtoimax.
62514         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
62515         strtoumax.
62516
62517 2001-09-20  Jim Meyering  <meyering@lucent.com>
62518
62519         * lib/xstrtol.c (strtoimax): Guard declaration with
62520         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
62521         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
62522         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
62523         (strtoumax): Likewise, for completeness (it wasn't necessary).
62524
62525 2001-09-17  Paul Eggert  <eggert@twinsun.com>
62526
62527         * lib/strtoimax.c (HAVE_LONG_LONG):
62528         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
62529         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
62530         to work around bug in IBM C compiler.
62531
62532 2001-09-17  Jim Meyering  <meyering@lucent.com>
62533
62534         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
62535         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
62536         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
62537         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
62538         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
62539         whenever the right hand side need not be expanded by the shell.
62540
62541 2001-09-16  Paul Eggert  <eggert@twinsun.com>
62542
62543         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
62544         library.  It's not correct, as some older glibcs are buggy.
62545         fnmatch wasn't fixed until glibc 2.2.
62546
62547         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
62548         special shell magic here.
62549
62550 2001-09-16  Jim Meyering  <meyering@lucent.com>
62551
62552         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
62553         * m4/jm-macros.m4: Require it.
62554
62555 2001-09-16  Jim Meyering  <meyering@lucent.com>
62556
62557         * lib/mkdir.c: New file.
62558
62559 2001-09-15  Jim Meyering  <meyering@lucent.com>
62560
62561         * m4/jm-macros.m4: Check for help2man.
62562
62563 2001-09-11  Jim Meyering  <meyering@lucent.com>
62564
62565         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
62566         The body, by Paul Eggert, was moved here from configure.in.
62567         * m4/jm-macros.m4: Require UTILS_HOST_OS.
62568
62569 2001-09-04  Paul Eggert  <eggert@twinsun.com>
62570
62571         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
62572         (jm_PREREQ): Use it.
62573
62574 2001-09-04  Paul Eggert  <eggert@twinsun.com>
62575
62576         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
62577         Use ssize_t, not int, to store result of readlink.
62578         Check for ssize_t overflow as well as size_t overflow,
62579         as POSIX says the result of readlink is implementation-defined
62580         when ssize_t overflows.
62581         Remove unnecessary cast to char*.
62582         Use free+malloc instead of realloc, as the storage doesn't need
62583         to be preserved and it's clearer and can be more efficient that way.
62584         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
62585         * lib/xreadlink.h (xreadlink): Update prototype.
62586
62587 2001-09-04  Paul Eggert  <eggert@twinsun.com>
62588
62589         * lib/xgetcwd.c: Revert some of the previous change; intead,
62590         fix the HAVE_GETCWD_NULL code to behave more like the
62591         !HAVE_GETCWD_NULL code used to.
62592
62593         Include "xalloc.h".
62594         (xgetcwd): Do not return NULL when memory is exhausted; instead,
62595         invoke xalloc_die.
62596
62597 2001-09-03  Paul Eggert  <eggert@twinsun.com>
62598
62599         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
62600         sys/param.h, as pathmax.h includes them.
62601
62602 2001-09-03  Paul Eggert  <eggert@twinsun.com>
62603
62604         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
62605         (jm_PREREQ_XGETCWD): New macro.
62606
62607         * m4/getcwd.m4: New file.
62608
62609 2001-09-03  Paul Eggert  <eggert@twinsun.com>
62610
62611         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
62612         like the HAVE_GETCWD_NULL code.
62613         Include pathmax.h if not HAVE_GETCWD.
62614         Do not include xalloc.h.
62615         (INITIAL_BUFFER_SIZE): New symbol.
62616         Do not use xmalloc / xrealloc, since the caller is responsible for
62617         handling errors.  Preserve errno around `free' during failure.
62618         Do not overrun buffer when using getwd.
62619
62620 2001-09-03  Paul Eggert  <eggert@twinsun.com>
62621
62622         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
62623         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
62624         getcwd (NULL, 0).
62625
62626 2001-09-03  Paul Eggert  <eggert@twinsun.com>
62627
62628         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
62629         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
62630         spotted by Jim Meyering.
62631
62632 2001-09-03  Jim Meyering  <meyering@lucent.com>
62633
62634         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
62635         failure.
62636
62637 2001-09-02  Jim Meyering  <meyering@lucent.com>
62638
62639         * lib/error.c: Update from GNU libc.
62640
62641 2001-09-01  Jim Meyering  <meyering@lucent.com>
62642
62643         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
62644         Used by df.
62645
62646 2001-09-01  Jim Meyering  <meyering@lucent.com>
62647
62648         * lib/xreadlink.c: New file.
62649         * lib/xreadlink.h: New file.
62650         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
62651         xreadlink.h.
62652
62653         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
62654         doesn't conflict with sparc Solaris 7's definition in
62655         /usr/include/sys/int_types.h.
62656
62657         * lib/exclude.c: Use `""', not `<>' to #include non-system header
62658         files.
62659         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
62660         and strncasecmp as r-values.  Unixware didn't have declarations.
62661
62662 2001-08-31  Paul Eggert  <eggert@twinsun.com>
62663
62664         * lib/xstrtol.h: Add copyright notice.
62665         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
62666         LONGINT_INVALID_SUFFIX_CHAR.
62667
62668 2001-08-31  Paul Eggert  <eggert@twinsun.com>
62669
62670         * lib/xstrtol.c (strtoimax): New decl.
62671
62672 2001-08-31  Paul Eggert  <eggert@twinsun.com>
62673
62674         * lib/xgetcwd.c: Don't include pathmax.h.
62675         Include stdlib.h and unistd.h if available.
62676         Include xalloc.h.
62677         (xmalloc, xstrdup, free): Remove decls.
62678         (xgetcwd): Don't assume sizes fit in unsigned.
62679         Check for overflow when computing sizes.
62680         Simplify reallocation code.
62681
62682 2001-08-31  Paul Eggert  <eggert@twinsun.com>
62683
62684         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
62685         a directory's st_size can have an arbitrary value, so the old
62686         usage could waste an arbitrary amount of memory.  All uses
62687         changed.
62688         * lib/savedir.h: Update prototype.
62689
62690 2001-08-31  Paul Eggert  <eggert@twinsun.com>
62691
62692         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
62693
62694         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
62695         old strtoimax.c.
62696
62697         Also, make the following further changes to make this file's
62698         configuration more similar to that of strtol.c:
62699         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
62700         (strtoumax, uintmax_t, strtoull, strtol): Remove.
62701         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
62702         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
62703         changed to signed values.
62704
62705         And make the following changes as well:
62706         Fix copyright notice, as 1999 was missing.
62707         (verify): New macro.
62708         (strtoimax): Check sizes at compile-time, not run-time.
62709         Prefer strtol to strtoll if both work.
62710         (main): Remove; it was not that useful and was a pain to maintain.
62711
62712         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
62713
62714 2001-08-31  Jim Meyering  <meyering@lucent.com>
62715
62716         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
62717         Use an initial, malloc'd, buffer of length 128 rather than
62718         a statically allocated one of length 1024.
62719
62720 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62721
62722         Simplify code, partly by assuming autoconf 2.52 semantics.
62723
62724         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
62725
62726         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
62727         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
62728         All uses removed.
62729         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
62730         Move AC_REQUIRE to next-to-top level, to avoid confusion.
62731         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
62732         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
62733         jm_AC_HEADER_INTTYPES_H.
62734         * m4/jm-macros.m4 (jm_MACROS): Likewise.
62735
62736         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
62737
62738         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
62739         Quote first arg of AC_DEFUN.
62740         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
62741         since they are needed to parse the include file even if we need
62742         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
62743         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
62744         but with opposite signedness.
62745
62746 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62747
62748         Merge 'exclude' changes from tar 1.13.22.
62749         This fixes one or two unlikely storage allocation overflow bugs,
62750         but doesn't change user-visible behavior otherwise.
62751
62752 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62753
62754         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
62755         (jm_PREREQ_EXCLUDE): New macro.
62756
62757 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62758
62759         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
62760         tm to be declared.
62761
62762 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62763
62764         * lib/hash.c: Remove '2001' from copyright notice.
62765
62766 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62767
62768         * lib/full-write.h: New file.
62769         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
62770         * lib/full-write.c: Correct credits, as cccp.c no longer
62771         exists and anyway it was so heavily changed from the old cccp
62772         code as to be unrecognizable.  Include full-write.h.
62773         (full_write) Return size_t, with short writes meaning failure.
62774         All callers changed.  This fixes a bug with large buffers
62775         on 64-bit hosts.
62776         * lib/utime.c: Include full-write.h.
62777
62778 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62779
62780         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
62781         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
62782         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
62783         Include if available.
62784         (<xalloc.h>): Include
62785         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
62786         (verify): New macro.  Use it to verify that EXCLUDE macros do not
62787         collide with FNM macros.
62788         (struct patopts): New struct.
62789         (struct exclude): Use it, as exclude patterns now come with options.
62790         (new_exclude): Support above changes.
62791         (new_exclude, add_exclude_file):
62792         Initial size must now be a power of two to simplify overflow checking.
62793         (free_exclude, fnmatch_no_wildcards): New function.
62794         (excluded_filename): No longer requires options arg, as the options
62795         are determined by add_exclude.  Now returns bool, not int.
62796         (excluded_filename, add_exclude):
62797         Add support for the fancy new exclusion options.
62798         (add_exclude, add_exclude_file): Now takes int options arg.
62799         Check for arithmetic overflow when computing sizes.
62800         (add_exclude_file): xrealloc might modify errno, so don't
62801         realloc until after errno might be used.
62802
62803         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
62804         New macros.
62805         (free_exclude): New decl.
62806         (add_exclude, add_exclude_file): Now takes int options arg.
62807         (excluded_filename): No longer requires options arg, as the options
62808         are determined by add_exclude.  Now returns bool, not int.
62809
62810 2001-08-30  Paul Eggert  <eggert@twinsun.com>
62811
62812         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
62813
62814 2001-08-27  Jim Meyering  <meyering@lucent.com>
62815
62816         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
62817
62818         * lib/version-etc.c (N_): Remove definition.
62819         Revert most of last change.
62820         Instead, simply don't mark the `Copyright...' string for translation.
62821         Based on advice from Paul Eggert.
62822
62823         * lib/strtoxmax.c: Tweak comment.
62824
62825 2001-08-26  Jim Meyering  <meyering@lucent.com>
62826
62827         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
62828
62829         * m4/xstrtoimax.m4: New file.
62830         * m4/xstrtoumax.m4: Add comments explaining why we
62831         AC_REPLACE_FUNCS(strtol).
62832
62833 2001-08-26  Jim Meyering  <meyering@lucent.com>
62834
62835         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
62836         of copyright with `%s' so translators don't get an untranslated
62837         message in 2002.
62838         (COPYRIGHT_YEAR): Define.
62839         (version_etc): Use fprintf rather than fputs.
62840         Suggestion from Ulrich Drepper.
62841
62842         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
62843
62844         * lib/strtoll.c: New file, from GNU libc.
62845         * lib/xstrtoimax.c: New file.
62846
62847         * lib/xstrtol.h: Add xstrtoimax.
62848         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
62849         * lib/strtoimax.c: New file.  Likewise, but first define
62850         STRTOUXMAX_SIGNED.
62851
62852         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
62853         ...
62854         * lib/strtoxmax.c: ... then renamed to this.
62855
62856 2001-08-18  Paul Eggert  <eggert@twinsun.com>
62857
62858         * m4/inttypes.m4: Add AC_PREREQ(2.13).
62859         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
62860         (jm_AC_TYPE_INTMAX_T): New macro.
62861         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
62862
62863         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
62864
62865         * m4/longlong.m4: Renamed from ulonglong.m4.
62866         * m4/inttypes.m4: Renamed from inttypes_h.m4.
62867         * m4/uintmax_t.m4: Removed.
62868
62869 2001-08-13  Paul Eggert  <eggert@twinsun.com>
62870
62871         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
62872         Port to Solaris 8, where 'sed' requires a space after the 'r'
62873         command, and where sh dislikes "$/".  Clean up the spacing a bit.
62874         Redirect output to $tmp just once.
62875
62876 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
62877
62878         * lib/addext.c (<errno.h>): Include.
62879         (errno): Declare if not defined.
62880         (addext): Work correctly when pathconf returns -1 and leaves
62881         errno alone because there is no limit.  Also, work even if
62882         pathconf returns a value greater than SIZE_MAX.
62883
62884 2001-08-12  Jim Meyering  <meyering@lucent.com>
62885
62886         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
62887         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
62888         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
62889         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
62890         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
62891         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
62892         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
62893         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
62894         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
62895         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
62896         utime.m4, utimes.m4, xstrtoumax.m4:
62897         Quote the first argument in each use of AC_DEFUN.
62898
62899 2001-08-12  Jim Meyering  <meyering@lucent.com>
62900
62901         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
62902         Simply `return getcwd (NULL, 0);'.
62903         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
62904         Use 1300 as initial value for length, not PATH_MAX.
62905
62906         * lib/pathmax.h: Clean up cpp syntax.
62907
62908 2001-08-12  Jim Meyering  <meyering@lucent.com>
62909
62910         * lib/gettimeofday.c: New file.
62911         * lib/gtod.h: New file.
62912         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
62913
62914 2001-08-05  Jim Meyering  <meyering@lucent.com>
62915
62916         * m4/jm-macros.m4: Require autoconf-2.52.
62917
62918 2001-08-04  Jim Meyering  <meyering@lucent.com>
62919
62920         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
62921         stmt, to get in sync with glibc.
62922
62923 2001-08-03  Paul Eggert  <eggert@twinsun.com>
62924
62925         The following changes are from gettext 0.10.39 as maintained by
62926         Bruno Haible.
62927
62928         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
62929         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
62930         with inverted sense.  All uses changed.
62931
62932         * lib/mbswidth.c: Don't include <limits.h>.
62933         Include <stdlib.h> and <string.h> unconditionally.
62934         (iswcntrl, mbsinit, ISCNTRL): New macros.
62935         (mbsnwidth): Use K&R style function declarations.
62936         Don't bother checking for MB_LEN_MAX == 1, since the compiler
62937         can optimize it when MB_CUR_MAX == 1.
62938         The width of control characters is zero, not 1.
62939
62940 2001-08-03  Paul Eggert  <eggert@twinsun.com>
62941
62942         The following changes are from gettext 0.10.39 as maintained by
62943         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
62944
62945         * m4/codeset.m4: Upgrade to serial AM1.
62946         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
62947         all uses changed.  Quote first arg of AC_DEFUN.
62948         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
62949
62950         * m4/iconv.m4: Upgrade to serial AM2.
62951         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
62952         Add --with-libconv-prefix.
62953         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
62954         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
62955         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
62956         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
62957         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
62958
62959         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
62960         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
62961         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
62962         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
62963         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
62964         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
62965         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
62966         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
62967         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
62968
62969         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
62970         string.h any more.
62971
62972         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
62973         not the default value.
62974
62975         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
62976         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
62977         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
62978         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
62979         Also check for iswcntrl, used for wcwidth fallback.
62980         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
62981         to Autoconf 2.13.
62982
62983 2001-08-03  Jim Meyering  <meyering@lucent.com>
62984
62985         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
62986         as it was in the original.  Reported by Paul Eggert.
62987
62988 2001-07-16  Jim Meyering  <meyering@lucent.com>
62989
62990         * m4/gettimeofday.m4: New file.
62991         Prompted by a report from Bernhard Baehr.
62992
62993 2001-07-15  Jim Meyering  <meyering@lucent.com>
62994
62995         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
62996         stuff. Now it's in ../Makefile.cfg.
62997
62998 2001-07-15  Jim Meyering  <meyering@lucent.com>
62999
63000         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
63001         (BUILT_SOURCES): Add unlocked-io.h.
63002         (io_functions): Define.
63003         (unlocked-io.h): New rule.
63004         (DISTCLEANFILES): Add unlocked-io.h.
63005         (all-local): Depend on unlocked-io.h, to ensure it is created.
63006
63007         * lib/unlocked-io.hin: New file
63008
63009         * lib/regex.c: Update from glibc.
63010
63011 2001-07-05  Jim Meyering  <meyering@lucent.com>
63012
63013         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
63014         recommendation.
63015         (libfetish_a_SOURCES): Put all .h files here instead.
63016         Remove a thus-exposed (better checks in automake) duplicate and
63017         two unnecessary .h files.
63018
63019 2001-07-04  Jim Meyering  <meyering@lucent.com>
63020
63021         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
63022         that generates jm-glibc-io.m4 so that it doesn't trigger any make
63023         distcheck failure.
63024
63025 2001-07-02  Jim Meyering  <meyering@lucent.com>
63026
63027         The following changes were prompted by suggestions from Bruno Haible.
63028
63029         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
63030         is now generated.
63031         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
63032         definition of EXTRA_DIST.
63033         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
63034         ensure that the generated file is created/updated whenever the list
63035         of $(unlocked_functions) is changed.
63036         (jm-glibc-io.m4): New rule.
63037         (unlocked-io.h): New rule -- currently unused.
63038
63039 2001-06-24  Jim Meyering  <meyering@lucent.com>
63040
63041         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
63042         unmatched right bracket, rather than kludging it with an extra,
63043         falsely-matching quote in a comment.  Patch by Akim Demaille.
63044
63045 2001-06-11  Jim Meyering  <meyering@lucent.com>
63046
63047         * lib/regex.c: Update from GNU libc.
63048
63049 2001-05-27  Jim Meyering  <meyering@lucent.com>
63050
63051         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
63052         Check for ut_type in struct utmp.
63053
63054 2001-05-27  Jim Meyering  <meyering@lucent.com>
63055
63056         * lib/readutmp.h (UT_TYPE): Define.
63057
63058 2001-05-24  Jim Meyering  <meyering@lucent.com>
63059
63060         * lib/argmatch.c: Include "quote.h".
63061         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
63062         quote function.  Reported by Göran Uddeborg.
63063
63064 2001-05-22  Jim Meyering  <meyering@lucent.com>
63065
63066         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
63067         now that we use the package-supplied version unconditionally.
63068         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
63069
63070 2001-05-21  Jim Meyering  <meyering@lucent.com>
63071
63072         * m4/regex.m4: Change a couple backticks to single quotes to avoid
63073         shell syntax errors.
63074
63075 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
63076
63077         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
63078
63079 2001-05-20  Paul Eggert  <eggert@twinsun.com>
63080
63081         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
63082         Don't bother to check library strftime, since
63083         we'll be using our own my_strftime function anyway.
63084         Define my_strftime instead of strftime.
63085
63086 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
63087
63088         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
63089         which is not yet declared.
63090
63091 2001-05-15  Jim Meyering  <meyering@lucent.com>
63092
63093         * m4/regex.m4: Use proper quoting so brackets appear in the test
63094         program.
63095         Reported by, and with help from, Bruno Haible.
63096
63097 2001-05-13  Jim Meyering  <meyering@lucent.com>
63098
63099         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
63100         undefined.
63101
63102 2001-05-11  Paul Eggert  <eggert@twinsun.com>
63103
63104         dirname code cleanup.  base_name now behaves more compatibly
63105         with POSIX basename when given file names that have trailing
63106         slashes, and similarly for dir_name.  Add new primitives
63107         base_len and dir_len.  Put the directory-name-related decls
63108         into dirname.h.
63109
63110         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
63111         * lib/backupfile.c (base_name): Likewise.
63112         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
63113         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
63114         * lib/makepath.c (strip_trailing_slashes): Likewise.
63115         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
63116         ISSLASH): Likewise.
63117         * lib/rename.c (strip_trailing_slashes): Likewise.
63118         * lib/same.c (base_name): Likewise.
63119         * lib/stripslash.c (ISSLASH): Likewise.
63120
63121         * lib/addext.c: Include <dirname.h> after size_t is defined.
63122         * lib/backupfile.c: Likewise.
63123
63124         * lib/addext.c (addext): Use base_len to trim redundant
63125         trailing slashes instead of doing it ourselves.
63126         But do not trim the last slash if it is not redundant.
63127
63128         * lib/backupfile.c (find_backup_file_name,
63129         max_backup_version): Use base_len instead of rolling it ourselves.
63130         Handle the case of "" and (on DOS) "C:" correctly.
63131
63132         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
63133         needed. Include <string.h>, <dirname.h>.
63134         (base_name): Allow file names ending in slashes, other than names
63135         that are all slashes.  In this case, return the basename followed
63136         by the slashes.  This is more general, and can be used in places
63137         where the original base_name purposely had an assertion failure.
63138         (base_len): New function.
63139
63140         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
63141         Do not include <assert.h>; no longer needed.
63142         Include xalloc.h.
63143         (memrchr): Remove decl.
63144         (dir_name_r): Remove.
63145         (dir_len): Renamed from dirlen.  All callers changed.
63146         Rewrite in terms of base_name, for simplicity and consistency.
63147         (dir_name): Never return NULL.  All callers changed.
63148         Do not include <stdlib.h> in test program; no longer needed.
63149         return 0; is fine for test program.
63150
63151         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
63152         New macros.
63153         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
63154
63155         * lib/path-concat.c (path_concat): Use base_len to compute
63156         base length, not strlen; this means we cannot rely on memcpy
63157         to null-terminate.
63158
63159         * lib/same.c (STREQ): Remove.
63160         (same_name): Handle the case where the basename ends in trailing '/'.
63161
63162         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
63163         a slash was stripped.  Do not strip the last slash after a
63164         file system prefix.
63165
63166 2001-05-11  Paul Eggert  <eggert@twinsun.com>
63167
63168         * lib/Makefile.am (libfetish_a_SOURCES):
63169         Add strftime.c, since we now compile it on all hosts.
63170
63171         * lib/strftime.c (my_strftime):
63172         Define to nstrftime if emacs, but only if my_strftime is not defined.
63173         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
63174         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
63175         Add one more extra argument: a nanoseconds value.
63176         All uses changed.
63177         (ns): New macro.
63178         (my_strftime function): Add %N format.
63179         (emacs_strftimeu): Renamed from emacs_strftime,
63180         with extra ut argument.
63181
63182 2001-05-09  Paul Eggert  <eggert@twinsun.com>
63183
63184         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
63185
63186 2001-04-21  Jim Meyering  <meyering@lucent.com>
63187
63188         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
63189         doesn't interfere.
63190
63191 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
63192
63193         * m4/ftruncate.m4: Check for chsize.
63194         Link with ftruncate.o unconditionally if ftruncate is missing.
63195         This was required when cross-compiling to i586-mingw32msvc.
63196
63197 2001-04-08  Jim Meyering  <meyering@lucent.com>
63198
63199         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
63200         recomputed; that's necessary when the offset spans a DST transition.
63201         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
63202
63203 2001-04-02  Jim Meyering  <meyering@lucent.com>
63204
63205         * lib/regex.h, regex.c: Update from GNU libc.
63206
63207 2001-03-24  Jim Meyering  <meyering@lucent.com>
63208
63209         * m4/jm-macros.m4: Require autoconf-2.49d.
63210
63211 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
63212
63213         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
63214
63215 2001-03-19  Paul Eggert  <eggert@twinsun.com>
63216
63217         * lib/version-etc.c (version_etc_copyright): Update to 2001.
63218
63219 2001-03-17  Jim Meyering  <meyering@lucent.com>
63220
63221         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
63222         now that the version in autoconf is equivalent.
63223         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
63224
63225         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
63226         Suggestion from Akim Demaille.
63227
63228         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
63229         (jm_PREREQ_TEMPNAME): New function.
63230
63231 2001-03-16  Paul Eggert  <eggert@twinsun.com>
63232
63233         * lib/tempname.c (uint64_t): Define to uintmax_t if
63234         not defined, and if UINT64_MAX is not defined.
63235         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
63236         Reported by John David Anglin.
63237
63238 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
63239
63240         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
63241         resolve alias if codeset is empty.
63242         * lib/config.charset (BeOS): Use wildcard syntax.
63243
63244 2001-03-13  Jim Meyering  <meyering@lucent.com>
63245
63246         * lib/path-concat.c (path_concat)
63247         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
63248         concatenating e.g., `C:' and `foo'.
63249         From Bruno Haible.
63250
63251 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
63252
63253         * lib/localcharset.c (locale_charset): Don't use
63254         setlocale(LC_CTYPE,NULL). Don't return NULL.
63255         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
63256
63257 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
63258
63259         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
63260         support for DOS/DJGPP.
63261
63262 2001-03-01  Paul Eggert  <eggert@twinsun.com>
63263
63264         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
63265         lacks mkstemp.  Compile our own tempname.c if we compile our own
63266         mkstemp.c, as mkstemp relies on tempname.
63267
63268 2001-03-01  Jim Meyering  <meyering@lucent.com>
63269
63270         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
63271         AH_VERBATIM really does output its argument verbatim.
63272
63273 2001-02-28  Paul Eggert  <eggert@twinsun.com>
63274
63275         * lib/Makefile.am (libfetish_a_SOURCES):
63276         Add dup-safer.c, fopen-safer.c.
63277         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
63278
63279         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
63280         * lib/unistd-safer.h: New files.
63281
63282 2001-02-25  Paul Eggert  <eggert@twinsun.com>
63283
63284         The mkstemp replacement is taken from glibc 2.2.2, with some
63285         portability fixes for use outside glibc, as follows:
63286
63287         * lib/tempname.c (struct_stat64): New macro.
63288         (direxists, __gen_tempname): Use it.
63289         This avoids a portability problem with Solaris 8.
63290
63291         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
63292         (<stddef.h>, <stdint.h>, <string.h>):
63293         Include only if STDC_HEADERS || _LIBC.
63294         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
63295         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
63296         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
63297         (__set_errno): Define this macro if <errno.h> doesn't.
63298         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
63299         Define these macros if <stdio.h> doesn't.
63300         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
63301         Define these macros if <sys/stat.h>
63302         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
63303         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
63304         __xstat64): Define if not _LIBC.
63305         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
63306         (__gen_tempname): Invoke gettimeofday only if
63307         HAVE_GETTIMEOFDAY || _LIBC;
63308         otherwise, fall back on plain "time".
63309         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
63310
63311         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
63312
63313         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
63314
63315 2001-02-18  Paul Eggert  <eggert@twinsun.com>
63316
63317         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
63318
63319 2001-02-17  Paul Eggert  <eggert@twinsun.com>
63320
63321         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
63322         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
63323         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
63324         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
63325
63326 2001-02-17  Paul Eggert  <eggert@twinsun.com>
63327
63328         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
63329         Remove workaround macros for hosts that have mbrtowc but not
63330         mbstate_t, as we now insist on proper declarations for both
63331         before using mbrtowc.
63332
63333 2001-02-17  Jim Meyering  <meyering@lucent.com>
63334
63335         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
63336         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
63337         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
63338         UnixWare 7.1.1.
63339
63340         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
63341         rather than AC_CACHE_VAL.
63342
63343 2001-02-17  Jim Meyering  <meyering@lucent.com>
63344
63345         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
63346         around included file name.
63347
63348         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
63349
63350         * lib/strftime.c: Update from GNU libc (the only changes were to
63351         comments).
63352
63353 2001-02-17  Jim Meyering  <meyering@lucent.com>
63354
63355         * lib/regex.c: Update from libc.
63356
63357 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
63358
63359         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
63360         clash.
63361
63362 2001-02-16  Paul Eggert  <eggert@twinsun.com>
63363
63364         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
63365         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
63366         Reported by Mark Hounschell via Paul Eggert.
63367
63368 2001-02-07  Jim Meyering  <meyering@lucent.com>
63369
63370         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
63371
63372 2001-02-05  Jim Meyering  <meyering@lucent.com>
63373
63374         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
63375         it includes the patch required for `large file' support with at least
63376         HP-UX's 10.20 /bin/cc.
63377
63378 2001-02-03  Jim Meyering  <meyering@lucent.com>
63379
63380         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
63381         AS_IF, now that it works once again (mysteriously).
63382         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
63383
63384 2001-01-30  Jim Meyering  <meyering@lucent.com>
63385
63386         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
63387         * m4/chown.m4: Rename conftestchown to conftest.chown.
63388         * m4/rename.m4: s/conftestdir/conftest.d1/ and
63389         s/conftestdir2/conftest.d2/.
63390         * m4/utimes.m4: s/conftestdata/conftest.data/
63391         Inspired by Pavel Roskin's change in autoconf.
63392
63393 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
63394
63395         * lib/config.charset: Update for FreeBSD 4.2.
63396
63397 2001-01-27  Jim Meyering  <meyering@lucent.com>
63398
63399         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
63400         a use of AS_IF.
63401         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
63402
63403 2001-01-26  Jim Meyering  <meyering@lucent.com>
63404
63405         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
63406         quotearg.c includes it.
63407
63408 2001-01-26  Jim Meyering  <meyering@lucent.com>
63409
63410         * lib/quotearg.c: Include stddef.h.
63411         * lib/quote.c: Include stddef.h.
63412         Reported by Axel Kittenberger.
63413
63414         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
63415         line in double quotes so that it evokes a better diagnostic.
63416         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
63417         Reported by Axel Kittenberger.
63418
63419 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
63420
63421         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
63422         as if it was a `charset'.
63423
63424 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
63425
63426         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
63427         has const.
63428
63429 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
63430
63431         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
63432         to avoid a warning.  Add back 'const' to inptr.
63433
63434 2001-01-20  Jim Meyering  <meyering@lucent.com>
63435
63436         Be sure that headers are checked before used in code compiled
63437         for the type checks.
63438         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
63439         In place of that, invoke jm_CHECK_ALL_TYPES.
63440         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
63441         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
63442         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
63443         The check for ssize_t was mistakenly run before the test for unistd.h.
63444
63445         The configure-time check for stdbool.h was missing.
63446         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
63447         (jm_PREREQ_HASH): New function.
63448
63449 2001-01-17  Jim Meyering  <meyering@lucent.com>
63450
63451         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
63452         for autoconf-2.49c.
63453         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
63454
63455 2001-01-16  Jim Meyering  <meyering@lucent.com>
63456
63457         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
63458         From Bruno Haible.
63459
63460 2001-01-14  Jim Meyering  <meyering@lucent.com>
63461
63462         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
63463         foo and bar.  Create conftestdir/ in the script, not in the C code.
63464         Remove directories in the script, not in the C code.
63465         Remove conftestdir{,2} before trying to create the directory.
63466         Make the entire configure script fail if the mkdir fails.
63467
63468 2001-01-14  Jim Meyering  <meyering@lucent.com>
63469
63470         * lib/rename.c: New file.  From Volker Borchert.
63471         Include stdlib.h, string.h or strings.h, and xalloc.h.
63472         Use strip_trailing_slashes rather than open-coding it.
63473
63474 2001-01-03  Paul Eggert  <eggert@twinsun.com>
63475
63476         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
63477
63478 2001-01-03  Jim Meyering  <meyering@lucent.com>
63479
63480         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
63481         of local `inptr' to avoid warning with some system declarations of
63482         iconv.
63483
63484 2001-01-02  Volker Borchert  <bt@teknon.de>
63485
63486         * m4/rename.m4: New file.
63487         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
63488
63489 2001-01-01  Jim Meyering  <meyering@lucent.com>
63490
63491         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
63492         even on systems with utmpx.h.  It's necessary for the declaration of
63493         utmp's ut_user member.  Reported by Andreas Jaeger.
63494
63495         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
63496         available. They are required for the declarations of getgrgid and
63497         getpwuid resp.
63498         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
63499         Reported by Andreas Jaeger.
63500
63501 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
63502
63503         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
63504         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
63505         so `make install' also works in VPATH builds.
63506
63507 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
63508
63509         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
63510         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
63511         can be used in subdirectories.
63512
63513 2000-12-29  Paul Eggert  <eggert@twinsun.com>
63514
63515         * lib/modechange.c: Do not assume that mode_t uses the
63516         traditional octal encoding.  E.g. "chmod 1 FOO" should set
63517         the other-execute bit of FOO even if S_IXOTH != 1.
63518
63519         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
63520         WOTH, XOTH, ALLM): New macros.
63521         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
63522          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
63523         Use them.
63524         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
63525         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
63526         (mode_compile):
63527         No need to use uintmax_t; unsigned long is long enough.
63528         Don't bother to get suffix since we don't use it.
63529
63530 2000-12-26  Jim Meyering  <meyering@lucent.com>
63531
63532         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
63533         better with autoheader.
63534
63535 2000-12-24  Jim Meyering  <meyering@lucent.com>
63536
63537         * lib/hash.c (is_prime): Return explicit boolean values.
63538         (hash_get_first): Return NULL to appease Irix5.6's 89.
63539         Reported by Nelson Beebe.
63540
63541 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
63542
63543         * lib/localcharset.c (locale_charset): Add support for Win32.
63544
63545 2000-12-18  Paul Eggert  <eggert@twinsun.com>
63546
63547         * lib/physmem.h, lib/physmem.c: New files.
63548
63549         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
63550         (noinst_HEADERS): Add physmem.h.
63551
63552         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
63553         't' for compatibility with Solaris 8 sort.
63554
63555 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
63556
63557         * lib/config.charset: Add support for BeOS.
63558
63559 2000-12-17  Jim Meyering  <meyering@lucent.com>
63560
63561         * m4/dos.m4 (jm_AC_DOS): New file and macro.
63562         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
63563
63564 2000-12-16  Jim Meyering  <meyering@lucent.com>
63565
63566         This bug had a serious impact on chown: `chown N:M FILE' (for integer
63567         N and M) would have treated it like `chown N:N FILE'.
63568
63569         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
63570
63571 2000-12-16  Jim Meyering  <meyering@lucent.com>
63572
63573         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
63574         SHELLS_FILE to a file name that's useful on djgpp systems.
63575         Include stdlib.h.
63576         (ADDITIONAL_DEFAULT_SHELLS): Define.
63577         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
63578         Based mostly on a patch from Prashant TR.
63579
63580 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
63581
63582         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
63583         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
63584         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
63585
63586 2000-12-08  Andreas Schwab  <schwab@suse.de>
63587
63588         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
63589         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
63590
63591 2000-12-07  Jim Meyering  <meyering@lucent.com>
63592
63593         * lib/stripslash.c (ISSLASH): Define.
63594         (strip_trailing_slashes): Use ISSLASH rather than comparing against
63595         `/'.
63596         From Prashant TR.
63597
63598         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
63599         (dir_name_r): Declare this function as static.
63600         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
63601         manifest itself on a name containing a mix of slashes and
63602         backslashes.
63603         Make this function work with names starting with a DOS-style
63604         drive letter and colon prefix.
63605         (dir_name): Append `.' if necessary.
63606         Based mostly on patches from Prashant TR and Eli Zaretskii.
63607
63608         * lib/dirname.h (dir_name_r): Remove prototype.
63609
63610 2000-12-06  Paul Eggert  <eggert@twinsun.com>
63611
63612         * m4/off_t-format.m4: Remove this file.
63613         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
63614
63615 2000-12-06  Jim Meyering  <meyering@lucent.com>
63616
63617         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
63618         replacement strtoull, we may well need the replacement strtoul, too.
63619         Check for declarations of strtoul and strtoull.
63620         Check for strtol.  Mainly as a cue to cause automake to include
63621         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
63622         Check for limits.h -- strtol.c needs it.
63623
63624 2000-12-05  Jim Meyering  <meyering@lucent.com>
63625
63626         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
63627
63628 2000-12-04  Jim Meyering  <meyering@lucent.com>
63629
63630         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
63631         Also include memory.h, stdlib.h, unistd.h if appropriate.
63632         Reported by Andreas Jaeger (conflicting declaration of malloc).
63633
63634 2000-12-02  Jim Meyering  <meyering@lucent.com>
63635
63636         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
63637         * m4/jm-macros.m4 (jm_MACROS): require it.
63638
63639 2000-12-02  Jim Meyering  <meyering@lucent.com>
63640
63641         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
63642
63643 2000-12-01  Paul Eggert  <eggert@twinsun.com>
63644
63645         * lib/memrchr.c: Include <config.h> before any system include file.
63646
63647 2000-11-30  Jim Meyering  <meyering@lucent.com>
63648
63649         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
63650
63651 2000-11-30  Jim Meyering  <meyering@lucent.com>
63652
63653         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
63654
63655 2000-11-29  Paul Eggert  <eggert@twinsun.com>
63656
63657         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
63658
63659 2000-11-26  Jim Meyering  <meyering@lucent.com>
63660
63661         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
63662
63663 2000-11-22  Paul Eggert  <eggert@twinsun.com>
63664
63665         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
63666         size of (size_t) -1; it's not portable.
63667
63668 2000-11-17  Jim Meyering  <meyering@lucent.com>
63669
63670         * lib/strstr.c: Update from GNU libc.
63671
63672 2000-11-17  Akim Demaille  <akim@epita.fr>
63673
63674         * lib/obstack.h: Formatting changes.
63675         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
63676         prevent type checking.
63677         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
63678         cast the value to (void *): assigning a `foo *' to a `void *'
63679         variable is valid.
63680         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
63681
63682 2000-11-16  Jim Meyering  <meyering@lucent.com>
63683
63684         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
63685
63686 2000-11-11  Jim Meyering  <meyering@lucent.com>
63687
63688         * lib/error.c: Add a couple #includes, merging from GNU libc version.
63689
63690 2000-11-10  Jim Meyering  <meyering@lucent.com>
63691
63692         * lib/obstack.h: Update from GNU libc.
63693         * lib/obstack.c: Likewise.
63694
63695 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
63696
63697         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
63698
63699 2000-11-06  Paul Eggert  <eggert@twinsun.com>
63700
63701         * lib/getusershell.c (setusershell): Use rewind rather than
63702         fseek/fseeko, to avoid configuration hassles with fseeko.
63703         Don't bother opening SHELLS_FILE if shellstream is NULL;
63704         it's not necessary.
63705
63706 2000-11-05  Jim Meyering  <meyering@lucent.com>
63707
63708         * lib/makepath.h (make_dir): Declare.
63709         * lib/makepath.c (make_dir): Remove `static' attribute.
63710         Tweak a comment.
63711
63712 2000-11-04  Jim Meyering  <meyering@lucent.com>
63713
63714         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
63715
63716 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
63717
63718         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
63719         last one in a bucket, advance to the next bucket.
63720
63721 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
63722
63723         * lib/fnmatch.c: Do not comment out all the code if we are using
63724         the GNU C library, because in some cases we are replacing buggy
63725         code in the GNU C library itself.
63726
63727 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
63728
63729         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
63730         (regex_compile): Catch bogus \(\1\).
63731
63732 2000-10-30  Paul Eggert  <eggert@twinsun.com>
63733
63734         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
63735         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
63736         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
63737
63738 2000-10-30  Paul Eggert  <eggert@twinsun.com>
63739
63740         * lib/error.h, getline.h, modechange.h:
63741         Remove "2000" from Copyright line, as the file hasn't been
63742         changed this year other than in the copyright notice.
63743
63744         * lib/xalloc.h: Add "2000" to Copyright line, as this file
63745         was changed this year.
63746
63747 2000-10-29  Jim Meyering  <meyering@lucent.com>
63748
63749         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
63750         renaming.
63751         * m4/ls-mntd-fs.m4: Likewise
63752
63753 2000-10-29  Jim Meyering  <meyering@lucent.com>
63754
63755         * lib/xstat.in: Fix grammar in comment.
63756
63757 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
63758
63759         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
63760         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
63761         doesn't define __restrict_arr.
63762
63763 2000-10-28  Jim Meyering  <meyering@lucent.com>
63764
63765         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
63766         (jm_PREREQ_MEMCHR): New function.
63767
63768 2000-10-28  Jim Meyering  <meyering@lucent.com>
63769
63770         * lib/memchr.c: Update from libc.
63771         Adjust for portability:
63772         [HAVE_STDLIB_H]: Include stdlib.h.
63773         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
63774         Undef __memchr, too.
63775         [!weak_alias]: Define __memchr to memchr.
63776
63777         * lib/regex.c: Update from libc.
63778         * lib/regex.h: Likewise.
63779         * lib/getopt1.c: Likewise.
63780         * lib/memcmp.c: Likewise.
63781
63782         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
63783         Avoid using fseek, when possible -- it's broken by design.
63784         Patch by Ulrich Drepper.
63785
63786 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
63787
63788         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
63789         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
63790         Giving in to popular pressure to shut up the compiler with casts.
63791
63792 2000-10-26  Jim Meyering  <meyering@lucent.com>
63793
63794         * lib/strftime.c: Update from libc.
63795
63796 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
63797
63798         * regex.c: More `unsigned char' -> `re_char' changes.
63799         Also change several `int' into `re_wchar_t'.
63800         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
63801         (PUSH_FAILURE_POINTER): Don't cast any more.
63802         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
63803         We want GCC to complain, since this piece of code makes
63804         re_match non-reentrant, which *should* be fixed.
63805         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
63806         (EXTEND_BUFFER): Use RETALLOC.
63807         (SET_LIST_BIT): Don't cast.
63808         (re_wchar_t): New type.
63809         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
63810         that those two functions will always properly return.
63811         (IMMEDIATE_QUIT_CHECK): Cast to void.
63812         (analyse_first): Use recursion rather than an explicit stack.
63813         (re_compile_fastmap): Can't fail anymore.
63814         (re_search_2): Don't check re_compile_fastmap for failure.
63815         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
63816         Now also sets the new value (passed in a new argument).
63817         (re_match_2_internal): Use it.
63818         Also, use a new var `reg' of type size_t when looping through regs
63819         rather than reuse the inappropriate `mcnt'.
63820
63821 2000-10-25  Jim Meyering  <meyering@lucent.com>
63822
63823         * lib/obstack.c: Update from libc.
63824
63825 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
63826
63827         * regex.c (regex_compile): Change the way of handling a range from
63828         a char less than 256 to a char not less than 256.
63829
63830 2000-10-24  Andrew Innes  <andrewi@gnu.org>
63831
63832         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
63833         NT-Emacs only.
63834         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
63835         so that re_search functions only quit when callers expect them to.
63836
63837 2000-10-23  Jim Meyering  <meyering@lucent.com>
63838
63839         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
63840         wrong.  That set_locale call must not have any side effects.
63841         From Paul Eggert.
63842
63843 2000-10-22  Jim Meyering  <meyering@lucent.com>
63844
63845         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
63846         [CYCLIC]: Remove now-unused definition.
63847
63848         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
63849         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
63850         Suggestion from Ulrich Drepper.
63851
63852 2000-10-21  Jim Meyering  <meyering@lucent.com>
63853
63854         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
63855         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
63856         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
63857
63858 2000-10-21  Jim Meyering  <meyering@lucent.com>
63859
63860         * lib/dirname.c (memrchr): Declare if necessary.
63861         (dir_name): Remove the restriction that there be no
63862         trailing slashes.  Now, this code skips past them, effectively
63863         ignoring them.
63864         [TEST_DIRNAME] (main): New unit tests.
63865
63866         * lib/memrchr.c: New file from GNU libc.
63867         Undef __memrchr, too.
63868         [!weak_alias]: Define __memrchr to memrchr.
63869         Guard weak_alias use with `#ifdef weak_alias'.
63870
63871 2000-10-21  Jim Meyering  <meyering@lucent.com>
63872
63873         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
63874         (dir_name): Use dir_name_r.
63875         * lib/dirname.h (dir_name_r): Declare it.
63876
63877 2000-10-17  Jim Meyering  <meyering@lucent.com>
63878
63879         * lib/quote.h (PARAMS): Define and use.
63880         Reported by Akim Demaille.
63881
63882         * lib/getopt.c: Update from libc.
63883
63884 2000-10-16  Jim Meyering  <meyering@lucent.com>
63885
63886         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
63887         setlocale.
63888         From Jan Fedak.
63889
63890 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
63891
63892         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
63893
63894 2000-09-25  Jim Meyering  <meyering@lucent.com>
63895
63896         * lib/md5.h (rol): Define (from GnuPG).
63897
63898         * lib/sha.c: Give credit (GnuPG) where due.
63899         (M): Use rol rather than open-coding it.
63900         Add a FIXME comment.
63901
63902 2000-09-21  Jim Meyering  <meyering@lucent.com>
63903
63904         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
63905         Reported by Michael Stone.
63906
63907 2000-09-20  Jim Meyering  <meyering@lucent.com>
63908
63909         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
63910         (noinst_HEADERS): Add sha.h.
63911         Based on code from Scott G. Miller and from GnuPG.
63912
63913 2000-09-18  Jim Meyering  <meyering@lucent.com>
63914
63915         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
63916         LIBS. Otherwise, everyone ends up linking with -lelf for some
63917         configurations.
63918         Reported by Mike Stone.
63919
63920 2000-09-15  Jim Meyering  <meyering@lucent.com>
63921
63922         * lib/regex.c: Update from libc.
63923
63924 2000-09-10  Jim Meyering  <meyering@lucent.com>
63925
63926         * lib/getopt.c (_getopt_internal): Update from glibc.
63927
63928 2000-09-09  Jim Meyering  <meyering@lucent.com>
63929
63930         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
63931         think it should be used as a general replacement for isascii.
63932         * lib/fnmatch.c: Likewise.
63933         * lib/mbswidth.c: Likewise
63934         * lib/regex.c: Likewise.
63935
63936         Don't use atoi.
63937         * lib/userspec.c: Include sys/param.h and limits.h.
63938         Include xstrtol.h.
63939         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
63940         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
63941         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
63942         UID, GID.  Check range.
63943
63944 2000-09-06  Jim Meyering  <meyering@lucent.com>
63945
63946         * lib/getopt.c (_getopt_internal): Update from glibc.
63947
63948 2000-08-30  Jim Meyering  <meyering@lucent.com>
63949
63950         * lib/strftime.c: Merge in changes from GNU libc.
63951
63952 2000-08-26  Jim Meyering  <meyering@lucent.com>
63953
63954         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
63955         * m4/fpending.m4: New file.
63956
63957 2000-08-26  Jim Meyering  <meyering@lucent.com>
63958
63959         * lib/closeout.c: Include "__fpending.h".
63960         (close_stdout_status): Return right away if there's nothing to flush.
63961
63962         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
63963         * lib/__fpending.c: New file.
63964         * lib/__fpending.h: New file.
63965
63966 2000-08-20  Jim Meyering  <meyering@lucent.com>
63967
63968         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
63969         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
63970         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
63971
63972 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
63973
63974         Improve fileutils installation on systems where running
63975         programs (like install) can't be unlinked.
63976         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
63977         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
63978
63979 2000-08-07  Paul Eggert  <eggert@twinsun.com>
63980
63981         Standardize on "memory exhausted" instead of "Memory exhausted"
63982         or "virtual memory exhausted".
63983         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
63984         "virtual memory exhausted".
63985         * lib/same.c (same_name): Invoke xalloc_die instead of printing
63986         our own message.
63987         * lib/userspec.c (parse_user_spec): Likewise.
63988         * lib/bumpalloc.h: comment fix
63989         * lib/same.c, userspec.c: Include xalloc.h.
63990
63991         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
63992         not char *const and pointing to a constant array.
63993         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
63994         (xrealloc): Comment fix.
63995
63996         * lib/userspec.c (parse_user_spec):
63997         Don't translate a message until just before returning,
63998         to avoid unnecessary translation.
63999
64000 2000-08-07  Jim Meyering  <meyering@lucent.com>
64001
64002         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
64003         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
64004         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
64005         getgroups.c, gethostname.c, getopt.h, group-member.c,
64006         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
64007         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
64008         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
64009         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
64010         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
64011         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
64012         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
64013         yesno.c: Back out Copyright date changes for each file with no change
64014         this year.  This eases coordination with other programs using the same
64015         source code modules.  From Paul Eggert.
64016
64017 2000-08-06  Paul Eggert  <eggert@twinsun.com>
64018
64019         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
64020         not char, for compatibility with glibc 2.1.3 strftime.c.
64021
64022 2000-08-03  Greg McGary  <greg@mcgary.org>
64023
64024         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
64025         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
64026         (EXTEND_BUFFER): Use them.
64027
64028 2000-08-01  Jim Meyering  <meyering@lucent.com>
64029
64030         * lib/dirname.c (ISSLASH): Define.
64031         (BACKSLASH_IS_PATH_SEPARATOR): Define.
64032         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
64033         both `\' and `/' may be use as path separators.
64034         Based on a patch from Prashant TR.
64035
64036 2000-07-31  Paul Eggert  <eggert@twinsun.com>
64037
64038         * lib/quotearg.c (quotearg_n_options): Don't make the initial
64039         slot vector a constant, since it might get modified.
64040
64041 2000-07-31  Jim Meyering  <meyering@lucent.com>
64042
64043         * lib/xmalloc.c: Use `virtual memory exhausted', not
64044         `Memory exhausted'.
64045         * lib/obstack.c (print_and_abort): Likewise.
64046
64047 2000-07-30  Paul Eggert  <eggert@twinsun.com>
64048
64049         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
64050         buffer, so that the caller can always quote one small
64051         component of a "memory exhausted" message in slot 0.
64052         From a suggestion by Jim Meyering.
64053
64054 2000-07-30  Jim Meyering  <meyering@lucent.com>
64055
64056         * lib/makepath.c (make_path): Quote the other instance, too.
64057
64058         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
64059         (STATIC_BUF_SIZE): Define.
64060         (quotearg_n_options): Use only statically allocated storage when
64061         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
64062         than STATIC_BUF_SIZE.
64063
64064 2000-07-29  Jim Meyering  <meyering@lucent.com>
64065
64066         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
64067         * lib/dirname.c (dir_name): Likewise.
64068
64069         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
64070         `/'.
64071
64072         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
64073         (dir_name): Assert that there are no trailing slashes.
64074
64075 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
64076
64077         * lib/mbswidth.h (mbswidth): Add a flags argument.
64078         (mbswidth): New declaration.
64079         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
64080         * lib/mbswidth.c (mbswidth): Add a flags argument.
64081         (mbsnwidth): New function.
64082
64083 2000-07-24  Jim Meyering  <meyering@lucent.com>
64084
64085         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
64086
64087 2000-07-23  Paul Eggert  <eggert@twinsun.com>
64088
64089         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
64090
64091 2000-07-23  Paul Eggert  <eggert@twinsun.com>
64092
64093         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
64094         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
64095         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
64096         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
64097         invoke multibyte primitives.
64098
64099 2000-07-23  Paul Eggert  <eggert@twinsun.com>
64100
64101         * lib/quotearg.c:
64102         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
64103         so that mbstate_t is always defined.
64104
64105         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
64106         be 1 in at least one GCC installation, and this configuration
64107         error is likely to be common.  Ignoring MB_LEN_MAX hurts
64108         performance on hosts that have mbrtowc but have only unibyte
64109         locales, but I assume these hosts are rare.
64110
64111 2000-07-23  Paul Eggert  <eggert@twinsun.com>
64112
64113         * lib/mbswidth.c (_XOPEN_SOURCE):
64114         Don't define; this causes problems on Solaris 7.
64115         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
64116
64117 2000-07-23  Jim Meyering  <meyering@lucent.com>
64118
64119         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
64120         too: getgrgid, getpwuid, getuid.
64121
64122 2000-07-23  Jim Meyering  <meyering@lucent.com>
64123
64124         * lib/basename.c (base_name): Add an assertion.
64125
64126 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
64127
64128         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
64129         shadow its mbsinit function.
64130
64131 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
64132
64133         * lib/mbswidth.h: New file.
64134         * lib/mbswidth.c: New file.
64135         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
64136         (noinst_HEADERS): Add mbswidth.h.
64137
64138 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
64139
64140         * lib/config.charset: Add support for FreeBSD. Improve support for
64141         HP-UX and IRIX 6.
64142
64143 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
64144
64145         * m4/mbswidth.m4: New file.
64146         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
64147
64148 2000-07-15  Jim Meyering  <meyering@lucent.com>
64149
64150         * lib/makepath.c: Include quote.h.
64151         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
64152         corresponding argument in a `quote (...)' call.
64153         Give better diagnostics.
64154
64155         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
64156         (noinst_HEADERS): Add quote.h.
64157
64158         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
64159         from tar's src/misc.c.
64160         * lib/quote.h: New file.  Prototypes for same.
64161
64162 2000-07-14  Paul Eggert  <eggert@twinsun.com>
64163
64164         From a suggestion by Bruno Haible.
64165         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
64166         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
64167         to decide whether to define the BeOS workaround macro;
64168         this adjusts to the change to AC_MBSTATE_T.
64169
64170 2000-07-14  Jim Meyering  <meyering@lucent.com>
64171
64172         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
64173         jm_AC_TYPE_UINTMAX_T.
64174
64175 2000-07-13  Paul Eggert  <eggert@twinsun.com>
64176
64177         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
64178
64179         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
64180         quotearg_buffer_restyled): Add support for
64181         clocale_quoting_style.  Undo previous change to
64182         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
64183         and "{RIGHT QUOTATION MARK}" msgids.
64184
64185 2000-07-10  Paul Eggert  <eggert@twinsun.com>
64186
64187         From a suggestion by Bruno Haible.
64188         * m4/mbstate_t.m4 (AC_MBSTATE_T):
64189         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
64190         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
64191         and mbstate_t, to a single-part test that simply defines mbstate_t.
64192         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
64193         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
64194
64195 2000-07-10  Jim Meyering  <meyering@lucent.com>
64196
64197         * m4/strerror_r.m4: Mirror the correction made in autoconf.
64198
64199         * m4/gnu-source.m4: Output to confdefs.h directly.
64200         Suggestion from Akim Demaille.
64201
64202 2000-07-09  Paul Eggert  <eggert@twinsun.com>
64203
64204         The old behavior of quoting `like this' doesn't look good with
64205         newer, ISO-style fonts.  See:
64206         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
64207
64208         Instead, quote "like this" by default.  Let the translator
64209         tailor the locale-specific quoting behavior by providing
64210         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
64211
64212         * lib/quotearg.c (N_): New macro.
64213         (gettext_default): New function.
64214         (quotearg_buffer_restyled): Use
64215         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
64216         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
64217
64218 2000-07-09  Jim Meyering  <meyering@lucent.com>
64219
64220         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
64221         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
64222
64223         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
64224         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
64225
64226 2000-07-09  Jim Meyering  <meyering@lucent.com>
64227
64228         * lib/Most files: Update copyright dates to include 2000.
64229
64230 2000-07-08  Jim Meyering  <meyering@lucent.com>
64231
64232         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
64233         if not defined.
64234         (xgethostname): Remove now-unnecessary #ifdef.
64235         Move declaration of `err' into loop where it's used.
64236
64237 2000-07-05  Paul Eggert  <eggert@twinsun.com>
64238         and Bruno Haible  <haible@clisp.cons.org>
64239
64240         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
64241         only if the test for an object-type mbstate_t fails.  This
64242         prevents us from mistakenly reporting that mbstate_t is a
64243         system object type after we "#define mbstate_t int" to work
64244         around its lack.
64245
64246 2000-07-05  Paul Eggert  <eggert@twinsun.com>
64247         and Bruno Haible  <haible@clisp.cons.org>
64248
64249         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
64250
64251 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
64252
64253         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
64254         to strerror_r.
64255         Include <ctype.h> for use of isalpha.
64256
64257 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
64258
64259         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
64260         by allocating a larger buffer. Test the gethostname return value for
64261         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
64262         returns an error and ENAMETOOLONG isn't defined.
64263
64264 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
64265
64266         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
64267         dimension.
64268
64269 2000-07-04  Jim Meyering  <meyering@lucent.com>
64270
64271         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
64272         of the deprecated AC_CHECKING.
64273
64274 2000-07-04  Jim Meyering  <meyering@lucent.com>
64275
64276         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
64277         Reported by Bruno Haible.
64278
64279 2000-07-04  Jim Meyering  <meyering@lucent.com>
64280
64281         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
64282         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
64283         lacks mbrtowc.
64284
64285 2000-07-03  Paul Eggert  <eggert@twinsun.com>
64286
64287         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
64288         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
64289
64290 2000-07-03  Paul Eggert  <eggert@twinsun.com>
64291         and Bruno Haible  <haible@clisp.cons.org>
64292
64293         * lib/quotearg.c (mbrtowc):
64294         Assign to *pwc, and return 1 only if result is nonzero.
64295         (iswprint): Use ISPRINT when substituting our own mbrtowc.
64296
64297 2000-07-03  Jim Meyering  <meyering@lucent.com>
64298
64299         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
64300
64301 2000-07-03  Jim Meyering  <meyering@lucent.com>
64302
64303         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
64304         This is necessary to get a definition of e.g., UTMP_FILE on
64305         HP-UX 10.20.
64306         From Bob Proulx.
64307
64308 2000-07-02  Jim Meyering  <meyering@lucent.com>
64309
64310         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
64311
64312         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
64313         AC_LIBOBJ(function_name).
64314         * m4/chown.m4: Likewise.
64315         * m4/fnmatch.m4: Likewise.
64316         * m4/ftruncate.m4: Likewise.
64317         * m4/getgroups.m4: Likewise.
64318         * m4/getline.m4: Likewise.
64319         * m4/group-member.m4: Likewise.
64320         * m4/jm-macros.m4: Likewise.
64321         * m4/lstat.m4: Likewise.
64322         * m4/malloc.m4: Likewise.
64323         * m4/memcmp.m4: Likewise.
64324         * m4/nanosleep.m4: Likewise.
64325         * m4/putenv.m4: Likewise.
64326         * m4/realloc.m4: Likewise.
64327         * m4/regex.m4: Likewise.
64328         * m4/stat.m4: Likewise.
64329         * m4/strftime.m4: Likewise.
64330
64331 2000-07-02  Jim Meyering  <meyering@lucent.com>
64332
64333         * lib/quotearg.c (mbstate_t): Don't define here.
64334
64335 2000-07-02  Jim Meyering  <meyering@lucent.com>
64336
64337         * lib/nanosleep.c (SIGCONT): Define if not already defined.
64338
64339 2000-07-01  Jim Meyering  <meyering@lucent.com>
64340
64341         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
64342
64343 2000-07-01  Jim Meyering  <meyering@lucent.com>
64344
64345         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
64346         problem.
64347
64348 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
64349
64350         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
64351         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
64352
64353 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
64354
64355         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
64356         per change in ../m4/ls-mntd-fs.m4.
64357         (read_filesystem_list): Ignore symbolic links.
64358
64359 2000-06-29  Jim Meyering  <meyering@lucent.com>
64360
64361         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
64362         for declaration of strcmp.
64363
64364         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
64365
64366         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
64367         Avoid warning by casting result to `char *' to remove `const'.
64368
64369 2000-06-28  Jim Meyering  <meyering@lucent.com>
64370
64371         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
64372         included by quotearg.c, for which we perform this test.  From
64373         Bruno Haible.
64374
64375 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
64376
64377         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
64378         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
64379         <utmpx.h> exists, put readutmp.o into LIBOBJS.
64380
64381 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
64382
64383         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
64384
64385 2000-06-26  Paul Eggert  <eggert@twinsun.com>
64386
64387         savedir now sets errno on failure and invokes xmalloc to get memory.
64388         Fix a couple of other minor bugs while we're at it.
64389
64390         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
64391         (NAMLEN): Remove macro.
64392         (malloc, realloc): Remove decls.
64393         (stpcpy): Likewise.
64394         ("xalloc.h"): Include.
64395         (NAME_SIZE_DEFAULT): New macro.
64396         (savedir): Use xmalloc / xrealloc to allocate memory.
64397         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
64398         Skip "" directory entries.
64399         Use strlen to calculate directory entry length, since the old method
64400         is rarely used these days and isn't worth supporting.
64401         Don't use a pointer after freeing it.
64402         Check for integer overflow when calculating allocation size.
64403         Use memcpy to copy entries, instead of stpcpy.
64404         Set errno properly when returning NULL.
64405         Check for readdir error.
64406
64407 2000-06-26  Jim Meyering  <meyering@lucent.com>
64408
64409         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
64410
64411 2000-06-25  Jim Meyering  <meyering@lucent.com>
64412
64413         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
64414         Linux header bug when _XOPEN_SOURCE is defined to 500.
64415
64416 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
64417
64418         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
64419         deficiency.
64420
64421 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
64422
64423         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
64424         Include xalloc.h.
64425         Don't include <stdlib.h>.  Don't declare malloc, realloc.
64426
64427 2000-06-24  Jim Meyering  <meyering@lucent.com>
64428
64429         * m4/strerror_r.m4: Revive this file -- to try out an experimental
64430         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
64431         for which strerror does return char*, but which lacks a conveniently
64432         accessible declaration of the function.  If the compile-test says
64433         strerror_r doesn't work, then resort to a `run'-test that works on
64434         BeOS and segfaults on DEC Unix.
64435
64436 2000-06-24  Jim Meyering  <meyering@lucent.com>
64437
64438         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
64439
64440 2000-06-23  Paul Eggert  <eggert@twinsun.com>
64441
64442         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
64443         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
64444
64445 2000-06-23  Paul Eggert  <eggert@twinsun.com>
64446
64447         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
64448         (mbrtowc, mbstate_t): Define substitutes if
64449         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
64450         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
64451         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
64452
64453 2000-06-23  Jim Meyering  <meyering@lucent.com>
64454
64455         * m4/afs.m4: Add missing AC_MSG_RESULT.
64456         Reported by Bruno Haible.
64457
64458         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
64459         Suggestion from Bruno Haible.
64460
64461 2000-06-23  Jim Meyering  <meyering@lucent.com>
64462
64463         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
64464
64465 2000-06-21  Jim Meyering  <meyering@lucent.com>
64466
64467         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
64468
64469 2000-06-21  Jim Meyering  <meyering@lucent.com>
64470
64471         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
64472         (noinst_HEADERS): Add getstr.h.
64473
64474         * lib/getline.c (getstr): Move into a separate file.
64475         * lib/getstr.c (getstr): New file, extracted from getline.c, with
64476         the following changes: new parameter, delim2; both delim[12]
64477         parameters have type `int', not `char'.  The latter would lose
64478         with 8-bit delimiters.
64479         * lib/getstr.h: New file.
64480
64481 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
64482
64483         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
64484         than 1024, return a memory chunk of least possible size, instead
64485         of size PATH_MAX + 2. In the loop, increment the size proportionally.
64486         Use free/xmalloc instead of xrealloc to avoid copying for very long
64487         paths.
64488
64489 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
64490
64491         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
64492         the empty string.
64493
64494 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
64495
64496         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
64497         address, not strdup.  Include <stdlib.h> and don't declare free().
64498
64499 2000-06-19  Jim Meyering  <meyering@lucent.com>
64500
64501         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
64502
64503 2000-06-18  Jim Meyering  <meyering@lucent.com>
64504
64505         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
64506
64507         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
64508         `checking whether...' message to be consistent with that of the
64509         lstat test.
64510
64511 2000-06-18  Jim Meyering  <meyering@lucent.com>
64512
64513         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
64514         Besides, these days every porting target provides a mkdir function.
64515
64516         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
64517         needed. (this snippet comes from src/system.h).
64518
64519 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
64520
64521         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
64522
64523 2000-06-15  Paul Eggert  <eggert@twinsun.com>
64524
64525         * lib/human.c (adjust_value): New function.
64526         (human_readable_inexact): Apply rounding style even when
64527         printing approximate values.
64528
64529 2000-06-14  Paul Eggert  <eggert@twinsun.com>
64530
64531         * lib/human.c (human_readable_inexact): Allow an input block
64532         size that is not a multiple of the output block size, and vice versa.
64533         Reported by Piergiorgio Sartor.
64534
64535 2000-06-14  Paul Eggert  <eggert@twinsun.com>
64536
64537         * lib/getdate.y (get_date): Apply relative times after time
64538         zone indicator, not before.  Reported by Todd A. Jacobs.
64539
64540 2000-06-13  Jim Meyering  <meyering@lucent.com>
64541
64542         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
64543
64544         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
64545
64546 2000-06-12  Paul Eggert  <eggert@twinsun.com>
64547
64548         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
64549
64550 2000-06-12  Jim Meyering  <meyering@lucent.com>
64551
64552         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
64553         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
64554         optional argument.
64555         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
64556         the optional argument, `lib'.
64557
64558 2000-06-08  Jim Meyering  <meyering@lucent.com>
64559
64560         * m4/largefile.m4: Remove file (now that it's part of autoconf).
64561
64562 2000-06-04  Paul Eggert  <eggert@twinsun.com>
64563
64564         Rewrite largefile configuration so that we don't need to run
64565         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
64566         AC_CANONICAL_HOST in configure.in -- jmm]
64567
64568         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
64569         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
64570         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
64571         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
64572         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
64573         All uses changed.
64574         Instead of inspecting the output of getconf, try to compile the
64575         test program without and with the macro definition.
64576         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
64577         for getconf.  Instead, check for the needed flags by compiling
64578         test programs.
64579
64580 2000-06-04  Paul Eggert  <eggert@twinsun.com>
64581
64582         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
64583
64584 2000-06-04  Jim Meyering  <meyering@lucent.com>
64585
64586         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
64587         SunOS 4.1.4 for which gid_t is an unsigned type.
64588
64589 2000-06-03  Jim Meyering  <meyering@lucent.com>
64590
64591         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
64592         now that autoconf requires that.
64593
64594         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
64595         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
64596         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
64597
64598 2000-06-03  Jim Meyering  <meyering@lucent.com>
64599
64600         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
64601
64602 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
64603
64604         * m4/glibc21.m4: New file.
64605         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
64606
64607 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
64608
64609         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
64610         newer, don't install charset.alias.
64611         * lib/config.charset: Change the Linux/glibc rules so they become empty
64612         on glibc-2.1 or newer.
64613
64614 2000-06-02  Jim Meyering  <meyering@lucent.com>
64615
64616         * lib/mountlist.c: Back out last change.  Instead, do this...
64617         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
64618         me_dummy member using the same `ignore'-testing code.
64619         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
64620         fs_type strings.
64621         From Mark D. Roth.
64622
64623 2000-05-29  Jim Meyering  <meyering@lucent.com>
64624
64625         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
64626         mounts with the `ignore' attribute.  Based on a patch from
64627         Mark D. Roth.
64628
64629 2000-05-28  Jim Meyering  <meyering@lucent.com>
64630
64631         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
64632         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
64633         * m4/stat.m4: Likewise.
64634         * m4/lstat.m4: Likewise.
64635         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
64636
64637         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
64638         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
64639
64640 2000-05-26  Jim Meyering  <meyering@lucent.com>
64641
64642         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
64643
64644 2000-05-24  Jim Meyering  <meyering@lucent.com>
64645
64646         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
64647         autoconf requires that.
64648         * m4/lib-check.m4: Likewise.
64649         * m4/jm-macros.m4: Likewise.
64650         * m4/strftime.m4: Likewise.
64651
64652         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
64653         AC_CHECK_DECLS, now that autoconf requires that.
64654
64655 2000-05-22  Jim Meyering  <meyering@lucent.com>
64656
64657         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
64658         * m4/lstat.m4: Likewise.
64659
64660 2000-05-22  Jim Meyering  <meyering@lucent.com>
64661
64662         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
64663
64664 2000-05-20  Jim Meyering  <meyering@lucent.com>
64665
64666         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
64667         (jm_PREREQ): Use it.
64668
64669 2000-05-18  Jim Meyering  <meyering@lucent.com>
64670
64671         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
64672         back, too, since it may have been modified by allocate_entry.
64673         (hash_delete): Rewrite to use neither the assignment operator
64674         nor the comma operator in an if-expression.
64675
64676 2000-05-15  Paul Eggert  <eggert@twinsun.com>
64677
64678         * lib/closeout.c:
64679         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
64680         Remove; no longer needed.
64681         "quotearg.h": Add include.
64682         (file_name): Do not bother to explicitly initialize to NULL; it's less
64683         efficient on some hosts.
64684         (close_stdout_status): Remove test as to whether stdout was already
64685         closed; it breaks for the case "echo x | sort >&-".
64686         Quote file name colons.
64687         Do not assume that _("write error") lacks format strings.
64688
64689 2000-05-15  Jim Meyering  <meyering@lucent.com>
64690
64691         * lib/version-etc.c (version_etc_copyright): Update the copyright
64692         string used in all --version output.
64693
64694 2000-05-14  Jim Meyering  <meyering@lucent.com>
64695
64696         * lib/closeout.c (close_stdout_set_file_name): New function.
64697         (close_stdout_status): Use new file-scoped global.
64698         Return right away if fstat says the stdout file descriptor is invalid.
64699         * lib/closeout.h (close_stdout_set_file_name): Declare.
64700
64701 2000-05-10  Jim Meyering  <meyering@lucent.com>
64702
64703         * lib/closeout.c [default_exit_status]: New file-scoped variable.
64704         (close_stdout_set_status): New function.
64705         * lib/closeout.h (close_stdout_set_status): Declare.
64706
64707 2000-05-09  Jim Meyering  <meyering@lucent.com>
64708
64709         * m4/gettext.m4: Rename this...
64710         * m4/libintl.m4: ...to this.
64711
64712 2000-05-08  Jim Meyering  <meyering@lucent.com>
64713
64714         * lib/long-options.c: Don't include closeout.h.
64715         (parse_long_options): Don't call close_stdout for --version.
64716
64717 2000-05-06  Paul Eggert  <eggert@twinsun.com>
64718
64719         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
64720         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
64721         2.1.3 bug.  This avoids a clash when files like regex.c define
64722         _GNU_SOURCE.
64723
64724 2000-05-06  Jim Meyering  <meyering@lucent.com>
64725
64726         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
64727         (AC_REPLACE_FUNCS): Add strnlen.
64728
64729         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
64730         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
64731
64732         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
64733         AC_SEARCH_LIBS call for nanosleep.
64734         (LIB_NANOSLEEP): Set and AC_SUBST.
64735
64736 2000-05-06  Jim Meyering  <meyering@lucent.com>
64737
64738         * lib/strnlen.c: Undefine __strnlen and strnlen.
64739         [!weak_alias]: Define __strnlen to strnlen.
64740
64741         * lib/atexit.c: New file, from libiberty.
64742
64743 2000-05-06  Jim Meyering  <meyering@lucent.com>
64744
64745         * lib/closeout.c (close_stdout_status): Also check for errors on the
64746         stderr stream.
64747
64748 2000-05-05  Jim Meyering  <meyering@lucent.com>
64749
64750         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
64751         AC_SEARCH_LIBS call for clock_gettime.
64752         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
64753
64754         * m4/search-libs.m4: Update from autoconf.
64755
64756         su doesn't work on Solaris 2.6.
64757         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
64758         <shadow.h>.  Reported by Dragos Harabor.
64759
64760 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
64761
64762         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
64763         memcpy instead of xmalloc, xrealloc, path_concat.
64764         (locale_charset): Treat empty environment variables as absent.
64765         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
64766
64767 2000-05-04  Jim Meyering  <meyering@lucent.com>
64768
64769         * lib/getopt.c: Update from glibc.
64770         * lib/obstack.c: Likewise.
64771         * lib/obstack.h: Likewise.
64772         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
64773         file
64774
64775         * lib/regex.h: Likewise.
64776         * lib/strndup.c: Likewise.
64777         * lib/strnlen.c: New file, from glibc.
64778
64779 2000-05-03  Jim Meyering  <meyering@lucent.com>
64780
64781         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
64782
64783 2000-05-02  Paul Eggert  <eggert@twinsun.com>
64784
64785         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
64786         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
64787         compile-time test, rather than inspecting host and OS, to
64788         decide whether to define _LARGEFILE_SOURCE.
64789
64790 2000-05-01  Jim Meyering  <meyering@lucent.com>
64791
64792         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
64793
64794         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
64795         Based on a patch from Bruno Haible.
64796
64797 2000-05-01  Jim Meyering  <meyering@lucent.com>
64798
64799         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
64800
64801 2000-04-29  Jim Meyering  <meyering@lucent.com>
64802
64803         * lib/path-concat.c: Declare strdup only if it's not defined.
64804         * lib/canon-host.c: Likewise.
64805
64806 2000-04-28  Jim Meyering  <meyering@lucent.com>
64807
64808         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
64809         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
64810         is included first, then limits.h is included by locale.h by libintl.h.
64811         From John David Anglin.
64812
64813 2000-04-25  Jim Meyering  <meyering@lucent.com>
64814
64815         * lib/makepath.c (S_IRWXUGO): Define.
64816         (make_path): Always perform explicit chmod if MODE specifies any
64817         of the `special' permission bits.  Prompted by a bug report against
64818         install from Mate Wierdl and Joost van Baal.
64819
64820 2000-04-18  Jim Meyering  <meyering@lucent.com>
64821
64822         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
64823         (jm_PREREQ): Use it.
64824
64825 2000-04-18  Jim Meyering  <meyering@lucent.com>
64826
64827         * lib/README: New file.
64828
64829         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
64830         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
64831
64832 2000-04-17  Jim Meyering  <meyering@lucent.com>
64833
64834         Get it right :-)
64835         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
64836         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
64837         Suggestion from Akim Demaille.
64838
64839 2000-04-17  Jim Meyering  <meyering@lucent.com>
64840
64841         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
64842         the definition of it to rpl_strftime also defined-away the system's
64843         declaration.
64844
64845 2000-04-15  Jim Meyering  <meyering@lucent.com>
64846
64847         Use `C' to denote so-called `contiguous' files, the same way
64848         that tar does.
64849         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
64850         (ftypelet): Use S_ISCTG.
64851         From Michael Deutschmann.
64852
64853 2000-04-14  Jim Meyering  <meyering@lucent.com>
64854
64855         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
64856         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
64857         clobbered.
64858
64859 2000-04-14  Jim Meyering  <meyering@lucent.com>
64860
64861         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
64862
64863 2000-04-13  Jim Meyering  <meyering@lucent.com>
64864
64865         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
64866         AH_VERBATIM to insert required #ifndef into config.h.in.
64867         Suggestion from Akim Demaille.
64868
64869 2000-04-12  Jim Meyering  <meyering@lucent.com>
64870
64871         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
64872         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
64873         Christian Krackowizer.
64874
64875         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
64876         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
64877         (AC_SYS_LARGEFILE): Require.
64878         (AM_C_PROTOTYPES): Require.
64879
64880 2000-04-08  Jim Meyering  <meyering@lucent.com>
64881
64882         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
64883         names don't conflict.  Reported by Eli Zaretskii.
64884
64885 2000-04-07  Jim Meyering  <meyering@lucent.com>
64886
64887         * lib/putenv.c: Move inclusion of errno.h so it follows that of
64888         sys/types.h, to work around system header problems on AIX 3.2.5.
64889         From Bruno Haible.
64890
64891 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
64892
64893         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
64894         bug.  Deal with the different error behavior of Irix iconv.
64895
64896 2000-04-05  Paul Eggert  <eggert@twinsun.com>
64897
64898         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
64899         IRIX if the installer said otherwise.
64900
64901 2000-04-05  Jim Meyering  <meyering@lucent.com>
64902
64903         Portability tweaks required for ultrix4.3.
64904         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
64905         (jm_CHECK_DECLS): Add getutent to the list of functions.
64906         (_jm_DECL_HEADERS): Add utmpx.h.
64907         From John David Anglin.
64908
64909         * m4/strftime.m4: Back out the 2000-04-02 change.
64910         Instead of that change, simply undefine putenv in the test program.
64911
64912 2000-04-05  Jim Meyering  <meyering@lucent.com>
64913
64914         Portability tweaks required for ultrix4.3.
64915         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
64916         getutent.
64917         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
64918         * lib/canon-host.c: Declare strdup.
64919         * lib/path-concat.c: Likewise.
64920         From John David Anglin.
64921
64922 2000-04-04  Jim Meyering  <meyering@lucent.com>
64923
64924         Be more DOS 8.3-friendly.
64925         * lib/ref-add.sin: Renamed from ref-add.sed.in.
64926         * lib/ref-del.sin: Renamed from ref-del.sed.in.
64927         * lib/Makefile.am: Reflect renaming.
64928         Reported by Eli Zaretskii.
64929
64930         Use a temporary file name that won't clash with `charset.alias'
64931         in the DOS 8.3 name space.
64932         * lib/Makefile.am (charset_tmp): Define.
64933         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
64934         (uninstall-local): Likewise.
64935         Reported by Eli Zaretskii.
64936
64937 2000-04-03  Jim Meyering  <meyering@lucent.com>
64938
64939         * m4/gettext.m4: Fix typo in comment.
64940
64941         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
64942         textutils/configure.in).  Suggestion from Paul Eggert.
64943         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
64944
64945 2000-04-02  Paul Eggert  <eggert@twinsun.com>
64946
64947         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
64948         variable in the shell rather than using putenv, which isn't
64949         portable.  This avoids the configure-time inter-test dependency
64950         on the potentially-renamed putenv function.
64951
64952 2000-03-30  Paul Eggert  <eggert@twinsun.com>
64953
64954         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
64955         before checking struct stat.st_blksize, so that
64956         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
64957
64958 2000-03-29  Paul Eggert  <eggert@twinsun.com>
64959
64960         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
64961         since strftime.c uses HAVE_STRFTIME to decide whether to use
64962         the underlying strftime.
64963
64964 2000-03-29  Paul Eggert  <eggert@twinsun.com>
64965
64966         * lib/time/strftime.c (my_strftime): Make sure we call the system
64967         strftime, not ourselves, when invoking the underlying strftime.
64968
64969 2000-03-24  Jim Meyering  <meyering@lucent.com>
64970
64971         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
64972         (charset_alias): Define.
64973         (install-exec-local): Factor out common code.
64974         (uninstall-local): Split lines longer than 80.
64975         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
64976         (SUFFIXES): Define.
64977         (.sed.in.sed): New rule.  Don't redirect directly to $@.
64978         (CLEANFILES): Add ref-add.sed and ref-del.sed.
64979
64980 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
64981
64982         * lib/config.charset: Output a line containing "Packages using this
64983         file".
64984         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
64985         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
64986         ref-del.sed): New rules.
64987
64988 2000-03-17  Jim Meyering  <meyering@lucent.com>
64989
64990         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
64991         Otherwise, include <strings.h>
64992
64993 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
64994
64995         * lib/unicodeio.c (utf8_wctomb): New function.
64996         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
64997         format instead of in UCS-4 with platform dependent endianness.
64998
64999 2000-03-10  Jim Meyering  <meyering@lucent.com>
65000
65001         * m4/lib-check.m4: Look for getspnam in -lgen, too.
65002         From Marco Franzen.
65003
65004 2000-03-07  Paul Eggert  <eggert@twinsun.com>
65005
65006         * lib/savedir.c (savedir): Work even if directory size is
65007         negative; this can happen with some screwy NFS configurations.
65008
65009 2000-03-06  Jim Meyering  <meyering@lucent.com>
65010
65011         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
65012         if it's NULL (because we ran out of memory).  From Bruno Haible.
65013
65014 2000-03-05  Jim Meyering  <meyering@lucent.com>
65015
65016         * lib/localcharset.c ("path-concat.h"): Include.
65017         (get_charset_aliases): Use path_concat instead of ANSI string
65018         concatenation.
65019
65020         * lib/unicodeio.h (PARAMS): Define.
65021         Use it to guard prototype.
65022
65023 2000-03-04  Jim Meyering  <meyering@lucent.com>
65024
65025         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
65026         for lib/localcharset.c.
65027
65028 2000-03-04  Jim Meyering  <meyering@lucent.com>
65029
65030         * lib/Makefile.am (install-exec-local): Create $(libdir) before
65031         installing into it.
65032         (uninstall-local): Uncomment this rule so `make distcheck' works
65033         once again.
65034
65035         * lib/unicodeio.c (<errno.h>): Include it.
65036         (errno): Declare if not defined.
65037
65038         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
65039
65040         * lib/config.charset: New version, incorporating remarks from a linux
65041         i18n mailing list.  From Bruno Haible.
65042
65043 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
65044
65045         * m4/codeset.m4: New file.
65046         * m4/iconv.m4: New file.
65047         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
65048
65049 2000-03-03  Jim Meyering  <meyering@lucent.com>
65050
65051         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
65052
65053 2000-03-02  Jim Meyering  <meyering@lucent.com>
65054
65055         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
65056         the messages come out on separate lines.
65057
65058         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
65059         rather than jm_CHECK_DECLARATIONS.
65060         * m4/decl.m4: Remove now-unused file.
65061
65062         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
65063         geteuid.
65064
65065 2000-03-02  Jim Meyering  <meyering@lucent.com>
65066
65067         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
65068
65069 2000-03-01  Jim Meyering  <meyering@lucent.com>
65070
65071         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
65072         * lib/unicodeio.c: Likewise.
65073
65074 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
65075
65076         * lib/config.charset: New file.
65077         * lib/localcharset.c: New file.
65078         * lib/unicodeio.h, lib/unicodeio.c: New files.
65079         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
65080         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
65081         (noinst_HEADERS): Add unicodeio.h.
65082         (all-local, install-exec-local, charset.alias): New targets.
65083
65084 2000-02-28  Paul Eggert  <eggert@twinsun.com>
65085
65086         * lib/quotearg.c (ALERT_CHAR): New macro.
65087         (quotearg_buffer_restyled): Use it.
65088
65089 2000-02-27  Jim Meyering  <meyering@lucent.com>
65090
65091         * m4/check-decl.m4: Add getenv to the list.
65092
65093 2000-02-27  Jim Meyering  <meyering@lucent.com>
65094
65095         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
65096         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
65097
65098         * lib/backupfile.c: Guard inclusion of stdlib.h with
65099         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
65100         Declare malloc if needed.
65101
65102         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
65103         `#ifndef HAVE_DECL..'
65104         now that autoconf always defines the HAVE_DECL_ symbols.
65105         * lib/human.c: Likewise.
65106         * lib/same.c: Likewise.
65107         * lib/strtoumax.c: Likewise.
65108
65109         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
65110         declaration check was not run.
65111         * lib/hash.c: Likewise.
65112         * lib/human.c: Likewise.
65113         * lib/same.c: Likewise.
65114         * lib/strtoumax.c: Likewise.
65115
65116         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
65117         `.', then first look up the entire `.'-containing string as a login
65118         name.
65119
65120 2000-02-23  Jim Meyering  <meyering@lucent.com>
65121
65122         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
65123         in place of my hack.
65124
65125 2000-02-18  Paul Eggert  <eggert@twinsun.com>
65126
65127         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
65128         (textint): New typedef.
65129         (parser_control): Member year changed from int to textint.
65130         All uses changed.
65131         (YYSTYPE): Removed; replaced by %union with int and textint members.
65132         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
65133         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
65134         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
65135         (tSNUMBER, tUNUMBER): Now of type <textintval>.
65136         (date, number, to_year): Use width of number in digits, not its value,
65137         to determine whether it's a 2-digit year, or a 2-digit time.
65138         (yylex): Store number of digits of numeric tokens.
65139         Reported by John Kendall.
65140
65141         (parser_control): Changed from struct parser_control to typedef (for
65142         consistency).  All uses changed.
65143
65144         (tID): Removed; not used.
65145         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
65146
65147 2000-02-14  Paul Eggert  <eggert@twinsun.com>
65148
65149         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
65150         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
65151
65152 2000-02-12  Jim Meyering  <meyering@lucent.com>
65153
65154         * lib/userspec.c (ISDIGIT): Define it.
65155         (isdigit): Remove definition.
65156         (is_number): Use ISDIGIT, not isdigit.
65157         <libintl.h>: Include.
65158         (_ and N_): Define.
65159         (parse_user_spec): Mark translatable strings.
65160
65161 2000-02-10  Jim Meyering  <meyering@lucent.com>
65162
65163         With these changes, nanosleep.[ch] are finally enough like the other
65164         lib/* replacement files to compile on a few more losing systems.
65165
65166         * lib/nanosleep.h: Don't include config.h.
65167         Remove prototype from declaration of nanosleep.
65168         (PARAMS): Remove now-unneeded definition.
65169         * lib/nanosleep.c: #undef nanosleep.
65170         (rpl_nanosleep): Rename from nanosleep.
65171
65172 2000-02-10  Jim Meyering  <meyering@lucent.com>
65173
65174         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
65175         gnu_nanosleep to rpl_nanosleep.
65176
65177 2000-02-09  Jim Meyering  <meyering@lucent.com>
65178
65179         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
65180         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
65181
65182 2000-02-08  Akim Demaille  <akim@epita.fr>
65183
65184         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
65185         `[' and `]' and remove uses of `changequote'.
65186         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
65187         (AC_SYS_LARGEFILE): Likewise.
65188         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
65189         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
65190         of changequote.
65191         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
65192         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
65193         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
65194         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
65195
65196 2000-02-05  Jim Meyering  <meyering@lucent.com>
65197
65198         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
65199         Remove explicit use of AC_HEADER_TIME.  It is required by
65200         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
65201         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
65202         in autoconf whereby the expansion of the latter ended up preceding
65203         the expansion of its prerequisite, AC_HEADER_TIME.
65204         Reported by Volker Borchert.
65205
65206 2000-02-03  Jim Meyering  <meyering@lucent.com>
65207
65208         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
65209
65210 2000-02-03  Jim Meyering  <meyering@lucent.com>
65211
65212         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
65213         rather than with `#if HAVE_UTMPNAME'.
65214
65215 2000-02-02  Jim Meyering  <meyering@lucent.com>
65216
65217         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
65218         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
65219         Reported by Eli Zaretskii.
65220
65221 2000-02-01  Jim Meyering  <meyering@lucent.com>
65222
65223         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
65224
65225 2000-01-31  Jim Meyering  <meyering@lucent.com>
65226
65227         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
65228         functions.  Add the time.h and sys/time.h headers along with the
65229         AC_REQUIRE'ment of AC_HEADER_TIME.
65230
65231 2000-01-31  Jim Meyering  <meyering@lucent.com>
65232
65233         * lib/nanosleep.h (nanosleep): Guard declaration with
65234         `#if ! HAVE_DECL_NANOSLEEP'.
65235         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
65236         the declaration in that vendor's sys/timers.h.
65237         Reported by Christian Krackowizer.
65238
65239         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
65240         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
65241         (ISPRINT): Likewise.
65242         Reported by Tom Tromey.
65243
65244 2000-01-30  Jim Meyering  <meyering@lucent.com>
65245
65246         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
65247
65248         * m4/prereq.m4 (utmp_includes): Define.
65249         Check for ut_user and ut_name members in both struct utmpx
65250         and struct utmp.
65251
65252 2000-01-30  Jim Meyering  <meyering@lucent.com>
65253
65254         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
65255         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
65256         header files where only utmpx.ut_user is declared.
65257
65258         * lib/readutmp.h (UT_USER): Define.
65259
65260 2000-01-29  Jim Meyering  <meyering@lucent.com>
65261
65262         * m4/lib-check.m4: New file containing library-related checks from
65263         fileutils and sh-utils (textutils had none).
65264
65265 2000-01-28  Jim Meyering  <meyering@lucent.com>
65266
65267         * m4/perl.m4: Change format of warning message to look more like that
65268         from the missing script.  Suggestion from François Pinard.
65269
65270 2000-01-25  Jim Meyering  <meyering@lucent.com>
65271
65272         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
65273         well as time.h in the compile check.
65274         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
65275         Fix typo in cross-compiling case: s/yes/no/.
65276
65277 2000-01-23  Jim Meyering  <meyering@lucent.com>
65278
65279         * m4/jm-macros.m4: Move df-related tests here from
65280         fileutils/configure.in
65281
65282         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
65283         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
65284
65285         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
65286         s/space/ac_fsusage_space/.
65287         (jm_FILE_SYSTEM_USAGE): Take two parameters.
65288
65289         * m4/ftruncate.m4: New file (derived from part of
65290         fileutils/configure.in).
65291         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
65292         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
65293
65294         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
65295         AC_SUBST these here, rather than just in sh-util/configure.in, so
65296         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
65297         all the same.
65298         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
65299         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
65300         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
65301         (AC_SUBST(POW_LIBM)): Likewise.
65302         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
65303
65304 2000-01-23  Jim Meyering  <meyering@lucent.com>
65305
65306         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
65307         obstack.c.
65308
65309 2000-01-22  Jim Meyering  <meyering@lucent.com>
65310
65311         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
65312
65313         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
65314
65315         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
65316         configure.in
65317         (AC_CHECK_HEADERS): Likewise for sh-utils.
65318         (AC_CHECK_HEADERS): Likewise for textutils.
65319         Merge the three lists of headers.
65320
65321         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
65322         from fileutils' configure.in.
65323
65324         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
65325         code. Moved tests into their own function (_jm_DECL_HEADERS) in
65326         check-decl.m4.
65327
65328         * m4/check-decl.m4: Use #if rather than #ifdef.
65329         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
65330         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
65331         (_jm_DECL_HEADERS): Define new function.
65332         (jm_CHECK_DECLARATIONS): Require it.
65333
65334 2000-01-22  Jim Meyering  <meyering@lucent.com>
65335
65336         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
65337         [! HAVE_DECL_STRTOULL]: Declare strtoull.
65338         Required for some AIX systems.  Reported by Christian Krackowizer.
65339         [TESTING] (main): New function.
65340
65341         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
65342         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
65343         letters.
65344
65345         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
65346         iswprint.
65347
65348         * lib/strverscmp.c (ISDIGIT): Define.
65349         (strverscmp): Use ISDIGIT, not isdigit.
65350
65351 2000-01-19  Jim Meyering  <meyering@lucent.com>
65352
65353         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
65354         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
65355         defines `struct timespec' in <sys/time.h>
65356
65357         * m4/c-bs-a.m4: Remove uses of changequote altogether.
65358         Thanks to Akim for explaining.
65359
65360 2000-01-17  Paul Eggert  <eggert@twinsun.com>
65361
65362         * lib/nanosleep.c (nanosleep):
65363         Don't use SA_INTERRUPT to decide whether to call sigaction, as
65364         POSIX.1 doesn't require SA_INTERRUPT and some systems
65365         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
65366         it's been part of POSIX.1 since day 1 (in 1988).
65367
65368 2000-01-17  Jim Meyering  <meyering@lucent.com>
65369
65370         * lib/interlock: Remove unused file.  Reported by François Pinard.
65371
65372 2000-01-16  Paul Eggert  <eggert@twinsun.com>
65373
65374         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
65375         alert, backslash, formfeed, and vertical tab unnecessarily in
65376         shell quoting style.
65377
65378 2000-01-16  Jim Meyering  <meyering@lucent.com>
65379
65380         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
65381         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
65382         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
65383         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
65384
65385 2000-01-16  Jim Meyering  <meyering@lucent.com>
65386
65387         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
65388         because the latter didn't work.
65389
65390 2000-01-15  Jim Meyering  <meyering@lucent.com>
65391
65392         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
65393         (AC_REPLACE_FUNCS): Add memcpy and memset.
65394         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
65395         Add strpbrk.
65396         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
65397
65398 2000-01-12  Jim Meyering  <meyering@lucent.com>
65399
65400         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
65401         (jm_PREREQ): Use it.
65402         (jm_PREREQ_READUTMP): New macro.
65403         (jm_PREREQ): Use it.
65404
65405 2000-01-11  Paul Eggert  <eggert@twinsun.com>
65406
65407         Quote multibyte characters correctly.
65408         * m4/c-bs-a.m4: New file.
65409         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
65410         (jm_PREREQ): Use it.
65411
65412 2000-01-11  Paul Eggert  <eggert@twinsun.com>
65413
65414         * m4/uintmax_t.m4: Port to autoconf 2.13.
65415
65416 2000-01-08  Jim Meyering  <meyering@ascend.com>
65417
65418         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
65419         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
65420
65421 2000-01-04  Jim Meyering  <meyering@ascend.com>
65422
65423         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
65424         jm_STRUCT_DIRENT_D_TYPE.
65425         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
65426         jm_STRUCT_DIRENT_D_INO.
65427         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
65428         jm_STRUCT_UTIMBUF.
65429         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
65430         renamings.
65431         * m4/utime.m4: Likewise.
65432
65433         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
65434         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
65435
65436 2000-01-03  Paul Eggert  <eggert@twinsun.com>
65437
65438         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
65439         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
65440
65441 2000-01-02  Jim Meyering  <meyering@ascend.com>
65442
65443         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
65444         remember if this is necessary.
65445
65446 1999-12-26  Jim Meyering  <meyering@ascend.com>
65447
65448         * m4/jm-macros.m4: Use it here.
65449         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
65450
65451 1999-12-23  Jim Meyering  <meyering@ascend.com>
65452
65453         * m4/jm-macros.m4: Check for clock_gettime (moved from
65454         fileutils/configure.in)
65455         Check for gettimeofday.
65456
65457 1999-12-20  Jim Meyering  <meyering@ascend.com>
65458
65459         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
65460         autoconf-2.14a-1999-12-20.
65461
65462 1999-12-19  Jim Meyering  <meyering@ascend.com>
65463
65464         * m4/lstat-slash.m4: New file.
65465         * m4/jm-macros.m4: Use the new macro:
65466         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
65467
65468 1999-12-07  Jim Meyering  <meyering@ascend.com>
65469
65470         * m4/perl.m4: Require that File::Compare be available, too.
65471         Too many systems seem to lack it.
65472
65473         * m4/strftime.m4: Add checks for most of the cpp macros tested in
65474         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
65475
65476 1999-11-18  Paul Eggert  <eggert@twinsun.com>
65477
65478         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
65479         problem with the QNX 4.25 shell, which doesn't propagate exit
65480         status of failed commands inside shell assignments.
65481
65482 1999-11-17  Jim Meyering  <meyering@ascend.com>
65483
65484         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
65485
65486 1999-11-07  Jim Meyering  <meyering@ascend.com>
65487
65488         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
65489
65490 1999-11-06  Jim Meyering  <meyering@ascend.com>
65491
65492         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
65493         * m4/jm-macros.m4 (jm_MACROS): Use it here.
65494
65495 1999-11-05  Jim Meyering  <meyering@ascend.com>
65496
65497         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
65498         configure.in of textutils, fileutils, and sh-utils into this one
65499         (shared between those packages) file.
65500         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
65501         AC_STRUCT_ST_BLKSIZE.
65502
65503 1999-11-03  Jim Meyering  <meyering@ascend.com>
65504
65505         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
65506         of AC_CHECK_TYPE checks includes unistd.h.
65507         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
65508         Suggestion from Akim Demaille.
65509
65510 1999-10-30  Jim Meyering  <meyering@ascend.com>
65511
65512         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
65513         m4-quoted string.
65514         * m4/ls-mntd-fs.m4: Likewise.
65515         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
65516         * m4/jm-winsz1.m4: Likewise.
65517
65518         * m4/const.m4: Remove file, since the fix made it into the experimental
65519         version of autoconf.
65520         * m4/mktime.m4: Likewise.
65521
65522         * m4/check-type.m4: Remove file, now that the latest version of
65523         AC_CHECK_TYPE takes a third arg to specify additional #includes.
65524
65525         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
65526         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
65527         AC_CHECK_TYPE.
65528
65529 1999-10-04  Jim Meyering  <meyering@ascend.com>
65530
65531         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
65532
65533 1999-09-22  Paul Eggert  <eggert@twinsun.com>
65534
65535         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
65536         2.95.1 bug with HP-UX 10.20.
65537
65538 1999-09-17  Jim Meyering  <meyering@ascend.com>
65539
65540         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
65541         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
65542         due to missing strdup (against sh-utils-2.0).
65543
65544 1999-08-29  Jim Meyering  <meyering@ascend.com>
65545
65546         * m4/jm-macros.m4: Require jm_BISON.
65547         * m4/bison.m4: New file.
65548
65549 1999-08-17  Paul Eggert  <eggert@twinsun.com>
65550
65551         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
65552         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
65553
65554 1999-08-05  Jim Meyering  <meyering@ascend.com>
65555
65556         * m4/getline.m4: Rename test file from conftestdata to conftest.data
65557         to avoid conflicts with `conftest' on 8+3 filesystems.
65558         Suggestion from Eli Zaretskii.
65559
65560 1999-08-04  Jim Meyering  <meyering@ascend.com>
65561
65562         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
65563         fileutils and sh-utils (textutils's getline test was inadequate).
65564         (AM_FUNC_GETLINE): Run this test.
65565         (AC_CHECK_FUNCS): Check for getdelim.
65566         Reported by Bob Proulx.
65567
65568 1999-08-02  Jim Meyering  <meyering@ascend.com>
65569
65570         * m4/jm-macros.m4: Add a comment.
65571
65572 1999-08-01  Paul Eggert  <eggert@twinsun.com>
65573
65574         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
65575         <inttypes.h> defines strtoumax as a macro (and not as a
65576         function).
65577
65578 1999-08-01  Paul Eggert  <eggert@twinsun.com>
65579
65580         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
65581         that we can shift, multiply and divide unsigned long long
65582         values; Ultrix cc can't do it.
65583
65584 1999-08-01  Paul Eggert  <eggert@twinsun.com>
65585
65586         * m4/mktime.m4: New file, which is a preview of what should appear
65587         in the next public autoconf release.
65588
65589 1999-08-01  Paul Eggert  <eggert@twinsun.com>
65590
65591         * m4/lfs.m4: Remove this file.
65592         * m4/largefile.m4: New file.  It contains the old contents of
65593         lfs.m4, except that all names with prefix AC_LFS have been
65594         changed to use the prefix AC_SYS_LARGEFILE instead, to be
65595         compatible with future autoconf versions.  Also, some minor m4
65596         quoting problems have been fixed.
65597
65598 1999-08-01  Paul Eggert  <eggert@twinsun.com>
65599
65600         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
65601         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
65602         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
65603         and simplify the shell code.
65604
65605 1999-08-01  Jim Meyering  <meyering@ascend.com>
65606
65607         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
65608         m4.
65609
65610 1999-07-20  Jim Meyering  <meyering@ascend.com>
65611
65612         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
65613
65614 1999-07-15  Jim Meyering  <meyering@ascend.com>
65615
65616         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
65617
65618 1999-05-22  Jim Meyering  <meyering@ascend.com>
65619
65620         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
65621
65622 1999-05-20  Jim Meyering  <meyering@ascend.com>
65623
65624         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
65625         Add a colon after each `then' in case $4 is empty.
65626
65627 1999-05-16  Jim Meyering  <meyering@ascend.com>
65628
65629         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
65630
65631 1999-05-10  Jim Meyering  <meyering@ascend.com>
65632
65633         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
65634
65635         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
65636         AC_FUNC_MKTIME.
65637
65638 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
65639
65640         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
65641
65642 1999-05-04  Paul Eggert  <eggert@twinsun.com>
65643
65644         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
65645         not CPPFLAGS, so that linking works correctly in IRIX.
65646
65647 1999-04-30  Paul Eggert  <eggert@twinsun.com>
65648
65649         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
65650
65651 1999-04-20  Paul Eggert  <eggert@twinsun.com>
65652
65653         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
65654         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
65655         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
65656         jm_AC_TYPE_UNSIGNED_LONG_LONG.
65657         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
65658
65659         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
65660
65661 1999-04-20  Jim Meyering  <meyering@ascend.com>
65662
65663         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
65664         AC_REPLACE xstroull if necessary.  From Paul Eggert.
65665         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
65666
65667 1999-04-18  Jim Meyering  <meyering@ascend.com>
65668
65669         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
65670         * m4/jm-macros.m4: Use it.
65671
65672 1999-04-06  Jim Meyering  <meyering@ascend.com>
65673
65674         * m4/strftime.m4: Remove test for %f.
65675
65676 1999-03-29  Jim Meyering  <meyering@ascend.com>
65677
65678         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
65679         superset of the AC_TYPE_* checks in the textutils, fileutils,
65680         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
65681         AC_TYPE_PID_T.
65682
65683 1999-03-28  Jim Meyering  <meyering@ascend.com>
65684
65685         * m4/jm-macros.m4: Define GNU_PACKAGE here.
65686         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
65687         replaced e.g., in the *.sh files of the sh-utils.
65688
65689 1999-03-20  Jim Meyering  <meyering@ascend.com>
65690
65691         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
65692         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
65693         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
65694
65695 1999-03-19  Jim Meyering  <meyering@ascend.com>
65696
65697         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
65698
65699 1999-03-12  Jim Meyering  <meyering@ascend.com>
65700
65701         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
65702
65703 1999-03-07  Jim Meyering  <meyering@ascend.com>
65704
65705         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
65706         declared.
65707
65708 1999-02-17  Jim Meyering  <meyering@ascend.com>
65709
65710         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
65711         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
65712
65713 1999-02-07  Jim Meyering  <meyering@ascend.com>
65714
65715         * m4/group-member.m4: New file -- extracted from sh-utils'
65716         configure.in.
65717
65718         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
65719         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
65720
65721 1999-02-06  Jim Meyering  <meyering@ascend.com>
65722
65723         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
65724         * m4/fnmatch.m4: Likewise.
65725         * m4/getgroups.m4: Likewise.
65726         * m4/lstat.m4: Likewise.
65727         * m4/malloc.m4: Likewise.
65728         * m4/putenv.m4: Likewise.
65729         * m4/realloc.m4: Likewise.
65730         * m4/regex.m4: Likewise.
65731         * m4/stat.m4: Likewise.
65732         * m4/strftime.m4: Likewise.
65733         Suggestion from Alain Magloire.
65734
65735         * m4/chown.m4: Use `.$ac_objext', not `.o'.
65736         * m4/fnmatch.m4: Likewise.
65737         * m4/getgroups.m4: Likewise.
65738         * m4/getline.m4: Likewise.
65739         * m4/lstat.m4: Likewise.
65740         * m4/malloc.m4: Likewise.
65741         * m4/memcmp.m4: Likewise.
65742         * m4/putenv.m4: Likewise.
65743         * m4/realloc.m4: Likewise.
65744         * m4/regex.m4: Likewise.
65745         * m4/stat.m4: Likewise.
65746         * m4/strftime.m4: Likewise.
65747         Suggestion from Alain Magloire.
65748
65749         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
65750         an argument.
65751
65752         * m4/regex.m4: Add a run-time Test for proper operation of
65753         re_compile_pattern.
65754
65755 1999-01-31  Jim Meyering  <meyering@ascend.com>
65756
65757         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
65758
65759 1999-01-30  Jim Meyering  <meyering@ascend.com>
65760
65761         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
65762
65763         * m4/jm-mktime.m4: Make this a wrapper around the official
65764         AM_FUNC_MKTIME rather than my private copy, now that the official one
65765         is up to date.
65766         * m4/mktime.m4: Remove file.
65767
65768         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
65769         * m4/uptime.m4: Likewise.
65770         * m4/uintmax_t.m4: Likewise.
65771
65772 1999-01-28  Jim Meyering  <meyering@ascend.com>
65773
65774         * m4/jm-macros.m4: Use jm_AFS.
65775         * m4/afs.m4: New file (from fileutils' configure.in).
65776
65777         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
65778         * m4/chown.m4: Likewise.
65779         * m4/d-ino.m4: Likewise.
65780         * m4/d-type.m4: Likewise.
65781         * m4/fnmatch.m4: Likewise.
65782         * m4/getgroups.m4: Likewise.
65783         * m4/gettext.m4: Likewise.
65784         * m4/jm-mktime.m4: Likewise.
65785         * m4/jm-winsz2.m4: Likewise.
65786         * m4/lcmessage.m4: Likewise.
65787         * m4/ls-mntd-fs.m4: Likewise.
65788         * m4/malloc.m4: Likewise.
65789         * m4/memcmp.m4: Likewise.
65790         * m4/putenv.m4: Likewise.
65791         * m4/realloc.m4: Likewise.
65792         * m4/st_mtim.m4: Likewise.
65793         * m4/strftime.m4: Likewise.
65794
65795 1999-01-16  Jim Meyering  <meyering@ascend.com>
65796
65797         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
65798         (ARGMATCH_DIE_DECL): Define.
65799
65800 1999-01-12  Jim Meyering  <meyering@ascend.com>
65801
65802         * m4/Makefile.am.in: Rewrite to avoid using fmt.
65803         Reported by Lars Hecking.
65804
65805 1999-01-10  Jim Meyering  <meyering@ascend.com>
65806
65807         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
65808         gross kludge.
65809         * m4/inttypes_h.m4: Likewise.
65810         * m4/lstat.m4: Likewise.
65811         * m4/malloc.m4: Likewise.
65812         * m4/readdir.m4: Likewise.
65813         * m4/realloc.m4: Likewise.
65814         * m4/st_dm_mode.m4: Likewise.
65815         * m4/stat.m4: Likewise.
65816         * m4/utimbuf.m4: Likewise.
65817         * m4/utimes.m4: Likewise.
65818
65819         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
65820         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
65821         comments in config.h.in are meaningful.
65822
65823         * m4/jm-macros.m4: Require autoconf-2.13 here.
65824
65825         * m4/regex.m4: By default, don't use the included regex.c on systems
65826         with glibc 2.  Suggestion from Uli Drepper.
65827
65828 1999-01-02  Jim Meyering  <meyering@ascend.com>
65829
65830         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
65831
65832 1998-12-18  Jim Meyering  <meyering@ascend.com>
65833
65834         * m4/Makefile.am.in (Makefile.am): Simplify rule.
65835         Based on a suggestion from Lars Hecking.
65836
65837 1998-11-16  Paul Eggert  <eggert@twinsun.com>
65838
65839         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
65840
65841 1998-11-16  Jim Meyering  <meyering@ascend.com>
65842
65843         * m4/lfs.m4: Double-quote the `uname...` expression.
65844
65845 1998-11-14  Jim Meyering  <meyering@ascend.com>
65846
65847         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
65848         * m4/stat.m4: Likewise.
65849
65850 1998-11-03  Jim Meyering  <meyering@ascend.com>
65851
65852         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
65853         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
65854
65855 1998-10-18  Jim Meyering  <meyering@ascend.com>
65856
65857         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
65858
65859 1998-10-17  Jim Meyering  <meyering@ascend.com>
65860
65861         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
65862         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
65863         calls for those previously hard-coded headers.  Instead, take a new
65864         parameter.
65865         (jm_CHECK_DECLARATIONS): Reflect interface change.
65866         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
65867         (jm_CHECK_DECL_LOCALTIME_R): New macro.
65868
65869         * m4/mktime.m4: Test for spring-forward gap before long-running test.
65870
65871 1998-10-14  Jim Meyering  <meyering@ascend.com>
65872
65873         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
65874         instead of "TZ=America/Vancouver".  From Paul Eggert.
65875
65876 1998-10-11  Jim Meyering  <meyering@ascend.com>
65877
65878         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
65879         This adds a test for a recently added compatibility fix for mktime.c.
65880         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
65881
65882 1998-09-27  Jim Meyering  <meyering@ascend.com>
65883
65884         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
65885
65886         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
65887         ../configure.in, including a change from Gordon Matzigkeit to allow
65888         cross-compiling for the Hurd.
65889
65890         * m4/glibc.m4: New file/macro to test for the GNU C Library
65891         versions 1 and 2.  From Gordon Matzigkeit.
65892         Indent.
65893
65894 1998-09-21  Jim Meyering  <meyering@ascend.com>
65895
65896         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
65897
65898 1998-08-18  Paul Eggert  <eggert@twinsun.com>
65899
65900         Port nanosecond-resolution times to UnixWare 2.1.2 and
65901         pedantic Solaris 2.6.
65902
65903         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
65904         AC_STRUCT_ST_MTIM.
65905         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
65906         Generate name of ns member, instead of just 1 or undef.
65907         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
65908
65909 1998-08-15  Jim Meyering  <meyering@ascend.com>
65910
65911         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
65912         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
65913         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
65914         instead of jm_TYPE_SSIZE_T.
65915
65916 1998-08-12  Jim Meyering  <meyering@ascend.com>
65917
65918         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
65919
65920 1998-08-02  Jim Meyering  <meyering@ascend.com>
65921
65922         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
65923         in acconfig.h manually.
65924
65925 1998-07-31  Paul Eggert  <eggert@twinsun.com>
65926
65927         * m4/st_mtim.m4: New file.
65928
65929 1998-07-28  Jim Meyering  <meyering@ascend.com>
65930
65931         * m4/utimes.m4: Undef stat.
65932
65933 1998-07-25  Jim Meyering  <meyering@ascend.com>
65934
65935         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
65936         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
65937
65938 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
65939
65940         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
65941         uid and gid actually remain unchanged.
65942
65943 1998-07-07  Jim Meyering  <meyering@ascend.com>
65944
65945         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
65946
65947 1998-07-04  Jim Meyering  <meyering@ascend.com>
65948
65949         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
65950         to prove that this macro can be used in packages without regex.c.
65951
65952 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
65953
65954         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
65955         is to be used.
65956
65957 1998-07-03  Jim Meyering  <meyering@ascend.com>
65958
65959         * m4/gettext.m4: Add -lintl if it's found to be necessary.
65960
65961         * m4/gettext.m4: New file -- from gettext-0.10.35.
65962         * m4/lcmessage.m4: Likewise.
65963         * m4/progtest.m4: Likewise.
65964
65965         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
65966         * m4/jm-macros.m4: Require the new macro.
65967
65968 1998-06-29  Jim Meyering  <meyering@ascend.com>
65969
65970         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
65971         for the definition of NGROUPS (used in a system header included
65972         by sys/mount.h).
65973
65974 1998-06-28  Jim Meyering  <meyering@ascend.com>
65975
65976         * m4/ls-mntd-fs.m4: New file.
65977         * m4/fstypename.m4: New file.
65978
65979         * m4/jm-macros.m4: Require the new macro.
65980         * m4/jm-glibc-io.m4: New file.
65981
65982 1998-05-19  Jim Meyering  <meyering@ascend.com>
65983
65984         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
65985         * m4/lchown.m4: New file.
65986
65987         * m4/Makefile.am.in: New file.
65988         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
65989
65990 1998-05-14  Jim Meyering  <meyering@ascend.com>
65991
65992         * m4/Makefile.am (EXTRA_DIST): Add them.
65993         * m4/jm-macros.m4: New file.
65994         * m4/utimbuf.m4: New file.
65995
65996 1998-05-12  Jim Meyering  <meyering@ascend.com>
65997
65998         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
65999
66000 1998-05-11  Jim Meyering  <meyering@ascend.com>
66001
66002         * m4/isc-posix.m4: New file.
66003
66004 1998-05-10  Jim Meyering  <meyering@ascend.com>
66005
66006         * m4/jm-mktime.m4: Use AM_FUNC_MKTIME, now that it's up to date.
66007
66008 1998-05-09  Jim Meyering  <meyering@ascend.com>
66009
66010         * m4/Makefile.am (EXTRA_DIST): Add ssize_t.m4.
66011         (EXTRA_DIST): Remove mktime.m4, now that the new version is included
66012         with automake.
66013
66014         * m4/ssize_t.m4: New file.
66015         * m4/mktime.m4: Remove file -- the new automake has this now.
66016
66017 1998-04-26  Jim Meyering  <meyering@ascend.com>
66018
66019         * m4/assert.m4: New file.
66020         * m4/Makefile.am (EXTRA_DIST): Add assert.m4.
66021
66022 1998-04-05  Jim Meyering  <meyering@ascend.com>
66023
66024         * m4/prereq.m4 (jm_PREREQ_REGEX): New macro.
66025         (jm_PREREQ): Use it here.
66026
66027 1998-03-23  Jim Meyering  <meyering@eng.ascend.com>
66028
66029         * m4/inttypes_h.m4: Kludges so I don't have to add HAVE_INTTYPES_H
66030         in acconfig.h.
66031
66032 1998-03-15  Jim Meyering  <meyering@eng.ascend.com>
66033
66034         * m4/prereq.m4: New file.
66035         * m4/error.m4: New file.
66036         * m4/Makefile.am (EXTRA_DIST): Add error.m4 and prereq.m4.
66037
66038 1998-02-07  Jim Meyering  <meyering@eng.ascend.com>
66039
66040         * m4/getline.m4: Don't set am_cv_func_working_getline before the
66041         cache-check for the same variable -- that defeated the purpose of
66042         the test; the test program was never run.  This was a problem only
66043         on systems with losing getline functions -- HP-UX 10.20 is one.
66044         Reported by Bjorn Helgaas.
66045
66046 1998-02-06  Jim Meyering  <meyering@eng.ascend.com>
66047
66048         * m4/Makefile.am (EXTRA_DIST): Add perl.m4.
66049
66050 1998-01-10  Jim Meyering  <meyering@na-net.ornl.gov>
66051
66052         * m4/Makefile.am (EXTRA_DIST): Add const.m4.
66053
66054         * m4/const.m4: New file.  Use an initializer in this declaration
66055         typedef int charset[2]; const charset x;
66056         Reported by Bob Glickstein.
66057
66058 1997-12-21  Jim Meyering  <meyering@na-net.ornl.gov>
66059
66060         * m4/chown.m4: Fix reversed types on -1 args to chown.
66061         From Kaveh Ghazi.
66062
66063 1997-12-14  Jim Meyering  <meyering@na-net.ornl.gov>
66064
66065         * m4/check-decl.m4: s/DECLARATION_/DECL_/g.
66066         Add lseek and memchr.
66067
66068         * m4/decl.m4: s/HAVE_DECLARATION_/HAVE_DECL_/g.
66069         T.E.Dickey <dickey@clark.net> said that some older preprocessors
66070         have a 20-character limit on names.
66071
66072 1997-11-30  Jim Meyering  <meyering@na-net.ornl.gov>
66073
66074         * m4/inttypes_h.m4: New file.
66075         * m4/uintmax_t.m4: New file.
66076         * m4/Makefile.am (EXTRA_DIST): Add inttypes_h.m4 and uintmax_t.m4.
66077
66078
66079         -----
66080
66081         Local Variables:
66082         coding: utf-8
66083         End:
66084
66085         Copyright (C) 1997-2010 Free Software Foundation, Inc.
66086
66087         Copying and distribution of this file, with or without
66088         modification, are permitted provided the copyright notice
66089         and this notice are preserved.