* lib/allocsa.h (safe_alloca): Avoid compiler warning.
[gnulib.git] / ChangeLog
1 2007-05-28  Eric Blake  <ebb9@byu.net>
2
3         * lib/allocsa.h (safe_alloca): Avoid compiler warning.
4
5 2007-05-28  Bruno Haible  <bruno@clisp.org>
6
7         * modules/fseek-tests: New file.
8         * tests/test-fseek.c: New file, based on tests/test-fseeko.c.
9         * tests/test-fseek.sh: New file, based on tests/test-fseeko.sh.
10
11         * lib/fseek.c: New file.
12         * modules/fseek: New file.
13         * m4/fseek.m4: New file.
14         * doc/functions/fseek.texi: Update.
15         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEK,
16         REPLACE_FSEEK.
17         * lib/stdio_.h (rpl_fseek): New declaration.
18         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEK,
19         REPLACE_FSEEK.
20
21 2007-05-28  Bruno Haible  <bruno@clisp.org>
22
23         * lib/stdio_.h (fflush): More comments.
24
25 2007-05-28  Bruno Haible  <bruno@clisp.org>
26
27         * m4/lseek.m4 (gl_FUNC_LSEEK): When not cross-compiling, perform a real
28         runtime test.
29
30 2007-05-28  Eric Blake  <ebb9@byu.net>
31
32         Improve lseek module.
33         * lib/lseek.c (rpl_lseek): Detect EBADF on mingw.
34         * lib/unistd_.h (lseek): Scale back link warning message.
35         * tests/test-lseek.c: Beef up test.
36         * tests/test-lseek.sh: Exercise more facets of lseek.
37         Reported by Bruno Haible.
38
39 2007-05-28  Bruno Haible  <bruno@clisp.org>
40
41         * tests/test-unistd.c: Test all the types that <unistd.h> is expected
42         to define.
43
44 2007-05-27  Bruno Haible  <bruno@clisp.org>
45
46         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-31 patch.
47
48 2007-05-27  Bruno Haible  <bruno@clisp.org>
49
50         * modules/openmp: New file.
51         * m4/openmp.m4: New file, taken from autoconf's CVS with changes by
52         Noah Misch.
53
54 2007-05-26  Bruno Haible  <bruno@clisp.org>
55
56         * modules/chdir-long (Depends-on): Add fchdir.
57         * modules/chdir-safer (Depends-on): Likewise.
58         * modules/fts (Depends-on): Likewise.
59         * modules/fts-lgpl (Depends-on): Likewise.
60         * modules/openat (Depends-on): Likewise.
61         * modules/savewd (Depends-on): Likewise.
62
63 2007-05-24  Eric Blake  <ebb9@byu.net>
64
65         Fix lseek on mingw.
66         * modules/lseek: New module.
67         * m4/lseek.m4: New file.
68         * lib/lseek.c: New file.
69         * modules/lseek-tests: New file.
70         * tests/test-lseek.c: New file.
71         * tests/test-lseek.sh: New file.
72         * MODULES.html.sh: Document lseek module.
73         * modules/fflush (Depends-on): Add lseek, fseeko.
74         * modules/fseeko (Depends-on): Likewise.
75         * modules/ftello (Depends-on): Likewise.
76         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Replace fseek[o] if lseek is
77         broken.
78         * m4/ftello.m4 (gl_FUNC_FTELLO): Replace ftell[o] if lseek is
79         broken.
80         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Trigger fseeko module.
81         * lib/fseeko.c (rpl_fseeko): Quit early on non-seekable files.
82         * lib/ftello.c (rpl_ftello): Likewise.
83         * tests/test-fseeko.c (main): Test this.
84         * tests/test-fseeko.sh: Likewise.
85         * tests/test-ftello.c (main): Likewise.
86         * tests/test-ftello.sh: Likewise.
87         * lib/stdio_.h (fseek, ftell): Simplify, since missing fseeko now
88         implies replacing fseek.
89         * modules/stdio (Makefile.am): No longer need HAVE_FSEEKO,
90         HAVE_FTELLO.
91         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Add lseek info.
92         * modules/unistd (Makefile.am): Likewise.
93         * lib/unistd_.h (lseek): Declare a replacement.
94         * doc/functions/lseek.texi (lseek): Document this fix.
95         * doc/functions/fseek.texi (fseek): Likewise.
96         * doc/functions/ftell.texi (ftell): Likewise.
97
98 2007-05-24  Bruno Haible  <bruno@clisp.org>
99
100         * tests/test-vasnprintf-posix.c (test_function): Allow up to 50 bytes
101         in the printed representation of a NaN.
102         * tests/test-vasprintf-posix.c (test_function): Likewise.
103         * tests/test-snprintf-posix.h (test_function): Likewise.
104         * tests/test-sprintf-posix.h (test_function): Likewise.
105         Reported by Eric Blake.
106
107 2007-05-23  Eric Blake  <ebb9@byu.net>
108
109         Fix fseeko/ftello on cygwin 1.5.24.
110         * doc/functions/fseeko.texi (fseeko): Document the fix.
111         * doc/functions/ftello.texi (ftello): Document the fix.
112         * doc/functions/stdin.texi (stdin): Document the cygwin bug.
113         * doc/functions/stdout.text (stdout): New file.
114         * doc/functions/stderr.text (stderr): New file.
115         * doc/gnulib.texi (Function Substitutes): Use new files.
116         * tests/test-fseeko.c (main): Check for broken fseeko on cygwin
117         prior to 1.7.0.
118         * tests/test-ftello.c (main): Likewise for ftello.
119         * tests/test-fseeko.sh: New file.
120         * tests/test-ftello.sh: New file.
121         * modules/fseeko-tests (Makefile.am): Ensure test-fseeko is run
122         with seekable stdin.
123         * modules/ftello-tests (Makefile.am): Likewise for test-ftello.
124         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Detect the cygwin bug.
125         (gl_REPLACE_FSEEKO): New macro.
126         * m4/ftello.m4 (gl_FUNC_FTELLO, gl_REPLACE_FTELLO): Likewise.
127         * modules/fseeko (Files): Distribute fseeko.c.
128         * modules/ftello (Files): Distribute ftello.c.
129         * lib/fseeko.c (rpl_fseeko) [__CYGWIN__]: Convert stdin to 64-bit
130         mode.
131         * lib/ftello.c (rpl_ftello): New file.
132         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Allow replacement of
133         fseeko, ftello.
134         (gl_STDIN_LARGE_OFFSET): New macro.
135         * modules/stdio (Makefile.am): Perform the replacement.
136         * lib/stdio_.h (rpl_fseeko, rpl_ftello): Define when needed.
137
138 2007-05-23  Bruno Haible  <bruno@clisp.org>
139
140         * lib/stdio_.h (fseeko, ftello): Provide a link warning only if
141         GNULIB_POSIXCHECK is defined.
142
143 2007-05-21  Bruno Haible  <bruno@clisp.org>
144
145         * m4/printf.m4 (gl_PRINTF_INFINITE, gl_PRINTF_INFINITE_LONG_DOUBLE):
146         Check also the output for NaN arguments. When cross-compiling, guess
147         no on IRIX.
148         * lib/vasnprintf.c: Update comments.
149         * tests/test-vasnprintf-posix.c (strisnan): New function.
150         (test_function): Use it.
151         * tests/test-vasprintf-posix.c (strisnan): New function.
152         (test_function): Use it.
153         * tests/test-snprintf-posix.h (strisnan): New function.
154         (test_function): Use it.
155         * tests/test-sprintf-posix.h (strisnan): New function.
156         (test_function): Use it.
157         Reported by Eric Blake.
158
159 2007-05-20  Bruno Haible  <bruno@clisp.org>
160
161         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Add test for large finite
162         numbers that fails on BeOS.
163         * doc/functions/frexpl.texi: Update.
164
165 2007-05-20  Jim Meyering  <jim@meyering.net>
166
167         * NEWS: Mention the incompatible change (s/futimens/gl_futimens/)
168         forced upon us by glibc-2.6.
169
170 2007-05-20  Bruno Haible  <bruno@clisp.org>
171
172         Fix *printf result for NaN, Inf on AIX, Solaris, OSF/1.
173         * m4/printf.m4 (gl_PRINTF_INFINITE): Update cross-compiling guesses.
174         (gl_PRINTF_INFINITE_LONG_DOUBLE): New macro.
175         * lib/vasnprintf.c: Use NEED_PRINTF_INFINITE_DOUBLE instead of
176         NEED_PRINTF_INFINITE.
177         (is_infinitel): New function.
178         (VASNPRINTF): Handle NEED_PRINTF_INFINITE_LONG_DOUBLE case.
179         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE): Renamed from
180         gl_PREREQ_VASNPRINTF_INFINITE.
181         (gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE): New macro.
182         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
183         gl_PRINTF_INFINITE_LONG_DOUBLE and test its result. Invoke
184         gl_PREREQ_VASNPRINTF_INFINITE_DOUBLE and
185         gl_PREREQ_VASNPRINTF_INFINITE_LONG_DOUBLE instead of
186         gl_PREREQ_VASNPRINTF_INFINITE.
187         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
188         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
189         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
190         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
191         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
192         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
193         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
194         * doc/functions/fprintf.texi: Update.
195         * doc/functions/printf.texi: Update.
196         * doc/functions/snprintf.texi: Update.
197         * doc/functions/sprintf.texi: Update.
198         * doc/functions/vfprintf.texi: Update.
199         * doc/functions/vprintf.texi: Update.
200         * doc/functions/vsnprintf.texi: Update.
201         * doc/functions/vsprintf.texi: Update.
202
203 2007-05-20  Bruno Haible  <bruno@clisp.org>
204
205         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): Set REPLACE_FREXPL if frexpl
206         was not found in libc.
207         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Likewise.
208
209 2007-05-20  Bruno Haible  <bruno@clisp.org>
210
211         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
212         printed as "-nan" instead of "nan".
213         * tests/test-vasprintf-posix.c (test_function): Likewise.
214         * tests/test-snprintf-posix.h (test_function): Likewise.
215         * tests/test-sprintf-posix.h (test_function): Likewise.
216         Needed for HP-UX 11.
217
218 2007-05-20  Jim Meyering  <jim@meyering.net>
219
220         Fix buggy test for the fchownat-deref bug.
221         * m4/openat.m4 (gl_FUNC_FCHOWNAT_DEREF_BUG): Create the dangling
222         symlink required for the run-test.  Without it, this test would
223         always declare that fchownat doesn't work, and client code would
224         unnecessarily use the replacement function with fixed libc.
225         (gl_FUNC_FCHOWNAT): Eliminate a variable that wasn't initialized.
226         Reported by Greg Schafer.
227
228 2007-05-19  Bruno Haible  <bruno@clisp.org>
229
230         * m4/isnanf.m4 (gl_ISNANF_WORKS): New macro.
231         (gl_FUNC_ISNANF_NO_LIBM): Invoke it.
232         * lib/isnan.c (FUNC): Use run-time expressions for SGI compiler.
233         Needed for IRIX 6.5 and Solaris 2.5.1.
234
235 2007-05-19  Bruno Haible  <bruno@clisp.org>
236
237         * tests/test-vasnprintf-posix.c (have_minus_zero): New function.
238         (test_function): Skip tests involving -0.0 on platforms where
239         -0.0 = 0.0.
240         * tests/test-vasprintf-posix.c (have_minus_zero): New function.
241         (test_function): Skip tests involving -0.0 on platforms where
242         -0.0 = 0.0.
243         * tests/test-snprintf-posix.h (have_minus_zero): New function.
244         (test_function): Skip tests involving -0.0 on platforms where
245         -0.0 = 0.0.
246         * tests/test-sprintf-posix.h (have_minus_zero): New function.
247         (test_function): Skip tests involving -0.0 on platforms where
248         -0.0 = 0.0.
249         * tests/test-fprintf-posix.h (test_function): Remove all -0.0 related
250         tests.
251         * tests/test-printf-posix.h (test_function): Likewise.
252         * tests/test-printf-posix.output: Remove all -0.0 related results.
253         Needed for IRIX 6.5.
254
255 2007-05-19  Bruno Haible  <bruno@clisp.org>
256
257         * tests/test-vasnprintf-posix.c (test_function): Allow NaN to be
258         printed as "nan0x7fffffff" instead of "nan".
259         * tests/test-vasprintf-posix.c (test_function): Likewise.
260         * tests/test-snprintf-posix.h (test_function): Likewise.
261         * tests/test-sprintf-posix.h (test_function): Likewise.
262         * tests/test-fprintf-posix.h (NaN): Remove macro.
263         (test_function): Remove all NaN related tests.
264         * tests/test-printf-posix.h (NaN): Remove macro.
265         (test_function): Remove all NaN related tests.
266         * tests/test-printf-posix.output: Remove all NaN related results.
267         Needed for IRIX 6.5.
268
269 2007-05-19  Bruno Haible  <bruno@clisp.org>
270
271         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Fix C89 syntax error in test code.
272         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Likewise.
273
274 2007-05-19  Bruno Haible  <bruno@clisp.org>
275
276         * lib/float_.h: New file.
277         * m4/float_h.m4: New file.
278         * modules/float: New file.
279         * modules/isnanl (Dependencies): Add float.
280         * modules/isnanl-nolibm (Dependencies): Likewise.
281         * modules/mathl (Dependencies): Likewise.
282         * modules/printf-frexpl (Dependencies): Likewise.
283         * modules/signbit (Dependencies): Likewise.
284         * modules/vasnprintf (Dependencies): Likewise.
285         * doc/headers/float.texi: Update.
286
287 2007-05-19  Jim Meyering  <jim@meyering.net>
288
289         * lib/utimens.c (gl_futimens): Rename from futimens,
290         now that glibc-2.6 declares futimens.
291         * lib/utimens.h: Likewise.
292
293 2007-05-19  Bruno Haible  <bruno@clisp.org>
294
295         Avoid test failures on mingw.
296         * tests/test-fprintf-posix.sh: Convert CR/LF to LF in output.
297         * tests/test-printf-posix.sh: Likewise.
298         * tests/test-vfprintf-posix.sh: Likewise.
299         * tests/test-vprintf-posix.sh: Likewise.
300
301 2007-05-19  Bruno Haible  <bruno@clisp.org>
302
303         Fix *printf result for NaN, Inf, -0.0 on mingw.
304         * m4/printf.m4 (gl_PRINTF_INFINITE): New macro.
305         * lib/vasnprintf.c: Include math.h and isnan.h.
306         (is_infinite_or_zero): New function.
307         (VASNPRINTF): Fix also the handling of infinite or zero 'double'
308         values in the %f, %F, %e, %E, %g, %G directives.
309         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_INFINITE): New macro.
310         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
311         gl_PRINTF_INFINITE and test its result. Invoke
312         gl_PREREQ_VASNPRINTF_INFINITE.
313         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
314         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
315         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
316         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
317         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
318         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
319         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
320         * doc/functions/fprintf.texi: Update.
321         * doc/functions/printf.texi: Update.
322         * doc/functions/snprintf.texi: Update.
323         * doc/functions/sprintf.texi: Update.
324         * doc/functions/vfprintf.texi: Update.
325         * doc/functions/vprintf.texi: Update.
326         * doc/functions/vsnprintf.texi: Update.
327         * doc/functions/vsprintf.texi: Update.
328
329 2007-05-19  Bruno Haible  <bruno@clisp.org>
330
331         * lib/vasnprintf.c (convert_to_decimal): Add an extra_zeroes argument.
332         (scale10_round_decimal_long_double): Inline scale10_round_long_double.
333         Instead of multiplying with 10^k, set extra_zeroes to k.
334         (scale10_round_long_double): Remove function.
335
336 2007-05-18  Bruno Haible  <bruno@clisp.org>
337
338         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Fix logic bug
339         introduced on 2007-05-06.
340
341 2007-05-18  Bruno Haible  <bruno@clisp.org>
342
343         * tests/test-vasnprintf-posix.c (test_function): Also test the %e and
344         %g directives.
345         * tests/test-vasprintf-posix.c (test_function): Likewise.
346         * tests/test-snprintf-posix.h (test_function): Likewise.
347         * tests/test-sprintf-posix.h (test_function): Likewise.
348
349 2007-05-18  Bruno Haible  <bruno@clisp.org>
350
351         * tests/test-vasnprintf-posix.c (SIZEOF): New macro.
352         (strmatch): New function.
353         (test_function): Test the %f directive on numbers of various exponents.
354         * tests/test-vasprintf-posix.c (SIZEOF): New macro.
355         (strmatch): New function.
356         (test_function): Test the %f directive on numbers of various exponents.
357         * tests/test-snprintf-posix.h (strmatch): New function.
358         (test_function): Test the %f directive on numbers of various exponents.
359         * tests/test-sprintf-posix.h (strmatch): New function.
360         (test_function): Test the %f directive on numbers of various exponents.
361         * tests/test-snprintf-posix.c (SIZEOF): New macro.
362         * tests/test-sprintf-posix.c (SIZEOF): New macro.
363         * tests/test-vsnprintf-posix.c (SIZEOF): New macro.
364         * tests/test-vsprintf-posix.c (SIZEOF): New macro.
365
366 2007-05-18  Bruno Haible  <bruno@clisp.org>
367
368         Add support for 'long double' number output.
369         * m4/printf.m4 (gl_PRINTF_LONG_DOUBLE): New macro.
370         * lib/vasnprintf.c: Include math.h and float+.h.
371         (mp_limb_t): New type.
372         (GMP_LIMB_BITS): New macro.
373         (mp_twolimb_t): New type.
374         (GMP_TWOLIMB_BITS): New macro.
375         (mpn_t): New type.
376         (multiply, divide, convert_to_decimal, decode_long_double,
377         scale10_round_long_double, scale10_round_decimal_long_double,
378         floorlog10l): New functions.
379         (VASNPRINTF) [NEED_PRINTF_LONG_DOUBLE]: Implement 'long double' support
380         for the %f, %F, %e, %E, %g, %G directives.
381         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_LONG_DOUBLE): New macro.
382         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
383         gl_PRINTF_LONG_DOUBLE and test its result. Invoke
384         gl_PREREQ_VASNPRINTF_LONG_DOUBLE.
385         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
386         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
387         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
388         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
389         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
390         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
391         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
392         * modules/fprintf-posix (Depends-on): Add frexpl-nolibm.
393         * modules/snprintf-posix (Depends-on): Likewise.
394         * modules/sprintf-posix (Depends-on): Likewise.
395         * modules/vasnprintf-posix (Depends-on): Likewise.
396         * modules/vasprintf-posix (Depends-on): Likewise.
397         * modules/vfprintf-posix (Depends-on): Likewise.
398         * modules/vsnprintf-posix (Depends-on): Likewise.
399         * modules/vsprintf-posix (Depends-on): Likewise.
400         * modules/vasnprintf (Files): Add lib/float+.h.
401         * doc/functions/fprintf.texi: Update.
402         * doc/functions/printf.texi: Update.
403         * doc/functions/snprintf.texi: Update.
404         * doc/functions/sprintf.texi: Update.
405         * doc/functions/vfprintf.texi: Update.
406         * doc/functions/vprintf.texi: Update.
407         * doc/functions/vsnprintf.texi: Update.
408         * doc/functions/vsprintf.texi: Update.
409
410 2007-05-18  Bruno Haible  <bruno@clisp.org>
411
412         * lib/vasnprintf.c (USE_SNPRINTF): Define to 0 on BeOS.
413
414 2007-05-18  Bruno Haible  <bruno@clisp.org>
415
416         * lib/vasnprintf.c (VASNPRINTF) [WIN32]: Use %I64d instead of %lld
417         for printing 64-bit integers. Needed for mingw.
418
419 2007-05-18  Bruno Haible  <bruno@clisp.org>
420
421         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
422         gl_FUNC_FREXPL_WORKS.
423         * modules/printf-frexpl (Files): Add m4/frexpl.m4.
424
425 2007-05-18  Bruno Haible  <bruno@clisp.org>
426
427         * modules/frexpl-nolibm-tests: New file.
428
429         * modules/frexpl-nolibm: New file.
430         * m4/frexpl.m4 (gl_FUNC_FREXPL_NO_LIBM): New macro.
431
432 2007-05-17  Paul Eggert  <eggert@cs.ucla.edu>
433
434         * lib/dirent_.h: Prefer #include_next <foo.h> to #include
435         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
436         GCC 4.2, which otherwise issues a lot of warnings.
437         * lib/iconv_.h, lib/locale_.h, lib/netinet_in_.h, lib/sys_select_.h:
438         * lib/sys_socket_.h, lib/sys_stat_.h, lib/sysexits_.h, lib/unistd_.h:
439         Likewise.
440         * modules/fchdir (dirent.h): Substitute @HAVE_INCLUDE_NEXT@.
441         * modules/iconv_open (iconv.h): Likewise.
442         * modules/locale (locale.h): Likewise.
443         * modules/netinet_in (netinet/in.h): Likewise.
444         * modules/sys_select (sys_select.h): Likewise.
445         * modules/sys_socket (sys/socket.h): Likewise.
446         * modules/sys_stat (sys/stat.h): Likewise.
447         * modules/sysexits (sysexits.h): Likewise.
448         * modules/unistd (unistd.h): Likewise.
449
450 2007-05-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
451
452         * modules/closein-tests (Makefile.am): Distribute
453         `test-closein.sh'.
454
455 2007-05-17  Bruno Haible  <bruno@clisp.org>
456
457         * tests/test-printf-posix.output: Renamed from
458         tests/test-fprintf-posix.out.
459         * modules/fprintf-posix-tests: Update.
460         * modules/printf-posix-tests: Update.
461         * modules/vfprintf-posix-tests: Update.
462         * modules/vprintf-posix-tests: Update.
463         * tests/test-fprintf-posix.sh: Update.
464         * tests/test-printf-posix.sh: Update.
465         * tests/test-vfprintf-posix.sh: Update.
466         * tests/test-vprintf-posix.sh: Update.
467         Reported by Ralf Wildenhues.
468
469 2007-05-16  Paul Eggert  <eggert@cs.ucla.edu>
470
471         * lib/fcntl_.h: Prefer #include_next <foo.h> to #include
472         @ABSOLUTE_FOO_H@ if @HAVE_INCLUDE_NEXT@.  This works better with
473         GCC 4.2, which otherwise issues a lot of warnings.
474         * lib/inttypes_.h, lib/math_.h, lib/search_.h, lib/signal_.h:
475         * lib/stdint_.h, lib/stdio_.h, lib/stdlib_.h, lib/string_.h:
476         * lib/sys_time_.h, lib/time_.h, lib/wchar_.h, lib/wctype_.h: Likewise.
477         * lib/stdlib_.h: Don't bother with #pragma GCC system_header, as
478         it should no longer be needed.
479         * lib/string_.h: Likewise.
480         * modules/absolute-header (HAVE_INCLUDE_NEXT): New 'make' define.
481         * modules/fcntl (fcntl.h): Substitute @HAVE_INCLUDE_NEXT@.
482         * modules/inttypes (inttypes.h): Likewise.
483         * modules/math (math.h): Likewise.
484         * modules/search (search.h): Likewise.
485         * modules/signal (signal.h): Likewise.
486         * modules/stdint (stdint.h): Likewise.
487         * modules/stdio (stdio.h): Likewise.
488         * modules/stdlib (stdlib.h): Likewise.
489         * modules/string (string.h): Likewise.
490         * modules/sys_time (sys/time.h): Likewise.
491         * modules/time (time.h): Likewise.
492         * modules/wchar (wchar.h): Likewise.
493         * modules/wctype (wtype.h): Likewise.
494
495 2007-05-16  Thien-Thi Nguyen  <ttn@gnuvola.org>  (tiny change)
496
497         * doc/gnulib-tool.texi (CVS Issues): Fix typo.
498
499 2007-05-13  Bruno Haible  <bruno@clisp.org>
500
501         * stpcpy.m4 (gl_FUNC_STPCPY): Require AC_C_RESTRICT.
502         * stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
503         * strsep.m4 (gl_FUNC_STRSEP): Likewise.
504         * strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
505         (gl_PREREQ_STRTOK_R): Don't require it here.
506
507 2007-05-13  Bruno Haible  <bruno@clisp.org>
508
509         * lib/stdlib_.h (mkdtemp, mkstemp): Comment out argument name. Needed
510         when used in C++ mode.
511
512 2007-05-12  Bruno Haible  <bruno@clisp.org>
513
514         * lib/linebuffer.h: Tweak doc.
515         * lib/linebuffer.c: Likewise.
516
517 2007-05-12  James Youngman  <jay@gnu.org>
518
519         * lib/linebuffer.c (readlinebuffer_delim): New function,
520         like readlinebuffer, but use a caller-specified delimiter.
521         (readlinebuffer): Just call readlinebuffer_delim with '\n'
522         as the delimiter.
523         * lib/linebuffer.h (readlinebuffer_delim): Declare it.
524
525 2007-05-12  Sergey Poznyakoff  <gray@gnu.org.ua>
526
527         * m4/openat.m4 (gl_FUNC_OPENAT): Do not require openat-die.
528         * modules/openat (Files): Remove openat-die.c.
529         (Depends-on): Add openat-die.
530         * modules/openat-die: New module.
531
532 2007-05-06  Bruno Haible  <bruno@clisp.org>
533
534         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING, gl_VSNPRINTF_ZEROSIZE_C99):
535         Update with info about Cygwin.
536         * doc/functions/fprintf.texi: Update.
537         * doc/functions/printf.texi: Update.
538         * doc/functions/snprintf.texi: Update.
539         * doc/functions/sprintf.texi: Update.
540         * doc/functions/vfprintf.texi: Update.
541         * doc/functions/vprintf.texi: Update.
542         * doc/functions/vsnprintf.texi: Update.
543         * doc/functions/vsprintf.texi: Update.
544         Reported by Eric Blake.
545
546 2007-05-06  Bruno Haible  <bruno@clisp.org>
547
548         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_ZERO]: Perform the
549         padding ourselves for the floating-point directives.
550         * m4/printf.m4 (gl_PRINTF_FLAG_ZERO): New macro.
551         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_ZERO): New macro.
552         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
553         gl_PRINTF_FLAG_ZERO and test its result. Invoke
554         gl_PREREQ_VASNPRINTF_FLAG_ZERO.
555         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
556         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
557         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
558         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
559         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
560         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
561         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
562         * tests/test-snprintf-posix.h (test_function): Also check the width
563         and some flags in the %f directive.
564         * tests/test-sprintf-posix.h (test_function): Likewise.
565         * tests/test-vasnprintf-posix.c (test_function): Likewise.
566         * tests/test-vasprintf-posix.c (test_function): Likewise.
567         * doc/functions/fprintf.texi: Update.
568         * doc/functions/printf.texi: Update.
569         * doc/functions/snprintf.texi: Update.
570         * doc/functions/sprintf.texi: Update.
571         * doc/functions/vfprintf.texi: Update.
572         * doc/functions/vprintf.texi: Update.
573         * doc/functions/vsnprintf.texi: Update.
574         * doc/functions/vsprintf.texi: Update.
575
576 2007-05-06  Bruno Haible  <bruno@clisp.org>
577
578         * lib/vasnprintf.c (VASNPRINTF) [NEED_PRINTF_FLAG_GROUPING]: Don't
579         pass the ' flag character to sprintf or snprintf.
580         * m4/printf.m4 (gl_PRINTF_FLAG_GROUPING): New macro.
581         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_FLAG_GROUPING): New macro.
582         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
583         gl_PRINTF_FLAG_GROUPING and test its result. Invoke
584         gl_PREREQ_VASNPRINTF_FLAG_GROUPING.
585         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
586         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Likewise.
587         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
588         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
589         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
590         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
591         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
592         * tests/test-snprintf-posix.h (test_function): Also check the grouping
593         flag.
594         * tests/test-sprintf-posix.h (test_function): Likewise.
595         * tests/test-vasnprintf-posix.c (test_function): Likewise.
596         * tests/test-vasprintf-posix.c (test_function): Likewise.
597         * doc/functions/fprintf.texi: Update.
598         * doc/functions/printf.texi: Update.
599         * doc/functions/snprintf.texi: Update.
600         * doc/functions/sprintf.texi: Update.
601         * doc/functions/vfprintf.texi: Update.
602         * doc/functions/vprintf.texi: Update.
603         * doc/functions/vsnprintf.texi: Update.
604         * doc/functions/vsprintf.texi: Update.
605
606 2007-05-01  Bruno Haible  <bruno@clisp.org>
607
608         * tests/test-argp-2.sh (func_compare): Drop .exe suffix.
609
610 2007-05-03  Paul Eggert  <eggert@cs.ucla.edu>
611
612         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Use better
613         comment for D_INO_IN_DIRENT.  Problem reported by James Youngman.
614
615 2007-05-02  Paul Eggert  <eggert@cs.ucla.edu>
616
617         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Test whether
618         readdir returns garbage in d_ino.  Problem reported by Kaz Sasayama in
619         <http://lists.gnu.org/archive/html/bug-gnulib/2007-05/msg00021.html>.
620
621 2007-05-02  Sergey Poznyakoff  <gray@gnu.org.ua>
622
623         * lib/argp-help.c (struct hol_entry): New member `ord'.
624         (HOL_ENTRY_PTRCMP): Use ord for comparison
625         (hol_sort): Initialize ord.
626
627 2007-05-01  Bruno Haible  <bruno@clisp.org>
628
629         * doc/functions/_Exit_C99.texi: Renamed from doc/functions/_Exit.texi.
630         Reported by Eric Blake.
631         * doc/gnulib.texi (Function Substitutes): Update.
632
633 2007-05-01  Bruno Haible  <bruno@clisp.org>
634
635         * doc/functions.texi: Remove file, now redundant through
636         doc/functions/*.texi.
637
638 2007-05-01  Bruno Haible  <bruno@clisp.org>
639
640         * modules/argp (Depends-on): Add sleep.
641
642 2007-05-01  Bruno Haible  <bruno@clisp.org>
643
644         * modules/sleep-tests: New file.
645         * tests/test-sleep.c: New file.
646
647         * modules/sleep: New file.
648         * lib/sleep.c: New file.
649         * m4/sleep.m4: New file.
650         * lib/unistd_.h (sleep): New declaration.
651         * m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize GNULIB_SLEEP,
652         HAVE_SLEEP.
653         * modules/unistd (Makefile.am): Substitute GNULIB_SLEEP, HAVE_SLEEP.
654         * doc/functions/sleep.texi: Document the sleep module.
655
656 2007-05-01  Bruno Haible  <bruno@clisp.org>
657
658         * lib/sigprocmask.h: Remove file.
659         * lib/signal_.h: Incorporate the previous contents of sigprocmask.h.
660         * lib/sigprocmask.c: Include <signal.h> instead of sigprocmask.h.
661         * m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Substitute GNULIB_SIGPROCMASK,
662         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T.
663         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Require
664         gl_SIGNAL_H_DEFAULTS. Set HAVE_POSIX_SIGNALBLOCKING as a shell variable.
665         (gl_PREREQ_SIGPROCMASK): Require gl_SIGNAL_H_DEFAULTS. Set
666         HAVE_SIGSET_T as a shell variable.
667         * modules/signal (Makefile.am): Substitute GNULIB_SIGPROCMASK,
668         HAVE_POSIX_SIGNALBLOCKING, HAVE_SIGSET_T into signal.h.
669         * modules/sigprocmask (Files): Remove lib/sigprocmask.h.
670         (Depends-on): Add signal. Remove verify.
671         (configure.ac): Invoke gl_SIGNAL_MODULE_INDICATOR.
672         (Include): Mention <signal.h> instead of sigprocmask.h.
673         * NEWS: Mention the change.
674         * lib/fatal-signal.c: Don't include sigprocmask.h.
675
676 2007-05-01  Bruno Haible  <bruno@clisp.org>
677
678         * modules/signal: New file.
679         * lib/signal_.h: New file.
680         * m4/signal_h.m4: New file.
681
682 2007-05-01  Bruno Haible  <bruno@clisp.org>
683
684         * lib/wctype_.h: Test HAVE_ISWCNTRL at configure time.
685         * m4/wctype.m4 (gl_WCTYPE_H): Substitute HAVE_ISWCNTRL.
686         * modules/wctype (Makefile.am): Substitute HAVE_ISWCNTRL instead of
687         HAVE_WCTYPE_CTMP_BUG into wctype.h.
688
689 2007-05-01  Bruno Haible  <bruno@clisp.org>
690
691         * lib/sys_stat_.h: Test HAVE_LSTAT, HAVE_DECL_MKDIR, HAVE_IO_H at
692         configure time.
693         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Substitute HAVE_LSTAT,
694         HAVE_DECL_MKDIR, HAVE_IO_H via AC_SUBST.
695         * modules/sys_stat (Makefile.am): Substitute their values into
696         sys/stat.h.
697
698 2007-05-01  Bruno Haible  <bruno@clisp.org>
699
700         * lib/glob_.h: Test HAVE_SYS_CDEFS_H at configure time.
701         * m4/glob.m4 (gl_PREREQ_GLOB): Substitute HAVE_SYS_CDEFS_H via AC_SUBST.
702         * modules/glob (Makefile.am): Put HAVE_SYS_CDEFS_H value into glob.h.
703
704 2007-05-01  Bruno Haible  <bruno@clisp.org>
705
706         * doc/header/assert.texi: Undo last change: don't mention the gnulib
707         'assert' module here.
708
709 2007-05-01  Bruno Haible  <bruno@clisp.org>
710
711         * doc/functions/*.texi: New files.
712         * doc/functions/google-ranking.txt: New file.
713         * doc/gnulib.texi (Function Substitutes): New chapter.
714         (ctime, inet_ntoa): Remove sections.
715         * doc/ctime.texi: Remove file.
716         * doc/inet_ntoa.texi: Remove file.
717         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Update
718         dependencies.
719         (%.info): New rule, specifying a --reference-limit.
720
721 2007-05-01  Bruno Haible  <bruno@clisp.org>
722
723         * MODULES.html.sh (posix_functions): Remove 'exec', 'toc'.
724
725 2007-05-01  Bruno Haible  <bruno@clisp.org>
726
727         * modules/mkdir (Depends-on): Add sys_stat, because sys_stat provides
728         the portability of 'mkdir' to mingw systems.
729
730 2007-05-01  Bruno Haible  <bruno@clisp.org>
731
732         * doc/headers/google-ranking.txt: New file.
733
734 2007-04-30  Eric Blake  <ebb9@byu.net>
735
736         Prefer fseeko to fseek.
737         * modules/getpass (Depends-on): Add fseeko.
738         * lib/getpass.c (getpass): Use fseeko, not fseek.
739
740 2007-04-30  Sergey Poznyakoff  <gray@gnu.org.ua>
741
742         * lib/argp-help.c (hol_entry_cmp): Option sorting algorithm
743         assumes the sorting is stable, while most qsort implementations
744         are not.  Use argument addresses to ensure they never compare as
745         equal.
746
747         * tests/test-argp-2.sh (usage-indent test): Fix output
748         (func_compare): Restore diff options
749         * tests/test-argp.c: Restore #include "progname.h"
750
751 2007-04-29  Bruno Haible  <bruno@clisp.org>
752
753         * m4/printf.m4 (gl_VSNPRINTF_ZEROSIZE_C99): New macro.
754         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
755         gl_VSNPRINTF_ZEROSIZE_C99. Test gl_cv_func_vsnprintf_zerosize_c99.
756         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
757         * modules/snprintf-posix-tests (Files): Add tests/test-snprintf.c.
758         (configure.ac): Define CHECK_SNPRINTF_POSIX.
759         (TESTS, check_PROGRAMS): Add test-snprintf.
760         * modules/vsnprintf-posix-tests (Files): Add tests/test-vsnprintf.c.
761         (configure.ac): Define CHECK_VSNPRINTF_POSIX.
762         (TESTS, check_PROGRAMS): Add test-vsnprintf.
763         * tests/test-snprintf.c (main) [!CHECK_SNPRINTF_POSIX]: Disable
764         assertions that fail on HP-UX, OSF/1, or IRIX.
765         * tests/test-vsnprintf.c (main) [!CHECK_VSNPRINTF_POSIX]: Likewise.
766
767 2007-04-29  Bruno Haible  <bruno@clisp.org>
768
769         * MODULES.html.sh (posix_functions): Remove 'contents'.
770
771 2007-04-29  Karl Berry  <karl@gnu.org>
772
773         * config/srclist.txt (gendocs_template_min): new entry.
774
775 2007-04-29  Bruno Haible  <bruno@clisp.org>
776
777         Work around fpurge bug on BSD systems.
778         * modules/fpurge (Makefile.am): Compile fpurge.c unconditionally.
779         * m4/fpurge.m4 (gl_FUNC_FPURGE): Don't invoke AC_LIBOBJ.
780         * lib/fpurge.h (fpurge): Don't handle __fpurge wrapper here. Define
781         fpurge to rpl_fpurge if the system already has this function.
782         * lib/fpurge.c (fpurge): Handle also the __fpurge wrapper case and
783         the case where the system already has this function. Correct invariants
784         on BSD systems.
785         * lib/fseeko.c (rpl_fseeko): Update recognition of preceding fflush on
786         BSD systems.
787
788 2007-04-29  Sergey Poznyakoff  <gray@gnu.org.ua>
789
790         * lib/argp-help.c (hol_cluster_cmp): Reverse comparison.  Change
791         proposed by Sven Verdoolaege.
792
793         * tests/test-argp.c: Fix option ordering.  Test deeply clustered
794         options.
795         * tests/test-argp-2.sh (func_compare): Use diff instead of cmp.
796         (usage and help tests): Update
797
798 2007-04-29  Bruno Haible  <bruno@clisp.org>
799
800         * tests/test-fflush.c (main): Use a file of size 17, not 10.
801         Print more information in case of failure. Disable a test on BeOS.
802
803 2007-04-29  Bruno Haible  <bruno@clisp.org>
804
805         * tests/**/test-*.[hc] (ASSERT): Use fprintf to show the line number.
806         This helps debugging on systems on which no gdb is available.
807
808 2007-04-29  Bruno Haible  <bruno@clisp.org>
809
810         * lib/freading.h: Improve comments.
811         * lib/fwriting.h: Likewise.
812         * tests/test-freading.c (main): Don't check freading immediately after
813         repositioning. Needed for glibc.
814
815 2007-04-29  Bruno Haible  <bruno@clisp.org>
816
817         * lib/freading.c (freading): Trivial simplification.
818
819 2007-04-28  Bruno Haible  <bruno@clisp.org>
820
821         * tests/test-fwriting.c (main): Also test the interaction between
822         fflush and fwriting.
823         * modules/fwriting-tests (Depends-on): Add fflush.
824
825         * tests/test-freading.c (main): Also test the interaction between
826         fflush and freading.
827         * modules/freading-tests (Depends-on): Add fflush.
828
829 2007-04-28  Bruno Haible  <bruno@clisp.org>
830
831         * lib/stdio_.h (fseek, ftell): Provide link warnings suggesting to use
832         fseeko and ftello.
833         Suggested by Eric Blake.
834
835 2007-04-28  Jim Meyering  <jim@meyering.net>
836
837         Avoid false-negative in gl_STDINT_H's C99 conformance test.
838         * m4/stdint.m4 (gl_STDINT_H): When checking whether stdint.h conforms
839         to C99, include all of gl_STDINT_INCLUDES, not just <stddef.h>.
840
841 2007-04-27  Eric Blake  <ebb9@byu.net>
842
843         * doc/headers/assert.texi (assert.h): Document assert module use.
844
845 2007-04-27  Bruno Haible  <bruno@clisp.org>
846
847         * doc/headers/*.texi: New files.
848         * doc/gnulib.texi (Header File Substitutes): New chapter.
849         * doc/Makefile (gnulib.info, gnulib.html, gnulib.dvi): Specify
850         dependencies.
851         (standards.info ,standards.html, standards.dvi): Update dependencies.
852         (mostlyclean, clean): New targets.
853
854 2007-04-27  Bruno Haible  <bruno@clisp.org>
855
856         * lib/sysexits_.h: Renamed from lib/sysexit_.h.
857         * modules/sysexits (Files, Makefile.am): Update.
858
859         * lib/sys_socket_.h: Renamed from lib/socket_.h.
860         * modules/sys_socket (Files, Makefile.am): Update.
861
862         * lib/sys_stat_.h: Renamed from lib/stat_.h.
863         * modules/sys_stat (Files, Makefile.am): Update.
864
865 2007-04-27  Eric Blake  <ebb9@byu.net>
866
867         * lib/freading.h: Improve comments.
868         * lib/fwriting.h: Likewise.
869         * lib/fflush.c: Likewise.
870
871         Fix closein for mingw.
872         * modules/closein-tests: Add tests for closein.
873         * tests/test-closein.c: New file.
874         * tests/test-closein.sh: Likewise.
875         * lib/unistd_.h [!SEEK_CUR]: Mingw also needs stdlib.h for _exit.
876         * lib/closein.c (close_stdin): Don't fflush non-seekable streams.
877
878 2007-04-27  Bruno Haible  <bruno@clisp.org>
879
880         * lib/inttypes_.h [_DECC]: Don't use #include_next if the compiler
881         version is < 6.
882         * lib/math_.h [__DECC]: Likewise.
883         * lib/stdio_.h [__DECC]: Likewise.
884         * lib/stdlib_.h [__DECC]: Likewise.
885         * lib/string_.h [__DECC]: Likewise.
886         * lib/time_.h [__DECC]: Likewise.
887         * lib/wchar_.h [__DECC]: Likewise.
888         * lib/wctype_.h [__DECC]: Likewise.
889
890 2007-04-27  Bruno Haible  <bruno@clisp.org>
891
892         * tests/test-fbufmode.c (main): Relax test, to avoid failure on mingw.
893
894 2007-04-27  Bruno Haible  <bruno@clisp.org>
895
896         * lib/fflush.c: Add comments.
897         * modules/fpurge-tests (Depends-on): Add fflush.
898         * modules/freadable-tests (Depends-on): Likewise.
899         * modules/fwritable-tests (Depends-on): Likewise.
900
901 2007-04-27  Charles Wilson  <libtool@cwilson.fastmail.fm>
902
903         * m4/argz.m4 (gl_FUNC_ARGZ): Use !HAVE_WORKING_ARGZ instead of
904         SYSTEM_ARGZ_IS_BROKEN.  Also, minor stylistic improvements.
905         Report by Bruno Haible <bruno@clisp.org>.
906
907 2007-04-26  Eric Blake  <ebb9@byu.net>
908
909         Fix fflush on mingw.
910         * modules/fflush (Depends-on): Add freading.
911         * lib/fflush.c (rpl_fflush): Use freading to avoid losing buffered
912         but unread data.
913
914 2007-04-26  Eric Blake  <ebb9@byu.net>
915         and Bruno Haible  <bruno@clisp.org>
916
917         Implement freading and fwriting.
918         * lib/freading.c: New file.
919         * lib/freading.h: Likewise.
920         * m4/freading.m4: Likewise.
921         * modules/freading: Likewise.
922         * modules/freading-tests: Likewise.
923         * tests/test-freading.c: Likewise.
924         * lib/fwriting.c: New file.
925         * lib/fwriting.h: Likewise.
926         * m4/fwriting.m4: Likewise.
927         * modules/fwriting: Likewise.
928         * modules/fwriting-tests: Likewise.
929         * tests/test-fwriting.c: Likewise.
930         * MODULES.html.sh (File stream based Input/Output): Mention them.
931
932 2007-04-26  Bruno Haible  <bruno@clisp.org>
933
934         * lib/stdio_.h (fseeko, ftello): Check that off_t has the same size as
935         'long' when we assume it.
936         Suggested by Eric Blake.
937
938 2007-04-26  Bruno Haible  <bruno@clisp.org>
939
940         Ensure fseeko, ftello are declared on glibc systems.
941         * modules/fflush (configure.ac-early): Require AC_FUNC_FSEEKO.
942         * modules/fseeko (configure.ac-early): Likewise.
943         * modules/ftello (configure.ac-early): Likewise.
944         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Don't define HAVE_FSEEKO, rely on
945         AC_FUNC_FSEEKO for this.
946         * m4/fseeko.m4 (gl_FUNC_FSEEKO): Inline gl_CHECK_FSEEKO.
947         (gl_CHECK_FSEEKO): Remove macro.
948
949 2007-04-26  Bruno Haible  <bruno@clisp.org>
950
951         * tests/test-fflush.c (main): Also check the ftell result after
952         fflush and fseek/fseeko.
953         * lib/fflush.c (rpl_fflush): For BSD implementations, update the
954         file descriptor position cache in the stream.
955         * lib/fseeko.c (rpl_fseeko): Likewise.
956
957 2007-04-26  Bruno Haible  <bruno@clisp.org>
958
959         * modules/fflush-tests (Depends-on): Add fseeko.
960
961 2007-04-25  Charles Wilson  <libtool@cwilson.fastmail.fm>
962             Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
963
964         * lib/argz_.h: ensure error_t definition is obtained in same
965         mechanism system argz.h would have.
966         * m4/argz.m4 (gl_FUNC_ARGZ): add new test to check if $host's
967         argz facilities are known bad.  Err on the side of caution if
968         cross-compiling.
969
970 2007-04-25  Eric Blake  <ebb9@byu.net>
971
972         * lib/fpurge.c (includes): Use stdlib.h for free.
973         * tests/test-fflush.c (main): Also test fflush-fseeko.
974
975 2007-04-25  Bruno Haible  <bruno@clisp.org>
976
977         Make fflush+fseek POSIX-compliant on FreeBSD and MacOS X.
978         * lib/fseeko.c: New file.
979         * lib/stdio_.h: Include <sys/types.h> when off_t is needed.
980         (fseeko, fseek): Define to replacements if REPLACE_FFLUSH.
981         * m4/fseeko.m4 (gl_CHECK_FSEEKO): New macro, extracted from
982         gl_FUNC_FSEEKO.
983         (gl_FUNC_FSEEKO): Invoke it.
984         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Arrange to compile fseeko.c. Invoke
985         gl_CHECK_FSEEKO. Define HAVE_FSEEKO.
986         * modules/fflush (Files): Add lib/fseeko.c, m4/fseeko.m4.
987
988 2007-04-25  Bruno Haible  <bruno@clisp.org>
989
990         * modules/fflush (Depends-on): Add ftello.
991
992 2007-04-25  Bruno Haible  <bruno@clisp.org>
993
994         * modules/ftello-tests: New file.
995         * tests/test-ftello.c: New file.
996
997         * modules/ftello: New file.
998         * m4/ftello.m4: New file.
999         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FTELLO,
1000         HAVE_FTELLO.
1001         * lib/stdio_.h (ftello): New declaration.
1002         * modules/stdio (Makefile.am): Substitute also GNULIB_FTELLO,
1003         HAVE_FTELLO.
1004
1005 2007-04-25  Bruno Haible  <bruno@clisp.org>
1006
1007         * modules/fseeko-tests: New file.
1008         * tests/test-fseeko.c: New file.
1009
1010         * modules/fseeko: New file.
1011         * m4/fseeko.m4: New file.
1012         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FSEEKO,
1013         HAVE_FSEEKO.
1014         * lib/stdio_.h (fseeko): New declaration.
1015         * modules/stdio (Makefile.am): Substitute also GNULIB_FSEEKO,
1016         HAVE_FSEEKO.
1017
1018 2007-04-25  Bruno Haible  <bruno@clisp.org>
1019
1020         * lib/stdio_.h (fflush): Add support for GNULIB_POSIXCHECK.
1021
1022 2007-04-25  Bruno Haible  <bruno@clisp.org>
1023
1024         * lib/unistd_.h: Include <stdio.h> if needed to get the SEEK_* macros.
1025         * tests/test-stdio.c: Check that the various SEEK_* macros are defined.
1026         * tests/test-unistd.c: Likewise.
1027         * tests/test-fcntl.c: Likewise.
1028
1029 2007-04-23  Eric Blake  <ebb9@byu.net>
1030
1031         * lib/fflush.c: Fix missing include.
1032         Reported by Bruno Haible.
1033
1034 2007-04-23  Bruno Haible  <bruno@clisp.org>
1035
1036         * lib/fpurge.c (fpurge) [glibc, BSD]: Free a malloc()ed ungetc buffer.
1037         Reported by Eric Blake.
1038
1039 2007-04-23  Bruno Haible  <bruno@clisp.org>
1040
1041         * lib/fbufmode.c (fbufmode): Port to Solaris/SPARC64.
1042
1043 2007-04-23  Bruno Haible  <bruno@clisp.org>
1044
1045         * lib/fseterr.c (fseterr): Don't hardcode the value of _IOERR.
1046
1047 2007-04-23  Bruno Haible  <bruno@clisp.org>
1048
1049         * tests/test-fbufmode.c (main): Be prepared to a failure of setvbuf.
1050         Needed on HP-UX 11.
1051
1052 2007-04-16  Eric Blake  <ebb9@byu.net>
1053
1054         Make fflush rely on fpurge.
1055         * lib/fflush.c (rpl_fflush): Rely on fpurge module, rather than
1056         open coding all variants.
1057         * modules/fflush (Depends-on): Add fpurge and unistd.
1058         * modules/fflush-tests (Depends-on): Unistd is no longer extra.
1059         * m4/fflush.m4 (gl_REPLACE_FFLUSH): Simplify.
1060
1061         Fix --with-tests compilation on cygwin.
1062         * modules/argmatch-tests (Makefile.am): List gnulib library first
1063         in LDADD.
1064         * modules/argp-tests (Makefile.am): Likewise.
1065         * modules/array-list-tests (Makefile.am): Likewise.
1066         * modules/array-oset-tests (Makefile.am): Likewise.
1067         * modules/avltree-list-tests (Makefile.am): Likewise.
1068         * modules/avltree-oset-tests (Makefile.am): Likewise.
1069         * modules/avltreehash-list-tests (Makefile.am): Likewise.
1070         * modules/carray-list-tests (Makefile.am): Likewise.
1071         * modules/dirname-tests (Makefile.am): Likewise.
1072         * modules/frexp-tests (Makefile.am): Likewise.
1073         * modules/isnanl-tests (Makefile.am): Likewise.
1074         * modules/linked-list-tests (Makefile.am): Likewise.
1075         * modules/linkedhash-list-tests (Makefile.am): Likewise.
1076         * modules/lock-tests (Makefile.am): Likewise.
1077         * modules/rbtree-list-tests (Makefile.am): Likewise.
1078         * modules/rbtree-oset-tests (Makefile.am): Likewise.
1079         * modules/rbtreehash-list-tests (Makefile.am): Likewise.
1080         * modules/tls-tests (Makefile.am): Likewise.
1081         * modules/tsearch-tests (Makefile.am): Likewise.
1082         * modules/xvasprintf-tests (Makefile.am): Likewise.
1083
1084         Fix fpurge for cygwin.
1085         * lib/fpurge.c (fpurge): Fix order of operation flub, and return a
1086         value.
1087         * modules/fpurge-tests (Depends-on): Clean up trash.
1088
1089 2007-04-16  Simon Josefsson  <simon@josefsson.org>
1090
1091         * lib/gc-libgcrypt.c (gc_hash_open): Shut up compiler warnings.
1092
1093         * m4/autobuild.m4: Re-indent.
1094
1095 2007-04-13  Bruno Haible  <bruno@clisp.org>
1096
1097         * modules/fpurge-tests: New file.
1098         * tests/test-fpurge.c: New file.
1099
1100         * modules/fpurge: New file.
1101         * lib/fpurge.h: New file.
1102         * lib/fpurge.c: New file.
1103         * m4/fpurge.m4: New file.
1104
1105 2007-04-13  Bruno Haible  <bruno@clisp.org>
1106
1107         * modules/fbufmode-tests: New file.
1108         * tests/test-fbufmode.c: New file.
1109
1110         * modules/fbufmode: New file.
1111         * lib/fbufmode.h: New file.
1112         * lib/fbufmode.c: New file.
1113         * m4/fbufmode.m4: New file.
1114
1115 2007-04-13  Bruno Haible  <bruno@clisp.org>
1116
1117         * modules/fwritable-tests: New file.
1118         * tests/test-fwritable.c: New file.
1119
1120         * modules/fwritable: New file.
1121         * lib/fwritable.h: New file.
1122         * lib/fwritable.c: New file.
1123         * m4/fwritable.m4: New file.
1124
1125 2007-04-13  Bruno Haible  <bruno@clisp.org>
1126
1127         * modules/freadable-tests: New file.
1128         * tests/test-freadable.c: New file.
1129
1130         * modules/freadable: New file.
1131         * lib/freadable.h: New file.
1132         * lib/freadable.c: New file.
1133         * m4/freadable.m4: New file.
1134
1135 2007-04-13  Bruno Haible  <bruno@clisp.org>
1136
1137         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
1138         MOSTLYCLEANFILES.
1139
1140 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
1141
1142         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
1143         gzip bootstrap.conf to avoid dragging in i18n machinery.
1144         (gnulib_tool_option): Use it.
1145
1146 2007-04-13  Bruno Haible  <bruno@clisp.org>
1147
1148         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
1149         %F directives.
1150         * tests/test-vasprintf-posix.c (test_function): Likewise.
1151         * tests/test-snprintf-posix.h (test_function): Likewise.
1152         * tests/test-sprintf-posix.h (test_function): Likewise.
1153         * tests/test-fprintf-posix.h (test_function): Likewise.
1154         * tests/test-printf-posix.h (test_function): Likewise.
1155         * tests/test-fprintf-posix.out: Likewise.
1156
1157 2007-04-13  Bruno Haible  <bruno@clisp.org>
1158
1159         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
1160         * modules/tls-tests (configure.ac): Likewise.
1161         Reported by Arto C. Nirkko <anirkko@insel.ch>.
1162
1163 2007-04-13  Bruno Haible  <bruno@clisp.org>
1164
1165         * lib/tls.c (glthread_tls_get): Fix return type.
1166         Patch by Arto C. Nirkko <anirkko@insel.ch>.
1167
1168 2007-04-12  Eric Blake  <ebb9@byu.net>
1169
1170         * modules/gettime (Depends-on): Remove gettime.
1171         Reported by Dmitry V. Levin.
1172
1173 2007-04-12  Bruno Haible  <bruno@clisp.org>
1174
1175         * modules/fflush (Include): Mention <stdio.h>.
1176         * modules/strtoimax (Include): Mention <inttypes.h>.
1177         * modules/strtoumax (Include): Likewise.
1178
1179 2007-04-12  Eric Blake  <ebb9@byu.net>
1180
1181         * .cvsignore: New file.
1182         * .gitignore: Likewise.
1183
1184 2007-04-12  Bruno Haible  <bruno@clisp.org>
1185
1186         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
1187         not before, since $(LDADD) often contains libgnu.a.
1188         * modules/striconv-tests (test_striconv_LDADD): Likewise.
1189         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
1190         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
1191         Needed on Cygwin.
1192
1193 2007-04-12  Eric Blake  <ebb9@byu.net>
1194
1195         Work around glibc's failure to flush stdin on fclose.
1196         * lib/closein.c (close_stdin): Flush stdin before closing.
1197
1198         Work around glibc's failure to reset seekable stdin on exit.
1199         * modules/closein: New module.
1200         * lib/closein.c: New file.
1201         * lib/closein.h: Likewise.
1202         * m4/closein.m4: Likewise.
1203         * MODULES.html.sh (File stream based Input/Output): Document it.
1204
1205 2007-04-12  Simon Josefsson  <simon@josefsson.org>
1206
1207         * gnulib-tool: Rename generated 'autobuild' script to
1208         'do-autobuild' in --create-megatestdir output.
1209
1210         * doc/gnulib.texi (Build robot for gnulib): Fix.
1211
1212 2007-04-12  Simon Josefsson  <simon@josefsson.org>
1213
1214         * modules/sysexits (Depends-on): Add absolute-header.
1215
1216 2007-04-12  Eric Blake  <ebb9@byu.net>
1217
1218         No need to preserve errno on success.
1219         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
1220         Reported by Bruno Haible.
1221
1222 2007-04-12  Simon Josefsson  <simon@josefsson.org>
1223
1224         * MODULES.html.sh (Support for maintaining and releasing
1225         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
1226
1227 2007-04-12  Simon Josefsson  <simon@josefsson.org>
1228
1229         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
1230
1231 2007-04-12  Simon Josefsson  <simon@josefsson.org>
1232
1233         * modules/autobuild: New module.
1234
1235         * m4/autobuild.m4: New file.
1236
1237 2007-04-11  Bruno Haible  <bruno@clisp.org>
1238
1239         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
1240         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
1241         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
1242         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
1243         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
1244         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1245         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1246         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
1247         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1248         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1249         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
1250         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1251         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1252         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
1253         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1254         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1255         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
1256         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1257         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1258         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
1259         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1260         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1261         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
1262         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1263         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1264         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
1265         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
1266         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
1267         Reported by Eric Blake.
1268
1269 2007-04-11  Bruno Haible  <bruno@clisp.org>
1270
1271         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
1272
1273 2007-04-10  Bruno Haible  <bruno@clisp.org>
1274
1275         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
1276         for NaN and Infinity. Needed on FreeBSD 6.1.
1277         * tests/test-vasnprintf-posix.c (test_function): Undo last change
1278         regarding results for "%010a" of Infinity and NaN.
1279         * tests/test-vasprintf-posix.c (test_function): Likewise.
1280         * tests/test-snprintf-posix.h (test_function): Likewise.
1281         * tests/test-sprintf-posix.h (test_function): Likewise.
1282         * tests/test-fprintf-posix.h (test_function): Likewise.
1283         * tests/test-printf-posix.h (test_function): Likewise.
1284         * tests/test-fprintf-posix.out: Likewise.
1285
1286 2007-04-10  Bruno Haible  <bruno@clisp.org>
1287
1288         * modules/locale-tests: New file.
1289         * tests/test-locale.c: New file.
1290
1291         * modules/locale: New file.
1292         * lib/locale_.h: New file.
1293         * m4/locale_h.m4: New file.
1294
1295 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
1296             Bruno Haible  <bruno@clisp.org>
1297
1298         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
1299         be determined, test for availability of the copysignf, copysign,
1300         copysignl functions.
1301         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
1302         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
1303         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
1304
1305 2007-04-09  Eric Blake  <ebb9@byu.net>
1306
1307         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
1308         * modules/stdio (Makefile.am): Support fflush.
1309         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
1310         * modules/fflush: New file.
1311         * lib/fflush.c: Likewise.
1312         * m4/fflush.m4: Likewise.
1313         * modules/fflush-tests: New test.
1314         * tests/test-fflush.c: Likewise.
1315         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
1316
1317 2007-04-06  Bruno Haible  <bruno@clisp.org>
1318
1319         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
1320         (VASNPRINTF): Use signbit for faster determination whether to print a
1321         minus sign.
1322         * modules/vasnprintf (Files): Remove lib/float+.h.
1323         * modules/fprintf-posix (Depends-on): Add signbit.
1324         * modules/snprintf-posix (Depends-on): Likewise.
1325         * modules/sprintf-posix (Depends-on): Likewise.
1326         * modules/vasnprintf-posix (Depends-on): Likewise.
1327         * modules/vasprintf-posix (Depends-on): Likewise.
1328         * modules/vfprintf-posix (Depends-on): Likewise.
1329         * modules/vsnprintf-posix (Depends-on): Likewise.
1330         * modules/vsprintf-posix (Depends-on): Likewise.
1331
1332 2007-04-06  Bruno Haible  <bruno@clisp.org>
1333
1334         * tests/test-frexp.c (main): Test also the sign bit of zero results.
1335         * tests/test-frexpl.c (main): Likewise.
1336         * tests/test-ldexpl.c (main): Likewise.
1337         * modules/frexp-tests (Depends-on): Add signbit.
1338         * modules/frexpl-tests (Depdends-on): Likewise.
1339         * modules/ldexpl-tests (Depdends-on): Likewise.
1340
1341 2007-04-06  Bruno Haible  <bruno@clisp.org>
1342
1343         * modules/signbit-tests: New file.
1344         * tests/test-signbit.c: New file.
1345
1346         * modules/signbit: New file.
1347         * lib/signbitf.c: New file.
1348         * lib/signbitd.c: New file.
1349         * lib/signbitl.c: New file.
1350         * m4/signbit.m4: New file.
1351         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
1352         (signbit): New macro.
1353         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
1354         REPLACE_SIGNBIT.
1355         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
1356         REPLACE_FREXPL into math.h.
1357
1358 2007-04-06  Bruno Haible  <bruno@clisp.org>
1359
1360         * modules/isnanf-nolibm-tests: New file.
1361         * tests/test-isnanf.c: New file.
1362
1363         * modules/isnanf-nolibm: New file.
1364         * lib/isnanf.h: New file.
1365         * lib/isnanf.c: New file.
1366         * lib/isnan.c: Consider the USE_FLOAT macro.
1367         * m4/isnanf.m4: New file.
1368
1369 2007-04-06  Bruno Haible  <bruno@clisp.org>
1370
1371         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
1372         (Link): New section.
1373
1374         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
1375
1376 2007-04-06  Bruno Haible  <bruno@clisp.org>
1377
1378         Assume the 'long double' type.
1379         * m4/longdouble.m4: Remove file.
1380         * config/srclist.txt: Don't mention longdouble.m4.
1381         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
1382         * lib/float+.h: Likewise.
1383         * lib/frexp.c: Likewise.
1384         * lib/printf-args.h: Likewise.
1385         * lib/printf-args.c: Likewise.
1386         * lib/printf-frexp.c: Likewise.
1387         * lib/printf-parse.c: Likewise.
1388         * lib/vasnprintf.c: Likewise.
1389         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
1390         * m4/intl.m4: Likewise.
1391         * m4/isnanl.m4: Likewise.
1392         * m4/printf.m4: Likewise.
1393         * m4/printf-frexpl.m4: Likewise.
1394         * m4/vasnprintf.m4: Likewise.
1395         * modules/allocsa (Files): Remove m4/longdouble.m4.
1396         * modules/gettext (Files): Likewise.
1397         * modules/relocatable-prog-wrapper (Files): Likewise.
1398         * modules/vasnprintf (Files): Likewise.
1399         * modules/isnanl (Files): Likewise.
1400         (Include): Simplify.
1401         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
1402         (Include): Simplify.
1403         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
1404         (Include): Simplify.
1405         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
1406         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1407         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
1408         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1409         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
1410         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1411         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
1412         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1413         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
1414         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1415         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
1416         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
1417         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
1418         * tests/test-isnanl.c: Likewise.
1419         * tests/test-snprintf-posix.h: Likewise.
1420         * tests/test-sprintf-posix.h: Likewise.
1421         * tests/test-vasnprintf-posix.c: Likewise.
1422         * tests/test-vasnprintf-posix2.c: Likewise.
1423         * tests/test-vasprintf-posix.c: Likewise.
1424
1425 2007-04-06  Bruno Haible  <bruno@clisp.org>
1426
1427         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
1428         * lib/math_.h [__DECC]: Include the overridden include file through
1429         #include_next, outside the double-inclusion guard.
1430         * lib/stdio_.h [__DECC]: Likewise.
1431         * lib/stdlib_.h [__DECC]: Likewise.
1432         * lib/string_.h [__DECC]: Likewise.
1433         * lib/time_.h [__DECC]: Likewise.
1434         * lib/wchar_.h [__DECC]: Likewise.
1435         * lib/wctype_.h [__DECC]: Likewise.
1436         * lib/inttypes_.h [__DECC]: Likewise.
1437         Reported by Albert Chin <china@thewrittenword.com> in
1438         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
1439
1440 2007-04-04  Eric Blake  <ebb9@byu.net>
1441
1442         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
1443         1.5.x.
1444
1445 2007-04-04  Bruno Haible  <bruno@clisp.org>
1446
1447         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
1448         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
1449
1450 2007-04-04  Bruno Haible  <bruno@clisp.org>
1451
1452         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
1453         results for "%010a" of Infinity and NaN.
1454         * tests/test-vasprintf-posix.c (test_function): Likewise.
1455         * tests/test-snprintf-posix.h (test_function): Likewise.
1456         * tests/test-sprintf-posix.h (test_function): Likewise.
1457         * tests/test-fprintf-posix.h (test_function): Remove these tests.
1458         * tests/test-printf-posix.h (test_function): Likewise.
1459         * tests/test-fprintf-posix.out: Update.
1460         Needed for FreeBSD 6.1.
1461
1462 2007-04-04  Bruno Haible  <bruno@clisp.org>
1463
1464         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
1465         directly used by the gnulib modules nor by gnulib-tool.
1466
1467 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
1468
1469         * DEPENDENCIES: Give overall description of version dependency
1470         desirability.  Use more-typical names for apps.
1471         Add shell, coreutils, diffutils, grep, tar, gzip.
1472
1473 2007-04-04  Simon Josefsson  <simon@josefsson.org>
1474
1475         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
1476
1477 2007-04-04  Karl Berry  <karl@gnu.org>
1478
1479         * MODULES.html.sh (func_module): missing '.
1480
1481 2007-04-03  Bruno Haible  <bruno@clisp.org>
1482
1483         * modules/argmatch-tests (Makefile.am): New variable
1484         test_argmatch_LDADD.
1485         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
1486         * modules/array-list-tests (Makefile.am): New variable
1487         test_array_list_LDADD.
1488         * modules/array-oset-tests (Makefile.am): New variable
1489         test_array_oset_LDADD.
1490         * modules/avltree-list-tests (Makefile.am): New variable
1491         test_avltree_list_LDADD.
1492         * modules/avltree-oset-tests (Makefile.am): New variable
1493         test_avltree_oset_LDADD.
1494         * modules/avltreehash-list-tests (Makefile.am): New variable
1495         test_avltreehash_list_LDADD.
1496         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
1497         test_canonicalize_lgpl_LDADD.
1498         * modules/carray-list-tests (Makefile.am): New variable
1499         test_carray_list_LDADD.
1500         * modules/dirname-tests (Makefile.am): New variable
1501         test_dirname_LDADD.
1502         * modules/linked-list-tests (Makefile.am): New variable
1503         test_linked_list_LDADD.
1504         * modules/linkedhash-list-tests (Makefile.am): New variable
1505         test_linkedhash_list_LDADD.
1506         * modules/rbtree-list-tests (Makefile.am): New variable
1507         test_rbtree_list_LDADD.
1508         * modules/rbtree-oset-tests (Makefile.am): New variable
1509         test_rbtree_oset_LDADD.
1510         * modules/rbtreehash-list-tests (Makefile.am): New variable
1511         test_rbtreehash_list_LDADD.
1512         * modules/xvasprintf-tests (Makefile.am): New variable
1513         test_xvasprintf_LDADD.
1514         Reported by Eric Blake.
1515
1516 2007-04-03  Eric Blake  <ebb9@byu.net>
1517
1518         * DEPENDENCIES: Weaken m4 requirements.
1519
1520 2007-04-03  Bruno Haible  <bruno@clisp.org>
1521
1522         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
1523         * modules/isnanl-tests (configure.ac): Likewise.
1524
1525 2007-04-03  Ben Pfaff  <blp@gnu.org>
1526
1527         * modules/iconv_open: Add $(srcdir)/ to source directory
1528         references in Makefile fragments that call gperf, to fix VPATH
1529         builds.
1530
1531 2007-04-03  Bruno Haible  <bruno@clisp.org>
1532
1533         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
1534         * lib/ldexpl.c: Undo last change.
1535
1536 2007-04-03  Bruno Haible  <bruno@clisp.org>
1537
1538         * modules/printf-frexpl (Depends-on): Undo last change.
1539         (Files): Add m4/ldexpl.m4.
1540
1541 2007-04-03  Bruno Haible  <bruno@clisp.org>
1542
1543         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
1544         * modules/isnanl (Link): New section.
1545
1546         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
1547         * modules/frexp (Link): New section.
1548
1549         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
1550         * modules/frexpl (Link): New section.
1551
1552         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
1553         * modules/ldexpl (Link): New section.
1554
1555 2007-04-03  Bruno Haible  <bruno@clisp.org>
1556
1557         * modules/TEMPLATE-EXTENDED: New file.
1558         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
1559
1560 2007-04-03  Bruno Haible  <bruno@clisp.org>
1561
1562         * DEPENDENCIES: New file.
1563         Suggested by Simon Josefsson.
1564
1565 2007-04-03  Bruno Haible  <bruno@clisp.org>
1566
1567         * doc/gnulib.texi: Escape @.
1568
1569 2007-04-03  James Youngman  <jay@gnu.org>
1570         and Paul Eggert  <eggert@cs.ucla.edu>
1571
1572         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
1573         birthtime on all systems that have birthtime, not just those which
1574         use st_birthtimensec rather than st_birthtim.  Putting zero in
1575         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
1576         that the birth time is not available for files on an NFS mount.
1577
1578 2007-04-03  Simon Josefsson  <simon@josefsson.org>
1579
1580         * modules/memxor: Move back from crypto/, suggested by Bruno.
1581         * modules/crypto/hmac-sha1: Fix memxor dependency.
1582
1583         * modules/crypto/gc: Moved from ../.
1584
1585 2007-04-02  Eric Blake  <ebb9@byu.net>
1586
1587         * lib/ldexpl.c (includes): Avoid libm.
1588
1589         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
1590
1591 2007-04-02  Bruno Haible  <bruno@clisp.org>
1592
1593         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
1594         on IRIX.
1595
1596 2007-04-02  Bruno Haible  <bruno@clisp.org>
1597
1598         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
1599         x86 or x86_64 platforms running MacOS X.
1600         Reported by Ryan Schmidt <@ryandesign.com>.
1601
1602 2007-04-02  Bruno Haible  <bruno@clisp.org>
1603
1604         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
1605         i386.
1606
1607 2007-04-01  Simon Josefsson  <simon@josefsson.org>
1608
1609         * modules/crypto/arcfour: Moved from ../.
1610         * modules/crypto/arcfour-tests: Moved from ../.
1611         * modules/crypto/arctwo: Moved from ../.
1612         * modules/crypto/arctwo-tests: Moved from ../.
1613         * modules/crypto/des: Moved from ../.
1614         * modules/crypto/des-tests: Moved from ../.
1615         * modules/crypto/gc-arcfour: Moved from ../.
1616         * modules/crypto/gc-arcfour-tests: Moved from ../.
1617         * modules/crypto/gc-arctwo: Moved from ../.
1618         * modules/crypto/gc-arctwo-tests: Moved from ../.
1619         * modules/crypto/gc-des: Moved from ../.
1620         * modules/crypto/gc-des-tests: Moved from ../.
1621         * modules/crypto/gc-hmac-md5: Moved from ../.
1622         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
1623         * modules/crypto/gc-hmac-sha1: Moved from ../.
1624         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
1625         * modules/crypto/gc-md2: Moved from ../.
1626         * modules/crypto/gc-md2-tests: Moved from ../.
1627         * modules/crypto/gc-md4: Moved from ../.
1628         * modules/crypto/gc-md4-tests: Moved from ../.
1629         * modules/crypto/gc-md5: Moved from ../.
1630         * modules/crypto/gc-md5-tests: Moved from ../.
1631         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
1632         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
1633         * modules/crypto/gc-random: Moved from ../.
1634         * modules/crypto/gc-rijndael: Moved from ../.
1635         * modules/crypto/gc-rijndael-tests: Moved from ../.
1636         * modules/crypto/gc-sha1: Moved from ../.
1637         * modules/crypto/gc-sha1-tests: Moved from ../.
1638         * modules/crypto/gc-tests: Moved from ../.
1639         * modules/crypto/hmac-md5: Moved from ../.
1640         * modules/crypto/hmac-md5-tests: Moved from ../.
1641         * modules/crypto/hmac-sha1: Moved from ../.
1642         * modules/crypto/hmac-sha1-tests: Moved from ../.
1643         * modules/crypto/md2: Moved from ../.
1644         * modules/crypto/md2-tests: Moved from ../.
1645         * modules/crypto/md4: Moved from ../.
1646         * modules/crypto/md4-tests: Moved from ../.
1647         * modules/crypto/md5: Moved from ../.
1648         * modules/crypto/md5-tests: Moved from ../.
1649         * modules/crypto/memxor: Moved from ../.
1650         * modules/crypto/rijndael: Moved from ../.
1651         * modules/crypto/rijndael-tests: Moved from ../.
1652         * modules/crypto/sha1: Moved from ../.
1653
1654 2007-03-30  James Youngman  <jay@gnu.org>
1655
1656         * tests/test-stat-time.c (prepare_test): use chmod() rather than
1657         rename() to change the ctime of a file (because ctime is unaffected
1658         by rename on jfs2 on AIX 5.1).
1659         (main): Start by doing cleanup, in case a previous run failed leaving
1660         test files behind.
1661
1662 2007-03-31  Bruno Haible  <bruno@clisp.org>
1663
1664         Support old proprietary implementations of iconv.
1665         * modules/iconv_open: New file.
1666         * lib/iconv_.h: New file.
1667         * m4/iconv_h.m4: New file.
1668         * lib/iconv_open.c: New file.
1669         * lib/iconv_open-aix.gperf: New file.
1670         * lib/iconv_open-hpux.gperf: New file.
1671         * lib/iconv_open-irix.gperf: New file.
1672         * lib/iconv_open-osf.gperf: New file.
1673         * m4/iconv_open.m4: New file.
1674         * modules/linebreak (Depends-on): Add iconv_open.
1675         * modules/striconv (Depends-on): Likewise.
1676         * modules/striconveh (Depends-on): Likewise.
1677         * modules/unicodeio (Depends-on): Likewise.
1678         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
1679         (iconv_t)(-1).
1680         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
1681         conversion if cd is (iconv_t)(-1).
1682         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
1683         is not possible.
1684
1685 2007-03-31  Bruno Haible  <bruno@clisp.org>
1686
1687         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
1688         work on Solaris either. Protect also second use of "autodetect_jp".
1689
1690 2007-03-31  Bruno Haible  <bruno@clisp.org>
1691
1692         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
1693         the function is not present.
1694
1695 2007-03-31  Bruno Haible  <bruno@clisp.org>
1696
1697         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
1698         the function is not present.
1699
1700 2007-03-31  Bruno Haible  <bruno@clisp.org>
1701
1702         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
1703         a bug in HP-UX iconv_open().
1704
1705 2007-03-31  Bruno Haible  <bruno@clisp.org>
1706
1707         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
1708         (Mathematics <math.h>): New section, add fpieee.
1709         (Input/output <stdio.h>): Add fseterr.
1710         (Mathematics <math.h>): New section, add printf-frexp.
1711         (Container data structures): Add sublist.
1712         (Core language properties): Add fpucw, inline.
1713         (Functions for greatest-width integer types <inttypes.h>): Add
1714         imaxabs, imaxdiv, inttypes.
1715         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
1716         isnanl-nolibm, ldexp.
1717         (Mathematics <math.h>): New section, add printf-frexpl.
1718         (Support for systems lacking POSIX:2001): Add fprintf-posix,
1719         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
1720         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
1721         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
1722         (Unicode string functions): Add unistr/u*-mbtoucr.
1723         (Java): Add javacomp-script, javaexec-script.
1724         (C#): Add csharpcomp-script, csharpexec-script.
1725         (Support for building libraries and executables): Add havelib,
1726         relocatable-*.
1727         (Support for maintaining and releasing projects): Renamed from
1728         'Support for maintaining and release projects'. Add announce-gen.
1729
1730 2007-03-31  Bruno Haible  <bruno@clisp.org>
1731
1732         * README: Talk primarily about git.
1733         (git and CVS): Renamed from CVS.
1734         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
1735         gnulib is available through git.
1736         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
1737
1738 2007-03-30  Bruno Haible  <bruno@clisp.org>
1739
1740         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
1741         * lib/poll_.h: Likewise.
1742         * lib/stat_.h: Likewise.
1743         * lib/sys_time_.h: Likewise.
1744         * lib/sysexit_.h: Likewise.
1745         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
1746         * lib/stdbool_.h: Likewise.
1747         * lib/byteswap_.h: Add double-inclusion guard.
1748
1749 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
1750
1751         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
1752
1753 2007-03-30  Karl Berry  <karl@gnu.org>
1754
1755         * config/srclist-update: double space after USA in the license
1756         substitution, since that's how it's usually (?) written.
1757
1758 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
1759
1760         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
1761         reported by Bruno Haible.
1762
1763 2007-03-29  Bruno Haible  <bruno@clisp.org>
1764
1765         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
1766         a bug in AIX iconv().
1767
1768 2007-03-29  Bruno Haible  <bruno@clisp.org>
1769
1770         * modules/ldexpl-tests: New file.
1771         * tests/test-ldexpl.c: New file.
1772
1773 2007-03-29  Bruno Haible  <bruno@clisp.org>
1774
1775         * lib/ldexpl.c: Include fpucw.h.
1776         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
1777         multiplication.
1778         * modules/ldexpl (Depends-on): Add fpucw.
1779
1780 2007-03-29  Bruno Haible  <bruno@clisp.org>
1781
1782         * modules/ldexpl: New file.
1783         * m4/ldexpl.m4: New file.
1784         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
1785         set.
1786         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
1787         REPLACE_LDEXPL.
1788         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
1789         REPLACE_LDEXPL.
1790         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
1791         gl_FUNC_LDEXPL_WORKS.
1792         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
1793         * modules/mathl (Files): Remove lib/ldexpl.c.
1794         (Depends-on): Add ldexpl.
1795
1796 2007-03-29  Bruno Haible  <bruno@clisp.org>
1797
1798         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
1799
1800 2007-03-29  Bruno Haible  <bruno@clisp.org>
1801
1802         * tests/test-striconveh.c (main): Don't assume that a direct conversion
1803         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
1804         and possibly also HP-UX.
1805         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
1806         work on AIX, IRIX, HP-UX, OSF/1.
1807         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
1808         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
1809         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
1810         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
1811         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
1812         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
1813
1814 2007-03-29  Bruno Haible  <bruno@clisp.org>
1815
1816         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
1817
1818 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
1819
1820         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
1821         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
1822
1823 2007-03-29  Eric Blake  <ebb9@byu.net>
1824
1825         * lib/acl-internal.h: Remove redundant include.
1826         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
1827         Cygwin when a file is locked.
1828
1829 2007-03-29  Bruno Haible  <bruno@clisp.org>
1830
1831         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
1832         file.
1833         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
1834
1835 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
1836
1837         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
1838         try to remove a parent directory if the child couldn't be removed
1839         (except for the first rmdir, which could fail because the child
1840         doesn't exist).  Problem reported by Jeff Blaine in
1841         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
1842
1843 2007-03-28  Bruno Haible  <bruno@clisp.org>
1844
1845         * lib/striconveh.c (utf8conv_carefully): New function.
1846         (mem_cd_iconveh_internal): Invoke it.
1847
1848 2007-03-28  Bruno Haible  <bruno@clisp.org>
1849
1850         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
1851         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
1852         input.
1853         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
1854         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
1855         unistr/u8-uctomb.
1856
1857 2007-03-28  Bruno Haible  <bruno@clisp.org>
1858
1859         * modules/unistr/u8-mbtoucr: New file.
1860         * lib/unistr/u8-mbtoucr.c: New file.
1861         * modules/unistr/u16-mbtoucr: New file.
1862         * lib/unistr/u16-mbtoucr.c: New file.
1863         * modules/unistr/u16-mbtoucr: New file.
1864         * lib/unistr/u16-mbtoucr.c: New file.
1865         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
1866
1867 2007-03-27  Simon Josefsson  <simon@josefsson.org>
1868             Bruno Haible  <bruno@clisp.org>
1869
1870         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
1871         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
1872         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
1873
1874         * m4/stdio_h.m4: Add stubs for vasprintf too.
1875
1876         * modules/stdio: Support vasprintf in sed command.
1877
1878         * modules/vasprintf: Depend on stdio for prototypes.  Remove
1879         vasprintf.h.  Add stdio module indicator.
1880
1881         * lib/stdio_.h: Declare asprintf and vasprintf, based on
1882         vasprintf.h.
1883
1884         * lib/vasprintf.h: File removed.
1885
1886         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
1887         * lib/vasprintf.c: Ditto.
1888         * lib/xvasprintf.c: Ditto.
1889         * tests/test-vasprintf-posix.c: Ditto.
1890         * tests/test-vasprintf.c: Ditto.
1891
1892 2007-03-27  Bruno Haible  <bruno@clisp.org>
1893
1894         Make vasnprintf multithread-safe.
1895         * lib/vasnprintf.c (decimal_point_char): New function.
1896         (VASNPRINTF): Use it.
1897         Suggested by Simon Josefsson.
1898
1899 2007-03-27  Eric Blake  <ebb9@byu.net>
1900
1901         Support sub-second birthtime on cygwin.
1902         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
1903         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
1904         (get_stat_birthtime): Also work with st_birthtim.
1905
1906 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
1907
1908         * lib/stat-time.h (USE_BIRTHTIME): Remove.
1909         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
1910         (get_stat_birthtime_ns): Do not try to use "spare" fields.
1911         (get_stat_birthtime_ns): Simplify compile-time tests.
1912         (get_stat_birthtime): Change the API to look like
1913         get_stat_mtime etc., except return a negative tv_nsec on error.
1914         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
1915         Don't check for "spare" fields.
1916         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
1917         or for struct stat.st_birthtime, as these tests aren't used.
1918         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
1919
1920 2007-03-27  Bruno Haible  <bruno@clisp.org>
1921
1922         * lib/stat-time.h: Include <sys/stat.h>.
1923
1924 2007-03-27  James Youngman  <jay@gnu.org>
1925
1926         * lib/stat-time.h (get_stat_birthtime): New function for
1927           retrieving st_birthtime as provided by UFS2 (hence *BSD).
1928         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
1929           and its variants.
1930         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
1931         * modules/stat-time-test: New file.
1932         * tests/test-stat-time.c: New test, devised by Bruno Haible.
1933
1934 2007-03-26  Bruno Haible  <bruno@clisp.org>
1935
1936         Better support of signalling NaNs.
1937         * lib/atanl.c: Include isnanl.h.
1938         (atanl): Perform test for NaN at the beginning of the function and
1939         through a call to isnanl.
1940         * lib/cosl.c: Include isnanl.h.
1941         (cosl): Perform test for NaN at the beginning of the function and
1942         through a call to isnanl.
1943         * lib/ldexpl.c: Include isnanl.h.
1944         (ldexpl): Perform test for NaN through a call to isnanl.
1945         * lib/logl.c: Include isnanl.h.
1946         (logl): Perform test for NaN at the beginning of the function and
1947         through a call to isnanl.
1948         * lib/sinl.c: Include isnanl.h.
1949         (sinl): Perform test for NaN at the beginning of the function and
1950         through a call to isnanl.
1951         * lib/sqrtl.c: Include isnanl.h.
1952         (sqrtl): Perform test for NaN at the beginning of the function and
1953         through a call to isnanl.
1954         * lib/tanl.c: Include isnanl.h.
1955         (tanl): Perform test for NaN at the beginning of the function and
1956         through a call to isnanl.
1957         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
1958         * modules/mathl (Depends-on): Add isnanl.
1959
1960 2007-03-26  Eric Blake  <ebb9@byu.net>
1961
1962         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
1963         regression in logic sense of previous patch.
1964
1965 2007-03-26  Bruno Haible  <bruno@clisp.org>
1966
1967         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
1968         unportable shell command "if ! ...".
1969         Reported by Ralf Wildenhues.
1970
1971 2007-03-25  Bruno Haible  <bruno@clisp.org>
1972
1973         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
1974         <sysexits.h> file, and only add EX_CONFIG.
1975         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
1976         absolute file name and whether it is sufficient. Substitute also
1977         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
1978         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
1979         ABSOLUTE_SYSEXITS_H into sysexits.h.
1980
1981 2007-03-25  Bruno Haible  <bruno@clisp.org>
1982
1983         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
1984         hints is NULL.
1985
1986 2007-03-25  Bruno Haible  <bruno@clisp.org>
1987
1988         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
1989         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
1990
1991 2007-03-25  Bruno Haible  <bruno@clisp.org>
1992
1993         * lib/vasnprintf.c: Include langinfo.h.
1994         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
1995         multithread-safe.
1996         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
1997         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
1998         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
1999         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2000         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2001         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2002         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
2003         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
2004         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2005         Reported by Simon Josefsson.
2006
2007 2007-03-25  Bruno Haible  <bruno@clisp.org>
2008
2009         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
2010         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
2011         * modules/vasnprintf (Depends-on): Add stdint.
2012
2013 2007-03-25  Bruno Haible  <bruno@clisp.org>
2014
2015         * modules/fpieee: New file.
2016         * m4/fpieee.m4: New file.
2017         * modules/isnan-nolibm (Depends-on): Add fpieee.
2018         * modules/isnanl-nolibm (Depends-on): Add fpieee.
2019         * modules/isnanl (Depends-on): Add fpieee.
2020
2021 2007-03-25  Bruno Haible  <bruno@clisp.org>
2022
2023         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
2024
2025 2007-03-25  Bruno Haible  <bruno@clisp.org>
2026
2027         Avoid test failures on IRIX 6.5.
2028         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
2029         (main): Use it.
2030         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
2031         macros.
2032         (main): Use them.
2033
2034 2007-03-25  Bruno Haible  <bruno@clisp.org>
2035
2036         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
2037         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
2038         exists but doesn't work.
2039         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
2040         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
2041         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
2042         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
2043
2044 2007-03-25  Bruno Haible  <bruno@clisp.org>
2045
2046         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
2047         returns inf. Needed on IRIX 6.5.
2048
2049 2007-03-25  Bruno Haible  <bruno@clisp.org>
2050
2051         * tests/test-frexpl.c: Include isnanl-nolibm.h.
2052         (main): Use isnanl instead of x != x idiom.
2053         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
2054
2055         * tests/test-frexp.c: Include isnan.h.
2056         (main): Use isnan instead of x != x idiom.
2057         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
2058
2059 2007-03-25  Bruno Haible  <bruno@clisp.org>
2060
2061         * tests/test-frexp.c (NaN): New function/macro.
2062         (main): Use it instead of 0.0 / 0.0.
2063         * tests/test-isnan.c (NaN): New function/macro.
2064         (main): Use it instead of 0.0 / 0.0.
2065         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
2066         (test_function): Use it instead of 0.0 / 0.0.
2067         * tests/test-vasprintf-posix.c (NaN): New function/macro.
2068         (test_function): Use it instead of 0.0 / 0.0.
2069         * tests/test-snprintf-posix.h (NaN): New function/macro.
2070         (test_function): Use it instead of 0.0 / 0.0.
2071         * tests/test-sprintf-posix.h (NaN): New function/macro.
2072         (test_function): Use it instead of 0.0 / 0.0.
2073         * tests/test-fprintf-posix.h (NaN): New function/macro.
2074         (test_function): Use it instead of 0.0 / 0.0.
2075         * tests/test-printf-posix.h (NaN): New function/macro.
2076         (test_function): Use it instead of 0.0 / 0.0.
2077
2078         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
2079
2080 2007-03-25  Bruno Haible  <bruno@clisp.org>
2081
2082         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
2083
2084 2007-03-25  Bruno Haible  <bruno@clisp.org>
2085
2086         * lib/regexec.c (merge_state_with_log): Make static.
2087
2088 2007-03-25  Bruno Haible  <bruno@clisp.org>
2089
2090         * lib/trigl.c (kernel_rem_pio2): Make static.
2091
2092 2007-03-25  Bruno Haible  <bruno@clisp.org>
2093
2094         * lib/sincosl.c (sincosl_table): Make static.
2095
2096 2007-03-25  Bruno Haible  <bruno@clisp.org>
2097
2098         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
2099         if the compiler does not support C99.
2100
2101 2007-03-25  Bruno Haible  <bruno@clisp.org>
2102
2103         * modules/time (Makefile.am): Ensure all rule action lines start with a
2104         tab.
2105
2106 2007-03-24  Bruno Haible  <bruno@clisp.org>
2107
2108         * modules/tsearch-tests: New file.
2109         * tests/test-tsearch.sh: New file.
2110         * tests/test-tsearch.c: New file, mostly copied from glibc.
2111
2112         * modules/search-tests: New file.
2113         * tests/test-search.c: New file.
2114
2115         * modules/search: New file.
2116         * lib/search_.h: New file, incorporating lib/tsearch.h.
2117         * m4/search_h.m4: New file.
2118         * lib/tsearch.h: Remove file.
2119         * lib/tsearch.c: Include search.h instead of tsearch.h.
2120         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
2121         HAVE_TSEARCH.
2122         * modules/tsearch (Files): Remove lib/tsearch.h.
2123         (Depends-on): Add search.
2124         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
2125         (Include): Change tsearch.h into search.h.
2126
2127 2007-03-24  Bruno Haible  <bruno@clisp.org>
2128
2129         * modules/fpucw: New file.
2130         * lib/fpucw.h: New file.
2131         * lib/frexp.c: Include fpucw.h.
2132         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
2133         (FUNC): Use them.
2134         * lib/printf-frexp.c: Include fpucw.h.
2135         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
2136         (FUNC): Use them.
2137         * lib/vasnprintf.c: Include fpucw.h.
2138         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
2139         'long double' calculations.
2140         * tests/test-frexpl.c: Include fpucw.h.
2141         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
2142         * tests/test-printf-frexpl.c: Include fpucw.h.
2143         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
2144         * modules/frexpl (Depends-on): Add fpucw.
2145         * modules/printf-frexpl (Depends-on): Likewise.
2146         * modules/fprintf-posix (Depends-on): Likewise.
2147         * modules/snprintf-posix (Depends-on): Likewise.
2148         * modules/sprintf-posix (Depends-on): Likewise.
2149         * modules/vasnprintf-posix (Depends-on): Likewise.
2150         * modules/vasprintf-posix (Depends-on): Likewise.
2151         * modules/vfprintf-posix (Depends-on): Likewise.
2152         * modules/vsnprintf-posix (Depends-on): Likewise.
2153         * modules/vsprintf-posix (Depends-on): Likewise.
2154         * modules/frexpl-tests (Depends-on): Likewise.
2155         * modules/printf-frexpl-tests (Depends-on): Likewise.
2156
2157 2007-03-24  Bruno Haible  <bruno@clisp.org>
2158
2159         * lib/float+.h: New file.
2160         * lib/isnan.c: Include float+.h.
2161         (SIZE): New macro.
2162         (FUNC): Compare only SIZE bytes of the value.
2163         * lib/vasnprintf.c: Include float+.h.
2164         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
2165         SIZEOF_LDBL or SIZEOF_DBL bytes.
2166         * modules/isnan-nolibm (Files): Add lib/float+.h.
2167         * modules/isnanl-nolibm (Files): Add lib/float+.h.
2168         * modules/isnanl (Files): Add lib/float+.h.
2169         * modules/vasnprintf (Files): Add lib/float+.h.
2170
2171 2007-03-24  Bruno Haible  <bruno@clisp.org>
2172
2173         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
2174         include isnanl-nolibm.h.
2175
2176 2007-03-24  Bruno Haible  <bruno@clisp.org>
2177
2178         * tests/test-read-file.c (main): Don't produce spurious output for
2179         expected situations. Make the test fail if it encountered unexpected
2180         results.
2181
2182 2007-03-24  Bruno Haible  <bruno@clisp.org>
2183
2184         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
2185         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
2186
2187 2007-03-24  Bruno Haible  <bruno@clisp.org>
2188
2189         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
2190
2191 2007-03-24  Bruno Haible  <bruno@clisp.org>
2192
2193         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
2194         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
2195
2196         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
2197         * modules/utf8-ucs4: Turn into a symbolic link to module
2198         unistr/u8-mbtouc.
2199
2200         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
2201         utf8-ucs4-unsafe.
2202         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
2203         unistr/u8-mbtouc-unsafe.
2204
2205         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
2206         * modules/utf16-ucs4: Turn into a symbolic link to module
2207         unistr/u16-mbtouc.
2208
2209         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
2210         utf16-ucs4-unsafe.
2211         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
2212         unistr/u16-mbtouc-unsafe.
2213
2214         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
2215         * modules/ucs4-utf8: Turn into a symbolic link to module
2216         unistr/u8-ubtomb.
2217
2218         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
2219         * modules/ucs4-utf16: Turn into a symbolic link to module
2220         unistr/u16-ubtomb.
2221
2222 2007-03-24  Bruno Haible  <bruno@clisp.org>
2223
2224         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
2225         Enable the function only if HAVE_INLINE.
2226         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
2227         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
2228         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
2229         Enable the function only if HAVE_INLINE.
2230         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
2231         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
2232         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
2233         Enable the function only if HAVE_INLINE.
2234         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
2235         Enable the function only if HAVE_INLINE.
2236         * modules/utf8-ucs4: Update.
2237         * modules/utf8-ucs4-unsafe: Update.
2238         * modules/utf16-ucs4: Update.
2239         * modules/utf16-ucs4-unsafe: Update.
2240         * modules/ucs4-utf8: Update.
2241         * modules/ucs4-utf16: Update.
2242
2243 2007-03-24  Bruno Haible  <bruno@clisp.org>
2244
2245         * lib/utf8-ucs4.h: Remove file.
2246         * lib/utf8-ucs4-unsafe.h: Remove file.
2247         * lib/utf16-ucs4.h: Remove file.
2248         * lib/utf16-ucs4-unsafe.h: Remove file.
2249         * lib/ucs4-utf8.h: Remove file.
2250         * lib/ucs4-utf16.h: Remove file.
2251         * lib/unistr.h: Include their previous contents.
2252         * m4/utf-ucs4.m4: Remove file.
2253         * m4/ucs4-utf.m4: Remove file.
2254         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
2255         (Depends-on): Add unistr/base.
2256         (configure.ac): Remove gl_UTF_UCS4.
2257         (Makefile.am): Update.
2258         (Include): Change to unistr.h.
2259         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
2260         (Depends-on): Add unistr/base.
2261         (configure.ac): Remove gl_UTF_UCS4.
2262         (Makefile.am): Update.
2263         (Include): Change to unistr.h.
2264         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
2265         (Depends-on): Add unistr/base.
2266         (configure.ac): Remove gl_UTF_UCS4.
2267         (Makefile.am): Update.
2268         (Include): Change to unistr.h.
2269         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
2270         (Depends-on): Add unistr/base.
2271         (configure.ac): Remove gl_UTF_UCS4.
2272         (Makefile.am): Update.
2273         (Include): Change to unistr.h.
2274         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
2275         (Depends-on): Add unistr/base.
2276         (configure.ac): Remove gl_UCS4_UTF.
2277         (Makefile.am): Update.
2278         (Include): Change to unistr.h.
2279         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
2280         (Depends-on): Add unistr/base.
2281         (configure.ac): Remove gl_UCS4_UTF.
2282         (Makefile.am): Update.
2283         (Include): Change to unistr.h.
2284         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
2285         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
2286         utf8-ucs4-unsafe.h.
2287         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
2288         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
2289         utf16-ucs4-unsafe.h.
2290         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
2291         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
2292         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
2293         * lib/unistr/u8-strchr.c: Likewise.
2294         * lib/unistr/u8-strrchr.c: Likewise.
2295         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
2296         * lib/unistr/u16-strchr.c: Likewise.
2297         * lib/unistr/u16-strrchr.c: Likewise.
2298         * lib/striconveh.c: Update.
2299         * lib/linebreak.c: Update.
2300
2301 2007-03-24  Bruno Haible  <bruno@clisp.org>
2302
2303         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
2304         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
2305
2306 2007-03-22  Bruno Haible  <bruno@clisp.org>
2307
2308         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
2309
2310 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
2311
2312         * MODULES.html.sh (File system functions): New module write-any-file.
2313         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
2314         * m4/write-any-file.m4: New files.
2315
2316 2007-03-23  Eric Blake  <ebb9@byu.net>
2317
2318         * gnulib-tool: Rearrange space-tab sequences, since some editors
2319         like to eat them.
2320
2321 2007-03-23  Eric Blake  <ebb9@byu.net>
2322
2323         * lib/version-etc.c (version_etc_va): Update license wording to
2324         be more concise.  Recommended by Richard Stallman.
2325
2326 2007-03-22  Bruno Haible  <bruno@clisp.org>
2327
2328         * lib/poll.c (MSG_PEEK): New fallback definition.
2329
2330 2007-03-22  Bruno Haible  <bruno@clisp.org>
2331
2332         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
2333         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
2334         (main): Update.
2335         Fixes a compilation error on BeOS.
2336
2337 2007-03-22  Bruno Haible  <bruno@clisp.org>
2338
2339         * modules/frexpl-tests: New file.
2340         * tests/test-frexpl.c: New file.
2341
2342         * modules/frexpl: New file.
2343         * m4/frexpl.m4: New file.
2344         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
2345         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
2346         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
2347         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
2348         (Depends-on): Add frexpl. Remove isnanl-nolibm.
2349         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
2350
2351 2007-03-22  Bruno Haible  <bruno@clisp.org>
2352
2353         * lib/frexpl.c: Share code with lib/frexp.c.
2354         * modules/mathl (Files): Add lib/frexp.c.
2355         (Depends-on): Add isnanl-nolibm.
2356
2357 2007-03-22  Bruno Haible  <bruno@clisp.org>
2358
2359         * modules/printf-frexp (Files): Add m4/frexp.m4.
2360         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
2361         only if the found frexp function actually works.
2362
2363 2007-03-22  Bruno Haible  <bruno@clisp.org>
2364
2365         * lib/frexp.c: Remove older implementation that uses divisions.
2366
2367 2007-03-21  Bruno Haible  <bruno@clisp.org>
2368
2369         * modules/frexp-tests: New file.
2370         * tests/test-frexp.c: New file.
2371
2372         * modules/frexp: New file.
2373         * lib/frexp.c: New file.
2374         * m4/frexp.m4: New file.
2375         * lib/math_.h (frexp): New declaration.
2376         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
2377         REPLACE_FREXP.
2378         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
2379
2380 2007-03-21  Bruno Haible  <bruno@clisp.org>
2381
2382         * modules/isnanl-tests: New file.
2383         * tests/test-isnanl.c: New file.
2384
2385         * modules/isnanl: New file.
2386         * lib/isnanl.h: New file.
2387         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
2388         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
2389         gl_FUNC_ISNANL_WORKS.
2390         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
2391         New macros.
2392
2393 2007-03-21  Bruno Haible  <bruno@clisp.org>
2394
2395         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
2396         lib/isnanl.h.
2397         (Include): Update.
2398         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
2399         * lib/vasnprintf.c: Update.
2400         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
2401         tests/test-isnanl.h, remove tests/test-isnanl.c.
2402         (Makefile.am): Update.
2403         * tests/test-isnanl-nolibm.c: New file.
2404         * tests/test-isnanl.h: New file.
2405         * tests/test-isnanl.c: Remove file.
2406
2407 2007-03-21  Jim Meyering  <jim@meyering.net>
2408
2409         When trying to open ".", treat ESTALE like EACCES.
2410         * lib/savewd.c (savewd_save): Resort to forking not just upon
2411         failure with EACCES, but also when errno is ESTALE.
2412
2413 2007-03-20  Bruno Haible  <bruno@clisp.org>
2414
2415         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
2416         Needed on AIX 5.1. Reported by Matthew Woehlke.
2417
2418 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
2419
2420         Suggestions by Bruno Haible:
2421         * lib/acl-internal.h: Include "gettext.h" rather than rolling
2422         our own.
2423         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
2424         * modules/acl (Depends-on): Add gettext.
2425
2426 2007-03-19  Bruno Haible  <bruno@clisp.org>
2427
2428         * modules/iconvme: Remove file.
2429         * lib/iconvme.h: Remove file.
2430         * lib/iconvme.c: Remove file.
2431         * m4/iconvme.m4: Remove file.
2432
2433 2007-03-19  Bruno Haible  <bruno@clisp.org>
2434
2435         * doc/relocatable-maint.texi: Break long shell script line.
2436         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
2437
2438 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
2439
2440         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
2441         handle file_has_acl.
2442         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
2443         * lib/acl.c: Move header inclusions and related macro defns into
2444         lib/acl-internal.h.
2445         (S_ISLNK): Remove defn, since that's now done for us.
2446         (file_has_acl): Move to lib/file-has-acl.c.
2447         Call acl_trivial if available.  This is the crucial part of the fix.
2448         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
2449         shared within the library.  Rewrite a bit, partly to make it compatible
2450         with the GNU coding style.
2451         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
2452         Remove unnecessary double-quotes.
2453         Don't test for acl_to_text; the build will catch that.
2454         Replace acl_entries if it doesn't exist and it is needed.
2455         Check for -lsec and acl_trivial (as used on Solaris 10).
2456         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
2457         lib/file-has-acl.c.
2458         (Depends-on): Add sys_stat, for S_ISLNK.
2459
2460 2007-03-19  Ben Pfaff  <blp@gnu.org>
2461
2462         * doc/gnulib.texi: Fix typos.
2463         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
2464
2465 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
2466
2467         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
2468         If size is zero here, buf must be zero.
2469
2470 2007-03-19  Simon Josefsson  <simon@josefsson.org>
2471
2472         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
2473         <bruno@clisp.org>.
2474
2475 2007-03-18  Bruno Haible  <bruno@clisp.org>
2476
2477         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
2478         Suggested by Eric Blake.
2479
2480 2007-03-18  Ben Pfaff  <blp@gnu.org>
2481
2482         * doc/relocatable.texi: Recommend using as prefix a directory
2483         that does not exist and will never be created.  Based on
2484         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
2485         and others.
2486
2487 2007-03-17  Bruno Haible  <bruno@clisp.org>
2488
2489         * lib/fchownat.c: Include lchown.h.
2490
2491 2007-03-17  Bruno Haible  <bruno@clisp.org>
2492
2493         Fix endless loop when the given allocated size was > INT_MAX.
2494         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
2495         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
2496         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
2497         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
2498         * lib/sprintf.c (sprintf): Likewise.
2499
2500 2007-03-17  Bruno Haible  <bruno@clisp.org>
2501
2502         * tests/test-argp-2.sh (func_compare): Output a context diff.
2503
2504 2007-03-17  Bruno Haible  <bruno@clisp.org>
2505
2506         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
2507         locale's decimal-point character.
2508
2509 2007-03-17  Bruno Haible  <bruno@clisp.org>
2510
2511         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
2512         before comparing it. Needed because on some platforms (e.g. x86) a
2513         'long double' occupies less bytes than sizeof (long double).
2514
2515 2007-03-17  Bruno Haible  <bruno@clisp.org>
2516
2517         * tests/test-crc.c (main): Make printf statements 64-bit clean.
2518         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
2519         * tests/test-getaddrinfo.c (simple): Likewise.
2520         * tests/test-read-file.c (main): Likewise.
2521
2522 2007-03-17  Bruno Haible  <bruno@clisp.org>
2523
2524         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
2525
2526 2007-03-17  Bruno Haible  <bruno@clisp.org>
2527
2528         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
2529         unused variable.
2530
2531 2007-03-17  Bruno Haible  <bruno@clisp.org>
2532
2533         * tests/test-c-strcasecmp.c: Include c-strcase.h.
2534         * tests/test-c-strncasecmp.c: Likewise.
2535
2536 2007-03-17  Bruno Haible  <bruno@clisp.org>
2537
2538         * modules/stdlib (Depends-on): Add unistd.
2539         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
2540         Needed for MacOS X 10.3.
2541
2542 2007-03-17  Bruno Haible  <bruno@clisp.org>
2543
2544         * lib/unistr/u-strdup.h: Include <stdlib.h>.
2545
2546 2007-03-17  Bruno Haible  <bruno@clisp.org>
2547
2548         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
2549
2550 2007-03-17  Bruno Haible  <bruno@clisp.org>
2551
2552         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
2553         to reflect files copied from gnulib (with or without modifications).
2554         Suggested by Jim Meyering.
2555
2556 2007-03-17  Eric Blake  <ebb9@byu.net>
2557
2558         * NEWS: Document stdlib change from 2007-02-18.
2559
2560 2007-03-17  Jim Meyering  <jim@meyering.net>
2561
2562         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
2563         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
2564         someone uses a name containing shell meta-characters.
2565         Reported by Alfred M. Szmidt.
2566
2567         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
2568
2569 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
2570
2571         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
2572         and copy gettext configuration files only if configure.ac contains
2573         a use of AM_GNU_GETTEXT_VERSION.
2574
2575 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
2576
2577         * build-aux/bootstrap (gnulib_name): New variable.
2578         (gnulib_tool_options): Use it.
2579
2580 2007-03-13  Simon Josefsson  <simon@josefsson.org>
2581
2582         * tests/test-des.c: Use new namespace.
2583
2584 2007-03-15  Bruno Haible  <bruno@clisp.org>
2585
2586         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
2587         Reported by James Youngman <jay@gnu.org>.
2588
2589 2007-03-15  Bruno Haible  <bruno@clisp.org>
2590
2591         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
2592         declared prototype. Needed with cc on OSF/1 5.1.
2593
2594 2007-03-15  Bruno Haible  <bruno@clisp.org>
2595
2596         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
2597         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
2598         (struct gl_list_implementation): Add dispose_fn argument to the
2599         'create_empty', 'create' methods.
2600         (struct gl_list_impl_base): Add field 'dispose_fn'.
2601         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
2602         argument.
2603         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
2604         dispose_fn argument.
2605         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
2606         dispose_fn on the dropped values.
2607         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
2608         dispose_fn argument.
2609         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
2610         dropped values.
2611         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
2612         (gl_tree_remove_node): Call dispose_fn on the dropped value.
2613         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
2614         (gl_tree_remove_node): Call dispose_fn on the dropped value.
2615         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
2616         argument.
2617         (gl_tree_list_free): Call dispose_fn on the dropped values.
2618         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
2619         the dropped values.
2620         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
2621         Add dispose_fn argument.
2622         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
2623         Call dispose_fn on the dropped values.
2624         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
2625         Add dispose_fn argument.
2626         (gl_sublist_create): Initialize the 'dispose_fn' field.
2627         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
2628         * tests/test-array_list.c (main): Update.
2629         * tests/test-carray_list.c (main): Update.
2630         * tests/test-avltree_list.c (main): Update.
2631         * tests/test-rbtree_list.c (main): Update.
2632         * tests/test-avltreehash_list.c (main): Update.
2633         * tests/test-rbtreehash_list.c (main): Update.
2634         * tests/test-linked_list.c (main): Update.
2635         * tests/test-linkedhash_list.c (main): Update.
2636         * tests/test-array_oset.c (main): Update.
2637
2638 2007-03-15  Bruno Haible  <bruno@clisp.org>
2639
2640         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
2641         (gl_oset_create_empty): Add dispose_fn argument.
2642         (struct gl_oset_implementation): Add dispose_fn argument to
2643         'create_empty' method.
2644         (struct gl_oset_impl_base): Add dispose_fn field.
2645         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
2646         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
2647         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
2648         values.
2649         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
2650         (gl_tree_oset_free): Call dispose_fn on the dropped values.
2651         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
2652         dropped value.
2653         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
2654         dropped value.
2655         * tests/test-array_oset.c (main): Update.
2656         * tests/test-avltree_oset.c (main): Update.
2657         * tests/test-rbtree_oset.c (main): Update.
2658         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
2659
2660 2007-03-13  Bruno Haible  <bruno@clisp.org>
2661
2662         * tests/test-stdbool.c (i): Update after last patch.
2663
2664 2007-03-12  Bruno Haible  <bruno@clisp.org>
2665
2666         * lib/quotearg.c: Include <wctype.h> early, before the definition of
2667         the iswprint macro. Needed on Solaris 2.5.1.
2668
2669 2007-03-12  Bruno Haible  <bruno@clisp.org>
2670
2671         * tests/test-printf-frexp.c (main): Declare x as volatile.
2672
2673 2007-03-12  Simon Josefsson  <simon@josefsson.org>
2674
2675         * doc/gnulib.texi (Build robot for gnulib): New section.
2676
2677 2007-03-12  Jim Meyering  <jim@meyering.net>
2678
2679         * build-aux/bootstrap: New file.
2680         * build-aux/bootstrap.conf: New file, from coreutils.
2681
2682 2007-03-11  Bruno Haible  <bruno@clisp.org>
2683
2684         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
2685
2686 2007-03-12  Simon Josefsson  <simon@josefsson.org>
2687
2688         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
2689         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
2690         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
2691
2692 2007-03-11  Bruno Haible  <bruno@clisp.org>
2693
2694         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
2695         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
2696
2697 2007-03-11  Bruno Haible  <bruno@clisp.org>
2698
2699         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
2700         formula. Needed for SunPRO C 5.0.
2701
2702 2007-03-11  Bruno Haible  <bruno@clisp.org>
2703
2704         * modules/long-options (Depends-on): Add getopt.
2705
2706 2007-03-11  Bruno Haible  <bruno@clisp.org>
2707
2708         * modules/modechange (Depends-on): Add stdbool.
2709
2710 2007-03-11  Bruno Haible  <bruno@clisp.org>
2711
2712         * modules/i-ring (Depends-on): Add stdbool.
2713
2714 2007-03-11  Bruno Haible  <bruno@clisp.org>
2715
2716         * modules/gc-des (Depends-on): Add stdbool.
2717
2718 2007-03-11  Bruno Haible  <bruno@clisp.org>
2719
2720         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
2721
2722 2007-03-11  Bruno Haible  <bruno@clisp.org>
2723
2724         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
2725
2726 2007-03-11  Bruno Haible  <bruno@clisp.org>
2727
2728         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
2729
2730 2007-03-11  Bruno Haible  <bruno@clisp.org>
2731
2732         * lib/vasnprintf.c (sprintf): Undefine.
2733
2734 2007-03-11  Bruno Haible  <bruno@clisp.org>
2735
2736         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
2737         initializers in SunPRO C and Compaq C compilers.
2738
2739 2007-03-11  Bruno Haible  <bruno@clisp.org>
2740
2741         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
2742         decrementing code ANSI C compliant.
2743
2744 2007-03-11  Bruno Haible  <bruno@clisp.org>
2745
2746         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
2747         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
2748
2749 2007-03-11  Bruno Haible  <bruno@clisp.org>
2750
2751         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
2752         <stdbool.h> substitute doesn't pass.
2753
2754 2007-03-11  Bruno Haible  <bruno@clisp.org>
2755
2756         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
2757
2758 2007-03-11  Bruno Haible  <bruno@clisp.org>
2759
2760         * gnulib-tool (func_create_megatestdir): Create also an autobuild
2761         script, for submission to autobuild.josefsson.org.
2762
2763 2007-03-10  Bruno Haible  <bruno@clisp.org>
2764
2765         * modules/canonicalize-lgpl-tests: New file.
2766         * tests/test-canonicalize-lgpl.sh: New file.
2767         * tests/test-canonicalize-lgpl.c: New file.
2768
2769         * modules/c-strcase-tests: New file.
2770         * tests/test-c-strcase.sh: New file.
2771         * tests/test-c-strcasecmp.c: New file.
2772         * tests/test-c-strncasecmp.c: New file.
2773
2774         * modules/atexit-tests: New file.
2775         * tests/test-atexit.sh: New file.
2776         * tests/test-atexit.c: New file.
2777
2778 2007-03-10  Bruno Haible  <bruno@clisp.org>
2779
2780         * tests/test-binary-io.sh: Use temporary filenames that are not so
2781         likely to clash with those of other tests (in a parallel make).
2782         * tests/test-binary-io.c: Likewise.
2783
2784 2007-03-10  Bruno Haible  <bruno@clisp.org>
2785
2786         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
2787         fallback; use #error instead.
2788         Suggested by Simon Josefsson.
2789
2790 2007-03-10  Bruno Haible  <bruno@clisp.org>
2791
2792         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
2793         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
2794         first and the last.
2795
2796 2007-03-10  Bruno Haible  <bruno@clisp.org>
2797
2798         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
2799
2800 2007-03-10  Bruno Haible  <bruno@clisp.org>
2801
2802         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
2803         "make distcheck".
2804         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
2805         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
2806         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
2807
2808 2007-03-10  Bruno Haible  <bruno@clisp.org>
2809
2810         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
2811         variable.
2812         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
2813         variable.
2814
2815 2007-03-09  Eric Blake  <ebb9@byu.net>
2816         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
2817
2818         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
2819         types are not being provided by gnulib.
2820         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
2821         types are supported.
2822
2823 2007-03-10  Bruno Haible  <bruno@clisp.org>
2824
2825         * lib/stdio_.h (__attribute__): New macro.
2826         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
2827         vsprintf): Specify __attribute__ __format__ for GCC.
2828         Suggested by Eric Blake.
2829
2830 2007-03-09  Bruno Haible  <bruno@clisp.org>
2831
2832         * modules/printf-posix-tests: New file.
2833         * tests/test-printf-posix.sh: New file.
2834         * tests/test-printf-posix.c: New file.
2835
2836         * modules/printf-posix: New file.
2837         * lib/printf.c: New file.
2838         * m4/printf-posix-rpl.m4: New file.
2839         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
2840         REPLACE_PRINTF.
2841         * lib/stdio_.h (printf): New declaration.
2842         (format, __format__, ____printf____, ____scanf____, ____strftime____,
2843         ____strfmon____): New macros.
2844         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
2845         REPLACE_PRINTF.
2846
2847 2007-03-09  Bruno Haible  <bruno@clisp.org>
2848
2849         * tests/test-vasnprintf-posix2.sh: New file.
2850         * tests/test-vasnprintf-posix2.c: New file.
2851         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
2852         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
2853         (Makefile.am): Activate test-vasnprintf-posix2.sh.
2854
2855         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
2856         a locale dependent decimal point, rather than always '.'.
2857
2858 2007-03-09  Eric Blake  <ebb9@byu.net>
2859
2860         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
2861         spite of platforms like Tandem/NSK that define it to -1.
2862
2863 2007-03-08  Bruno Haible  <bruno@clisp.org>
2864
2865         * modules/vprintf-posix-tests: New file.
2866         * tests/test-vprintf-posix.sh: New file.
2867         * tests/test-vprintf-posix.c: New file.
2868         * tests/test-printf-posix.h: New file.
2869
2870         * modules/vprintf-posix: New file.
2871         * lib/vprintf.c: New file.
2872         * m4/vprintf-posix.m4: New file.
2873         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
2874         REPLACE_VPRINTF.
2875         * lib/stdio_.h (vprintf): New declaration.
2876         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
2877         REPLACE_VPRINTF.
2878
2879 2007-03-08  Bruno Haible  <bruno@clisp.org>
2880
2881         * modules/fprintf-posix-tests: New file.
2882         * tests/test-fprintf-posix.sh: New file.
2883         * tests/test-fprintf-posix.c: New file.
2884
2885         * modules/fprintf-posix: New file.
2886         * lib/fprintf.c: New file.
2887         * m4/fprintf-posix.m4: New file.
2888         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
2889         REPLACE_FPRINTF.
2890         * lib/stdio_.h (fprintf): New declaration.
2891         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
2892         REPLACE_FPRINTF.
2893
2894 2007-03-08  Bruno Haible  <bruno@clisp.org>
2895
2896         * modules/vfprintf-posix-tests: New file.
2897         * tests/test-vfprintf-posix.sh: New file.
2898         * tests/test-vfprintf-posix.c: New file.
2899         * tests/test-fprintf-posix.h: New file.
2900         * tests/test-fprintf-posix.out: New file.
2901
2902         * modules/vfprintf-posix: New file.
2903         * lib/vfprintf.c: New file.
2904         * m4/vfprintf-posix.m4: New file.
2905         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
2906         REPLACE_VFPRINTF.
2907         * lib/stdio_.h (vfprintf): New declaration.
2908         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
2909         REPLACE_VFPRINTF.
2910
2911 2007-03-08  Bruno Haible  <bruno@clisp.org>
2912
2913         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
2914
2915 2007-03-08  Bruno Haible  <bruno@clisp.org>
2916
2917         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
2918         instead of 'expr' invocations.
2919         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
2920         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
2921         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
2922         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
2923         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
2924         Suggested by Paul Eggert.
2925
2926 2007-03-08  Bruno Haible  <bruno@clisp.org>
2927
2928         * modules/fseterr-tests: New file.
2929         * tests/test-fseterr.c: New file.
2930
2931         * modules/fseterr: New file.
2932         * lib/fseterr.h: New file.
2933         * lib/fseterr.c: New file.
2934
2935 2007-03-08  Bruno Haible  <bruno@clisp.org>
2936
2937         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
2938         * lib/getopt_.h: Likewise.
2939         * lib/mbswidth.h: Likewise.
2940         * lib/setenv.h: Likewise.
2941         * lib/vasnprintf.h: Likewise.
2942         * lib/vasprintf.h: Likewise.
2943         * lib/verror.h: Likewise.
2944         * lib/xsetenv.h: Likewise.
2945         * lib/xvasprintf.h: Likewise.
2946
2947 2007-03-08  Jim Meyering  <jim@meyering.net>
2948
2949         * users.txt: Add parted.
2950
2951         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
2952
2953 2007-03-07  Bruno Haible  <bruno@clisp.org>
2954
2955         * m4/printf.m4: Make the shell script snippets copy&pastable.
2956
2957 2007-03-02  Bruno Haible  <bruno@clisp.org>
2958
2959         * lib/netinet_in_.h: New file.
2960         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
2961         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
2962         * modules/netinet_in (Files): Add lib/netinet_in_.h.
2963         (Depends-on): Add absolute-header.
2964         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
2965         into netinet/in.h.
2966
2967 2007-03-03  Bruno Haible  <bruno@clisp.org>
2968
2969         * lib/sys_select_.h: New file.
2970         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
2971         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
2972         * modules/sys_select (Files): Add lib/sys_select_.h.
2973         (Depends-on): Add absolute-header.
2974         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
2975         into sys/select.h.
2976
2977 2007-03-02  Bruno Haible  <bruno@clisp.org>
2978
2979         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
2980         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
2981         values.
2982         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
2983         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
2984         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
2985         * modules/sys_socket (Depends-on): Add absolute-header.
2986         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
2987         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
2988         (Include): Remove requirement of inclusion of <sys/types.h>.
2989
2990 2007-03-02  Bruno Haible  <bruno@clisp.org>
2991
2992         * lib/byteswap_.h (bswap_32): Fix formula.
2993
2994 2007-03-06  Bruno Haible  <bruno@clisp.org>
2995
2996         * modules/sprintf-posix-tests: New file.
2997         * tests/test-sprintf-posix.c: New file.
2998
2999         * modules/sprintf-posix: New file.
3000         * lib/sprintf.c: New file.
3001         * m4/sprintf-posix.m4: New file.
3002         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
3003         REPLACE_SPRINTF.
3004         * lib/stdio_.h (sprintf): New declaration.
3005         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
3006         REPLACE_SPRINTF.
3007
3008 2007-03-06  Bruno Haible  <bruno@clisp.org>
3009
3010         * modules/vsprintf-posix-tests: New file.
3011         * tests/test-vsprintf-posix.c: New file.
3012         * tests/test-sprintf-posix.h: New file.
3013
3014         * modules/vsprintf-posix: New file.
3015         * lib/vsprintf.c: New file.
3016         * m4/vsprintf-posix.m4: New file.
3017         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
3018         REPLACE_VSPRINTF.
3019         * lib/stdio_.h (vsprintf): New declaration.
3020         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
3021         REPLACE_VSPRINTF.
3022
3023 2007-03-06  Bruno Haible  <bruno@clisp.org>
3024
3025         * modules/vsnprintf (Depend-on): Remove minmax.
3026
3027 2007-03-06  Bruno Haible  <bruno@clisp.org>
3028
3029         * modules/snprintf-posix-tests: New file.
3030         * tests/test-snprintf-posix.c: New file.
3031
3032         * modules/snprintf-posix: New file.
3033         * m4/snprintf-posix.m4: New file.
3034         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
3035         gl_FUNC_SNPRINTF.
3036         (gl_FUNC_SNPRINTF): Invoke it.
3037         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
3038         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
3039         is set.
3040         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
3041
3042 2007-03-06  Bruno Haible  <bruno@clisp.org>
3043
3044         * modules/vsnprintf-posix-tests: New file.
3045         * tests/test-vsnprintf-posix.c: New file.
3046         * tests/test-snprintf-posix.h: New file.
3047
3048         * modules/vsnprintf-posix: New file.
3049         * m4/vsnprintf-posix.m4: New file.
3050         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
3051         gl_FUNC_VSNPRINTF.
3052         (gl_FUNC_VSNPRINTF): Invoke it.
3053         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
3054         * lib/stdio_.h (vsnprintf): Define as a replacement if
3055         REPLACE_VSNPRINTF is set.
3056         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
3057
3058 2007-03-06  Bruno Haible  <bruno@clisp.org>
3059
3060         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
3061         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
3062
3063 2007-03-06  Bruno Haible  <bruno@clisp.org>
3064
3065         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
3066         (asinl): Declare also if HAVE_DECL_ASINL is set.
3067         (atanl): Declare also if HAVE_DECL_ATANL is set.
3068         (ceill): Declare also if HAVE_DECL_CEILL is set.
3069         (cosl): Declare also if HAVE_DECL_COSL is set.
3070         (expl): Declare also if HAVE_DECL_EXPL is set.
3071         (floorl): Declare also if HAVE_DECL_FLOORL is set.
3072         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
3073         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
3074         (logl): Declare also if HAVE_DECL_LOGL is set.
3075         (sinl): Declare also if HAVE_DECL_SINL is set.
3076         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
3077         (tanl): Declare also if HAVE_DECL_TANL is set.
3078         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
3079         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
3080         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
3081         declaration of frexpl, ldexpl.
3082         * modules/printf-frexpl (Depends-on): Add math.
3083         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
3084
3085 2007-03-05  Bruno Haible  <bruno@clisp.org>
3086
3087         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
3088         frexpl and ldexpl are declared.
3089         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
3090
3091 2007-03-05  Bruno Haible  <bruno@clisp.org>
3092
3093         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
3094         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
3095
3096 2007-03-05  Bruno Haible  <bruno@clisp.org>
3097
3098         * lib/stdio_.h: Include <stddef.h>.
3099
3100 2007-03-05  Bruno Haible  <bruno@clisp.org>
3101
3102         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
3103
3104 2007-03-05  Bruno Haible  <bruno@clisp.org>
3105
3106         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
3107         NetBSD 4, from Ralf Wildenhues.
3108
3109 2007-03-04  Bruno Haible  <bruno@clisp.org>
3110
3111         * lib/vasprintf.h: Update #if logic for the case when the functions
3112         exist but are overridden.
3113
3114 2007-03-04  Bruno Haible  <bruno@clisp.org>
3115
3116         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
3117         implementations: glibc-2.4 and MacOS X 10.3.
3118         * tests/test-vasnprintf-posix.c (test_function): Test also the case
3119         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
3120         * tests/test-vasprintf-posix.c (test_function): Likewise.
3121
3122 2007-03-04  Bruno Haible  <bruno@clisp.org>
3123
3124         * modules/vasprintf-posix-tests: New file.
3125         * tests/test-vasprintf-posix.c: New file.
3126
3127         * modules/vasprintf-posix: New file.
3128         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
3129         defined.
3130         * m4/vasprintf-posix.m4: New file.
3131         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
3132         gl_FUNC_VASPRINTF.
3133         (gl_FUNC_VASPRINTF): Invoke it.
3134         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
3135         here.
3136         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
3137
3138 2007-03-04  Bruno Haible  <bruno@clisp.org>
3139
3140         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
3141         REPLACE_GETTIMEOFDAY.
3142         * modules/sys_time (Makefile.am): Likewise.
3143         * m4/sys_time_h.m4: Likewise.
3144         * m4/gettimeofday.m4: Likewise.
3145
3146 2007-03-04  Bruno Haible  <bruno@clisp.org>
3147
3148         * modules/vasnprintf-posix-tests: New file.
3149         * tests/test-vasnprintf-posix.c: New file.
3150
3151         * modules/vasnprintf-posix: New file.
3152         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
3153         printf-frexpl.h.
3154         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
3155         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
3156         REPLACE_VASNPRINTF is defined.
3157         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
3158         gl_FUNC_VASNPRINTF.
3159         (gl_FUNC_VASNPRINTF): Invoke it.
3160         * m4/vasnprintf-posix.m4: New file.
3161         * m4/printf.m4: New file.
3162
3163 2007-03-04  Bruno Haible  <bruno@clisp.org>
3164
3165         Compile progreloc.c only if --enable-relocatable is specified.
3166         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
3167         if --enable-relocatable was specified.
3168         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
3169         lib_SOURCES.
3170
3171 2007-03-04  Jim Meyering  <jim@meyering.net>
3172
3173         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
3174         Use it consistently, rather than enumerating errno constants.
3175
3176 2007-03-04  Bruno Haible  <bruno@clisp.org>
3177
3178         * modules/xvasprintf-tests: New file.
3179         * tests/test-xvasprintf.c: New file.
3180
3181         * modules/vasprintf-tests: New file.
3182         * tests/test-vasprintf.c: New file.
3183
3184         * modules/vasnprintf-tests: New file.
3185         * tests/test-vasnprintf.c: New file.
3186
3187         * modules/vsnprintf-tests: New file.
3188         * tests/test-vsnprintf.c: New file.
3189
3190         * modules/snprintf-tests: New file.
3191         * tests/test-snprintf.c: New file.
3192
3193 2007-03-04  Bruno Haible  <bruno@clisp.org>
3194
3195         Compile relocatable.c only if --enable-relocatable is specified.
3196         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
3197         gl_RELOCATABLE_LIBRARY.
3198         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
3199         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
3200         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
3201         gl_RELOCATABLE_LIBRARY.
3202         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
3203         (Makefile.am): Remove lib_SOURCES.
3204         * modules/relocatable-lib-lgpl (configure.ac): Invoke
3205         gl_RELOCATABLE_LIBRARY.
3206         (Makefile.am): Remove lib_SOURCES.
3207         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
3208         always.
3209         * modules/relocatable-prog-wrapper (configure.ac): Invoke
3210         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
3211
3212 2007-03-04  Bruno Haible  <bruno@clisp.org>
3213
3214         * modules/argmatch-tests: New file.
3215         * tests/test-argmatch.c: New file.
3216
3217         * tests/test-allocsa.c (main): Halve the number of loop runs.
3218
3219         * modules/alloca-opt-tests: New file.
3220         * tests/test-alloca-opt.c: New file.
3221
3222 2007-03-04  Jim Meyering  <jim@meyering.net>
3223
3224         Work around difference between Linux ACLs and Solaris 10 ZFS.
3225         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
3226         for EINVAL.
3227
3228 2007-03-03  Bruno Haible  <bruno@clisp.org>
3229
3230         * modules/relocatable-prog (Depends-on): Add back progreloc's
3231         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
3232
3233 2007-03-03  Bruno Haible  <bruno@clisp.org>
3234
3235         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
3236         * modules/relocatable-lib: New file.
3237
3238 2007-03-03  Bruno Haible  <bruno@clisp.org>
3239
3240         * modules/relocatable-prog: Renamed from modules/relocatable.
3241         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
3242
3243 2007-03-03  Bruno Haible  <bruno@clisp.org>
3244
3245         * modules/relocatable-script (Files): Add doc/relocatable.texi,
3246         m4/relocatable-lib.m4.
3247         (Depends-on): Remove 'relocatable'.
3248         (configure.ac): Add gl_RELOCATABLE_NOP.
3249
3250 2007-03-03  Bruno Haible  <bruno@clisp.org>
3251
3252         * modules/relocatable-prog-wrapper: New file.
3253         * modules/relocatable (Depends-on): Add it. Remove all other
3254         dependencies except progname.
3255         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
3256
3257         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
3258         (gl_FUNC_STRERROR): Nop.
3259         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
3260
3261         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
3262         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
3263
3264         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
3265         (gl_FUNC_READLINK): Update.
3266
3267         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
3268
3269 2007-03-03  Bruno Haible  <bruno@clisp.org>
3270
3271         * lib/xreadlink.c: Include <unistd.h> unconditionally.
3272         * modules/xreadlink (Depends-on): Add unistd.
3273         * modules/xreadlink-with-size (Depends-on): Likewise.
3274
3275 2007-03-03  Bruno Haible  <bruno@clisp.org>
3276
3277         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
3278         extracted from gt_FUNC_SETENV.
3279         (gt_FUNC_SETENV): Remove macro.
3280         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
3281         remove gt_FUNC_SETENV.
3282
3283 2007-03-03  Bruno Haible  <bruno@clisp.org>
3284
3285         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
3286         ENABLE_RELOCATABLE here.
3287         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
3288
3289 2007-03-03  Bruno Haible  <bruno@clisp.org>
3290
3291         * modules/rbtreehash-list-tests (Depends-on): Add progname.
3292         * tests/test-rbtreehash_list.c: Include progname.h.
3293         (main): Call set_program_name.
3294
3295         * modules/rbtree-oset-tests (Depends-on): Add progname.
3296         * tests/test-rbtree_oset.c: Include progname.h.
3297         (main): Call set_program_name.
3298
3299         * modules/rbtree-list-tests (Depends-on): Add progname.
3300         * tests/test-rbtree_list.c: Include progname.h.
3301         (main): Call set_program_name.
3302
3303         * modules/linked-list-tests (Depends-on): Add progname.
3304         * tests/test-linked_list.c: Include progname.h.
3305         (main): Call set_program_name.
3306
3307 2007-03-03  Bruno Haible  <bruno@clisp.org>
3308
3309         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
3310         All uses of __restrict changed to _Restrict_.
3311         * lib/glob_.h (__restrict): Remove macro.
3312
3313 2007-03-02  Bruno Haible  <bruno@clisp.org>
3314
3315         * modules/gettext (configure.ac): Require gettext infrastructure
3316         from version 0.16.1.
3317
3318 2007-03-02  Bruno Haible  <bruno@clisp.org>
3319
3320         * modules/linkedhash-list-tests (Depends-on): Add progname.
3321         * tests/test-linkedhash_list.c: Include progname.h.
3322         (main): Call set_program_name.
3323
3324         * modules/carray-list-tests (Depends-on): Add progname.
3325         * tests/test-carray_list.c: Include progname.h.
3326         (main): Call set_program_name.
3327
3328         * modules/avltreehash-list-tests (Depends-on): Add progname.
3329         * tests/test-avltreehash_list.c: Include progname.h.
3330         (main): Call set_program_name.
3331
3332         * modules/avltree-oset-tests (Depends-on): Add progname.
3333         * tests/test-avltree_oset.c: Include progname.h.
3334         (main): Call set_program_name.
3335
3336         * modules/avltree-list-tests (Depends-on): Add progname.
3337         * tests/test-avltree_list.c: Include progname.h.
3338         (main): Call set_program_name.
3339
3340         * modules/array-oset-tests (Depends-on): Add progname.
3341         * tests/test-array_oset.c: Include progname.h.
3342         (main): Call set_program_name.
3343
3344         * modules/array-list-tests (Depends-on): Add progname.
3345         * tests/test-array_list.c: Include progname.h.
3346         (main): Call set_program_name.
3347
3348         * modules/argp-tests (Depends-on): Add progname.
3349         * tests/test-argp.c: Include argp.h first. Include progname.h.
3350         (main): Call set_program_name.
3351
3352 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
3353
3354         * doc/gnulib-tool.texi (Initial import): Reword description of
3355         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
3356         limited effect even if defined after the first system include.
3357
3358 2007-03-01  Bruno Haible  <bruno@clisp.org>
3359
3360         * build-aux/config.libpath: Update to libtool-1.5.22.
3361         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
3362
3363 2007-03-01  Bruno Haible  <bruno@clisp.org>
3364
3365         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
3366         foo_CFLAGS.
3367         Reported by Ralf Wildenhues.
3368
3369 2007-03-01  Bruno Haible  <bruno@clisp.org>
3370
3371         * build-aux/install-reloc: Remove object files left over by some
3372         compilers.
3373         Reported by Ralf Wildenhues.
3374
3375 2007-03-01  Bruno Haible  <bruno@clisp.org>
3376
3377         * build-aux/install-reloc: Break long lines.
3378
3379 2007-03-01  Bruno Haible  <bruno@clisp.org>
3380
3381         * doc/relocatable.texi: Document that it may not work on OpenBSD.
3382         Reported by Ralf Wildenhues.
3383
3384 2007-03-01  Bruno Haible  <bruno@clisp.org>
3385
3386         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
3387         include ordering constraints.
3388
3389 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
3390
3391         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
3392         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
3393         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
3394         as another example.
3395         * lib/time_.h: Fix misspelling.
3396         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
3397         Require gl_HEADER_TIME_H_DEFAULTS.
3398         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
3399         * m4/time_r.m4 (gl_TIME_R): Likewise.
3400         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
3401
3402 2007-03-01  Bruno Haible  <bruno@clisp.org>
3403
3404         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
3405         * m4/utimens.m4 (gl_UTIMENS): Likewise.
3406
3407 2007-03-01  Jim Meyering  <jim@meyering.net>
3408
3409         * modules/xreadlink (Maintainer): Add my name.
3410         * modules/xreadlink-with-size (Depends-on): Alphabetize.
3411
3412 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
3413             Bruno Haible  <bruno@clisp.org>
3414
3415         * build-aux/install-reloc: Compile also c-ctype.c.
3416         * build-aux/relocatable.sh.in: New file.
3417         * doc/relocatable.texi: New file.
3418         * doc/relocatable-maint.texi: New file.
3419         * doc/gnulib.texi: Include relocatable-maint.texi.
3420         * lib/progreloc.c: Include unistd.h unconditionally.
3421         * lib/relocwrapper.c: Include unistd.h unconditionally.
3422         Include c-ctype.h.
3423         (add_dotbin): Use c_tolower.
3424         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
3425         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
3426         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
3427         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
3428         to m4/relocatable-lib.m4.
3429         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
3430         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
3431         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
3432         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
3433         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
3434         * modules/relocatable: New file.
3435         * modules/relocatable-lib: New file.
3436         * modules/relocatable-script: New file.
3437
3438 2007-02-28  Bruno Haible  <bruno@clisp.org>
3439
3440         Import --enable-relocatable infrastructure.
3441         * build-aux/config.libpath: New file, from GNU gettext.
3442         * build-aux/install-reloc: New file, from GNU gettext.
3443         * build-aux/reloc-ldflags: New file, from GNU gettext.
3444         * lib/relocatable.h: New file, from GNU gettext.
3445         * lib/relocatable.c: New file, from GNU gettext.
3446         * lib/relocwrapper.c: New file, from GNU gettext.
3447         * m4/relocatable.m4: New file, from GNU gettext.
3448
3449 2007-02-28  Bruno Haible  <bruno@clisp.org>
3450
3451         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
3452
3453         * modules/xreadlink: New file, from GNU gettext with modifications.
3454         * lib/xreadlink.c: New file, from GNU gettext.
3455         * lib/xreadlink.h: Add comments.
3456         (xreadlink): New declaration.
3457
3458         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
3459         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
3460         lib/xreadlink-with-size.c.
3461         (configure.ac): Remove gl_XREADLINK invocation.
3462         (Makefile.am): Augment lib_SOURCES.
3463         * m4/xreadlink.m4: Remove file.
3464         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
3465         (xreadlink_with_size): Renamed from xreadink.
3466         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
3467         * modules/canonicalize (Depends-on): Replace xreadlink with
3468         xreadlink-with-size.
3469         * lib/canonicalize.c (canonicalize_filename_mode): Update.
3470
3471 2007-02-25  Jim Meyering  <jim@meyering.net>
3472
3473         * build-aux/announce-gen: When complaining about excess arguments,
3474         list them.
3475
3476 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
3477
3478         * README: Document signed integer overflow situation more
3479         accurately.
3480
3481 2007-02-25  Bruno Haible  <bruno@clisp.org>
3482
3483         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
3484         'a' or 'A' conversion.
3485
3486 2007-02-25  Bruno Haible  <bruno@clisp.org>
3487
3488         * modules/filename: Renamed from modules/pathname.
3489         (Files): Replace lib/pathname.h with lib/filename.h. Replace
3490         lib/concatpath.c with lib/concat-filename.c.
3491         (Makefile.am): Update.
3492         (Include): Replace pathname.h with filename.h.
3493         * lib/filename.h: Renamed from lib/pathname.h.
3494         (concatenated_filename): Renamed from concatenated_pathname.
3495         * lib/concat-filename.c: Renamed from lib/concatpath.c.
3496         (concatenated_filename): Renamed from concatenated_pathname.
3497         * lib/findprog.c: Include filename.h instead of pathname.h.
3498         (find_in_path): Update.
3499         * lib/javacomp.c: Include filename.h instead of pathname.h.
3500         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
3501         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
3502         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
3503         is_oldgcj_14_13_usable, is_javac_usable): Update.
3504         * lib/javaexec.c: Include filename.h instead of pathname.h.
3505         (execute_java_class): Update.
3506         * modules/findprog: Update.
3507         * modules/javacomp: Update.
3508         * modules/javaexec: Update.
3509         * MODULES.html.sh (File system functions): Add 'filename', remove
3510         'pathname'.
3511
3512 2007-02-25  Bruno Haible  <bruno@clisp.org>
3513
3514         * modules/printf-frexpl-tests: New file.
3515         * tests/test-printf-frexpl.c: New file.
3516
3517         * modules/printf-frexpl: New file.
3518         * lib/printf-frexpl.h: New file.
3519         * lib/printf-frexpl.c: New file.
3520         * m4/printf-frexpl.m4: New file.
3521
3522 2007-02-25  Bruno Haible  <bruno@clisp.org>
3523
3524         * modules/printf-frexp-tests: New file.
3525         * tests/test-printf-frexp.c: New file.
3526
3527         * modules/printf-frexp: New file.
3528         * lib/printf-frexp.h: New file.
3529         * lib/printf-frexp.c: New file.
3530         * m4/printf-frexp.m4: New file.
3531
3532 2007-02-25  Bruno Haible  <bruno@clisp.org>
3533
3534         Assume automake >= 1.10 for the tests.
3535         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
3536         * modules/arctwo-tests: Likewise.
3537         * modules/argp-tests: Likewise.
3538         * modules/avltree-list-tests: Likewise.
3539         * modules/avltree-oset-tests: Likewise.
3540         * modules/avltreehash-list-tests: Likewise.
3541         * modules/carray-list-tests: Likewise.
3542         * modules/crc-tests: Likewise.
3543         * modules/des-tests: Likewise.
3544         * modules/gc-arcfour-tests: Likewise.
3545         * modules/gc-arctwo-tests: Likewise.
3546         * modules/gc-des-tests: Likewise.
3547         * modules/gc-hmac-md5-tests: Likewise.
3548         * modules/gc-hmac-sha1-tests: Likewise.
3549         * modules/gc-md2-tests: Likewise.
3550         * modules/gc-md4-tests: Likewise.
3551         * modules/gc-md5-tests: Likewise.
3552         * modules/gc-pbkdf2-sha1-tests: Likewise.
3553         * modules/gc-rijndael-tests: Likewise.
3554         * modules/gc-sha1-tests: Likewise.
3555         * modules/gc-tests: Likewise.
3556         * modules/getaddrinfo-tests: Likewise.
3557         * modules/hmac-md5-tests: Likewise.
3558         * modules/hmac-sha1-tests: Likewise.
3559         * modules/linked-list-tests: Likewise.
3560         * modules/linkedhash-list-tests: Likewise.
3561         * modules/lock-tests: Likewise.
3562         * modules/md2-tests: Likewise.
3563         * modules/md4-tests: Likewise.
3564         * modules/md5-tests: Likewise.
3565         * modules/rbtree-list-tests: Likewise.
3566         * modules/rbtree-oset-tests: Likewise.
3567         * modules/rbtreehash-list-tests: Likewise.
3568         * modules/read-file-tests: Likewise.
3569         * modules/rijndael-tests: Likewise.
3570         * modules/stdint-tests: Likewise.
3571         * modules/tls-tests: Likewise.
3572
3573 2007-02-24  Bruno Haible  <bruno@clisp.org>
3574
3575         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
3576         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
3577         function; instead check whether isnan with a double argument links.
3578         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
3579         function; instead check whether isnan with a 'long double' argument
3580         links.
3581         Reported by Eric Blake <ebb9@byu.net>.
3582
3583 2007-02-24  Bruno Haible  <bruno@clisp.org>
3584
3585         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
3586         defined.
3587         * lib/isnanl.c: Remove all code. Just include isnan.c.
3588         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
3589
3590 2007-02-25  Jim Meyering  <jim@meyering.net>
3591
3592         Avoid conflicting types for 'unsetenv' on FreeBSD.
3593         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
3594         conflicting with FreeBSD's (5.0 and 6.1) function declaration
3595         in stdlib.h.
3596
3597 2007-02-24  Bruno Haible  <bruno@clisp.org>
3598
3599         * modules/isnanl-nolibm-tests: New file.
3600         * tests/test-isnanl.c: New file.
3601
3602         * modules/isnanl-nolibm: New file.
3603         * lib/isnanl.h: New file.
3604         * lib/isnanl.c: New file.
3605         * m4/isnanl.m4: New file.
3606
3607 2007-02-24  Bruno Haible  <bruno@clisp.org>
3608
3609         * modules/isnan-nolibm-tests: New file.
3610         * tests/test-isnan.c: New file.
3611
3612         * modules/isnan-nolibm: New file.
3613         * lib/isnan.h: New file.
3614         * lib/isnan.c: New file.
3615         * m4/isnan.m4: New file.
3616
3617 2007-02-24  Bruno Haible  <bruno@clisp.org>
3618
3619         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
3620         assume that an exponent fits in 20 bits.
3621
3622 2007-02-24  Jim Meyering  <jim@meyering.net>
3623
3624         * m4/regex.m4: Update the description of the configure-time option,
3625         --without-included-regex, to state accurately what the defaults are,
3626         and perhaps to give people an idea why using this option is risky.
3627
3628 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
3629
3630         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
3631         loops on small arguments.  This attempts to avoid the problem
3632         Bruno Haible reported for AIX 4.3.2 in
3633         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
3634
3635 2007-02-23  Bruno Haible  <bruno@clisp.org>
3636
3637         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
3638         Needed for help2man.
3639
3640 2007-02-23  Karl Berry  <karl@gnu.org>
3641
3642         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
3643         exists, foo.h should be cvs-ignored, not committed.
3644
3645 2007-02-23  Eric Blake  <ebb9@byu.net>
3646
3647         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
3648         * lib/stat-time.h (includes): Likewise.
3649         * lib/utimecmp.c (includes): Likewise.
3650         * lib/utimens.h (includes): Likewise.
3651         * lib/getdate.y (includes): Also include "timespec.h" for use
3652         internal to the module.
3653         * modules/utimens (Depends-on): Revert yesterday's patch.
3654         * modules/nanosleep (Depends-on): Add missing dependency.
3655
3656 2007-02-22  Bruno Haible  <bruno@clisp.org>
3657
3658         * lib/glob.c: Don't include getlogin_r.h.
3659
3660 2007-02-22  Jim Meyering  <jim@meyering.net>
3661
3662         * modules/utimens (Depends-on): Add timespec, required for
3663         utimens.h's inclusion of timespec.h.
3664
3665 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
3666
3667         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
3668         long unreadable paths in GNU/Linux.  Problem reported by Andreas
3669         Schwab in
3670         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
3671         I'll try to think of a better way to fix the Solaris problem.
3672
3673         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
3674         like glibc; on Solaris 10, it fails with errno == EINVAL.
3675         POSIX says the behavior is unspecified if the first argument is NULL,
3676         so play it safe and never pass NULL to the system getcwd.
3677
3678 2007-02-21  Jim Meyering  <jim@meyering.net>
3679
3680         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
3681         of gettimeofday.  It would conflict with the one now always
3682         provided via sys_time_.h.  Reported by Matthew Woehlke, as
3683         an IRIX 6.5 build failure.
3684
3685 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
3686
3687         Minor fixups to port to Solaris 10 with Sun C 5.8.
3688         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
3689         * modules/getcwd (Depends-on): Add dirfd.
3690         * lib/putenv.c (putenv): #undef it.
3691         (rpl_putenv): New decl.
3692         (malloc, free): Include <stdlib.h> rather than prototyping separately.
3693
3694 2007-02-20  Bruno Haible  <bruno@clisp.org>
3695
3696         * modules/stdio-tests: New file.
3697         * tests/test-stdio.c: New file.
3698
3699         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
3700         (Depends-on): Add stdio.
3701         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
3702         (Include): Use <stdio.h> instead of vsnprintf.h.
3703         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
3704         HAVE_DECL_VSNPRINTF.
3705         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
3706
3707         * modules/snprintf (Files): Remove lib/snprintf.h.
3708         (Depends-on): Add stdio.
3709         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
3710         (Include): Use <stdio.h> instead of snprintf.h.
3711         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
3712         HAVE_DECL_SNPRINTF.
3713         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
3714         * lib/getaddrinfo.c: Likewise.
3715
3716         * modules/stdio: New file.
3717         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
3718         * lib/snprintf.h: Remove file.
3719         * lib/vsnprintf.h: Remove file.
3720         * lib/.cppi-disable: Remove snprintf.h.
3721         * m4/stdio_h.m4: New file.
3722         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
3723
3724 2007-02-20  Jim Meyering  <jim@meyering.net>
3725
3726         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
3727         used by e.g., mingw.  From Bruno Haible.
3728
3729 2007-02-19  Bruno Haible  <bruno@clisp.org>
3730
3731         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
3732         warnings.
3733         Reported by Ben Pfaff <blp@cs.stanford.edu>.
3734
3735 2007-02-19  Bruno Haible  <bruno@clisp.org>
3736
3737         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
3738         from mingw users.
3739
3740 2007-02-19  Bruno Haible  <bruno@clisp.org>
3741
3742         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
3743         warnings.
3744         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
3745
3746 2007-02-19  Jim Meyering  <jim@meyering.net>
3747
3748         Don't use FD after a successful "fdopendir (fd)".
3749         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
3750         Reset it by calling dirfd on the just-obtained DIR*.
3751
3752         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
3753         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
3754
3755 2007-02-18  Bruno Haible  <bruno@clisp.org>
3756
3757         * lib/readlink.c: Include <unistd.h>.
3758         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
3759         HAVE_READLINK.
3760         * modules/readlink (Depends-on): Add unistd.
3761         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3762         (Include): Add <unistd.h>.
3763
3764         * lib/getlogin_r.h: Remove file.
3765         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
3766         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
3767         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
3768         HAVE_DECL_GETLOGIN_R.
3769         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
3770         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3771         (Include): Use <unistd.h> instead of getlogin_r.h.
3772
3773         * lib/getcwd.h: Remove file.
3774         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
3775         * lib/xgetcwd.c: Likewise.
3776         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
3777         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
3778         * modules/getcwd (Files): Remove lib/getcwd.h.
3779         (Depends-on): Add unistd.
3780         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3781         (Include): Use <unistd.h> instad of getcwd.h.
3782
3783         * lib/ftruncate.c: Include <unistd.h> first.
3784         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
3785         Set HAVE_FTRUNCATE.
3786         * modules/ftruncate (Depends-on): Add unistd.
3787         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3788
3789         * lib/fchdir.c: Include <unistd.h> first.
3790         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
3791         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
3792         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
3793         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3794         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
3795
3796         * lib/dup2.c: Include <unistd.h> first.
3797         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
3798         HAVE_DUP2.
3799         * modules/dup2 (Depends-on): Add unistd.
3800         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3801
3802         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
3803         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
3804         REPLACE_CHOWN. Don't define chown as a macro here.
3805         * modules/chown (Depends-on): Add unistd.
3806         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
3807
3808         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
3809         Add definition for GL_LINK_WARNING.
3810         (chown, dup2): New declarations.
3811         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
3812         link warning.
3813         (ftruncate): New declaration.
3814         (getcwd): New declaration, taken from old getcwd.h.
3815         (getlogin_r): New declaration, taken from old getlogin_r.h.
3816         (readlink): New declaration.
3817         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
3818         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
3819         (gl_PREREQ_UNISTD): Remove macro.
3820         (gl_UNISTD_MODULE_INDICATOR): New macro.
3821         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
3822         many new variables. Don't set UNISTD_H.
3823         * modules/unistd (Description): Change.
3824         (Depends-on): Add link-warning.
3825         (configure.ac): Update.
3826         (Makefile.am): Create unistd.h always. Substitute many new variables
3827         into it.
3828
3829 2007-02-18  Bruno Haible  <bruno@clisp.org>
3830
3831         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
3832         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
3833         HAVE_GETSUBOPT.
3834         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
3835         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
3836         * lib/getsubopt.h: Remove file.
3837         * modules/getsubopt (Files): Remove lib/getsubopt.h.
3838         (Depends-on): Add stdlib.
3839         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3840         (Includes): Use <stdlib.h> instead of getsubopt.h.
3841         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
3842         Set HAVE_GETSUBOPT.
3843         * lib/getsubopt.c: Don't include getsubopt.h.
3844
3845 2007-02-18  Bruno Haible  <bruno@clisp.org>
3846
3847         * modules/fchdir (Depends-on): Add dup2.
3848
3849 2007-02-18  Bruno Haible  <bruno@clisp.org>
3850
3851         * lib/stdlib_.h: Handle glibc's special invocation convention
3852         specially.
3853
3854 2007-02-18  Bruno Haible  <bruno@clisp.org>
3855
3856         * modules/stdlib-tests: New file.
3857         * tests/test-stdlib.c: New file.
3858
3859         * modules/mkstemp (Files): Remove lib/mkstemp.h.
3860         (Depends-on): Add stdlib.
3861         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3862         (Includes): Use <stdlib.h> instead of mkstemp.h.
3863         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
3864         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
3865         * lib/mkstemp.c: Don't include mkstemp.h.
3866         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
3867         * lib/stdlib--.h: Don't include mkstemp.h.
3868
3869         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
3870         (Depends-on): Add stdlib.
3871         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
3872         (Includes): Use <stdlib.h> instead of mkdtemp.h.
3873         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
3874         HAVE_MKDTEMP.
3875         * lib/mkdtemp.c: Don't include mkdtemp.h.
3876         * lib/clean-temp.c: Don't include mkdtemp.h.
3877
3878         * modules/exit (Files): Remove lib/exit.h.
3879         (Depends-on): Add stdlib.
3880         (Makefile.am): Remove lib_SOURCES.
3881         (Include): Use <stdlib.h> instead of exit.h.
3882         * lib/argmatch.c: Don't include exit.h.
3883         * lib/execute.c: Likewise.
3884         * lib/pagealign_alloc.c: Likewise.
3885         * lib/pipe.c: Likewise.
3886         * lib/wait-process.c: Likewise.
3887         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
3888         * lib/exitfail.c: Likewise.
3889         * lib/savewd.c: Likewise.
3890         * lib/xsetenv.c: Likewise.
3891
3892         * modules/stdlib: New file.
3893         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
3894         and extra comments about mkstemp().
3895         * lib/exit.h: Remove file.
3896         * lib/mkdtemp.h: Remove file.
3897         * lib/mkstemp.h: Remove file.
3898         * m4/stdlib_h.m4: New file.
3899         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
3900
3901 2007-02-18  Bruno Haible  <bruno@clisp.org>
3902
3903         * modules/math-tests: New file.
3904         * tests/test-math.c: New file.
3905
3906         * modules/math: New file.
3907         * modules/mathl (Files): Remove lib/mathl.h.
3908         (Depends-on): Add math.
3909         (Makefile.am): Don't mention mathl.h.
3910         (Include): Use <math.h> instead of mathl.h.
3911         * lib/math_.h: New file.
3912         * lib/mathl.h: Remove file.
3913         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
3914         mathl.h.
3915         * lib/asinl.c: Likewise.
3916         * lib/atanl.c: Likewise.
3917         * lib/ceill.c: Likewise.
3918         * lib/cosl.c: Likewise.
3919         * lib/expl.c: Likewise.
3920         * lib/floorl.c: Likewise.
3921         * lib/frexpl.c: Likewise.
3922         * lib/ldexpl.c: Likewise.
3923         * lib/logl.c: Likewise.
3924         * lib/sincosl.c: Likewise.
3925         * lib/sinl.c: Likewise.
3926         * lib/sqrtl.c: Likewise.
3927         * lib/tanl.c: Likewise.
3928         * lib/trigl.c: Likewise.
3929         * m4/math_h.m4: New file.
3930         * MODULES.html.sh (Mathematics): Add math.
3931
3932 2007-02-17  Bruno Haible  <bruno@clisp.org>
3933
3934         * modules/wctype-tests: New file.
3935         * tests/test-wctype.c: New file.
3936
3937         * modules/wchar-tests: New file.
3938         * tests/test-wchar.c: New file.
3939
3940         * modules/unistd-tests: New file.
3941         * tests/test-unistd.c: New file.
3942
3943         * modules/time-tests: New file.
3944         * tests/test-time.c: New file.
3945
3946         * modules/sysexits-tests: New file.
3947         * tests/test-sysexits.c: New file.
3948
3949         * modules/sys_time-tests: New file.
3950         * tests/test-sys_time.c: New file.
3951
3952         * modules/sys_stat-tests: New file.
3953         * tests/test-sys_stat.c: New file.
3954
3955         * modules/sys_socket-tests: New file.
3956         * tests/test-sys_socket.c: New file.
3957
3958         * modules/sys_select-tests: New file.
3959         * tests/test-sys_select.c: New file.
3960
3961         * modules/string-tests: New file.
3962         * tests/test-string.c: New file.
3963
3964         * modules/stdbool-tests: New file.
3965         * tests/test-stdbool.c: New file.
3966
3967         * modules/netinet_in-tests: New file.
3968         * tests/test-netinet_in.c: New file.
3969
3970         * modules/inttypes-tests: New file.
3971         * tests/test-inttypes.c: New file.
3972
3973         * modules/fcntl-tests: New file.
3974         * tests/test-fcntl.c: New file.
3975
3976         * modules/byteswap-tests: New file.
3977         * tests/test-byteswap.c: New file.
3978
3979         * modules/arpa_inet-tests: New file.
3980         * tests/test-arpa_inet.c: New file.
3981
3982 2007-02-17  Bruno Haible  <bruno@clisp.org>
3983
3984         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
3985         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
3986         if the corresponding module is not enabled. Emit link warnings if
3987         the function is used nevertheless.
3988         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
3989         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
3990         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
3991         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
3992         * modules/inttypes (Depends-on): Add link-warning.
3993         (Makefile.am): Copy the contents of build-aux/link-warning.h into
3994         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
3995         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
3996         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
3997         * modules/imaxdiv (configure.ac): Likewise.
3998         * modules/strtoimax (configure.ac): Likewise.
3999         * modules/strtoumax (configure.ac): Likewise.
4000
4001 2007-02-17  Bruno Haible  <bruno@clisp.org>
4002
4003         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
4004         gl_STRING_MODULE_INDICATOR_DEFAULTS.
4005         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
4006         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
4007
4008 2007-02-17  Bruno Haible  <bruno@clisp.org>
4009
4010         * modules/link-warning: New file.
4011         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
4012         * lib/string_.h (GL_LINK_WARNING): Remove definition.
4013         * modules/string (Depends-on): Add link-warning.
4014         (Makefile.am): Copy the contents of build-aux/link-warning.h into
4015         string.h.
4016         * MODULES.html.sh (Support for building libraries and executables): Add
4017         link-warning.
4018
4019 2007-02-17  Bruno Haible  <bruno@clisp.org>
4020
4021         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
4022         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
4023         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
4024         long lines.
4025
4026 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
4027             Bruno Haible  <bruno@clisp.org>
4028
4029         * modules/tmpfile: New file.
4030         * lib/tmpfile.c: New file.
4031         * m4/tmpfile.m4: New file.
4032         * MODULES.html.sh (func_all_modules): New section "Input/output".
4033
4034 2007-02-15  Bruno Haible  <bruno@clisp.org>
4035
4036         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
4037         (supports_delete_on_close): New function.
4038         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
4039
4040 2007-02-14  Bruno Haible  <bruno@clisp.org>
4041
4042         * modules/mbspcasecmp-tests: New file.
4043         * tests/test-mbspcasecmp.sh: New file.
4044         * tests/test-mbspcasecmp.c: New file.
4045
4046         New module mbspcasecmp.
4047         * modules/mbspcasecmp: New file.
4048         * lib/mbspcasecmp.c: New file.
4049         * lib/string_.h (strncasecmp): Change warning message.
4050         (mbspcasecmp): New declaration.
4051         * m4/mbspcasecmp.m4: New file.
4052         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4053         GNULIB_MBSPCASECMP.
4054         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
4055         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
4056
4057 2007-02-14  Bruno Haible  <bruno@clisp.org>
4058
4059         * modules/mbsncasecmp-tests: New file.
4060         * tests/test-mbsncasecmp.sh: New file.
4061         * tests/test-mbsncasecmp.c: New file.
4062
4063         New module mbsncasecmp.
4064         * modules/mbsncasecmp: New file.
4065         * lib/mbsncasecmp.c: New file.
4066         * lib/string_.h (mbsncasecmp): New declaration.
4067         * m4/mbsncasecmp.m4: New file.
4068         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4069         GNULIB_MBSNCASECMP.
4070         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
4071         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
4072
4073 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
4074
4075         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
4076         Verify that it doesn't overlap with our flags.
4077         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
4078         do not have the desired effect in multibyte locales; instead, use
4079         mbscasecmp.
4080         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
4081         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
4082         we don't require GNU fnmatch ourselves (if our users require it, they
4083         should do so explicitly).
4084
4085         Fix regex code so it doesn't rely on strcasecmp.
4086         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
4087         Otherwise, include gnulib's langinfo.h.
4088         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
4089         undesirable behavior in non-C locales.  Instead, rely on localecharset.
4090         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
4091         * modules/regex (FILES): Remove m4/codeset.m4.
4092         (Depends-on): Add localcharset.  Remove strcase.
4093
4094 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4095
4096         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
4097         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
4098
4099 2007-02-13  Bruno Haible  <bruno@clisp.org>
4100
4101         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
4102         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4103
4104 2007-02-12  Bruno Haible  <bruno@clisp.org>
4105
4106         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
4107         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
4108         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
4109         time warning rather than a link error.
4110
4111 2007-02-12  Bruno Haible  <bruno@clisp.org>
4112
4113         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
4114         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
4115         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
4116
4117 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
4118
4119         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
4120         args, not 2.
4121
4122 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
4123
4124         New module 'time', so that apps can include <time.h> as per
4125         POSIX and GNU instead of separate include files like time_r.h
4126         and timegm.h.  This implementation tries out a simpler approach
4127         for replacing decls in standard include files (as compared to
4128         the string module), somewhat as an experiment.
4129
4130         * config/srclist.txt: Comment out mktime.c for now.
4131         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
4132         since it doesn't apply any more.  Use generic wording instead.
4133         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
4134         'time'.
4135         * lib/time_.h, m4/time_h.m4, modules/time: New files.
4136         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
4137         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
4138         Don't include <sys/types.h>; no longer needed since we assume C89.
4139         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
4140         * lib/strftime.c: Likewise.
4141         * lib/time_r.c: Likewise.
4142         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
4143         * lib/nanosleep.c: Include <time.h> first, to check interface.
4144         * lib/strptime.c: Likewise.
4145         * lib/time_r.c: Likewise.
4146         * lib/timegm.c: Likewise.
4147         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
4148         needed.
4149         * lib/timegm.c: Don't include timegm.h; no longer needed.
4150         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
4151         time.h now handles any problems in that area.
4152         (struct timespec, nanosleep): Remove; time.h now arranges for these.
4153         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
4154         that time.h defines struct timespec.
4155         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
4156         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
4157         handles that.
4158         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
4159         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
4160         needed.  Set REPLACE_LOCALTIME.
4161         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
4162         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
4163         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
4164         nanosleep; time_h.m4 now does that.  Don't require
4165         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
4166         module handles this now.
4167         * modules/getdate (Depends-on): Remove timespec.  Add time.
4168         * modules/nanosleep (Depends-on): Likewise.
4169         * modules/stat-time (Depends-on): Likewise.
4170         * modules/nanosleep (Include): Include time.h, not timespec.h.
4171         * modules/strptime (Files): Remove lib/strptime.h.
4172         (Depends-on): Add extensions, time.
4173         (Include): Include time.h, not strptime.h.
4174         * modules/time_r (Files): Remove lib/time_r.h.
4175         (Depends-on): Add time.
4176         (Include): Include time.h, not time_r.h.
4177         * modules/timegm: Likewise.
4178         * modules/timespec (Description): Now does timespec-related decls
4179         of our own, instead of struct timespec itself.
4180         (Depends-on): Add time; remove extensions.
4181         (Maintainer): Add self.
4182         * modules/utimecmp (Depends-on): Add time; remove timespec.
4183         * modules/utimens (Depends-on): Likewise.
4184         * modules/xnanosleep (Depends-on): Likewise.
4185
4186 2007-02-11  Bruno Haible  <bruno@clisp.org>
4187
4188         * lib/c-strstr.c: Include allocsa.h.
4189         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
4190         * lib/c-strcasestr.c: Include allocsa.h.
4191         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
4192         * lib/strcasestr.c: Include allocsa.h.
4193         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
4194         * lib/mbsstr.c: Include allocsa.h.
4195         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
4196         allocsa/freesa instead of malloc/free.
4197         * lib/mbscasestr.c: Include allocsa.h.
4198         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
4199         allocsa/freesa instead of malloc/free.
4200         * modules/c-strstr (Depends-on): Add allocsa.
4201         * modules/c-strcasestr (Depends-on): Likewise.
4202         * modules/strcasestr (Depends-on): Likewise.
4203         * modules/mbsstr (Depends-on): Likewise.
4204         * modules/mbscasestr (Depends-on): Likewise.
4205
4206 2007-02-11  Bruno Haible  <bruno@clisp.org>
4207
4208         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
4209
4210         * modules/mbsspn-tests: New file.
4211         * tests/test-mbsspn.sh: New file.
4212         * tests/test-mbsspn.c: New file.
4213
4214 2007-02-11  Bruno Haible  <bruno@clisp.org>
4215
4216         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
4217
4218         * modules/mbspbrk-tests: New file.
4219         * tests/test-mbspbrk.sh: New file.
4220         * tests/test-mbspbrk.c: New file.
4221
4222 2007-02-11  Bruno Haible  <bruno@clisp.org>
4223
4224         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
4225         unneeded cast.
4226
4227         * modules/mbscspn-tests: New file.
4228         * tests/test-mbscspn.sh: New file.
4229         * tests/test-mbscspn.c: New file.
4230
4231 2007-02-11  Bruno Haible  <bruno@clisp.org>
4232
4233         * modules/mbscasecmp-tests: New file.
4234         * tests/test-mbscasecmp.sh: New file.
4235         * tests/test-mbscasecmp.c: New file.
4236
4237 2007-02-11  Bruno Haible  <bruno@clisp.org>
4238
4239         Ensure O(n) worst-case complexity of mbscasestr.
4240         * lib/mbscasestr.c: Include stdbool.h.
4241         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
4242         functions.
4243         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
4244         the bookkeeping indicates that it's worth it.
4245         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
4246
4247         * modules/mbscasestr-tests: New file.
4248         * tests/test-mbscasestr1.c: New file.
4249         * tests/test-mbscasestr2.sh: New file.
4250         * tests/test-mbscasestr2.c: New file.
4251         * tests/test-mbscasestr3.sh: New file.
4252         * tests/test-mbscasestr3.c: New file.
4253         * tests/test-mbscasestr4.sh: New file.
4254         * tests/test-mbscasestr4.c: New file.
4255         * m4/locale-tr.m4: New file.
4256
4257 2007-02-11  Bruno Haible  <bruno@clisp.org>
4258
4259         Ensure O(n) worst-case complexity of mbsstr.
4260         * lib/mbsstr.c: Include stdbool.h.
4261         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
4262         functions.
4263         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
4264         bookkeeping indicates that it's worth it.
4265         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
4266
4267         * modules/mbsstr-tests: New file.
4268         * tests/test-mbsstr1.c: New file.
4269         * tests/test-mbsstr2.sh: New file.
4270         * tests/test-mbsstr2.c: New file.
4271         * tests/test-mbsstr3.sh: New file.
4272         * tests/test-mbsstr3.c: New file.
4273         * m4/locale-fr.m4: New file.
4274
4275 2007-02-11  Bruno Haible  <bruno@clisp.org>
4276
4277         * lib/mbsrchr.c (mbsrchr): Fix bug.
4278
4279         * modules/mbsrchr-tests: New file.
4280         * tests/test-mbsrchr.sh: New file.
4281         * tests/test-mbsrchr.c: New file.
4282
4283 2007-02-11  Bruno Haible  <bruno@clisp.org>
4284
4285         * lib/mbschr.c (mbschr): Fix bug.
4286
4287         * modules/mbschr-tests: New file.
4288         * tests/test-mbschr.sh: New file.
4289         * tests/test-mbschr.c: New file.
4290         * m4/locale-zh.m4: New file.
4291
4292 2007-02-11  Bruno Haible  <bruno@clisp.org>
4293
4294         Support for copying multibyte string iterators.
4295         * lib/mbiter.h: Include <string.h>.
4296         (mbiter_multi_copy): New function.
4297         (mbi_copy): New macro.
4298         * lib/mbuiter.h: Include <string.h>.
4299         (mbuiter_multi_copy): New function.
4300         (mbui_copy): New macro.
4301
4302 2007-02-11  Bruno Haible  <bruno@clisp.org>
4303
4304         New module mbslen.
4305         * modules/mbslen: New file.
4306         * lib/mbslen.c: New file.
4307         * lib/string_.h (mbslen): New declaration.
4308         * m4/mbslen.m4: New file.
4309         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4310         GNULIB_MBSLEN.
4311         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
4312         * MODULES.html.sh (Internationalization functions): Add mbslen.
4313
4314 2007-02-11  Bruno Haible  <bruno@clisp.org>
4315
4316         Ensure O(n) worst-case complexity of strcasestr substitute.
4317         * lib/strcasestr.c: Include stdbool.h.
4318         (knuth_morris_pratt): New function.
4319         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
4320         bookkeeping indicates that it's worth it.
4321         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
4322
4323         * modules/strcasestr-tests: New file.
4324         * tests/test-strcasestr.c: New file.
4325
4326 2007-02-11  Bruno Haible  <bruno@clisp.org>
4327
4328         Ensure O(n) worst-case complexity of c_strcasestr.
4329         * lib/c-strcasestr.c: Include stdbool.h, string.h.
4330         (knuth_morris_pratt): New function.
4331         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
4332         the bookkeeping indicates that it's worth it.
4333         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
4334
4335         * modules/c-strcasestr-tests: New file.
4336         * tests/test-c-strcasestr.c: New file.
4337
4338 2007-02-11  Bruno Haible  <bruno@clisp.org>
4339
4340         Ensure O(n) worst-case complexity of c_strstr.
4341         * lib/c-strstr.c: Include stdbool.h, string.h.
4342         (knuth_morris_pratt): New function.
4343         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
4344         bookkeeping indicates that it's worth it.
4345         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
4346
4347         * lib/c-strstr.c: Complete rewrite for maintainability.
4348
4349         * modules/c-strstr-tests: New file.
4350         * tests/test-c-strstr.c: New file.
4351
4352 2007-02-11  Bruno Haible  <bruno@clisp.org>
4353
4354         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
4355         5.2.1 and earlier, whereby \055 was treated just like the range
4356         delimiter '-'.
4357         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
4358
4359 2007-02-08  Bruno Haible  <bruno@clisp.org>
4360
4361         * modules/regex (Depends-on): Add stdbool.
4362         Reported by Dalibor Topic <robilad@kaffe.org>.
4363
4364 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
4365
4366         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
4367         Prefer returning from main to exiting from it.
4368         Remove unnecessary parens after sizeof.
4369
4370 2007-02-05  Bruno Haible  <bruno@clisp.org>
4371
4372         New module mbssep.
4373         * modules/mbssep: New file.
4374         * lib/mbssep.c: New file.
4375         * lib/string_.h (strsep): Add a conditional link warning.
4376         (mbssep): New declaration.
4377         * m4/mbssep.m4: New file.
4378         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4379         GNULIB_MBSSEP.
4380         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
4381         * MODULES.html.sh (Internationalization functions): Add mbssep.
4382
4383 2007-02-05  Bruno Haible  <bruno@clisp.org>
4384
4385         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
4386         Optimize search in case of 1 delimiter.
4387
4388 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
4389
4390         * lib/acl.h: Include sys/types.h before sys/acl.h.
4391
4392 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
4393
4394         Merge upstream fix for glibc bugzilla #3957:
4395
4396         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
4397
4398         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
4399         bit for RE_HAT_LISTS_NOT_NEWLINE.
4400         (build_charclass_op): Remove bogus comment.
4401
4402 2007-02-05  Simon Josefsson  <simon@josefsson.org>
4403
4404         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
4405
4406 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
4407
4408         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
4409         * lib/memmem.c [!defined _LIBC]: Include config.h.
4410
4411 2007-02-04  Bruno Haible  <bruno@clisp.org>
4412
4413         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
4414         warning message.
4415
4416 2007-02-04  Bruno Haible  <bruno@clisp.org>
4417
4418         New module mbstok_r.
4419         * modules/mbstok_r: New file.
4420         * lib/mbstok_r.c: New file.
4421         * lib/string_.h (strtok_r): Change argument names to match the
4422         comments. Add a conditional link warning.
4423         (mbstok_r): New declaration.
4424         * m4/mbstok_r.m4: New file.
4425         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4426         GNULIB_MBSTOK_R.
4427         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
4428         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
4429
4430 2007-02-04  Bruno Haible  <bruno@clisp.org>
4431
4432         New module mbsspn.
4433         * modules/mbsspn: New file.
4434         * lib/mbsspn.c: New file.
4435         * lib/string_.h (strspn): Add a conditional link warning.
4436         (mbsspn): New declaration.
4437         * m4/mbsspn.m4: New file.
4438         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4439         GNULIB_MBSSPN.
4440         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
4441         * MODULES.html.sh (Internationalization functions): Add mbsspn.
4442
4443 2007-02-04  Bruno Haible  <bruno@clisp.org>
4444
4445         New module mbspbrk.
4446         * modules/mbspbrk: New file.
4447         * lib/mbspbrk.c: New file.
4448         * lib/string_.h (strpbrk): Add a conditional link warning.
4449         (mbspbrk): New declaration.
4450         * m4/mbspbrk.m4: New file.
4451         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4452         GNULIB_MBSPBRK.
4453         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
4454         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
4455
4456 2007-02-04  Bruno Haible  <bruno@clisp.org>
4457
4458         New module mbscspn.
4459         * modules/mbscspn: New file.
4460         * lib/mbscspn.c: New file.
4461         * lib/string_.h (strcspn): Add a conditional link warning.
4462         (mbscspn): New declaration.
4463         * m4/mbscspn.m4: New file.
4464         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4465         GNULIB_MBSCSPN.
4466         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
4467         * MODULES.html.sh (Internationalization functions): Add mbscspn.
4468
4469 2007-02-04  Bruno Haible  <bruno@clisp.org>
4470
4471         New module mbscasestr, reduced goal of strcasestr.
4472         * modules/mbscasestr: New file.
4473         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
4474         (mbscasestr): Renamed from strcasestr.
4475         * lib/strcasestr.c: Don't include mbuiter.h.
4476         (strcasestr): Remove support for multibyte locales.
4477         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
4478         Change the conditional link warning.
4479         (mbscasestr): New declaration.
4480         * m4/mbscasestr.m4: New file.
4481         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
4482         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
4483         REPLACE_STRCASESTR.
4484         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
4485         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
4486         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
4487         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
4488         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
4489         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
4490         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
4491         (Depends-on): Remove mbuiter.
4492         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
4493
4494 2007-02-04  Bruno Haible  <bruno@clisp.org>
4495
4496         Simplify handling of strncasecmp.
4497         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
4498         the conditional link warning.
4499         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
4500         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
4501         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
4502         * modules/strcase (configure.ac): Don't invoke
4503         gl_STRING_MODULE_INDICATOR.
4504         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
4505
4506 2007-02-04  Bruno Haible  <bruno@clisp.org>
4507
4508         New module mbscasecmp, reduced goal of strcasecmp.
4509         * modules/mbscasecmp: New file.
4510         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
4511         (mbscasecmp): Renamed from strcasecmp.
4512         * lib/strcasecmp.c: Don't include mbuiter.h.
4513         (strcasecmp): Remove support for multibyte locales.
4514         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
4515         Change the conditional link warning.
4516         (mbscasecmp): New declaration.
4517         * m4/mbscasecmp.m4: New file.
4518         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
4519         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
4520         REPLACE_STRCASECMP.
4521         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
4522         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4523         GNULIB_MBSCASECMP.
4524         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
4525         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
4526         * modules/strcase (Files): Remove m4/mbrtowc.m4.
4527         (Depends-on): Remove mbuiter.
4528         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
4529
4530 2007-02-04  Bruno Haible  <bruno@clisp.org>
4531
4532         New module mbsstr. Remove module strstr.
4533         * modules/mbsstr: New file.
4534         * modules/strstr: Remove file.
4535         * lib/mbsstr.c: Renamed from lib/strstr.c.
4536         (mbsstr): Renamed from strstr.
4537         * lib/string_.h (strstr): Remove declaration. Change the conditional
4538         link warning.
4539         (mbsstr): New declaration.
4540         * m4/mbsstr.m4: New file.
4541         * m4/strstr.m4: Remove file.
4542         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
4543         REPLACE_STRSTR.
4544         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
4545         Don't initialize GNULIB_STRSTR.
4546         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
4547         substitute GNULIB_STRSTR and REPLACE_STRSTR.
4548         * MODULES.html.sh (Internationalization functions): Add mbsstr.
4549         (Support for systems lacking ANSI C 89): Remove strstr.
4550
4551 2007-02-04  Bruno Haible  <bruno@clisp.org>
4552
4553         New module mbsrchr.
4554         * modules/mbsrchr: New file.
4555         * lib/mbsrchr.c: New file.
4556         * lib/string_.h (strrchr): Add a conditional link warning.
4557         (mbsrchr): New declaration.
4558         * m4/mbsrchr.m4: New file.
4559         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4560         GNULIB_MBSRCHR.
4561         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
4562         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
4563
4564 2007-02-04  Bruno Haible  <bruno@clisp.org>
4565
4566         New module mbschr.
4567         * modules/mbschr: New file.
4568         * lib/mbschr.c: New file.
4569         * lib/string_.h (strchr): Add a conditional link warning.
4570         (mbschr): New declaration.
4571         * m4/mbschr.m4: New file.
4572         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
4573         GNULIB_MBSCHR.
4574         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
4575         * MODULES.html.sh (Internationalization functions): Add mbschr.
4576
4577 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
4578
4579         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
4580
4581         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
4582
4583 2007-02-04  Bruno Haible  <bruno@clisp.org>
4584
4585         New module description section 'configure.ac-early'.
4586         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
4587         (func_get_autoconf_early_snippet): New function.
4588         (func_import, func_create_testdir): Use it. Remove special cases for
4589         modules 'extensions' and 'lock'.
4590         * modules/extensions (configure.ac-early): Require
4591         gl_USE_SYSTEM_EXTENSIONS.
4592         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
4593
4594 2007-02-04  Bruno Haible  <bruno@clisp.org>
4595
4596         Make use of gcj-4.3's -fsource and -ftarget option.
4597         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
4598         and if so try the options -fsource and -ftarget.
4599         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
4600         source_version, ftarget_option, target_version arguments.
4601         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
4602         (is_envjavac_oldgcj_14_14_usable): Renamed from
4603         is_envjavac_gcj_14_14_usable.
4604         (is_envjavac_oldgcj_14_13_usable): Renamed from
4605         is_envjavac_gcj_14_13_usable.
4606         (is_gcj_present): Update.
4607         (is_gcj_43, is_gcj43_usable): New functions.
4608         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
4609         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
4610         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
4611         try the options -fsource and -ftarget.
4612
4613 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
4614
4615         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
4616         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
4617         larger value.
4618
4619 2007-02-03  Jim Meyering  <jim@meyering.net>
4620
4621         Give tools a better chance to allocate space for very large buffers.
4622         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
4623
4624         Make pwd and readlink work also when run with an unreadable parent dir
4625         on systems with openat support.
4626         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
4627         provided getcwd function, even when we have openat support.
4628         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
4629
4630 2007-02-02  Bruno Haible  <bruno@clisp.org>
4631
4632         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
4633         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
4634         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
4635         portability problems if one of these functions is only used on specific
4636         platforms.
4637         Reported by Paul Eggert.
4638
4639 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
4640
4641         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
4642         is causing more trouble than it's curing.
4643         * lib/regex_internal.h (__mempcpy): Remove.
4644         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
4645         (and make the code a tad smaller to boot).
4646         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
4647
4648 2007-02-02  Jim Meyering  <jim@meyering.net>
4649
4650         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
4651         section, not in the Makefile.am: one.
4652
4653 2007-02-02  Eric Blake  <ebb9@byu.net>
4654
4655         * lib/strchrnul.c: Always include config.h first.
4656
4657         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
4658         gnulib strstr is not necessary here.
4659
4660 2007-02-02  Simon Josefsson  <simon@josefsson.org>
4661
4662         * m4/socklen.m4: Fix typo.
4663
4664 2007-02-02  Eric Blake  <ebb9@byu.net>
4665
4666         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
4667         * modules/netinet_in (Makefile.am): Likewise.
4668
4669 2007-02-01  Bruno Haible  <bruno@clisp.org>
4670
4671         * lib/string_.h (GL_LINK_WARNING): New macro.
4672         (strcasecmp, strstr, strcasestr): If provided by the system,
4673         conditionally define as a macro that leads to a warning instead of to
4674         an error.
4675         (strncasecmp): Conditionally define as a macro that leads to a warning.
4676
4677 2007-02-01  Karl Berry  <karl@gnu.org>
4678
4679         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
4680
4681 2007-02-01  Bruno Haible  <bruno@clisp.org>
4682
4683         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
4684         renamings.
4685
4686 2007-02-01  Eric Blake  <ebb9@byu.net>
4687
4688         * modules/regex (Depends-on): Revert dependence on mempcpy.
4689         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
4690         module's definition of mempcpy.
4691         Reported by Paul Eggert.
4692
4693 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
4694
4695         * lib/string_.h: If the gnulib module XYZ is not present, undefine
4696         the symbol XYZ before redefining it.  This fixes a problem with
4697         programs that don't use XYZ, when compiled on systems that define
4698         XYZ to something else.
4699
4700 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
4701
4702         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
4703         occurs when "mkdir -m foo" creates a setgid directory that is (1)
4704         writeable to group or other and (2) is intended to have a special
4705         mode bit that is set or cleared.  In such a case, the directory
4706         should be neither group- nor other-writeable until the special
4707         mode bits are right.
4708
4709 2007-01-31  Eric Blake  <ebb9@byu.net>
4710
4711         * modules/mountlist (Depends-on): Add strstr.
4712
4713         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
4714         bug.
4715         * modules/string (Makefile.am): Remove redundant replacement.
4716         * modules/regex (Depends-on): Add mempcpy.
4717
4718 2007-01-31  Bruno Haible  <bruno@clisp.org>
4719
4720         New module description field 'Link'.
4721         * gnulib-tool (func_usage): Document --extract-link-directive.
4722         (sed_extract_prog): Recognize 'Link' directive.
4723         (func_get_link_directive): New function.
4724         (func_import): Show summary of link directives.
4725         Handle --extract-link-directive option.
4726         * modules/acl (Link): New section.
4727         * modules/clock-time (Link): New section.
4728         * modules/euidaccess (Link): New section.
4729         * modules/gettext (Link): New section.
4730         * modules/iconv (Link): New section.
4731         * modules/lock (Link): New section.
4732         * modules/nanosleep (Link): New section.
4733         * modules/readline (Link): New section.
4734
4735 2007-01-27  Bruno Haible  <bruno@clisp.org>
4736
4737         Enforce the use of gnulib modules for unportable <string.h> functions.
4738         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
4739         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
4740         (gl_HEADER_STRING_H_BODY): Require it.
4741         * lib/string_.h: If the gnulib module XYZ is not present, redefine
4742         the symbol XYZ to one that gives a link error.
4743         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
4744         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
4745         * modules/mempcpy (configure.ac): Likewise.
4746         * modules/memrchr (configure.ac): Likewise.
4747         * modules/stpcpy (configure.ac): Likewise.
4748         * modules/stpncpy (configure.ac): Likewise.
4749         * modules/strcase (configure.ac): Likewise.
4750         * modules/strcasestr (configure.ac): Likewise.
4751         * modules/strchrnul (configure.ac): Likewise.
4752         * modules/strdup (configure.ac): Likewise.
4753         * modules/strndup (configure.ac): Likewise.
4754         * modules/strnlen (configure.ac): Likewise.
4755         * modules/strpbrk (configure.ac): Likewise.
4756         * modules/strsep (configure.ac): Likewise.
4757         * modules/strstr (configure.ac): Likewise.
4758         * modules/strtok_r (configure.ac): Likewise.
4759
4760 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
4761
4762         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
4763
4764 2007-01-30  Jim Meyering  <jim@meyering.net>
4765
4766         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
4767
4768 2007-01-29  Bruno Haible  <bruno@clisp.org>
4769
4770         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
4771         * lib/execute.c: Likewise.
4772         * lib/pipe.c: Likewise.
4773         * lib/printf-args.h: Likewise.
4774         * lib/printf-args.c: Likewise.
4775         * lib/printf-parse.c: Likewise.
4776         * lib/vasnprintf.c: Likewise.
4777
4778 2007-01-29  Eric Blake  <ebb9@byu.net>
4779
4780         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
4781         declaration.
4782
4783 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
4784
4785         * lib/strptime.h (strptime): Use 'restrict' for args where
4786         POSIX requires this.
4787         * lib/strptime.c (strptime): Likewise.
4788         Change license notice from LGPL to GPL, since gnulib-tool will
4789         change this as needed.
4790         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
4791         defined.
4792         Include "strptime.h" first, to check interface.
4793         Do not #undef _LIBC and _NL_CURRENT.
4794         Do not include <stdlib.h>; no longer needed.
4795         Include "time_r.h" and declare ptime_locale_status
4796         only if _LIBC is not defined.
4797         (__P): Remove unused macro.
4798         (match_string): Bring back glibc version, but use it only if _LIBC
4799         is defined.
4800         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
4801         Remove unnecessary assertion and abort() call.
4802         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
4803         * m4/strptime.m4: Fix serial number comment.
4804         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
4805         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
4806         (Depends-on): Add time_r.
4807
4808 2007-01-29  Bruno Haible  <bruno@clisp.org>
4809
4810         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
4811         strptime.
4812         * modules/strptime (Depends-on): Add stdbool.
4813         * lib/strptime.h: Include <time.h> always. Add comments.
4814
4815 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
4816
4817         * modules/strptime: New file.
4818         * lib/strptime.h: New file.
4819         * lib/strptime.c: New file.
4820         * m4/strptime.m4: New file.
4821
4822 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
4823
4824         * MODULES.html.sh: New module mpsort.
4825         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
4826
4827         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
4828         a circularity problem with HP-UX ia64 reported by Bob Proulx in
4829         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
4830         All uses changed.
4831         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
4832         All uses changed.
4833         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
4834         to _Restrict_.
4835         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
4836         the parameter matches the prototype.
4837
4838 2007-01-28  Jim Meyering  <jim@meyering.net>
4839
4840         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
4841         sys/time.h here, reverting that part of the previous patch:
4842         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
4843
4844 2007-01-28  Bruno Haible  <bruno@clisp.org>
4845
4846         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
4847         value of $(SYS_TIME_H).
4848         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
4849         remove it conditionally, too. [added by Jim Meyering]
4850         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
4851         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
4852         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
4853         GETTIMEOFDAY_REPLACEMENT to 1.
4854
4855 2007-01-28  Bruno Haible  <bruno@clisp.org>
4856
4857         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
4858         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
4859         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
4860         Set UNISTD_H instead of UNISTD_H2.
4861         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
4862
4863 2007-01-28  Bruno Haible  <bruno@clisp.org>
4864
4865         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
4866         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
4867
4868 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4869
4870         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
4871         (func_create_testdir): Ensure C locale for `grep' and `tr'
4872         character ranges.
4873         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
4874         ACLOCAL_AMFLAGS parsing state machine.
4875
4876 2007-01-27  Bruno Haible  <bruno@clisp.org>
4877
4878         * modules/unistr/base: Update.
4879
4880 2007-01-27  Bruno Haible  <bruno@clisp.org>
4881
4882         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
4883         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
4884         * modules/unistr/u32-mbtouc-unsafe: Renamed from
4885         modules/unistr/u32-mbtouc.
4886         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
4887         * lib/unistr.h: Update.
4888         * lib/linebreak.c: Update.
4889         * modules/unistr/u32-mbtouc: Renamed from
4890         modules/unistr/u32-mbtouc-safe.
4891         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
4892         * lib/unistr.h: Update.
4893         * lib/unistr/u32-to-u8.c: Update.
4894         * lib/unistr/u32-to-u16.c: Update.
4895
4896 2007-01-27  Bruno Haible  <bruno@clisp.org>
4897
4898         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
4899         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
4900         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
4901         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
4902         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
4903         * modules/unistr/u16-mbtouc-unsafe: Renamed from
4904         modules/unistr/u16-mbtouc.
4905         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
4906         * lib/unistr.h: Update.
4907         * lib/linebreak.c: Update.
4908         * modules/linebreak: Update.
4909         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
4910         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
4911         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
4912         * modules/unistr/u16-mbtouc: Renamed from
4913         modules/unistr/u16-mbtouc-safe.
4914         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
4915         * lib/unistr.h: Update.
4916         * lib/unistr/u16-to-u8.c: Update.
4917         * modules/unistr/u16-to-u8: Update.
4918         * lib/unistr/u16-to-u32.c: Update.
4919         * modules/unistr/u16-to-u32: Update.
4920
4921 2007-01-27  Bruno Haible  <bruno@clisp.org>
4922
4923         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
4924         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
4925         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
4926         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
4927         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
4928         * modules/unistr/u8-mbtouc-unsafe: Renamed from
4929         modules/unistr/u8-mbtouc.
4930         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
4931         * lib/unistr.h: Update.
4932         * lib/striconveh.c: Update.
4933         * modules/striconveh: Update.
4934         * lib/linebreak.c: Update.
4935         * modules/linebreak: Update.
4936         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
4937         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
4938         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
4939         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
4940         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
4941         * lib/unistr.h: Update.
4942         * lib/striconveh.c: Update.
4943         * modules/striconveh: Update.
4944         * lib/unistr/u8-to-u16.c: Update.
4945         * modules/unistr/u8-to-u16: Update.
4946         * lib/unistr/u8-to-u32.c: Update.
4947         * modules/unistr/u8-to-u32: Update.
4948
4949 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4950
4951         Sync from Libtool.
4952         * lib/argz.c: Do not include strings.h nor memory.h, include
4953         string.h unconditionally.  Patch by Simon Josefsson.
4954
4955 2007-01-27  Bruno Haible  <bruno@clisp.org>
4956
4957         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
4958         from gl_HEADER_STRING_H_BODY.
4959         (gl_HEADER_STRING_H_BODY): Require it.
4960         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
4961         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
4962         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
4963         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
4964         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
4965         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
4966         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
4967         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
4968         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
4969         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
4970         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
4971         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
4972         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
4973         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
4974         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
4975
4976 2007-01-27  Bruno Haible  <bruno@clisp.org>
4977
4978         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
4979         check_PROGRAMS into noinst_PROGRAMS.
4980         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
4981         check_PROGRAMS in this case.
4982         (func_import): Set for_test to false.
4983         (func_create_testdir): Set for_test to true.
4984
4985 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
4986             Bruno Haible  <bruno@clisp.org>
4987
4988         * modules/strcasestr (Files): Remove lib/strcasestr.h.
4989         (Depends-on): Add string.
4990         (Includes): Use <string.h> instead of strcasestr.h.
4991         * modules/string (Makefile.am): Also substitute the value of
4992         REPLACE_STRCASESTR.
4993         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
4994         assume strcasestr is declared in <string.h> not <strings.h>. Also
4995         set REPLACE_STRCASESTR.
4996         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
4997         REPLACE_STRCASESTR.
4998         * lib/strcasestr.h: Remove file.
4999         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
5000         * lib/string_.h (strcasestr): New declaration.
5001
5002 2007-01-27  Bruno Haible  <bruno@clisp.org>
5003
5004         * lib/string_.h: Use 'extern'.
5005
5006 2007-01-27  Jim Meyering  <jim@meyering.net>
5007
5008         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
5009         of set-but-not-used local, "q".
5010
5011         * lib/mempcpy.c: Include <config.h> before <string.h>.
5012         This fixes a compilation error on HP-UX, due to the system's
5013         "restrict"-using mempcpy prototype.
5014
5015 2007-01-26  Bruno Haible  <bruno@clisp.org>
5016
5017         Small optimization.
5018         * lib/javacomp.c: Include c-strstr.h.
5019          (is_envjavac_gcj): Use c_strstr instead of strstr.
5020         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
5021
5022 2007-01-26  Bruno Haible  <bruno@clisp.org>
5023
5024         * MODULES.html.sh (Unicode string functions): Add the new modules.
5025
5026         * modules/uniconv/u32-strconv-to-locale: New file.
5027         * lib/uniconv/u32-strconv-to-locale.c: New file.
5028
5029         * modules/uniconv/u16-strconv-to-locale: New file.
5030         * lib/uniconv/u16-strconv-to-locale.c: New file.
5031
5032         * modules/uniconv/u8-strconv-to-locale: New file.
5033         * lib/uniconv/u8-strconv-to-locale.c: New file.
5034
5035         * modules/uniconv/u32-strconv-from-locale: New file.
5036         * lib/uniconv/u32-strconv-from-locale.c: New file.
5037
5038         * modules/uniconv/u16-strconv-from-locale: New file.
5039         * lib/uniconv/u16-strconv-from-locale.c: New file.
5040
5041         * modules/uniconv/u8-strconv-from-locale: New file.
5042         * lib/uniconv/u8-strconv-from-locale.c: New file.
5043
5044         * modules/uniconv/u32-strconv-to-enc: New file.
5045         * lib/uniconv/u32-strconv-to-enc.c: New file.
5046         * modules/uniconv/u32-strconv-to-enc-tests: New file.
5047         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
5048
5049         * modules/uniconv/u16-strconv-to-enc: New file.
5050         * lib/uniconv/u16-strconv-to-enc.c: New file.
5051         * lib/uniconv/u-strconv-to-enc.h: New file.
5052         * modules/uniconv/u16-strconv-to-enc-tests: New file.
5053         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
5054
5055         * modules/uniconv/u8-strconv-to-enc: New file.
5056         * lib/uniconv/u8-strconv-to-enc.c: New file.
5057         * modules/uniconv/u8-strconv-to-enc-tests: New file.
5058         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
5059
5060         * modules/uniconv/u32-strconv-from-enc: New file.
5061         * lib/uniconv/u32-strconv-from-enc.c: New file.
5062         * modules/uniconv/u32-strconv-from-enc-tests: New file.
5063         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
5064
5065         * modules/uniconv/u16-strconv-from-enc: New file.
5066         * lib/uniconv/u16-strconv-from-enc.c: New file.
5067         * modules/uniconv/u16-strconv-from-enc-tests: New file.
5068         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
5069
5070         * modules/uniconv/u8-strconv-from-enc: New file.
5071         * lib/uniconv/u8-strconv-from-enc.c: New file.
5072         * lib/uniconv/u-strconv-from-enc.h: New file.
5073         * modules/uniconv/u8-strconv-from-enc-tests: New file.
5074         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
5075
5076         * modules/uniconv/u32-conv-from-enc: New file.
5077         * lib/uniconv/u32-conv-from-enc.c: New file.
5078         * modules/uniconv/u32-conv-from-enc-tests: New file.
5079         * tests/uniconv/test-u32-conv-from-enc.c: New file.
5080
5081         * modules/uniconv/u16-conv-from-enc: New file.
5082         * lib/uniconv/u16-conv-from-enc.c: New file.
5083         * lib/uniconv/u-conv-from-enc.h: New file.
5084         * modules/uniconv/u16-conv-from-enc-tests: New file.
5085         * tests/uniconv/test-u16-conv-from-enc.c: New file.
5086
5087         * modules/uniconv/u8-conv-from-enc: New file.
5088         * lib/uniconv/u8-conv-from-enc.c: New file.
5089         * modules/uniconv/u8-conv-from-enc-tests: New file.
5090         * tests/uniconv/test-u8-conv-from-enc.c: New file.
5091
5092         * modules/uniconv/base: New file.
5093         * lib/uniconv.h: New file.
5094
5095 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
5096
5097         * doc/gnulib-tool.texi (Initial import): Update to match current
5098         behavior with strdup module.
5099         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
5100         * lib/memmem.h: Remove; all uses removed.  This is now done
5101         by <string.h>.
5102         * lib/mempcpy.h: Likewise.
5103         * lib/memrchr.h: Likewise.
5104         * lib/stpcpy.h: Likewise.
5105         * lib/stpncpy.h: Likewise.
5106         * lib/strcase.h: Likewise.
5107         * lib/strchrnul.h: Likewise.
5108         * lib/strdup.h: Likewise.
5109         * lib/strndup.h: Likewise.
5110         * lib/strnlen.h: Likewise.
5111         * lib/strpbrk.h: Likewise.
5112         * lib/strsep.h: Likewise.
5113         * lib/strstr.h: Likewise.
5114         * lib/strtok_r.h: Likewise.
5115         * lib/string_.h: New file.
5116         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
5117         Rely on <string.h> instead.
5118         * lib/canon-host.c: Likewise.
5119         * lib/chdir-long.c: Likewise.
5120         * lib/concatpath.c: Likewise.
5121         * lib/exclude.c: Likewise.
5122         * lib/fchdir.c: Likewise.
5123         * lib/getaddrinfo.c: Likewise.
5124         * lib/getcwd.c: Likewise.
5125         * lib/getsubopt.c: Likewise.
5126         * lib/glob.c: Likewise.
5127         * lib/hard-locale.c: Likewise.
5128         * lib/iconvme.c: Likewise.
5129         * lib/javacomp.c: Likewise.
5130         * lib/mempcpy.c: Likewise.
5131         * lib/memrchr.c: Likewise.
5132         * lib/regex_internal.h: Likewise.
5133         * lib/stpncpy.c: Likewise.
5134         * lib/strcasecmp.c: Likewise.
5135         * lib/strchrnul.c: Likewise.
5136         * lib/strdup.c: Likewise.
5137         * lib/striconv.c: Likewise.
5138         * lib/striconveh.c: Likewise.
5139         * lib/striconveha.c: Likewise.
5140         * lib/strncasecmp.c: Likewise.
5141         * lib/strndup.c: Likewise.
5142         * lib/strnlen.c: Likewise.
5143         * lib/strsep.c: Likewise.
5144         * lib/strstr.c: Likewise.
5145         * lib/strtok_r.c: Likewise.
5146         * lib/userspec.c: Likewise.
5147         * lib/w32spawn.h: Likewise.
5148         * lib/xstrndup.c: Likewise.
5149         * lib/mountlist.c (strstr): Remove decl.
5150         * m4/string_h.m4: New file.
5151         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
5152         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
5153         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
5154         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
5155         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
5156         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
5157         Set REPLACE_STRCASECMP if necessary.
5158         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
5159         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
5160         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
5161         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
5162         HAVE_DECL_STRDUP if necessary.
5163         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
5164         since gl_FUNC_STRNDUP does that now.
5165         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
5166         Check for decl here...
5167         (gl_PREREQ_STRNLEN): ... not here.
5168         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
5169         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
5170         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
5171         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
5172         necessary.
5173         * modules/string: New file.
5174         * modules/memmem (Files): Remove special-purpose include file.
5175         (Depends-on): Add string.
5176         (Include): Include <string.h>, not the removed file.
5177         * modules/mempcpy: Likewise.
5178         * modules/memrchr: Likewise.
5179         * modules/stpcpy: Likewise.
5180         * modules/stpncpy: Likewise.
5181         * modules/strcase: Likewise.
5182         * modules/strchrnul: Likewise.
5183         * modules/strdup: Likewise.
5184         * modules/strndup: Likewise.
5185         * modules/strnlen: Likewise.
5186         * modules/strpbrk: Likewise.
5187         * modules/strsep: Likewise.
5188         * modules/strstr: Likewise.
5189         * modules/strtok_r: Likewise.
5190         * tests/test-dirname.c: Don't include "strdup.h", since
5191         <string.h> now suffices.
5192         * tests/test-memmem.c: Don't include "memmem.h", since
5193         <string.h> now suffices.
5194
5195 2007-01-25  Bruno Haible  <bruno@clisp.org>
5196
5197         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
5198         *resultp is 0.
5199
5200         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
5201         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
5202         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
5203         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
5204
5205         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
5206         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
5207         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
5208         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
5209         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
5210         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
5211
5212 2007-01-24  Bruno Haible  <bruno@clisp.org>
5213
5214         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
5215         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
5216         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
5217         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
5218         gl_FUNC_FTS_CORE.
5219         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
5220         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
5221         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
5222         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
5223         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
5224         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
5225         gl_FUNC_FCHOWNAT.
5226         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
5227         gl_FUNC_STRFTIME.
5228         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
5229         Reported by Ralf Wildenhues.
5230
5231 2007-01-24  Bruno Haible  <bruno@clisp.org>
5232
5233         Drop AC_REQUIRE calls that are redundant with the module dependencies.
5234         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
5235         gl_GETADDRINFO.
5236         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
5237         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
5238         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
5239
5240 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
5241
5242         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
5243         Don't use 'exit'; just return from 'main'.
5244         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
5245
5246         * lib/fnmatch_.h: Readjust white space and comments to match
5247         glibc, to avoid spurious diffs.
5248
5249 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
5250
5251         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
5252         2004-12-01 change by Jakub Jelinek, since this code won't compile
5253         if !LIBC.  Problem reported by Bob Proulx.
5254
5255 2007-01-23  Bruno Haible  <bruno@clisp.org>
5256
5257         * lib/striconveh.c: Include c-strcaseeq.h.
5258         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
5259         * modules/striconveh (Depends-on): Add c-strcaseeq.
5260
5261 2007-01-23  Bruno Haible  <bruno@clisp.org>
5262
5263         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
5264
5265         * modules/c-strcaseeq: New file.
5266         * lib/c-strcaseeq.h: New file.
5267
5268         * modules/streq: New file.
5269         * lib/streq.h: New file.
5270
5271 2007-01-23  Bruno Haible  <bruno@clisp.org>
5272
5273         * modules/striconveha-tests: New file.
5274         * tests/test-striconveha.c: New file.
5275
5276         * lib/striconveha.h: Include <stdbool.h>.
5277         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
5278         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
5279         (mem_iconveha_notranslit): Renamed from mem_iconveha.
5280         (mem_iconveha): New function.
5281         (str_iconveha_notranslit): Renamed from str_iconveha.
5282         (str_iconveha): New function.
5283         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
5284         c-strcase.
5285
5286 2007-01-23  Bruno Haible  <bruno@clisp.org>
5287
5288         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
5289         encodings without forgiving before trying any encoding with handler.
5290         (str_iconveha): Try all encodings without forgiving before trying any
5291         encoding with handler.
5292
5293 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
5294
5295         Import the following changes from libc.
5296
5297         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
5298
5299         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
5300
5301         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
5302
5303         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
5304         normal_bracket label.
5305
5306         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
5307
5308         [BZ #361]
5309         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
5310         to normal_bracket after fetching the next character.
5311
5312 2007-01-22  Bruno Haible  <bruno@clisp.org>
5313
5314         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
5315         argument.
5316         * lib/striconveh.c (iconv_carefully_1): New function.
5317         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
5318         argument.
5319         (str_cd_iconveh): Update.
5320         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
5321         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
5322         * tests/test-striconveh.c (MAGIC): New macro.
5323         (new_offsets): New function.
5324         (main): Test call with and without offsets.
5325
5326 2007-01-22  Bruno Haible  <bruno@clisp.org>
5327
5328         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
5329         * modules/sys_select (Makefile.am): Likewise.
5330         * modules/sys_socket (Makefile.am): Likewise.
5331         * modules/sys_time (Makefile.am): Likewise.
5332
5333 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
5334
5335         * modules/gettimeofday (License): Change from GPL to LGPL, since
5336         gettimeofday is a library function.
5337
5338 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5339
5340         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
5341
5342 2007-01-21  Bruno Haible  <bruno@clisp.org>
5343
5344         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
5345
5346 2007-01-21  Bruno Haible  <bruno@clisp.org>
5347
5348         * modules/striconveha: New file.
5349         * lib/striconveha.h: New file.
5350         * lib/striconveha.c: New file.
5351         * MODULES.html.sh (Internationalization functions): Add striconveha.
5352         * lib/striconv.c (str_iconv): Optimize the case of an empty input
5353         string.
5354         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
5355
5356 2007-01-21  Bruno Haible  <bruno@clisp.org>
5357
5358         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
5359         * lib/striconveh.c (str_iconveh): Likewise.
5360
5361 2007-01-21  Bruno Haible  <bruno@clisp.org>
5362
5363         * lib/striconveh.h (mem_iconveh): New declaration.
5364         * lib/striconveh.c (mem_iconveh): New function.
5365         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
5366
5367 2007-01-21  Bruno Haible  <bruno@clisp.org>
5368
5369         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
5370
5371         * lib/striconveh.h (mem_cd_iconveh): Change specification.
5372         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
5373         original result buffer.
5374         (str_cd_iconveh): Update.
5375         * tests/test-striconveh.c (main): Update.
5376
5377         * lib/striconv.h (mem_cd_iconv): Change specification.
5378         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
5379         result buffer.
5380         (str_cd_iconv): Update.
5381         * tests/test-striconv.c (main): Update.
5382
5383 2007-01-21  Bruno Haible  <bruno@clisp.org>
5384
5385         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
5386
5387 2007-01-20  Jim Meyering  <jim@meyering.net>
5388
5389         * lib/userspec.c (parse_with_separator): If a user or group string
5390         starts with "+", skip the corresponding name-to-ID look-up, since
5391         such a look-up must fail: user and group names may not include "+".
5392
5393 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
5394
5395         * lib/poll.c: Include sys/time.h and time.h unconditionally,
5396         since we now assume the sys_time module.
5397         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
5398         check for sys/time.h; no longer needed.
5399         * modules/poll (Depends-on): Depend on sys_time.
5400
5401 2007-01-18  Bruno Haible  <bruno@clisp.org>
5402
5403         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
5404         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
5405
5406         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
5407         gettimeofday.
5408
5409         * tests/test-gettimeofday.c: Include <time.h>.
5410         (dummy): Remove variable.
5411
5412         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
5413         gl_HEADER_SYS_TIME_H.
5414         (gl_HEADER_SYS_TIME_H): New macro.
5415
5416         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
5417         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5418         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
5419         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
5420         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5421         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
5422         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
5423         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5424         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
5425         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
5426         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5427
5428         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
5429         last change; it caused a compilation error when cross-compiling to
5430         Cygwin.
5431
5432 2007-01-18  Jim Meyering  <jim@meyering.net>
5433
5434         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
5435         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
5436         than the race-prone "test -d sys || mkdir sys".
5437         (configure.ac): Use AC_PROG_MKDIR_P.
5438         * modules/sys_select: Likewise.
5439         * modules/sys_socket: Likewise.
5440         * modules/sys_time: Likewise.
5441
5442 2007-01-18  Eric Blake  <ebb9@byu.net>
5443
5444         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
5445         replace gettimeofday.
5446         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
5447         name, to avoid infinite recursion.
5448
5449 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
5450
5451         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
5452         module sys_time.
5453         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
5454         assume timespec.h defines struct timeval.
5455         * lib/settime.c: Likewise.
5456         * lib/utimens.c: Likewise.
5457         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
5458         since we now assume the gettimeofday module.
5459         * lib/tempname.c (__gen_tempname): Likewise.
5460         * lib/gettimeofday.h: Remove.
5461         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
5462         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
5463         Include <time.h>, for 'time()'.
5464         (localtime_buffer_addr): Also use this workaround if
5465         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
5466         to simplify the uses.  All uses changed.
5467         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
5468         that #undef is inside {}, and 'const' follows type name consistently.
5469         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
5470         (gettimeofday): Do not use the maximum possible value for
5471         tv->tv_usec, since that might break usages other than ls.c.
5472         Instead, we'll leave ls.c alone.  This undoes today's patch
5473         by Bruno.  Add a compile-time warning for 1s-clock resolution;
5474         we've never observed the problem but might as well keep the
5475         canary.
5476         * lib/nanosleep.c: Include timespec.h first, for interface check.
5477         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
5478         now assume the sys_time module.
5479         * lib/tempname.c: Likewise.
5480         * lib/timespec.h: Likewise.
5481         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
5482         needed.
5483         * lib/strftime.c: Likewise.
5484         * lib/timespec.h: Likewise.
5485         * lib/posixtm.c: Include posixtm.h first, for interface check.
5486         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
5487         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
5488         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
5489         * lib/sys_time_.h: New file.
5490         * lib/timespec.h (struct timespec): Use long int, not long.
5491         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
5492         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
5493         Remove obsolescent call to AC_HEADER_TIME.
5494         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
5495         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
5496         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
5497         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
5498         Likewise.
5499         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
5500         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
5501         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
5502         into the sys_time module.  Check for gettimeofday just once.
5503         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
5504         for gettimeofday signature to just check the signature.  Merely
5505         compile it, since linking doesn't test signature.  Improve test for
5506         whether gettimeofday.o is actually needed.
5507         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
5508         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
5509         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
5510         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5511         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
5512         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
5513         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
5514         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
5515         than worrying about sys/time.h.
5516         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
5517         Don't bother worrying about TIME_WITH_SYS_TIME.
5518         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
5519         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
5520         * m4/sys_time_h.m4: New file.
5521         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
5522         Don't include sys/time.h.  Return from main rather than exiting.
5523         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
5524         all uses changed.
5525         * modules/gethrxtime (Depends-on): Add sys_time.
5526         * modules/gettime (Depends-on): Likewise.
5527         * modules/gettimeofday (Depends-on): Likewise.
5528         * modules/nanosleep (Depends-on): Likewise.
5529         * modules/settime (Depends-on): Likewise.
5530         * modules/tempname (Depends-on): Likewise.
5531         * modules/utimens (Depends-on): Likewise.
5532         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
5533         (Include:) Change back to <sys/time.h>.
5534         (Maintainer:) Add self.
5535         * modules/sys_time: New file.
5536         * modules/tempname (Depends-on): Add gettimeofday.
5537         * tests/test-gettimeofday.c: Include <sys/time.h>
5538         rather than gettimeofday.h.
5539
5540 2007-01-17  Bruno Haible  <bruno@clisp.org>
5541
5542         * gnulib-tool (func_get_license): Revert last patch. Instead, let
5543         the license default to GPL.
5544         (func_create_testdir): Don't complain if a module is LGPL and its
5545         tests module depends on GPLed modules.
5546
5547 2007-01-17  Bruno Haible  <bruno@clisp.org>
5548
5549         * lib/gettimeofday.c (gettimeofday): Add code for the case
5550         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
5551         maximum possible value for tv->tv_usec, rather than the minimum one.
5552
5553 2005-10-08  Martin Lambers  <marlam@marlam.de>
5554 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
5555 2007-01-16  Bruno Haible  <bruno@clisp.org>
5556
5557         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
5558         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
5559         gl_FUNC_GETTIMEOFDAY.
5560         (Include): Add gettimeofday.h.
5561         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
5562         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
5563         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
5564         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
5565         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
5566         * lib/gettimeofday.h: New file.
5567         * lib/gettimeofday.c: Include <sys/timeb.h>.
5568         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
5569         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
5570         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
5571         fall back on time().
5572
5573         * tests/test-gettimeofday.c: New file.
5574         * modules/gettimeofday-tests: New file.
5575
5576 2007-01-16  Eric Blake  <ebb9@byu.net>
5577
5578         * modules/fnmatch (Depends-on): Depend on wchar.
5579         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
5580         * m4/fnmatch.m4: Likewise.
5581         * modules/mbchar (Makefile.am): Assume <wchar.h>.
5582         * m4/mbchar.m4: Likewise.
5583         * modules/mbswidth (Depends-on): Depend on wchar.
5584         * lib/mbswidth.c: Assume <wchar.h>.
5585         * m4/mbswidth.m4: Likewise.
5586         * modules/quotearg (Depends-on): Depend on wchar.
5587         * lib/quotearg.c: Assume <wchar.h>.
5588         * m4/quotearg.m4: Likewise.
5589         * modules/regex (Depends-on): Depend on wchar.
5590         * lib/regex_internal.h: Assume <wchar.h>.
5591         * m4/regex.m4: Likewise.
5592         * modules/stdint (Depends-on): Depend on wchar.
5593         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
5594         * m4/stdint.m4: Likewise.
5595         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
5596         * modules/strftime (Depends-on): Depend on wchar.
5597         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
5598         * modules/strtol (Depends-on): Depend on wchar.
5599         * lib/strtol.c: Assume <wchar.h>.
5600         * modules/wcwidth (Depends-on): Depend on wchar.
5601         * lib/wcwidth.h: Assume <wchar.h>.
5602         * m4/wcwidth.m4: Likewise.
5603
5604 2007-01-16  Bruno Haible  <bruno@clisp.org>
5605
5606         * modules/csharpexec-script: New, created from...
5607         * modules/csharpexec: ... this.
5608
5609 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
5610
5611         * modules/javaexec-script: New, created from...
5612         * modules/javaexec: ... this.
5613
5614 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5615
5616         * modules/poll (Dependencies): Add sys_select.
5617
5618 2007-01-15  Jim Meyering  <jim@meyering.net>
5619
5620         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
5621         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
5622         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
5623         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
5624
5625 2007-01-15  Bruno Haible  <bruno@clisp.org>
5626
5627         * modules/striconveh: New file.
5628         * lib/striconveh.h: New file.
5629         * lib/striconveh.c: New file.
5630         * MODULES.html.sh (Internationalization functions): Add striconveh.
5631
5632         * modules/striconveh-tests: New file.
5633         * tests/test-striconveh.c: New file.
5634
5635 2007-01-15  Bruno Haible  <bruno@clisp.org>
5636
5637         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
5638         not from GNU libiconv or GNU libc.
5639
5640 2007-01-15  Bruno Haible  <bruno@clisp.org>
5641
5642         * doc/gnulib-intro.texi (Copyright): Explain the different license
5643         terms for module descriptions, autoconf macros, tests, documentation.
5644
5645 2007-01-14  Bruno Haible  <bruno@clisp.org>
5646
5647         * modules/striconv-tests: New file.
5648         * tests/test-striconv.c: New file.
5649
5650 2007-01-14  Bruno Haible  <bruno@clisp.org>
5651
5652         * modules/iconv-tests: New file.
5653         * tests/test-iconv.c: New file.
5654
5655 2007-01-14  Bruno Haible  <bruno@clisp.org>
5656
5657         * gnulib-tool (func_get_license): For test modules, use the license of
5658         the main module.
5659
5660 2007-01-14  Bruno Haible  <bruno@clisp.org>
5661
5662         * modules/iconv (Include): Clarify that <iconv.h> can only be included
5663         if iconv is found to exist.
5664
5665 2007-01-14  Bruno Haible  <bruno@clisp.org>
5666
5667         * modules/c-ctype-tests: New file.
5668         * tests/test-c-ctype.c: New file.
5669
5670 2007-01-14  Bruno Haible  <bruno@clisp.org>
5671
5672         * modules/binary-io-tests: New file.
5673         * tests/test-binary-io.sh: New file.
5674         * tests/test-binary-io.c: New file.
5675
5676 2007-01-14  Bruno Haible  <bruno@clisp.org>
5677
5678         * modules/array-oset-tests: New file.
5679         * tests/test-array_oset.c: New file.
5680
5681 2007-01-14  Bruno Haible  <bruno@clisp.org>
5682
5683         * modules/array-list-tests: New file.
5684         * tests/test-array_list.c: New file.
5685
5686 2007-01-14  Bruno Haible  <bruno@clisp.org>
5687
5688         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
5689         and make.
5690         Reported by Simon Josefsson in
5691         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
5692
5693 2007-01-14  Bruno Haible  <bruno@clisp.org>
5694
5695         * modules/allocsa-tests: New file.
5696         * tests/test-allocsa.c: New file.
5697
5698 2007-01-14  Bruno Haible  <bruno@clisp.org>
5699
5700         * modules/fchdir (Depends-on): Add absolute-header.
5701         * modules/unistd (Depends-on): Likewise.
5702
5703 2006-12-30  Bruno Haible  <bruno@clisp.org>
5704
5705         * modules/fchdir: New file.
5706         * modules/unistd (Files): Add lib/unistd_.h.
5707         (Makefile.am): Generate unistd.h from unistd_.h.
5708         * lib/fchdir.c: New file.
5709         * lib/dirent_.h: New file.
5710         * lib/unistd_.h: New file.
5711         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
5712         * m4/fchdir.m4: New file.
5713         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
5714         (gl_HEADER_UNISTD): Invoke it.
5715         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
5716         function.
5717         * lib/backupfile.c (opendir, closedir): Undefine.
5718         * lib/chown.c (open, close): Undefine.
5719         * lib/clean-temp.c (open, close): Undefine.
5720         * lib/copy-file.c (open, close): Undefine.
5721         * lib/execute.c (open, close): Undefine.
5722         * lib/fsusage.c (open, close): Undefine.
5723         * lib/gc-gnulib.c (open, close): Undefine.
5724         * lib/getcwd.c (opendir, closedir): Undefine.
5725         * lib/glob.c (opendir, closedir): Undefine.
5726         * lib/javacomp.c (open, close): Undefine.
5727         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
5728         * lib/openat-proc.c (open, close): Undefine.
5729         * lib/pagealign_alloc.c (open, close): Undefine.
5730         * lib/pipe.c (open, close): Undefine.
5731         * lib/progreloc.c (open, close): Undefine.
5732         * lib/savedir.c (opendir, closedir): Undefine.
5733         * lib/utime.c (open, close): Undefine.
5734         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
5735
5736 2007-01-10  Bruno Haible  <bruno@clisp.org>
5737
5738         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
5739
5740 2007-01-12  Eric Blake  <ebb9@byu.net>
5741
5742         Provide a robust <wchar.h>.  Further simplifications are now
5743         possible in other modules, but not included here.
5744         * modules/wchar: New module.
5745         * m4/wchar.m4: New file.
5746         * lib/wchar_.h: Likewise.
5747         * modules/mbchar (Depends-on): Depend on wchar, as the first use
5748         of the new module.
5749         * MODULES.html.sh (Extended multibyte and wide character utilities):
5750         New section.
5751
5752 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
5753
5754         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
5755         to a reasonable default for memory allocation.
5756         (xreadlink): Don't allocate a huge buffer, to work around a buggy
5757         file system that reports garbage st_size values for symlinks.
5758         Problem reported by Liyang Hu.
5759
5760 2007-01-11  Simon Josefsson  <simon@josefsson.org>
5761
5762         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
5763         Emacs .#* auto-save files).
5764
5765 2007-01-11  Bruno Haible  <bruno@clisp.org>
5766
5767         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
5768         directory.
5769
5770 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
5771
5772         Use @...@ consistently in lib/wctype_.h.
5773         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
5774         on it being set to 1 or 0.
5775         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
5776         go back to AC_SUBSTing it.
5777         * modules/wctype (Makefile.am): Undo previous change.
5778
5779 2007-01-10  Eric Blake  <ebb9@byu.net>
5780
5781         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
5782         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
5783         * modules/wctype (Makefile.am): Likewise.
5784         Reported by Chris McGuire.
5785
5786 2007-01-10  Jim Meyering  <jim@meyering.net>
5787
5788         fts.c: a small readability/maintainability improvement
5789         * lib/fts.c (fts_read): Make this code slightly more readable and
5790         maintainable by hoisting the "sp->fts_cur = p" assignments to
5791         immediately follow the statements that set P.  Derived from
5792         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
5793
5794 2007-01-10  Eric Blake  <ebb9@byu.net>
5795
5796         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
5797         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
5798         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
5799         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
5800         Reported by Chris McGuire.
5801
5802 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5803
5804         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
5805         in sed script.
5806
5807 2007-01-09  Bruno Haible  <bruno@clisp.org>
5808
5809         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
5810         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
5811         variables.
5812         (func_module): Use them.
5813
5814 2007-01-09  Bruno Haible  <bruno@clisp.org>
5815
5816         * modules/unistr/base: New file.
5817         * lib/unistr.h: New file.
5818
5819         * modules/unistr/u8-to-u16: New file.
5820         * lib/unistr/u8-to-u16.c: New file.
5821
5822         * modules/unistr/u8-to-u32: New file.
5823         * lib/unistr/u8-to-u32.c: New file.
5824
5825         * modules/unistr/u16-to-u8: New file.
5826         * lib/unistr/u16-to-u8.c: New file.
5827
5828         * modules/unistr/u16-to-u32: New file.
5829         * lib/unistr/u16-to-u32.c: New file.
5830
5831         * modules/unistr/u32-to-u8: New file.
5832         * lib/unistr/u32-to-u8.c: New file.
5833
5834         * modules/unistr/u32-to-u16: New file.
5835         * lib/unistr/u32-to-u16.c: New file.
5836
5837         * modules/unistr/u8-check: New file.
5838         * modules/unistr/u16-check: New file.
5839         * modules/unistr/u32-check: New file.
5840         * lib/unistr/u8-check.c: New file.
5841         * lib/unistr/u16-check.c: New file.
5842         * lib/unistr/u32-check.c: New file.
5843
5844         * modules/unistr/u8-chr: New file.
5845         * modules/unistr/u16-chr: New file.
5846         * modules/unistr/u32-chr: New file.
5847         * lib/unistr/u8-chr.c: New file.
5848         * lib/unistr/u16-chr.c: New file.
5849         * lib/unistr/u32-chr.c: New file.
5850
5851         * modules/unistr/u8-cmp: New file.
5852         * modules/unistr/u16-cmp: New file.
5853         * modules/unistr/u32-cmp: New file.
5854         * lib/unistr/u8-cmp.c: New file.
5855         * lib/unistr/u16-cmp.c: New file.
5856         * lib/unistr/u32-cmp.c: New file.
5857
5858         * modules/unistr/u8-cpy: New file.
5859         * modules/unistr/u16-cpy: New file.
5860         * modules/unistr/u32-cpy: New file.
5861         * lib/unistr/u8-cpy.c: New file.
5862         * lib/unistr/u16-cpy.c: New file.
5863         * lib/unistr/u32-cpy.c: New file.
5864         * lib/unistr/u-cpy.h: New file.
5865
5866         * modules/unistr/u8-cpy-alloc: New file.
5867         * modules/unistr/u16-cpy-alloc: New file.
5868         * modules/unistr/u32-cpy-alloc: New file.
5869         * lib/unistr/u8-cpy-alloc.c: New file.
5870         * lib/unistr/u16-cpy-alloc.c: New file.
5871         * lib/unistr/u32-cpy-alloc.c: New file.
5872         * lib/unistr/u-cpy-alloc.h: New file.
5873
5874         * modules/unistr/u8-endswith: New file.
5875         * modules/unistr/u16-endswith: New file.
5876         * modules/unistr/u32-endswith: New file.
5877         * lib/unistr/u8-endswith.c: New file.
5878         * lib/unistr/u16-endswith.c: New file.
5879         * lib/unistr/u32-endswith.c: New file.
5880         * lib/unistr/u-endswith.h: New file.
5881
5882         * modules/unistr/u8-mblen: New file.
5883         * modules/unistr/u16-mblen: New file.
5884         * modules/unistr/u32-mblen: New file.
5885         * lib/unistr/u8-mblen.c: New file.
5886         * lib/unistr/u16-mblen.c: New file.
5887         * lib/unistr/u32-mblen.c: New file.
5888
5889         * modules/unistr/u8-mbtouc: New file.
5890         * modules/unistr/u16-mbtouc: New file.
5891         * modules/unistr/u32-mbtouc: New file.
5892         * lib/unistr/u8-mbtouc.c: New file.
5893         * lib/unistr/u16-mbtouc.c: New file.
5894         * lib/unistr/u32-mbtouc.c: New file.
5895
5896         * modules/unistr/u8-mbtouc-safe: New file.
5897         * modules/unistr/u16-mbtouc-safe: New file.
5898         * modules/unistr/u32-mbtouc-safe: New file.
5899         * lib/unistr/u8-mbtouc-safe.c: New file.
5900         * lib/unistr/u16-mbtouc-safe.c: New file.
5901         * lib/unistr/u32-mbtouc-safe.c: New file.
5902
5903         * modules/unistr/u8-move: New file.
5904         * modules/unistr/u16-move: New file.
5905         * modules/unistr/u32-move: New file.
5906         * lib/unistr/u8-move.c: New file.
5907         * lib/unistr/u16-move.c: New file.
5908         * lib/unistr/u32-move.c: New file.
5909         * lib/unistr/u-move.h: New file.
5910
5911         * modules/unistr/u8-next: New file.
5912         * modules/unistr/u16-next: New file.
5913         * modules/unistr/u32-next: New file.
5914         * lib/unistr/u8-next.c: New file.
5915         * lib/unistr/u16-next.c: New file.
5916         * lib/unistr/u32-next.c: New file.
5917
5918         * modules/unistr/u8-prev: New file.
5919         * modules/unistr/u16-prev: New file.
5920         * modules/unistr/u32-prev: New file.
5921         * lib/unistr/u8-prev.c: New file.
5922         * lib/unistr/u16-prev.c: New file.
5923         * lib/unistr/u32-prev.c: New file.
5924
5925         * modules/unistr/u8-set: New file.
5926         * modules/unistr/u16-set: New file.
5927         * modules/unistr/u32-set: New file.
5928         * lib/unistr/u8-set.c: New file.
5929         * lib/unistr/u16-set.c: New file.
5930         * lib/unistr/u32-set.c: New file.
5931         * lib/unistr/u-set.h: New file.
5932
5933         * modules/unistr/u8-startswith: New file.
5934         * modules/unistr/u16-startswith: New file.
5935         * modules/unistr/u32-startswith: New file.
5936         * lib/unistr/u8-startswith.c: New file.
5937         * lib/unistr/u16-startswith.c: New file.
5938         * lib/unistr/u32-startswith.c: New file.
5939         * lib/unistr/u-startswith.h: New file.
5940
5941         * modules/unistr/u8-stpcpy: New file.
5942         * modules/unistr/u16-stpcpy: New file.
5943         * modules/unistr/u32-stpcpy: New file.
5944         * lib/unistr/u8-stpcpy.c: New file.
5945         * lib/unistr/u16-stpcpy.c: New file.
5946         * lib/unistr/u32-stpcpy.c: New file.
5947         * lib/unistr/u-stpcpy.h: New file.
5948
5949         * modules/unistr/u8-stpncpy: New file.
5950         * modules/unistr/u16-stpncpy: New file.
5951         * modules/unistr/u32-stpncpy: New file.
5952         * lib/unistr/u8-stpncpy.c: New file.
5953         * lib/unistr/u16-stpncpy.c: New file.
5954         * lib/unistr/u32-stpncpy.c: New file.
5955         * lib/unistr/u-stpncpy.h: New file.
5956
5957         * modules/unistr/u8-strcat: New file.
5958         * modules/unistr/u16-strcat: New file.
5959         * modules/unistr/u32-strcat: New file.
5960         * lib/unistr/u8-strcat.c: New file.
5961         * lib/unistr/u16-strcat.c: New file.
5962         * lib/unistr/u32-strcat.c: New file.
5963         * lib/unistr/u-strcat.h: New file.
5964
5965         * modules/unistr/u8-strchr: New file.
5966         * modules/unistr/u16-strchr: New file.
5967         * modules/unistr/u32-strchr: New file.
5968         * lib/unistr/u8-strchr.c: New file.
5969         * lib/unistr/u16-strchr.c: New file.
5970         * lib/unistr/u32-strchr.c: New file.
5971
5972         * modules/unistr/u8-strcmp: New file.
5973         * modules/unistr/u16-strcmp: New file.
5974         * modules/unistr/u32-strcmp: New file.
5975         * lib/unistr/u8-strcmp.c: New file.
5976         * lib/unistr/u16-strcmp.c: New file.
5977         * lib/unistr/u32-strcmp.c: New file.
5978
5979         * modules/unistr/u8-strcpy: New file.
5980         * modules/unistr/u16-strcpy: New file.
5981         * modules/unistr/u32-strcpy: New file.
5982         * lib/unistr/u8-strcpy.c: New file.
5983         * lib/unistr/u16-strcpy.c: New file.
5984         * lib/unistr/u32-strcpy.c: New file.
5985         * lib/unistr/u-strcpy.h: New file.
5986
5987         * modules/unistr/u8-strcspn: New file.
5988         * modules/unistr/u16-strcspn: New file.
5989         * modules/unistr/u32-strcspn: New file.
5990         * lib/unistr/u8-strcspn.c: New file.
5991         * lib/unistr/u16-strcspn.c: New file.
5992         * lib/unistr/u32-strcspn.c: New file.
5993         * lib/unistr/u-strcspn.h: New file.
5994
5995         * modules/unistr/u8-strdup: New file.
5996         * modules/unistr/u16-strdup: New file.
5997         * modules/unistr/u32-strdup: New file.
5998         * lib/unistr/u8-strdup.c: New file.
5999         * lib/unistr/u16-strdup.c: New file.
6000         * lib/unistr/u32-strdup.c: New file.
6001         * lib/unistr/u-strdup.h: New file.
6002
6003         * modules/unistr/u8-strlen: New file.
6004         * modules/unistr/u16-strlen: New file.
6005         * modules/unistr/u32-strlen: New file.
6006         * lib/unistr/u8-strlen.c: New file.
6007         * lib/unistr/u16-strlen.c: New file.
6008         * lib/unistr/u32-strlen.c: New file.
6009         * lib/unistr/u-strlen.h: New file.
6010
6011         * modules/unistr/u8-strmblen: New file.
6012         * modules/unistr/u16-strmblen: New file.
6013         * modules/unistr/u32-strmblen: New file.
6014         * lib/unistr/u8-strmblen.c: New file.
6015         * lib/unistr/u16-strmblen.c: New file.
6016         * lib/unistr/u32-strmblen.c: New file.
6017
6018         * modules/unistr/u8-strmbtouc: New file.
6019         * modules/unistr/u16-strmbtouc: New file.
6020         * modules/unistr/u32-strmbtouc: New file.
6021         * lib/unistr/u8-strmbtouc.c: New file.
6022         * lib/unistr/u16-strmbtouc.c: New file.
6023         * lib/unistr/u32-strmbtouc.c: New file.
6024
6025         * modules/unistr/u8-strncat: New file.
6026         * modules/unistr/u16-strncat: New file.
6027         * modules/unistr/u32-strncat: New file.
6028         * lib/unistr/u8-strncat.c: New file.
6029         * lib/unistr/u16-strncat.c: New file.
6030         * lib/unistr/u32-strncat.c: New file.
6031         * lib/unistr/u-strncat.h: New file.
6032
6033         * modules/unistr/u8-strncmp: New file.
6034         * modules/unistr/u16-strncmp: New file.
6035         * modules/unistr/u32-strncmp: New file.
6036         * lib/unistr/u8-strncmp.c: New file.
6037         * lib/unistr/u16-strncmp.c: New file.
6038         * lib/unistr/u32-strncmp.c: New file.
6039
6040         * modules/unistr/u8-strncpy: New file.
6041         * modules/unistr/u16-strncpy: New file.
6042         * modules/unistr/u32-strncpy: New file.
6043         * lib/unistr/u8-strncpy.c: New file.
6044         * lib/unistr/u16-strncpy.c: New file.
6045         * lib/unistr/u32-strncpy.c: New file.
6046         * lib/unistr/u-strncpy.h: New file.
6047
6048         * modules/unistr/u8-strnlen: New file.
6049         * modules/unistr/u16-strnlen: New file.
6050         * modules/unistr/u32-strnlen: New file.
6051         * lib/unistr/u8-strnlen.c: New file.
6052         * lib/unistr/u16-strnlen.c: New file.
6053         * lib/unistr/u32-strnlen.c: New file.
6054         * lib/unistr/u-strnlen.h: New file.
6055
6056         * modules/unistr/u8-strpbrk: New file.
6057         * modules/unistr/u16-strpbrk: New file.
6058         * modules/unistr/u32-strpbrk: New file.
6059         * lib/unistr/u8-strpbrk.c: New file.
6060         * lib/unistr/u16-strpbrk.c: New file.
6061         * lib/unistr/u32-strpbrk.c: New file.
6062         * lib/unistr/u-strpbrk.h: New file.
6063
6064         * modules/unistr/u8-strrchr: New file.
6065         * modules/unistr/u16-strrchr: New file.
6066         * modules/unistr/u32-strrchr: New file.
6067         * lib/unistr/u8-strrchr.c: New file.
6068         * lib/unistr/u16-strrchr.c: New file.
6069         * lib/unistr/u32-strrchr.c: New file.
6070
6071         * modules/unistr/u8-strspn: New file.
6072         * modules/unistr/u16-strspn: New file.
6073         * modules/unistr/u32-strspn: New file.
6074         * lib/unistr/u8-strspn.c: New file.
6075         * lib/unistr/u16-strspn.c: New file.
6076         * lib/unistr/u32-strspn.c: New file.
6077         * lib/unistr/u-strspn.h: New file.
6078
6079         * modules/unistr/u8-strstr: New file.
6080         * modules/unistr/u16-strstr: New file.
6081         * modules/unistr/u32-strstr: New file.
6082         * lib/unistr/u8-strstr.c: New file.
6083         * lib/unistr/u16-strstr.c: New file.
6084         * lib/unistr/u32-strstr.c: New file.
6085         * lib/unistr/u-strstr.h: New file.
6086
6087         * modules/unistr/u8-strtok: New file.
6088         * modules/unistr/u16-strtok: New file.
6089         * modules/unistr/u32-strtok: New file.
6090         * lib/unistr/u8-strtok.c: New file.
6091         * lib/unistr/u16-strtok.c: New file.
6092         * lib/unistr/u32-strtok.c: New file.
6093         * lib/unistr/u-strtok.h: New file.
6094
6095         * modules/unistr/u8-uctomb: New file.
6096         * modules/unistr/u16-uctomb: New file.
6097         * modules/unistr/u32-uctomb: New file.
6098         * lib/unistr/u8-uctomb.c: New file.
6099         * lib/unistr/u16-uctomb.c: New file.
6100         * lib/unistr/u32-uctomb.c: New file.
6101
6102         * MODULES.html.sh (Unicode string functions): Add the new modules.
6103
6104 2007-01-08  Bruno Haible  <bruno@clisp.org>
6105
6106         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
6107         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
6108         subdirectories.
6109
6110 2007-01-08  Karl Berry  <karl@gnu.org>
6111
6112         * doc/error.texi: mention that main() fns must set program_name
6113         when progname is used.
6114
6115 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
6116
6117         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
6118         WCTYPE_H is empty, for the benefit of builds from non-distclean
6119         directories.  Problem reported by Eric Blake in
6120         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
6121
6122 2007-01-08  Bruno Haible  <bruno@clisp.org>
6123
6124         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
6125         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
6126         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
6127         PROVIDE_CANONICALIZE_FILENAME_MODE.
6128         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
6129
6130 2007-01-08  Bruno Haible  <bruno@clisp.org>
6131
6132         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
6133         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
6134         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
6135         * lib/fts.c: Likewise.
6136         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
6137
6138 2006-12-25  Bruno Haible  <bruno@clisp.org>
6139
6140         * modules/utf8-ucs4-safe: New file.
6141         * lib/utf8-ucs4-safe.h: New file.
6142         * lib/unistr/utf8-ucs4-safe.c: New file.
6143
6144         * modules/utf16-ucs4-safe: New file.
6145         * lib/utf16-ucs4-safe.h: New file.
6146         * lib/unistr/utf16-ucs4-safe.c: New file.
6147
6148         * MODULES.html.sh (Unicode string functions): Add the new modules.
6149
6150 2007-01-08  Bruno Haible  <bruno@clisp.org>
6151
6152         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
6153         (Depends-on): Add unitypes.
6154         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
6155         (u8_mbtouc_aux): Move out to separate file.
6156         (u8_mbtouc): Use ucs4_t, uint8_t types.
6157         * lib/unistr/utf8-ucs4.c: New file.
6158
6159         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
6160         (Depends-on): Add unitypes.
6161         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
6162         (u16_mbtouc_aux): Move out to separate file.
6163         (u16_mbtouc): Use ucs4_t, uint16_t types.
6164         * lib/unistr/utf16-ucs4.c: New file.
6165
6166         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
6167         (Depends-on): Add unitypes.
6168         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
6169         (u8_uctomb_aux): Move out to separate file.
6170         (u8_uctomb): Use ucs4_t, uint8_t types.
6171         * lib/unistr/ucs4-utf8.c: New file.
6172
6173         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
6174         (Depends-on): Add unitypes.
6175         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
6176         (u16_uctomb_aux): Move out to separate file.
6177         (u16_uctomb): Use ucs4_t, uint16_t types.
6178         * lib/unistr/ucs4-utf16.c: New file.
6179
6180 2006-12-25  Bruno Haible  <bruno@clisp.org>
6181
6182         * modules/unitypes: New file.
6183         * lib/unitypes.h: New file.
6184         * MODULES.html.sh (func_all_modules): New section "Unicode string
6185         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
6186         this section. Add unitypes.
6187
6188 2007-01-08  Bruno Haible  <bruno@clisp.org>
6189
6190         Avoid variable names that conflict with those from libtool.
6191         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
6192         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
6193         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
6194         library_names_spec to acl_library_names_spec, hardcode_* to
6195         acl_hardcode_*.
6196         Reported by Ralf Wildenhues.
6197
6198 2007-01-08  Bruno Haible  <bruno@clisp.org>
6199
6200         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
6201         definition.
6202         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
6203         definition.
6204         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
6205         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
6206         definition.
6207         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
6208         definition.
6209         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
6210         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
6211         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
6212         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
6213         definition.
6214         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
6215         definition.
6216         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
6217         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
6218         GC_USE_<algorithm>.
6219         * lib/gc-libgcrypt.c: Likewise.
6220         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
6221         * modules/gc-arctwo (configure.ac): Likewise.
6222         * modules/gc-des (configure.ac): Likewise.
6223         * modules/gc-hmac-md5 (configure.ac): Likewise.
6224         * modules/gc-hmac-sha1 (configure.ac): Likewise.
6225         * modules/gc-md2 (configure.ac): Likewise.
6226         * modules/gc-md4 (configure.ac): Likewise.
6227         * modules/gc-md5 (configure.ac): Likewise.
6228         * modules/gc-random (configure.ac): Likewise.
6229         * modules/gc-rijndael (configure.ac): Likewise.
6230         * modules/gc-sha1 (configure.ac): Likewise.
6231
6232 2007-01-08  Bruno Haible  <bruno@clisp.org>
6233
6234         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
6235         macro definition.
6236         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
6237         definition.
6238         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
6239         definition.
6240         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
6241         * modules/fcntl-safer (configure.ac): Likewise.
6242         * modules/fopen-safer (configure.ac): Likewise.
6243         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
6244         GNULIB_FWRITEERROR macro definition.
6245
6246 2007-01-08  Bruno Haible  <bruno@clisp.org>
6247
6248         * m4/gnulib-common.m4: New file.
6249         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
6250         (func_get_filelist): Add m4/gnulib-common.m4.
6251
6252 2007-01-08  Bruno Haible  <bruno@clisp.org>
6253
6254         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
6255         command.
6256
6257 2007-01-08  Jim Meyering  <jim@meyering.net>
6258
6259         Use a more robust test for a "can't happen" condition.
6260         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
6261         narrowed the st_size value.  Presuming the "can't happen" condition
6262         is true, that narrowing could conceivably convert an invalid st_size
6263         value into a valid one.  Instead, use a change based on Matthew
6264         Woehlke's original patch.
6265
6266         Slight readability improvement: use an assert-like macro
6267         in place of literal "abort ()" uses.
6268         * lib/fts.c (fts_assert): Define.
6269         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
6270         Use this macro instead of a bare 'abort'.
6271
6272 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
6273
6274         Don't worry about using IRIX 5.3's wctype.h broken definitions;
6275         simply work around them.
6276         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
6277         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
6278         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
6279         declaring.
6280         Don't bother to define as macros, since the standard doesn't require it.
6281         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
6282         longer worry about IRIX 5.3.
6283         (HAVE_WCTYPE_CTMP_BUG): Remove.
6284
6285 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
6286
6287         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
6288         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
6289         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
6290         Problems reported by Georg Schwarz for IRIX 5.3.
6291
6292         * gnulib-tool (autoconf_minversion): Take the maximum version number
6293         found, not the minimum.  Problem reported by James Youngman.
6294
6295 2007-01-03  Karl Berry  <karl@gnu.org>
6296
6297         * doc/error.texi: new file, explaining interaction with progname.
6298         * doc/gnulib.texi: include it.  Update copyright.
6299
6300 2007-01-03  Simon Josefsson  <simon@josefsson.org>
6301
6302         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
6303         AC_CANONICAL_HOST, to improve autobuild outputs.
6304
6305 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
6306             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
6307
6308         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
6309         sockets, server sockets, and other file descriptors.  Count errors
6310         to compute the return value.  Reorder the code a bit to be easier
6311         to follow.  Don't set event bits that were not requested (except
6312         POLLERR and POLLHUP).
6313
6314 2007-01-01  Bruno Haible  <bruno@clisp.org>
6315
6316         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
6317
6318 2007-01-03  Jim Meyering  <jim@meyering.net>
6319
6320         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
6321
6322 2007-01-02  Bruno Haible  <bruno@clisp.org>
6323
6324         * modules/settime (Include): Require timespec.h.
6325         * modules/nanosleep (Include): Likewise.
6326
6327 2007-01-01  Bruno Haible  <bruno@clisp.org>
6328
6329         * gnulib-tool (func_emit_copyright_notice): Bump year.
6330         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
6331
6332 2007-01-01  Bruno Haible  <bruno@clisp.org>
6333
6334         Improve support for OpenBSD.
6335         * build-aux/config.rpath (libname_spec): Export.
6336         (library_names_spec): New variable. Export.
6337         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
6338         library_names_spec from the config.rpath output. Locate shared library
6339         through the name pattern in library_names_spec.
6340
6341 2007-01-01  Eric Blake  <ebb9@byu.net>
6342
6343         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
6344
6345 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
6346
6347         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
6348         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
6349         assume the C locale, and avoid an "eval" that could cause trouble.
6350         Problem with SORT reported by Bob Proulx.
6351
6352         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
6353         Define.  Trivial patch from Henning Nielsen Lund, originally
6354         sent to bug-grep@gnu.org today.
6355
6356 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
6357
6358         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
6359         struct stat.  Problem reported by Henning Nielsen Lund.
6360         * lib/acl.c: Include acl.h first, to check interface.  Don't
6361         bother to include sys/types.h and sys/stat.h again.
6362
6363 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
6364
6365         Import the following change from libc; problem reported by
6366         Sven Verdoolaege.
6367
6368         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
6369
6370         [BZ #1373]
6371         * lib/argp.h: Remove __NTH for __argp_usage inline function.
6372
6373 2006-12-28  Jim Meyering  <jim@meyering.net>
6374
6375         * build-aux/announce-gen: Do not assume that the package
6376         builds any of tar.gz, tar.bz2, and .xdelta files.
6377         Suggestion from Simon Josefsson.
6378
6379 2006-12-28  Simon Josefsson  <simon@josefsson.org>
6380
6381         * modules/announce-gen: New file.
6382
6383 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
6384
6385         * lib/mbchar.h: Just include <wctype.h>; the wctype module
6386         handles its gotchas now.
6387         * lib/mbswidth.c: Likewise.
6388         * lib/wcwidth.h: Likewise.
6389         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
6390         and iswcntrl; the wctype module does this stuff now.
6391         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
6392         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
6393         * modules/mbchar (Depends-on): Add wctype.
6394         * modules/mbswidth (Depends-on): Likewise.
6395         * modules/wcwidth (Depends-on): Likewise.
6396
6397 2006-12-27  Eric Blake  <ebb9@byu.net>
6398
6399         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
6400         module uses more than what <wctype.h> is required to provide.
6401
6402 2006-12-26  Eric Blake  <ebb9@byu.net>
6403
6404         * gnulib-tool (sed_extract_prog): Avoid space-tab.
6405
6406 2006-12-26  Eric Blake  <ebb9@byu.net>
6407
6408         * modules/absolute-header: New module.
6409         * modules/fcntl (Depends-on): Depend on it.
6410         * modules/inttypes (Depends-on): Likewise.
6411         * modules/stdint (Depends-on): Likewise.
6412         * modules/sys_stat (Depends-on): Likewise.
6413         * modules/wctype (Depends-on): Likewise.
6414         * MODULES.html.sh (Support for building libraries and
6415         executables): Document it.
6416
6417 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
6418
6419         * gnulib-tool (SED): Remove, undoing previous change.
6420         The problem was that it broke coreutils on Solaris, because
6421         "sed --posix" leaked into a makefile.
6422         (sed): New alias, if 'alias' and GNU sed.
6423
6424 2006-12-24  Jim Meyering  <jim@meyering.net>
6425
6426         Work around an fchownat bug in glibc-2.4:
6427         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
6428         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
6429         in spite of the -P option.
6430         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
6431         New macros.
6432         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
6433         * modules/openat (Files): Add lib/fchownat.c.
6434         * lib/openat.c (fchownat): Don't define here.  Move to...
6435         * lib/fchownat.c: ...this new file.
6436
6437 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
6438
6439         Fix bug reported by Bruno Haible in
6440         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
6441         where quotearg.c didn't compile on Mac OS X 10.2 because it
6442         lacks <wchar.h> and wint_t.
6443         * lib/wctype_.h (__wctype_wint_t): New type.
6444         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
6445         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
6446         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
6447         Arg is now of type __wctype_wint_t, not wint_t.
6448         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
6449         substitute HAVE_WINT_T.
6450         * modules/wctype (Files): Add m4/wint_t.m4.
6451         (wctype.h): Substitute HAVE_WINT_T.
6452
6453 2006-12-23  Bruno Haible  <bruno@clisp.org>
6454
6455         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
6456
6457 2006-12-23  Bruno Haible  <bruno@clisp.org>
6458
6459         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
6460         S_ISLNK.
6461         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
6462         mingw.
6463
6464 2006-12-22  Bruno Haible  <bruno@clisp.org>
6465
6466         * lib/copy-file.c: Include acl.h.
6467         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
6468         Close the file descriptors only after being done with copy_acl.
6469         * modules/copy-file (Depends-on): Add acl.
6470
6471 2006-12-22  Bruno Haible  <bruno@clisp.org>
6472
6473         * gnulib-tool (SED): New variable.
6474         Use $SED instead of sed everywhere.
6475
6476 2006-12-22  Bruno Haible  <bruno@clisp.org>
6477
6478         * modules/no-c++: New file.
6479         * m4/no-c++.m4: New file.
6480         * MODULES.html.sh (Support for building libraries and executables):
6481         Add no-c++.
6482
6483 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
6484
6485         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
6486         Include <limits.h>, and use its INT_MAX to rewrite the
6487         j loop so that it does not overflow 'int'.  Problem reported by
6488         Ralf Wildenhues in
6489         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
6490         Play it safe by shifting left by 1 rather than multiplying by 2,
6491         as GCC is less likely to optimize this away when the value
6492         is signed (when it assumes overflow leads to undefined behavior).
6493         Also, don't assume time_t uses two's complement.
6494
6495 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
6496
6497         * MODULES.html.sh: New module wctype.
6498         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
6499         * lib/fnmatch.c: Don't bother to include <wchar.h> before
6500         <wctype.h>, since the new wctype module should fix this.
6501         * lib/quotearg.c: Include <wctype.h> unconditionally, since
6502         the wctype module should arrange for it.
6503         * lib/regex_internal.h: Likewise.
6504         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
6505         since the wctype module should handle this now.
6506         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
6507         * modules/fnmatch (Depends-on): Add wctype.
6508         * modules/quotearg (Depends-on): Likewise.
6509         * modules/regex (Depends-on): Likewise.
6510
6511 2006-12-19  Bruno Haible  <bruno@clisp.org>
6512
6513         * lib/strdup.h [C++]: Wrap definitions in extern "C".
6514         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
6515
6516 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6517
6518         * modules/savewd (Depends-on): Fix dependency on fcntl.
6519
6520 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
6521
6522         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
6523         conforms to C99, rather than relying on the user's environment
6524         setting of STDINT_H.
6525
6526 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
6527         and Eric Blake  <ebb9@byu.net>
6528
6529         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
6530         This is more consistent with the other defines here.
6531         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
6532         Port to z/OS.  Problem reported by Paul Gilmartin.
6533         Change local vars to use gl_ prefix rather than ac_.
6534         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
6535         with other defines.
6536         * modules/double-slash-root: New module.
6537         * modules/dirname (Files): Remove m4/double-slash-root.m4.
6538         (Depends-on): Add double-slash-root.
6539         * MODULES.html.sh (File system functions): Mention new module.
6540
6541 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
6542
6543         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
6544         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
6545         This is for the benefit of gzip, which doesn't do i18n.
6546
6547 2006-12-12  Jim Meyering  <jim@meyering.net>
6548
6549         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
6550         Reported by Andreas Schwab <schwab@suse.de>.
6551
6552 2006-12-12  Bruno Haible  <bruno@clisp.org>
6553
6554         Merge these changes.
6555         2006-09-05  Bruno Haible  <bruno@clisp.org>
6556         * lib/iconvme.c (iconv_string): No need to save and restore errno when
6557         iconv_alloc succeeded.
6558         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
6559         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
6560         test for " && dest " at the end - dest is always != NULL there. Call
6561         iconv with 4xNULL arguments initially, to reset the state. Call iconv
6562         with 2xNULL arguments, also to flush the state storage. Handle the
6563         IRIX iconv behaviour. Realloc the final result, to throw away unused
6564         memory.
6565
6566 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
6567
6568         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
6569         and fchmodat unconditionally, since glibc 2.4 has them.
6570         Problem reported by Arkadiusz Miskiewicz.
6571
6572 2006-12-10  Bruno Haible  <bruno@clisp.org>
6573
6574         * gnulib-tool (func_import): Show the include files only for those
6575         modules that are copied and specified.
6576         Reported by Karl Berry.
6577
6578 2006-12-08  Jim Meyering  <jim@meyering.net>
6579
6580         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
6581         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
6582
6583         * build-aux/announce-gen: Add two new options, both optional:
6584         --bootstrap-tools=TOOL_LIST
6585               a comma-separated list of tools, e.g.,
6586               autoconf,automake,bison,gnulib
6587         --gnulib-snapshot-date=DATE
6588               if gnulib is in the bootstrap tool list,
6589               then report this as the snapshot date.
6590               If not specified, use the current date/time.
6591               If you specify a date here, be sure it's UTC.
6592
6593 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6594
6595         * tests/test-argp-2.sh: Fix test to match actual output.
6596         (func_compare): Fix sed script to be portable.
6597
6598 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
6599
6600         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
6601         workaround for this case.  It is not autoconfigured now; offhand
6602         it's hard to see how to autoconfigure it.
6603
6604 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
6605
6606         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
6607         a directory that is about to be chowned.  Such a directory's
6608         initial file permissions should permit the owner only and this
6609         should not be changed until after the chown, since the group and
6610         other bits would be incorrect if they granted permission before
6611         the chown.
6612
6613         Fix porting problem for iswctype reported by Georg Schwarz in:
6614         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
6615         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
6616         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
6617         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
6618         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
6619
6620 2006-12-03  Jim Meyering  <jim@meyering.net>
6621
6622         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
6623         p->fts_statp may not yet be defined.
6624         (fts_read): Instead, set it in the caller, once p->fts_statp is
6625         sure to be defined, and corresponds to a top-level directory.
6626         This bug made du -x fail.  Here's the coreutils test case:
6627         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
6628         Reported by Mike Frysinger.
6629
6630 2006-12-01  Jim Meyering  <jim@meyering.net>
6631
6632         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
6633         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
6634         Reported by Simon Josefsson.
6635
6636 2006-11-30  Jim Meyering  <jim@meyering.net>
6637
6638         * m4/warning.m4: Use the all-permissive copyright notice
6639         recommended by RMS (rather than LGPL).
6640         * m4/vararrays.m4: Likewise.
6641         * m4/flexmember.m4: Likewise.
6642
6643 2006-11-29  Bruno Haible  <bruno@clisp.org>
6644
6645         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
6646         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
6647         using +=.
6648         Reported by Simon Josefsson <simon@josefsson.org>.
6649
6650 2006-11-28  James Youngman <jay@gnu.org>
6651
6652         * README: Advise users that they might find the bug-gnulib@gnu.org
6653         and autotools-announce@gnu.org mailing lists useful.
6654
6655 2006-11-28  Bruno Haible  <bruno@clisp.org>
6656
6657         * m4/ptrdiff_max.m4: Remove file.
6658
6659 2006-11-21  Bruno Haible  <bruno@clisp.org>
6660
6661         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
6662         _AC_COMPUTE_INT.
6663         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6664         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
6665         _AC_COMPUTE_INT.
6666         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6667         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
6668         _AC_COMPUTE_INT.
6669         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6670
6671 2006-11-28  Jim Meyering  <jim@meyering.net>
6672
6673         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
6674         warning from "gcc -Wshadow" about shadowing the builtin.
6675
6676 2006-11-27  Bruno Haible  <bruno@clisp.org>
6677
6678         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
6679         _AC_COMPUTE_INT.
6680         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
6681
6682 2006-11-27  Bruno Haible  <bruno@clisp.org>
6683             Paul Eggert  <eggert@cs.ucla.edu>
6684
6685         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
6686
6687 2006-11-26  Bruno Haible  <bruno@clisp.org>
6688
6689         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
6690         noinst_LTLIBRARIES.
6691
6692 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
6693             Bruno Haible  <bruno@clisp.org>
6694
6695         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
6696         if compiling with "gcc -ansi".
6697
6698 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
6699
6700         Fix some incompatibilities with gcc -ansi -pedantic.
6701         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
6702         if compiling pedantically with GCC, unless it's C99 or later.
6703         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
6704         it mishandles gcc -ansi -pedantic as well.
6705         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
6706         if gcc -pedantic.
6707         * lib/regexec.c (check_node_accept_bytes): Don't use auto
6708         initializers for struct if -pedantic, unless it's C99 or later.
6709
6710 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
6711
6712         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
6713         Don't close an fd more than once. Identical atimes indicate
6714         success, not failure.
6715
6716 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
6717
6718         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
6719
6720 2006-11-23  Jim Meyering  <jim@meyering.net>
6721
6722         * build-aux/announce-gen: New file.  From coreutils.
6723
6724 2006-11-22  Jim Meyering  <jim@meyering.net>
6725
6726         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
6727         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
6728         (fts_read): Use a temporary to narrow the overused st_size member
6729         before using it in a switch statement.  Reported by Matthew Woehlke.
6730
6731         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
6732         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
6733
6734 2006-11-20  Bruno Haible  <bruno@clisp.org>
6735
6736         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
6737         changequote instead of pairs of brackets.
6738         Reported by Andreas Schwab <schwab@suse.de>.
6739
6740 2006-11-21  Jim Meyering  <jim@meyering.net>
6741
6742         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
6743         so as to remain compatible with older compilers.
6744         Patch from Michael Deutschmann.
6745
6746 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
6747
6748         * MODULES.html.sh (File system functions): Add openat.
6749
6750         * lib/openat.h (rpl_fstatat): New macro, if
6751         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
6752         (fstatat): Define to rpl_fstatat under the same conditions,
6753         unless COMPILING_FSTATAT.
6754         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
6755         seems to have the bug.
6756         * lib/fstatat.c: New file.
6757         * modules/openat (Files): Add it.
6758
6759 2006-11-20  Bruno Haible  <bruno@clisp.org>
6760
6761         * Makefile: New file.
6762
6763 2006-11-20  Jim Meyering  <jim@meyering.net>
6764
6765         The beginnings of syntax-related checks for gnulib.
6766         * lib/Makefile: New file.
6767         * lib/t-idcache: New script.  Ensure that the two halves of
6768         idcache.c stay in sync.
6769
6770         * lib/idcache.c: Adjust comments in user- and group- portions to
6771         be more accurate, and to be consistent with one another.
6772
6773 2006-11-20  Jim Meyering  <jim@meyering.net>
6774
6775         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
6776         continue using the flexible array member (thus, this module performs
6777         half as many malloc calls), with the addition that...
6778         (getgroup, getuser): Consistently record a non-match via an empty
6779         "name" string, and map an empty string match to a NULL return value.
6780         * modules/idcache (Depends-on): Re-add flexmember.
6781
6782         * lib/idcache.c (getuser): Remove all uses of the register keyword.
6783         (getuidbyname, getgroup, getgidbyname): Likewise.
6784
6785         Use cleaner syntax: NULL rather than 0.
6786         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
6787
6788 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
6789
6790         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
6791         It mishandled the case where the group was missing.
6792         Problem reported by Greg Schafer.
6793         * modules/idcache: Likewise.
6794
6795 2006-11-18  Jim Meyering  <jim@meyering.net>
6796
6797         * check-module (%exempt_header): Add exception for some
6798         conditionally-included headers.
6799
6800         * modules/i-ring (Depends-on): Add verify.
6801         (License): Change to LGPL.
6802
6803 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
6804
6805         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
6806         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
6807         and inttostr.h.  Use snprintf rather than uinttostr, so that
6808         LGPLed code doesn't depend on GPLed.
6809
6810 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
6811
6812         * modules/inline (License): Change from GPL to LGPL.
6813
6814 2006-11-17  Jim Meyering  <jim@meyering.net>
6815
6816         * modules/d-type (License): Switch to LGPL.
6817
6818 2006-11-15  Bruno Haible  <bruno@clisp.org>
6819
6820         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
6821
6822 2006-11-15  Eric Blake  <ebb9@byu.net>
6823
6824         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
6825         the module dependency.
6826
6827 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
6828             Bruno Haible  <bruno@clisp.org>
6829
6830         * gnulib-tool (func_create_testdir): Add license consistency check.
6831
6832 2006-11-15  Eric Blake  <ebb9@byu.net>
6833
6834         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
6835         random "(cached)" in configure output.
6836
6837 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6838
6839         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
6840         test for conforming inttypes.h is both announced and cached.
6841
6842         * MODULES.html.sh (seen_modules, seen_files): New variables.
6843         (func_module): Rewrite to use a few less gnulib-tool and sed
6844         invocations.  Avoid a couple of quadratic algorithms for ...
6845         (missed_modules, missed_files): ... these, with ...
6846         (func_append, func_tmpdir): ... these new functions, from
6847         gnulib-tool.  Analogously, install traps for cleanup.
6848
6849         * tests/test-gc.c (main): Remove unused variables.
6850         * tests/test-read-file.c: Include stdlib.h, for 'free'.
6851
6852 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
6853
6854         * modules/inttostr (License): Change to LGPL.
6855
6856 2006-11-14  Eric Blake  <ebb9@byu.net>
6857
6858         * modules/tempname (License): Change to LGPL.
6859
6860 2006-11-14  Eric Blake  <ebb9@byu.net>
6861
6862         * doc/functions.texi (Function Portability): *printf functions on
6863         Cygwin now understand all POSIX size specifiers.
6864
6865 2006-11-14  Bruno Haible  <bruno@clisp.org>
6866
6867         * modules/c-ctype (License): Change to LGPL.
6868
6869 2006-11-12  Bruno Haible  <bruno@clisp.org>
6870
6871         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
6872         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
6873         for GNOME libraries, for which the include files are installed in
6874         subdirectories of $prefix/include.
6875
6876 2006-11-12  Bruno Haible  <bruno@clisp.org>
6877
6878         * m4/lib-link.m4: Require at least autoconf-2.54.
6879         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
6880         name to underscores for the --with option.
6881
6882 2006-11-13  Bruno Haible  <bruno@clisp.org>
6883
6884         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
6885         the tests directory.
6886         Reported by Ralf Wildenhues.
6887
6888 2006-11-13  Bruno Haible  <bruno@clisp.org>
6889
6890         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
6891         (func_emit_initmacro_end): Undo the override here.
6892         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
6893         Works around the famous automake error in coreutils.
6894
6895 2006-11-13  Eric Blake  <ebb9@byu.net>
6896
6897         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
6898         element, not its node.
6899
6900 2006-11-12  Bruno Haible  <bruno@clisp.org>
6901
6902         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
6903         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
6904
6905 2006-11-12  Bruno Haible  <bruno@clisp.org>
6906
6907         * gnulib-tool: New option --local-symlink.
6908         (func_usage): Document it.
6909         (lsymbolic): New variable.
6910         (func_import, func_create_testdir): If --symlink was not specified,
6911         test whether --local-symlink was specified and the file comes from
6912         the local_gnulib_dir.
6913
6914 2006-11-12  Bruno Haible  <bruno@clisp.org>
6915
6916         * gnulib-tool (func_ln): New function.
6917         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
6918
6919 2006-11-12  Bruno Haible  <bruno@clisp.org>
6920
6921         Finish support for source files in subdirectories.
6922         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
6923         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
6924         AUTOMAKE_OPTIONS.
6925         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
6926
6927 2006-11-12  Bruno Haible  <bruno@clisp.org>
6928
6929         * gnulib-tool (func_get_automake_snippet): Synthesize also an
6930         EXTRA_lib_SOURCES augmentation.
6931         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
6932
6933 2006-11-12  Jim Meyering  <jim@meyering.net>
6934
6935         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
6936         file descriptors.  This also averts a failure on systems with
6937         native openat support when a traversed directory lacks "x" access.
6938         * lib/fts_.h: Include "i-ring.h"
6939         (struct FTS) [fts_fd_ring]: New member.
6940         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
6941         (FCHDIR): Add parentheses.
6942         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
6943         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
6944         When descending, rather than simply closing the previous
6945         fts_cwd_fd value, push that file descriptor onto the ring.
6946         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
6947         (fts_open): Initialize the new fd_ring member.
6948         (fts_close): Clear the ring.
6949         (fts_safe_changedir): When possible, use our new fd_ring to skip
6950         the diropen and fstat and dev/ino comparison that would normally
6951         accompany a virtual `chdir ("..")'.
6952
6953         * modules/fts (Depends-on): Add i-ring.
6954         * modules/i-ring: New module.
6955         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
6956         * m4/i-ring.m4: New file.
6957
6958 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6959
6960         * gnulib-tool (func_create_testdir): Fix replacement of
6961         `build-aux' in configure.ac.  Run autotools in gltests
6962         subdirectory.
6963         (func_create_testdir, func_create_megatestdir, test): There is
6964         no need for '--force' in most autotool invocations in a new
6965         tree.  Actually fail the whole test if any of the tools, or the
6966         configure or make stages fail.
6967
6968         Sync from Automake.
6969         * build-aux/gnupload: Revert last change.  Add pointer to upload
6970         instructions of the GNU Maintenance Instructions.
6971         Suggestion by Karl Berry.
6972
6973 2006-11-10  Jim Meyering  <jim@meyering.net>
6974
6975         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
6976
6977 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
6978
6979         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
6980         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
6981         (bind_textdomain_codeset) [! ENABLE_NLS]:
6982         Evaluate all the arguments.  That way, callers get compatible behavior
6983         if the arguments have side effects.  Also, it avoids some GCC
6984         diagnostics in some cases; Joel E. Denny reported problems when Bison
6985         was configured with --enable-gcc-warnigs.
6986
6987 2006-11-10  Jim Meyering  <jim@meyering.net>
6988
6989         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
6990         relevant options in CFLAGS (like -O, -fno-inline) are taken into
6991         account.
6992
6993 2006-11-10  Jim Meyering  <jim@meyering.net>
6994
6995         * modules/inline: New file/module.
6996         * modules/xalloc (Files): Remove m4/inline.m4.
6997         (Depends-on): Add inline, instead.
6998         * modules/oset: Likewise.
6999         * modules/list: Likewise.
7000
7001 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
7002
7003         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
7004         Problem reported by Matthew Woehlke.
7005
7006 2006-11-09  Bruno Haible  <bruno@clisp.org>
7007
7008         * lib/tempname.c (gen_tempname): Remove variant that invokes
7009         __gen_tempname.
7010         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
7011         __gen_tempname.
7012
7013 2006-11-08  Bruno Haible  <bruno@clisp.org>
7014
7015         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
7016         to 'yes' instead of 'cross-compiling'.
7017
7018 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
7019
7020         * lib/quotearg.h (quotearg_free): New decl.
7021         * lib/quotearg.c (quotearg_free): New function.
7022         (slot0, nslots, slotvec0, slotvec):
7023         Now file-scope so that quotearg_free can get at them.
7024
7025 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7026
7027         Sync from Automake.
7028         * build-aux/gnupload: Add missing 'gnu' to example URL.
7029         Report by Karl Berry.
7030
7031 2006-11-08  Bruno Haible  <bruno@clisp.org>
7032
7033         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
7034         Suggested by Paul Eggert.
7035
7036 2006-11-08  Jim Meyering  <jim@meyering.net>
7037
7038         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
7039         It's already included if !_LIBC.
7040         (fts_safe_changedir): Add a comment.
7041
7042 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
7043
7044         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
7045         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
7046         Matthew Woehlke.
7047
7048         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
7049         definitions up, to avoid colliding with change below.
7050         (static_inline) [HAVE_INLINE]: New macro.
7051         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
7052         Provide extern decls when !HAVE_INLINE.  Do not define unless
7053         static_inline is defined, either by us or by xmalloc.c.  Use
7054         static_inline rather than static inline.
7055         (XCALLOC): Optimize sizeof(T) = 1 case.
7056         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
7057
7058 2006-11-07  Bruno Haible  <bruno@clisp.org>
7059
7060         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
7061         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
7062         AC_C_INLINE.
7063         * modules/xalloc (Files): Add m4/inline.m4.
7064
7065 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7066
7067         * README: Fix typo.
7068         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
7069         (Miscellanous Notes): ...from this.
7070
7071 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
7072
7073         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
7074         Mention that offsetof should be used instead of sizeof.
7075         From Bruno Haible.
7076
7077 2006-11-07  Bruno Haible  <bruno@clisp.org>
7078
7079         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
7080
7081 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
7082
7083         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
7084         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
7085         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
7086         (gl_tree_add_before, gl_tree_add_after):
7087         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
7088         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
7089         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
7090         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
7091         (gl_linked_add_after, gl_linked_add_at): Likewise.
7092         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
7093         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
7094         (gl_tree_add_before, gl_tree_add_after): Likewise.
7095         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
7096         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
7097         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
7098
7099 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7100
7101         * lib/gl_oset.h: Use C comment style, not C++ comment style.
7102
7103 2006-11-06  Bruno Haible  <bruno@clisp.org>
7104
7105         * m4/inline.m4: New file.
7106         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
7107         * modules/list (Files): Add m4/inline.m4.
7108         * modules/oset (Files): Likewise.
7109
7110 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
7111
7112         * lib/idcache.c: Include <stddef.h>, for offsetof.
7113         (struct userid.name): Change from char * to a flexible array member.
7114         All uses changed.
7115         * modules/idcache (Depends-on): Add flexmember.
7116
7117         * MODULES.html.sh (Core language properties): New module flexmember.
7118         * modules/flexmember, m4/flexmember.m4: New files.
7119
7120         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
7121         inline functions that are identical with the old xnmalloc_inline,
7122         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
7123         that we can avoid some unnecessary integer multiplications and
7124         divisions in the common case where the element size is known at
7125         compile time.
7126         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
7127         needed.
7128         (xnboundedmalloc): Remove.
7129         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
7130         arguments, for consistency with rest of this header.
7131         (xcharalloc): Rewrite using XNMALLOC.
7132         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
7133         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
7134         versions have been moved to lib/xalloc.h and renamed to be the
7135         non-*_inline versions.
7136         (xmalloc, xrealloc): Implement without reference to the xnmalloc
7137         and xnrealloc functions, since those functions are now inline and
7138         now call us.
7139         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
7140         renaming described above.
7141         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
7142         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
7143         captures the dependency in AC_C_INLINE.
7144
7145         New module canonicalize-lgpl, proposed by Charles Wilson in
7146         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
7147         with a few small changes afterwards.
7148         * MODULES.html.sh (File system functions): New module
7149         canonicalize-lgpl.
7150         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
7151         and canonicalize_file_name.
7152         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
7153         * modules/canonicalize-lgpl: New files.
7154
7155 2006-11-05  Bruno Haible  <bruno@clisp.org>
7156
7157         * gnulib-tool (func_import, func_create_testdir): Create directories
7158         also for files in subdirectories of lib/.
7159
7160 2006-11-05  Bruno Haible  <bruno@clisp.org>
7161
7162         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
7163         ANSI C compliant.
7164
7165 2006-11-03  Bruno Haible  <bruno@clisp.org>
7166
7167         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
7168         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
7169         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
7170         (xnboundedmalloc): New inline function.
7171         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
7172         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
7173         xmalloc.
7174         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
7175         xmalloc.
7176         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
7177         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
7178         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
7179         xmalloc.
7180         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
7181         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
7182         xmalloc.
7183         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
7184         gl_tree_add_after): Use XMALLOC instead of xmalloc.
7185         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
7186         xmalloc.
7187         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
7188         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
7189         gl_tree_add_after): Use XMALLOC instead of xmalloc.
7190         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
7191         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
7192         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
7193         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
7194
7195 2006-11-03  Bruno Haible  <bruno@clisp.org>
7196
7197         * lib/c-ctype.h [C++]: Define functions without name mangling.
7198         * lib/fwriteerror.h [C++]: Likewise.
7199         * lib/gcd.h [C++]: Likewise.
7200         * lib/linebreak.h [C++]: Likewise.
7201
7202 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
7203
7204         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
7205         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
7206         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
7207         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
7208         Check for functions and headers just once.
7209         Check for declaration of canonicalize_file_name.
7210         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
7211
7212 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
7213
7214         * gnulib-tool (func_import): Fix typo in actioncmd.
7215
7216 2006-11-02  Bruno Haible  <bruno@clisp.org>
7217
7218         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
7219         newline sequence in the Makefile.am snippet as a space, like "make"
7220         does.
7221         Reported by Roger Persson <perrog@gmail.com>.
7222
7223 2006-11-01  Bruno Haible  <bruno@clisp.org>
7224
7225         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
7226         already declared in <string.h>.
7227         * lib/strcase.h (strncasecmp): Don't declare it if yes.
7228
7229 2006-11-01  Bruno Haible  <bruno@clisp.org>
7230
7231         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
7232         * lib/strcase.h: Include <string.h>.
7233         (strcasecmp): Define to rpl_strcasecmp here.
7234
7235 2006-11-01  Bruno Haible  <bruno@clisp.org>
7236
7237         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
7238
7239 2006-11-01  Eric Blake  <ebb9@byu.net>
7240
7241         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
7242
7243         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
7244
7245 2006-10-29  Bruno Haible  <bruno@clisp.org>
7246
7247         Make it compile in C++ mode.
7248         * lib/full-write.c (full_rw): Add a cast.
7249
7250 2006-11-01  Bruno Haible  <bruno@clisp.org>
7251
7252         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
7253         be POSIX compliant.
7254         Reported by Roger Persson <perrog@gmail.com>.
7255
7256 2006-11-01  Eric Blake  <ebb9@byu.net>
7257
7258         * lib/getopt_.h: Fix comments.
7259
7260 2006-10-31  Eric Blake  <ebb9@byu.net>
7261
7262         * modules/tmpdir (Depends-on): Add sys_stat.
7263         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
7264         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
7265         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
7266         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
7267         tempname.
7268
7269 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
7270
7271         Avoid some C++ diagnostics reported by Bruno Haible.
7272         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
7273         xmalloc.
7274         (quotearg_alloc): Use xcharalloc rather than xmalloc.
7275         (struct slotvec): Move to top level.
7276         (quotearg_n_options): Rewrite to avoid xmalloc.
7277         * lib/xalloc.h (xcharalloc): New function.
7278         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
7279         [defined __cplusplus]: Add function template that provides result
7280         type propagation.  This part of the change is from Bruno Haible.
7281
7282 2006-10-29  Bruno Haible  <bruno@clisp.org>
7283
7284         Make it compile in C++ mode.
7285         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
7286         * lib/strnlen1.c (strnlen1): Cast memchr result.
7287         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
7288         * lib/clean-temp.c (string_equals, string_hash): Add casts.
7289         (create_temp_dir): Rename local variable 'template'.
7290         (compile_csharp_using_sscli): Add cast.
7291         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
7292         * lib/findprog.c (find_in_path): Likewise.
7293         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
7294         * lib/wait-process.c (register_slave_subprocess): Likewise.
7295
7296 2006-10-22  Bruno Haible  <bruno@clisp.org>
7297
7298         * modules/tsearch: New file.
7299         * lib/tsearch.h: New file.
7300         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
7301         * m4/tsearch.m4: New file.
7302         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
7303
7304 2006-10-29  Eric Blake  <ebb9@byu.net>
7305
7306         * lib/arcfour.c: Assume config.h.
7307         * lib/arctwo.c: Likewise.
7308         * lib/base64.c: Likewise.
7309         * lib/check-version.c: Likewise.
7310         * lib/crc.c: Likewise.
7311         * lib/des.c: Likewise.
7312         * lib/gc-gnulib.c: Likewise.
7313         * lib/gc-libgcrypt.c: Likewise.
7314         * lib/gc-pbkdf2-sha1.c: Likewise.
7315         * lib/getaddrinfo.c: Likewise.
7316         * lib/getdelim.c: Likewise.
7317         * lib/getline.c: Likewise.
7318         * lib/hmac-md5.c: Likewise.
7319         * lib/hmac-sha1.c: Likewise.
7320         * lib/iconvme.c: Likewise.
7321         * lib/md2.c: Likewise.
7322         * lib/md4.c: Likewise.
7323         * lib/memxor.c: Likewise.
7324         * lib/read-file.c: Likewise.
7325         * lib/readline.c: Likewise.
7326         * lib/rijndael-alg-fst.c: Likewise.
7327         * lib/rijndael-api-fst.c: Likewise.
7328         * lib/xgetdomainname.c: Likewise.
7329
7330 2006-10-28  Eric Blake  <ebb9@byu.net>
7331
7332         * lib/xstrndup.c: Assume config.h.
7333
7334 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
7335
7336         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
7337         stat-macros.h is now for our own macros, whereas stat_h is for
7338         macros in the <sys/stat.h> name space.
7339         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
7340         (STAT_MACROS_H): Remove.
7341         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
7342         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
7343         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
7344         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
7345         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
7346         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
7347         Move these macros to ...
7348         * lib/stat_.h: here.  Don't include stat-macros.h.
7349         * lib/canonicalize.c: Don't include stat-macros.h.
7350         * lib/chown.c: Likewise.
7351         * lib/euidaccess.c: Likewise.
7352         * lib/file-type.c: Likewise.
7353         * lib/filemode.c: Likewise.
7354         * lib/glob.c: Likewise.
7355         * lib/isapipe.c: Likewise.
7356         * lib/lchown.c: Likewise.
7357         * lib/lstat.c: Likewise.
7358         * lib/mkdir-p.c: Likewise.
7359         * lib/rmdir.c: Likewise.
7360         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
7361         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
7362         unless mkdir isn't declared, to speed up 'configure'.
7363         Always create sys/stat.h, since it's unlikely any real sys/stat.h
7364         would define all the S_* symbols.
7365         * modules/canonicalize (Depends-on):
7366         Depend on sys_stat, not stat-macros.
7367         * modules/chown: Likewise.
7368         * modules/euidaccess: Likewise.
7369         * modules/filemode: Likewise.
7370         * modules/file-type: Likewise.
7371         * modules/glob: Likewise.
7372         * modules/isapipe: Likewise.
7373         * modules/lchown: Likewise.
7374         * modules/lstat: Likewise.
7375         * modules/mkancesdirs: Likewise.
7376         * modules/rmdir: Likewise.
7377         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
7378         * modules/modechange: Likewise.
7379         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
7380         (configure.ac): Remove gl_STAT_MACROS.
7381         * modules/sys_stat (Depends-on): Remove stat-macros.
7382
7383 2006-10-27  Bruno Haible  <bruno@clisp.org>
7384
7385         * m4/signed.m4: Remove file.
7386         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
7387         invocation.
7388         * modules/vasnprintf (Files): Remove m4/signed.m4.
7389
7390 2006-10-27  Bruno Haible  <bruno@clisp.org>
7391
7392         Update to GNU gettext 0.16.
7393         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
7394         m4/inttypes-h.m4, m4/signed.m4.
7395         * m4/gettext.m4: Update to GNU gettext 0.16.
7396         * m4/intl.m4: New file, from GNU gettext.
7397         * m4/intldir.m4: New file, from GNU gettext.
7398         * config/srclist.txt: Update
7399
7400 2006-10-27  Eric Blake  <ebb9@byu.net>
7401
7402         * MODULES.html.sh: Document tempname.
7403         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
7404         dependencies.
7405         (Files): Move lib/tempname.c...
7406         * modules/tempname: ...to this new module.
7407         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
7408         (gl_PREREQ_TEMPNAME): Move...
7409         * m4/tempname.m4: ...to this new file.
7410         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
7411         * modules/sys_stat (Depends-on): Add stat-macros.
7412         * lib/stat_.h (includes): Pick up stat macros.
7413         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
7414         if stat macros are broken.
7415         * lib/tempname.c (includes): No need to include "stat-macros.h".
7416         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
7417         (direxists, __path_search) [!_LIBC]: Don't compile these in
7418         gnulib; the tmpdir module covers that.
7419         * lib/tempname.h: New file.
7420
7421 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
7422
7423         * COPYING: Explain how gnulib-tool converts licence headers.
7424         Almost all wording by Eric Blake.
7425
7426 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
7427
7428         * lib/mbchar.h (is_basic_table): Make read-only.
7429         * lib/mbchar.c (is_basic_table): Likewise.
7430         Reported by John Darrington.
7431
7432 2006-10-25  Bruno Haible  <bruno@clisp.org>
7433
7434         * lib/progname.h (set_program_name): Undefine before defining.
7435
7436 2006-10-25  Bruno Haible  <bruno@clisp.org>
7437
7438         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
7439         false for non-gcc C++ compilers.
7440         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
7441
7442 2006-10-24  Bruno Haible  <bruno@clisp.org>
7443
7444         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
7445         iconv implementations like Irix iconv.
7446
7447 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
7448
7449         * modules/vararrays: New file.
7450         * m4/vararrays.m4: New file, taken from diffutils.
7451         * MODULES.html.sh: New module vararrays.
7452
7453 2006-10-24  Karl Berry  <karl@gnu.org>
7454
7455         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
7456         Don't call GNU Unix.
7457
7458 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7459
7460         * users.txt: Add Libtool.
7461
7462         Sync from Libtool:
7463
7464         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
7465
7466         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
7467         to gnulib's policy of including config.h unconditionally.
7468
7469 2006-10-24  Bruno Haible  <bruno@clisp.org>
7470
7471         * modules/wcwidth (Files): Add m4/wint_t.m4.
7472         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
7473         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
7474
7475 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
7476
7477         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
7478         to pacify GCC with some -W flags enabled.  Problem reported by
7479         Bruno Haible.
7480
7481 2006-10-24  Jim Meyering  <jim@meyering.net>
7482
7483         * MODULES.html.sh: Remove uinttostr.  It's not a module.
7484         Reported by Karl Berry.
7485
7486 2006-10-23  Bruno Haible  <bruno@clisp.org>
7487
7488         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
7489
7490 2006-10-24  Bruno Haible  <bruno@clisp.org>
7491
7492         * lib/gl_list.h: Use C comment style, not C++ comment style.
7493
7494 2006-10-23  Eric Blake  <ebb9@byu.net>
7495
7496         * lib/getaddrinfo.c (includes): Add missing include.
7497
7498 2006-10-23  Bruno Haible  <bruno@clisp.org>
7499             Paul Eggert  <eggert@cs.ucla.edu>
7500
7501         Ability to rename obstack_free.
7502         * lib/obstack.h (__obstack_free): New macro. Declare instead of
7503         obstack_free.
7504         (obstack_free): Invoke the __obstack_free macro.
7505         * lib/obstack.c (obstack_free): Use __obstack_free macro.
7506
7507 2006-10-23  Bruno Haible  <bruno@clisp.org>
7508             Paul Eggert  <eggert@cs.ucla.edu>
7509
7510         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
7511         __argc, __argv from the declaration. (They are defined as macros on
7512         mingw.)
7513
7514 2006-10-22  Bruno Haible  <bruno@clisp.org>
7515
7516         * doc/gnulib-intro.texi: New file.
7517         * doc/gnulib.texi: Include it.
7518
7519 2006-10-21  Bruno Haible  <bruno@clisp.org>
7520
7521         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
7522         "Introduction", "Miscellanous Notes", "Particular Modules".
7523
7524 2006-10-21  Bruno Haible  <bruno@clisp.org>
7525
7526         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7527         Change mostlyclean-local rule to avoid sh syntax error from bash
7528         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
7529
7530 2006-10-23  Jim Meyering  <jim@meyering.net>
7531
7532         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
7533         in place of snprintf.
7534
7535         * modules/inttostr (Files): Add lib/uinttostr.c.
7536         * lib/uinttostr.c (inttostr): New file/function.
7537         * lib/inttostr.h (uinttostr): Declare.
7538         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
7539         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
7540         Add uinttostr.
7541         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
7542
7543 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
7544
7545         * lib/canonicalize.c (ELOOP): Define if not already defined.
7546         Problem reported by Bruno Haible in
7547         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
7548
7549 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
7550
7551         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
7552         Problem reported by Perry Smith and Ville Laurikari.
7553
7554         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
7555         uses.
7556
7557 2006-10-19  Bruno Haible  <bruno@clisp.org>
7558
7559         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
7560         for mingw.
7561
7562 2006-10-19  Bruno Haible  <bruno@clisp.org>
7563
7564         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
7565         Needed for mingw.
7566
7567 2006-10-19  Bruno Haible  <bruno@clisp.org>
7568
7569         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
7570
7571 2006-10-19  Bruno Haible  <bruno@clisp.org>
7572
7573         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
7574         it.
7575
7576 2006-10-19  Bruno Haible  <bruno@clisp.org>
7577
7578         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
7579         invocation.
7580
7581 2006-10-19  Bruno Haible  <bruno@clisp.org>
7582
7583         * gnulib-tool (func_create_testdir): Don't include ftruncate and
7584         mountlist by default.
7585
7586 2006-10-16  Bruno Haible  <bruno@clisp.org>
7587
7588         * lib/c-strstr.c: Include c-strstr.h.
7589
7590 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
7591
7592         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
7593         in a slash.
7594
7595 2006-10-18  Bruno Haible  <bruno@clisp.org>
7596
7597         * lib/lock.h [C++]: Wrap definitions in extern "C".
7598
7599 2006-10-18  Bruno Haible  <bruno@clisp.org>
7600
7601         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
7602         gl_LIBOBJS list.
7603
7604 2006-10-18  Bruno Haible  <bruno@clisp.org>
7605
7606         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
7607
7608 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
7609
7610         * lib/xstrtol.h: Include gettext.h.
7611         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
7612         Problem reported by Eric Blake.
7613         * modules/xstrtol (Depends-on): Add gettext-h.
7614
7615 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
7616
7617         * lib/strftime.c (advance): New macro.
7618         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
7619         incomplete type, so you can't add 0 to it.  Problem and patch
7620         reported by Eelco Dolstra for dietlibc.
7621
7622 2006-10-18  Jim Meyering  <jim@meyering.net>
7623
7624         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
7625         type for a local, and rename it: s/up/user_proc/.
7626
7627 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
7628
7629         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
7630         READ_UTMP_USER_PROCESS.
7631         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
7632
7633 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
7634
7635         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
7636         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
7637
7638 2006-10-17  Eric Blake  <ebb9@byu.net>
7639
7640         * lib/sigprocmask.c (sigprocmask): Fix typo.
7641
7642         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
7643
7644         * modules/clean-temp (Makefile.am): Don't add to make output...
7645         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
7646         config.h.
7647
7648 2006-10-17  Bruno Haible  <bruno@clisp.org>
7649
7650         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
7651         differently if DEFAULT_TEXT_DOMAIN is set.
7652
7653 2006-10-16  Bruno Haible  <bruno@clisp.org>
7654
7655         * lib/clean-temp.c: Include fwriteerror.h.
7656
7657 2006-10-16  Bruno Haible  <bruno@clisp.org>
7658
7659         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
7660
7661 2006-10-16  Bruno Haible  <bruno@clisp.org>
7662
7663         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
7664         * lib/sigprocmask.h: Include <sys/types.h>.
7665         (sigset_t): Use the system's definition if present.
7666
7667 2006-10-17  Eric Blake  <ebb9@byu.net>
7668
7669         * lib/xvasprintf.c (includes): Assume config.h.
7670         * lib/xasprintf.c (includes): Likewise.
7671
7672 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
7673
7674         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
7675         at least as wide as intmax_t.
7676
7677 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
7678
7679         (Imported from Automake.)
7680         * build-aux/gnupload: Update to version 1.1 of directive file.
7681
7682 2006-10-16  Eric Blake  <ebb9@byu.net>
7683
7684         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
7685         match Automake 1.10a.
7686
7687 2006-10-14  Bruno Haible  <bruno@clisp.org>
7688
7689         * modules/sigprocmask: New file.
7690         * lib/sigprocmask.h: New file.
7691         * lib/sigprocmask.c: New file.
7692         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
7693         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
7694         request sigprocmask.o.
7695         (gl_PREREQ_SIGPROCMASK): New macro.
7696         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
7697         (Depends-on): Add sigprocmask.
7698         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
7699         gt_SIGNALBLOCKING. Test for 'raise' only once.
7700         * lib/fatal-signal.c: Include sigprocmask.h.
7701         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
7702         unblock_fatal_signals): Define always.
7703         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
7704         sigprocmask.
7705
7706 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
7707
7708         Sync from Automake.
7709         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
7710         which incorrectly sets the mode of an existing destination
7711         directory.  In some cases the unpatched install-sh could do the
7712         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
7713         system.  We hope this is rare in practice, but it's clearly worth
7714         fixing.  Problem reported by Alex Unleashed in
7715         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
7716         Also, don't bother to check for -m bugs unless we're using -m;
7717         suggested by Stepan Kasal.
7718
7719 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7720
7721         Sync from Automake.
7722         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
7723         `-c' flag, so they appear at the same position as in %FASTDEP%
7724         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
7725         which ignores unknown options only after the first non-option.
7726         Bug report against M4 by Nelson H. F. Beebe.
7727
7728 2006-10-13  Jim Meyering  <jim@meyering.net>
7729
7730         Fix a bug in yesterday's change.
7731         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
7732         p->fts_statp->st_dev would be used uninitialized.
7733         Ensures that we always call fts_stat on the very first entry.
7734         Miklos Szeredi reported that find -xdev stopped working.
7735
7736 2006-10-12  Bruno Haible  <bruno@clisp.org>
7737
7738         * gnulib-tool (func_get_automake_snippet): Append an automatically
7739         computed EXTRA_DIST augmentation.
7740         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
7741         * modules/alloca-opt (Makefile.am): Likewise.
7742         * modules/allocsa (Makefile.am): Likewise.
7743         * modules/arcfour (Makefile.am): Likewise.
7744         * modules/arctwo (Makefile.am): Likewise.
7745         * modules/argmatch (Makefile.am): Likewise.
7746         * modules/argz (Makefile.am): Likewise.
7747         * modules/atexit (Makefile.am): Likewise.
7748         * modules/backupfile (Makefile.am): Likewise.
7749         * modules/byteswap (Makefile.am): Likewise.
7750         * modules/c-strtod (Makefile.am): Likewise.
7751         * modules/c-strtold (Makefile.am): Likewise.
7752         * modules/calloc (Makefile.am): Likewise.
7753         * modules/canon-host (Makefile.am): Likewise.
7754         * modules/canonicalize (Makefile.am): Likewise.
7755         * modules/chdir-long (Makefile.am): Likewise.
7756         * modules/chdir-safer (Makefile.am): Likewise.
7757         * modules/check-version (Makefile.am): Likewise.
7758         * modules/chown (Makefile.am): Likewise.
7759         * modules/cloexec (Makefile.am): Likewise.
7760         * modules/close-stream (Makefile.am): Likewise.
7761         * modules/closeout (Makefile.am): Likewise.
7762         * modules/crc (Makefile.am): Likewise.
7763         * modules/csharpexec (Makefile.am): Likewise.
7764         * modules/cycle-check (Makefile.am): Likewise.
7765         * modules/des (Makefile.am): Likewise.
7766         * modules/dev-ino (Makefile.am): Likewise.
7767         * modules/dirfd (Makefile.am): Likewise.
7768         * modules/dirname (Makefile.am): Likewise.
7769         * modules/dup2 (Makefile.am): Likewise.
7770         * modules/eealloc (Makefile.am): Likewise.
7771         * modules/error (Makefile.am): Likewise.
7772         * modules/euidaccess (Makefile.am): Likewise.
7773         * modules/exclude (Makefile.am): Likewise.
7774         * modules/exitfail (Makefile.am): Likewise.
7775         * modules/fcntl-safer (Makefile.am): Likewise.
7776         * modules/fcntl (Makefile.am): Likewise.
7777         * modules/file-type (Makefile.am): Likewise.
7778         * modules/fileblocks (Makefile.am): Likewise.
7779         * modules/filemode (Makefile.am): Likewise.
7780         * modules/filenamecat (Makefile.am): Likewise.
7781         * modules/fnmatch (Makefile.am): Likewise.
7782         * modules/fopen-safer (Makefile.am): Likewise.
7783         * modules/fpending (Makefile.am): Likewise.
7784         * modules/fprintftime (Makefile.am): Likewise.
7785         * modules/free (Makefile.am): Likewise.
7786         * modules/fsusage (Makefile.am): Likewise.
7787         * modules/ftruncate (Makefile.am): Likewise.
7788         * modules/fts (Makefile.am): Likewise.
7789         * modules/gc-arcfour (Makefile.am): Likewise.
7790         * modules/gc-des (Makefile.am): Likewise.
7791         * modules/gc-hmac-md5 (Makefile.am): Likewise.
7792         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
7793         * modules/gc-md4 (Makefile.am): Likewise.
7794         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
7795         * modules/gc-sha1 (Makefile.am): Likewise.
7796         * modules/gc (Makefile.am): Likewise.
7797         * modules/getaddrinfo (Makefile.am): Likewise.
7798         * modules/getcwd (Makefile.am): Likewise.
7799         * modules/getdelim (Makefile.am): Likewise.
7800         * modules/getdomainname (Makefile.am): Likewise.
7801         * modules/getgroups (Makefile.am): Likewise.
7802         * modules/gethostname (Makefile.am): Likewise.
7803         * modules/gethrxtime (Makefile.am): Likewise.
7804         * modules/getline (Makefile.am): Likewise.
7805         * modules/getloadavg (Makefile.am): Likewise.
7806         * modules/getlogin_r (Makefile.am): Likewise.
7807         * modules/getndelim2 (Makefile.am): Likewise.
7808         * modules/getopt (Makefile.am): Likewise.
7809         * modules/getpagesize (Makefile.am): Likewise.
7810         * modules/getpass-gnu (Makefile.am): Likewise.
7811         * modules/getpass (Makefile.am): Likewise.
7812         * modules/getsubopt (Makefile.am): Likewise.
7813         * modules/gettime (Makefile.am): Likewise.
7814         * modules/gettimeofday (Makefile.am): Likewise.
7815         * modules/getugroups (Makefile.am): Likewise.
7816         * modules/getusershell (Makefile.am): Likewise.
7817         * modules/glob (Makefile.am): Likewise.
7818         * modules/group-member (Makefile.am): Likewise.
7819         * modules/hard-locale (Makefile.am): Likewise.
7820         * modules/hash (Makefile.am): Likewise.
7821         * modules/hmac-md5 (Makefile.am): Likewise.
7822         * modules/hmac-sha1 (Makefile.am): Likewise.
7823         * modules/human (Makefile.am): Likewise.
7824         * modules/idcache (Makefile.am): Likewise.
7825         * modules/imaxabs (Makefile.am): Likewise.
7826         * modules/imaxdiv (Makefile.am): Likewise.
7827         * modules/inet_ntop (Makefile.am): Likewise.
7828         * modules/inet_pton (Makefile.am): Likewise.
7829         * modules/intprops (Makefile.am): Likewise.
7830         * modules/inttostr (Makefile.am): Likewise.
7831         * modules/inttypes (Makefile.am): Likewise.
7832         * modules/isapipe (Makefile.am): Likewise.
7833         * modules/javaversion (Makefile.am): Likewise.
7834         * modules/lchmod (Makefile.am): Likewise.
7835         * modules/lchown (Makefile.am): Likewise.
7836         * modules/localcharset (Makefile.am): Likewise.
7837         * modules/long-options (Makefile.am): Likewise.
7838         * modules/lstat (Makefile.am): Likewise.
7839         * modules/malloc (Makefile.am): Likewise.
7840         * modules/mathl (Makefile.am): Likewise.
7841         * modules/mbchar (Makefile.am): Likewise.
7842         * modules/md2 (Makefile.am): Likewise.
7843         * modules/md4 (Makefile.am): Likewise.
7844         * modules/md5 (Makefile.am): Likewise.
7845         * modules/memcasecmp (Makefile.am): Likewise.
7846         * modules/memchr (Makefile.am): Likewise.
7847         * modules/memcmp (Makefile.am): Likewise.
7848         * modules/memcoll (Makefile.am): Likewise.
7849         * modules/memcpy (Makefile.am): Likewise.
7850         * modules/memmem (Makefile.am): Likewise.
7851         * modules/memmove (Makefile.am): Likewise.
7852         * modules/mempcpy (Makefile.am): Likewise.
7853         * modules/memrchr (Makefile.am): Likewise.
7854         * modules/memset (Makefile.am): Likewise.
7855         * modules/memxor (Makefile.am): Likewise.
7856         * modules/mkancesdirs (Makefile.am): Likewise.
7857         * modules/mkdir-p (Makefile.am): Likewise.
7858         * modules/mkdir (Makefile.am): Likewise.
7859         * modules/mkdtemp (Makefile.am): Likewise.
7860         * modules/mkstemp (Makefile.am): Likewise.
7861         * modules/mktime (Makefile.am): Likewise.
7862         * modules/modechange (Makefile.am): Likewise.
7863         * modules/mountlist (Makefile.am): Likewise.
7864         * modules/nanosleep (Makefile.am): Likewise.
7865         * modules/obstack (Makefile.am): Likewise.
7866         * modules/openat (Makefile.am): Likewise.
7867         * modules/pagealign_alloc (Makefile.am): Likewise.
7868         * modules/pathmax (Makefile.am): Likewise.
7869         * modules/physmem (Makefile.am): Likewise.
7870         * modules/poll (Makefile.am): Likewise.
7871         * modules/posixtm (Makefile.am): Likewise.
7872         * modules/posixver (Makefile.am): Likewise.
7873         * modules/putenv (Makefile.am): Likewise.
7874         * modules/quote (Makefile.am): Likewise.
7875         * modules/quotearg (Makefile.am): Likewise.
7876         * modules/raise (Makefile.am): Likewise.
7877         * modules/read-file (Makefile.am): Likewise.
7878         * modules/readline (Makefile.am): Likewise.
7879         * modules/readlink (Makefile.am): Likewise.
7880         * modules/readtokens (Makefile.am): Likewise.
7881         * modules/readutmp (Makefile.am): Likewise.
7882         * modules/realloc (Makefile.am): Likewise.
7883         * modules/regex (Makefile.am): Likewise.
7884         * modules/rename-dest-slash (Makefile.am): Likewise.
7885         * modules/rename (Makefile.am): Likewise.
7886         * modules/rijndael (Makefile.am): Likewise.
7887         * modules/rmdir (Makefile.am): Likewise.
7888         * modules/rpmatch (Makefile.am): Likewise.
7889         * modules/safe-read (Makefile.am): Likewise.
7890         * modules/safe-write (Makefile.am): Likewise.
7891         * modules/same-inode (Makefile.am): Likewise.
7892         * modules/same (Makefile.am): Likewise.
7893         * modules/save-cwd (Makefile.am): Likewise.
7894         * modules/savedir (Makefile.am): Likewise.
7895         * modules/setenv (Makefile.am): Likewise.
7896         * modules/settime (Makefile.am): Likewise.
7897         * modules/sha1 (Makefile.am): Likewise.
7898         * modules/sig2str (Makefile.am): Likewise.
7899         * modules/snprintf (Makefile.am): Likewise.
7900         * modules/stat-macros (Makefile.am): Likewise.
7901         * modules/stat-time (Makefile.am): Likewise.
7902         * modules/stdbool (Makefile.am): Likewise.
7903         * modules/stdint (Makefile.am): Likewise.
7904         * modules/stdlib-safer (Makefile.am): Likewise.
7905         * modules/stpcpy (Makefile.am): Likewise.
7906         * modules/stpncpy (Makefile.am): Likewise.
7907         * modules/strcase (Makefile.am): Likewise.
7908         * modules/strcasestr (Makefile.am): Likewise.
7909         * modules/strchrnul (Makefile.am): Likewise.
7910         * modules/strcspn (Makefile.am): Likewise.
7911         * modules/strdup (Makefile.am): Likewise.
7912         * modules/strerror (Makefile.am): Likewise.
7913         * modules/strftime (Makefile.am): Likewise.
7914         * modules/strndup (Makefile.am): Likewise.
7915         * modules/strnlen (Makefile.am): Likewise.
7916         * modules/strpbrk (Makefile.am): Likewise.
7917         * modules/strsep (Makefile.am): Likewise.
7918         * modules/strstr (Makefile.am): Likewise.
7919         * modules/strtod (Makefile.am): Likewise.
7920         * modules/strtoimax (Makefile.am): Likewise.
7921         * modules/strtok_r (Makefile.am): Likewise.
7922         * modules/strtol (Makefile.am): Likewise.
7923         * modules/strtoll (Makefile.am): Likewise.
7924         * modules/strtoul (Makefile.am): Likewise.
7925         * modules/strtoull (Makefile.am): Likewise.
7926         * modules/strtoumax (Makefile.am): Likewise.
7927         * modules/strverscmp (Makefile.am): Likewise.
7928         * modules/sys_socket (Makefile.am): Likewise.
7929         * modules/sys_stat (Makefile.am): Likewise.
7930         * modules/sysexits (Makefile.am): Likewise.
7931         * modules/time_r (Makefile.am): Likewise.
7932         * modules/timegm (Makefile.am): Likewise.
7933         * modules/timespec (Makefile.am): Likewise.
7934         * modules/tmpfile-safer (Makefile.am): Likewise.
7935         * modules/trim (Makefile.am): Likewise.
7936         * modules/unistd-safer (Makefile.am): Likewise.
7937         * modules/unlinkdir (Makefile.am): Likewise.
7938         * modules/unlocked-io (Makefile.am): Likewise.
7939         * modules/userspec (Makefile.am): Likewise.
7940         * modules/utime (Makefile.am): Likewise.
7941         * modules/utimecmp (Makefile.am): Likewise.
7942         * modules/utimens (Makefile.am): Likewise.
7943         * modules/vasnprintf (Makefile.am): Likewise.
7944         * modules/vasprintf (Makefile.am): Likewise.
7945         * modules/vsnprintf (Makefile.am): Likewise.
7946         * modules/xalloc (Makefile.am): Likewise.
7947         * modules/xgetcwd (Makefile.am): Likewise.
7948         * modules/xnanosleep (Makefile.am): Likewise.
7949         * modules/xreadlink (Makefile.am): Likewise.
7950         * modules/xstrtod (Makefile.am): Likewise.
7951         * modules/xstrtol (Makefile.am): Likewise.
7952         * modules/xstrtold (Makefile.am): Likewise.
7953         * modules/yesno (Makefile.am): Likewise.
7954         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
7955
7956 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
7957
7958         * modules/error (Makefile.am): Distribute files through
7959         EXTRA_DIST, not lib_SOURCES.
7960
7961 2006-10-12  Eric Blake  <ebb9@byu.net>
7962
7963         * modules/error (Makefile.am): Distribute files in /lib.
7964         * modules/obstack (Makefile.am): Likewise.
7965
7966 2006-10-12  Bruno Haible  <bruno@clisp.org>
7967
7968         * modules/acl (Makefile.am): Distribute all files in lib/ through
7969         EXTRA_DIST.
7970         * modules/arcfour (Makefile.am): Likewise.
7971         * modules/arctwo (Makefile.am): Likewise.
7972         * modules/argmatch (Makefile.am): Likewise.
7973         * modules/argz (Makefile.am): Likewise.
7974         * modules/atexit (Makefile.am): Likewise.
7975         * modules/backupfile (Makefile.am): Likewise.
7976         * modules/c-strtod (Makefile.am): Likewise.
7977         * modules/c-strtold (Makefile.am): Likewise.
7978         * modules/calloc (Makefile.am): Likewise.
7979         * modules/canon-host (Makefile.am): Likewise.
7980         * modules/canonicalize (Makefile.am): Likewise.
7981         * modules/chdir-long (Makefile.am): Likewise.
7982         * modules/chdir-safer (Makefile.am): Likewise.
7983         * modules/check-version (Makefile.am): Likewise.
7984         * modules/chown (Makefile.am): Likewise.
7985         * modules/cloexec (Makefile.am): Likewise.
7986         * modules/close-stream (Makefile.am): Likewise.
7987         * modules/closeout (Makefile.am): Likewise.
7988         * modules/crc (Makefile.am): Likewise.
7989         * modules/cycle-check (Makefile.am): Likewise.
7990         * modules/des (Makefile.am): Likewise.
7991         * modules/dirfd (Makefile.am): Likewise.
7992         * modules/dirname (Makefile.am): Likewise.
7993         * modules/dup2 (Makefile.am): Likewise.
7994         * modules/euidaccess (Makefile.am): Likewise.
7995         * modules/exclude (Makefile.am): Likewise.
7996         * modules/exitfail (Makefile.am): Likewise.
7997         * modules/fcntl-safer (Makefile.am): Likewise.
7998         * modules/file-type (Makefile.am): Likewise.
7999         * modules/fileblocks (Makefile.am): Likewise.
8000         * modules/filemode (Makefile.am): Likewise.
8001         * modules/filenamecat (Makefile.am): Likewise.
8002         * modules/fnmatch (Makefile.am): Likewise.
8003         * modules/fopen-safer (Makefile.am): Likewise.
8004         * modules/fpending (Makefile.am): Likewise.
8005         * modules/fprintftime (Makefile.am): Likewise.
8006         * modules/free (Makefile.am): Likewise.
8007         * modules/fsusage (Makefile.am): Likewise.
8008         * modules/ftruncate (Makefile.am): Likewise.
8009         * modules/fts (Makefile.am): Likewise.
8010         * modules/gc (Makefile.am): Likewise.
8011         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
8012         * modules/getaddrinfo (Makefile.am): Likewise.
8013         * modules/getcwd (Makefile.am): Likewise.
8014         * modules/getdelim (Makefile.am): Likewise.
8015         * modules/getdomainname (Makefile.am): Likewise.
8016         * modules/getgroups (Makefile.am): Likewise.
8017         * modules/gethostname (Makefile.am): Likewise.
8018         * modules/gethrxtime (Makefile.am): Likewise.
8019         * modules/getline (Makefile.am): Likewise.
8020         * modules/getloadavg (Makefile.am): Likewise.
8021         * modules/getlogin_r (Makefile.am): Likewise.
8022         * modules/getopt (Makefile.am): Likewise.
8023         * modules/getpass (Makefile.am): Likewise.
8024         * modules/getpass-gnu (Makefile.am): Likewise.
8025         * modules/getsubopt (Makefile.am): Likewise.
8026         * modules/gettime (Makefile.am): Likewise.
8027         * modules/gettimeofday (Makefile.am): Likewise.
8028         * modules/getugroups (Makefile.am): Likewise.
8029         * modules/getusershell (Makefile.am): Likewise.
8030         * modules/glob (Makefile.am): Likewise.
8031         * modules/group-member (Makefile.am): Likewise.
8032         * modules/hard-locale (Makefile.am): Likewise.
8033         * modules/hash (Makefile.am): Likewise.
8034         * modules/hmac-md5 (Makefile.am): Likewise.
8035         * modules/hmac-sha1 (Makefile.am): Likewise.
8036         * modules/human (Makefile.am): Likewise.
8037         * modules/idcache (Makefile.am): Likewise.
8038         * modules/imaxabs (Makefile.am): Likewise.
8039         * modules/imaxdiv (Makefile.am): Likewise.
8040         * modules/inet_ntop (Makefile.am): Likewise.
8041         * modules/inet_pton (Makefile.am): Likewise.
8042         * modules/inttostr (Makefile.am): Likewise.
8043         * modules/isapipe (Makefile.am): Likewise.
8044         * modules/lchown (Makefile.am): Likewise.
8045         * modules/long-options (Makefile.am): Likewise.
8046         * modules/lstat (Makefile.am): Likewise.
8047         * modules/malloc (Makefile.am): Likewise.
8048         * modules/mathl (Makefile.am): Likewise.
8049         * modules/mbchar (Makefile.am): Likewise.
8050         * modules/md2 (Makefile.am): Likewise.
8051         * modules/md4 (Makefile.am): Likewise.
8052         * modules/md5 (Makefile.am): Likewise.
8053         * modules/memcasecmp (Makefile.am): Likewise.
8054         * modules/memchr (Makefile.am): Likewise.
8055         * modules/memcmp (Makefile.am): Likewise.
8056         * modules/memcoll (Makefile.am): Likewise.
8057         * modules/memcpy (Makefile.am): Likewise.
8058         * modules/memmem (Makefile.am): Likewise.
8059         * modules/memmove (Makefile.am): Likewise.
8060         * modules/mempcpy (Makefile.am): Likewise.
8061         * modules/memrchr (Makefile.am): Likewise.
8062         * modules/memset (Makefile.am): Likewise.
8063         * modules/memxor (Makefile.am): Likewise.
8064         * modules/mkancesdirs (Makefile.am): Likewise.
8065         * modules/mkdir (Makefile.am): Likewise.
8066         * modules/mkdir-p (Makefile.am): Likewise.
8067         * modules/mkdtemp (Makefile.am): Likewise.
8068         * modules/mkstemp (Makefile.am): Likewise.
8069         * modules/mktime (Makefile.am): Likewise.
8070         * modules/modechange (Makefile.am): Likewise.
8071         * modules/mountlist (Makefile.am): Likewise.
8072         * modules/nanosleep (Makefile.am): Likewise.
8073         * modules/openat (Makefile.am): Likewise.
8074         * modules/pagealign_alloc (Makefile.am): Likewise.
8075         * modules/physmem (Makefile.am): Likewise.
8076         * modules/poll (Makefile.am): Likewise.
8077         * modules/posixtm (Makefile.am): Likewise.
8078         * modules/posixver (Makefile.am): Likewise.
8079         * modules/putenv (Makefile.am): Likewise.
8080         * modules/quote (Makefile.am): Likewise.
8081         * modules/quotearg (Makefile.am): Likewise.
8082         * modules/raise (Makefile.am): Likewise.
8083         * modules/read-file (Makefile.am): Likewise.
8084         * modules/readline (Makefile.am): Likewise.
8085         * modules/readlink (Makefile.am): Likewise.
8086         * modules/readtokens (Makefile.am): Likewise.
8087         * modules/readutmp (Makefile.am): Likewise.
8088         * modules/realloc (Makefile.am): Likewise.
8089         * modules/regex (Makefile.am): Likewise.
8090         * modules/rename (Makefile.am): Likewise.
8091         * modules/rename-dest-slash (Makefile.am): Likewise.
8092         * modules/rijndael (Makefile.am): Likewise.
8093         * modules/rmdir (Makefile.am): Likewise.
8094         * modules/rpmatch (Makefile.am): Likewise.
8095         * modules/safe-read (Makefile.am): Likewise.
8096         * modules/safe-write (Makefile.am): Likewise.
8097         * modules/same (Makefile.am): Likewise.
8098         * modules/save-cwd (Makefile.am): Likewise.
8099         * modules/savedir (Makefile.am): Likewise.
8100         * modules/setenv (Makefile.am): Likewise.
8101         * modules/settime (Makefile.am): Likewise.
8102         * modules/sha1 (Makefile.am): Likewise.
8103         * modules/sig2str (Makefile.am): Likewise.
8104         * modules/snprintf (Makefile.am): Likewise.
8105         * modules/stdlib-safer (Makefile.am): Likewise.
8106         * modules/stpcpy (Makefile.am): Likewise.
8107         * modules/stpncpy (Makefile.am): Likewise.
8108         * modules/strcase (Makefile.am): Likewise.
8109         * modules/strcasestr (Makefile.am): Likewise.
8110         * modules/strchrnul (Makefile.am): Likewise.
8111         * modules/strcspn (Makefile.am): Likewise.
8112         * modules/strdup (Makefile.am): Likewise.
8113         * modules/strerror (Makefile.am): Likewise.
8114         * modules/strftime (Makefile.am): Likewise.
8115         * modules/strndup (Makefile.am): Likewise.
8116         * modules/strnlen (Makefile.am): Likewise.
8117         * modules/strpbrk (Makefile.am): Likewise.
8118         * modules/strsep (Makefile.am): Likewise.
8119         * modules/strstr (Makefile.am): Likewise.
8120         * modules/strtod (Makefile.am): Likewise.
8121         * modules/strtoimax (Makefile.am): Likewise.
8122         * modules/strtok_r (Makefile.am): Likewise.
8123         * modules/strtol (Makefile.am): Likewise.
8124         * modules/strtoll (Makefile.am): Likewise.
8125         * modules/strtoul (Makefile.am): Likewise.
8126         * modules/strtoull (Makefile.am): Likewise.
8127         * modules/strtoumax (Makefile.am): Likewise.
8128         * modules/strverscmp (Makefile.am): Likewise.
8129         * modules/time_r (Makefile.am): Likewise.
8130         * modules/timegm (Makefile.am): Likewise.
8131         * modules/tmpfile-safer (Makefile.am): Likewise.
8132         * modules/unistd-safer (Makefile.am): Likewise.
8133         * modules/unlinkdir (Makefile.am): Likewise.
8134         * modules/userspec (Makefile.am): Likewise.
8135         * modules/utime (Makefile.am): Likewise.
8136         * modules/utimecmp (Makefile.am): Likewise.
8137         * modules/utimens (Makefile.am): Likewise.
8138         * modules/vasnprintf (Makefile.am): Likewise.
8139         * modules/vasprintf (Makefile.am): Likewise.
8140         * modules/vsnprintf (Makefile.am): Likewise.
8141         * modules/xalloc (Makefile.am): Likewise.
8142         * modules/xgetcwd (Makefile.am): Likewise.
8143         * modules/xnanosleep (Makefile.am): Likewise.
8144         * modules/xreadlink (Makefile.am): Likewise.
8145         * modules/xstrtod (Makefile.am): Likewise.
8146         * modules/xstrtol (Makefile.am): Likewise.
8147         * modules/xstrtold (Makefile.am): Likewise.
8148         * modules/yesno (Makefile.am): Likewise.
8149
8150 2006-10-12  Jim Meyering  <jim@meyering.net>
8151
8152         * m4/getloadavg.m4: Revert the change below.
8153
8154         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
8155         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
8156         fail with a symlink, which is what coreutils' ./bootstrap now
8157         creates by default.
8158
8159 2006-10-12  Bruno Haible  <bruno@clisp.org>
8160
8161         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
8162         mingw.
8163         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
8164         MSVC and mingw explicitly.
8165
8166 2006-10-11  Simon Josefsson  <jas@extundo.com>
8167             Bruno Haible  <bruno@clisp.org>
8168
8169         Add support for multiple gnulib-tool invocations in the scope of a
8170         single configure.ac file.
8171         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
8172         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
8173         with the same contents as the _LIBADD variable.
8174         (func_emit_initmacro_start, func_emit_initmacro_end,
8175         func_emit_initmacro_done): New functions.
8176         (func_import, func_create_testdir): Invoke them. Allow the identifiers
8177         gl_LIBOBJS and gl_LTLIBOBJS.
8178
8179 2006-10-11  Bruno Haible  <bruno@clisp.org>
8180
8181         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
8182         (func_create_testdir): Don't create po/Makefile.am, don't invoke
8183         autoreconf. Instead, invoke autopoint explicitly but move back the
8184         *.m4 files from gnulib.
8185
8186 2006-10-11  Bruno Haible  <bruno@clisp.org>
8187
8188         * gnulib-tool (func_usage): Make module names after --create-testdir
8189         optional.
8190         (func_create_testdir): If no module was specified, use nearly all
8191         modules.
8192
8193 2006-10-12  Jim Meyering  <jim@meyering.net>
8194
8195         Big performance improvement for fts-based tools that use FTS_NOSTAT.
8196         Avoid spurious inode-mismatch problems on non-POSIX file systems.
8197         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
8198         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
8199         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
8200         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
8201         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
8202         (fts_set_stat_required): New function.
8203         (fts_open): Defer the calls to fts_stat, if possible or requested.
8204         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
8205         into fts_stat itself.
8206         (fts_read): Perform any required (deferred) fts_stat call.
8207         (fts_build): Likewise, for the directory we're about to open and read.
8208         In the readdir loop, carefully decide whether each entry will require
8209         an eventual call to fts_stat, using dirent.d_type info if available.
8210         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
8211         a command line argument into this function.  Update all callers.
8212         Map a return value of FTS_DOT to FTS_D for a command line argument.
8213         * modules/fts (Depends-on): Add d-type.  Alphabetize.
8214         Thanks to Miklos Szeredi for his tenacity and for the initial
8215         bug report about "find" failing on a FUSE-based file system.
8216
8217         * lib/fts.c (fts_open): Use consistent indentation.
8218
8219 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
8220
8221         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
8222         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
8223         reported by Jim Meyering.  All uses of cache variables renamed
8224         to match Autoconf's.
8225         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
8226         the other one.
8227
8228         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
8229         Fix misspelling in diagnostic.
8230
8231 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
8232
8233         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
8234         defined.  Problem reported by Matthew Woehlke.
8235
8236         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
8237         Add support for Tandem NonStop R series.
8238         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
8239         Use new macro.
8240
8241         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
8242         (has_trailing_slash): Omit size arg; all callers changed.
8243         Omit 'inline', since it doesn't help performance and we'd
8244         need to configure it.
8245         Don't count //, ///, etc. as having a trailing slash.
8246         As a side effect, this removes a C99ism reported by Matthew Woehlke.
8247         (rpl_rename_dest_slash): On failure, use rename's errno rather
8248         than (in some cases) an incorrect or junk errno.
8249         Simplify code by removing need to compute length; this does
8250         cause it to make two passes instead of one over the file name,
8251         but it's worth it.
8252
8253         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
8254         change, since Autoconf's version may no longer be appropriate now
8255         that we are using CVS Autoconf's version.  Add support for Tandem.
8256
8257 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
8258             Bruno Haible  <bruno@clisp.org>
8259
8260         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
8261         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
8262         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
8263         gl_AC_TYPE_LONG_LONG.
8264
8265         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
8266         instead of HAVE_LONG_LONG.
8267         * lib/printf-args.c (printf_fetchargs): Likewise.
8268         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
8269         * lib/vasnprintf.c (VASNPRINTF): Likewise.
8270         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
8271         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
8272         gl_AC_TYPE_LONG_LONG.
8273
8274 2006-10-11  Bruno Haible  <bruno@clisp.org>
8275
8276         * m4/longlong.m4: Add comments.
8277         * m4/ulonglong.m4: Likewise.
8278
8279 2006-10-10  Bruno Haible  <bruno@clisp.org>
8280
8281         Make it possible to #define stpcpy, strdup to aliases.
8282         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
8283         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
8284
8285 2006-10-10  Bruno Haible  <bruno@clisp.org>
8286
8287         Make it possible to #define gcd to an alias.
8288         * lib/gcd.c: Include config.h.
8289
8290 2006-10-10  Bruno Haible  <bruno@clisp.org>
8291
8292         Make it possible to #define c_isascii to an alias.
8293         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
8294         defined. Undefine the macros before defining them, to avoid gcc
8295         warnings.
8296         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
8297         define NO_C_CTYPE_MACROS early.
8298
8299 2006-10-10  Bruno Haible  <bruno@clisp.org>
8300
8301         Make it possible to #define set_program_name to an alias.
8302         * lib/progname.c: Don't undefine set_program_name; instead, undefine
8303         ENABLE_RELOCATABLE early.
8304
8305 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
8306
8307         Port to Tandem NSK OSS, which has 64-bit signed int but at most
8308         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
8309         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
8310         More generally, don't assume that 64-bit signed int is available
8311         if unsigned int is, and vice versa.
8312         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
8313         unsigned symbols, not on their signed counterparts.
8314         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
8315         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
8316         (UINT64_C, UINTMAX_C):
8317         Likewise.
8318         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
8319         unsigned counterparts.
8320         (Have_long_long, Unsigned): New macros.
8321         (Int): Renamed from INT.
8322         (strtoimax): Use the new macros.
8323         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
8324         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
8325         * modules/inttypes (inttypes.h): Substitute
8326         HAVE_UNSIGNED_LONG_LONG_INT.
8327         * modules/stdint (stdint.h): Likewise.
8328         (Files): Add m4/ulonglong.m4.
8329
8330 2006-10-10  Bruno Haible  <bruno@clisp.org>
8331
8332         Fix a gcc -Wshadow warning.
8333         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
8334         to 'bucket'.
8335         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
8336         gl_linked_indexof_from_to): Likewise.
8337         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
8338         Likewise.
8339         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
8340         Likewise.
8341         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
8342         Reported by Eric Blake.
8343
8344 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
8345
8346         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
8347         for NetBSD.  Problem reported by Bruno Haible.
8348
8349 2006-10-09  Jim Meyering  <jim@meyering.net>
8350
8351         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
8352         Patch from Bruno Haible.
8353
8354 2006-10-09  Jim Meyering  <jim@meyering.net>
8355
8356         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
8357         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
8358         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
8359
8360 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
8361
8362         Don't include <config.h> twice; this doesn't work in some cases,
8363         e.g., when config.h has "#define intmax_t long long int" and
8364         we include <config.h>, <inttypes.h>, <config.h> in that order.
8365         Problem reported by Matthew Woehlke in:
8366         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
8367         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
8368         * lib/fts-cycle.c: Don't include config.h.
8369         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
8370         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
8371         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
8372         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
8373         inttypes.h.
8374         * lib/xstrtoumax.c: Likewise.
8375         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
8376         __strtol and the like, so that this module is more like its siblings.
8377         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
8378         Remove; no longer needed now that we assume gnulib inttypes.h.
8379
8380 2006-10-08  Bruno Haible  <bruno@clisp.org>
8381
8382         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
8383         option.
8384
8385 2006-10-07  Jim Meyering  <jim@meyering.net>
8386
8387         * modules/inttypes (inttypes.h): Revert what seems to have been
8388         an inadvertent part of today's change: use "|", not "/" in the
8389         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
8390
8391 2006-10-07  Bruno Haible  <bruno@clisp.org>
8392
8393         * modules/sublist: New file.
8394
8395 2006-10-07  Bruno Haible  <bruno@clisp.org>
8396
8397         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
8398         * modules/argz (argz.h): Likewise.
8399         * modules/arpa_inet (arpa/inet.h): Likewise.
8400         * modules/byteswap (byteswap.h): Likewise.
8401         * modules/configmake (configmake.h): Likewise.
8402         * modules/fcntl (fcntl.h): Likewise.
8403         * modules/fnmatch (fnmatch.h): Likewise.
8404         * modules/getopt (getopt.h): Likewise.
8405         * modules/glob (glob.h): Likewise.
8406         * modules/inttypes (inttypes.h): Likewise.
8407         * modules/netinet_in (netinet/in.h): Likewise.
8408         * modules/poll (poll.h): Likewise.
8409         * modules/stdbool (stdbool.h): Likewise.
8410         * modules/stdint (stdint.h): Likewise.
8411         * modules/sys_select (sys/select.h): Likewise.
8412         * modules/sys_socket (sys/socket.h): Likewise.
8413         * modules/sys_stat (sys/stat.h): Likewise.
8414         * modules/sysexits (sysexits.h): Likewise.
8415         * modules/unistd (unistd.h): Likewise.
8416         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
8417         Add a "DO NOT EDIT" comment to the generated file.
8418         (func_import): Likewise for gnulib-comp.m4.
8419
8420 2006-10-07  Bruno Haible  <bruno@clisp.org>
8421
8422         * lib/gl_sublist.h: New file.
8423         * lib/gl_sublist.c: New file.
8424
8425 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
8426
8427         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
8428         name (relative to the original working directory) and the file
8429         name component (relative to the temporary working directory).  All
8430         callers changed.
8431         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
8432         * lib/mkdir-p.c (make_dir_parents): Likewise.
8433         * lib/mkdir-p.h (make_dir_parents): Likewise.
8434
8435 2006-10-06  Eric Blake  <ebb9@byu.net>
8436
8437         Define several macros for use by the clean-temp module.
8438         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
8439         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
8440         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
8441
8442         * lib/clean-temp.h (close_stream_temp): New declaration.
8443         * lib/clean-temp.c (includes): Pull in headers according to what
8444         other modules are in use.
8445         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
8446
8447 2006-10-06  Bruno Haible  <bruno@clisp.org>
8448
8449         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
8450         instead of fopen, fwriteerror.
8451
8452 2006-10-06  Bruno Haible  <bruno@clisp.org>
8453
8454         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
8455         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
8456         int.
8457         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
8458         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
8459         Return an error indicator.
8460         Suggested by Eric Blake.
8461
8462 2006-10-06  Bruno Haible  <bruno@clisp.org>
8463
8464         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
8465         Reported by Eric Blake.
8466
8467 2006-10-06  Bruno Haible  <bruno@clisp.org>
8468
8469         * modules/closeout (Description): Mention stderr too.
8470
8471 2006-10-06  Bruno Haible  <bruno@clisp.org>
8472         and Paul Eggert  <eggert@cs.ucla.edu>
8473
8474         * lib/closeout.c (close_stdout): Also close stderr.
8475         * lib/closeout.h: Update comment.
8476
8477 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
8478
8479         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
8480         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
8481         * lib/dirchownmod.c: Include lchown.h.
8482         * lib/lchown.c: Don't include files that lchown.h now includes.
8483         Don't declare chown, since lchown.h now does that.
8484         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
8485         (lchown): Define to rpl_chown if lchown is declared but
8486         does not exist.  Declare using a prototype if lchown is not
8487         declared.  Add a copyright notice.
8488         * lib/mkstemp.h: Include <unistd.h>.
8489         * lib/openat.c: Include lchown.h.
8490
8491         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
8492         we now test for that separately.
8493         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
8494         rather than O_NOFOLLOW, when testing whether it's possible to
8495         avoid a race condition reliably.
8496         * lib/savewd.c (savewd_chdir): Likewise.
8497
8498         Remove macros that are no longer needed now that stdint.h is
8499         reliable.
8500         * lib/fsusage.c (UINTMAX_MAX): Remove.
8501         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
8502         * lib/utimecmp.c (SIZE_MAX): Remove.
8503
8504         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
8505
8506         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
8507         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
8508         O_NOATIME works.
8509
8510 2006-10-05  Bruno Haible  <bruno@clisp.org>
8511
8512         * lib/gl_list.h (gl_sortedlist_search_from_to,
8513         gl_sortedlist_indexof_from_to): New declarations.
8514         (gl_list_implementation): New fields sortedlist_search_from_to,
8515         sortedlist_indexof_from_to.
8516         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
8517         inline functions.
8518         * lib/gl_list.c (gl_sortedlist_search_from_to,
8519         gl_sortedlist_indexof_from_to): New functions.
8520         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
8521         function.
8522         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
8523         (gl_array_sortedlist_search_from_to): New function.
8524         (gl_array_list_implementation): Update.
8525         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
8526         function.
8527         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
8528         (gl_carray_sortedlist_search_from_to): New function.
8529         (gl_carray_list_implementation): Update.
8530         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
8531         gl_linked_sortedlist_indexof_from_to): New functions.
8532         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
8533         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
8534         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
8535         gl_tree_sortedlist_indexof_from_to): New functions.
8536         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
8537         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
8538         Update.
8539         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
8540         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
8541         Update.
8542
8543 2006-10-05  Bruno Haible  <bruno@clisp.org>
8544
8545         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
8546         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
8547         (struct gl_list_implementation): Add fields search_from_to,
8548         indexof_from_to. Remove fields search, indexof.
8549         (gl_list_search): Use the search_from_to method.
8550         (gl_list_search_from, gl_list_search_from_to): New functions.
8551         (gl_list_indexof): Use the indexof_from_to method.
8552         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
8553         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
8554         (gl_list_search_from, gl_list_search_from_to): New functions.
8555         (gl_list_indexof): Use the indexof_from_to method.
8556         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
8557         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
8558         gl_array_indexof. Add start_index, end_index arguments.
8559         (gl_array_search_from_to): Renamed from gl_array_search. Add
8560         start_index, end_index arguments.
8561         (gl_array_remove, gl_array_list_implementation): Update.
8562         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
8563         gl_carray_indexof. Add start_index, end_index arguments.
8564         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
8565         start_index, end_index arguments.
8566         (gl_carray_remove, gl_carray_list_implementation): Update.
8567         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
8568         gl_linked_search. Add start_index, end_index arguments.
8569         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
8570         start_index, end_index arguments.
8571         (gl_linked_remove): Update.
8572         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
8573         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
8574         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
8575         field to 'size_t'.
8576         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
8577         gl_tree_search. Add start_index, end_index arguments.
8578         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
8579         start_index, end_index arguments.
8580         (gl_tree_remove): Update.
8581         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
8582         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
8583         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
8584         function.
8585         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
8586         gl_tree_search. Add start_index, end_index arguments.
8587         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
8588         start_index, end_index arguments.
8589         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
8590         Update.
8591         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
8592
8593 2006-10-05  Bruno Haible  <bruno@clisp.org>
8594
8595         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
8596
8597         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
8598         fwriteerror_temp): New declarations.
8599         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
8600         (descriptors): New variable.
8601         (cleanup): First, close the descriptors.
8602         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
8603         fclose_temp, fwriteerror_temp): New functions.
8604
8605 2006-10-04  Jim Meyering  <jim@meyering.net>
8606
8607         * lib/fts.c (fts_open): Tiny comment change.
8608
8609 2006-10-04  Bruno Haible  <bruno@clisp.org>
8610
8611         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
8612         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
8613         gl_LOCK_BODY.
8614         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
8615         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
8616         gl_LOCK_EARLY_BODY.
8617         (gl_LOCK): Require gl_LOCK_BODY.
8618
8619 2006-10-04  Bruno Haible  <bruno@clisp.org>
8620
8621         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
8622         (gl_oset_search_atleast): New declaration.
8623         (struct gl_oset_implementation): Add field 'search_atleast'.
8624         (gl_oset_search_atleast): New inline function.
8625         * lib/gl_oset.c (gl_oset_search_atleast): New function.
8626         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
8627         (gl_array_oset_implementation): Update.
8628         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
8629         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
8630         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
8631
8632 2006-10-04  Bruno Haible  <bruno@clisp.org>
8633
8634         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
8635
8636 2006-10-03  Bruno Haible  <bruno@clisp.org>
8637
8638         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
8639         from gl_avltreehash_list_implementation.
8640
8641 2006-10-03  Bruno Haible  <bruno@clisp.org>
8642
8643         * lib/gl_oset.c (gl_oset_add): Fix return type.
8644
8645 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
8646
8647         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
8648
8649 2006-10-02  Eric Blake  <ebb9@byu.net>
8650
8651         * modules/strnlen (Depends-on): Add extensions.
8652
8653 2006-10-02  Eric Blake  <ebb9@byu.net>
8654
8655         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
8656         definition in 2.60+.
8657
8658 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
8659
8660         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
8661         checks.
8662
8663 2006-10-02  Bruno Haible  <bruno@clisp.org>
8664
8665         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
8666         to the AUTOMAKE_OPTIONS.
8667         Reported by Jim Meyering.
8668
8669 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
8670
8671         Work around bug in Solaris 10 /proc file system:
8672         /proc/self/fd/NNN/.. isn't the parent directory of
8673         the directory whose file descriptor is NNN.  This needs to
8674         be worked around at run time, not compile time, since a
8675         program might be built on Solaris 8, where things work, and
8676         run on Solaris 10.
8677         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
8678         to use the following interface instead:
8679         (OPENAT_BUFFER_SIZE): New macro.
8680         (openat_proc_name): New function.
8681         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
8682         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
8683         Likewise.
8684         * lib/openat-proc.c: New file.
8685         * modules/openat (Files): Add lib/openat-proc.c.
8686         (Depends-on): Add same-inode, stdbool.
8687         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
8688
8689 2006-09-29  Bruno Haible  <bruno@clisp.org>
8690
8691         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
8692         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
8693         argument. Set stdout_closed before testing for ferror, not after.
8694         (fwriteerror, fwriteerror_no_ebadf): New functions.
8695
8696 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8697
8698         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
8699
8700 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
8701
8702         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
8703         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
8704
8705 2006-09-28  Jim Meyering  <jim@meyering.net>
8706
8707         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
8708         Include <unistd.h>.
8709
8710 2006-09-28  Bruno Haible  <bruno@clisp.org>
8711
8712         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
8713         * modules/linkedhash-list (Depends-on): Likewise.
8714         * modules/rbtreehash-list (Depends-on): Likewise.
8715
8716 2006-09-28  Bruno Haible  <bruno@clisp.org>
8717
8718         * lib/strndup.h: Simplify the redefinition of strndup.
8719         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
8720         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
8721
8722 2006-09-28  Bruno Haible  <bruno@clisp.org>
8723
8724         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
8725         * lib/gl_linkedhash_list.c: Likewise.
8726         * lib/gl_rbtreehash_list.c: Likewise.
8727
8728 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
8729
8730         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
8731         getaddrinfo.
8732
8733         * lib/__fpending.h: Don't include <stdio_ext.h> unless
8734         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
8735         it causes <stdio_ext.h> to cause a compile-time error.
8736         Problem reported by Nelson H. F. Beebe.
8737         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
8738         of HAVE_DECL___PENDING.
8739
8740         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
8741         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
8742         declaration.
8743
8744 2006-09-27  Jim Meyering  <jim@meyering.net>
8745
8746         This file could end up with a definition for a function
8747         named __strndup, rather than rpl_strndup on a system with
8748         incomplete weak_alias support.
8749         * lib/strndup.c (strndup): Rename from __strndup.
8750         Remove #defines that used to map __strndup to strndup.
8751         Don't use K&R prototypes.
8752         Remove LIBC-related code, since this file is not sync'd with glibc.
8753         * lib/strndup.h: Revamp, accordingly.
8754         * m4/strndup.m4: Modernize.
8755
8756 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
8757
8758         * modules/savewd (Depends-on): Add 'raise'.
8759         * lib/savewd.c: Include <signal.h>, for 'raise'.
8760
8761 2006-09-26  Jim Meyering  <jim@meyering.net>
8762
8763         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
8764         when we detect Darwin 8.7.0's acl_get_file bug.
8765         Rearrange to perform the new (below) run-test while $LIBS
8766         contains any acl-related library.  Set USE_ACL at the end.
8767         (gl_ACL_GET_FILE): New function.
8768
8769 2006-09-26  Eric Blake  <ebb9@byu.net>
8770
8771         * lib/verror.c: Include <config.h> unconditionally.
8772
8773 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
8774
8775         * modules/clock-time (Maintainer): Add self.
8776         * modules/getlogin_r (Depends-on): Add extensions.
8777
8778 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8779
8780         * modules/clock-time: New module.
8781         * modules/nanosleep (Depends-on): Add clock-time.
8782         * modules/gethrxtime (Depends-on): Likewise.
8783         * modules/gettime (Depends-on): Likewise.
8784         * modules/settime (Depends-on): Likewise.
8785
8786         * modules/fts-lgpl: Depend on openat.
8787         * modules/mkancesdirs: Depend on savewd.
8788         * modules/mkdir-p: Likewise.
8789
8790 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8791
8792         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
8793
8794         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
8795         `gl_have_arbitrary_file_name_length_limit' to
8796         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
8797         actually works between configure runs.
8798
8799 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8800             Bruno Haible  <bruno@clisp.org>
8801
8802         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
8803
8804 2006-09-25  Jim Meyering  <jim@meyering.net>
8805
8806         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
8807         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
8808
8809 2006-09-25  Eric Blake  <ebb9@byu.net>
8810
8811         * gnulib-tool (func_import, func_create_testdir): Fix typos in
8812         exec's in 2006-09-18 patch when shuffling fds.
8813
8814 2006-09-25  Bruno Haible  <bruno@clisp.org>
8815
8816         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
8817         Reported by Jim Meyering.
8818
8819 2006-09-24  Jim Meyering  <jim@meyering.net>
8820
8821         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
8822         compare a pointer against a literal "0".  That caused failures with
8823         at least HP-UX's hpcc.
8824
8825 2006-09-22  Simon Josefsson  <jas@extundo.com>
8826
8827         * modules/gc-sha1:
8828         * modules/gc-md4:
8829         * modules/gc-hmac-sha1:
8830         * modules/gc-hmac-md5:
8831         * modules/gc-des:
8832         * modules/gc-arcfour: Distribute more files.
8833
8834 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8835
8836         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
8837         (gl_linked_iterator_from_to): Initialize struct completely.
8838         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
8839         (gl_tree_iterator_from_to): Likewise
8840         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
8841         * lib/gl_array_list.c [lint] (gl_array_iterator)
8842         (gl_array_iterator_from_to): Likewise.
8843         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
8844         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
8845         (gl_carray_iterator_from_to): Likewise.
8846
8847         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
8848         * lib/md4.c (md4_process_block): Remove unused variable.
8849         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
8850         parentheses for clarity.
8851
8852 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8853
8854         * modules/bison-i18n (Depends-on): Add gettext.
8855
8856 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8857
8858         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
8859         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
8860         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
8861         also add missing comma that caused broken test.
8862         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
8863         stdlib.h, for `abort'.
8864         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
8865         variables.
8866         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
8867         include unistd.h if present, for `rmdir'.
8868         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
8869         variables.
8870         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
8871         in the process include standard headers for prototypes.
8872         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
8873         gets declared on GNU/Linux.
8874         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
8875         unistd.h, for `rmdir'.
8876         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
8877
8878         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
8879         always true.
8880         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
8881
8882         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
8883
8884 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8885
8886         * gnulib-tool (func_version): Create output all at once.  This
8887         may help avoid triggering unnecessary SIGPIPEs, and at any
8888         rate it doesn't hurt.
8889
8890 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8891             Bruno Haible  <bruno@clisp.org>
8892
8893         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
8894         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
8895         * m4/signed.m4 (bh_C_SIGNED): Likewise.
8896
8897         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
8898         (gl_FUNC_VASPRINTF): Invoke it.
8899
8900 2006-09-22  Bruno Haible  <bruno@clisp.org>
8901
8902         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
8903         getloadavg.c as first argument.
8904
8905 2006-09-22  Bruno Haible  <bruno@clisp.org>
8906
8907         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
8908         at the beginning of the gl_INIT macro.
8909         * modules/getloadavg (configure.ac): Pass $gl_source_base to
8910         gl_GETLOADAVG.
8911
8912 2006-09-22  Bruno Haible  <bruno@clisp.org>
8913
8914         * gnulib-tool (func_create_megatestdir): Don't include the config-h
8915         module.
8916         Suggested by Ralf Wildenhues.
8917
8918 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
8919
8920         Import this patch from libc:
8921
8922         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
8923
8924         * lib/regex_internal.c (re_string_reconstruct): Handle
8925         offset < pstr->valid_raw_len && pstr->offsets_needed case.
8926         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
8927         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
8928         re_string_context_at.
8929
8930         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
8931         now requires it.
8932         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
8933         gl_REGEX now does it for us.
8934         (gl_REGEX): Add test taken from
8935         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
8936
8937         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
8938         Check that large offsets work.  Modernize Autoconf usages.
8939         Prefer "yes" to mean a good thing rather than a bad.
8940         Don't put "#define mkstemp" in config.h, as this might interfere
8941         with standard system headers that "#define mkstemp mkstemp64".
8942
8943         * modules/mkstemp (Depends-on): Add extensions, so that
8944         mkstemp is visible on some platforms.
8945         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
8946         (Include): Change to "mkstemp.h" from <stdlib.h>.
8947         (Files): Add mkstemp.h.
8948
8949         * lib/mkstemp.h: New file, since some standard headers
8950         #define mkstemp.
8951         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
8952         Include "mkstemp.h".
8953         Make the _LIBC code resemble glibc original more,
8954         e.g., use K&R style.
8955         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
8956         (mkstemp): Remove, since mkstemp.h does this for us.
8957         * lib/stdlib--.h: Include mkstemp.h.
8958
8959         Import this patch from libc:
8960
8961         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
8962
8963         * lib/tempname.c (__gen_tempname): Change attempts_min
8964         into a macro.  Use preprocessor to decide how to initialize
8965         attempts [Coverity CID 67].
8966
8967 2006-09-20  Bruno Haible  <bruno@clisp.org>
8968
8969         * lib/mkdtemp.c: Import from libc.
8970         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
8971                 * sysdeps/posix/tempname.c (__gen_tempname): Change
8972                 attempts_min into a macro.  Use preprocessor to decide how to
8973                 initialize attempts [Coverity CID 67].
8974         2001-11-27  Paul Eggert  <eggert@twinsun.com>
8975                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
8976                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
8977
8978 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8979
8980         * gnulib-tool (func_exit): New function, to allow to pass the
8981         exit status portably through the trap.  Use everywhere.
8982         (--help, --version): Signal a write error.
8983         (trap): catch SIGPIPE, for write errors.
8984         Exit at the end of the trap, with the correct exit status.
8985
8986 2006-09-19  Karl Berry  <karl@gnu.org>
8987
8988         * doc/gnulib.texi: note about the license texinfo files.
8989
8990 2006-09-19  Eric Blake  <ebb9@byu.net>
8991
8992         * gnulib-tool: Avoid space-tab.
8993
8994 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
8995
8996         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
8997         that prevented coreutils 6.1 from building.  Problem reported
8998         by Petter Reinholdtsen.
8999
9000 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
9001
9002         * gnulib-tool (avoidlist): Fix typo that broke options like
9003         --avoid=lock that are used by coreutils bootstrap.
9004
9005 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
9006
9007         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
9008         more systematically.
9009
9010 2006-09-18  Jim Meyering  <jim@meyering.net>
9011
9012         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
9013
9014 2006-09-18  Bruno Haible  <bruno@clisp.org>
9015
9016         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
9017
9018 2006-09-18  Bruno Haible  <bruno@clisp.org>
9019
9020         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
9021         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
9022         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
9023         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
9024         * m4/gettext.m4: Require autoconf >= 2.52.
9025         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
9026         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
9027         of gl_cv_header_inttypes_h.
9028
9029 2006-09-18  Bruno Haible  <bruno@clisp.org>
9030
9031         * lib/javaversion.c: Include configmake.h.
9032
9033 2006-09-18  Bruno Haible  <bruno@clisp.org>
9034
9035         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
9036         avoid that the while loops be executed in a subshell.
9037
9038 2006-09-18  Bruno Haible  <bruno@clisp.org>
9039
9040         * MODULES.html.sh (func_module): Break long lines.
9041         Suggested by Bruce Korb <bkorb@gnu.org>.
9042
9043 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9044
9045         Speed up by a factor of 1.12.
9046         * gnulib-tool (nl): New variable.
9047         (func_import): Rewrite include directive extraction to only read each
9048         directive once.
9049
9050 2006-09-17  Bruno Haible  <bruno@clisp.org>
9051
9052         * modules/javaversion (Makefile.am): Remove DEFS setting.
9053         (Depends-on): Add configmake, for PKGDATADIR definition.
9054
9055 2006-09-17  Bruno Haible  <bruno@clisp.org>
9056
9057         * gnulib-tool (func_create_testdir): Rewrite all files at once.
9058
9059 2006-09-17  Bruno Haible  <bruno@clisp.org>
9060
9061         * gnulib-tool (func_append): New function, stolen from libtool.m4.
9062         (func_modules_transitive_closure, func_modules_add_dummy,
9063         func_modules_to_filelist, func_import, func_create_testdir,
9064         func_create_megatestdir, ...): Use it wherever possible.
9065         Suggested by Ralf Wildenhues.
9066
9067 2006-09-16  Karl Berry  <karl@gnu.org>
9068
9069         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
9070         to avoid sectioning errors.
9071         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
9072         [ifinfo]: blank line after @center-ed titles.
9073         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
9074         Spell FSF address consistently with others.
9075         (These changes approved by rms.)
9076
9077 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9078
9079         Speed up by a factor of 1.61.
9080         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
9081         already checked module names again.
9082
9083 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9084
9085         Speed up by a factor of 1.13.
9086         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
9087         for new_files, and the input to func_add_or_update.
9088
9089 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9090
9091         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
9092         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
9093
9094 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
9095
9096         * modules/mkancesdirs (Depends-on): Add fcntl.
9097         * modules/savewd: New file.
9098         * MODULES.html.sh (File system functions): Add savewd.
9099
9100         * modules/configmake (Makefile.am): Add support for the
9101         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
9102
9103 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
9104
9105         * m4/savewd.m4: New file.
9106
9107 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
9108
9109         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
9110         (dirchownmod): New arg FD.  All callers changed.
9111         Use FD rather than opening the directory ourself, as opening is
9112         now the caller's responsibility.
9113         * lib/dirchownmod.h: Likewise.
9114         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
9115         hosts that require <sys/types.h> before <sys/stat.h>.  Include
9116         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
9117         (test_dir): Remove.
9118         (mkancesdirs): Return length of prefix of FILE that has already
9119         been made, or -2 if there is a child doing the work.  Redo
9120         algorithm so that it is O(N) rather than O(N**2).  Optimize away
9121         ".", and treat ".." specially since it might stray back into
9122         already-created areas.  Use a subprocess if necessary.  New arg
9123         WD; all users changed.  MAKE_DIR function should now return 1
9124         if it creates a directory that is not readable.  Return -2 if
9125         a child process is spun off.
9126         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
9127         Adjust signature to match code.
9128         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
9129         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
9130         all users changed.
9131         * lib/savewd.c, lib/savewd.h: New files.
9132
9133 2006-09-15  Jim Meyering  <jim@meyering.net>
9134
9135         * modules/rename-dest-slash: New module.
9136         * MODULES.html.sh (posix_compat): Add it here.
9137
9138         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
9139
9140 2006-09-15  Jim Meyering  <jim@meyering.net>
9141
9142         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
9143         file.
9144
9145         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
9146
9147 2006-09-15  Jim Meyering  <jim@meyering.net>
9148
9149         * lib/rename-dest-slash.c (has_trailing_slash): Use
9150         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
9151         (rpl_rename_dest_slash): Perform the cheaper trailing slash
9152         test before testing whether SRC is a directory.
9153         Suggestions from Bruno Haible.
9154
9155         Avoid a warning about an unused variable.
9156         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
9157         into the #ifdef block where it's used.
9158
9159         * lib/rename-dest-slash.c: New file.
9160
9161 2006-09-14  Bruno Haible  <bruno@clisp.org>
9162
9163         * lib/allocsa.c: Include <config.h> unconditionally.
9164         * lib/asnprintf.c: Likewise.
9165         * lib/asprintf.c: Likewise.
9166         * lib/c-strcasecmp.c: Likewise.
9167         * lib/c-strcasestr.c: Likewise.
9168         * lib/c-strncasecmp.c: Likewise.
9169         * lib/c-strstr.c: Likewise.
9170         * lib/classpath.c: Likewise.
9171         * lib/clean-temp.c: Likewise.
9172         * lib/concatpath.c: Likewise.
9173         * lib/copy-file.c: Likewise.
9174         * lib/csharpcomp.c: Likewise.
9175         * lib/csharpexec.c: Likewise.
9176         * lib/execute.c: Likewise.
9177         * lib/fatal-signal.c: Likewise.
9178         * lib/findprog.c: Likewise.
9179         * lib/fwriteerror.c: Likewise.
9180         * lib/gl_array_list.c: Likewise.
9181         * lib/gl_array_oset.c: Likewise.
9182         * lib/gl_avltree_list.c: Likewise.
9183         * lib/gl_avltree_oset.c: Likewise.
9184         * lib/gl_avltreehash_list.c: Likewise.
9185         * lib/gl_carray_list.c: Likewise.
9186         * lib/gl_linked_list.c: Likewise.
9187         * lib/gl_linkedhash_list.c: Likewise.
9188         * lib/gl_list.c: Likewise.
9189         * lib/gl_oset.c: Likewise.
9190         * lib/gl_rbtree_list.c: Likewise.
9191         * lib/gl_rbtree_oset.c: Likewise.
9192         * lib/gl_rbtreehash_list.c: Likewise.
9193         * lib/imaxabs.c: Likewise.
9194         * lib/imaxdiv.c: Likewise.
9195         * lib/javacomp.c: Likewise.
9196         * lib/javaexec.c: Likewise.
9197         * lib/javaversion.c: Likewise.
9198         * lib/linebreak.c: Likewise.
9199         * lib/localcharset.c: Likewise.
9200         * lib/lock.c: Likewise.
9201         * lib/mbchar.c: Likewise.
9202         * lib/mbswidth.c: Likewise.
9203         * lib/mkdtemp.c: Likewise.
9204         * lib/pipe.c: Likewise.
9205         * lib/printf-args.c: Likewise.
9206         * lib/printf-parse.c: Likewise.
9207         * lib/progname.c: Likewise.
9208         * lib/progreloc.c: Likewise.
9209         * lib/readlink.c: Likewise.
9210         * lib/sh-quote.c: Likewise.
9211         * lib/stpcpy.c: Likewise.
9212         * lib/stpncpy.c: Likewise.
9213         * lib/strcasecmp.c: Likewise.
9214         * lib/strcasestr.c: Likewise.
9215         * lib/strcspn.c: Likewise.
9216         * lib/striconv.c: Likewise.
9217         * lib/strncasecmp.c: Likewise.
9218         * lib/strnlen1.c: Likewise.
9219         * lib/strstr.c: Likewise.
9220         * lib/strtok_r.c: Likewise.
9221         * lib/tls.c: Likewise.
9222         * lib/tmpdir.c: Likewise.
9223         * lib/unicodeio.c: Likewise.
9224         * lib/unsetenv.c: Likewise.
9225         * lib/vasnprintf.c: Likewise.
9226         * lib/vasprintf.c: Likewise.
9227         * lib/wait-process.c: Likewise.
9228         * lib/xallocsa.c: Likewise.
9229         * lib/xsetenv.c: Likewise.
9230         * lib/xstriconv.c: Likewise.
9231
9232 2006-09-13  Simon Josefsson  <jas@extundo.com>
9233
9234         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
9235         that internally, suggested by Ralf Wildenhues
9236         <Ralf.Wildenhues@gmx.de>.
9237
9238 2006-09-13  Simon Josefsson  <jas@extundo.com>
9239
9240         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
9241         @LIBOBJS@.
9242         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
9243
9244 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
9245
9246         * lib/_fpending.c: Include <config.h> unconditionally, since we no
9247         longer worry about uses that don't define HAVE_CONFIG_H.
9248         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
9249         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
9250         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
9251         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
9252         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
9253         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
9254         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
9255         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
9256         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
9257         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
9258         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
9259         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
9260         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
9261         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
9262         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
9263         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
9264         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
9265         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
9266         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
9267         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
9268         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
9269         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
9270         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
9271         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
9272         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
9273         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
9274         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
9275         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
9276         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
9277         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
9278         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
9279         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
9280         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
9281         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
9282         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
9283         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
9284         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
9285         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
9286         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
9287         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
9288         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
9289         Likewise.
9290
9291 2006-09-13  Eric Blake  <ebb9@byu.net>
9292
9293         * lib/getopt.c: Fix typo in last commit.
9294
9295 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
9296
9297         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
9298         dgettext.
9299
9300 2006-09-12  Jim Meyering  <jim@meyering.net>
9301
9302         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
9303         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
9304         Reported by Nelson H. F. Beebe.
9305
9306 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
9307
9308         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
9309         program_invocation_name and program_invocation_short_name are
9310         initialized.
9311         * lib/argp-namefrob.h: Move declarations of program_invocation_name
9312         and program_invocation_short_name to argp.h, so they are visible
9313         to user programs.
9314         * lib/argp.h: Likewise
9315
9316 2006-09-10  Bruno Haible  <bruno@clisp.org>
9317
9318         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
9319         m4/inttypes_h.m4, m4/uintmax_t.m4.
9320
9321 2006-09-10  Bruno Haible  <bruno@clisp.org>
9322
9323         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
9324         gl_AC_TYPE_UINTMAX_T.
9325
9326 2006-09-10  Bruno Haible  <bruno@clisp.org>
9327
9328         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
9329
9330 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
9331
9332         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
9333         convention.  Text proposed by Bruno Haible.
9334         (struct argp_option): Document the use of N_() wrappers.
9335
9336         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
9337         '\v', and translate the two parts separately, instead of feeding
9338         the whole string to gettext.  This allows to exclude
9339         '\v' from the strings visible to the translator by writing doc
9340         strings as N_("..") "\v" N_("..").
9341
9342 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
9343
9344         * config/srclist.txt: Undo latest change; the bug was fixed.
9345
9346 2006-09-09  Bruno Haible  <bruno@clisp.org>
9347
9348         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
9349         assignments if building a library without libtool.
9350         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
9351         in func_emit_lib_Makefile_am.
9352         (func_import): When building a static library libfoo.a, arrange to
9353         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
9354         (func_create_testdir): Likewise.
9355         * modules/gc (configure.ac, Makefile.am): If building statically,
9356         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
9357         * modules/iconvme (configure.ac, Makefile.am): Likewise.
9358         * modules/striconv (configure.ac, Makefile.am): Likewise.
9359         Based on a suggestion by Ralf Wildenhues.
9360
9361 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
9362
9363         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
9364         Check for unistd.h too, since Autoconf doesn't assume POSIX.
9365         Also:
9366
9367         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
9368         Add year_2050_test to catch glibc bug 2821
9369         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
9370
9371         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9372         Prefer #ifdef to #if.
9373
9374         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
9375         Return from 'main' instead of calling 'exit'.
9376
9377 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
9378
9379         * lib/mktime.c (guess_time_tm): Fix bug where mktime
9380         returned the maximum time_t value rather than (time_t) -1.
9381         Problem originally reported by William Bardwell
9382         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
9383
9384         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
9385         Moved to here ...
9386         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
9387         ... from here.
9388
9389 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
9390
9391         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
9392         2821 is fixed.
9393
9394 2006-09-08  Jim Meyering  <jim@meyering.net>
9395
9396         Don't make generated files read-only.  That would bother too many
9397         people.  However, do retain the ability to work when targets are
9398         read-only: remove the destination and temporary files before writing
9399         them (when generated via sed or echo), or by using the -f option for
9400         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
9401         * modules/alloca-opt, modules/argz, modules/arpa_inet:
9402         * modules/byteswap, modules/configmake, modules/fcntl:
9403         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
9404         * modules/localcharset, modules/netinet_in, modules/poll:
9405         * modules/stdbool, modules/stdint, modules/sys_select:
9406         * modules/sys_socket, modules/sys_stat, modules/sysexits:
9407
9408 2006-09-08  Jim Meyering  <jim@meyering.net>
9409
9410         Avoid new build failure on FreeBSD 6.0.
9411         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
9412         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
9413         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
9414
9415 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9416
9417         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
9418
9419 2006-09-07  Jim Meyering  <jim@meyering.net>
9420
9421         Fix global typo in last change: use chmod u-w, not chmod u-x.
9422         Spotted by Paul Eggert and Bruce Korb.
9423         * modules/alloca-opt, modules/argz, modules/arpa_inet:
9424         * modules/byteswap, modules/configmake, modules/fcntl:
9425         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
9426         * modules/localcharset, modules/netinet_in, modules/poll:
9427         * modules/stdbool, modules/stdint, modules/sys_select:
9428         * modules/sys_socket, modules/sys_stat, modules/sysexits:
9429
9430 2006-09-06  Jim Meyering  <jim@meyering.net>
9431
9432         Make generated files be read-only.
9433         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
9434         Ensure that each generated file is now read-only.
9435         * modules/argz: Likewise.
9436         * modules/arpa_inet: Likewise.
9437         * modules/byteswap: Likewise.
9438         * modules/configmake: Likewise.
9439         * modules/fcntl: Likewise.
9440         * modules/fnmatch: Likewise.
9441         * modules/getopt: Likewise.
9442         * modules/glob: Likewise.
9443         * modules/inttypes: Likewise.
9444         * modules/netinet_in: Likewise.
9445         * modules/poll: Likewise.
9446         * modules/stdbool: Likewise.
9447         * modules/stdint: Likewise.
9448         * modules/sys_select: Likewise.
9449         * modules/sys_socket: Likewise.
9450         * modules/sys_stat: Likewise.
9451         * modules/sysexits: Likewise.
9452         * modules/localcharset: Same as above, but continue using temporary
9453         file named "t-$@" (why different?) rather than the "$@-t" used
9454         everywhere else.
9455
9456         * modules/sysexits (Makefile.am): Replace literal occurrences
9457         of "sysexit.h" more readable, and more consistent, "$@".
9458
9459 2006-09-06  Bruno Haible  <bruno@clisp.org>
9460
9461         * modules/striconv: New file.
9462         * modules/xstriconv: New file.
9463         * MODULES.html.sh (Internationalization functions): Add striconv,
9464         xstriconv.
9465
9466 2006-09-06  Bruno Haible  <bruno@clisp.org>
9467
9468         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
9469         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
9470         not using libtool correctly.
9471
9472 2006-09-06  Bruno Haible  <bruno@clisp.org>
9473
9474         * lib/striconv.h: New file.
9475         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
9476         iconvstring.c.
9477         * lib/xstriconv.h: New file.
9478         * lib/xstriconv.c: New file.
9479
9480 2006-09-06  Bruno Haible  <bruno@clisp.org>
9481
9482         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
9483         lib_..._LDFLAGS.
9484
9485 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9486
9487         * lib/argz_.h: Sync from Libtool.
9488
9489         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
9490                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
9491
9492         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
9493
9494 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
9495
9496         * modules/trim: New file.
9497
9498 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
9499
9500         * lib/trim.h: New file.
9501         * lib/trim.c: New file.
9502
9503 2006-09-05  Bruno Haible  <bruno@clisp.org>
9504
9505         * MODULES.html.sh (String handling): Add trim.
9506
9507 2006-09-04  Karl Berry  <karl@gnu.org>
9508
9509         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
9510         until next release.
9511
9512 2006-09-03  Bruno Haible  <bruno@clisp.org>
9513
9514         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
9515         correctly.
9516
9517 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9518
9519         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
9520         not gl_GETLOADAVG.  Omit unneeded semicolons.
9521         Problems reported by Ralf Wildenhues in
9522         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
9523         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
9524         at the end, which is the usual gnulib style.
9525
9526         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
9527         of doing all the work ourselves.
9528         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
9529         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
9530
9531 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9532
9533         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
9534         Problem reported by Ralf Wildenhues in
9535         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
9536
9537         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
9538         HAVE_STRUCT_STATFS_F_FSTYPENAME.
9539
9540 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
9541
9542         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
9543         yesterday's patch by changing test -n to test -z.
9544
9545 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9546
9547         * modules/getloadavg (Files): Add m4/getloadavg.m4.
9548         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
9549         the former is now obsolescent.
9550
9551         * modules/chdir-long (Depends-on): Add fcntl.
9552
9553 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9554
9555         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
9556         obsolescent, and programs should use gnulib instead.
9557         * m4/getloadavg.m4: New file, with contents taken from Autoconf
9558         but with prefixes changed.
9559
9560 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
9561
9562         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
9563         or stdbool.h, because they might not exist while configuring.
9564
9565         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
9566         Don't include unistd.h or limits.h; not needed, since chdir-long.h
9567         does that for us.
9568         (O_DIRECTORY): Remove.
9569
9570 2006-08-31  Eric Blake  <ebb9@byu.net>
9571
9572         * gnulib-tool: Don't let emacs change spaces to TAB.
9573
9574 2006-08-31  Bruno Haible  <bruno@clisp.org>
9575
9576         * gnulib-tool: When calling func_import more than once, do it in a
9577         subshell.
9578         Reported by Eric Blake <ebb9@byu.net>.
9579
9580 2006-08-31  Bruno Haible  <bruno@clisp.org>
9581
9582         * gnulib-tool (nl): Remove variable.
9583         (sed_transform_lib_file): Use more robust test for config-h module.
9584         (func_import): Fix typo in 2006-08-25 patch.
9585
9586 2006-08-31  Bruno Haible  <bruno@clisp.org>
9587
9588         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
9589         specified, augment Makefile.am variables instead of assigning them.
9590
9591 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9592
9593         Work around a bug in both the Linux and SunOS 64-bit kernels:
9594         nanosleep mishandles sleeps for longer than 2**31 seconds.
9595         Problem reported by Frank v Waveren in
9596         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
9597         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
9598         Check for nanosleep bug.
9599         (LIB_NANOSLEEP): Append clock_gettime library if needed.
9600
9601 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9602
9603         Work around a bug in both the Linux and SunOS 64-bit kernels:
9604         nanosleep mishandles sleeps for longer than 2**31 seconds.
9605         Problem reported by Frank v Waveren in
9606         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
9607         * lib/nanosleep.c (BILLION): New constant.
9608         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
9609         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
9610         implementation.
9611
9612 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9613
9614         * modules/nanosleep (Depends-on): Add gettime.
9615
9616 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
9617         and Simon Josefsson  <jas@extundo.com>
9618         and Oskar Liljeblad  <oskar@osk.mine.nu>
9619
9620         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
9621         * gnulib-tool (func_import): New license type 'unmodifiable license
9622         text'.
9623         * modules/fdl: Use it.  Longer description.
9624         * module/gpl, module/lgpl: New files.
9625
9626 2006-08-30  Jim Meyering  <jim@meyering.net>
9627
9628         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
9629         shadowing the parameter.
9630
9631 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9632
9633         Sync from Libtool:
9634
9635         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9636
9637         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
9638         sharing with gnulib.  Report by Eric Blake.
9639
9640 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9641
9642         * modules/isapipe: New file.
9643         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
9644
9645 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9646
9647         * modules/configmake (Makefile.am): Add a comment, and omit
9648         the CONFIGMAKE_ prefix from generated macro names.  Suggested
9649         by Bruno Haible.
9650
9651 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9652
9653         * m4/isapipe.m4: New file.
9654
9655 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
9656
9657         * lib/isapipe.c, lib/isapipe.h: New files.
9658
9659 2006-08-29  Jim Meyering  <jim@meyering.net>
9660
9661         * modules/configmake (Makefile.am): Make configmake.h depend on
9662         Makefile.  Otherwise, a stale configmake.h could hang around.
9663
9664 2006-08-29  Eric Blake  <ebb9@byu.net>
9665
9666         * lib/error.c (error_at_line, print_errno_message): Match libc, after
9667         resolution of upstream bug 3044.
9668
9669 2006-08-29  Bruno Haible  <bruno@clisp.org>
9670
9671         * modules/localcharset (Depends-on): Add configmake.
9672         (Makefile.am): Remove setting of LIBDIR through DEFS.
9673
9674 2006-08-29  Bruno Haible  <bruno@clisp.org>
9675
9676         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
9677         defined.
9678
9679 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9680
9681         * modules/fcntl: New file.
9682         * modules/chdir-safer (Depends-on): Add fcntl.
9683         * modules/fts: Likewise.
9684         * modules/mkdir-p: Likewise.
9685
9686         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
9687         This undoes the most recent change, since we're now addressing the
9688         problem in a different way.
9689
9690         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
9691         into output, since the output might be called Makefile.am even
9692         if $makefile_name is something different.
9693         (func_import): Use $makefile_am rather than
9694         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
9695         empty.
9696
9697         * modules/inttypes (Files): Add m4/inttypes-h.m4.
9698
9699 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9700
9701         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
9702         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
9703         recent change to stdint.m4, since we're now addressing the problem in a
9704         different way.
9705
9706 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9707
9708         * m4/fcntl_h.m4: New file.
9709
9710 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
9711
9712         * lib/fcntl_.h: New file.
9713         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
9714         the fcntl module.
9715         * lib/dirchownmod.c: Likewise.
9716         * lib/fts.c: Likewise.
9717
9718         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
9719         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
9720         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
9721         just before including <inttypes.h>, to avoid circular inclusion.
9722
9723 2006-08-28  Jim Meyering  <jim@meyering.net>
9724
9725         * doc/visibility.texi: Actually read and correct the grammar of the
9726         sentence affected by yesterday's change.
9727
9728 2006-08-28  Eric Blake  <ebb9@byu.net>
9729
9730         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
9731         needs wrapper.
9732
9733 2006-08-28  Eric Blake  <ebb9@byu.net>
9734
9735         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
9736
9737 2006-08-28  Eric Blake  <ebb9@byu.net>
9738
9739         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
9740
9741 2006-08-28  Bruno Haible  <bruno@clisp.org>
9742
9743         * modules/c-strstr: New file, from GNU gettext.
9744         * MODULES.html.sh (String handling): Add c-strstr.
9745
9746 2006-08-28  Bruno Haible  <bruno@clisp.org>
9747
9748         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
9749         macros.
9750         Reported by Eric Blake.
9751
9752 2006-08-28  Bruno Haible  <bruno@clisp.org>
9753
9754         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
9755         (VASNPRINTF): Return a string of length > INT_MAX without failing.
9756         * lib/vasprintf.c: Include errno.h, limits.h.
9757         (EOVERFLOW): New fallback definition.
9758         (vasprintf): Test here whether the string length is > INT_MAX.
9759         * lib/vsnprintf.c: Include errno.h, limits.h.
9760         (EOVERFLOW): New fallback definition.
9761         (vsnprintf): Fix bug when generated string was too long for the buffer.
9762         Test here whether the string length is > INT_MAX.
9763
9764 2006-08-28  Bruno Haible  <bruno@clisp.org>
9765
9766         * lib/inttypes_.h (SCNX*): Remove definitions.
9767         Reported by Eric Blake.
9768
9769 2006-08-28  Bruno Haible  <bruno@clisp.org>
9770
9771         * lib/c-strstr.h: New file, from GNU gettext.
9772         * lib/c-strstr.c: New file, from GNU gettext.
9773
9774 2006-08-28  Bruno Haible  <bruno@clisp.org>
9775
9776         * gnulib-tool: Reorder some statements.
9777
9778 2006-08-28  Bruno Haible  <bruno@clisp.org>
9779
9780         * gnulib-tool: New option --makefile-name.
9781         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
9782         $makefile_name.
9783         (func_import): Write $makefile_name to the cache file, and read it from
9784         there unless explicitly specified. Use $makefile_name as file name
9785         instead of Makefile.am. Adjust the recommendations accordingly.
9786
9787 2006-08-28  Bruno Haible  <bruno@clisp.org>
9788
9789         * gnulib-tool (func_verify_module): Check against misapplying patch.
9790
9791 2006-08-28  Bruno Haible  <bruno@clisp.org>
9792
9793         * gnulib-tool (func_relativize, func_relconcat): New functions.
9794         Give an error if --local-dir is given with --update.
9795         Remove trailing slashes from $local_gnulib_dir.
9796         (func_import): Store the relativized $local_gnulib_dir in
9797         gnulib-cache.m4, and read it from there if not specified explicitly.
9798
9799 2006-08-28  Bruno Haible  <bruno@clisp.org>
9800
9801         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
9802         is the current directory. Respect also $local_gnulib_dir.
9803
9804 2006-08-28  Bruno Haible  <bruno@clisp.org>
9805             Simon Josefsson  <jas@extundo.com>
9806
9807         BeOS portability.
9808         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
9809
9810 2006-08-27  Jim Meyering  <jim@meyering.net>
9811
9812         * doc/visibility.texi: Remove duplicate word: "pointer".
9813
9814 2006-08-26  Bruno Haible  <bruno@clisp.org>
9815
9816         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
9817         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
9818         (Makefile.am): Create inttypes.h from inttypes_.h.
9819         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
9820
9821         * modules/imaxabs: New file.
9822
9823         * modules/imaxdiv: New file.
9824
9825 2006-08-26  Bruno Haible  <bruno@clisp.org>
9826
9827         * m4/inttypes.m4: New file.
9828         * m4/_inttypes_h.m4: Remove file.
9829         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
9830         PRI_MACROS_BROKEN.
9831         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
9832
9833         * m4/imaxabs.m4: New file.
9834
9835         * m4/imaxdiv.m4: New file.
9836
9837 2006-08-26  Bruno Haible  <bruno@clisp.org>
9838
9839         * lib/inttypes_.h: New file.
9840         * lib/inttypes.h: Remove file.
9841         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
9842
9843         * lib/imaxabs.c: New file.
9844
9845         * lib/imaxdiv.c: New file.
9846
9847 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
9848
9849         New config-h module, so that "make" output needn't be cluttered
9850         by -DHAVE_CONFIG_H.
9851         * MODULES.html.sh (Support for building libraries and executables):
9852         Add config-h.
9853         * modules/config-h: New file.
9854         * gnulib-tool (nl, sed_transform_lib_file): New vars.
9855         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
9856         the config-h module is used.
9857
9858         New configmake module, so that "make" output needn't be cluttered
9859         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
9860         * MODULES.html.sh (Support for building libraries and executables):
9861         Add configmake.
9862         * modules/configmake: New file.
9863
9864 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
9865
9866         * m4/config-h.m4: New file.
9867
9868 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
9869
9870         * config/srclist.txt: Add elisp-comp.
9871
9872 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
9873
9874         * MODULES.html.sh (Support for building libraries and executables):
9875         Add elisp-comp.
9876         * build-aux/elisp-comp: New file.
9877         * modules/elisp-comp: New file.
9878
9879 2006-08-24  Bruno Haible  <bruno@clisp.org>
9880
9881         * gnulib-tool (func_create_testdir): Use non-default values of
9882         sourcebase and m4base.
9883
9884 2006-08-24  Bruno Haible  <bruno@clisp.org>
9885
9886         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
9887         HTML structure.
9888
9889 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
9890
9891         * modules/openat (Depends-on): Add lchown.
9892
9893 2006-08-23  Bruno Haible  <bruno@clisp.org>
9894
9895         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
9896         of gl_LOCK_EARLY instead of gl_LOCK.
9897
9898 2006-08-23  Bruno Haible  <bruno@clisp.org>
9899
9900         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
9901         on OSF/1 to no.
9902         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
9903
9904 2006-08-23  Bruno Haible  <bruno@clisp.org>
9905
9906         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
9907         as unusable.
9908
9909         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
9910         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
9911         (gl_LOCK): New macro.
9912
9913 2006-08-22  Simon Josefsson  <jas@extundo.com>
9914
9915         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
9916         to md5 module.
9917
9918 2006-08-22  Simon Josefsson  <jas@extundo.com>
9919
9920         * MODULES.html.sh: Add "Support for maintaining and release
9921         projects".
9922
9923         * build-aux/gnupload: New file, from coreutils.
9924
9925 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9926
9927         Avoid the need for AC_LIBSOURCES in m4 macros.
9928         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
9929         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
9930         * modules/check-version (EXTRA_DIST): Add check-version.h.
9931         * modules/crc (EXTRA_DIST): Add crc.h.
9932         * modules/des (EXTRA_DIST): Add des.h.
9933         * modules/gc (EXTRA_DIST): Add gc.h.
9934         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
9935         * modules/getline (EXTRA_DIST): Add getline.h.
9936         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
9937         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
9938         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
9939         * modules/md2 (EXTRA_DIST): Add md2.h.
9940         * modules/md4 (EXTRA_DIST): Add md4.h.
9941         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
9942         * modules/read-file (EXTRA_DIST): Add read-file.h.
9943         * modules/readline (EXTRA_DIST): Add readline.h.
9944         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
9945         rijndael-api-fst.h.
9946
9947 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9948
9949         * m4/rijndael.m4 (gl_ARCFOUR):
9950         * m4/arctwo.m4 (gl_ARCTWO):
9951         * m4/check-version.m4 (gl_CHECK_VERSION):
9952         * m4/crc.m4 (gl_CRC):
9953         * m4/des.m4 (gl_DES):
9954         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
9955         * m4/gc.m4 (gl_GC):
9956         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
9957         * m4/getline.m4 (gl_FUNC_GETLINE):
9958         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
9959         * m4/hmac-md5.m4 (gl_HMAC_MD5):
9960         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
9961         * m4/md2.m4 (gl_MD2):
9962         * m4/md4.m4 (gl_MD4):
9963         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
9964         * m4/read-file.m4 (gl_FUNC_READ_FILE):
9965         * m4/readline.m4 (gl_FUNC_READLINE):
9966         * m4/rijndael.m4 (gl_RIJNDAEL):
9967         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
9968         to get the necessary .h files and whatnot.
9969
9970 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
9971
9972         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
9973         gnulib rather than the other way around.
9974         * config/srclistvars.sh (COREUTILS): Remove.
9975
9976 2006-08-22  Jim Meyering  <jim@meyering.net>
9977
9978         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
9979
9980         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
9981
9982 2006-08-22  Eric Blake  <ebb9@byu.net>
9983
9984         * modules/regexprops-generic: New file.
9985         * MODULES.html.sh (Support for building documentation): List it.
9986
9987 2006-08-22  Eric Blake  <ebb9@byu.net>
9988
9989         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
9990         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
9991         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
9992         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
9993
9994 2006-08-22  Bruno Haible  <bruno@clisp.org>
9995
9996         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
9997         and lib_LTLIBRARIES like the other lib_* variables.
9998
9999 2006-08-22  Bruno Haible  <bruno@clisp.org>
10000
10001         * build-aux/x-to-1.in: New file, from GNU gettext.
10002
10003 2006-08-22  Bruno Haible  <bruno@clisp.org>
10004
10005         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
10006         <utmpx.h> exists.
10007
10008 2006-08-22  Bruno Haible  <bruno@clisp.org>
10009
10010         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
10011         <utmpx.h> exists.
10012
10013 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
10014
10015         BeOS portability.
10016         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
10017         exist.
10018         Problem reported by Bruno Haible.
10019
10020 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
10021
10022         Avoid the need for AC_LIBSOURCES in m4 macros.
10023         * modules/acl (EXTRA_DIST): Add acl.h.
10024         * modules/argmatch (Files): Add m4/argmatch.m4.
10025         (configure.ac): Add gl_ARGMATCH.
10026         (EXTRA_DIST): Renamed from lib_SOURCES, for
10027         consistency with the other modules.  Remove argmatch.c.
10028         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
10029         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
10030         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
10031         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
10032         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
10033         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
10034         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
10035         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
10036         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
10037         * modules/closeout (EXTRA_DIST): Add closeout.h.
10038         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
10039         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
10040         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
10041         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
10042         dirname.h; remove basename.c and stripslash.c.
10043         * modules/exclude (EXTRA_DIST): Add exclude.h.
10044         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
10045         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
10046         * modules/file-type (EXTRA_DIST): Add file-type.h.
10047         * modules/filemode (EXTRA_DIST): Add filemode.h.
10048         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
10049         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
10050         * modules/fpending (EXTRA_DIST): Add __fpending.h.
10051         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
10052         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
10053         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
10054         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
10055         * modules/getdate (EXTRA_DIST): Add getdate.c.
10056         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
10057         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
10058         * modules/getpass (EXTRA_DIST): Add getpass.h.
10059         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
10060         * modules/group-member (EXTRA_DIST): Add group-member.h.
10061         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
10062         * modules/hash (EXTRA_DIST): Add hash.h.
10063         * modules/human (EXTRA_DIST): Add human.h.
10064         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
10065         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
10066         * modules/lchown (EXTRA_DIST): Add lchown.h.
10067         * modules/long-options (EXTRA_DIST): Add long-options.h.
10068         * modules/lstat (EXTRA_DIST): Add lstat.h.
10069         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
10070         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
10071         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
10072         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
10073         * modules/memxor (EXTRA_DIST): Add memxor.h.
10074         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
10075         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
10076         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
10077         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
10078         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
10079         * modules/physmem (EXTRA_DIST): Add physmem.h.
10080         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
10081         * modules/posixver (EXTRA_DIST): Add posixver.h.
10082         * modules/quote (EXTRA_DIST): Add quote.h.
10083         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
10084         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
10085         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
10086         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
10087         regex_internal.h regexec.c.
10088         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
10089         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
10090         * modules/same (EXTRA_DIST): Add same.h.
10091         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
10092         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
10093         * modules/savedir (EXTRA_DIST): Add savedir.h.
10094         * modules/sha1 (EXTRA_DIST): Add sha1.h.
10095         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
10096         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
10097         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
10098         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
10099         * modules/strdup (EXTRA_DIST): Add strdup.h.
10100         * modules/strftime (EXTRA_DIST): Add strftime.h.
10101         * modules/strndup (EXTRA_DIST): Add strndup.h.
10102         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
10103         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
10104         * modules/time_r (EXTRA_DIST): Add time_r.h.
10105         * modules/timespec (EXTRA_DIST): Add timespec.h.
10106         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
10107         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
10108         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
10109         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
10110         * modules/userspec (EXTRA_DIST): Add userspec.h.
10111         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
10112         * modules/utimens (EXTRA_DIST): Add utimens.h.
10113         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
10114         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
10115         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
10116         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
10117         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
10118         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
10119         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
10120         * modules/yesno (EXTRA_DIST): Add yesno.h.
10121
10122 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
10123
10124         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
10125
10126         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
10127         * m4/dev-ino.m4, same-inode.m4: Remove.
10128
10129         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
10130         * m4/acl.m4 (AC_FUNC_ACL):
10131         * m4/backupfile.m4 (gl_BACKUPFILE):
10132         * m4/c-strtod.m4 (gl_C99_STRTOLD):
10133         * m4/canon-host.m4 (gl_CANON_HOST):
10134         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
10135         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
10136         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
10137         * m4/cloexec.m4 (gl_CLOEXEC):
10138         * m4/close-stream.m4 (gl_CLOSE_STREAM):
10139         * m4/closeout.m4 (gl_CLOSEOUT):
10140         * m4/dirfd.m4 (gl_FUNC_DIRFD):
10141         * m4/dirname.m4 (gl_DIRNAME):
10142         * m4/exclude.m4 (gl_EXCLUDE):
10143         * m4/exitfail.m4 (gl_EXITFAIL):
10144         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
10145         * m4/file-type.m4 (gl_FILE_TYPE):
10146         * m4/filemode.m4 (gl_FILEMODE):
10147         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
10148         * m4/fpending.m4 (gl_FUNC_FPENDING):
10149         * m4/fprintftime.m4 (gl_FPRINTFTIME):
10150         * m4/fts.m4 (gl_FUNC_FTS):
10151         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
10152         * m4/getdate.m4 (gl_GETDATE):
10153         * m4/gethrxtime.m4 (gl_GETHRXTIME):
10154         * m4/getpagesize.m4 (gl_GETPAGESIZE):
10155         * m4/getpass.m4 (gl_FUNC_GETPASS):
10156         * m4/gettime.m4 (gl_GETTIME):
10157         * m4/getugroups.m4 (gl_GETUGROUPS):
10158         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
10159         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
10160         * m4/hard-locale.m4 (gl_HARD_LOCALE):
10161         * m4/hash.m4 (gl_HASH):
10162         * m4/idcache.m4 (gl_IDCACHE):
10163         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
10164         * m4/lchown.m4 (gl_FUNC_LCHOWN):
10165         * m4/long-options.m4 (gl_LONG_OPTIONS):
10166         * m4/lstat.m4 (gl_FUNC_LSTAT):
10167         * m4/md5.m4 (gl_MD5):
10168         * m4/memcasecmp.m4 (gl_MEMCASECMP):
10169         * m4/memcoll.m4 (gl_MEMCOLL):
10170         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
10171         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
10172         * m4/memxor.m4 (gl_MEMXOR):
10173         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
10174         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
10175         * m4/modechange.m4 (gl_MODECHANGE):
10176         * m4/mountlist.m4 (gl_MOUNTLIST):
10177         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
10178         * m4/openat.m4 (gl_FUNC_OPENAT):
10179         * m4/pathmax.m4 (gl_PATHMAX):
10180         * m4/physmem.m4 (gl_PHYSMEM):
10181         * m4/posixtm.m4 (gl_POSIXTM):
10182         * m4/posixver.m4 (gl_POSIXVER):
10183         * m4/quote.m4 (gl_QUOTE):
10184         * m4/quotearg.m4 (gl_QUOTEARG):
10185         * m4/readtokens.m4 (gl_READTOKENS):
10186         * m4/readutmp.m4 (gl_READUTMP):
10187         * m4/regex.m4 (gl_REGEX):
10188         * m4/safe-read.m4 (gl_SAFE_READ):
10189         * m4/safe-write.m4 (gl_SAFE_WRITE):
10190         * m4/same.m4 (gl_SAME):
10191         * m4/save-cwd.m4 (gl_SAVE_CWD):
10192         * m4/savedir.m4 (gl_SAVEDIR):
10193         * m4/settime.m4 (gl_SETTIME):
10194         * m4/sha1.m4 (gl_SHA1):
10195         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
10196         * m4/stat-macros.m4 (gl_STAT_MACROS):
10197         * m4/stat-time.m4 (gl_STAT_TIME):
10198         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
10199         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
10200         * m4/strdup.m4 (gl_FUNC_STRDUP):
10201         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
10202         * m4/strndup.m4 (gl_FUNC_STRNDUP):
10203         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
10204         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
10205         * m4/time_r.m4 (gl_TIME_R):
10206         * m4/timespec.m4 (gl_TIMESPEC):
10207         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
10208         * m4/unlinkdir.m4 (gl_UNLINKDIR):
10209         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
10210         * m4/userspec.m4 (gl_USERSPEC):
10211         * m4/utimecmp.m4 (gl_UTIMECMP):
10212         * m4/utimens.m4 (gl_UTIMENS):
10213         * m4/xalloc.m4 (gl_XALLOC):
10214         * m4/xgetcwd.m4 (gl_XGETCWD):
10215         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
10216         * m4/xreadlink.m4 (gl_XREADLINK):
10217         * m4/xstrtod.m4 (gl_XSTRTOD):
10218         * m4/yesno.m4 (gl_YESNO):
10219         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
10220         to get the necessary .h files and whatnot.
10221
10222 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
10223             Bruno Haible  <bruno@clisp.org>
10224
10225         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
10226         /bin/sh understanding of '!' conditional negation.
10227
10228 2006-08-21  Jim Meyering  <jim@meyering.net>
10229
10230         * modules/openat (Depends-on): Really alphabetize.
10231
10232         * modules/acl (Depends-on): Add error and quote.
10233
10234         * check-module (find_included_lib_files): Add at-func.c to the
10235         ok-to-include-more-than-once white list.
10236
10237         * modules/openat (Depends-on): Add lstat.  Alphabetize.
10238
10239 2006-08-21  Bruno Haible  <bruno@clisp.org>
10240
10241         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10242         Emit a pkgdata_DATA variable only if some snippets add contents to it.
10243         Reported by Martin Lambers <marlam@marlam.de>.
10244
10245 2006-08-21  Bruno Haible  <bruno@clisp.org>
10246
10247         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
10248         specify an installation location, don't emit a noinst_LIBRARIES or
10249         noinst_LTLIBRARIES assignment.
10250
10251 2006-08-21  Bruno Haible  <bruno@clisp.org>
10252
10253         BeOS portability.
10254         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
10255         BeOS has mbrtowc() but no <wctype.h>.
10256
10257 2006-08-21  Bruno Haible  <bruno@clisp.org>
10258
10259         BeOS portability.
10260         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
10261         exist.
10262
10263 2006-08-21  Bruno Haible  <bruno@clisp.org>
10264
10265         BeOS portability.
10266         * lib/mbchar.h: Include <wctype.h> only if it exists.
10267
10268 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
10269
10270         Remove files that are no longer needed by their respective modules.
10271         * m4/obstack.m4: Remove.
10272         * m4/strerror_r.m4: Remove.
10273         * m4/uint32_t.m4: Remove.
10274         * m4/uintptr_t.m4: Remove.
10275         * m4/ullong_max.m4: Remove.
10276         * m4/xstrtoimax.m4: Remove.
10277         * m4/xstrtoumax.m4: Remove.
10278
10279         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
10280         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
10281         dependencies now capture this.
10282
10283         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
10284         Do not use AC_LIBSOURCES, since gnulib modules now do this.
10285         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
10286         * m4/human.m4 (gl_HUMAN): Likewise.
10287         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
10288         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
10289
10290         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
10291
10292         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
10293         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
10294         stdint.
10295         * m4/human.m4 (gl_HUMAN): Likewise.
10296         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
10297         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
10298         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
10299         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
10300         * m4/xstrtol (gl_XSTRTOL): Likewise.
10301
10302         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
10303         AC_TYPE_LONG_LONG_INT.
10304         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
10305         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
10306         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
10307         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
10308
10309         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
10310         on stdbool.
10311
10312         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
10313         (gl_PREREQ_XSTRTOUL): Remove.
10314
10315         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
10316
10317         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
10318         mode.
10319
10320 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
10321
10322         Add and change modules to make it easier for coreutils to use
10323         gnulib-tool.
10324         * modules/backupfile (Files): Remove m4/d-ino.m4.
10325         (Depends-on): Add d-ino.
10326         * modules/cycle-check (Depends-on): Add stdint.
10327         (lib_SOURCES): Add cycle-check.h.
10328         * modules/d-ino: New module.
10329         * modules/d-type: New module.
10330         * modules/error (Files): Remove m4/strerror_r.m4.
10331         * modules/filemode (Files): Add m4/st_dm_mode.m4.
10332         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
10333         m4/inttypes_h.m4, m4/uintmax_t.m4.
10334         (Depends-on): Add stdint.
10335         (lib_SOURCES): Add fsusage.h.
10336         * modules/getcwd (Files): Remove d-ino.m4.
10337         (Depends-on): Add d-ino.
10338         * modules/getndelim2 (Depends-on): Add stdint.
10339         * modules/glob (Files): Remove m4/d-type.m4.
10340         (Depends-on): Add d-type.
10341         * modules/host-os: New module.
10342         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
10343         m4/inttypes_h.m4, m4/uintmax_t.m4.
10344         * Depends-on: Add stdint.
10345         (lib_SOURCES): Add human.h.
10346         * modules/inttostr (Files): Remove m4/intmax_t.m4,
10347         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
10348         m4/uintmax_t.m4, m4/ulonglong.m4.
10349         (Depends-on): Add stdint.
10350         (EXTRA_DIST): Add inttostr.h.
10351         * modules/lchmod: New module.
10352         * modules/link-follow: New module.
10353         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
10354         (Depends-on): Add lchmod.
10355         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
10356         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
10357         (Depends-on): Add stdint.
10358         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
10359         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
10360         (Depends-on): Add stdint.
10361         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
10362         * modules/perl: New module.
10363         * modules/regex (Depends-on): Add stdint.
10364         * modules/rmdir-errno: New module.
10365         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
10366         m4/intmax_t.m4.
10367         (Depends-on): Add stdint.
10368         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
10369         m4/uintmax_t.m4.
10370         (Depends-on): Add stdint.
10371         * modules/unlink-busy: New module.
10372         * modules/utimecmp (Depends-on): Add stdint.
10373         * modules/uptime: New module.
10374         * modules/winsz-ioctl: New module.
10375         * modules/winsz-termios: New module.
10376         * modules/xnanosleep (Depends-on): Add nanosleep.
10377         * modules/ullong_max: Remove.
10378         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
10379         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
10380         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
10381         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
10382         (Depends-on): Add inttypes.
10383         (lib_SOURCES): Add xstrtol.h.
10384         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
10385         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
10386         * MODULES.html.sh: Move 'assert' into the assert section.
10387         Move 'dummy' into the linking section.
10388         Remove ullong_max.
10389         Add section for compatibility checks for POSIX:2001 functions,
10390         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
10391         winsz-ioctl, and winsz-termios into it.
10392         Add lchmod.
10393         Add top-level Misc section and put host-os, perl, and uptime
10394         into it.
10395
10396 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
10397
10398         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
10399         now assume the stdint module.  Do not include inttypes.h.
10400         * lib/fsusage.h: Likewise.
10401         * lib/getndelim2.c: Likewise.
10402         * lib/human.h: Likewise.
10403         * lib/inttostr.h: Likewise.
10404         * lib/obstack.c: Likewise.
10405         * lib/regex_internal.h: Likewise.
10406         * lib/tempname.c: Likewise.
10407         * lib/utimecmp.c: Likewise.
10408         * lib/xstrtol.h: Likewise.
10409
10410         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
10411
10412         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
10413         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
10414         * lib/xtime.h: Likewise.
10415
10416 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
10417
10418         * modules/openat (Files): Add lib/fchmodat.c.
10419         Fixes problem reported by Jay Youngman.
10420
10421 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
10422
10423         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
10424         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
10425
10426 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
10427             Bruno Haible  <bruno@clisp.org>
10428
10429         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
10430         and is a script that invokes bison. Tighten the code. Add comments.
10431
10432 2006-08-18  Jim Meyering  <jim@meyering.net>
10433
10434         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
10435         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
10436         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
10437         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
10438
10439 2006-08-18  Bruno Haible  <bruno@clisp.org>
10440
10441         * modules/bison-i18n: New file.
10442         * MODULES.html.sh (Internationalization functions): Add it.
10443
10444 2006-08-18  Bruno Haible  <bruno@clisp.org>
10445
10446         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
10447         sys/statvfs.h. When getmntinfo was found, check its declaration and
10448         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
10449
10450 2006-08-18  Bruno Haible  <bruno@clisp.org>
10451
10452         * m4/bison-i18n.m4: New file, from bison.
10453
10454 2006-08-18  Bruno Haible  <bruno@clisp.org>
10455
10456         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
10457         (ME_DUMMY): Treat "kernfs" as a dummy.
10458         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
10459
10460 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
10461
10462         Update from coreutils.
10463
10464         2006-08-15  Jim Meyering  <jim@meyering.net>
10465
10466         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
10467
10468         2006-01-17  Jim Meyering  <jim@meyering.net>
10469
10470         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
10471
10472         2006-01-11  Jim Meyering  <jim@meyering.net>
10473
10474         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
10475         Check for the lchmod function.
10476
10477 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
10478
10479         Update from coreutils.
10480
10481         * lib/__fpending.h: Add copyright notice.
10482         * lib/fprintftime.h: Likewise.
10483         * lib/savedir.c: Use (C) in copyright notice.
10484         * lib/savedir.h: Likewise.
10485
10486         2006-08-15  Jim Meyering  <jim@meyering.net>
10487
10488         * lib/at-func.c: New file, with the logic of all emulated at-functions.
10489         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
10490         in support of the EXPECTED_ERRNO macro.
10491         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
10492         definitions.  Instead, define the appropriate symbols and include
10493         "at-func.c".
10494         * lib/mkdirat.c (mkdirat): Likewise.
10495         * lib/fchmodat.c (fchmodat): Likewise.
10496         (ENOSYS): Remove definition.
10497         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
10498         it.  Don't include "unistd--.h" -- it wasn't ever used.
10499
10500         2006-01-17  Jim Meyering  <jim@meyering.net>
10501
10502         Rewrite fts.c not to change the current working directory,
10503         by using openat, fstatat, fdopendir, etc..
10504
10505         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
10506         (HAVE_OPENAT_SUPPORT): Define.
10507         [_LIBC] (fchdir): Don't undef or define; no longer used.
10508         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
10509         Now, this `function' always succeeds, and consumes its file descriptor
10510         parameter -- so callers must not close such FDs.  Update callers.
10511         (diropen_fd, opendirat, cwd_advance_fd): New functions.
10512         (diropen): Add parameter, SP.  Adjust all callers.
10513         Implement using diropen_fd, rather than open.
10514         (fts_open): Initialize new member, fts_cwd_fd.
10515         Remove fts_rft-setting code.
10516         (fts_close): Close fts_cwd_fd, if necessary.
10517         (__opendir2): Define in terms of opendir or opendirat,
10518         depending on whether the FST_NOCHDIR flag is set.
10519         (fts_build): Since fts_safe_changedir consumes its FD, and since
10520         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
10521         and close the dup'd file descriptor upon failure.
10522         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
10523         (fts_safe_changedir): Tweak semantics to reflect that this function
10524         now calls cwd_advance_fd and hence consumes its FD argument.
10525         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
10526         [struct FTS] (fts_rft): Remove now-unused member.
10527         [struct FTS] (fts_cycle.state): Improve comment.
10528
10529         * lib/openat.c (openat_needs_fchdir): New function.
10530         * lib/openat.h (openat_needs_fchdir): Declare it.
10531
10532 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
10533
10534         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
10535         Problem and fix reported by Pádraig Brady in
10536         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
10537
10538 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10539
10540         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
10541
10542 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10543
10544         * lib/memcoll.c (memcoll): Optimize for the common case where the
10545         arguments are bytewise equal.
10546
10547 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
10548
10549         * doc/regexprops-generic.texi: Add a copyright notice.
10550
10551 2006-08-15  Bruno Haible  <bruno@clisp.org>
10552
10553         * modules/tmpdir (License): Change to LGPL.
10554
10555 2006-08-15  Bruno Haible  <bruno@clisp.org>
10556
10557         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
10558         module.
10559
10560 2006-08-14  Simon Josefsson  <jas@extundo.com>
10561
10562         * config/srclist.txt: Add gnupload.
10563
10564 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10565
10566         Change copyright notice from LGPL 2 to GPL 2, since that's the
10567         standard form used in the gnulib repository.
10568         * tests/test-lock.c: Likewise.
10569         * tests/test-stdint.c: Likewise.
10570         * tests/test-tls.c: Likewise.
10571
10572         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
10573         prelude-manager.  User shorter URLs for GNU projects, without '?'.
10574         Add copyright notice.
10575
10576         * check-module: Add copyright notice.  Output a copyright
10577         notice if "--version" is specified.
10578         * modules/COPYING: New file.
10579         * tests/test-getaddrinfo.c: Add copyright notice.
10580         * tests/test-verify.c: Likewise.
10581
10582 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10583
10584         Change copyright notice from LGPL 2 to GPL 2, since that's the
10585         standard form used in the gnulib repository.
10586         * lib/lock.c: LGPL -> GPL.
10587         * lib/lock.h: Likewise.
10588         * lib/strnlen1.c: Likewise.
10589         * lib/strnlen1.h: Likewise.
10590         * lib/tls.c: Likewise.
10591         * lib/tls.h: Likewise.
10592         * lib/tmpdir.c: Likewise.
10593
10594         * lib/TODO: Remove; this belongs only in coreutils.
10595
10596 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10597
10598         Add copyright notices to long-enough files that lack them, since
10599         otherwise the files aren't clearly free.  Use the same notice that
10600         getdate.texi already uses.
10601         * doc/alloca-opt.texi: Add copyright notice.
10602         * doc/alloca.texi: Likewise.
10603         * doc/ctime.texi: Likewise.
10604         * doc/functions.texi: Likewise.
10605         * doc/gcd.texi: Likewise.
10606         * doc/gnulib-tool.texi: Likewise.
10607         * doc/inet_ntoa.texi: Likewise.
10608         * doc/visibility.texi: Likewise.
10609
10610         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
10611         * doc/quote.texi: Add copyright notice.
10612
10613         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
10614         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
10615         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
10616         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
10617         is now obsolete, and give a pointer to the Sun list.
10618         Add copyright notice.
10619
10620 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
10621
10622         * config/srclistvars.sh: Add copyright notice.
10623
10624 2006-08-14  Eric Blake  <ebb9@byu.net>
10625
10626         Import the following change from libc:
10627
10628         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
10629
10630         Upstream bug 2997.
10631         * lib/misc/error.c: Add space between program name and message if file
10632         name is missing.
10633
10634 2006-08-12  Karl Berry  <karl@gnu.org>
10635
10636         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
10637         remove, these originate in gnulib now.
10638
10639 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10640
10641         * doc/Makefile (standards.info standards.html standards.dvi):
10642         Also depend on make-stds.texi.
10643
10644 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
10645
10646         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
10647         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
10648
10649         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
10650         in wchar_t.  Problem reported by Eric Blake.
10651
10652         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
10653         LEN is smaller than SIZE.  Suggested by Bruno Haible.
10654         Also, help the compiler to keep LEN in a register.
10655
10656 2006-08-11  Eric Blake  <ebb9@byu.net>
10657
10658         * users.txt: Sort.  Add tar.
10659
10660 2006-08-11  Bruno Haible  <bruno@clisp.org>
10661
10662         * users.txt: New file.
10663
10664 2006-08-11  Bruno Haible  <bruno@clisp.org>
10665
10666         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
10667         before <wchar.h>. Needed for OSF/1 and BSD/OS.
10668
10669 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
10670
10671         * modules/snprintf (Depends-on): Remove minmax.
10672         (Maintainer): Add self and Bruno.
10673
10674 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
10675
10676         * lib/.cppi-disable: Add snprintf.h, socket_.h.
10677         * lib/snprintf.c: Include <errno.h> and <limits.h>.
10678         (EOVERFLOW): Define if the system does not.
10679         Do not include "minmax.h"; it wasn't used.
10680         (snprintf): Don't assume size_t promotes to an unsigned type.
10681         Fix bug when generated string was too long for the buffer: the
10682         buffer's contents are supposed to be the initial prefix of the
10683         output.  Don't assume vasnprintf returns EOVERFLOW if the size
10684         exceeds INT_MAX; do the check ourselves.
10685
10686         Import the following changes from libc:
10687
10688         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
10689
10690         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
10691         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
10692         set wc to the byte which couldn't be converted.
10693         (re_string_reconstruct): Don't clear valid_raw_len before calling
10694         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
10695         tip_context using re_string_context_at.
10696
10697         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
10698
10699         * lib/posix/regex.h: g++ still cannot handled [restrict].
10700
10701         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
10702
10703         * lib/posix/regex.h: Remove special handling for VMS.
10704
10705 2006-08-10  Jim Meyering  <jim@meyering.net>
10706
10707         * modules/same-inode: New module.
10708         * modules/dev-ino: New module.
10709         * modules/cycle-check: Depend on these modules, rather than simply
10710         including their .h files.
10711         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
10712         required via m4/cycle-check.m4.
10713         * modules/same: Depend on new same-inode module, rather than
10714         including same-inode.h.
10715         * modules/chdir-safer: New file.
10716
10717         * modules/chown (Depends-on): Add stat-macros.
10718
10719 2006-08-10  Jim Meyering  <jim@meyering.net>
10720
10721         * m4/cycle-check.m4: New file.
10722         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
10723         * m4/dev-ino.m4, m4/same-inode.m4: New files.
10724
10725 2006-08-10  Eric Blake  <ebb9@byu.net>
10726
10727         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
10728         in from original proposal.
10729
10730 2006-08-10  Eric Blake  <ebb9@byu.net>
10731         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
10732
10733         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
10734         namespace.
10735
10736 2006-08-10  Bruno Haible  <bruno@clisp.org>
10737
10738         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
10739         as well.
10740
10741 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10742
10743         Sync from coreutils.
10744
10745         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
10746
10747         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
10748         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
10749
10750 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10751
10752         * modules/restrict: Remove; no longer needed now that we assume
10753         Autoconf 2.59 or later.
10754         * MODULES.html.sh: Remove 'restrict'.
10755         * modules/argp (Depends-on): Remove 'restrict'.
10756         * modules/base64 (Depends-on): Likewise.
10757         * modules/gc (Depends-on): Likewise.
10758         * modules/getaddrinfo (Depends-on): Likewise.
10759         * modules/glob (Depends-on): Likewise.
10760         * modules/inet_ntop (Depends-on): Likewise.
10761         * modules/inet_pton (Depends-on): Likewise.
10762         * modules/memxor (Depends-on): Likewise.
10763         * modules/regex (Depends-on): Likewise.
10764         * modules/strtok_r (Depends-on): Likewise.
10765         * modules/time_r (Depends-on): Likewise.
10766
10767 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
10768
10769         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
10770         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
10771         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
10772         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
10773         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
10774         * m4/memxor.m4 (gl_MEMXOR): Likewise.
10775         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
10776         gl_C_RESTRICT replaced by AC_C_RESTRICT.
10777
10778         Merge from coreutils.
10779         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
10780         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
10781         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
10782         * m4/time_r.m4 (gl_TIME_R): Likewise.
10783
10784 2006-08-09  Karl Berry  <karl@gnu.org>
10785
10786         * config/srclist.txt: no more gettext-tools, per Bruno.
10787
10788 2006-08-08  Eric Blake  <ebb9@byu.net>
10789
10790         * modules/verror: New module.
10791         * MODULES.html.sh: Document it.
10792
10793 2006-08-08  Eric Blake  <ebb9@byu.net>
10794
10795         * lib/verror.h, lib/verror.c: New files.
10796
10797 2006-08-08  Eric Blake  <ebb9@byu.net>
10798
10799         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
10800         verror_at_line output complies with GNU Coding Standards even when
10801         file is NULL.
10802
10803 2006-08-07  Bruno Haible  <bruno@clisp.org>
10804
10805         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
10806         versions of AIX.
10807         Reported by Ralf Wildenhues.
10808
10809 2006-08-07  Bruno Haible  <bruno@clisp.org>
10810
10811         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
10812         in an AC_DEFUN. Needed so that the autoconf snippets can use
10813         AC_REQUIRE.
10814
10815 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10816
10817         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10818         Initialize pkgdata_DATA.
10819         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
10820         overriding it.
10821
10822 2006-08-06  Eric Blake  <ebb9@byu.net>
10823
10824         * lib/error.h: Fold in some upstream changes from glibc.
10825         * lib/error.c: Likewise.
10826
10827 2006-08-04  Bruno Haible  <bruno@clisp.org>
10828
10829         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10830         Make the mostlyclean-local rule depend on mostlyclean-generic.
10831         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
10832
10833 2006-07-31  Bruno Haible  <bruno@clisp.org>
10834
10835         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
10836         <stdlib.h>, <string.h>.
10837
10838 2006-07-30  Bruno Haible  <bruno@clisp.org>
10839
10840         * modules/readlink (License): Change to LGPL.
10841
10842 2006-07-30  Bruno Haible  <bruno@clisp.org>
10843
10844         * modules/javaversion (Makefile.am): Distribute javaversion.java and
10845         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
10846         set PKGDATADIR to point to it.
10847
10848 2006-07-30  Bruno Haible  <bruno@clisp.org>
10849
10850         * modules/csharpexec (configure.ac): Comment out macro invocation.
10851         * modules/javaexec (configure.ac): Likewise.
10852         * modules/javacomp-script (configure.ac): Likewise.
10853
10854         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
10855
10856 2006-07-30  Bruno Haible  <bruno@clisp.org>
10857
10858         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
10859         linked-list.
10860
10861 2006-07-30  Bruno Haible  <bruno@clisp.org>
10862
10863         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
10864
10865 2006-07-30  Bruno Haible  <bruno@clisp.org>
10866
10867         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
10868         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
10869         get removed.
10870
10871 2006-07-29  Bruno Haible  <bruno@clisp.org>
10872
10873         Make it possible for gnulib-tool to work with locally modified or
10874         augmented gnulib repositories.
10875         * gnulib-tool (func_usage): Document --local-dir option.
10876         (local_gnulib_dir): New variable.
10877         Handle --local-dir option.
10878         (func_lookup_file): New function.
10879         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
10880         (func_get_description, func_get_filelist, func_get_description,
10881         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
10882         func_get_automake_snippet, func_get_include_directive,
10883         func_get_license, func_get_maintainer): Use func_lookup_file.
10884         (func_import, func_create_testdir): Use func_lookup_file.
10885
10886 2006-07-29  Bruno Haible  <bruno@clisp.org>
10887
10888         * modules/setenv (Depends-on): Add unistd.
10889
10890 2006-07-29  Bruno Haible  <bruno@clisp.org>
10891
10892         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
10893
10894 2006-07-29  Bruno Haible  <bruno@clisp.org>
10895
10896         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
10897
10898 2006-07-29  Bruno Haible  <bruno@clisp.org>
10899
10900         * gnulib-tool (import, update): If there is no Makefile.am, look at
10901         aclocal.m4, instead of bailing out.
10902
10903 2006-07-29  Bruno Haible  <bruno@clisp.org>
10904
10905         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
10906         Categorize the options by when they are useful.
10907
10908 2006-07-29  Bruno Haible  <bruno@clisp.org>
10909
10910         * gnulib-tool (func_usage): Document option --no-libtool.
10911         Handle option --no-libtool.
10912         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
10913         for changed semantics of $libtool variable.
10914         (func_import): Likewise. If libtool is not used, show this through
10915         an option --no-libtool.
10916         (func_create_testdir): Update.
10917
10918 2006-07-29  Bruno Haible  <bruno@clisp.org>
10919
10920         * gnulib-tool (func_import): Extend error message about missing
10921         --doc-base.
10922
10923 2006-07-29  Bruno Haible  <bruno@clisp.org>
10924
10925         * gnulib-tool (func_import): Don't create the $docbase directory if
10926         there is no file to store there.
10927
10928 2006-07-29  Bruno Haible  <bruno@clisp.org>
10929
10930         * gnulib-tool (autoconf_minversion): If a --dir option is given and
10931         relevant, look for configure.ac there, not in the current directory.
10932         Also use a simple search for AC_PREREQ, not "autoconf --trace".
10933
10934 2006-07-29  Bruno Haible  <bruno@clisp.org>
10935
10936         * gnulib-tool (SORT): New variable.
10937         (func_usage): Undocument --assume-autoconf option.
10938         Remove --assume-autoconf option handling.
10939         (autoconf_minversion): Determine from the contents of configure.ac.
10940         (func_import): Remove autoconf_minversion handling.
10941         Suggested by Eric Blake.
10942
10943 2006-07-29  Bruno Haible  <bruno@clisp.org>
10944
10945         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
10946
10947 2006-07-29  Bruno Haible  <bruno@clisp.org>
10948
10949         * config/srclist.txt (*setenv.[ch]): Remove rules.
10950
10951 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10952
10953         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
10954
10955 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10956
10957         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
10958         arpa/inet.h.
10959
10960 2006-07-28  Simon Josefsson  <jas@extundo.com>
10961
10962         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
10963         * modules/inet_pton (Depends-on): Likewise.
10964
10965 2006-07-28  Simon Josefsson  <jas@extundo.com>
10966
10967         * m4/netinet_in_h.m4: New file.
10968
10969 2006-07-28  Simon Josefsson  <jas@extundo.com>
10970
10971         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
10972         #include's.
10973
10974 2006-07-28  Simon Josefsson  <jas@extundo.com>
10975
10976         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
10977         #include's.
10978
10979 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
10980
10981         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
10982         setgid on directories only if they set these bits.
10983         * lib/modechange.h: Remove obsolete comment about masks.
10984
10985 2006-07-28  Eric Blake  <ebb9@byu.net>
10986
10987         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
10988         macro expansion.
10989
10990 2006-07-28  Bruno Haible  <bruno@clisp.org>
10991
10992         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
10993
10994 2006-07-28  Bruno Haible  <bruno@clisp.org>
10995
10996         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
10997
10998 2006-07-28  Bruno Haible  <bruno@clisp.org>
10999
11000         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
11001         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
11002         Define fallbacks.
11003         Avoids link error on FreeBSD 4.x.
11004         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
11005
11006         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
11007         encoding.
11008         * lib/mbswidth.c (iswcntrl): Likewise.
11009
11010 2006-07-27  Bruno Haible  <bruno@clisp.org>
11011
11012         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
11013         test.
11014
11015 2006-07-27  Bruno Haible  <bruno@clisp.org>
11016
11017         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
11018         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
11019         defined.
11020
11021 2006-07-26  Eric Blake  <ebb9@byu.net>
11022
11023         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
11024
11025 2006-07-26  Eric Blake  <ebb9@byu.net>
11026
11027         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
11028         like mingw that lack mkstemp.
11029         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
11030         avoid compilation warning on mingw.
11031
11032 2006-07-26  Bruno Haible  <bruno@clisp.org>
11033
11034         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
11035         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
11036         INT_FAST*_MIN, INTPTR_MIN.
11037
11038 2006-07-25  Bruno Haible  <bruno@clisp.org>
11039
11040         * modules/version-etc (Depends-on): Add stdarg.
11041
11042 2006-07-25  Bruno Haible  <bruno@clisp.org>
11043
11044         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
11045         complex commands.
11046
11047 2006-07-25  Bruno Haible  <bruno@clisp.org>
11048
11049         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
11050         defined in <stdarg.h> or config.h.
11051
11052 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
11053
11054         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
11055         (gl_STDIO_SAFER): Remove.
11056
11057 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
11058
11059         * MODULES.html.sh (File stream based Input/Output):
11060         Add fopen-safer, tmpfile-safer; remove stdio-safer.
11061         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
11062         * modules/fopen-safer, modules/tmpfile-safer: New files.
11063         * modules/stdio-safer: Remove.
11064
11065 2006-07-24  Bruno Haible  <bruno@clisp.org>
11066
11067         * modules/tmpdir: New file.
11068         * MODULES.html.sh (File system functions): Add it.
11069
11070 2006-07-24  Bruno Haible  <bruno@clisp.org>
11071
11072         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
11073         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
11074
11075 2006-07-24  Bruno Haible  <bruno@clisp.org>
11076
11077         * modules/clean-temp: New file.
11078
11079 2006-07-24  Bruno Haible  <bruno@clisp.org>
11080
11081         * m4/tmpdir.m4: New file, from GNU gettext.
11082
11083 2006-07-24  Bruno Haible  <bruno@clisp.org>
11084
11085         * lib/tmpdir.h: New file, from GNU gettext.
11086         * lib/tmpdir.c: New file, from GNU gettext.
11087
11088 2006-07-24  Bruno Haible  <bruno@clisp.org>
11089
11090         * lib/clean-temp.h: New file, from GNU gettext.
11091         * lib/clean-temp.c: New file, from GNU gettext.
11092
11093 2006-07-23  Eric Blake  <ebb9@byu.net>
11094
11095         * modules/stdio-safer (Files): Add tmpfile-safer.c.
11096         (Depends-on): Add binary-io.
11097
11098 2006-07-23  Eric Blake  <ebb9@byu.net>
11099
11100         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
11101
11102 2006-07-23  Eric Blake  <ebb9@byu.net>
11103
11104         * lib/tmpfile-safer.c: New file.
11105         * lib/stdio-safer.h (fopen_safer): Add prototype.
11106         * lib/stdio--.h (tmpfile): Make safer.
11107
11108 2006-07-23  Bruno Haible  <bruno@clisp.org>
11109
11110         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
11111         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
11112         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
11113         gl_linked_remove_at): Use it.
11114
11115 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
11116         and Simon Josefsson <jas@extundo.com>
11117
11118         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
11119
11120         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
11121
11122 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
11123
11124         * modules/close-stream: New file.
11125         * modules/closeout (Description): Make it clear that it exits
11126         with a diagnostic on error.
11127         (Depends-on): Add close-stream.  Remove fpending, stdbool.
11128         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
11129
11130 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
11131
11132         * m4/close-stream.m4: New file.
11133
11134 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
11135
11136         * lib/close-stream.c, lib/close-stream.h: New files.
11137
11138 2006-07-22  Bruno Haible  <bruno@clisp.org>
11139
11140         Merge from GNU gettext 0.15.
11141
11142         2006-05-01  Bruno Haible  <bruno@clisp.org>
11143
11144                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
11145
11146         2006-07-22  Bruno Haible  <bruno@clisp.org>
11147
11148                 * modules/javaversion: New file.
11149                 * MODULES.html.sh (Java): Add javaversion.
11150
11151         2006-03-12  Bruno Haible  <bruno@clisp.org>
11152
11153                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
11154
11155         2005-12-04  Bruno Haible  <bruno@clisp.org>
11156
11157                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
11158                 (untested).
11159
11160         2006-06-21  Bruno Haible  <bruno@clisp.org>
11161
11162                 Avoid warnings from recent versions of mcs.
11163                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
11164                 -o, -L, -r any more. Use options documented since mcs-1.0
11165                 instead. Similarly for -g.
11166
11167         2005-12-04  Bruno Haible  <bruno@clisp.org>
11168
11169                 * build-aux/csharpcomp.sh.in: Suffix for resources is
11170                 .resources, not .resource.
11171
11172         2005-07-09  Bruno Haible  <bruno@clisp.org>
11173
11174                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
11175                 add a .dll suffix.
11176                 Reported by Mark Junker <mjscod@gmx.de>.
11177
11178         2006-07-22  Bruno Haible  <bruno@clisp.org>
11179
11180                 * modules/gettext: Upgrade to gettext-0.15.
11181                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
11182                 m4/visibility.m4.
11183                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
11184
11185 2006-07-22  Bruno Haible  <bruno@clisp.org>
11186
11187         Merge from GNU gettext 0.15.
11188
11189         2006-03-25  Bruno Haible  <bruno@clisp.org>
11190
11191                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
11192
11193         2006-07-21  Bruno Haible  <bruno@clisp.org>
11194
11195                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
11196                 "1.1".
11197
11198         2006-05-09  Bruno Haible  <bruno@clisp.org>
11199
11200                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
11201                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
11202                 for the conftestver execution.
11203
11204         2006-05-01  Bruno Haible  <bruno@clisp.org>
11205
11206                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
11207                 optional target-version argument. Verify that the compiler
11208                 groks source of the specified source-version, or add -source
11209                 option as necessary. Verify that the compiler produces
11210                 bytecode in the specified target-version, or add -target and
11211                 -source options as necessary. Make the result of the test
11212                 available as variable CONF_JAVAC. Also log error output in
11213                 config.log.
11214
11215         2006-03-11  Bruno Haible  <bruno@clisp.org>
11216
11217                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
11218
11219         2006-05-09  Bruno Haible  <bruno@clisp.org>
11220
11221                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
11222                 CLASSPATH_SEPARATOR to a semicolon.
11223
11224         2006-03-12  Bruno Haible  <bruno@clisp.org>
11225
11226                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
11227                 available as variable CONF_JAVA, for subsequent autoconf
11228                 tests. Also log error output in config.log.
11229
11230         2006-07-19  Bruno Haible  <bruno@clisp.org>
11231
11232                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
11233                 that getline works on glibc2 systems. Needed to avoid trouble
11234                 in relocatable.c.
11235                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
11236
11237         2005-12-04  Bruno Haible  <bruno@clisp.org>
11238
11239                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
11240                 launcher (untested).
11241
11242         2005-12-04  Bruno Haible  <bruno@clisp.org>
11243
11244                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
11245
11246         2006-07-22  Bruno Haible  <bruno@clisp.org>
11247
11248                 * gettext.m4: Update from GNU gettext-0.15.
11249                 * nls.m4: Likewise.
11250                 * po.m4: Likewise.
11251                 * inttypes-pri.m4: Likewise.
11252                 * inttypes-h.m4: Renamed from inttypes.m4.
11253                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
11254
11255 2006-07-22  Bruno Haible  <bruno@clisp.org>
11256
11257         Merge from GNU gettext 0.15.
11258
11259         2005-07-05  Bruno Haible  <bruno@clisp.org>
11260
11261                 * printf-args.c (printf_fetchargs): Work around broken
11262                 definition of wint_t on mingw.
11263
11264         2005-02-12  Bruno Haible  <bruno@clisp.org>
11265
11266                 * xallocsa.h: Add extern "C" for C++.
11267
11268         2006-05-17  Bruno Haible  <bruno@clisp.org>
11269
11270                 Cygwin portability.
11271                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
11272
11273         2006-04-30  Bruno Haible  <bruno@clisp.org>
11274
11275                 * progreloc.c: Include <mach-o/dyld.h> if available.
11276                 (find_executable): Use _NSGetExecutablePath when possible.
11277
11278         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
11279
11280                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
11281                 function.
11282
11283         2005-12-29  Bruno Haible  <bruno@clisp.org>
11284
11285                 * progreloc.c (set_program_name_and_installdir): Fix
11286                 compilation error.
11287
11288         2005-12-04  Bruno Haible  <bruno@clisp.org>
11289
11290                 Cygwin portability.
11291                 * progreloc.c: Include <windows.h> also on Cygwin.
11292                 (find_executable): Add support for Cygwin.
11293                 (set_program_name_and_installdir): Handle also platforms with
11294                 nonempty EXEEXT.
11295
11296         2006-07-11  Bruno Haible  <bruno@clisp.org>
11297
11298                 * javacomp.c: Fix a comment.
11299                 Reported by Jim Meyering.
11300
11301         2006-04-30  Bruno Haible  <bruno@clisp.org>
11302
11303                 * javacomp.h (compile_java_class): Add source_version,
11304                 target_version arguments.
11305                 * javacomp.c: Rewritten to choose only a compiler that
11306                 respects the specified source_version and target_version.
11307
11308         2006-06-27  Bruno Haible  <bruno@clisp.org>
11309
11310                 Assume correct S_ISDIR macro.
11311                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
11312
11313         2006-07-22  Bruno Haible  <bruno@clisp.org>
11314
11315                 * javaversion.h: New file, from GNU gettext.
11316                 * javaversion.c: New file, from GNU gettext.
11317                 * javaversion.java: New file, from GNU gettext.
11318                 * javaversion.class: New file, from GNU gettext.
11319
11320         2006-05-17  Bruno Haible  <bruno@clisp.org>
11321
11322                 Cygwin portability.
11323                 * javaexec.c (execute_java_class): Test for jview program
11324                 also on Cygwin.
11325
11326         2006-04-09  Bruno Haible  <bruno@clisp.org>
11327
11328                 * fatal-signal.c: Don't include string.h.
11329                 (at_fatal_signal): Use a copying loop instead of memcpy.
11330
11331         2005-12-04  Bruno Haible  <bruno@clisp.org>
11332
11333                 * csharpexec.c: Add support for 'clix' launcher (untested).
11334                 (execute_csharp_using_sscli): New function.
11335                 (execute_csharp_program): Call it.
11336
11337         2006-06-21  Bruno Haible  <bruno@clisp.org>
11338
11339                 Avoid warnings from recent versions of mcs.
11340                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
11341                 -o, -L, -r any more. Use options documented since mcs-1.0
11342                 instead. Similarly for -g.
11343
11344         2005-07-09  Bruno Haible  <bruno@clisp.org>
11345
11346                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
11347                 add a .dll suffix.
11348                 Reported by Mark Junker <mjscod@gmx.de>.
11349
11350         2006-06-17  Bruno Haible  <bruno@clisp.org>
11351
11352                 * config.charset: Update for NetBSD 3.0.
11353
11354         2006-05-17  Bruno Haible  <bruno@clisp.org>
11355
11356                 Cygwin portability.
11357                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
11358
11359         2006-05-16  Bruno Haible  <bruno@clisp.org>
11360
11361                 * localcharset.c [CYGWIN]: Include <windows.h>.
11362                 (get_charset_aliases): For Cygwin, return the same CPxxx
11363                 aliases list as under WIN32.
11364                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
11365                 the environment variables. Fall back to GetACP().
11366
11367         2006-04-05  Bruno Haible  <bruno@clisp.org>
11368
11369                 * config.charset: Update Juan Manuel Guerrero's address.
11370
11371         2005-02-12  Bruno Haible  <bruno@clisp.org>
11372
11373                 * allocsa.h: Add extern "C" for C++.
11374
11375         2005-02-10  Bruno Haible  <bruno@clisp.org>
11376
11377                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
11378                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
11379
11380         2006-07-22  Bruno Haible  <bruno@clisp.org>
11381
11382                 * gettext.h: Update to GNU gettext-0.15.
11383
11384 2006-07-22  Bruno Haible  <bruno@clisp.org>
11385
11386         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
11387         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
11388         lib-prefix.m4, longdouble.m4, ssize_t.m4.
11389
11390 2006-07-21  Eric Blake  <ebb9@byu.net>
11391
11392         * modules/stdlib-safer: New file.
11393         * MODULES.html.sh (File stream based Input/Output): Add
11394         stdlib-safer.
11395
11396 2006-07-21  Eric Blake  <ebb9@byu.net>
11397
11398         * lib/stdlib-safer.h: New file from coreutils, required by
11399         stdlib--.h.
11400
11401 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
11402
11403         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
11404
11405 2006-07-20  Bruno Haible  <bruno@clisp.org>
11406
11407         * gnulib-tool: Recognize new option --assume-autoconf.
11408         (autoconf_minversion): New variable.
11409         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
11410
11411 2006-07-20  Bruno Haible  <bruno@clisp.org>
11412
11413         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
11414
11415 2006-07-19  Derek R. Price  <derek@ximbiot.com>
11416
11417         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
11418         Reindent and repaginate.
11419
11420 2006-07-19  Derek Price  <derek@ximbiot.com>
11421
11422         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
11423         Correct grammar.
11424
11425 2006-07-17  Bruno Haible  <bruno@clisp.org>
11426
11427         * modules/list: New file.
11428         * modules/array-list: New file.
11429         * modules/carray-list, modules/carray-list-tests: New files.
11430         * modules/linked-list, modules/linked-list-tests: New files.
11431         * modules/avltree-list, modules/avltree-list-tests: New files.
11432         * modules/rbtree-list, modules/rbtree-list-tests: New files.
11433         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
11434         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
11435         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
11436         * modules/oset: New file.
11437         * modules/array-oset: New file.
11438         * modules/avltree-oset, modules/avltree-oset-tests: New files.
11439         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
11440         * tests/test-carray_list.c: New file.
11441         * tests/test-linked_list.c: New file.
11442         * tests/test-avltree_list.c: New file.
11443         * tests/test-rbtree_list.c: New file.
11444         * tests/test-linkedhash_list.c: New file.
11445         * tests/test-avltreehash_list.c: New file.
11446         * tests/test-rbtreehash_list.c: New file.
11447         * tests/test-avltree_oset.c: New file.
11448         * tests/test-rbtree_oset.c: New file.
11449         * MODULES.html.sh (Container data structures): New section.
11450
11451 2006-07-17  Bruno Haible  <bruno@clisp.org>
11452
11453         * m4/gl_list.m4: New file.
11454
11455 2006-07-17  Bruno Haible  <bruno@clisp.org>
11456
11457         * lib/gl_list.h: New file.
11458         * lib/gl_list.c: New file.
11459         * lib/gl_array_list.h: New file.
11460         * lib/gl_array_list.c: New file.
11461         * lib/gl_carray_list.h: New file.
11462         * lib/gl_carray_list.c: New file.
11463         * lib/gl_linked_list.h: New file.
11464         * lib/gl_linked_list.c: New file.
11465         * lib/gl_anylinked_list1.h: New file.
11466         * lib/gl_anylinked_list2.h: New file.
11467         * lib/gl_avltree_list.h: New file.
11468         * lib/gl_avltree_list.c: New file.
11469         * lib/gl_anyavltree_list1.h: New file.
11470         * lib/gl_anyavltree_list2.h: New file.
11471         * lib/gl_rbtree_list.h: New file.
11472         * lib/gl_rbtree_list.c: New file.
11473         * lib/gl_anyrbtree_list1.h: New file.
11474         * lib/gl_anyrbtree_list2.h: New file.
11475         * lib/gl_anytree_list1.h: New file.
11476         * lib/gl_anytree_list2.h: New file.
11477         * lib/gl_linkedhash_list.h: New file.
11478         * lib/gl_linkedhash_list.c: New file.
11479         * lib/gl_anyhash_list1.h: New file.
11480         * lib/gl_anyhash_list2.h: New file.
11481         * lib/gl_avltreehash_list.h: New file.
11482         * lib/gl_avltreehash_list.c: New file.
11483         * lib/gl_rbtreehash_list.h: New file.
11484         * lib/gl_rbtreehash_list.c: New file.
11485         * lib/gl_anytreehash_list1.h: New file.
11486         * lib/gl_anytreehash_list2.h: New file.
11487
11488         * lib/gl_oset.h: New file.
11489         * lib/gl_oset.c: New file.
11490         * lib/gl_array_oset.h: New file.
11491         * lib/gl_array_oset.c: New file.
11492         * lib/gl_avltree_oset.h: New file.
11493         * lib/gl_avltree_oset.c: New file.
11494         * lib/gl_rbtree_oset.h: New file.
11495         * lib/gl_rbtree_oset.c: New file.
11496         * lib/gl_anytree_oset.h: New file.
11497
11498 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11499
11500         * m4/mkancesdirs.m4: New file.
11501         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
11502         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
11503         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
11504         it.
11505
11506 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11507
11508         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
11509         * lib/mkancesdirs.h: New files.
11510         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
11511         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
11512         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
11513         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
11514         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
11515         callers changed.  Revamp internals significantly, by not
11516         attempting to create directories that are temporarily more
11517         permissive than the final results.  Do not attempt to use
11518         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
11519         This removes some race conditions, fixes some bugs, and simplifies
11520         things.  Use new dirchownmod function to do owner and mode changes.
11521         * lib/mkdir-p.h: Likewise.
11522         * lib/modechange.c (octal_to_mode): New function.
11523         (struct mode_change): New member mentioned.
11524         (make_node_op_equals): New arg mentioned.  All callers changed.
11525         (mode_compile): Keep track of which mode bits the user has explicitly
11526         mentioned.
11527         (mode_adjust): New arg DIR, so that we implement the X op correctly.
11528         New arg PMODE_BITS, to keep track of which mode bits the user
11529         mentioned; it treats S_ISUID and S_ISGID speciall.
11530         All callers changed.
11531         * lib/modechange.h: Likewise.
11532
11533 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
11534
11535         * MODULES.html.sh: Add mkancestors.
11536         * modules/mkancesdirs: New module.
11537         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
11538         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
11539         The chdir-safer and afs files are now orphans; I'll remove them
11540         unless someone speaks up.
11541         Add lib/dirchownmod.c, lib/dirchownmod.h.
11542         (Depends-on): Remove alloca, chown, save-cwd, dirname.
11543         Add lchown, mkancesdirs.
11544         (Maintainer): Add self.
11545
11546 2006-07-15  Karl Berry  <karl@gnu.org>
11547
11548         * gnulib-tool: help message wording/arrangement.
11549
11550 2006-07-14  Simon Josefsson  <jas@extundo.com>
11551
11552         * doc/gnulib.texi (Libtool and Windows): New section.
11553
11554 2006-07-12  Simon Josefsson  <jas@extundo.com>
11555
11556         * modules/gendocs (License): Fix license, approved by Karl.
11557
11558 2006-07-12  Eric Blake  <ebb9@byu.net>
11559
11560         * MODULES.html.sh: Add gendocs.
11561
11562 2006-07-11  Eric Blake  <ebb9@byu.net>
11563
11564         * modules/fdl: New module, to install doc/fdl.texi.
11565         * MODULES.html.sh: Add new section for documentation modules.
11566         * gnulib-tool: Avoid space-tab.
11567         (--doc-base): New option, to manage files from doc.
11568
11569 2006-07-11  Eric Blake  <ebb9@byu.net>
11570
11571         * m4/absolute-header.m4: Fix comments to match recent change.
11572
11573 2006-07-11  Eric Blake  <ebb9@byu.net>
11574
11575         * gnulib-tool: List --doc-base before --tests-base.
11576
11577 2006-07-11  Derek R. Price  <derek@ximbiot.com>
11578
11579         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
11580
11581 2006-07-11  Bruno Haible  <bruno@clisp.org>
11582
11583         * README: Mention where to put documentation.
11584
11585 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11586
11587         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
11588
11589 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
11590
11591         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
11592         to stdint.m4.
11593
11594 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
11595
11596         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
11597         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
11598         "no/such/file/stdint.h" when there is no such file, so that
11599         the resulting C code can be parsed by dodgy compilers.
11600         Problems reported by Bob Proulx.
11601
11602 2006-07-10  Derek R. Price  <derek@ximbiot.com>
11603
11604         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
11605         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
11606         macros into the GNU _D_EXACT_NAMLEN.
11607         * lib/savedir.c:  Likewise.
11608         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
11609
11610 2006-07-10  Derek R. Price  <derek@ximbiot.com>
11611         and Paul Eggert  <eggert@cs.ucla.edu>
11612
11613         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
11614         * m4/savedir.m4:
11615         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
11616         macros into the GNU _D_EXACT_NAMLEN.
11617
11618 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11619
11620         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
11621         around the absolute name, to work around a problem with the HP-UX
11622         11.23 native C compiler, reported by Bob Proulx.
11623
11624 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11625
11626         * doc/maintain.texi, make-stds.texi: Sync from
11627         <http://savannah.gnu.org/projects/gnustandards>.
11628
11629 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
11630
11631         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
11632
11633 2006-07-09  Jim Meyering  <jim@meyering.net>
11634
11635         * m4/glob.m4: Remove a doubled word in a comment.
11636
11637 2006-07-09  Jim Meyering  <jim@meyering.net>
11638
11639         * lib/argp-pv.c: Remove a doubled word in a comment.
11640         * lib/check-version.c (check_version): Likewise.
11641         * lib/javacomp.c (compile_java_class): Likewise.
11642
11643 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
11644
11645         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
11646         for the benefit of people using Autoconf 2.60.  If you want to
11647         support older Autoconf versions you can copy m4/onceonly_2_57.m4
11648         (or m4/onceonly.m4, if pre-2.57) manually.
11649
11650 2006-07-08  Jim Meyering  <jim@meyering.net>
11651
11652         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
11653         comment.
11654         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
11655         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
11656         comment.
11657
11658 2006-07-08  Jim Meyering  <jim@meyering.net>
11659
11660         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
11661
11662 2006-07-07  Simon Josefsson  <jas@extundo.com>
11663
11664         * tests/test-crc.c: Change expected crc value, the test vector
11665         were probably computed using the old broken crc.c?
11666
11667 2006-07-06  Simon Josefsson  <jas@extundo.com>
11668
11669         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
11670         now the canonical place for the M4 file).
11671
11672         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
11673         from the sys_socket dependency now.
11674
11675         * modules/inet_pton (Files): Ditto.
11676
11677         * modules/inet_ntop (Files): Ditto.
11678
11679 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
11680
11681         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
11682         not gl_PREREQ_GETUSERSHELL.
11683
11684 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11685
11686         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
11687         with only one argument, for Autoconf 2.60.
11688         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
11689         expand to nothing, so add a shell command to avoid syntax error.
11690         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11691
11692 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11693
11694         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
11695
11696 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11697
11698         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
11699         no longer needed.  Check for isblank decl.
11700         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
11701         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
11702         of existence.
11703
11704 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11705
11706         * lib/getloadavg.c: Use __VMS, not VMS.
11707         * lib/getopt.c: Likewise.
11708         * lib/getpagesize.h: Likewise.
11709         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
11710         and probably does not work.
11711
11712 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
11713
11714         * lib/.cppi-disable: Add wcwidth.
11715         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
11716         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
11717         (ISGRAPH): Remove.  All uses changed to isgraph.
11718         (FOLD) [!defined _LIBC]: Remove special case.
11719         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
11720         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
11721         HAVE_ISBLANK.
11722         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
11723         case.
11724
11725 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
11726
11727         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
11728         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
11729         brackets.  Other minor changes to suppress some compiler
11730         warnings.
11731
11732 2006-07-06  Derek R. Price  <derek@ximbiot.com>
11733         and Paul Eggert  <eggert@cs.ucla.edu>
11734
11735         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
11736         of invoking obsolescent AC_HEADER_DIRENT macro.
11737         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
11738         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
11739         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
11740         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
11741         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
11742         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
11743         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
11744         * m4/readdir.m4: Remove; no longer needed.
11745
11746 2006-07-06  Derek R. Price  <derek@ximbiot.com>
11747         and Paul Eggert  <eggert@cs.ucla.edu>
11748
11749         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
11750         Don't worry about this obsolete case any more.
11751         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
11752         directories.
11753         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
11754         worry about this obsolete case any more.
11755         * lib/fts.c: Likewise.
11756         * lib/getcwd.c: Likewise.
11757         * lib/glob.h: Likewise.
11758         * lib/savedir.c: Likewise.
11759
11760 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11761
11762         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
11763         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
11764         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
11765         needed.
11766         All uses removed.
11767         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11768         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
11769         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
11770         needed.
11771         * m4/getdate.m4 (gl_GETDATE): Likewise.
11772         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
11773         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
11774         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
11775         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11776         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
11777         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
11778         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
11779         needed.
11780
11781 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
11782
11783         * lib/memcasecmp.c: Include <limits.h>.
11784         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
11785         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
11786         Don't assume isdigit succeeds only on '0' through '9'.
11787
11788 2006-07-05  Eric Blake  <ebb9@byu.net>
11789
11790         * modules/getaddrinfo (Depends-on): Add snprintf.
11791
11792 2006-07-05  Eric Blake  <ebb9@byu.net>
11793
11794         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
11795         to avoid 'header present but could not be compiled' on cygwin.
11796
11797 2006-07-05  Eric Blake  <ebb9@byu.net>
11798
11799         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
11800         missing from netdb.h.
11801         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
11802
11803 2006-07-05  Derek R. Price  <derek@ximbiot.com>
11804
11805         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
11806         no longer needed.
11807         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
11808         * m4/getdate.m4 (gl_GETDATE): Likewise.
11809         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
11810         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
11811         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
11812         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
11813         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
11814
11815 2006-07-05  Derek R. Price  <derek@ximbiot.com>
11816
11817         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
11818         All uses of is_space replaced by isspace.
11819         * lib/exit.h: Don't talk about STDC_HEADERS.
11820         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
11821         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
11822         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
11823         replaced by isprint etc.
11824         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
11825         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
11826         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
11827         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
11828         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
11829         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
11830
11831 2006-07-05  Bruno Haible  <bruno@clisp.org>
11832
11833         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
11834         the function exists, before testing against AIX.
11835         Reported by Martin Lambers <marlam@marlam.de>.
11836
11837 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
11838
11839         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
11840         From Mark D. Baushke.
11841
11842 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
11843
11844         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
11845         to the absolute name, not just one, to bypass Sun C 5.8's
11846         "warning: #include of /usr/include/... may be non-portable".
11847
11848 2006-07-04  Eric Blake  <ebb9@byu.net>
11849
11850         * modules/dirname-tests: New test module.
11851         * tests/test-dirname.c: New file, replacing dirname.c
11852         TEST_DIRNAME section that was recently deleted.
11853
11854 2006-07-04  Bruno Haible  <bruno@clisp.org>
11855
11856         Assume ANSI C header files and <ctype.h> functions.
11857         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
11858         (mbsnwidth): Use isprint, iscntrl instead.
11859
11860 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11861
11862         Merge from coreutils.
11863         * MODULES.html.sh: Add xstrtold.
11864         * modules/xstrtold: New file.
11865         * modules/cycle-check (Files): Add lib/same-inode.h.
11866         * modules/dirname (Files): Add m4/double-slash-root.m4.
11867         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
11868         * modules/mkdir-p (Files): Add lib/same-inode.h.
11869         * modules/same (Files): Add lib/same-inode.h.
11870
11871 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11872
11873         * m4/absolute-header.m4: Renamed from full-header-path.m4.
11874         This is to keep the terminology clean; POSIX talks about
11875         "absolute pathnames", not "full pathnames", but the GNU
11876         Coding Standards say to use "path" for something else;
11877         so use "absolute" to keep both sides happy.
11878         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
11879         Set gl_absolute_header, not gl_full_header_path.
11880         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
11881         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
11882         All uses changed.
11883
11884         Merge from coreutils.
11885
11886         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
11887
11888         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
11889         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
11890         want to require the building of c-strtod.o.
11891         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
11892         needs -lm directly.
11893         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
11894
11895         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
11896
11897         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
11898         --as-needed option if available.  Problem reported by Albert Chin in
11899         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
11900         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
11901         cc merely issues a bunch of annoying warnings for --as-needed
11902         (this problem was reported by Bob Proulx).  Also, try linking with
11903         -lm to detect a bug in binutils 2.16 (this problem was reported
11904         by Ralf Wildenhues).
11905
11906         2006-06-18  Jim Meyering  <jim@meyering.net>
11907
11908         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
11909         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
11910         macro.
11911         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
11912         also check for glibc-2.4's abort-inducing bug.
11913
11914         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
11915         Low-probability clean-up should be to use rmdir to get rid of
11916         the just-created directory, not unlink.
11917
11918         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
11919         configure fail, and request a bug report to inform us about it.
11920         Add a comment that, barring reports to the contrary, in 2007 we'll
11921         assume ftruncate is universally available.
11922
11923         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
11924
11925         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
11926
11927         2006-03-12  Jim Meyering  <jim@meyering.net>
11928
11929         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
11930         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
11931         * m4/same.m4 (gl_SAME): Likewise.
11932         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
11933
11934         2006-03-11  Eric Blake  <ebb9@byu.net>
11935
11936         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
11937         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
11938         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
11939         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
11940
11941 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
11942
11943         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
11944         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
11945         reported by Mark D. Baushke, one in
11946         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
11947
11948         Merge from coreutils.
11949
11950         * lib/.cppi-disable: Add stdint_.h.
11951         * lib/.cvsignore: Add stdint.h.
11952
11953         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
11954
11955         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
11956         both double and long double versions.
11957         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
11958         * lib/xstrtold.c: New file.
11959         * lib/xstrtod.h (xstrtold): New decl.
11960
11961         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
11962
11963         * lib/filemode.c (setst): Remove.
11964         (strmode): Rewrite to avoid setst.  This makes the code shorter,
11965         (arguably) clearer, and the generated code is a bit smaller on my
11966         Debian GNU/Linux stable x86 host.
11967
11968         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
11969
11970         * lib/filemode.c: Include "filemode.h" first, to test the interface.
11971         Assume that filemode.h includes sys/types.h and sys/stat.h.
11972         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
11973         (ftypelet): Reorder to put common cases first, for efficiency.
11974         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
11975         to do 'M'.
11976         (strmode): Renamed from mode_string, and now stores 12 bytes instead
11977         of 10, for compatibility with FreeBSD.  All callers changed.
11978         (filemodestring): Now stores 12 bytes instead of 10, and sets file
11979         types that can't be deduced solely from st_mode.  First arg is now a
11980         const pointer.
11981         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
11982         (strmode): Renamed from mode_string.
11983         (filemodestring): New decl.
11984         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
11985         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
11986         needed.
11987         (S_ISPORT, S_ISWHT): New macros, if not already defined.
11988
11989         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
11990
11991         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
11992         fsusage.h now does that.  Include fsusage.h first, to test interface.
11993         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
11994         at most one method (the old code could have generated decls that
11995         didn't conform to C89, not that this was ever exercised).
11996         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
11997
11998         2006-03-19  Jim Meyering  <jim@meyering.net>
11999
12000         Work even in a chroot where d_ino values for entries in "/"
12001         don't match the stat.st_ino values for the same names.
12002         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
12003         number, iterate through all entries again, using lstat instead.
12004         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
12005         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
12006
12007         * lib/getcwd.c (__getcwd): Clarify a comment.
12008         Use memcpy in place of a call to strcpy.
12009
12010         2006-03-12  Jim Meyering  <jim@meyering.net>
12011
12012         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
12013         matches that of the current directory (which we're about to chdir ".."
12014         out of), then save the dev-ino of the parent, instead.
12015
12016         * lib/same-inode.h (SAME_INODE): New file/macro.
12017         * lib/chdir-safer.c (SAME_INODE): Remove definition.
12018         Include "same-inode.h", instead.
12019         * lib/same.c: Likewise.
12020         * lib/cycle-check.h: Include "same-inode.h".
12021         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
12022         * lib/cycle-check.c (SAME_INODE): Remove definition.
12023         * lib/root-dev-ino.h: Include "same-inode.h".
12024
12025         2006-03-11  Eric Blake  <ebb9@byu.net>
12026
12027         * lib/same.c (same_name): s/base_name/last_component/
12028         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
12029         * lib/filenamecat.c (file_name_concat): Likewise.
12030
12031         2006-03-11  Eric Blake  <ebb9@byu.net>,
12032                     Paul Eggert  <eggert@cs.ucla.edu>
12033
12034         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
12035         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
12036         drive prefix.
12037         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
12038         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
12039         (last_component): New method.
12040         * lib/dirname.c (dir_len): Determine when drive letters need a
12041         subsequent slash.  Preserve // when it is special.
12042         (dir_name): Don't append dot when drive letter is absolute.
12043         [TEST_DIRNAME]: Move into a full-blown gnulib test.
12044         * lib/basename.c (base_name): New semantics - malloc the result.
12045         Preserve // when it is special.  Preserve relative files that look
12046         like drive letters.
12047         (base_len): Preserve // when it is special.
12048         (last_component): New method, similar to old base_name semantics.
12049         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
12050         base_name.  Strip redundant slashes from ///.
12051
12052 2006-07-03  Jim Meyering  <jim@meyering.net>
12053
12054         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
12055         macro is used before the first cycle_check call.
12056
12057 2006-07-03  Eric Blake  <ebb9@byu.net>
12058
12059         * modules/dirname (Depends-on): Add xstrndup.
12060
12061 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
12062
12063         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
12064         test cases, so that config.log is a bit easier to follow.
12065
12066 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
12067
12068         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
12069         both are 64 bits, since this seems to be the tradition, and this
12070         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
12071         we ever run into a host that prefers long long to long in this
12072         case, we'll need another configure-time test.  Problem reported by
12073         Jim Meyering.
12074
12075 2006-07-02  Eric Blake  <ebb9@byu.net>
12076
12077         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
12078
12079 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
12080
12081         * modules/inttypes (Depends-on): No longer depends on stdint.
12082         * modules/stdint (Description): Say more about assumptions.
12083         Say that the fast types might differ.  Say macros are used.
12084         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
12085         (Makefile.am): Revise list of substituted symbols to match
12086         new stdint.m4.
12087         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
12088         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
12089         * tests/test-stdint.c (verify_same_types)
12090         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
12091         the code conforms to C99/C89.
12092         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
12093         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
12094
12095 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
12096
12097         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
12098         but fix a bug, by requiring at least 64 bits.
12099         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
12100         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
12101         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
12102         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
12103
12104         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
12105         changes.  Make 2.59 a prerequisite.  Check and substitute for
12106         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
12107         inttypes.h.  Do not use special include files; just use the
12108         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
12109         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
12110         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
12111         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
12112         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
12113         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
12114         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
12115         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
12116         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
12117         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
12118         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
12119         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
12120         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
12121         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
12122         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
12123         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
12124         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
12125         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
12126         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
12127         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
12128         WINT_MAX.  Check for C99 conformance more strictly, by detecting
12129         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
12130         not check for things that C99 does not require, e.g., int8_t.  If
12131         a test isn't needed unless <stdint.h> isn't working, and is
12132         unlikely to be needed for any other reason, then don't do it
12133         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
12134         size_t, since we assume C89 freestanding at least.  Do not check
12135         for sig_atomic_t, wchar_t, or wint_t, since the code now does
12136         the right thing even if the types are not defined.  Instead use:
12137         (gl_STDINT_TYPE_PROPERTIES): New macro.
12138         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
12139         testing whether <sys/types.h> clashes, as Autoconf does this for
12140         us now.  All uses removed.
12141         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
12142         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
12143         (gl_CHECK_TYPE_SAME):
12144         Remove; no longer needed.
12145         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
12146         exists, since we'll return 0 anyway in that case.
12147         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
12148
12149 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
12150
12151         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
12152         possible collision with system files.
12153         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
12154         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
12155         WCHAR_MIN and WCHAR_MAX in this case.
12156         (<stddef.h>): Do not include; no longer needed.
12157         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
12158         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
12159         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
12160         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
12161         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
12162         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
12163         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
12164         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
12165         !defined(__c99))]: Include in this case too, since it's harmless
12166         now.
12167         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
12168         dangerous to do so.
12169         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
12170         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
12171         (_STDINT_MIN, _STDINT_MAX): New macros.
12172         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
12173         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
12174         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
12175         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
12176         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
12177         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
12178         macros, not typedefs; this simplifies things quite a bit.
12179         Use long int for all types narrower than int64_t.
12180         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
12181         Define in terms of long long int or int64_t or long int,
12182         not int64_t or int32_t.  This saves some compile-time testing.
12183         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
12184         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
12185         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
12186         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
12187         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
12188         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
12189         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
12190         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
12191         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
12192         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
12193         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
12194         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
12195         undef any previous version and define our own version, for
12196         simplicity and consistency with the new macros for types.
12197         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
12198         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
12199         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
12200         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
12201         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
12202         @WINT_T_SUFFIX@ to keep things simple here.
12203         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
12204         Simplify by assuming typical 8/16/32/64 host, since we're
12205         already doing that elsewhere anyway.
12206         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
12207         and assume long long int is 64 bits if available.  This
12208         speeds up 'configure'.
12209
12210 2006-07-01  Eric Blake  <ebb9@byu.net>
12211
12212         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
12213         Reported by Andreas Buening.
12214
12215 2006-07-01  Eric Blake  <ebb9@byu.net>
12216
12217         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
12218
12219 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
12220
12221         * lib/getaddrinfo.c: fixed typo
12222
12223 2006-06-29  Jim Meyering  <jim@meyering.net>
12224
12225         * modules/strftime (Maintainer): Add my name, since with the
12226         FPRINTFTIME changes strftime.c has forked from glibc.
12227
12228 2006-06-29  Eric Blake  <ebb9@byu.net>
12229
12230         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
12231
12232 2006-06-29  Eric Blake  <ebb9@byu.net>
12233
12234         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
12235
12236 2006-06-29  Eric Blake  <ebb9@byu.net>
12237
12238         * lib/stat_.h: New file.
12239
12240 2006-06-29  Eric Blake  <ebb9@byu.net>
12241
12242         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
12243         unused static function.
12244
12245 2006-06-29  Eric Blake  <ebb9@byu.net>
12246
12247         * doc/functions.texi (Function Portability): Document missing lstat
12248         on mingw.
12249
12250 2006-06-29  Eric Blake  <ebb9@byu.net>
12251
12252         * MODULES.html.sh: Add sys_stat.
12253         * modules/sys_stat: New module.
12254         * modules/mkstemp (Depends-on): Add sys_stat.
12255
12256 2006-06-29  Derek R. Price  <derek@ximbiot.com>
12257
12258         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
12259
12260 2006-06-29  Derek R. Price  <derek@ximbiot.com>
12261
12262         * m4/c-bs-a.m4: Removed.
12263
12264 2006-06-29  Derek R. Price  <derek@ximbiot.com>
12265
12266         * lib/strftime.c: Assume strftime() exists.
12267
12268 2006-06-29  Derek Price  <derek@ximbiot.com>
12269
12270         * modules/c-bs-a: Removed - \a is C89.
12271         * MODULES.html.sh: Remove c-bs-a.
12272
12273 2006-06-29  Bruno Haible  <bruno@clisp.org>
12274
12275         * modules/wcwidth (License): Change to LGPL.
12276
12277 2006-06-28  Simon Josefsson  <jas@extundo.com>
12278
12279         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
12280         on _WIN32.
12281
12282         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
12283         getnameinfo.
12284
12285 2006-06-28  Simon Josefsson  <jas@extundo.com>
12286
12287         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
12288
12289 2006-06-28  Simon Josefsson  <jas@extundo.com>
12290
12291         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
12292         functions there.  It will succeed on Windows XP, but on Windows
12293         2000 and (presumably) earlier, it will fail, and use the internal
12294         re-implementation.
12295         (use_win32_p): New function.
12296         (getaddrinfo): Use strtoul on servname, to support numeric ports.
12297         Support AI_NUMERICSERV to disable getservbyname.
12298         (getnameinfo): New function, only supports
12299         NI_NUMERICHOST|NI_NUMERICSERV for now.
12300
12301         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
12302         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
12303         getnameinfo.
12304
12305 2006-06-28  Eric Blake  <ebb9@byu.net>
12306
12307         * modules/wcwidth: New file.
12308         * modules/mbchar (Depends-on): Add wcwidth.
12309         * modules/mbswidth (Depends-on): Add wcwidth.
12310         * MODULES.html.sh: Add wcwidth.
12311
12312 2006-06-28  Eric Blake  <ebb9@byu.net>
12313
12314         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
12315         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
12316
12317 2006-06-28  Eric Blake  <ebb9@byu.net>
12318
12319         * lib/xvasprintf.h: Fix comments.
12320
12321 2006-06-28  Eric Blake  <ebb9@byu.net>
12322
12323         * lib/mbchar.h (wcwidth): Include wcwidth.h.
12324         * lib/mbswidth.c (wcwidth): Move from here...
12325         * lib/wcwidth.h: ...to this new file.
12326
12327 2006-06-28  Derek R. Price  <derek@ximbiot.com>
12328
12329         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
12330
12331         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
12332         it's obsolete.
12333         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
12334
12335 2006-06-28  Derek R. Price  <derek@ximbiot.com>
12336
12337         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
12338         Autoconf 2.60 says this stuff was obsolete.
12339
12340 2006-06-28  Bruno Haible  <bruno@clisp.org>
12341
12342         * modules/wcwidth (Files): Add m4/wchar_t.m4.
12343
12344 2006-06-28  Bruno Haible  <bruno@clisp.org>
12345
12346         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
12347         gt_TYPE_WCHAR_T.
12348
12349 2006-06-28  Bruno Haible  <bruno@clisp.org>
12350
12351         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
12352         declaration for wcwidth.
12353         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
12354
12355 2006-06-28  Bruno Haible  <bruno@clisp.org>
12356
12357         * lib/mkdtemp.c [MINGW]: Include <io.h>.
12358         (mkdir): Define using _mkdir.
12359
12360 2006-06-28  Bruno Haible  <bruno@clisp.org>
12361
12362         * lib/getaddrinfo.h: Fix POSIX URL.
12363         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
12364         _WIN32.
12365         (use_win32_p): Make static.
12366         (getaddrinfo): Reject service name if it is empty or does not consist
12367         solely of decimal digits, or if its value is > 65535.
12368         (getnameinfo): Remove useless casts.
12369
12370 2006-06-27  Simon Josefsson  <jas@extundo.com>
12371
12372         * modules/sys_select: New file, suggested by Bruno Haible, Paul
12373         Eggert and Martin Lambers.
12374
12375 2006-06-27  Simon Josefsson  <jas@extundo.com>
12376
12377         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
12378         Eggert and Martin Lambers.
12379
12380 2006-06-27  Bruno Haible  <bruno@clisp.org>
12381
12382         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
12383         result to 0, not to empty.
12384         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
12385
12386 2006-06-27  Bruno Haible  <bruno@clisp.org>
12387
12388         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
12389
12390 2006-06-26  Simon Josefsson  <jas@extundo.com>
12391
12392         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
12393         present.
12394
12395 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
12396
12397         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
12398         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
12399         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
12400
12401 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
12402
12403         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
12404
12405 2006-06-26  Bruno Haible  <bruno@clisp.org>
12406
12407         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
12408
12409 2006-06-26  Bruno Haible  <bruno@clisp.org>
12410
12411         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
12412
12413 2006-06-26  Bruno Haible  <bruno@clisp.org>
12414
12415         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
12416         SGI C compiler in pre-C99 mode.
12417         Suggested by Mark D. Baushke and Larry Jones.
12418
12419 2006-06-26  Bruno Haible  <bruno@clisp.org>
12420
12421         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
12422         WCHAR_MAX.
12423         Reported by Mark D. Baushke and Larry Jones.
12424
12425 2006-06-26  Bruno Haible  <bruno@clisp.org>
12426
12427         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
12428         in pre-C99 mode.
12429         Suggested by Mark D. Baushke and Larry Jones.
12430
12431 2006-06-23  Simon Josefsson  <jas@extundo.com>
12432             Bruno Haible  <bruno@clisp.org>
12433
12434         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
12435         Emit mostlyclean-local rule.
12436         (func_emit_tests_Makefile_am): Likewise.
12437         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
12438
12439 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
12440
12441         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
12442
12443 2006-06-23  Bruno Haible  <bruno@clisp.org>
12444
12445         * tests/test-stdint.c: Update to match ISO C 99 Technical
12446         Corrigendum 1.
12447
12448 2006-06-23  Bruno Haible  <bruno@clisp.org>
12449
12450         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
12451
12452 2006-06-23  Bruno Haible  <bruno@clisp.org>
12453
12454         * lib/stdint_.h: Treat IRIX like OpenBSD.
12455
12456 2006-06-23  Bruno Haible  <bruno@clisp.org>
12457
12458         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
12459         ISO C 99 Technical Corrigendum 1.
12460
12461 2006-06-22  Simon Josefsson  <jas@extundo.com>
12462
12463         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
12464         MinGW.
12465
12466 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
12467
12468         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
12469         needed.  Some compiler complained about some of them.  Problem reported
12470         by Larry Jones in
12471         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
12472
12473 2006-06-21  Simon Josefsson  <jas@extundo.com>
12474
12475         * tests/test-getaddrinfo.c: New file.
12476
12477         * modules/getaddrinfo-tests: New file.
12478
12479         * MODULES.html.sh: Add inet_pton.
12480
12481         * modules/inet_pton: New file.
12482
12483 2006-06-21  Simon Josefsson  <jas@extundo.com>
12484
12485         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
12486         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
12487         of using the (limited) gnulib implementation on Windows XP.
12488
12489         * m4/inet_pton.m4: New file.
12490
12491 2006-06-21  Simon Josefsson  <jas@extundo.com>
12492
12493         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
12494         variable.
12495
12496         * lib/socket_.h: Don't define WINVER.
12497
12498         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
12499         slightly modified to work in gnulib.
12500
12501 2006-06-21  Simon Josefsson  <jas@extundo.com>
12502
12503         * doc/gnulib.texi (Windows sockets): Add.
12504
12505 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
12506
12507         * lib/read-file.c (fread_file): Start with buffer allocation of
12508         0 bytes rather than 1 byte; this simplifies the code.
12509         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
12510         code to free buffer and save/restore errno.
12511         (internal_read_file): Remove unused local.
12512
12513 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
12514
12515         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
12516         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
12517         Problem reported by Denis Excoffier in
12518         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
12519
12520 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
12521
12522         * modules/sys_socket, modules/socklen: Include sys/types since
12523         FreeBSD 4.x's sys/socket.h needs it.
12524
12525 2006-06-19  Simon Josefsson  <jas@extundo.com>
12526
12527         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
12528
12529 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
12530
12531         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
12532
12533 2006-06-19  Bruno Haible  <bruno@clisp.org>
12534
12535         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
12536         and FULL_PATH_INTTYPES_H in angle brackets.
12537         Reported by Mark D. Baushke <mdb@gnu.org>.
12538
12539 2006-06-17  Eric Blake  <ebb9@byu.net>
12540
12541         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
12542         errno.
12543
12544 2006-06-17  Bruno Haible  <bruno@clisp.org>
12545
12546         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
12547         <sys/inttypes.h>.
12548
12549 2006-06-17  Bruno Haible  <bruno@clisp.org>
12550
12551         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
12552         whether errno is declared. Assume <errno.h> declares errno.
12553
12554 2006-06-17  Bruno Haible  <bruno@clisp.org>
12555
12556         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
12557
12558 2006-06-17  Bruno Haible  <bruno@clisp.org>
12559
12560         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
12561         problem on Solaris 2.5.1.
12562
12563 2006-06-16  Eric Blake  <ebb9@byu.net>
12564
12565         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
12566         * lib/unicodeio.c [!defined errno]: Likewise.
12567         * lib/strtol.c [!defined errno]: Likewise.
12568         * lib/strtod.c [!defined errno]: Likewise.
12569
12570 2006-06-15  Eric Blake  <ebb9@byu.net>
12571
12572         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
12573
12574 2006-06-15  Eric Blake  <ebb9@byu.net>
12575
12576         * config/srclist.txt (ssize_t.m4): Lose sync.
12577
12578 2006-06-15  Bruno Haible  <bruno@clisp.org>
12579
12580         * modules/stdint (Files): Include m4/full-header-path.m4,
12581         m4/size_max.m4, m4/wchar_t.m4.
12582         (Makefile.am): Many more substitutions.
12583         * modules/stdint-tests: New file.
12584         * tests/test-stdint.c: New file.
12585
12586 2006-06-15  Bruno Haible  <bruno@clisp.org>
12587
12588         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
12589         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
12590         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
12591         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
12592         gl_CHECK_TYPE_SAME): New macros.
12593
12594 2006-06-15  Bruno Haible  <bruno@clisp.org>
12595
12596         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
12597
12598 2006-06-15  Bruno Haible  <bruno@clisp.org>
12599
12600         * lib/stdint_.h: Rewritten to be fully auto-configured.
12601         Fixes bug on HP-UX/IA64.
12602
12603 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
12604
12605         * lib/getdate.y (__attribute__): Don't define if already defined.
12606         Problem reported by Larry Jones.
12607         * lib/utimens.c (__attribute__): Likewise.
12608
12609 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
12610
12611         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
12612         reported by Andreas Schwab.
12613
12614 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12615             Bruno Haible  <bruno@clisp.org>
12616
12617         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
12618         check for the declaration of strnlen and a run test that exposes the
12619         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
12620         rpl_strndup.
12621
12622 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12623             Bruno Haible  <bruno@clisp.org>
12624
12625         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
12626
12627 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12628
12629         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
12630         compile test, for Tru64 4.0D.
12631
12632 2006-05-28  Karl Berry  <karl@gnu.org>
12633
12634         * config/srclist.txt (printf-args.c): lose sync.
12635
12636 2006-05-26  Martin Lambers  <marlam@marlam.de>
12637
12638         * lib/getpass.c: Updates the test for the native W32 API, and adds
12639         missing includes, thus fixing compilation warnings.
12640
12641 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
12642
12643         * lib/exclude.c (exclude_fnmatch): New function.
12644         (excluded_file_name): Call exclude_fnmatch.
12645         * lib/exclude.h (excluded_file_name): New prototype
12646
12647 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
12648
12649         * lib/tempname.c (small_open, large_open): New macros.
12650         (__open, __open64) [!_LIBC]: Remove.
12651         (__gen_tempname): Use small_open and large_open instead of __open
12652         and __open64.  This fixes a portability bug on HP-UX 11.11i
12653         reported by Simon Wing-Tang in
12654         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
12655
12656 2006-05-24  Bruno Haible  <bruno@clisp.org>
12657
12658         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
12659         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
12660         Reported by Thorsten Maerz <torte@netztorte.de> via
12661         Aaron Stone <aaron@serendipity.cx>.
12662
12663 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
12664
12665         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
12666         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
12667         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
12668         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
12669         not really conditional on the cache.
12670         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
12671
12672 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
12673
12674         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
12675         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
12676         (my_usleep): Don't mishandle maximum value.
12677
12678 2006-05-19  Jim Meyering  <jim@meyering.net>
12679
12680         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
12681
12682 2006-05-17  Bruno Haible  <bruno@clisp.org>
12683
12684         Cygwin portability.
12685         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
12686
12687 2006-05-17  Bruno Haible  <bruno@clisp.org>
12688
12689         * lib/stdint_.h: Fix recognition of Cygwin.
12690
12691 2006-05-15  Bruno Haible  <bruno@clisp.org>
12692
12693         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
12694         on libtool patch by Ralf Wildenhues.
12695
12696 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
12697
12698         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
12699         test for C99 conformance; (bool) 0.5 is an integer constant
12700         expression, but (bool) -0.5 is not.  Problem reported by Fedor
12701         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
12702
12703 2006-05-11  Simon Josefsson  <jas@extundo.com>
12704
12705         * m4/xvasprintf.m4: Fix obvious typo.
12706
12707 2006-05-11  Jim Meyering  <jim@meyering.net>
12708
12709         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
12710         James Lemley.
12711
12712 2006-05-10  Simon Josefsson  <jas@extundo.com>
12713
12714         * lib/md4.c: Typo fix, update copyright years.
12715         (K1, K2): Don't use L because it turn computations into 64-bit on
12716         64-bit platforms.
12717
12718 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
12719
12720         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
12721         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
12722         unwanted sign propagation, e.g., on hosts with 64-bit int.
12723         There still are some problems with reeelly weird theoretical hosts
12724         (e.g., 33-bit int) but it's not worth worrying about now.
12725         * lib/sha1.c (rol): Likewise.
12726         (K1, K2, K3, K4): Remove unnecessary L suffix.
12727
12728 2006-05-10  Bruno Haible  <bruno@clisp.org>
12729
12730         * lib/des.c: Cast to avoid warnings.
12731
12732 2006-05-09  Bruno Haible  <bruno@clisp.org>
12733
12734         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
12735         (Depends-on): Depend also on xsize, stdarg.
12736         (configure.ac): Add gl_XVASPRINTF.
12737
12738 2006-05-09  Bruno Haible  <bruno@clisp.org>
12739
12740         * m4/xvasprintf.m4: New file.
12741
12742 2006-05-09  Bruno Haible  <bruno@clisp.org>
12743
12744         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
12745         (EOVERFLOW): Define fallback value.
12746         (xstrcat): New function.
12747         (xvasprintf): Recognize the special case of a string concatenation.
12748
12749 2006-05-08  Eric Blake  <ebb9@byu.net>
12750
12751         * gnulib-tool (func_version): Base copyright year on CVS date.
12752         (func_emit_copyright_notice): New function.
12753         (func_emit_lib_Makefile_am): Use it.
12754         (func_emit_tests_Makefile_am): Likewise.
12755         (func_import): Likewise.
12756
12757 2006-05-08  Bruno Haible  <bruno@clisp.org>
12758
12759         * modules/stdarg: New file.
12760         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
12761
12762 2006-05-08  Bruno Haible  <bruno@clisp.org>
12763
12764         * m4/stdarg.m4: New file, from GNU gettext.
12765
12766 2006-05-08  Bruno Haible  <bruno@clisp.org>
12767
12768         * config/srclist.txt (build-aux/config.rpath): different from latest
12769         release.
12770
12771 2006-05-08  Bruno Haible  <bruno@clisp.org>
12772
12773         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
12774
12775 2006-05-05  Jim Meyering  <jim@meyering.net>
12776
12777         * m4/warning.m4: New file, derived from bison's file by the same name.
12778
12779 2006-05-03  Bruno Haible  <bruno@clisp.org>
12780
12781         * lib/stdint_.h: Shorter URL.
12782         * lib/inttypes.h: Likewise.
12783
12784 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12785
12786         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
12787
12788 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12789
12790         * lib/verify.h: Document the internals better.  Most of this change
12791         was written by Bruno Haible.
12792
12793 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
12794
12795         * doc/verify.texi: New file, partly based on a proposal by
12796         Bruno Haible.
12797
12798 2006-05-02  Bruno Haible  <bruno@clisp.org>
12799
12800         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
12801         test from here...
12802         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
12803
12804 2006-04-29  Bruno Haible  <bruno@clisp.org>
12805
12806         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
12807         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
12808
12809 2006-04-29  Bruno Haible  <bruno@clisp.org>
12810
12811         * gnulib-tool: Make --update option actually work.
12812
12813 2006-04-29  Bruno Haible  <bruno@clisp.org>
12814
12815         * doc/gcd.texi: New file.
12816         * doc/gnulib.texi: Include it.
12817
12818 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
12819
12820         * lib/getdate.y (get_date): When adding relative date, start with the
12821         initial time, not with the result of the first mktime call.
12822
12823 2006-04-25  Bruno Haible  <bruno@clisp.org>
12824
12825         * gnulib-tool (func_import): Output the include directives in three
12826         blocks, sorted separately.
12827         Reported by Ben Pfaff <blp@cs.stanford.edu>.
12828
12829 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
12830
12831         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
12832         to define main with arguments, for C++.  Reported by Eric Blake.
12833         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
12834         Prefer 'int main ()' to 'int main (void)', for C++.
12835         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
12836         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
12837         for 'main', for C99 and C++.
12838
12839 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
12840
12841         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
12842         Don't assume that exit status -1 is valid.
12843         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
12844         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
12845         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
12846         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
12847         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
12848         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
12849         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
12850         functions can be used without declaring them, or that you can
12851         exit with status -1.
12852         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
12853
12854 2006-04-24  Karl Berry  <karl@gnu.org>
12855
12856         * config/srclist.txt (longdouble.m4): sync lost.
12857
12858 2006-04-24  Eric Blake  <ebb9@byu.net>
12859
12860         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
12861
12862 2006-04-24  Bruno Haible  <bruno@clisp.org>
12863
12864         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
12865         poll() implementation in AIX.
12866         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12867
12868 2006-04-24  Bruno Haible  <bruno@clisp.org>
12869
12870         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
12871         assigned exactly once.
12872
12873 2006-04-23  Claudio Fontana  <claudio@gnu.org>
12874             Bruno Haible  <bruno@clisp.org>
12875
12876         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
12877         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
12878         for AM_CPPFLAGS.
12879
12880 2006-04-23  Bruno Haible  <bruno@clisp.org>
12881
12882         * modules/copy-file: Depend on unistd.
12883         * modules/execute: Likewise.
12884         * modules/fatal-signal: Likewise.
12885         * modules/findprog: Likewise.
12886         * modules/mkdtemp : Likewise.
12887         * modules/pipe: Likewise.
12888         * modules/wait-process: Likewise.
12889
12890 2006-04-23  Bruno Haible  <bruno@clisp.org>
12891
12892         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
12893         condition was already detected.
12894         Reported by Ben Pfaff <blp@cs.stanford.edu>.
12895
12896 2006-04-23  Bruno Haible  <bruno@clisp.org>
12897
12898         * lib/copy-file.c: Include <unistd.h> unconditionally.
12899         * lib/execute.c: Likewise.
12900         * lib/fatal-signal.c: Likewise.
12901         * lib/findprog.c: Likewise.
12902         * lib/mkdtemp.c: Likewise.
12903         * lib/pipe.h: Likewise.
12904         * lib/pipe.c: Likewise.
12905         * lib/wait-process.h: Likewise.
12906
12907 2006-04-23  Bruno Haible  <bruno@clisp.org>
12908
12909         * gnulib-tool (func_usage): Fix --import description. Document
12910         --update.
12911         (func_import): Create temporary file in a temporary directory, if
12912         --dry-run is specified. Silence errors from 'grep' when there are no
12913         m4 files in $m4dir.
12914         (func_create_testdir): Silence errors from 'grep' when there are no
12915         m4 files in $m4dir.
12916         Reported by Karl Berry <karl@freefriends.org>.
12917
12918 2006-04-20  Bruno Haible  <bruno@clisp.org>
12919
12920         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
12921         one argument, so that the code will be portable to Autoconf 2.60.
12922         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
12923         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
12924         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
12925
12926 2006-04-19  Derek Price  <derek@ximbiot.com>
12927             Eric Blake  <ebb9@byu.net>
12928
12929         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
12930         rather than "/full/path.h".  Update comment to match.  Shorten &
12931         generalize m4_translit call via AS_TR_CPP.
12932
12933 2006-04-19  Derek Price  <derek@ximbiot.com>
12934             Eric Blake  <ebb9@byu.net>
12935
12936         * lib/inttypes.h: Correct grammar in comment.
12937
12938 2006-04-18  Derek Price  <derek@ximbiot.com>
12939             Paul Eggert  <eggert@cs.ucla.edu>
12940
12941         * modules/inttypes: New file.
12942         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
12943
12944 2006-04-18  Derek Price  <derek@ximbiot.com>
12945             Paul Eggert  <eggert@cs.ucla.edu>
12946
12947         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
12948         New files.
12949
12950 2006-04-18  Derek Price  <derek@ximbiot.com>
12951             Paul Eggert  <eggert@cs.ucla.edu>
12952
12953         * lib/inttypes.h: New file.
12954         * lib/strtoimax.c: Assume <inttypes.h>.
12955
12956 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
12957
12958         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
12959         isn't mounted.  Problem reported by Kir Kolyshkin.
12960
12961 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
12962
12963         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
12964         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
12965         Derek R. Price.
12966         * lib/regex.h (RE_DUP_MAX): Update comment to match current
12967         implementation.
12968
12969 2006-04-12  Eric Blake  <ebb9@byu.net>
12970
12971         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
12972         is now done automatically by the corresponding Autoconf macro.
12973
12974 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
12975
12976         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
12977         time_r.h.
12978
12979 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12980
12981         Merge regex changes from libc, removing some of our
12982         POSIX-conformance changes that were rejected and redoing them in a
12983         less-intrusive way.
12984
12985         * lib/regcomp.c (re_compile_internal, init_dfa):
12986         Length arg is now size_t, not Idx.  All uses changed.
12987         (peek_token): Forward decl now says internal_function.
12988         (__re_error_msgid, __re_error_msgid_idx):
12989         Now static rather than extern with attribute_hidden.
12990         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
12991         For some reason libc prefers K&R style defns for external functions.
12992         (regerror) [!defined _LIBC]: Likewise.
12993         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
12994         (seek_collating_symbol_entry, lookup_collation_sequence_value):
12995         (build_range_exp, build_collating_symbol):
12996         Use K&R-style defn.
12997         (re_compile_fastmap): Use '\0' to memset, not 0.
12998         (utf8_sb_map): Make the calculations more obvious.
12999         (init_dfa, parse_bracket_exp, build_charclass_op):
13000         Call calloc and cast result, as glibc does.
13001         (init_word_char, fetch_token, peek_token, peek_token_bracket):
13002         (build_range_exp, build_collating_symbol):
13003         Now internal functions.
13004
13005         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
13006
13007         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
13008         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
13009         Don't depend on VMS; depend on __VMS instead, for POSIX
13010         namespace cleanness.
13011         (regoff_t): Define to ssize_t, not long int.
13012
13013         Remove the REG_ macros named below.  Instead, make the old names
13014         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
13015         __USE_GNU_REGEX.
13016         (REG_BACKSLASH_ESCAPE_IN_LISTS):
13017         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
13018         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
13019         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
13020         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
13021         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
13022         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
13023         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
13024         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
13025         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
13026         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
13027         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
13028         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
13029         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
13030         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
13031         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
13032         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
13033         (REG_NREGS):
13034         Remove.  All uses replaced by the old RE_* names.
13035         (RE_BACKSLASH_ESCAPE_IN_LISTS):
13036         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
13037         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
13038         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
13039         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
13040         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
13041         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
13042         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
13043         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
13044         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
13045         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
13046         Don't bother having these macros be independent of each others'
13047         values, since they no longer exist in the POSIX name space.
13048
13049         Rename the following member names back to their old names,
13050         unless !__USE_GNU_REGEX.  All uses changed back.
13051         (buffer): Renamed from re_buffer.
13052         (allocated): Renamed from re_allocated.
13053         (used): Renamed from re_used.
13054         (syntax): Renamed from re_syntax.
13055         (fastmap): Renamed from re_fastmap.
13056         (translate): Renamed from re_translate.
13057         (can_be_null): Renamed from re_can_be_null.
13058         (regs_allocated): Renamed from re_regs_allocated.
13059         (fastmap_accurate): Renamed from re_fastmap_accurate.
13060         (no_sub): Renamed from re_no_sub.
13061         (not_bol): Renamed from re_not_bol.
13062         (not_eol): Renamed from re_not_eol.
13063         (newline_anchor): Renamed from re_newline_anchor.
13064         (num_regs): Renamed from rm_num_regs.
13065         (start): Renamed from rm_start.
13066         (end): Renamed from rm_end.
13067
13068         (free_state): Move up a bit.
13069
13070         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
13071         #define to be empty.
13072         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
13073         when that is what is intended.
13074         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
13075         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
13076         (MAX): New macro.
13077         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
13078         All uses changed back to re_malloc, etc.  It's now the caller's
13079         responsibility to check for overflow; all callers changed.
13080         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
13081         (re_x2nrealloc): Remove.
13082         (free_state): Remove decl.
13083
13084         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
13085         (re_set_registers, re_exec):
13086         Use K&R-style defn.
13087
13088         2006-01-31  Roland McGrath  <roland@redhat.com>
13089
13090         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
13091         Reported by Mike Frysinger <vapier@gentoo.org>.
13092
13093         2006-01-15  Andreas Jaeger  <aj@suse.de>
13094
13095         [BZ #1950]
13096         * lib/regex_internal.c (re_string_reconstruct): Adjust for
13097         build_wcs_upper_buffer change.
13098         (build_wcs_upper_buffer): Change return type.
13099
13100         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
13101
13102         * lib/regex_internal.h: Include <stdint.h> if available.
13103
13104         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
13105
13106         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
13107
13108         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
13109
13110         * lib/regcomp.c: Adjust for changed secondary hash function.
13111
13112         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
13113
13114         * lib/regex.h: Pretty printing.
13115         Clean up namespace a bit.
13116
13117         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
13118
13119         * lib/regexec.c (update_cur_sifted_state, check_arrival,
13120         check_arrival_add_next_nodes): Avoid using uninitialized variable.
13121
13122         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
13123                     Ulrich Drepper  <drepper@redhat.com>
13124
13125         [BZ #1302]
13126         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
13127         changed.
13128         (bitset_word_t): Renamed from bitset_word.  All uses changed.
13129
13130         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
13131
13132         [BZ #281]
13133         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
13134         * lib/regcomp.c: Remove unnecessary uses of
13135         unsigned RE_TRANSLATE_TYPE.
13136         * lib/regex_internal.h: Likewise.
13137         * lib/regex_internal.c: Likewise.
13138         * lib/regexec.c: Likewise.
13139         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
13140
13141         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
13142
13143         * lib/regexec.c (find_recover_state): Remove unnecessary
13144         initialization.
13145         (transit_state_bkref): Make DFA a const pointer.
13146         (get_subexp): Likewise.
13147         (check_arrival): Likewise.
13148         (update_cur_sifted_state): Likewise.
13149         (re_search_internal): Likewise.
13150         (prune_impossible_nodes): Likewise.
13151         (acquire_init_state_context): Likewise.
13152         (proceed_next_node): Likewise.
13153         (set_regs): Likewise.
13154         (free_fail_stack_return): Likewise.
13155         (check_arrival_expand_ecl): Mark DFA parameter as const.
13156         (check_arrival_expand_ecl_sub): Likewise.
13157         (check_subexp_limits): Likewise.
13158         (sub_epsilon_src_nodes):  Likewise.
13159         (add_epsilon_src_nodes):  Likewise.
13160         (merge_state_array): Likewise.
13161         (update_regs): Likewise.
13162         (build_trtable): Likewise.
13163         (sift_states_backward): Mark MCTX parameter as const.
13164         (build_sifted_states): Likewise.
13165         (update_cur_sifted_state): Likewise.
13166         (sift_states_mkref): Likewise.
13167         (check_arrival_expand_ecl): Mark eclosure as const.
13168         (check_dst_limits_calc_pos_1): Likewise.
13169         * lib/regex_internal.h (re_match_context_t): Make dfa a const
13170         pointer.
13171
13172         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
13173
13174         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
13175         (transit_state_sb): Likewise.
13176         (transit_state_mb): Likewise.
13177         (sift_states_iter_mb): Likewise.
13178         (check_arrival_add_next_nodes): Likewise.
13179         (check_node_accept_bytes): Change first parameter to pointer-to-const.
13180         [_LIBC] (re_search_2_stub): Use mempcpy.
13181
13182         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
13183         mbrtowc for very simple UTF-8 case.
13184
13185         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
13186         a pointer-to-const.
13187         (re_acquire_state_context): Likewise.
13188         * lib/regex_internal.h: Adjust prototypes.
13189
13190         * lib/regex.c: Prevent using C++ compilers.
13191
13192         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
13193         (re_acquire_state_context): Likewise.
13194
13195 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
13196
13197         * modules/regex (Depends-on): Add ssize_t.
13198
13199 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
13200
13201         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
13202         translation table.
13203
13204 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
13205
13206         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
13207
13208 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
13209             Bruno Haible  <bruno@clisp.org>
13210
13211         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
13212         <sys/types.h> and <inttypes.h>.
13213
13214 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13215
13216         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
13217         `__error_t_defined', so argp.h will not typedef the former.
13218
13219 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
13220
13221         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
13222         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
13223         glibc names.  Even if glibc is changed to conform to POSIX, the
13224         traditional names will be available anyway, since regex depends on
13225         the extensions module.  Also, fix a longstanding typo in the
13226         implementation of Spencer ERE test #75 from grep 2.3.  Problems
13227         reported by Emanuele Giaquinta.  Also, change sense of cached
13228         variable, so that the message makes sense.
13229
13230 2006-03-24  Simon Josefsson  <jas@extundo.com>
13231
13232         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
13233         including some doc fixes.
13234         (base64_encode_alloc): Fix +1 bug on allocation failures.
13235
13236 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13237
13238         * lib/base64.c (base64_encode): Do not read past end of array with
13239         unsanitized input on systems with CHAR_BIT > 8.
13240
13241 2006-03-24  Eric Blake  <ebb9@byu.net>
13242
13243         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
13244
13245 2006-03-22  Karl Berry  <karl@gnu.org>
13246
13247         * config/srclist.txt (*setenv.[ch]): get from coreutils.
13248         * config/srclistvars.sh (COREUTILS): new var.
13249
13250 2006-03-17  Jim Meyering  <jim@meyering.net>
13251
13252         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
13253         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
13254
13255 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
13256
13257         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
13258         no longer needs it.  Instead, check that regoff_t is as least
13259         as wide as ptrdiff_t.
13260
13261         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
13262         so that our regex.h stays compatible with the installed regex.
13263         This is helpful for installers who configure --without-included-regex.
13264         Problem reported by Emanuele Giaquinta.
13265
13266 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
13267
13268         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
13269         Typedef to long int, not to off_, as POSIX will likely change
13270         in that direction.
13271
13272 2006-03-15  Eric Blake  <ebb9@byu.net>
13273
13274         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
13275
13276 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
13277
13278         * lib/argp-help.c (validate_uparams): Fix typo
13279         * lib/argp-parse.c (argp_default_options): Consistently begin help
13280         messages with a lowercase letter.
13281
13282 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
13283
13284         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
13285         overrun buffers and shouldn't be used (much as gets shouldn't be
13286         used).
13287         * lib/time_r.c (asctime_r, ctime_r): Likewise.
13288
13289 2006-03-08  Simon Josefsson  <jas@extundo.com>
13290
13291         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
13292         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13293
13294 2006-03-08  Simon Josefsson  <jas@extundo.com>
13295
13296         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
13297         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13298
13299 2006-03-08  Simon Josefsson  <jas@extundo.com>
13300
13301         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
13302         signal that configure disabled the device.
13303
13304 2006-03-08  Simon Josefsson  <jas@extundo.com>
13305
13306         * build-aux/maint.mk: Fix refresh-po, to handle no translated
13307         languages.
13308
13309 2006-03-07  Simon Josefsson  <jas@extundo.com>
13310
13311         * modules/getopt (Depends-on): Add unistd.
13312
13313         * modules/unistd: New file.
13314
13315 2006-03-07  Simon Josefsson  <jas@extundo.com>
13316
13317         * modules/gc-random: New file.
13318
13319 2006-03-07  Simon Josefsson  <jas@extundo.com>
13320
13321         * m4/unistd_h.m4: New file.
13322
13323 2006-03-07  Simon Josefsson  <jas@extundo.com>
13324
13325         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
13326         test to be side-effect free by storing the result in the cache
13327         variable gl_cv_lib_readline, and moving the assignment of
13328         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
13329         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13330
13331 2006-03-07  Simon Josefsson  <jas@extundo.com>
13332
13333         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
13334         error on missing devices (the functions will return an error).
13335
13336         * m4/gc.m4: Move random stuff to gc-random.m4
13337
13338 2006-03-07  Simon Josefsson  <jas@extundo.com>
13339
13340         * lib/unistd_.h: New file.
13341
13342 2006-03-07  Simon Josefsson  <jas@extundo.com>
13343
13344         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
13345
13346 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
13347
13348         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
13349         Problem reported by Juan Manuel Guerrero.
13350
13351 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
13352
13353         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
13354         the unistd module.
13355         * lib/getlogin_r.c: Likewise.
13356         * lib/getlogin_r.h: Likewise.
13357         * lib/glob.c: Likewise.
13358         * lib/pagealign_alloc.c: Likewise.
13359         * lib/unistd_.h: Remove; no longer needed.
13360
13361 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
13362
13363         * MODULES.html.sh (Support for systems lacking POSIX:2001):
13364         Add unistd.
13365         * modules/c-stack (Depends-on): Add unistd.
13366         * modules/getlogin_r: Likewise.
13367         * modules/glob: Likewise.
13368         * modules/pagealign_alloc: Likewise.
13369         * modules/unistd (Files): Remove lib/unistd_.h.
13370         (EXTRA_DIST): Remove.
13371         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
13372         need unistd_.h.
13373         (MOSTLYCLEANFILES): Remove unistd.h-t.
13374
13375 2006-03-03  Simon Josefsson  <jas@extundo.com>
13376
13377         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
13378
13379 2006-03-03  Simon Josefsson  <jas@extundo.com>
13380
13381         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
13382         libidn and bison.
13383
13384 2006-03-03  Simon Josefsson  <jas@extundo.com>
13385
13386         * build-aux/maint.mk: Add indent target.
13387
13388 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
13389
13390         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
13391         our replacement poll.h in any case, to avoid a differing
13392         declaration from a system header.  Seen on AIX.
13393
13394 2006-03-01  Simon Josefsson  <jas@extundo.com>
13395
13396         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
13397         <kasal@ucw.cz>.
13398
13399 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13400
13401         * modules/gettime (Depends-on): Add extensions module.
13402         * modules/nanosleep (Depends-on): Likewise.
13403         * modules/settime (Depends-on): Likewise.
13404
13405 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
13406
13407         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
13408         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
13409         pedantically.
13410         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
13411         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
13412
13413         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
13414         not "==".  Reported by Ralf Wildenhues.
13415
13416 2006-03-01  Karl Berry  <karl@gnu.org>
13417
13418         * doc/Copyright/request-*: new files, synced from gnuorg.
13419
13420 2006-03-01  Karl Berry  <karl@gnu.org>
13421
13422         * config/srclist.txt (Copyright/*): new entries.
13423
13424 2006-02-28  Simon Josefsson  <jas@extundo.com>
13425
13426         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
13427
13428 2006-02-27  Simon Josefsson  <jas@extundo.com>
13429
13430         * lib/base64.h: Indent #define's.  From Jim Meyering
13431         <jim@meyering.net>.
13432
13433 2006-02-27  Jim Meyering  <jim@meyering.net>
13434
13435         Revert the change of 2006-02-24, so these files can continue
13436         to be sync'd from gettext.
13437         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
13438         of `config.h'.
13439
13440 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
13441
13442         * modules/intprops: New file.
13443         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
13444         Add intprops.
13445         * modules/getloadavg (Files): Remove lib/intprops.h.
13446         (Depends-on): Add intprops.
13447         * modules/human: Likewise.
13448         * modules/inttostr: Likewise.
13449         * modules/openat: Likewise.
13450         * modules/sig2str: Likewise.
13451         * modules/userspec: Likewise.
13452         * modules/utimecmp: Likewise.
13453         * modules/xnanosleep: Likewise.
13454         * modules/xstrtol: Likewise.
13455
13456 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
13457
13458         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
13459         * modules/lock-tests (TESTS): Use $(EXEEXT).
13460         * modules/tls-tests: Likewise.
13461         * modules/argp-tests: Likewise.
13462         (check_PROGRAMS): New var, replacing...
13463         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
13464
13465 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13466
13467         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
13468         `config.h'.
13469
13470 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
13471
13472         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
13473
13474 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
13475
13476         Sync from coreutils.
13477         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
13478         gl_CHDIR_SAFER.
13479
13480 2006-02-22  Jim Meyering  <jim@meyering.net>
13481
13482         Sync from coreutils.
13483         * m4/chdir-safer.m4: New file.
13484
13485 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
13486
13487         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
13488         AT_FDCWD exceeds INT_MAX.
13489         * lib/openat.h (AT_FDCWD): Likewise.
13490
13491 2006-02-17  Eric Blake  <address@hidden>
13492
13493         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
13494
13495 2006-02-16  Simon Josefsson  <jas@extundo.com>
13496
13497         * modules/getaddrinfo (Depends-on): Add sys_socket.
13498
13499 2006-02-15  Simon Josefsson  <jas@extundo.com>
13500
13501         * build-aux/maint.mk: Add dsyntax-check rule.
13502
13503 2006-02-15  Eric Blake  <ebb9@byu.net>
13504
13505         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
13506         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
13507         'present but cannot compile' warnings on cygwin.
13508         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
13509         use ws2tcpip.h if sys/socket.h works.
13510         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
13511         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
13512
13513 2006-02-14  Simon Josefsson  <jas@extundo.com>
13514
13515         * modules/maintainer-makefile (Files): Rename.
13516
13517         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
13518         and (the local) Makefile.cfg to maint-cfg.mk.
13519
13520         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
13521         to the latter.
13522
13523         * modules/maintainer-makefile: New module.
13524
13525         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
13526         severaly stripped to make it possible to build it up from scratch
13527         with reliable tests.
13528
13529         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
13530         fixes to permit overriding the default actions when configure and
13531         makefile are not available.
13532
13533 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
13534
13535         Sync from coreutils.
13536         * modules/lstat (Depends-on): Don't depend on xalloc.
13537         (License): Change from GPL to LGPL, since this is now simply a
13538         replacement for a libc function.
13539
13540 2006-02-14  Jim Meyering  <jim@meyering.net>
13541
13542         Sync from coreutils.
13543
13544         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
13545         failure on deficient systems, and simplify gnulib lgpl dependencies.
13546         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
13547         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
13548
13549         * lib/xalloc-die.c: Remove unused definition of N_.
13550
13551 2006-02-14  Jim Meyering  <jim@meyering.net>
13552
13553         Sync from coreutils.
13554         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
13555         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
13556         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
13557         double-quote uses of that variable, to accommodate the rare case in
13558         which getmntent is available in none of the libraries checked.  This
13559         happens at least on FreeBSD 5.0.
13560
13561 2006-02-13  Simon Josefsson  <jas@extundo.com>
13562
13563         * gnulib-tool (Usage): Fix --import, from
13564         karl@freefriends.org (Karl Berry).
13565
13566 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
13567
13568         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
13569
13570 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
13571
13572         * lib/argp-namefrob.h: Restore changes accidentally lost during the
13573         "autoupdate" on 2005-12-12.
13574
13575 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
13576
13577         * modules/closeout (Depends-on): Remove atexit.
13578
13579 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
13580
13581         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
13582         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
13583
13584 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
13585
13586         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
13587         __EXTENSIONS__ if this causes compilation to fail.  Problem
13588         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
13589         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
13590
13591 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
13592
13593         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
13594         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
13595         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
13596         All uses changed.
13597
13598 2006-01-26  Simon Josefsson  <jas@extundo.com>
13599
13600         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
13601         prototype is visible on mingw32.
13602
13603         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
13604         for mingw32.
13605
13606         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
13607         mingw32).
13608
13609 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
13610
13611         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
13612         attempt to open for write; this always fails, at least on POSIX
13613         hosts.  This reinstates the 2006-01-09 change, which was
13614         inadvertently removed.
13615
13616 2006-01-26  Bruno Haible  <bruno@clisp.org>
13617
13618         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
13619         Reported by Paul Eggert.
13620
13621 2006-01-26  Bruno Haible  <bruno@clisp.org>
13622             Paul Eggert  <eggert@cs.ucla.edu>
13623
13624         * lib/stdbool_.h (_Bool)
13625         [(! (defined __cplusplus || defined __BEOS__)
13626           && !defined __GNUC__
13627           && !(defined __HP_cc || defined __xlc__
13628                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
13629                || defined __sgi))]:
13630         #define to signed char in these cases too; this simplifies
13631         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
13632         etc., separately) and makes it more conservative.
13633
13634 2006-01-25  Simon Josefsson  <jas@extundo.com>
13635
13636         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
13637         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
13638         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
13639
13640 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
13641
13642         * lib/argp-namefrob.h: Bugfix. Remove stray #
13643
13644 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
13645
13646         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
13647         so that we test the test.
13648         Check for yet another HP-UX cc bug involving *bool |= bool.
13649
13650 2006-01-25  Karl Berry  <karl@gnu.org>
13651
13652         * config/srclist.txt (vasnprintf.c): sync lost.
13653
13654 2006-01-25  Jim Meyering  <jim@meyering.net>
13655
13656         Sync from the stable (b5) branch of coreutils:
13657
13658         * lib/fts.c (fts_children): Don't let close() clobber errno from
13659         failed fchdir().
13660
13661         * lib/fts.c (fts_stat): When following a symlink-to-directory,
13662         don't necessarily interpret stat-fails+lstat-succeeds as indicating
13663         a dangling symlink.  That can also happen at least for ELOOP.
13664         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
13665         FYI, this bug predates the inclusion of fts.c in coreutils.
13666
13667         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
13668         in their own block, so pre-c99 compilers don't object.
13669
13670         Avoid the double-free (first in fts_read, second in fts_close) that
13671         would occur when an `active' directory is made inaccessible (e.g.,
13672         via chmod a-x) during a traversal.
13673         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
13674         before returning.  Reproduce this failure by
13675         mkdir -p a/b; cd a; chmod a-x . b
13676         Reported by Stavros Passas.
13677
13678 2006-01-25  Jim Meyering  <jim@meyering.net>
13679
13680         * lib/fileblocks.c: Remove more useless parentheses.
13681         * lib/readutmp.h: Likewise.
13682
13683 2006-01-25  Bruno Haible  <bruno@clisp.org>
13684
13685         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
13686         warnings.
13687         Reported by Paul Eggert.
13688
13689 2006-01-25  Bruno Haible  <bruno@clisp.org>
13690
13691         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
13692         rid of a trap command. For Solaris sh.
13693         Reported by Mark D. Baushke <mdb@gnu.org>.
13694
13695 2006-01-24  Simon Josefsson  <jas@extundo.com>
13696
13697         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
13698         Bruno.
13699
13700 2006-01-24  Karl Berry  <karl@gnu.org>
13701
13702         * config/srclist.txt (argp-namefrob.h): sync lost.
13703
13704 2006-01-24  Jim Meyering  <jim@meyering.net>
13705
13706         * modules/openat (Files): Add lib/intprops.h.
13707         From Mark D. Baushke.
13708
13709 2006-01-24  Jim Meyering  <jim@meyering.net>
13710
13711         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
13712         Reported by Mark D. Baushke.
13713
13714 2006-01-24  Jim Meyering  <jim@meyering.net>
13715
13716         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
13717
13718 2006-01-24  Bruno Haible  <bruno@clisp.org>
13719
13720         * modules/strnlen (Maintainer): Change from glibc to all.
13721
13722 2006-01-24  Bruno Haible  <bruno@clisp.org>
13723
13724         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
13725         Patch by Paul Eggert.
13726
13727 2006-01-24  Bruno Haible  <bruno@clisp.org>
13728
13729         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
13730         already has it.
13731         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
13732         2005-11-26.
13733
13734         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
13735         'signed char' to avoid problems with the built-in _Bool type.
13736         Reported by Paul Eggert on 2005-11-26.
13737
13738 2006-01-24  Bruno Haible  <bruno@clisp.org>
13739
13740         * gnulib-tool (func_import): Avoid constructing complicated sed
13741         expressions inside backquote.
13742         Report and solution by Mark D. Baushke <mdb@gnu.org>.
13743
13744 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
13745
13746         These changes imported from libc.
13747         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
13748         test and two separate function calls.
13749         * lib/strndup.c (__strndup): Add libc_hidden_def.
13750
13751 2006-01-23  Simon Josefsson  <jas@extundo.com>
13752
13753         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
13754         Remove the test_*_SOURCES variable: automake infers it by default.
13755         * modules/tls-tests: Likewise.
13756
13757 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13758
13759         Work around porting bugs reported by Dieter in
13760         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
13761         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
13762         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
13763         Include "getopt.h" first, to check interface.
13764         (getenv): Declare only if defined HAVE_DECL_GETENV &&
13765         !HAVE_DECL_GETENV.
13766         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
13767         (__strndup): Revert to K&R-style function dfns, the glibc style.
13768         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
13769         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
13770         Include strnlen.h first, to get prototype properly.
13771         (strnlen): Renamed from __strnlen.
13772         Remove weak alias.
13773
13774 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13775
13776         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
13777
13778 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
13779
13780         * config/srclist.txt: Adjust to reflect glibc reorganization.
13781         This affects only comments.
13782
13783 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
13784
13785          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
13786          Reported by Bruce Korb <bkorb@gnu.org>.
13787
13788 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
13789
13790         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
13791         to pacify gcc -Wswitch-default.
13792
13793 2006-01-22  Bruno Haible  <bruno@clisp.org>
13794
13795         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
13796         temporary buffer for sprintf, take into account the precision also
13797         for 'd', 'i', 'u', 'o', 'x', 'X'.
13798
13799 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
13800
13801         * modules/argp-tests: New module
13802         * tests/test-argp.c: New file
13803         * tests/test-argp-2.sh: New file
13804
13805 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
13806
13807         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
13808         (__argp_base_name): Removed
13809         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
13810         typo.
13811         (__argp_base_name): Provide macro definition or extern declaration
13812         depending on the configuration
13813
13814 2006-01-20  Simon Josefsson  <jas@extundo.com>
13815
13816         * modules/inet_ntop (Depends-on): Depend on sys_socket.
13817
13818 2006-01-20  Simon Josefsson  <jas@extundo.com>
13819
13820         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
13821
13822 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
13823
13824         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
13825         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
13826         Suggested by Bruno Haible.
13827
13828 2006-01-20  Karl Berry  <karl@gnu.org>
13829
13830         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
13831         until changes propagate, I guess.
13832
13833 2006-01-19  Simon Josefsson  <jas@extundo.com>
13834
13835         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
13836
13837 2006-01-19  Simon Josefsson  <jas@extundo.com>
13838
13839         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
13840
13841 2006-01-19  Simon Josefsson  <jas@extundo.com>
13842
13843         * gnulib-tool: Set check_PROGRAMS.
13844
13845         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
13846         modules/des-tests, modules/gc-arcfour-tests,
13847         modules/gc-arctwo-tests, modules/gc-des-tests,
13848         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
13849         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
13850         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
13851         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
13852         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
13853         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
13854         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
13855         test_*_SOURCES.
13856
13857 2006-01-18  Simon Josefsson  <jas@extundo.com>
13858
13859         * modules/socklen (Depends-on): Depend on sys_socket.
13860
13861 2006-01-18  Simon Josefsson  <jas@extundo.com>
13862
13863         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
13864         modules/des-tests, modules/gc-arcfour-tests,
13865         modules/gc-arctwo-tests, modules/gc-des-tests,
13866         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
13867         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
13868         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
13869         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
13870         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
13871         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
13872         $(EXEEXT) to automake TESTS variable, for mingw32.
13873
13874 2006-01-17  Simon Josefsson  <jas@extundo.com>
13875
13876         * modules/socklen (Include): Need sys/socket.h.
13877
13878 2006-01-17  Bruno Haible  <bruno@clisp.org>
13879
13880         * modules/ssize_t (Include): Add <sys/types.h>.
13881
13882 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
13883
13884         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
13885         it's not portable and it doesn't work with cross-compiles.
13886         Problem reported by Bruno Haible.  Fix missing-$ typo in
13887         'test "gl_cv_ignore_unused_libraries" ...' that prevented
13888         -zignore from being used with Sun's C compiler.
13889
13890 2006-01-12  Simon Josefsson  <jas@extundo.com>
13891
13892         * lib/base64.c: Fix warning, reported by Bruno Haible
13893         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
13894
13895 2006-01-12  Bruno Haible  <bruno@clisp.org>
13896
13897         * modules/ldd: New file.
13898         * build-aux/ldd.sh.in: New file.
13899         * MODULES.html.sh (Support for building libraries and executables): Add
13900         ldd.
13901
13902 2006-01-12  Bruno Haible  <bruno@clisp.org>
13903
13904         * m4/ldd.m4: New file.
13905
13906 2006-01-12  Bruno Haible  <bruno@clisp.org>
13907
13908         * gnulib-tool (func_import, func_create_testdir): Don't go into an
13909         endless loop while replacing $auxdir with build-aux.
13910
13911 2006-01-11  Simon Josefsson  <jas@extundo.com>
13912
13913         * lib/stdint_.h (SIZE_MAX): Add missing (.
13914
13915 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
13916
13917         Sync from coreutils.
13918         * lib/md5.c: Fix commentary typos.
13919         (alignof, UNALIGNED_P): No need for a GCC-specific version.
13920         * lib/md5.h (__attribute__): Remove; unused.
13921         * lib/sha1.c: Fix commentary to match md5 better.
13922         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
13923         so that we don't need to worry about alignment.  All uses changed.
13924         This merges the 2005-10-28 md5 change into sha1.
13925
13926 2006-01-11  Jim Meyering  <jim@meyering.net>
13927
13928         Sync from coreutils.
13929         * lib/md5.c (OP): Fix spacing.
13930
13931 2006-01-11  Bruno Haible  <bruno@clisp.org>
13932
13933         Ensure automatic ordering between gl_LOCK and gl_ARGP.
13934         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
13935         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
13936
13937 2006-01-11  Bruno Haible  <bruno@clisp.org>
13938
13939         Ensure automatic ordering between gl_LOCK and gl_ARGP.
13940         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
13941         the "early" section as well.
13942
13943 2006-01-11  Bruno Haible  <bruno@clisp.org>
13944
13945         Avoid "ar: no archive members specified" error on MacOS X.
13946         * gnulib-tool (func_modules_add_dummy): New function.
13947         (func_import, func_create_testdir): Invoke it.
13948
13949 2006-01-11  Bruno Haible  <bruno@clisp.org>
13950
13951         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
13952         with $auxdir in AC_CONFIG_FILES statements.
13953
13954 2006-01-11  Bruno Haible  <bruno@clisp.org>
13955
13956         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
13957         Initialize also noinst_HEADERS to empty.
13958
13959 2006-01-11  Bruno Haible  <bruno@clisp.org>
13960
13961         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
13962         variables.
13963         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
13964         autoreconf.
13965
13966 2006-01-11  Bruno Haible  <bruno@clisp.org>
13967
13968         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
13969         overridable by the user.
13970         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13971
13972 2006-01-10  Simon Josefsson  <jas@extundo.com>
13973
13974         * modules/sys_socket: New file.
13975
13976 2006-01-10  Simon Josefsson  <jas@extundo.com>
13977
13978         * m4/sys_socket_h.m4: New file.
13979
13980 2006-01-10  Simon Josefsson  <jas@extundo.com>
13981
13982         * lib/socket_.h: New file.
13983
13984 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13985
13986         * modules/readutmp (Maintainer): Add myself.
13987
13988 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13989
13990         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
13991         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
13992         People who are still concerned with buggy memcmp implementations
13993         can invoke gl_FUNC_MEMCMP themselves.
13994
13995 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
13996
13997         * lib/regex_internal.h (BITSET_WORD_BITS):
13998         Work around a bug in 64-bit PGC (before version 6.1-2), where the
13999         preprocessor mishandles large unsigned values as if they were signed.
14000         Problem reported by Claudio Fontana in
14001         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
14002
14003 2006-01-10  Jim Meyering  <jim@meyering.net>
14004
14005         Avoid the double-free (first in fts_read, second in fts_close) that
14006         would occur when an `active' directory is made inaccessible (e.g.,
14007         via chmod a-x) during a traversal.
14008         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
14009         before returning.  Reproduce this failure by
14010         mkdir -p a/b; cd a; chmod a-x . b
14011         Reported by Stavros Passas.
14012
14013         Sync from coreutils.
14014         * lib/sha1.c: Tweak grammar in a comment.
14015
14016 2006-01-10  Jim Meyering  <jim@meyering.net>
14017
14018         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
14019         Patch by Joerg Sonnenberger.
14020
14021 2006-01-10  Bruno Haible  <bruno@clisp.org>
14022
14023         * modules/readutmp: Depend on module free.
14024         * modules/strtok_r: Depend on module restrict.
14025
14026 2006-01-10  Bruno Haible  <bruno@clisp.org>
14027
14028         * modules/gettext (configure.ac): Add an invocation of
14029         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
14030
14031 2006-01-10  Bruno Haible  <bruno@clisp.org>
14032
14033         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
14034         Reported by Werner Lemberg <wl@gnu.org>.
14035
14036 2006-01-10  Bruno Haible  <bruno@clisp.org>
14037
14038         * lib/localcharset.c: Update from GNU gettext.
14039
14040 2006-01-10  Bruno Haible  <bruno@clisp.org>
14041
14042         * lib/argp.h (__const): Remove macro. Use const instead.
14043         * lib/argp-fmtstream.h (__const): Likewise.
14044         * lib/glob_.h (__const): Remove macro.
14045         * lib/glob-libc.h: Use const instead of __const.
14046
14047 2006-01-10  Bruno Haible  <bruno@clisp.org>
14048
14049         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
14050         variable.
14051         Needed to avoid an automake error regarding the 'gettext' module.
14052
14053 2006-01-09  Simon Josefsson  <jas@extundo.com>
14054
14055         * modules/inet_ntop (Depends-on): Add restrict.
14056
14057 2006-01-09  Simon Josefsson  <jas@extundo.com>
14058
14059         * modules/gc-rijndael-tests (License): Put under LGPL.
14060
14061         * modules/gc-des-tests (License): Likewise.
14062
14063         * modules/gc-arcfour-tests (License): Likewise.
14064
14065         * modules/gc-arctwo-tests (License): Likewise.
14066
14067         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
14068
14069         * modules/gc-hmac-sha1-tests (Files): Likewise.
14070
14071         * modules/gc-hmac-md5-tests (License): Likewise.
14072
14073         * modules/gc-sha1-tests (License): Likewise.
14074
14075         * modules/gc-md5-tests (License): Likewise.
14076
14077         * modules/gc-md4-tests (License): Likewise.
14078
14079         * modules/gc-md2-tests (License): Likewise.
14080
14081         * modules/gc-tests (License): Likewise.
14082
14083         * modules/des-tests (License): Likewise.
14084
14085         * modules/md4-tests (License): Likewise.
14086
14087         * modules/md2-tests (License): Likewise.
14088
14089 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
14090
14091         Sync from coreutils:
14092
14093         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
14094         * modules/lib-ignore: New file.
14095         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
14096         chdir-safer.m4, lchmod.m4.
14097         * modules/openat: Add mkdirat.c, openat-priv.h.
14098
14099 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
14100
14101         Sync from coreutils.
14102         * m4/lib-ignore.m4: New file.
14103         * m4/lchmod.m4: New file.
14104
14105 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
14106
14107         Sync from coreutils.
14108         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
14109         for write access: POSIX says that must fail.
14110         * lib/fts.c (diropen): Likewise.
14111         * lib/save-cwd.c (save_cwd): Likewise.
14112         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
14113         well, for minor improvements on hosts that lack O_DIRECTORY.
14114         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
14115         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
14116         Fall back on chown if open failed with EACCES.
14117
14118         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
14119         Report an error at compile-time if only a 1-second nominal clock
14120         resolution is found.
14121
14122         * lib/lchmod.h: New file.
14123         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
14124         (make_dir_parents): Use lchown rather than chown, and
14125         lchmod rather than chmod.
14126
14127         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
14128         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
14129         "proc" reported by n0dalus.
14130
14131         * lib/mountlist.c: Include <limits.h>.
14132         (dev_from_mount_options)
14133         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
14134         New function.  It no longer assumes "dev=" has the System V meaning
14135         on Linux (since it doesn't).  It also parses "dev=" more carefully.
14136         (read_file_system_list)
14137         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
14138         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
14139         dev= in that case.
14140
14141         * lib/posixtm.h (PDS_PRE_2000): New macro.
14142         * lib/posixtm.c (year): Arg is now syntax_bits rather than
14143         allow_century.  All usages changed.  Reject dates outside the range
14144         1969-1999 if PDS_PRE_2000 is used.
14145
14146 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
14147
14148         Sync from coreutils.
14149         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
14150         (Time of day items): Mention the possibility of leap seconds.
14151         Problem reported by Dr. David Alan Gilbert.
14152
14153 2006-01-09  Jim Meyering  <jim@meyering.net>
14154
14155         Sync from coreutils.
14156
14157         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
14158
14159         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
14160
14161         * lib/modechange.c (mode_compile): Reject an invalid mode string
14162         that starts with an octal digit.  From Andreas Gruenbacher.
14163
14164         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
14165         and dup to open_safer and dup_safer, respectively.
14166         (openat_permissive): Fix typo in comment.
14167
14168         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
14169         "gettext.h"; either no longer needed or are guaranteed by openat.h.
14170         (_): Remove; no longer needed.
14171         (openat): Renamed from rpl_openat; no need for rpl_openat
14172         since openat.h renames openat for us.
14173         Replace most of the body with a call to openat_permissive,
14174         to avoid duplicate code.
14175         Port to (probably hypothetical) environments were mode_t is
14176         wider than int.
14177         (openat_permissive): Require mode arg, so that we can check
14178         types better.  Put it just after flags.  Change cwd failure
14179         indicator from pointer-to-bool to pointer-to-errno-value.
14180         All callers changed.
14181         Invoke openat_save_fail and/or openat_restore_fail if
14182         cwd_errno is null, so that openat can call us.
14183         (openat_permissive, fdopendir, fstatat, unlinkat):
14184         Simplify errno handling to avoid some duplicate code,
14185         as it's OK to set errno on success.
14186         * lib/openat.h: Revamp code so that function macros depend on
14187         __OPENAT_PREFIX only, not also on AT_FDCWD.
14188         (openat_ro): Remove.  Caller changed to use openat_permissive.
14189         (openat_permissive): Now a macro, if not a function.
14190         (openat_restore_fail, openat_save_fail): Now always functions,
14191         since mkdirat needs them even if __OPENAT_PREFIX is defined.
14192
14193         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
14194         and openat.c.
14195         * lib/mkdirat.c: Include openat-priv.h.
14196         Remove definitions of macros defined therein.
14197         * lib/openat.c: Likewise.
14198
14199         * lib/mkdirat.c (mkdirat): New file and function.
14200         * lib/openat.h (mkdirat): Declare.
14201
14202         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
14203
14204         * lib/openat.h (openat_permissive): Declare.
14205         (openat_ro): Define.
14206
14207         * lib/openat.c (EXPECTED_ERRNO): New macro.
14208         (openat_permissive): New function -- used in remove.c rewrite.
14209         (all functions): Set errno just before returning, only if there
14210         was an actual failure.
14211         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
14212
14213         Emulate openat-family functions using Linux's procfs, if possible.
14214         Idea and some code based on Ulrich Drepper's glibc changes.
14215
14216         * lib/openat.c: (BUILD_PROC_NAME): New macro.
14217         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
14218         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
14219         before falling back on save_cwd and restore_cwd.
14220         (fdopendir, fstatat, unlinkat): Likewise.
14221
14222         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
14223         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
14224
14225         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
14226         as second argument to va_arg.  Otherwise, some versions of gcc
14227         warn that `if this code is reached, the program will abort'.
14228
14229 2006-01-09  Jim Meyering  <jim@meyering.net>
14230
14231         Sync from coreutils.
14232         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
14233         Require openat-priv.h.
14234
14235 2006-01-09  Bruno Haible  <bruno@clisp.org>
14236
14237         * modules/strnlen (Include): Use strnlen.h.
14238
14239 2006-01-09  Bruno Haible  <bruno@clisp.org>
14240
14241         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
14242
14243 2006-01-09  Bruno Haible  <bruno@clisp.org>
14244
14245         * lib/sysexit_.h (EX_OK): New macro.
14246         Suggested by Martin Lambers <marlam@marlam.de>.
14247
14248 2006-01-09  Bruno Haible  <bruno@clisp.org>
14249
14250         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
14251         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
14252
14253 2006-01-09  Bruno Haible  <bruno@clisp.org>
14254
14255         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
14256         numbers.
14257
14258 2006-01-09  Bruno Haible  <bruno@clisp.org>
14259
14260         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
14261         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
14262         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
14263         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
14264
14265 2006-01-09  Bruno Haible  <bruno@clisp.org>
14266
14267         * build-aux/javacomp.sh.in: New file, moved from lib/.
14268         * modules/javacomp-script (Files): Update.
14269         (configure.ac): Add AC_CONFIG_FILES invocation.
14270         (EXTRA_DIST): Remove variable.
14271
14272         * build-aux/javaexec.sh.in: New file, moved from lib/.
14273         * modules/javaexec (Files): Update.
14274         (configure.ac): Add AC_CONFIG_FILES invocation.
14275         (EXTRA_DIST): Remove javaexec.sh.in.
14276
14277         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
14278         * modules/csharpcomp-script (Files): Update.
14279         (configure.ac): Add AC_CONFIG_FILES invocation.
14280         (EXTRA_DIST): Remove variable.
14281
14282         * build-aux/csharpexec.sh.in: New file, moved from lib/.
14283         * modules/csharpexec (Files): Update.
14284         (configure.ac): Add AC_CONFIG_FILES invocation.
14285         (EXTRA_DIST): Remove csharpexec.sh.in.
14286
14287 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
14288
14289         Sync from coreutils.
14290
14291         Add POSIX ACL support
14292         * lib/acl.h (copy_acl, set_acl): Add declarations.
14293         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
14294         systems other than Linux.
14295         (chmod_or_fchmod): New function: use fchmod when possible,
14296         and chmod otherwise.
14297         (file_has_acl): Add a POSIX ACL implementation, with a
14298         Linux-specific subcase.
14299         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
14300         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
14301         acls are unsupported.
14302         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
14303         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
14304         are unsupported.
14305
14306 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
14307
14308         Sync from coreutils.
14309         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
14310
14311 2006-01-07  Bruno Haible  <bruno@clisp.org>
14312
14313         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
14314         gl_EARLY.
14315
14316 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
14317
14318         * lib/strftime.c (tzname): Don't declare if it is already #defined.
14319         Problem reported for Mingw by Mark Junker.
14320
14321 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
14322
14323         * README: Gnulib normally doesn't generate a tarball.
14324
14325 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
14326
14327         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
14328         long int, not int, for nanosecond counts, so that people who are
14329         used to POSIX struct timespec won't be surprised.  Reported by Jim
14330         Meyering.
14331
14332 2005-12-28  Bruno Haible  <bruno@clisp.org>
14333
14334         * build-aux/config.rpath: Update from GNU gettext.
14335
14336 2005-12-16  Jim Meyering  <jim@meyering.net>
14337
14338         * modules/fprintftime: New module.
14339         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
14340
14341 2005-12-16  Jim Meyering  <jim@meyering.net>
14342
14343         * m4/fprintftime.m4: New file.
14344
14345 2005-12-16  Jim Meyering  <jim@meyering.net>
14346
14347         * lib/fprintftime.c, lib/fprintftime.h: New files.
14348
14349 2005-12-15  Simon Josefsson  <jas@extundo.com>
14350
14351         * modules/socklen (configure.ac): Fix M4 macro name, to align with
14352         new m4/socklen.m4.
14353
14354 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
14355
14356         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
14357         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
14358
14359 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
14360
14361         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
14362         * lib/argp-help.c (fill_in_uparams): Check if the constructed
14363         struct uparams is valid. Fall back to the default values if it is
14364         not.
14365
14366 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
14367
14368         * modules/argp (Files): Add argp-pin.c
14369         (Depends-on): dirname
14370         (lib_SOURCES): Add argp-pin.c
14371
14372 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
14373
14374         * m4/argp.m4:  Check if program_invocation_name and
14375         program_invocation_short_name are declared and define appropriate
14376         macros if they are not.
14377
14378 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
14379
14380         * lib/argp-help.c (__argp_base_name): New function
14381         (__argp_short_program_name): Rewrite using __argp_base_name
14382         * lib/argp-namefrob.h: Define program_invocation_name and
14383         program_invocation_short_name if requested
14384         (__argp_base_name): Add prototype
14385         * lib/argp-parse.c (argp_def): Use gettext wrappers
14386         (argp_default_parser): Use __argp_base_name
14387         * lib/argp-pin.c: New file. Defines program_invocation_name and
14388         program_invocation_short_name on systems that lack them.
14389
14390 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
14391
14392         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
14393         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
14394         porting problem reported by Georg Schwarz in
14395         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
14396
14397 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
14398
14399         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
14400         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
14401         porting problem reported by Georg Schwarz in
14402         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
14403
14404 2005-12-05  Bruno Haible  <bruno@clisp.org>
14405
14406         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
14407         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
14408         Reported by Mark Junker <mjscod@gmx.de>.
14409
14410 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
14411
14412         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
14413         Use implementation from Albert Chin, with some
14414         comments/corrections by Stepan Kasal and myself.
14415
14416 2005-12-02  Bruno Haible  <bruno@clisp.org>
14417
14418         * gnulib-tool (func_import): Accept GPLed build tool modules when
14419         --lgpl is given.
14420         * modules/csharpcomp-script: New file.
14421         * modules/csharpcomp: Depend on it.
14422         * modules/javacomp-script: New file.
14423         * modules/javacomp: Depend on it.
14424         Suggested by Simon Josefsson.
14425
14426 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
14427
14428         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
14429         statement, to work around an HP-UX 10.20 compiler bug reported by
14430         Peter O'Gorman.
14431
14432 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
14433
14434         * modules/savedir (Depends-on): Add openat.
14435
14436 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
14437
14438         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
14439         (uintmax_t) [defined uintmax_t]: Do not declare.
14440         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
14441         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
14442         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
14443         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
14444         sake of portability to weird hosts that C allows (though we don't
14445         know of any practical examples).
14446
14447         * lib/savedir.h (fdsavedir): New decl.
14448         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
14449         contains most of the former guts of savedir.
14450         (savedir): Use savedirstream.
14451         Include "openat.h".
14452
14453 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
14454
14455         * modules/obstack (Files): Add m4/ulonglong.m4.
14456         Problem reported by Davide Angelocola.
14457
14458 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
14459
14460         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
14461         coreutils no longer futzes with rounding modes.
14462
14463 2005-11-14  Jim Meyering  <jim@meyering.net>
14464
14465         * lib/mkstemp-safer.c: Include <config.h>, required for possible
14466         replacement of mkstemp.
14467
14468 2005-11-10  Simon Josefsson  <jas@extundo.com>
14469
14470         * lib/readline.c: Remove EOL.
14471
14472 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14473
14474         * modules/gethrxtime (Depends-on): Add gettime.
14475
14476 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14477
14478         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
14479         or gettimeofday; no longer needed.
14480
14481 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
14482
14483         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
14484         time business.
14485         (gethrxtime) [! (HAVE_NANOUPTIME
14486         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
14487         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
14488         our own approximation.
14489
14490 2005-11-08  Eric Blake  <ebb9@byu.net>
14491
14492         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
14493
14494 2005-11-08  Eric Blake  <ebb9@byu.net>
14495
14496         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
14497
14498 2005-11-04  Bruno Haible  <bruno@clisp.org>
14499
14500         * gnulib-tool: Implement --update mode.
14501
14502 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
14503
14504         Fix porting problem reported by Theodoros V. Kalamatianos.
14505         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
14506         Don't assume that futimes failing means we must fail.
14507
14508 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
14509
14510         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
14511         variables to suggest the intended function of the PATH_MAX check.
14512
14513 2005-10-30  Kean Johnston  <jkj@sco.com>
14514
14515         Trivial changes to support SCO systems.
14516         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
14517         as PATH_MAX.
14518         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
14519         where __ptr is null when no I/O is pending.
14520
14521 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
14522
14523         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
14524         leave errno alone.  Problem reported by Dmitry V. Levin.
14525
14526 2005-10-28  Simon Josefsson  <jas@extundo.com>
14527
14528         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
14529         Test more.
14530
14531         * tests/test-gc-md2.c, tests/test-md2.c: New files.
14532
14533         * modules/md2, modules/md2-tests: New files.
14534
14535 2005-10-28  Simon Josefsson  <jas@extundo.com>
14536
14537         * m4/inet_ntop.m4: More tests.
14538
14539         * m4/gc-md2.m4, md2.m4: New file.
14540
14541 2005-10-28  Simon Josefsson  <jas@extundo.com>
14542
14543         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
14544         "restrict" keywords, as per POSIX.  Protect the function
14545         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
14546         Don't use K&R prototypes.  Check the sprintf return values.
14547         Re-define EAFNOSUPPORT if not present.  Indent.
14548
14549         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
14550         suggested by Bruno Haible <bruno@clisp.org>.
14551
14552         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
14553
14554         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
14555
14556         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
14557         libgcrypt).
14558
14559         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
14560
14561         * lib/md2.h, lib/md2.c: New files.
14562
14563 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
14564
14565         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
14566         errno alone.  Problem reported by Frederic Jolliton.
14567
14568 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
14569
14570         * modules/verify (License): Change from GPL to LGPL.  This is a
14571         tiny module and there are apparently near-equivalents that are
14572         under the BSD license.
14573
14574 2005-10-24  Simon Josefsson  <jas@extundo.com>
14575
14576         * modules/sha1: Relicense to LGPL.
14577
14578 2005-10-24  Simon Josefsson  <jas@extundo.com>
14579
14580         * lib/md4.h: Shrink buffer size, now that we changed the type.
14581
14582 2005-10-23  Simon Josefsson  <jas@extundo.com>
14583
14584         * gnulib-tool (func_import): Fix --tests-base.
14585
14586 2005-10-22  Simon Josefsson  <jas@extundo.com>
14587
14588         * modules/arcfour (Depends-on): Need stdint.
14589
14590 2005-10-22  Simon Josefsson  <jas@extundo.com>
14591
14592         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
14593         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
14594
14595 2005-10-22  Simon Josefsson  <jas@extundo.com>
14596
14597         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
14598         suggested by Bruno Haible <bruno@clisp.org>.
14599
14600 2005-10-22  Simon Josefsson  <jas@extundo.com>
14601
14602         * lib/crc.h: Include stddef.h, for size_t.
14603
14604 2005-10-22  Simon Josefsson  <jas@extundo.com>
14605
14606         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
14607         arcfour_context struct (simplify test vector testing in GNU
14608         Shishi).
14609
14610 2005-10-21  Simon Josefsson  <jas@extundo.com>
14611
14612         * modules/des, modules/des-tests: New files.
14613
14614         * modules/gc-des, modules/gc-des-tests: New files.
14615
14616         * tests/test-des.c, tests/test-gc-des.c: New file.
14617
14618 2005-10-21  Simon Josefsson  <jas@extundo.com>
14619
14620         * modules/arctwo, modules/arctwo-tests: New files.
14621
14622         * tests/test-arctwo.c: New file.
14623
14624         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
14625
14626         * tests/test-gc-arctwo.c: New file.
14627
14628 2005-10-21  Simon Josefsson  <jas@extundo.com>
14629
14630         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
14631         Bruno Haible <bruno@clisp.org>.
14632
14633         * m4/gc-des.m4: New file.
14634
14635 2005-10-21  Simon Josefsson  <jas@extundo.com>
14636
14637         * m4/arctwo.m4: New file.
14638
14639         * m4/gc-arctwo.m4: New file.
14640
14641 2005-10-21  Simon Josefsson  <jas@extundo.com>
14642
14643         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
14644         block.
14645
14646 2005-10-21  Simon Josefsson  <jas@extundo.com>
14647
14648         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
14649         <bruno@clisp.org>.
14650
14651         * lib/hmac-sha1.c (hmac_sha1): Likewise.
14652
14653         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
14654         Bruno Haible <bruno@clisp.org>.
14655
14656         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
14657         <bruno@clisp.org>.
14658
14659 2005-10-21  Simon Josefsson  <jas@extundo.com>
14660
14661         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
14662
14663 2005-10-21  Simon Josefsson  <jas@extundo.com>
14664
14665         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
14666
14667 2005-10-21  Simon Josefsson  <jas@extundo.com>
14668
14669         * lib/des.h, lib/des.c: New files.
14670
14671         * lib/gc-gnulib.c: Support DES.c
14672
14673 2005-10-21  Simon Josefsson  <jas@extundo.com>
14674
14675         * lib/arctwo.h, lib/arctwo.c: New files.
14676
14677         * lib/gc-gnulib.c: Support ARCTWO.
14678
14679 2005-10-21  Simon Josefsson  <jas@extundo.com>
14680
14681         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
14682         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
14683
14684 2005-10-21  Simon Josefsson  <jas@extundo.com>
14685
14686         * gnulib-tool (func_import, func_create_testdir): Define automake
14687         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
14688         Makefile.am snippet),
14689         suggested by Bruno Haible <bruno@clisp.org>.
14690
14691         * modules/gc (Makefile.am): Use it.
14692
14693 2005-10-21  Bruno Haible  <bruno@clisp.org>
14694
14695         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
14696         patch.
14697
14698 2005-10-19  Simon Josefsson  <jas@extundo.com>
14699
14700         * tests/test-gc-rijndael.c: New file.
14701
14702         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
14703
14704 2005-10-19  Simon Josefsson  <jas@extundo.com>
14705
14706         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
14707         interface too.
14708
14709 2005-10-19  Simon Josefsson  <jas@extundo.com>
14710
14711         * tests/test-gc-arcfour.c: New file.
14712
14713         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
14714
14715 2005-10-19  Simon Josefsson  <jas@extundo.com>
14716
14717         * modules/gc-md4, modules/gc-md4-tests: New file.
14718
14719         * tests/test-gc-md4.c: New file.
14720
14721 2005-10-19  Simon Josefsson  <jas@extundo.com>
14722
14723         * m4/gc-md4.m4: New file.
14724
14725 2005-10-19  Simon Josefsson  <jas@extundo.com>
14726
14727         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
14728         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
14729         <kasal@ucw.cz>.
14730
14731 2005-10-19  Simon Josefsson  <jas@extundo.com>
14732
14733         * m4/gc-arcfour.m4: New file.
14734
14735         * m4/gc-rijndael.m4: New file.
14736
14737 2005-10-19  Simon Josefsson  <jas@extundo.com>
14738
14739         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
14740
14741 2005-10-19  Simon Josefsson  <jas@extundo.com>
14742
14743         * lib/gc-gnulib.c: Support ARCFOUR.
14744
14745 2005-10-19  Simon Josefsson  <jas@extundo.com>
14746
14747         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
14748         support.
14749
14750         * lib/gc.h: Add ECB enum type.
14751
14752         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
14753
14754 2005-10-18  Simon Josefsson  <jas@extundo.com>
14755
14756         * tests/test-md5.c: New file.
14757
14758         * modules/md5-tests: New file.
14759
14760 2005-10-18  Simon Josefsson  <jas@extundo.com>
14761
14762         * tests/test-md4.c: New file.
14763
14764         * modules/md4, modules/md4-tests: New files.
14765
14766 2005-10-18  Simon Josefsson  <jas@extundo.com>
14767
14768         * m4/md4.m4: New file.
14769
14770 2005-10-18  Simon Josefsson  <jas@extundo.com>
14771
14772         * lib/md4.h, lib/md4.c: New files, based on md5.?.
14773
14774 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
14775
14776         * gnulib-tool (func_create_testdir): Omit the second check whether
14777         BUILT_SOURCES in nonempty.
14778
14779 2005-10-17  Simon Josefsson  <jas@extundo.com>
14780
14781         * tests/test-rijndael.c: New file.
14782
14783 2005-10-17  Simon Josefsson  <jas@extundo.com>
14784
14785         * modules/sha1: Depend on stdint instead of md5.
14786
14787         * modules/md5: Depend on stdint, remove uint32_t.
14788
14789 2005-10-17  Simon Josefsson  <jas@extundo.com>
14790
14791         * modules/gc-sha1-tests: New file.
14792
14793         * tests/test-gc-sha1.c: New file.
14794
14795 2005-10-17  Simon Josefsson  <jas@extundo.com>
14796
14797         * m4/md5.m4: Remove call to uint32_t.m4.
14798
14799 2005-10-17  Simon Josefsson  <jas@extundo.com>
14800
14801         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
14802
14803         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
14804         md5.h.
14805
14806         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
14807
14808         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
14809
14810 2005-10-17  Simon Josefsson  <jas@extundo.com>
14811
14812         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
14813
14814 2005-10-17  Simon Josefsson  <jas@extundo.com>
14815
14816         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
14817
14818 2005-10-17  Simon Josefsson  <jas@extundo.com>
14819
14820         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
14821
14822         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
14823
14824 2005-10-17  Bruno Haible  <bruno@clisp.org>
14825
14826         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
14827         that it can also be used in a test.
14828
14829 2005-10-16  Bruno Haible  <bruno@clisp.org>
14830
14831         * gnulib-tool (func_emit_tests_Makefile_am): Also define
14832         TESTS_ENVIRONMENT, so that individual tests can augment it.
14833
14834         * gnulib-tool (func_create_testdir): Use an intermediate target for
14835         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
14836         macros, like $(ALLOCA_H), which cannot be passed through the command
14837         line.
14838
14839 2005-10-15  Simon Josefsson  <jas@extundo.com>
14840
14841         * modules/rijndael-tests: New file.
14842
14843         * modules/rijndael: New file.
14844
14845 2005-10-15  Simon Josefsson  <jas@extundo.com>
14846
14847         * m4/rijndael.m4: New file.
14848
14849 2005-10-15  Simon Josefsson  <jas@extundo.com>
14850
14851         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
14852
14853         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
14854
14855 2005-10-14  Simon Josefsson  <jas@extundo.com>
14856
14857         * tests/test-arcfour.c: New file.
14858
14859         * modules/arcfour, modules/arcfour-tests: New files.
14860
14861 2005-10-14  Simon Josefsson  <jas@extundo.com>
14862
14863         * m4/arcfour.m4: New file.
14864
14865 2005-10-14  Simon Josefsson  <jas@extundo.com>
14866
14867         * lib/arcfour.h, lib/arcfour.c: New files.
14868
14869 2005-10-14  Roland McGrath  <roland@redhat.com>
14870
14871         Import from libc.  [BZ #1331]
14872         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
14873         macro argument.
14874         Reported by Matej Vela <vela@debian.org>.
14875
14876 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
14877
14878         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
14879         include <wchar.h>; no longer needed.
14880
14881 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
14882
14883         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
14884
14885 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
14886         and  Ulrich Drepper  <drepper@redhat.com>
14887
14888         Import from libc.
14889         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
14890         instead of inline stream orientation test and two separate
14891         function calls.  Pay no attention to USE_IN_LIBIO.
14892
14893 2005-10-13  Simon Josefsson  <jas@extundo.com>
14894
14895         * modules/gc-hmac-md5-tests: New file.
14896
14897         * tests/test-gc-hmac-sha1.c: New file.
14898
14899         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
14900
14901         * modules/gc-hmac-md5-tests: New file.
14902
14903         * tests/test-gc-md5.c: New file.
14904
14905         * modules/gc-md5-tests: New file.
14906
14907 2005-10-13  Simon Josefsson  <jas@extundo.com>
14908
14909         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
14910         Move memory allocation outside of loop.
14911
14912 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
14913
14914         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
14915         intermediate directory is in a read-only file system.  Problem
14916         reported by Eric Blake.
14917
14918 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
14919
14920         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
14921
14922 2005-10-12  Simon Josefsson  <jas@extundo.com>
14923
14924         * tests/test-hmac-sha1.c: New file.
14925
14926         * modules/hmac-sha1-tests: New file.
14927
14928         * modules/hmac-sha1: New file.
14929
14930 2005-10-12  Simon Josefsson  <jas@extundo.com>
14931
14932         * modules/gc-sha1: New file.
14933
14934 2005-10-12  Simon Josefsson  <jas@extundo.com>
14935
14936         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
14937
14938         * tests/test-gc-pbkdf2-sha1.c: New file.
14939
14940 2005-10-12  Simon Josefsson  <jas@extundo.com>
14941
14942         * modules/gc-md5, modules/gc-hmac-md5: New files.
14943
14944         * modules/gc (Files): Remove md5, memxor and hmac files.
14945
14946 2005-10-12  Simon Josefsson  <jas@extundo.com>
14947
14948         * m4/gc-pbkdf2-sha1.m4: New file.
14949
14950         * m4/gc-hmac-sha1.m4: New file.
14951
14952         * m4/gc-sha1: New file.
14953
14954         * m4/hmac-sha1.m4: New file.
14955
14956 2005-10-12  Simon Josefsson  <jas@extundo.com>
14957
14958         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
14959
14960         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
14961
14962 2005-10-12  Simon Josefsson  <jas@extundo.com>
14963
14964         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
14965         suggested by Bruno Haible <bruno@clisp.org>.
14966
14967 2005-10-12  Simon Josefsson  <jas@extundo.com>
14968
14969         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
14970
14971 2005-10-12  Simon Josefsson  <jas@extundo.com>
14972
14973         * lib/gc-pbkdf2-sha1.c: New file.
14974
14975         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
14976
14977 2005-10-12  Simon Josefsson  <jas@extundo.com>
14978
14979         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
14980
14981         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
14982
14983 2005-10-12  Simon Josefsson  <jas@extundo.com>
14984
14985         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
14986         GC_USE_HMAC_MD5, respectively.
14987
14988         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
14989         (gc_md5): Fix typo.
14990
14991         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
14992
14993         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
14994
14995         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
14996
14997 2005-10-12  Bruno Haible  <bruno@clisp.org>
14998
14999         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
15000         Reported by Stepan Kasal <kasal@ucw.cz>.
15001
15002 2005-10-11  Simon Josefsson  <jas@extundo.com>
15003
15004         * tests/test-crc.c: New file.
15005
15006         * modules/crc, modules/crc-tests: New files.
15007
15008 2005-10-11  Simon Josefsson  <jas@extundo.com>
15009
15010         * m4/crc.m4: New file.
15011
15012 2005-10-11  Simon Josefsson  <jas@extundo.com>
15013
15014         * lib/gc.h: Add gc_hash and gc_hash_buffer.
15015
15016         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
15017
15018         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
15019
15020 2005-10-11  Simon Josefsson  <jas@extundo.com>
15021
15022         * lib/crc.h, lib/crc.c: New files.
15023
15024         * lib/gc.h (gc_hash_buffer): Add doc.
15025
15026 2005-10-11  Bruno Haible  <bruno@clisp.org>
15027
15028         * modules/c-strcasestr: New file.
15029         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
15030
15031 2005-10-11  Bruno Haible  <bruno@clisp.org>
15032
15033         * modules/c-strcase: New file.
15034         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
15035
15036 2005-10-11  Bruno Haible  <bruno@clisp.org>
15037
15038         * lib/strcasecmp.c: Include limits.h.
15039         (strcasecmp): Avoid integer overflow on exotic platforms.
15040         * lib/strncasecmp.c: Include limits.h.
15041         (strncasecmp): Avoid integer overflow on exotic platforms.
15042         Reported by Paul Eggert.
15043
15044 2005-10-11  Bruno Haible  <bruno@clisp.org>
15045
15046         * lib/c-strcasestr.h: New file, from GNU gettext.
15047         * lib/c-strcasestr.c: New file, from GNU gettext.
15048
15049 2005-10-11  Bruno Haible  <bruno@clisp.org>
15050
15051         * lib/c-strcase.h: New file, from GNU gettext.
15052         * lib/c-strcasecmp.c: New file, from GNU gettext.
15053         * lib/c-strncasecmp.c: New file, from GNU gettext.
15054
15055 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
15056
15057         * modules/mempcpy (License): GPL -> LGPL.
15058         * modules/strchrnul (License): Likewise.
15059         * modules/sysexits (License): Likewise.
15060
15061 2005-10-08  Simon Josefsson  <jas@extundo.com>
15062
15063         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
15064
15065 2005-10-07  Simon Josefsson  <jas@extundo.com>
15066
15067         * m4/memxor.m4: Remove gl_C_RESTRICT call.
15068
15069 2005-10-06  Simon Josefsson  <jas@extundo.com>
15070
15071         * tests/test-hmac-md5.c: New file.
15072
15073         * modules/hmac-md5-tests: New file.
15074
15075         * modules/hmac-md5: New file.
15076
15077 2005-10-06  Simon Josefsson  <jas@extundo.com>
15078
15079         * m4/hmac-md5.m4: New file.
15080
15081         * m4/memxor.m4: Require gl_C_RESTRICT.
15082
15083 2005-10-06  Simon Josefsson  <jas@extundo.com>
15084
15085         * lib/memxor.c (memxor): Avoid casts and warnings.
15086
15087 2005-10-06  Simon Josefsson  <jas@extundo.com>
15088
15089         * lib/hmac-md5.c: New file.
15090
15091         * lib/hmac.h: New file.
15092
15093 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
15094
15095         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
15096         promotes to int, not unsigned int, to catch the AIX 5.3
15097         compiler bug.
15098
15099 2005-10-05  Simon Josefsson  <jas@extundo.com>
15100
15101         * modules/memxor: New file.
15102
15103         * modules/iconv (Files): Move config.rpath to havelib, it is used
15104         there.
15105
15106         * modules/havelib (Files): Add config.rpath.
15107
15108 2005-10-05  Simon Josefsson  <jas@extundo.com>
15109
15110         * m4/memxor.m4: New file.
15111
15112 2005-10-05  Simon Josefsson  <jas@extundo.com>
15113
15114         * lib/memxor.c (memxor): Fix compiler error.
15115
15116         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
15117         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
15118
15119         * lib/memxor.h, lib/memxor.c: New files.
15120
15121         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
15122         we assume all systems have it, suggested by Jim Meyering
15123         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
15124         any systems lack sys/socket.h; mingw32 is known to lack it, but we
15125         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
15126         same reasons.
15127
15128 2005-10-05  Simon Josefsson  <jas@extundo.com>
15129
15130         * config/srclist.txt: Add glibc bug 1423 for md5.h.
15131
15132 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
15133
15134         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
15135         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
15136         needed, since the source code now assumes these .h files.
15137
15138 2005-10-05  Derek Price  <derek@ximbiot.com>
15139
15140         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
15141
15142 2005-10-05  Bruno Haible  <bruno@clisp.org>
15143
15144         * modules/stdint (License): Change to LGPL.
15145
15146 2005-10-04  Simon Josefsson  <jas@extundo.com>
15147
15148         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
15149         D. Baushke" <mdb@gnu.org>.
15150
15151 2005-10-04  Bruno Haible  <bruno@clisp.org>
15152
15153         * lib/verify.h (verify_true): Provide alternative definition for C++.
15154
15155 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
15156
15157         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
15158         (SSIZE_MAX): New macro, if not already defined.
15159         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
15160         than 2 GiB.
15161
15162 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
15163
15164         Sync from coreutils.
15165         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
15166         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
15167         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
15168         ULLONG_MAX doesn't work with 2.7.2.1.
15169
15170 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
15171
15172         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
15173         From Ben Pfaff.
15174
15175         * modules/exclude (Depends-on): Depend on verify.
15176         * modules/strtoimax (Depends-on): Likewise.
15177         * modules/utimecmp (Depends-on): Likewise.
15178
15179 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
15180
15181         * lib/exclude.c: Include verify.h.
15182         (verify): Remove.  All callers changed to use verify.h's version.
15183         * lib/strtoimax.c: Likewise.
15184         * lib/utimecmp.c: Likewis.e
15185
15186         Sync from coreutils.
15187         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
15188         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
15189         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
15190         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
15191         bother returning ENOSYS if settimeofday or stime fails; just let
15192         them return whatever errno they want to return.
15193         * lib/utimens.c: Include unistd.h, for dup2.
15194         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
15195         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
15196
15197 2005-10-02  Jim Meyering  <jim@meyering.net>
15198
15199         Sync from coreutils.
15200         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
15201         from glibc-2.2.5 that fails for read-only files.
15202
15203 2005-10-02  Jim Meyering  <jim@meyering.net>
15204
15205         Sync from coreutils.
15206         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
15207         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
15208         `#if HAVE_CONFIG_H'.
15209         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
15210         Remove AT_FDCWD test.
15211         Do not consume the fd unless successful.
15212         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
15213         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
15214         block, so that we don't even try to compile it if settimeofday is
15215         available.  This works around a compilation failure on OSF1 V5.1,
15216         due to stime requiring a `long int*' while tv_sec is `int'.
15217
15218 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
15219
15220         Sync from coreutils.
15221         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
15222         against `yes', rather than just testing for nonempty.
15223
15224 2005-10-01  Simon Josefsson  <jas@extundo.com>
15225
15226         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
15227         and Darwin.
15228
15229         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
15230         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
15231         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
15232         freeaddrinfo and gai_strerror are declared by the POSIX headers.
15233         Check if struct addrinfo is declared.
15234
15235 2005-10-01  Simon Josefsson  <jas@extundo.com>
15236
15237         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
15238         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
15239         AI_* and EAI_* definitions.  Protect function declarations.
15240
15241 2005-10-01  Jim Meyering  <jim@meyering.net>
15242
15243         Sync from coreutils.
15244
15245         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
15246         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
15247         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
15248         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
15249         in the inet and nsl libraries.  Required on Solaris 5.7.
15250
15251 2005-10-01  Jim Meyering  <jim@meyering.net>
15252
15253         Sync from coreutils.
15254         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
15255         in the inet and nsl libraries.  Required on Solaris 5.7.
15256
15257 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
15258
15259         * lib/getdelim.c (getdelim): Remove unused variables.
15260
15261 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
15262
15263         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
15264         so that the code works even with ancient cpp.  Portability problem
15265         with GCC 2.7.2.1 reported by Thomas M.Ott.
15266
15267 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
15268
15269         * modules/regex (Depends-on): Add strcase.
15270
15271         * modules/gethostname (Licence): Change from GPL to LGPL, since
15272         gethostname.c is a trivial implementation of a standard library
15273         function.
15274         * modules/poll (License): Change from GPL to LGPL, since it's
15275         derived from LGPL code.
15276
15277 2005-09-27  Jim Meyering  <jim@meyering.net>
15278
15279         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
15280         HAVE_CONFIG_H.
15281
15282         * lib/intprops.h (signed_type_or_expr__): Define.
15283         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
15284         for unsigned types.
15285
15286 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
15287
15288         * lib/verify.h (verify_expr): Remove, replacing with:
15289         (verify_true): New macro that returns true instead of void.
15290         (verify_type__): Remove.
15291         (verify): Use verify_true rather than verify_type__.
15292
15293 2005-09-26  Bruno Haible  <bruno@clisp.org>
15294
15295         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
15296         is necessary.
15297         (lib_SOURCES): Remove mbchar.c.
15298         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
15299         (Files): Add m4/mbrtowc.m4.
15300         * modules/mbiter: Likewise.
15301         * modules/mbuiter: Likewise.
15302
15303 2005-09-26  Bruno Haible  <bruno@clisp.org>
15304
15305         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
15306         compile mbchar.c if they are not both present.
15307         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
15308         * m4/mbiter.m4 (gl_MBITER): Likewise.
15309         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
15310         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
15311         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
15312
15313 2005-09-25  Jim Meyering  <jim@meyering.net>
15314
15315         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
15316         also uses socklen_t.
15317
15318 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
15319
15320         * lib/utimens.c (ENOSYS): Define if not already defined.
15321         (futimens): Support having a null PATH if the file descriptor
15322         is nonnegative.
15323
15324         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
15325         Remove.
15326         (__attribute): Define to empty unless GCC 3.1 or later.
15327         This works around a core dump on OpenBSD 3.4, which has GCC
15328         2.95.3, which dumps core when given __attribute__(()).  It also
15329         simplifies other tests, since we really don't want to bother with
15330         worrying about which ancient version of GCC supported what.
15331         Original problem reported by Yoann Vandoorselaere, with part of
15332         the fix suggested by Derek Price.
15333
15334 2005-09-24  Jim Meyering  <jim@meyering.net>
15335
15336         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
15337         so we can once again use a positive bitfield width of 1 -- now we
15338         don't have to explain why we were using a bitfield width of 2.
15339
15340 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
15341
15342         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
15343         and similarly for the other external symbols.  Problem reported
15344         by James Gallager.
15345
15346         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
15347         bug reported by Jim Meyering.
15348
15349         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
15350         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
15351         not needed, since socklen is a prerequisite module.
15352
15353 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
15354
15355         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
15356         Problem reported by Eric Blake.
15357         (getaddrinfo): Initialize se so that it's not garbage.
15358         Redo internal storage allocation so that it doesn't make unportable
15359         assumptions about alignment.
15360         Fix a memory leak.
15361
15362         * lib/utimens.c (futimens): Use futimesat if available.
15363         Prefer it to futimes since it doesn't have the futimes bug.
15364
15365         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
15366         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
15367         Instead, declare a function that returns a pointer to an array,
15368         and use verify_type__ to declare the size of the array.
15369         Problem and germ of a solution reported by Bruno Haible.
15370         (verify_type__): Use 2, not 1, for bitfield size, to avoid
15371         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
15372
15373 2005-09-23  Jim Meyering  <jim@meyering.net>
15374
15375         Sync from coreutils.
15376         Correct build failure (socklen_t not defined) on at least
15377         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
15378         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
15379
15380 2005-09-23  Jim Meyering  <jim@meyering.net>
15381
15382         * modules/getaddrinfo (Depends-on): Add socklen.
15383
15384 2005-09-23  Bruno Haible  <bruno@clisp.org>
15385
15386         * tests/test-verify.c: New file.
15387
15388 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
15389
15390         Sync from coreutils.
15391
15392         * modules/argmatch (Depends-on): Add verify.
15393         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
15394         unistd-safer.
15395         * modules/save-cwd (Depends-on): Likewise.
15396
15397         * modules/openat (Files): Add lib/openat-die.c.
15398         (Depends-on): Remove error, exitfail.
15399         Add dirname.
15400
15401         * modules/verify: New file.
15402         * MODULES.html.sh (Diagnostics <assert.h>): New section,
15403         with "verify" module.
15404
15405 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
15406
15407         Sync from coreutils.
15408
15409         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
15410         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
15411         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
15412         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
15413         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
15414         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
15415         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
15416         Don't bother checking for string.h, stdlib.h, unistd.h.
15417         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
15418         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
15419         module's job.
15420         * m4/jm-macros.m4 (gl_MACROS): Likewise.
15421         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
15422
15423         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
15424         (gl_GETDATE): Use it.
15425
15426         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
15427
15428 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
15429
15430         Sync from coreutils.
15431
15432         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
15433         stat-time.h.
15434         * lib/argmatch.h: Include verify.h
15435         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
15436         (ARGMATCH_ASSERT): Remove; unused.
15437         * lib/canonicalize.c: Assume STDC_HEADERS.
15438         * lib/exclude.c: Include "strcase.h".
15439         * lib/regex_internal.h [!defined _LIBC]: Likewise.
15440         * lib/getusershell.c: Include stdio--.h rather than stdio.h
15441         and stdio-safer.h.
15442         (getusershell): Call fopen, not fopen_safer.
15443         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
15444         Do not include unistd-safer.h.
15445         (save_cwd): Don't call fd_safer; no longer needed
15446         now that we include fcntl--.h.
15447
15448         * lib/getdate.y (relative_time): New type.
15449         (RELATIVE_TIME_0): New constant.
15450         (parser_control): Use relative_time instead of doing it ourselves.
15451         (%union): Add new relative_time rel member.
15452         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
15453         Now typeless.
15454         (relunit, relunit_snumber): Now of type rel.
15455         (zone, rel, relunit, get_date): Adjust to above changes.
15456
15457         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
15458         Do not include unistd-safer.h.
15459         (getloadavg): Don't call fd_safer; no longer needed
15460         now that we include fcntl--.h.
15461
15462         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
15463         (make_dir_parents): Treat ENOSYS like EEXIST.
15464
15465         Improve quality of diagnostics on restore_cwd failure.
15466         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
15467         (make_dir_parents): Last arg is now int * (for errno), not bool *.
15468         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
15469         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
15470         each time through the loop.  Do not diagnose restore_cwd failure;
15471         that is the caller's job (and perhaps the caller does not care).
15472
15473         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
15474         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
15475         If the file already exists but is not a directory, don't bother
15476         to try to make its parents.
15477         Close potential file descriptor leak if we can't chdir("/") (!).
15478         Don't always return true if chdir($PWD) fails; return true only
15479         if the requested action was done successfully (except for the
15480         chdir($PWD)).
15481         Don't log final directory unless we actually made it.
15482         Refactor to avoid duplicate code to fix up permissions.
15483         Don't attempt to fix up parent permissions if chdir($PWD) fails.
15484
15485         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
15486         to make it a bit faster and (I hope) clearer.
15487         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
15488         Fix bug in formats like %2N.
15489
15490         * lib/verify.h: New file.
15491
15492 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
15493
15494         Sync from coreutils.
15495         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
15496
15497 2005-09-22  Jim Meyering  <jim@meyering.net>
15498
15499         Sync from coreutils.
15500
15501         * m4/lstat.m4 (gl_FUNC_LSTAT):
15502         Use AC_LIBSOURCES to require lstat.c and lstat.h.
15503         Remove obsolete comment.
15504         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
15505         * m4/xstrtod.m4: Likewise.
15506
15507         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
15508
15509 2005-09-22  Jim Meyering  <jim@meyering.net>
15510
15511         Sync from coreutils.
15512
15513         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
15514
15515         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
15516         the .tm_year member, since otherwise gcc-4.0 would now warn about
15517         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
15518
15519         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
15520         order to avoid an unsuppressible warning from gcc on 64-bit systems.
15521
15522         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
15523         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
15524         when run in a time zone for which daylight savings time is in effect
15525         for the starting date.
15526
15527         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
15528         stop us from restricting permissions of just-created absolute-named
15529         directories.
15530         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
15531         to restore initial working directory.
15532         * lib/mkdir-p.c (make_dir_parents): New parameter:
15533         different_working_dir, to tell caller if/when we change the working
15534         directory and are unable to return to the initial one.
15535         * lib/mkdir-p.h (make_dir_parents): Update prototype.
15536         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
15537         `return false'.  This fixes a bug introduced on 2004-07-30.
15538
15539         * lib/openat.c (fdopendir): Be sure to close the supplied
15540         file descriptor before returning.  This makes our replacement
15541         implementation a little closer to Solaris's, where fdopendir
15542         ties the file descriptor to the returned DIR* pointer.
15543         * lib/openat.c (unlinkat): New function.
15544         * lib/openat.h (unlinkat): Add prototype.
15545         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
15546         (openat_restore_fail): Rename from openat_restore_die.
15547         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
15548
15549         Provide an alternative to exiting immediately upon save_cwd or
15550         restore_cwd failure.  Now, an application can arrange e.g.,
15551         to perform a longjump in that case.
15552         * lib/openat.c: Include dirname.h.
15553         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
15554         (rpl_openat, fdopendir, fstatat): Call openat_save_die
15555         and openat_restore_die rather than calling error directly.
15556         Don't include "error.h" or "exitfail.h"; they're no longer needed.
15557
15558         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
15559         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
15560         define.
15561
15562         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
15563         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
15564                             int utc, int nanoseconds);
15565         Background:
15566         date should not have to allocate a megabyte of virtual memory to
15567         handle a format argument like +%1048575T.  When implemented with
15568         strftime, it must allocate such a buffer, use strftime to fill it
15569         in, print it, then free it.
15570         With fprintftime, it simply prints everything and exits.
15571         With no need for memory allocation, that's one fewer way to fail.
15572         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
15573         optional field width, not before, so we accept %9:z, not %:9z.
15574         (my_strftime): Be sure to use L_('x') for literals.
15575
15576         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
15577         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
15578         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
15579         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
15580         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
15581         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
15582         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
15583         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
15584         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
15585         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
15586         * lib/xgethostname.c, lib/xreadlink.c:
15587         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
15588
15589         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
15590         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
15591         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
15592         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
15593         and don't include <sys/file.h>).
15594
15595 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
15596
15597         Sync from coreutils.
15598
15599         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
15600         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
15601         [!LDAV_DONE]: Avoid unused variable warning.
15602
15603 2005-09-21  Bruno Haible  <bruno@clisp.org>
15604
15605         * lib/unicodeio.h (unicode_to_mb): New declaration.
15606
15607 2005-09-20  Derek Price  <derek@ximbiot.com>
15608
15609         * lib/getaddrinfo.c: Don't include <netdb.h> included from
15610         getaddrinfo.h.
15611
15612 2005-09-20  Bruno Haible  <bruno@clisp.org>
15613
15614         * gnulib-tool: Remove trailing slashes from the values specified for
15615         --source-base, --m4-base, --tests-base, --aux-dir.
15616         Suggested by Simon Josefsson <jas@extundo.com>.
15617
15618 2005-09-20  Bruno Haible  <bruno@clisp.org>
15619
15620         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
15621         func_modules_to_filelist, func_import, func_create_testdir): Make all
15622         sorting results locale-independent, so that gnulib-cache.m4 doesn't
15623         change when gnulib-tool is invoked in a different locale.
15624
15625 2005-09-19  Simon Josefsson  <jas@extundo.com>
15626
15627         * m4/socklen.m4: Fix typo.
15628
15629 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
15630
15631         Use a consistent style for including <config.h>.
15632         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
15633         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
15634         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
15635         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
15636         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
15637         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
15638         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
15639         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
15640         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
15641         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
15642         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
15643         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
15644         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
15645         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
15646         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
15647         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
15648         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
15649         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
15650         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
15651         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
15652         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
15653         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
15654         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
15655         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
15656         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
15657         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
15658         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
15659         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
15660         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
15661         lib/xstrtoumax.c, lib/yesno.c:
15662         Standardize inclusion of config.h.
15663         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
15664         lib/inttostr.h:  Removed inclusion of config.h from header files.
15665         * lib/inttostr.c:  Adjusted in-tree users.
15666         * lib/timespec.h: Remove superfluous warning to include config.h.
15667         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
15668         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
15669         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
15670         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
15671         config.h with HAVE_CONFIG_H.
15672
15673 2005-09-19  Jim Meyering  <jim@meyering.net>
15674
15675         * modules/pathmax (License): Change to LGPL.
15676
15677 2005-09-19  Derek Price  <derek@ximbiot.com>
15678
15679         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
15680
15681 2005-09-19  Bruno Haible  <bruno@clisp.org>
15682
15683         * gnulib-tool (import): Provide default for --tests-base.
15684
15685 2005-09-19  Bruno Haible  <bruno@clisp.org>
15686
15687         * doc/quote.texi: New file, extracted from gnulib.texi.
15688         * doc/ctime.texi: New file, extracted from gnulib.texi.
15689         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
15690         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
15691         * doc/gnulib.texi: Include them.
15692
15693 2005-09-18  Bruno Haible  <bruno@clisp.org>
15694
15695         Portability fix.
15696         * gnulib-tool (func_readlink): New function.
15697         (func_ln_if_changed): Use it.
15698
15699 2005-09-18  Bruno Haible  <bruno@clisp.org>
15700
15701         * gnulib-tool: Support --with-tests also with --import.
15702         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
15703         (func_import): Use variables $testsbase and $inctests. Emit a
15704         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
15705         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
15706         SUBDIRS += $testsdir.
15707         (func_create_testdir): Update.
15708
15709 2005-09-18  Bruno Haible  <bruno@clisp.org>
15710
15711         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
15712         instead of $dry_run.
15713         (func_cp_if_changed, func_mv_if_changed): Remove functions.
15714         (func_ln_if_changed): Don't handle dry-run here.
15715         (func_import): In dry-run mode, detect more precisely which actions
15716         would be performed, and don't use "...ing" verbs.
15717
15718 2005-09-18  Bruno Haible  <bruno@clisp.org>
15719
15720         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
15721         (func_import): Use join on two temporary files instead of three nested
15722         loops, in order to determine which files are new or old.
15723
15724 2005-09-18  Bruno Haible  <bruno@clisp.org>
15725
15726         * gnulib-tool (func_import): Comment out code that spits out the
15727         new files with --dry-run.
15728
15729 2005-09-18  Bruno Haible  <bruno@clisp.org>
15730
15731         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
15732
15733 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15734
15735         * lib/stat-time.h: New file.
15736         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
15737         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
15738         in a different way.
15739         (timespec_cmp): New function.
15740         * lib/utimecmp.c: Include stat-time.h.
15741         (SYSCALL_RESOLUTION): Depend on whether various struct stat
15742         members exist, not on the obsolescent ST_MTIM_NSEC.
15743         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
15744
15745 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15746
15747         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
15748
15749 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
15750
15751         * MODULES.html.sh (File system functions): Add stat-time.
15752         * modules/stat-time: New file.
15753         * modules/timespec (Files): Remove m4/st_mtim.m4; this
15754         is now done in a different way, by the stat-time module.
15755         * modules/utimecmp (Depends-on): Add stat-time.
15756
15757 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
15758
15759         * m4/st_mtim.m4: Remove.  Superseded by...
15760         * m4/stat-time.m4: New file.
15761         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
15762         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
15763
15764 2005-09-15  Derek Price  <derek@ximbiot.com>
15765
15766         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
15767
15768 2005-09-15  Derek Price  <derek@ximbiot.com>
15769
15770         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
15771         * lib/regex_internal.c: Ditto, using this...
15772         (__GNUC_PREREQ): ...new macro.
15773         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
15774         using...
15775         (__GNUC_PREREQ): ...this new macro.
15776
15777         * lib/strstr.h: Include string.h. Define strstr as a macro here.
15778
15779 2005-09-15  Derek Price  <derek@ximbiot.com>
15780             Paul Eggert  <eggert@cs.ucla.edu>
15781
15782         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
15783         changes, consolidating in...
15784         * lib/regex_internal.h: ...this file.
15785
15786 2005-09-13  Jim Meyering  <jim@meyering.net>
15787
15788         * lib/canon-host.c: Filter through gnu indent and reword comments
15789         slightly.
15790         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
15791
15792 2005-09-13  Derek Price  <derek@ximbiot.com>
15793
15794         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
15795         failure.
15796         Reported by Jim Meyering  <jim@meyering.net>.
15797
15798 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
15799
15800         * lib/base64.c: Typo.
15801         (base64_encode): Put b64str in initialized data section.
15802
15803 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
15804
15805         Merge glibc and coreutils changes into gnulib, plus a few
15806         extra fixes.
15807         * lib/md5.c: Use #error rather than a string.
15808         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
15809         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
15810         (__attribute__): Define to empty for non recent-GCC.
15811         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
15812         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
15813         Renamed from their non-__ counterparts, with new macros replacing
15814         them if not _LIBC.  Add __THROW attribute.
15815         (rol): Remove.
15816         (struct md5_ctx): Align buffer if using GCC.
15817         * lib/sha1.h (struct sha1_ctx): Likewise.
15818         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
15819         The old name was backwards.
15820         (NOTSWAP): Remove; not used.
15821         (rol): New macro, moved here from md5.h.
15822         (sha1_process_block): Remove a FIXME that doesn't make sense.
15823
15824 2005-09-12  Derek Price  <derek@ximbiot.com>
15825
15826         Return usable errors from canon-host.
15827         * lib/canon-host.h: New file.
15828         * lib/canon-host.c (canon_host): Wrap...
15829         (canon_host_r): ...this new function, which now relies exclusively on
15830         getaddrinfo.
15831         (ch_strerror): New function.
15832         (last_cherror): New global.
15833         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
15834         interface.
15835         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
15836         void *.
15837         (freeaddrinfo): Free ai->ai_canonname when set.
15838
15839 2005-09-12  Derek Price  <derek@ximbiot.com>
15840
15841         Make canon-host require getaddrinfo.
15842         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
15843         AC_LIBSOURCE canon-host.h.  Call...
15844         (gl_PREREQ_CANON_HOST): ...this new function, which requires
15845         gl_GETADDRINFO.
15846         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
15847
15848 2005-09-12  Derek Price  <derek@ximbiot.com>
15849
15850         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
15851         LGPL.
15852         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
15853
15854 2005-09-12  Derek Price  <derek@ximbiot.com>
15855
15856         * lib/gai_strerror.c: Include config.h when available.  Include
15857         getaddrinfo.h before other headers to test interface.
15858         Reported by Larry Jones <lawrence.jones@ugs.com>.
15859
15860 2005-09-12  Derek Price  <derek@ximbiot.com>
15861             Paul Eggert  <eggert@cs.ucla.edu>
15862
15863         * modules/glob (Files): Add glob-libc.h.
15864
15865 2005-09-12  Derek Price  <derek@ximbiot.com>
15866             Paul Eggert  <eggert@cs.ucla.edu>
15867
15868         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
15869         glob_.h, glob-libc.h.
15870         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
15871
15872 2005-09-12  Derek Price  <derek@ximbiot.com>
15873             Paul Eggert  <eggert@cs.ucla.edu>
15874
15875         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
15876         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
15877         protecting things that should be done only in gnulib contexts.
15878         * lib/glob_.h: New file, containing only the glob things needed for
15879         gnulib.
15880         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
15881         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
15882         (glob, globfree, glob_pattern_p): Now defined simply in terms of
15883         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
15884         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
15885         and to respect the namespace rules better.
15886
15887 2005-09-08  Simon Josefsson  <jas@extundo.com>
15888
15889         * modules/socklen: New file.
15890
15891 2005-09-08  Simon Josefsson  <jas@extundo.com>
15892
15893         * m4/socklen.m4: New file.
15894
15895 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15896
15897         * modules/utimens (Files): Add m4/utimbuf.m4, since
15898         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
15899         Reported by Sergey Poznyakoff.
15900
15901 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15902
15903         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
15904         definitions, since that's the preferred style in glibc.
15905         Fix a minor spacing issue, and update copyright notice to match
15906         glibc's.
15907
15908 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
15909
15910         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
15911
15912 2005-09-06  Simon Josefsson  <jas@extundo.com>
15913
15914         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
15915         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
15916
15917 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15918
15919         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
15920         warning.
15921
15922 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
15923
15924         * config/srclist.txt: Add glibc bug 1302.
15925
15926 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
15927
15928         Change bitset word type from unsigned int to unsigned long int,
15929         as this has better performance on typical 64-bit hosts.
15930         Port bitset code to hosts with unusual word sizes.
15931         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
15932         (build_collating_symbol):
15933         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
15934         argument is a bitset.  This is merely a style issue, but it makes
15935         it clearer that an entire array is expected.
15936         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
15937         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
15938         Port to the case where bitset_word is not the same as unsigned int.
15939         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
15940         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
15941         Likewise.
15942         * lib/regexec.c (check_dst_limits_calc_pos_1,
15943         check_subexp_matching_top):
15944         (build_trtable, group_nodes_into_DFAstates):
15945         Likewise.
15946         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
15947         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
15948         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
15949         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
15950         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
15951         * lib/regcomp.c (optimize_subexps, lower_subexp):
15952         Work even if bitset_word has holes in its bitwise representation.
15953         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
15954         * lib/regexec.c (check_dst_limits_calc_pos_1,
15955         check_subexp_matching_top):
15956         Likewise.
15957         * lib/regex_internal.c (re_string_reconstruct):
15958         Don't assume UCHAR_MAX == 255.
15959         * lib/regex_internal.h (bitset_set_all): Likewise.
15960         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
15961         All uses changed.
15962         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
15963         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
15964         All uses changed.
15965         (BITSET_WORD_MAX): New macro.
15966         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
15967         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
15968         (bitset_empty, bitset_copy):
15969         Prefer sizeof (bitset) to multiplying it out ourselves.
15970         (bitset_not_merge): Remove; unused.
15971         (bitset_contain): Return bool, not unsigned int with one bit on.
15972         All callers changed.
15973         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
15974         alignment than re_node_set; do this by defining a new internal
15975         type struct dests_alloc and using it to allocate memory.
15976
15977 2005-09-05  Bruno Haible  <bruno@clisp.org>
15978
15979         * gnulib-tool (func_import): Fix comparison in handling of symbolic
15980         links.
15981
15982 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
15983
15984         * modules/size_max (Makefile.am): Add size_max.h
15985
15986 2005-09-04  Derek Price  <derek@ximbiot.com>
15987
15988         * gnulib-tool (func_import): Fix reversed $symbolic logic.
15989
15990 2005-09-03  Simon Josefsson  <jas@extundo.com>
15991
15992         * gnulib-tool: Fix typo.
15993
15994 2005-09-03  Simon Josefsson  <jas@extundo.com>
15995
15996         * config/srclist.txt: Add glibc bug 1293.
15997
15998 2005-09-03  Derek Price  <derek@ximbiot.com>
15999
16000         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
16001         From Larry Jones <lawrence.jones@ugs.com>.
16002
16003 2005-09-02  Simon Josefsson  <jas@extundo.com>
16004
16005         * modules/socklen: New file.
16006
16007 2005-09-02  Simon Josefsson  <jas@extundo.com>
16008
16009         * modules/havelib: New module.
16010
16011         * modules/gettext, modules/iconv, modules/lock, modules/readline:
16012         Use havelib.
16013
16014 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
16015
16016         Check for arithmetic overflow when calculating sizes, to prevent
16017         some buffer-overflow issues.  These patches are conservative, in the
16018         sense that when I couldn't determine whether an overflow was possible,
16019         I inserted a run-time check.
16020         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
16021         macros.
16022         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
16023         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
16024         (re_xnrealloc, re_x2nrealloc): New inline functions.
16025         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
16026         parse_bracket_exp):
16027         (build_equiv_class, build_charclass): Check for arithmetic overflow
16028         in size expression calculations.
16029         * lib/regex_internal.c (re_string_realloc_buffers):
16030         (build_wcs_upper_buffer, re_node_set_add_intersect):
16031         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
16032         (re_dfa_add_node, register_state): Likewise.
16033         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
16034         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
16035         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
16036         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
16037
16038 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
16039
16040         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
16041         m4/ulonglong.m4.  Problem reported by Martin Lambers.
16042
16043 2005-09-02  Bruno Haible  <bruno@clisp.org>
16044
16045         Support for lib vs. lib64 distinction on biarch platforms.
16046         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
16047         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
16048         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
16049
16050 2005-09-02  Bruno Haible  <bruno@clisp.org>
16051
16052         * gnulib-tool (import): In the other first-use case, provide defaults
16053         as well.
16054
16055 2005-09-02  Bruno Haible  <bruno@clisp.org>
16056
16057         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
16058         patches not yet found in the latest gettext release.
16059
16060 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
16061
16062         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
16063         to avoid a collision with bits/local_lim.h in glibc.
16064         All uses changed.  Problem reported by Dmitry V. Levin in
16065         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
16066
16067         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
16068         bugs in int versus size_t comparisons.
16069         (re_string_context_at): Fix bug where the code assumed that
16070         Idx is signed.
16071
16072         Use bool where appropriate.
16073         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
16074         All callers changed.
16075         (calc_eclosure_iter): Likewise, for ROOT arg.
16076         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
16077         (build_charclass_op): Likewise, for NON_MATCH arg.
16078         * lib/regex_internal.c (re_string_allocate, re_string_construct):
16079         (re_string_construct_common): Likewise, for ICASE arg.
16080         * lib/regexec.c (re_search_2_stub, re_search_stub):
16081         Likewise, for RET_LEN arg.
16082         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
16083         (set_regs): Likewise, for FL_BACKTRACK arg.
16084         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
16085         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
16086         (calc_eclosure_iter, parse_bracket_exp):
16087         Use bool for internal variables that are booleans.
16088         * lib/regexec.c (re_search_internal, check_matching,
16089         proceed_next_node):
16090         (set_regs, build_sifted_states, sift_states_bkref):
16091         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
16092         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
16093         (find_collation_sequence_value):
16094         Likewise.
16095         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
16096         (re_node_set_compare):
16097         Return bool, not int. All callers changed.
16098         * lib/regexec.c (check_halt_node_context, check_dst_limits):
16099         (build_trtable, check_node_accept): Likewise.
16100         * lib/regex_internal.h: Include stdbool.h.
16101
16102         Fix bugs uncovered when converting to bool.
16103         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
16104         failure instead of charging ahead blindly.
16105         * lib/regex_internal.c (register_state): Likewise.
16106         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
16107         for freeing internal storage.
16108         (group_nodes_into_DFA_states): Use unsigned int, not int, for
16109         bitset pieces used as boolean, to avoid undefined behavior
16110         on hosts that do int overflow checking.
16111
16112 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
16113
16114         * config/srclist.txt: Add glibc bugs 1285-1287.
16115
16116 2005-09-01  Jim Meyering  <jim@meyering.net>
16117
16118         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
16119         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
16120         Require gl_STAT_MACROS, too.
16121
16122 2005-09-01  Bruno Haible  <bruno@clisp.org>
16123
16124         * gnulib-tool (import): In the first-use case, provide defaults.
16125
16126 2005-09-01  Bruno Haible  <bruno@clisp.org>
16127
16128         * gnulib-tool (func_import): Remove the .tmp files.
16129
16130 2005-09-01  Bruno Haible  <bruno@clisp.org>
16131
16132         * gnulib-tool (func_import): Fix handling of symbolic links.
16133
16134 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
16135
16136         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
16137         old glibc regex code mishandles strings longer than 2**31 bytes.
16138         This patch fixes this when the regex code is used in gnulib
16139         (i.e., outside glibc).
16140
16141         This patch should not affect the use of the regex code inside
16142         glibc.  No doubt this problem also needs to be handled for glibc
16143         as well, but the result will be an incompatible change to the
16144         glibc ABI, and the old ABI will have to be supported too.  That
16145         can be the the subject for another patch.
16146
16147         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
16148         governing whether the rest of this patch is active.  By default,
16149         the macro is disabled and the patch has no effect.
16150         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
16151         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
16152         (struct re_pattern_buffer, re_search, re_search_2, re_match):
16153         (re_match_2, re_set_registers): Use the new types.
16154         * lib/regex_internal.h (Idx, re_hashval_t): New types.
16155         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
16156         New macros.
16157         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
16158         (re_string_context_at, bin_tree_t, re_dfastate_t):
16159         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
16160         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
16161         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
16162         (re_string_char_size_at, re_string_wchar_at):
16163         (re_string_elem_size_at):
16164         Use the new types and macros to port to 64-bit hosts.
16165         Use unsigned types for internal values, so that the code
16166         mostly works even for arrays larger than SSIZE_MAX.
16167         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
16168         (search_duplicated_node, calc_eclosure_iter, fetch_number):
16169         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
16170         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
16171         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
16172         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
16173         (calc_inveclosure, parse_dup_op, build_range_exp):
16174         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
16175         (fetch_number, create_token_tree, mark_opt_subexp):
16176         Likewise.
16177         * lib/regex_internal.c (re_string_construct_common,
16178         create_ci_newstate):
16179         (create_cd_newstate, re_string_allocate, re_string_construct):
16180         (re_string_realloc_buffers, build_wcs_upper_buffer):
16181         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
16182         (re_string_reconstruct, re_string_peek_byte_case):
16183         (re_string_fetch_byte_case, re_string_context_at):
16184         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
16185         (re_node_set_init_copy, re_node_set_add_intersect):
16186         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
16187         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
16188         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
16189         (re_acquire_state, re_acquire_state_context, register_state):
16190         Likewise.
16191         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
16192         search_cur_bkref_entry):
16193         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
16194         (re_search_internal, re_search_2_stub, re_search_stub)
16195         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
16196         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
16197         (update_cur_sifted_state, check_dst_limits):
16198         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
16199         (check_subexp_limits, sift_states_bkref, merge_state_array):
16200         (check_subexp_matching_top, get_subexp, get_subexp_sub):
16201         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
16202         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
16203         (expand_bkref_cache, check_node_accept_bytes):
16204         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
16205         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
16206         (acquire_init_state_context, check_halt_node_context):
16207         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
16208         (sift_states_backward, clean_state_log_if_needed):
16209         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
16210         (find_recover_state, transit_state_sb, transit_state_mb):
16211         (transit_state_bkref, build_trtable, match_ctx_clean):
16212         Likewise.
16213         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
16214         to work around an assumption that REG_MISSING is negative.
16215
16216         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
16217         (seek_collating_symbol_entry) [defined _LIBC]:
16218         (lookup_collation_sequence_value) [defined _LIBC]:
16219         (build_range_exp, build_collating_symbol) [defined _LIBC]:
16220         Use prototypes rather than old-style function definitions.
16221         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
16222         (transit_state_sb) [0]:
16223         (find_collation_sequence_value) [defined _LIBC]: Likewise.
16224
16225         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
16226         rm_eo.
16227
16228         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
16229         (optimize_subexps, lower_subexp):
16230         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
16231         since the signed shift might overflow.  Use 1u<<31 instead.
16232         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
16233         Likewise.
16234         * lib/regexec.c (check_dst_limits_calc_pos_1,
16235         check_subexp_matching_top): Likewise.
16236
16237         * lib/regcomp.c (optimize_subexps, lower_subexp):
16238         Use CHAR_BIT rather than 8, for clarity.
16239         * lib/regexec.c (check_dst_limits_calc_pos_1):
16240         (check_subexp_matching_top): Likewise.
16241         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
16242         have to worry about portability issues when shifting it left.
16243         Remove no-longer-needed test for table_size > 0.
16244         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
16245         in a word, as the resulting behavior is undefined.
16246         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
16247         in one case, a <= should have been an <, and in another case the
16248         whole test was missing.
16249         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
16250         the standard name CHAR_BIT.
16251         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
16252         this is not true on one's complement and signed-magnitude hosts.
16253
16254         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
16255         next_last_offset.
16256         (struct re_dfa_t): Remove unused member states_alloc.
16257         * lib/regcomp.c (init_dfa): Don't initialize unused members.
16258
16259 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
16260
16261         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
16262         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
16263         and large-file glibc and in 32-bit large-file Solaris.
16264
16265 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
16266
16267         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
16268         lengths fit in regoff_t; this isn't true if regoff_t is the same
16269         width as size_t.
16270         * lib/regex.c (re_search_internal): 5th arg is LAST_START
16271         (= START + RANGE) instead of RANGE.  This avoids overflow
16272         problems when regoff_t is the same width as size_t.
16273         All callers changed.
16274         (re_search_2_stub): Check for overflow when adding the
16275         sizes of the two strings.
16276         (re_search_stub): Check for overflow when adding START
16277         to RANGE; if it occurs, substitute the extreme value.
16278
16279 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
16280
16281         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
16282
16283 2005-08-31  Jim Meyering  <jim@meyering.net>
16284
16285         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
16286         a pointer-to-const.
16287         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
16288         (register_state): Likewise.
16289         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
16290         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
16291         (group_nodes_into_DFAstates): Likewise.
16292
16293 2005-08-31  Jim Meyering  <jim@meyering.net>
16294
16295         * check-module: Add a FIXME comment.
16296
16297 2005-08-31  Eric Blake  <ebb9@byu.net>
16298
16299         * modules/unistd-safer (Files): Add unistd--.h.
16300         * modules/stdio-safer (Files): Add stdio--.h.
16301
16302 2005-08-31  Derek Price  <derek@ximbiot.com>
16303
16304         * lib/getdelim.c (getdelim): Return EOF on EOF.
16305         Reported by Larry Jones <lawrence.jones@ugs.com>.
16306
16307 2005-08-31  Bruno Haible  <bruno@clisp.org>
16308
16309         Avoid unnecessary diffs in the generated lib/Makefile.am.
16310         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
16311         the generated files.
16312         (func_import): Don't set cmd.
16313
16314 2005-08-31  Bruno Haible  <bruno@clisp.org>
16315
16316         * lib/strstr.c: Include <stddef.h>, for NULL.
16317         * lib/strcasestr.c: Likewise.
16318         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
16319
16320 2005-08-31  Bruno Haible  <bruno@clisp.org>
16321
16322         * gnulib-tool: New option --macro-prefix.
16323         (func_import): Use macro_prefix.
16324         (import): Handle option --macro-prefix.
16325
16326 2005-08-31  Bruno Haible  <bruno@clisp.org>
16327
16328         * gnulib-tool (import): Rename most ac_* variables to cached_*.
16329         Also use new variables cached_lgpl, cached_libtool.
16330
16331 2005-08-31  Bruno Haible  <bruno@clisp.org>
16332
16333         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
16334         always instantiating them.
16335
16336 2005-08-31  Bruno Haible  <bruno@clisp.org>
16337
16338         * gnulib-tool (func_import): Read the previous cached settings
16339         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
16340         earlier added by gnulib but are now dropped. Warn when a gnulib file
16341         overwrites a non-gnulib file.
16342
16343 2005-08-31  Bruno Haible  <bruno@clisp.org>
16344
16345         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
16346         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
16347         projects that don't keep autogenerated files in CVS. Put into
16348         actioncmd only the specified modules, not the transitive closure.
16349
16350 2005-08-31  Bruno Haible  <bruno@clisp.org>
16351
16352         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
16353         Create directories that shall be filled.
16354         (import): Don't look for gl_* macros in configure.ac. Recurse across
16355         all directories containing a gnulib-cache.m4 files, if meaningful.
16356
16357 2005-08-31  Bruno Haible  <bruno@clisp.org>
16358
16359         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
16360         (import): Set seen_libtool when we see gl_LIBTOOL.
16361
16362 2005-08-31  Bruno Haible  <bruno@clisp.org>
16363
16364         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
16365         declaration macro definitions from generated gnulib.m4.
16366
16367 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
16368
16369         * lib/iconvme.h: Add prototype for iconv_alloc.
16370
16371 2005-08-29  Simon Josefsson  <jas@extundo.com>
16372
16373         * lib/iconvme.c: Fix errno.
16374
16375 2005-08-29  Bruno Haible  <bruno@clisp.org>
16376
16377         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
16378         that it works when the directory contains spaces.
16379
16380 2005-08-29  Bruno Haible  <bruno@clisp.org>
16381
16382         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
16383
16384 2005-08-29  Bruno Haible  <bruno@clisp.org>
16385
16386         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
16387         Emit more advice.
16388
16389 2005-08-29  Bruno Haible  <bruno@clisp.org>
16390         and Stepan Kasal  <kasal@ucw.cz>
16391
16392         * check-module: If more parameters are given, check each of them
16393         separately; add more exceptions, as noted by Jim Meyering.
16394         (check_module): New procedure.
16395         (%exempt_header): Now contains all exceptions.
16396
16397 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
16398
16399         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
16400
16401 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
16402
16403         * lib/iconvme.c: Split iconv_string into iconv_alloc.
16404
16405 2005-08-28  Bruno Haible  <bruno@clisp.org>
16406
16407         * m4/gnulib-tool.m4: New file.
16408
16409 2005-08-27  Jim Meyering  <jim@meyering.net>
16410
16411         * modules/unistd-safer (Files): Add pipe-safer.c.
16412         * modules/fcntl-safer (Files): Add creat-safer.c.
16413
16414 2005-08-27  Jim Meyering  <jim@meyering.net>
16415
16416         * m4/stdlib-safer.m4: New file.  From coreutils.
16417         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
16418         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
16419         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
16420         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
16421         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
16422
16423 2005-08-27  Jim Meyering  <jim@meyering.net>
16424
16425         * lib/fopen-safer.c: Merge minor changes from coreutils.
16426         * lib/dup-safer.c: Likewise.
16427         * lib/fd-safer.c: Likewise.
16428
16429         Merge from coreutils.
16430         * lib/stdio--.h: New file.
16431         * lib/stdlib--.h: New file.
16432         * lib/mkstemp-safer.c: New file.
16433
16434         GNU tar needs these.
16435         * lib/pipe-safer.c: New file.
16436         * lib/creat-safer.c: New file.
16437         * lib/fcntl--.h (creat): Define to creat_safer.
16438         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
16439         * lib/unistd--.h (pipe): Define to pipe_safer.
16440         * lib/unistd-safer.h: Declare pipe_safer.
16441
16442 2005-08-26  Simon Josefsson  <jas@extundo.com>
16443
16444         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
16445         Haible <bruno@clisp.org>.
16446
16447 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
16448
16449         * lib/regex_internal.h: Remove all references to
16450         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
16451         or better.
16452         (bitset_not, bitset_merge, bitset_not_merge):
16453         (bitset_mask, re_string_allocate, re_string_construct):
16454         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
16455         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
16456         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
16457         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
16458         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
16459         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
16460         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
16461         (re_acquire_state_context):
16462         Remove unnecessary forward decls.
16463         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
16464         Put __attribute at function definition,
16465         now that the function decl has been removed.
16466         * lib/regex_internal.c (re_string_peek_byte_case):
16467         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
16468         Likewise.
16469
16470 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
16471
16472         * m4/regex.m4: Add AC_PREREQ(2.50).
16473         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
16474
16475 2005-08-25  Simon Josefsson  <jas@extundo.com>
16476
16477         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
16478         __fsetlocking.
16479
16480 2005-08-25  Simon Josefsson  <jas@extundo.com>
16481
16482         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
16483         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
16484         GLIBC specific code.
16485
16486 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16487
16488         Make regex safe for g++.  This fixes one real bug (an "err"
16489         that should have been "*err").  g++ problem reported by
16490         Sam Steingold.
16491         * lib/regex_internal.h (re_calloc): New macro, consistent with
16492         re_malloc etc.  All callers of calloc changed to use re_calloc.
16493         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
16494         not int.  All callers changed.
16495         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
16496         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
16497         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
16498         (find_recover_state): Change "err" to "*err"; this fixes what
16499         appears to be a real bug.
16500         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
16501         versus int.
16502
16503 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16504
16505         * modules/regex (Depends-on): Add malloc, since the code
16506         assumes that !malloc(0) means failure.
16507
16508 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16509
16510         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
16511
16512         alloca modernization/simplification for regex.
16513         * lib/regex.c: Remove portability cruft for alloca.  This no longer
16514         needs to be at the start of the file, and can be moved into
16515         regex_internal.h and simplified.
16516         * lib/regex_internal.h: Include <alloca.h>.
16517         (__libc_use_alloca) [!defined _LIBC]: New macro.
16518         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
16519         now works outside glibc.
16520
16521 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
16522
16523         * config/srclist.txt: Add glibc bugs 1241, 1245.
16524
16525 2005-08-25  Jim Meyering  <jim@meyering.net>
16526
16527         * lib/open-safer.c: Include <config.h>.
16528         Otherwise, we'd lose LARGEFILE support in any file using
16529         e.g. "fcntl--.h"
16530
16531 2005-08-25  Bruno Haible  <bruno@clisp.org>
16532
16533         * m4/minmax.m4: Require autoconf 2.52.
16534         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
16535         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
16536         alternatives of translit over the alphabet.
16537         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
16538
16539 2005-08-24  Simon Josefsson  <jas@extundo.com>
16540
16541         * tests/test-getpass.c: New file.
16542
16543 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16544
16545         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
16546         for GNU regex features.
16547
16548 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16549
16550         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
16551         * lib/regex.h (regerror): Likewise.
16552
16553         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
16554         requires this.  (The code never needed it.)
16555
16556         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
16557         All uses of recently-renamed identifiers changed to use the new,
16558         POSIX-compliant names.  The code will build and run just fine
16559         without these changes, but it's better to eat our own dog food
16560         and use the standard-conforming names.
16561
16562         * lib/regex.h: Fix a multitude of POSIX name space violations.
16563         These changes have an effect only for programs that define
16564         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
16565         do not change anything for programs compiled in the normal way.
16566         Also, there is no effect on the ABI.
16567
16568         (_REGEX_SOURCE): New macro.
16569         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
16570         defined and _GNU_SOURCE is not; this fixes a name space violation.
16571
16572         Rename the following macros to obey POSIX requirements.
16573         The old names are still visible as macros if _REGEX_SOURCE is defined.
16574         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
16575         RE_BACKSLASH_ESCAPE_IN_LISTS.
16576         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
16577         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
16578         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
16579         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
16580         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
16581         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
16582         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
16583         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
16584         (REG_INTERVALS): renamed from RE_INTERVALS.
16585         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
16586         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
16587         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
16588         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
16589         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
16590         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
16591         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
16592         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
16593         RE_UNMATCHED_RIGHT_PAREN_ORD.
16594         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
16595         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
16596         (REG_DEBUG): renamed from RE_DEBUG.
16597         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
16598         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
16599         unusual, since we can't clash with the POSIX REG_ICASE.
16600         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
16601         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
16602         (REG_NO_SUB): renamed from RE_NO_SUB.
16603         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
16604         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
16605         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
16606         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
16607         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
16608         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
16609         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
16610         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
16611         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
16612         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
16613         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
16614         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
16615         RE_SYNTAX_POSIX_MINIMAL_BASIC.
16616         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
16617         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
16618         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
16619         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
16620         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
16621         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
16622         (REG_FIXED): Renamed from REGS_FIXED.
16623         (REG_NREGS): Renamed from RE_NREGS.
16624
16625         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
16626         of other REG_* macros, since POSIX says the user is allowed to
16627         #undef these macros selectively.
16628
16629         (reg_errcode_t): Update comment stating what other tables need
16630         to be consistent.
16631
16632         Rename the following enum values to obey POSIX requirements.
16633         The old names are still visible as macros.
16634         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
16635         is not defined, since GNU is supposed to be a superset of POSIX as
16636         much as possible, and since we want reg_errcode_t to be a signed
16637         type for implementation consistency.
16638         (_REG_NOERROR): Renamed from REG_NOERROR.
16639         (_REG_NOMATCH): Renamed from REG_NOMATCH.
16640         (_REG_BADPAT): Renamed from REG_BADPAT.
16641         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
16642         (_REG_ECTYPE): Renamed from REG_ECTYPE.
16643         (_REG_EESCAPE): Renamed from REG_EESCAPE.
16644         (_REG_ESUBREG): Renamed from REG_ESUBREG.
16645         (_REG_EBRACK): Renamed from REG_EBRACK.
16646         (_REG_EPAREN): Renamed from REG_EPAREN.
16647         (_REG_EBRACE): Renamed from REG_EBRACE.
16648         (_REG_BADBR): Renamed from REG_BADBR.
16649         (_REG_ERANGE): Renamed from REG_ERANGE.
16650         (_REG_ESPACE): Renamed from REG_ESPACE.
16651         (_REG_BADRPT): Renamed from REG_BADRPT.
16652         (_REG_EEND): Renamed from REG_EEND.
16653         (_REG_ESIZE): Renamed from REG_ESIZE.
16654         (_REG_ERPAREN): Renamed from REG_ERPAREN.
16655         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
16656         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
16657         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
16658         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
16659
16660         (_REG_RE_NAME, _REG_RM_NAME): New macros.
16661         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
16662         changed.  But support the old name if the new one is not defined
16663         and if _REGEX_SOURCE.
16664
16665         Change the following member names in struct re_pattern_buffer.
16666         The old names are still supported if !_REGEX_SOURCE.
16667         The new names are always supported, regardless of _REGEX_SOURCE.
16668         (re_buffer): Renamed from buffer.
16669         (re_allocated): Renamed from allocated.
16670         (re_used): Renamed from used.
16671         (re_syntax): Renamed from syntax.
16672         (re_fastmap): Renamed from fastmap.
16673         (re_translate): Renamed from translate.
16674         (re_can_be_null): Renamed from can_be_null.
16675         (re_regs_allocated): Renamed from regs_allocated.
16676         (re_fastmap_accurate): Renamed from fastmap_accurate.
16677         (re_no_sub): Renamed from no_sub.
16678         (re_not_bol): Renamed from not_bol.
16679         (re_not_eol): Renamed from not_eol.
16680         (re_newline_anchor): Renamed from newline_anchor.
16681
16682         Change the following member names in struct re_registers.
16683         The old names are still supported if !_REGEX_SOURCE.
16684         The new names are always supported, regardless of _REGEX_SOURCE.
16685         (rm_num_regs): Renamed from num_regs.
16686         (rm_start): Renamed from start.
16687         (rm_end): Renamed from end.
16688
16689         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
16690         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
16691         Prepend __ to parameter names.
16692
16693         Undo yesterday's changes.
16694
16695 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
16696
16697         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
16698         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
16699         lib/regex.c.
16700
16701 2005-08-24  Jim Meyering  <jim@meyering.net>
16702
16703         Sync from coreutils.
16704         * m4/fcntl-safer.m4: New file.
16705
16706         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
16707         and object files for this module.
16708
16709 2005-08-24  Jim Meyering  <jim@meyering.net>
16710
16711         Sync from coreutils.
16712         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
16713
16714 2005-08-24  Jim Meyering  <jim@meyering.net>
16715
16716         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
16717         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
16718
16719 2005-08-24  Jim Meyering  <jim@meyering.net>
16720
16721         * modules/fcntl-safer: New module.
16722         * modules/fts (Depends-on): Add fcntl-safer.
16723         * MODULES.html.sh (File descriptor based Input/Output):
16724         Add fcntl-safer.
16725
16726 2005-08-24  Bruno Haible  <bruno@clisp.org>
16727
16728         Support for unit test modules.
16729         * modules/README: Mention tests modules.
16730         * modules/TEMPLATE-TESTS: New file.
16731         * gnulib-tool: New options --extract-tests-module, --with-tests and
16732         --tests-base (unused for the moment).
16733         (testsbase, inctests): New variables.
16734         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
16735         (func_verify_module): Exclude TEMPLATE-TESTS.
16736         (func_verify_nontests_module, func_verify_tests_module): New functions.
16737         (func_get_dependencies): Add implicit dependency for tests modules.
16738         (func_get_tests_module): New function.
16739         (func_modules_transitive_closure): When --with-tests was specified,
16740         include the unit tests as well, unless explicitly avoided.
16741         (func_emit_lib_Makefile_am): Ignore the tests modules here.
16742         (func_emit_tests_Makefile_am): New function.
16743         (func_create_testdir): When --with-tests was specified, emit a
16744         tests/ directory.
16745         * MODULES.html.sh (Future developments): Update.
16746
16747 2005-08-24  Bruno Haible  <bruno@clisp.org>
16748
16749         * modules/tls-tests: New file.
16750         * tests/test-tls.c: New file, from GNU gettext.
16751
16752 2005-08-24  Bruno Haible  <bruno@clisp.org>
16753
16754         * modules/lock-tests: New file.
16755         * tests/test-lock.c: New file, from GNU gettext.
16756
16757 2005-08-24  Bruno Haible  <bruno@clisp.org>
16758
16759         * lib/lock.h: Add multiple inclusion guard.
16760         * lib/tls.h: Add multiple inclusion guard.
16761
16762 2005-08-24  Bruno Haible  <bruno@clisp.org>
16763
16764         * gnulib-tool: Add support for the --aux-dir option to
16765         --create-testdir, --create-megatestdir, --test, --megatest.
16766         (func_create_testdir, func_create_megatestdir): Optionally emit a
16767         AC_CONFIG_AUX_DIR directive.
16768         (create-testdir, create-megatestdir, test, megatest): Provide a
16769         default value for $auxdir.
16770
16771 2005-08-24  Bruno Haible  <bruno@clisp.org>
16772
16773         * gnulib-tool (import): Use compound statement instead of subshell
16774         where possible.
16775
16776 2005-08-24  Bruno Haible  <bruno@clisp.org>
16777
16778         * gnulib-tool (import): Change --aux-dir default to "build-aux".
16779
16780 2005-08-24  Bruno Haible  <bruno@clisp.org>
16781
16782         * gnulib-tool (func_version): Update.
16783
16784 2005-08-24  Bruno Haible  <bruno@clisp.org>
16785
16786         * gnulib-tool (func_import, func_create_testdir,
16787         func_create_megatestdir): Quote all autoconf macro arguments.
16788
16789 2005-08-24  Bruno Haible  <bruno@clisp.org>
16790
16791         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
16792         option --force, because --force causes the aclocal.m4 of each
16793         subdirectory to be newer than the corresponding config.h.in.
16794
16795 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16796
16797         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
16798         All contents moved to gl_REGEX.
16799         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
16800         assume that it does.
16801
16802 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16803
16804         * lib/regex.h (REG_NOSYS)
16805         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
16806         Define, since POSIX requires it as of 2001.
16807         (_REG_ENOSYS)
16808         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
16809         New private symbol, used to keep the enum signed in all cases.
16810         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
16811         Youngman in
16812         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
16813
16814         * lib/regex_internal.c (re_string_skip_chars, register_state):
16815         (calc_state_hash):
16816         Remove forward decls; no longer needed now that we use prototypes.
16817         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
16818         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
16819         (clean_state_log_if_needed): Likewise.
16820
16821 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
16822
16823         * config/srclist.txt: Add glibc bugs 1231-1233.
16824
16825 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16826
16827         Fix problems reported by Sam Steingold in
16828         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
16829         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
16830         assumed that reg_errcode_t is a signed type, which is not
16831         necessarily true if _XOPEN_SOURCE is not defined.
16832         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
16833         since some compilers warn about it otherwise.
16834
16835 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16836
16837         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
16838         (init_word_char, create_initial_state, duplicate_node_closure):
16839         (fetch_token, peek_token_bracket, build_range_exp):
16840         (build_collating_symbol): Remove forward decls; no longer needed
16841         now that we use prototypes.
16842
16843         * lib/regcomp.c:
16844         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
16845         (re_compile_fastmap_iter, regcomp, regerror, regfree):
16846         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
16847         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
16848         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
16849         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
16850         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
16851         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
16852         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
16853         (build_range_exp, build_collating_symbol, parse_bracket_exp):
16854         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
16855         (build_charclass, build_charclass_op, fetch_number, create_tree):
16856         (create_token_tree, mark_opt_subexp, duplicate_tree):
16857         Use prototypes rather than old-style definitions.
16858
16859         * lib/regex_internal.c:
16860         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
16861         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
16862         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
16863         (re_string_reconstruct, re_string_peek_byte_case):
16864         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
16865         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
16866         (re_node_set_init_copy, re_node_set_add_intersect):
16867         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
16868         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
16869         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
16870         (re_acquire_state, re_acquire_state_context, register_state):
16871         (create_ci_newstate, create_cd_newstate, free_state):
16872         Likewise.
16873         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
16874         re_search_2):
16875         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
16876         (re_search_internal, prune_impossible_nodes):
16877         (acquire_init_state_context, check_matching, static):
16878         (check_halt_node_context, check_halt_state_context, proceed_next_node):
16879         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
16880         (update_regs, sift_states_backward, build_sifted_states):
16881         (clean_state_log_if_needed, merge_state_array):
16882         (update_cur_sifted_state, add_epsilon_src_nodes):
16883         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
16884         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
16885         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
16886         (find_recover_state, check_subexp_matching_top, transit_state_mb):
16887         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
16888         (check_arrival, check_arrival_add_next_nodes):
16889         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
16890         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
16891         (check_node_accept_bytes, check_node_accept, extend_buffers):
16892         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
16893         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
16894         (sift_ctx_init):
16895         Likewise.
16896
16897         * lib/regex_internal.h:
16898         (re_string_allocate, re_string_construct, re_string_reconstruct):
16899         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
16900         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
16901         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
16902         (re_string_context_at, re_string_peek_byte_case):
16903         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
16904         is defined, since we now use prototypes always.
16905
16906         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
16907         C89 or better.  All uses removed.
16908
16909 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
16910
16911         * config/srclist.txt: Add glibc bugs 1220-1227.
16912
16913 2005-08-20  Jim Meyering  <jim@meyering.net>
16914
16915         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
16916         of unused local, dfa.
16917
16918 2005-08-20  Bruno Haible  <bruno@clisp.org>
16919
16920         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
16921
16922 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16923
16924         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
16925         (re_node_set_insert_last, re_dfa_add_node):
16926         Rename local variables to avoid GCC shadowing warnings.
16927
16928 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16929
16930         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
16931         [defined lint]: Suppress bogus uninitialized-variable warnings.
16932
16933         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
16934         and let the caller return REG_ESPACE if out of space.  This
16935         removes an uninitialied-variable warning with GCC 4.0.1, and also
16936         avoids taking the address of a local variable.  All callers
16937         changed.
16938
16939 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
16940
16941         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
16942         $LIBCSRC/posix/regexec.c.
16943         Add glibc bug 1217 for regcomp.c.
16944
16945 2005-08-19  Jim Meyering  <jim@meyering.net>
16946
16947         * lib/regexec.c (proceed_next_node): Redo local variables to
16948         avoid GCC shadowing warnings.
16949
16950 2005-08-18  Bruno Haible  <bruno@clisp.org>
16951
16952         * lib/strstr.c (strstr): Fix return value in multibyte case.
16953         * lib/strcasestr.c (strcasestr): Likewise.
16954
16955 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
16956
16957         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
16958
16959 2005-08-17  Jim Meyering  <jim@meyering.net>
16960
16961         Make the %s format (seconds since the epoch) work for a negative
16962         number and when used with a zero-padded field width, e.g. %015s.
16963
16964         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
16965         label so that it precedes the code to set `digits'.  Otherwise,
16966         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
16967         print `00-22'.  Now, it prints `-0022', as it should.
16968
16969 2005-08-17  Bruno Haible  <bruno@clisp.org>
16970
16971         * modules/strstr (Files): Add m4/mbrtowc.m4.
16972         (Depends-on): Add mbuiter.
16973
16974 2005-08-17  Bruno Haible  <bruno@clisp.org>
16975
16976         * modules/strcasestr: New file.
16977         * MODULES.html.sh (String handling, based on ANSI C 89): Add
16978         strcasestr.
16979
16980 2005-08-17  Bruno Haible  <bruno@clisp.org>
16981
16982         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
16983
16984 2005-08-17  Bruno Haible  <bruno@clisp.org>
16985
16986         * modules/mbuiter: New file.
16987         * MODULES.html.sh (Extended multibyte and wide character utilities):
16988         Add mbuiter.
16989
16990 2005-08-17  Bruno Haible  <bruno@clisp.org>
16991
16992         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
16993         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
16994
16995 2005-08-17  Bruno Haible  <bruno@clisp.org>
16996
16997         * m4/strcasestr.m4: New file.
16998
16999 2005-08-17  Bruno Haible  <bruno@clisp.org>
17000
17001         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
17002         * lib/strstr.c: Completely rewritten, with multibyte locale support.
17003
17004 2005-08-17  Bruno Haible  <bruno@clisp.org>
17005
17006         * lib/strcasestr.h: New file.
17007         * lib/strcasestr.c: New file.
17008
17009 2005-08-17  Bruno Haible  <bruno@clisp.org>
17010
17011         * lib/strcasecmp.c: Use mbuiter.h.
17012
17013 2005-08-17  Bruno Haible  <bruno@clisp.org>
17014
17015         * lib/mbuiter.h: New file.
17016
17017 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
17018
17019         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
17020         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
17021         and gl_GETOPT are both invoked via different paths (as happens
17022         with GNU tar CVS because it uses both argp and getopt), the former
17023         wins.
17024
17025 2005-08-16  Bruno Haible  <bruno@clisp.org>
17026
17027         * modules/tls: New file.
17028         * MODULES.html.sh (Multithreading): Add tls.
17029
17030 2005-08-16  Bruno Haible  <bruno@clisp.org>
17031
17032         * modules/strnlen1: New file.
17033         * MODULES.html.sh (String handling): Add strnlen1.
17034
17035 2005-08-16  Bruno Haible  <bruno@clisp.org>
17036
17037         * modules/strcase (Files): Add m4/mbrtowc.m4.
17038         (Depends-on): Add strnlen1, mbchar.
17039
17040 2005-08-16  Bruno Haible  <bruno@clisp.org>
17041
17042         * modules/mbiter: New file.
17043         * MODULES.html.sh (Extended multibyte and wide character utilities):
17044         Add mbiter.
17045
17046 2005-08-16  Bruno Haible  <bruno@clisp.org>
17047
17048         * modules/mbfile: New file.
17049         * MODULES.html.sh (Extended multibyte and wide character utilities):
17050         Add mbfile.
17051
17052 2005-08-16  Bruno Haible  <bruno@clisp.org>
17053
17054         * modules/mbchar: New file.
17055         * MODULES.html.sh (Extended multibyte and wide character utilities):
17056         New section.
17057
17058 2005-08-16  Bruno Haible  <bruno@clisp.org>
17059
17060         * m4/tls.m4: New file, from GNU gettext.
17061
17062 2005-08-16  Bruno Haible  <bruno@clisp.org>
17063
17064         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
17065         always.
17066         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
17067
17068 2005-08-16  Bruno Haible  <bruno@clisp.org>
17069
17070         * m4/mbiter.m4: New file.
17071
17072 2005-08-16  Bruno Haible  <bruno@clisp.org>
17073
17074         * m4/mbfile.m4: New file.
17075
17076 2005-08-16  Bruno Haible  <bruno@clisp.org>
17077
17078         * m4/mbchar.m4: New file.
17079
17080 2005-08-16  Bruno Haible  <bruno@clisp.org>
17081
17082         * lib/tls.h: New file, from GNU gettext.
17083         * lib/tls.c: New file, from GNU gettext.
17084
17085 2005-08-16  Bruno Haible  <bruno@clisp.org>
17086
17087         * lib/strnlen1.h: New file.
17088         * lib/strnlen1.c: New file.
17089
17090 2005-08-16  Bruno Haible  <bruno@clisp.org>
17091
17092         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
17093         (mbi_init): Update.
17094         (mbi_avail, mbi_advance): Let the iteration end before the terminating
17095         NUL byte, not after it.
17096
17097 2005-08-16  Bruno Haible  <bruno@clisp.org>
17098
17099         * lib/strcase.h (strcasecmp): Add note in comments.
17100         * lib/strncasecmp.c: Use code from strcasecmp.c.
17101         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
17102         (strcasecmp): Work correctly in multibyte locales.
17103
17104 2005-08-16  Bruno Haible  <bruno@clisp.org>
17105
17106         * lib/mbiter.h: New file.
17107
17108 2005-08-16  Bruno Haible  <bruno@clisp.org>
17109
17110         * lib/mbfile.h: New file.
17111
17112 2005-08-16  Bruno Haible  <bruno@clisp.org>
17113
17114         * lib/mbchar.h: New file.
17115         * lib/mbchar.c: New file.
17116
17117 2005-08-16  Bruno Haible  <bruno@clisp.org>
17118
17119         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
17120         the valid ones. Makes the comparison operations transitive:
17121         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
17122         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
17123
17124 2005-08-15  Simon Josefsson  <jas@extundo.com>
17125
17126         * modules/ssize_t (License): Change to 'unlimited'.
17127
17128         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
17129
17130 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
17131
17132         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
17133         Add comments for each pending glibc patch.
17134
17135 2005-08-15  Bruno Haible  <bruno@clisp.org>
17136
17137         * lib/regex.h (__restrict_arr): Don't define to __restrict if
17138         __cplusplus is defined.
17139
17140 2005-08-14  Jim Meyering  <jim@meyering.net>
17141
17142         Sync from coreutils.
17143
17144         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
17145         Use the hash-table-based cycle-detection code not just when
17146         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
17147         Reported by James Youngman in
17148         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
17149         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
17150         FTS_TIGHT_CYCLE_CHECK.
17151         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
17152         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
17153         once again.
17154         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
17155         * lib/fts.c (fd_safer): Remove decl.
17156         Include fcntl--.h rather than unistd-safer.h
17157         (fts_safe_changedir): Don't call fd_safer; no longer needed
17158         now that we include fcntl--.h.
17159
17160 2005-08-12  Simon Josefsson  <jas@extundo.com>
17161
17162         * modules/getndelim2: Use ssize_t module.
17163         * modules/getnline: Likewise.
17164         * modules/safe-read: Likewise.
17165         * modules/xreadlink: Likewise.
17166
17167         * modules/ssize_t: New file.
17168
17169 2005-08-12  Simon Josefsson  <jas@extundo.com>
17170
17171         * m4/readline.m4: Look for termcap, curses or ncurses if required.
17172
17173 2005-08-12  Simon Josefsson  <jas@extundo.com>
17174
17175         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17176         ssize_t.
17177
17178 2005-08-12  Simon Josefsson  <jas@extundo.com>
17179
17180         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
17181         readline, getdelim and check_version.
17182         (Support for systems lacking ISO C 99: Sizes of integer types):
17183         Add size_max.
17184
17185 2005-08-12  Bruno Haible  <bruno@clisp.org>
17186
17187         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
17188
17189 2005-08-11  Simon Josefsson  <jas@extundo.com>
17190
17191         * modules/readline: New file.
17192
17193         * modules/strnlen (Files): Add strnlen.h.
17194
17195 2005-08-11  Simon Josefsson  <jas@extundo.com>
17196
17197         * m4/readline.m4: New file.
17198
17199 2005-08-11  Simon Josefsson  <jas@extundo.com>
17200
17201         * lib/readline.h, readline.c: New file.
17202
17203 2005-08-11  Simon Josefsson  <jas@extundo.com>
17204
17205         * doc/gnulib.texi (Initial import, Finishing touches): Mention
17206         gl_AVOID.
17207
17208 2005-08-11  Bruno Haible  <bruno@clisp.org>
17209
17210         * lib/strnlen.h (strnlen): Change parameter name to match comment.
17211
17212 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
17213
17214         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
17215
17216 2005-08-10  Simon Josefsson  <jas@extundo.com>
17217
17218         * tests/test-iconvme.c: New file.
17219
17220 2005-08-10  Simon Josefsson  <jas@extundo.com>
17221
17222         * m4/strnlen.m4: New file.
17223
17224         * m4/strndup.m4: Don't check for strnlen declaration, done in
17225         strnlen.m4.
17226
17227 2005-08-10  Simon Josefsson  <jas@extundo.com>
17228
17229         * lib/strndup.c: Use strnlen.h.
17230
17231         * lib/strnlen.h: New file.
17232
17233 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
17234
17235         * README: Typos.
17236
17237 2005-08-02  Simon Josefsson  <jas@extundo.com>
17238
17239         * modules/readline: New file.
17240
17241 2005-08-02  Simon Josefsson  <jas@extundo.com>
17242
17243         * modules/getdelim: New file.
17244
17245         * modules/getline: Rewrite, don't use getndelim2.
17246
17247 2005-08-02  Simon Josefsson  <jas@extundo.com>
17248
17249         * m4/getline.m4: Separate out getdelim stuff into separate module.
17250
17251         * m4/getdelim.m4: New file.
17252
17253 2005-08-02  Simon Josefsson  <jas@extundo.com>
17254
17255         * lib/getline.h, getline.c: Rewrite.
17256
17257         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
17258
17259 2005-07-31  Bruno Haible  <bruno@clisp.org>
17260
17261         * lib/lock.h (gl_lock_initializer): New macro.
17262         (gl_lock_define_initialized): Use it.
17263         (gl_rwlock_initializer): New macro.
17264         (gl_rwlock_define_initialized): Use it.
17265         (gl_recursive_lock_initializer): New macro.
17266         (gl_recursive_lock_define_initialized): Use it.
17267
17268 2005-07-30  Karl Berry  <karl@gnu.org>
17269
17270         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
17271         Report from Ben Pfaff, regarding getopt.
17272
17273 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
17274
17275         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
17276         normal way.
17277         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
17278         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
17279         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
17280         (gl_GETOPT): Use the new macros.  Most of the implementation
17281         is moved to the new macros.  This is for programs like Emacs
17282         that don't want all the functionality of gl_GETOPT.
17283
17284 2005-07-26  Bruno Haible  <bruno@clisp.org>
17285
17286         * m4/lock.m4: Update from GNU gettext.
17287
17288 2005-07-26  Bruno Haible  <bruno@clisp.org>
17289
17290         * lib/lock.h: Update from GNU gettext.
17291         * lib/lock.c: Update from GNU gettext.
17292
17293 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
17294
17295         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
17296         obsolescent AC_TRY_RUN.  Include the default includes files, for
17297         'exit'.
17298
17299 2005-07-24  Bruno Haible  <bruno@clisp.org>
17300
17301         * modules/visibility: New file.
17302         * MODULES.html.sh (Misc): Add visibility.
17303
17304 2005-07-24  Bruno Haible  <bruno@clisp.org>
17305
17306         * m4/visibility.m4: New file.
17307
17308 2005-07-24  Bruno Haible  <bruno@clisp.org>
17309
17310         * doc/visibility.texi: New file.
17311
17312 2005-07-22  Bruno Haible  <bruno@clisp.org>
17313
17314         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
17315         $(ALLOCA_H), redundant through BUILT_SOURCES.
17316         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
17317         redundant through BUILT_SOURCES.
17318         * modules/byteswap (Makefile.am): Remove explicit dependency on
17319         $(BYTESWAP_H), redundant through BUILT_SOURCES.
17320         * modules/fnmatch (Makefile.am): Remove explicit dependency on
17321         $(FNMATCH_H), redundant through BUILT_SOURCES.
17322         * modules/getopt (Makefile.am): Remove explicit dependency on
17323         $(GETOPT_H), redundant through BUILT_SOURCES.
17324         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
17325         redundant through BUILT_SOURCES.
17326         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
17327         redundant through BUILT_SOURCES.
17328         * modules/stdbool (Makefile.am): Remove explicit dependency on
17329         $(STDBOOL_H), redundant through BUILT_SOURCES.
17330         * modules/stdint (Makefile.am): Remove explicit dependency on
17331         $(STDINT_H), redundant through BUILT_SOURCES.
17332         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
17333         Remove explicit dependency on $(SYSEXITS_H).
17334         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
17335
17336 2005-07-18  Simon Josefsson  <jas@extundo.com>
17337
17338         * lib/check-version.c (check_version): Accept identical versions too.
17339
17340 2005-07-18  Bruno Haible  <bruno@clisp.org>
17341
17342         * modules/lock: New file.
17343         * MODULES.html.sh (Multithreading): New section.
17344
17345 2005-07-18  Bruno Haible  <bruno@clisp.org>
17346
17347         * m4/lock.m4: New file, from GNU gettext.
17348
17349 2005-07-18  Bruno Haible  <bruno@clisp.org>
17350
17351         * lib/lock.h: New file, from GNU gettext.
17352         * lib/lock.c: New file, from GNU gettext.
17353
17354 2005-07-18  Bruno Haible  <bruno@clisp.org>
17355
17356         * lib/lock.h (gl_once_t): New type.
17357         (gl_once_define, gl_once): New macros.
17358         * lib/lock.c (fresh_once): New variable.
17359         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
17360         functions.
17361
17362 2005-07-16  Simon Josefsson  <jas@extundo.com>
17363
17364         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
17365         workaround, suggested by Bruno.
17366
17367 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
17368
17369         * modules/xalloc (Depends-on): Add xalloc-die.
17370         * modules/xvasprintf (Depends-on): Add xalloc-die.
17371
17372 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
17373
17374         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
17375         with a minor change.
17376
17377 2005-07-15  Bruno Haible  <bruno@clisp.org>
17378
17379         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
17380         When using lib/poll.c, define poll as rpl_poll.
17381
17382 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
17383
17384         * modules/argp (Depends-on): Remove unlocked-io.
17385
17386 2005-07-14  Derek Price  <derek@ximbiot.com>
17387
17388         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
17389         for glob symlink bug.
17390
17391 2005-07-14  Bruno Haible  <bruno@clisp.org>
17392
17393         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
17394         Instead, test for *_unlocked function declarations directly.
17395
17396 2005-07-11  Simon Josefsson  <jas@extundo.com>
17397
17398         * modules/size_max: New file.
17399
17400         * modules/xsize: Depend on size_max module for size_max.m4.
17401
17402 2005-07-11  Simon Josefsson  <jas@extundo.com>
17403
17404         * lib/size_max.h: New file.
17405
17406 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
17407
17408         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
17409         copyright symbol and the year.
17410         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
17411         (version_etc_va): Use parameterized copyright notice.
17412         Reword to conform to the current GNU coding standards.
17413
17414 2005-07-11  Karl Berry  <karl@gnu.org>
17415
17416         * doc/gnulib.texi (Quoting): new node.
17417         (Initial import): more info, from Patrice.
17418
17419 2005-07-11  Bruno Haible  <bruno@clisp.org>
17420
17421         * gnulib-tool (func_usage): Document option --avoid.
17422         (Command line options): Handle --avoid.
17423         (func_acceptable): New function.
17424         (func_modules_transitive_closure): Use it.
17425
17426 2005-07-11  Bruno Haible  <bruno@clisp.org>
17427
17428         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
17429         Reported by Jim Meyering.
17430
17431 2005-07-10  Bruno Haible  <bruno@clisp.org>
17432
17433         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
17434         Needed when size_t is smaller than 'unsigned int'.
17435         Reported by Paul Eggert.
17436
17437 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
17438
17439         * modules/argp (Depends-on): Add unlocked-io
17440
17441 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
17442
17443         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
17444         block of defines.
17445
17446 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
17447
17448         * config/srclist.txt: Comment out regcomp.c, since we have a porting
17449         fix now.
17450
17451 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
17452         and Paul Eggert  <eggert@cs.ucla.edu>
17453
17454         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
17455         in wint_t, not wchar_t.  Remove now-unnecessary cast.
17456
17457 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
17458
17459         * modules/regex (Files): Add lib/regex_internal.c,
17460         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
17461         (Depends-on): Add extensions.
17462         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
17463
17464 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
17465
17466         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
17467         pathconf.
17468         * m4/same.m4 (gl_SAME): Likewise.
17469         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
17470
17471         * m4/regex.m4: Adjust to new libc regex implementation.
17472         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
17473         all the .c and .h parts of (the new) regex.
17474         Quote the m4 stuff better.
17475         Check for RE_ICASE bug of old gnulib.
17476         Check for REG_STARTEND of recent libc.
17477         Rename local variables from jm_* to gl_*.
17478         Quote operand of "test -f".
17479         Say "recent enough" version of libc, not "version 2".
17480         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
17481         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
17482         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
17483         Remove check for btowc, isascii.
17484         Require AM_LANGINFO_CODESET.
17485
17486 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
17487
17488         * lib/regex.c, regex.h: Sync from libc.
17489         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
17490         * lib/regexec.c:
17491         New files, synced from libc, except that regex_internal.h
17492         currently has a small porting fix.
17493
17494 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
17495
17496         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
17497         regex_internal.c, regexec.c.
17498         Add regex_internal.h too, but as a comment, since the libc version
17499         is currently broken in gnulib mode.
17500
17501 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
17502
17503         Support programs like Emacs that use gnulib but not gettext.
17504         * MODULES.html.sh (Internationalization functions): Add gettext-h.
17505         * modules/gettext-h: New file.
17506         * modules/gettext (Files): Remove lib/gettext.h.
17507         (Depends-on): Add gettext-h.
17508         (Makefile.am): Remove lib_SOURCES.
17509         * modules/argmatch, modules/c-stack, modules/closeout:
17510         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
17511         * modules/execute, modules/file-type, modules/getaddrinfo:
17512         * modules/getopt, modules/human, modules/javacomp:
17513         * modules/javaexec, modules/mkdir-p, modules/obstack:
17514         * modules/openat, modules/pagealign_alloc, modules/pipe:
17515         * modules/quotearg, modules/regex, modules/rpmatch:
17516         * modules/unicodeio, modules/userspec, modules/version-etc:
17517         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
17518         * modules/xsetenv:
17519         Depend on gettext-h, not gettext.
17520
17521 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
17522
17523         * gnulib-tool (func_import): Add support for 'public domain' license.
17524         * modules/alloca, modules/atexit, modules/memmove:
17525         Now public domain, not GPL.
17526         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
17527         * modules/realloc, modules/strerror, modules/strtod:
17528         Now LGPL, not GPL.
17529
17530 2005-07-05  Bruno Haible  <bruno@clisp.org>
17531
17532         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
17533         autoconf CVS. Needed for mingw.
17534
17535 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17536
17537         Remove the dependency of the strftime module on the tzset module.
17538         * modules/strftime (Depends-on): Remove dependency on tzset.
17539
17540 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17541
17542         Remove the dependency of the strftime module on the tzset module.
17543         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
17544         gl_FUNC_TZSET_CLOBBER.
17545
17546 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
17547
17548         Remove the dependency of the strftime module on the tzset module.
17549         * lib/strftime.c (my_strftime)
17550         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
17551         Copy the input structure, to work around some of the bug with
17552         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
17553         Solaris releases, you should also use the tzset module, but we won't
17554         require it as a dependency any more since we don't want LGPLed code
17555         to depend on GPLed code.
17556
17557 2005-07-02  Jim Meyering  <jim@meyering.net>
17558
17559         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
17560         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
17561         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
17562         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
17563
17564 2005-07-02  Jim Meyering  <jim@meyering.net>
17565
17566         * lib/backupfile.c (backup_args): Change a `0' to NULL.
17567
17568 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
17569
17570         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
17571         declares only 'struct timespec;' (!).
17572
17573 2005-07-01  Jim Meyering  <jim@meyering.net>
17574
17575         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
17576         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
17577         * lib/save-cwd.c, tempname.c:
17578         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
17579         and don't include <sys/file.h>).
17580
17581 2005-06-29  Jim Meyering  <jim@meyering.net>
17582
17583         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
17584         type name.  Use the variable name instead.
17585         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
17586         Likewise.
17587
17588 2005-06-28  Simon Josefsson  <jas@extundo.com>
17589
17590         * modules/check-version (Files): Add check-version.m4.
17591
17592 2005-06-28  Simon Josefsson  <jas@extundo.com>
17593
17594         * m4/check-version.m4: New file, suggested by Jim Meyering
17595         <jim@meyering.net>.
17596
17597 2005-06-28  Simon Josefsson  <jas@extundo.com>
17598
17599         * lib/check-version.h, lib/check-version.c: New files.
17600
17601 2005-06-28  Simon Josefsson  <jas@extundo.com>
17602
17603         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
17604         collision with global variable.  Better indentation.  Don't
17605         increment buffer pointer beyond buffer end.  Based on comments
17606         from Paul Eggert <eggert@cs.ucla.edu>.
17607
17608         * lib/base64.h: Indent.
17609
17610 2005-06-28  Simon Josefsson  <jas@extundo.com>
17611
17612         * doc/gnulib.texi (Library version handling): New section.
17613
17614 2005-06-28  Jim Meyering  <jim@meyering.net>
17615
17616         * check-module (find_included_lib_files): Hard-code another
17617         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
17618         but modules/fts-lgpl (correctly) does not list those files.
17619
17620         * modules/canonicalize (Files): Add lib/pathmax.h.
17621
17622 2005-06-25  Simon Josefsson  <jas@extundo.com>
17623
17624         * modules/check-version: New file.
17625
17626 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
17627
17628         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
17629         initializer of struct addrinfo, as an indication that we don't
17630         care how many members the structure has.
17631
17632 2005-06-24  Derek Price  <derek@ximbiot.com>
17633         and Bruno Haible  <bruno@clisp.org>
17634
17635         Remove stat module & update lstat.
17636         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
17637         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
17638         * m4/stat.m4: Remove this file.
17639
17640 2005-06-24  Derek Price  <derek@ximbiot.com>
17641         and Bruno Haible  <bruno@clisp.org>
17642
17643         Remove stat module & update lstat.
17644         * lib/stat.c: Remove this file...
17645         (slash_aware_lstat): ...moving this content and its support...
17646         * lib/lstat.c (rpl_lstat): ...into here.
17647         * lib/lstat.h: New file.
17648
17649 2005-06-24  Derek Price  <derek@ximbiot.com>
17650         and Bruno Haible  <bruno@clisp.org>
17651
17652         Remove stat module & update lstat.
17653         * config/srclist.txt (libc sources): Remove stat.
17654
17655 2005-06-24  Derek Price  <derek@ximbiot.com>
17656         and Bruno Haible  <bruno@clisp.org>
17657
17658         Remove stat module & update lstat.
17659         * MODULES.html.sh (stat): Remove.
17660         * MODULES.html: Regenerated.
17661         * modules/lstat (Description): Correct function name.
17662         (Files): Add "lstat.h".
17663         (Depends-on): Remove stat, add xalloc, stat-macros.
17664         * modules/stat: Remove this file.
17665         (Include): Add "lstat.h", remove <sys/stat.h>.
17666
17667 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
17668
17669         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
17670         (ranged_convert): Don't save conversion in a temporary struct.
17671         This causes a warning with GCC 4.0.0, and anyway in the typical
17672         case it's not worth the extra 100 bytes or so of code.
17673         (ranged_convert, __mktime_internal): When calling a function via a
17674         pointer P, use P () rather than (*P) (), as we now assume C89 or
17675         better.
17676
17677 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
17678
17679         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
17680         "who -r" failed to give output.  Problem reported by Tim Waugh.
17681
17682         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
17683         (xcalloc): Use it to avoid needless tests.
17684         Problem reported by Jim Meyering.
17685
17686 2005-06-20  Derek Price  <derek@ximbiot.com>
17687
17688         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
17689         unnecessary for Autoconfs > 2.59c.
17690
17691 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17692
17693         * lib/argp.h (__option_is_short): Check upper limit of
17694         __key. Isprint() requires its argument to have the value
17695         of an unsigned char or EOF.
17696
17697 2005-06-16  Jim Meyering  <jim@meyering.net>
17698
17699         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
17700         when either N or S is zero.
17701
17702 2005-06-16  Derek Price  <derek@ximbiot.com>
17703
17704         * m4/bison.m4: Declare YACC & YFLAGS precious.
17705
17706 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
17707
17708         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
17709         multibyte string or pattern, fall back on unibyte matching.
17710         Problem reported by James Youngman.
17711
17712 2005-06-08  Bruno Haible  <bruno@clisp.org>
17713
17714         * modules/csharpcomp: New file.
17715         * MODULES.html.sh (C#): Add csharpcomp.
17716
17717 2005-06-08  Bruno Haible  <bruno@clisp.org>
17718
17719         * m4/csharpcomp.m4: New file, from GNU gettext.
17720
17721 2005-06-08  Bruno Haible  <bruno@clisp.org>
17722
17723         * lib/csharpcomp.h: New file, from GNU gettext.
17724         * lib/csharpcomp.c: New file, from GNU gettext.
17725         * lib/csharpcomp.sh.in: New file, from GNU gettext.
17726
17727 2005-06-08  Bruno Haible  <bruno@clisp.org>
17728
17729         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
17730         warning on mingw.
17731
17732 2005-06-07  Derek Price  <derek@ximbiot.com>
17733
17734         Sync from CVS.
17735         * lib/glob_.h: Indent nested #ifdef.
17736
17737 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17738
17739         Sync from coreutils.
17740         Use "file name" when talking about file names, instead of "filename"
17741         or "path", as per the GNU coding standards.
17742         * lib/mkdir-p.c: Renamed from makepath.c.
17743         (make_dir_parents): Renamed from make_path.  All callers changed.
17744         * lib/mkdir-p.h: Likewise.  All includers changed.
17745         * lib/filenamecat.c: Renamed from path-concat.c.
17746         (file_name_concat): Renamed from path_concat.  All callers changed.
17747         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
17748         * lib/filenamecat.h: Likewise.  All includers changed.
17749         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
17750         in comments or local variable names.
17751         * lib/basename.c: Likewise.
17752         * lib/canonicalize.c, canonicalize.h: Likewise.
17753         * lib/dirname.c, dirname.h: Likewise.
17754         * lib/euidaccess.c: Likewise.
17755         * lib/exclude.c: Likewise
17756         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
17757         * lib/fsusage.c, fsuage.h: Likewise.
17758         * lib/fts.c, fts_.h: Likewise.
17759         * lib/getcwd.c: Likewise.
17760         * lib/getloadavg.c: Likewise.
17761         * lib/mkstemp.c: Likewise.
17762         * lib/mountlist.c, mountlist.h: Likewise.
17763         * lib/openat.c, openat.h: Likewise.
17764         * lib/readlink-stub.c: Likewise.
17765         * lib/readutmp.c, readutmp.h: Likewise.
17766         * lib/rename.c: Likewise.
17767         * lib/rmdir.c: Likewise.
17768         * lib/same.c: Likewise.
17769         * lib/savedir.c: Likewise.
17770         * lib/stripslash.c: Likewise.
17771         * lib/tempname.c: Likewise.
17772         * lib/xreadlink.c: Likewise.
17773         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
17774         All uses changed.
17775         * lib/exclude.h: Likewise.
17776
17777         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
17778         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17779         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
17780         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17781         * lib/pathmax.h: Include <limits.h> unconditionally, since other
17782         files have been getting away with it for years (MORE/BSD 4.3
17783         is extinct now).
17784         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
17785         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
17786
17787         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
17788         Define to 256, not 255, as per modern POSIX.
17789
17790 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17791
17792         Sync from coreutils.
17793         Use "file name" when talking about file names, instead of "filename"
17794         or "path", as per the GNU coding standards.
17795         * MODULES.html.sh: mkdir-p renamed from makepath.
17796         filenamecat renamed from path-concat.
17797         * modules/filenamecat: Renamed from modules/path-concat.
17798         (Files): filenamecat.h and filenamecat.c renamed from
17799         path-concat.h and path-concat.c.
17800         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
17801         (Include): filenamecat.h, not path-concat.h.
17802         * modules/mkdir-p: Renamed from modules/makepath.
17803         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
17804         makepath.c.
17805         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
17806         (Include): mkdir-p.h, not makepath.h.
17807
17808 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
17809
17810         Sync from coreutils.
17811         * m4/mkdir-p.m4: Renamed from makepath.m4.
17812         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
17813         Rename files from makepath.c to mkdir-p.c, and from
17814         makepath.h to mkdir-p.h.
17815         * m4/filenamecat.m4: Renamed from path-concat.m4.
17816         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
17817         Rename files from path-concat.c to filenamecat.c,
17818         and from path-concat.h to filenamecat.h.
17819         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
17820         "file name" in local variables or comments.
17821         * m4/rename.m4: Likewise.
17822
17823 2005-06-01  Bruno Haible  <bruno@clisp.org>
17824
17825         * modules/csharpexec: New file.
17826         * MODULES.html.sh (C#): New section.
17827
17828 2005-06-01  Bruno Haible  <bruno@clisp.org>
17829
17830         * m4/csharp.m4: New file, from GNU gettext.
17831         * m4/csharpexec.m4: New file, from GNU gettext.
17832
17833 2005-06-01  Bruno Haible  <bruno@clisp.org>
17834
17835         * lib/csharpexec.h: New file, from GNU gettext.
17836         * lib/csharpexec.c: New file, from GNU gettext.
17837         * lib/csharpexec.sh.in: New file, from GNU gettext.
17838
17839 2005-05-31  Derek Price  <derek@ximbiot.com>
17840             Paul Eggert  <eggert@cs.ucla.edu>
17841
17842         Sync from cvs.
17843         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
17844
17845 2005-05-31  Derek Price  <derek@ximbiot.com>
17846             Paul Eggert  <eggert@cs.ucla.edu>
17847
17848         Sync from cvs.
17849         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
17850
17851 2005-05-29  Derek Price  <derek@ximbiot.com>
17852
17853         * config/srclist.txt (glob_.h, glob.c): Add these files.
17854
17855 2005-05-29  Derek Price  <derek@ximbiot.com>
17856
17857         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
17858         * modules/glob: New file.
17859         * modules/getlogin_r: Add link to POSIX spec in description.
17860
17861 2005-05-29  Derek Price  <derek@ximbiot.com>
17862             Paul Eggert  <eggert@cs.ucla.edu>
17863
17864         * m4/glob.m4: New file.
17865
17866 2005-05-29  Derek Price  <derek@ximbiot.com>
17867             Paul Eggert  <eggert@cs.ucla.edu>
17868
17869         * lib/glob_.h, lib/glob.c: New files.
17870
17871 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17872
17873         * modules/fts (Files): Remove m4/inttypes-pri.m4.
17874         * modules/fts-lgpl (Depends-on): Remove gettext.
17875
17876 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17877
17878         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
17879         and don't require gt_INTTYPES_PRI.
17880
17881 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
17882
17883         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
17884
17885         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
17886         the configuration hassle isn't worth it.
17887         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
17888         (LONGEST_MODIFIER, PRIuMAX): Remove.
17889
17890 2005-05-27  Bruno Haible  <bruno@clisp.org>
17891
17892         * lib/getlogin_r.h: Remove second include of <stddef.h>.
17893
17894 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
17895
17896         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
17897         _POSIX_PTHREAD_SEMANTICS for Solaris.
17898
17899 2005-05-25  Derek Price  <derek@ximbiot.com>
17900
17901         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
17902
17903 2005-05-25  Derek Price  <derek@ximbiot.com>
17904             Paul Eggert  <eggert@cs.ucla.edu>
17905
17906         * modules/getlogin_r, m4/getlogin_r.m4: New files.
17907         * lib/getlogin_r.c, getlogin_r.h: New files.
17908
17909 2005-05-25  Bruno Haible  <bruno@clisp.org>
17910             Derek Price  <derek@ximbiot.com>
17911
17912         * lib/getlogin_r.h: Simplify API documentation.
17913
17914 2005-05-23  Derek Price  <derek@ximbiot.com>
17915
17916         * modules/minmax (Files): Add m4/minmax.m4.
17917         (configure.ac): Add gl_MINMAX.
17918
17919 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
17920
17921         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
17922         so that unistd-safer.h (GPL'ed code) need not be included.
17923
17924 2005-05-22  Bruno Haible  <bruno@clisp.org>
17925
17926         * m4/minmax.m4: New file.
17927         Based on a patch by Derek Price <derek@ximbiot.com>.
17928
17929 2005-05-22  Bruno Haible  <bruno@clisp.org>
17930
17931         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
17932         (INT64_MIN): Fix definition.
17933         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
17934
17935         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
17936         NEED_SIGNED_INT_TYPES.
17937
17938         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
17939         HAVE_SYSTEM_INTTYPES.
17940
17941 2005-05-22  Bruno Haible  <bruno@clisp.org>
17942
17943         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
17944         Also include <sys/param.h> if it defines MIN, MAX.
17945         Based on a patch by Derek Price <derek@ximbiot.com>.
17946
17947 2005-05-21  Jim Meyering  <jim@meyering.net>
17948
17949         * modules/fts (Files): Add m4/inttypes-pri.m4.
17950         (Depends-on): Add lstat and remove gettext.  Alphabetize.
17951
17952 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17953
17954         New fts module.
17955         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
17956         (setup_dir, free_dir): New functions.
17957         (enter_dir, leave_dir): Define trivial
17958         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
17959         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
17960         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
17961         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
17962         Move to fts-cycle.c.
17963         (fts_open): Use setup_dir.
17964         (fts_close): Use free_dir.
17965         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
17966         This adds a label and some gotos, but the alternatives were messier.
17967         Check for memory allocation failure when entering a dir.
17968         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
17969         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
17970         (FTS): New member fts_cycle, that is a union that contains the
17971         old active_dir_ht and cycle_state.  All uses changed to mention
17972         fts_cycle.ht and fts_cycle.state.
17973         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
17974         fts.c, with the following changes:
17975         (setup_dir, free_dir): New functions.
17976         (enter_dir): Now returns bool.  Return true if successful, false
17977         if memory exhausted.  All callers changed.
17978         Do not bother partly cleaning up on
17979         memory allocation failure; that is free_dir's job.
17980         However, free ad if hash_insert fails, to avoid memory leak.
17981         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
17982         fts->fts_options to see which union member to use.
17983
17984 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17985
17986         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
17987         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
17988
17989 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
17990
17991         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
17992
17993 2005-05-20  Jim Meyering  <jim@meyering.net>
17994
17995         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
17996         Now a macro, to pacify GCC.
17997
17998 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
17999
18000         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
18001         of -1.
18002
18003 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
18004
18005         * lib/chown.c (rpl_chown): Return -1 on failure.
18006
18007 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
18008
18009         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
18010         Don't check for stddef.h.
18011         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
18012         don't use its results.
18013         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
18014         since we include them unconditionally.  Don't require
18015         AM_STDBOOL_H, since stdbool is a prerequisite.
18016         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
18017         since we assume C89 or better.
18018         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
18019         as we don't use their results.
18020         Don't check for fchdir, memmove, memset, strrchr, as we use
18021         them unconditionally.
18022         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
18023         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
18024
18025 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
18026
18027         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
18028         Include <stddef.h> unconditionally, since we assume C89 now.
18029         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
18030         * lib/fts.c: Include fts_.h first, to check interface.
18031         Do not include intprops.h; no longer needed.
18032         Include cycle-check.h and hash.h, since fts_.h no longer does.
18033         Remove unnecessary casts of closedir to void.
18034         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
18035         decide whether to decrement nlinks.
18036         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
18037         (FTS): Use struct hash_table * instead of Hash_table, so that
18038         we no longer need to include hash.h here.
18039
18040 2005-05-18  Jim Meyering  <jim@meyering.net>
18041
18042         * modules/dirfd (License): Change to LGPL.  Most of the code
18043         is already in the public domain.
18044
18045 2005-05-18  Jim Meyering  <jim@meyering.net>
18046
18047         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
18048         Reported by Yoann Vandoorselaere.
18049
18050 2005-05-17  Jim Meyering  <jim@meyering.net>
18051
18052         * m4/fts.m4: New file, from coreutils.
18053
18054 2005-05-17  Jim Meyering  <jim@meyering.net>
18055
18056         * lib/fts.c, lib/fts_.h: New files, from coreutils.
18057
18058 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
18059
18060         Sync from coreutils.
18061         * m4/unlinkdir.m4: New file.
18062
18063 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
18064
18065         Sync from coreutils.
18066         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
18067         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
18068         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
18069         White space changes only.
18070         * lib/makepath.c (make_path): Port to hosts where leading "//" is
18071         special.
18072         * lib/yesno.c: Include getline.h, not ctype.h.
18073         (yesno): Don't remove leading white space; POSIX doesn't allow it.
18074         Use getline to remove arbitrary restriction on response length.
18075
18076 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
18077
18078         * config/srclist-update: Spell out "Street" in FSF postal
18079         mail address; this is the style the FSF seems to prefer.
18080
18081         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
18082         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
18083         this updates FSF postal mail address.
18084
18085         Sync from coreutils.
18086         * modules/unlinkdir: New file.
18087         * modules/yesno (Depends-on): Add getline.
18088         * MODULES.html.sh (File system functions): Add unlinkdir.
18089
18090 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
18091
18092         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
18093         lib/strsep.h:
18094         Change the initial comment to refer to GPL, not LGPL.
18095         gnulib-tool will change it to LGPL as needed.
18096
18097         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
18098         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
18099         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
18100         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
18101         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
18102         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
18103         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
18104         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
18105         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
18106         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
18107         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
18108         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
18109         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
18110         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
18111         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
18112         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
18113         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
18114         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
18115         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
18116         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
18117         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
18118         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
18119         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
18120         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
18121         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
18122         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
18123         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
18124         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
18125         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
18126         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
18127         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
18128         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
18129         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
18130         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
18131         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
18132         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
18133         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
18134         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
18135         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
18136         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
18137         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
18138         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
18139         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
18140         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
18141         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
18142         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
18143         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
18144         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
18145         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
18146         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
18147         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
18148         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
18149         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
18150         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
18151         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
18152         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
18153         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
18154         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
18155         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
18156         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
18157         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
18158         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
18159         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
18160         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
18161         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
18162         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
18163         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
18164         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
18165         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
18166         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
18167         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
18168         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
18169         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
18170         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
18171         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
18172         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
18173         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
18174         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
18175         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
18176         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
18177         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
18178         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
18179         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
18180         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
18181         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
18182         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
18183         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
18184         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
18185         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
18186         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
18187         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
18188         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
18189         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
18190         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
18191         lib/yesno.c, lib/yesno.h:
18192         Update FSF postal mail address.
18193
18194 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
18195
18196         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
18197         tests/test-memmem.c, tests/test-stpncpy.c:
18198         Update FSF postal mail address.
18199
18200 2005-05-13  Bruno Haible  <bruno@clisp.org>
18201
18202         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
18203         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
18204         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
18205         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
18206         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
18207         Add support for 64-bit integers in the MSVC compiler.
18208
18209 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18210
18211         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
18212
18213 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
18214
18215         * gnulib-tool (func_import): Sort and uniquify recommended includes.
18216
18217 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
18218
18219         * doc/getdate.texi (General date syntax): Don't say that date
18220         date --iso-8601=ns generates acceptable dates; it doesn't yet.
18221         Problem reported by Nic Ferrier.
18222
18223 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18224
18225         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
18226         specified in ai_socktype. Fix invalid ai_protocol
18227         check. ai_protocol is usually set to 0 or depending on
18228         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
18229         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
18230         ai_socktype / ai_protocol in the returned addrinfo structure.
18231
18232 2005-05-10  Simon Josefsson  <jas@extundo.com>
18233
18234         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
18235         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
18236
18237 2005-05-10  Karl Berry  <karl@gnu.org>
18238
18239         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
18240         (from http://www.gnu.org/licenses).
18241         * doc/COPYING.LIB: also rename to COPYING.LESSER.
18242         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
18243         fdl.texi suffices.
18244
18245 2005-05-10  Karl Berry  <karl@gnu.org>
18246
18247         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
18248         (COPYING.DOC): remove.
18249
18250         * config/srclist-update: new FSF address.
18251
18252 2005-05-10  Derek Price  <derek@ximbiot.com>
18253
18254         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
18255         possible.
18256
18257 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18258             Bruno Haible  <bruno@clisp.org>
18259
18260         * modules/inet_ntop: New file.
18261         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18262         inet_ntop.
18263
18264 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18265             Bruno Haible  <bruno@clisp.org>
18266
18267         * m4/inet_ntop.m4: New file.
18268
18269 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
18270             Bruno Haible  <bruno@clisp.org>
18271
18272         * lib/inet_ntop.h: New file.
18273         * lib/inet_ntop.c: New file, from glibc with modifications.
18274
18275 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
18276
18277         * modules/time_r (License): Change to LGPL.
18278         * modules/extensions (License): Change to LGPL.  Actually,
18279         the license is more permissive than that, but currently gnulib-tool
18280         doesn't know how to handle more-permissive licenses.
18281
18282         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
18283         Problem reported by Dave Love.
18284
18285 2005-05-08  Jim Meyering  <jim@meyering.net>
18286
18287         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
18288         blank.
18289
18290 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
18291
18292         * modules/argmatch (Depends-on): Add stdbool.
18293         * modules/backupfile (Depends-on): Likewise.
18294         * modules/chdir-long (Depends-on): Likewise.
18295         * modules/closeout (Depends-on): Likewise.
18296         * modules/cycle-check (Depends-on): Likewise.
18297         * modules/dirname (Depends-on): Likewise.
18298         * modules/fnmatch (Depends-on): Likewise.
18299         * modules/fsusage (Depends-on): Likewise.
18300         * modules/fwriteerror (Depends-on): Likewise.
18301         * modules/getcwd (Depends-on): Likewise.
18302         * modules/getloadavg (Depends-on): Likewise.
18303         * modules/hard-locale (Depends-on): Likewise.
18304         * modules/makepath (Depends-on): Likewise.
18305         * modules/mountlist (Depends-on): Likewise.
18306         * modules/nanosleep (Depends-on): Likewise.
18307         * modules/posixtm (Depends-on): Likewise.
18308         * modules/quotearg (Depends-on): Likewise.
18309         * modules/readtokens (Depends-on): Likewise.
18310         * modules/readtokens0 (Depends-on): Likewise.
18311         * modules/readutmp (Depends-on): Likewise.
18312         * modules/save-cwd (Depends-on): Likewise.
18313         * modules/strftime (Depends-on): Likewise.
18314         * modules/userspec (Depends-on): Likewise.
18315         * modules/utimecmp (Depends-on): Likewise.
18316         * modules/xgetcwd (Depends-on): Likewise.
18317         * modules/xnanosleep (Depends-on): Likewise.
18318         * modules/xstrtod (Depends-on): Likewise.
18319         * modules/yesno (Depends-on): Likewise.
18320
18321 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
18322
18323         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
18324         needless checks.
18325
18326 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
18327
18328         Merge from coreutils.  Among other things,
18329         add bulletproofing for cases where stdin, stdout, or stderr are closed.
18330         * lib/fd-safer.c: New file.
18331         * lib/fcntl-safer.h, open-safer.c: Remove.
18332         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
18333         * lib/dup-safer.c: Include unistd-safer.h first.
18334         Don't include errno.h.
18335         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
18336         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
18337         * lib/file-type.c: Rely on file-type.h change.
18338         * lib/getloadavg.c: Include unistd-safer.h.
18339         (getloadavg): Use safer open.
18340         * lib/getusershell.c: Include "stdio-safer.h".
18341         (getusershell): Use safer fopen.
18342         * lib/long-options.c (long_options): Use NULL rather than 0.
18343         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
18344         'free'.
18345         * lib/modechange.c: Likewise.
18346         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
18347         (MODE_DONE): New constant.
18348         (struct mode_change): Remove 'next' member.
18349         (make_node_op_equals): New function; like the old one of the
18350         same name, except it allocates an array.
18351         (mode_compile, mode_create_from_ref): Use it.
18352         (mode_compile): Allocate result as an array, not a linked list.
18353         Parse octal string ourself, so that we catch mistakes like "+0".
18354         (mode_adjust): Arg is an array, not a linked list.
18355         * lib/modechange.c: Include stat-macros.h, xalloc.h.
18356         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
18357         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
18358         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
18359         Remove.  This is now stat-macros.h's job.
18360         (talloc): Remove.  All callers replaced by xalloc, so that
18361         our invokers don't have to worry about reporting memory failures.
18362         (make_node_op_equals): Remove.
18363         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
18364         New constants.
18365         (struct mode_change): Moved here from modechange.h.
18366         (mode_append_entry): Remove.
18367         (mode_compile): Remove MASKED_OPS arg, since it encouraged
18368         apps to have incorrect behavior.  Use simpler algorithm for head
18369         and tail.  Don't futz with umask; that's now the job of mode_adjust.
18370         Detect more invalid usages rather than having somewhat-random behavior.
18371         Don't insert an "a=" action, as that leads to incorrect behavior.
18372         (mode_compile, mode_create_from_ref): Return NULL on error instead
18373         of an enum, since now there's only one way to have an error.  All
18374         callers changed.
18375         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
18376         at the correct time.  Simplify calculation of "+u" and its ilk.
18377         Don't mishandle "+X".
18378         (mode_free): Remove "register" and localize decls.
18379         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
18380         (struct mode_change): Move to modechange.c; callers don't
18381         need to see this stuff.
18382         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
18383         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
18384         (mode_change, mode_adjust): Reflect the new signatures noted above.
18385         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
18386         that might redefine system include files.
18387         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
18388         (my_usleep): Use NULL rather than (void *) 0.
18389         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
18390         Use siginterrupt to specify that system calls should be interrupted.
18391         (rpl_nanosleep): Move initialization of suspended closer to call of
18392         my_usleep.
18393         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
18394         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
18395         (desirable_utmp_entry): New function.
18396         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
18397         using x2nrealloc, to simplify logic.
18398         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
18399         size calculation.  Do not assume utmp file is a regular file.
18400         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
18401         (READ_UTMP_CHECK_PIDS): New constant.
18402         * lib/save-cwd.c: Include unistd-safer.h.
18403         (save_cwd): Use fd_safer.
18404         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
18405         [!_LIBC] Include "stat-macros.h" instead.
18406         * lib/unistd-safer.h (fd_safer): New decl.
18407
18408 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
18409
18410         * modules/getloadavg (Depends-on): Add unistd-safer.
18411         * modules/getusershell (Depends-on): Add stdio-safer.
18412         * modules/lstat (Depends-on): Remove xalloc.
18413         * modules/mkstemp (Depends-on): Add stat-macros.
18414         * modules/modechange (Depends-on): Remove xstrtol.
18415         Add stat-macros, xalloc.
18416         * modules/save-cwd (Depends-on): Add unistd-safer.
18417         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
18418         * modules/unistd-safer (Files): Add lib/fd-safer.c
18419         (Makefile.am): Remove lib_SOURCES.
18420
18421         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
18422         Remove fcntl-safer; unistd-safer supersedes it.
18423
18424 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
18425
18426         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
18427         AC_HEADER_STAT.
18428         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
18429         (gl_PREREQ_CHOWN): Remove.
18430         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
18431         it.  Don't require AC_HEADER_STAT.
18432         (gl_PREREQ_LSTAT): Remove.
18433         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
18434         Don't require AC_HEADER_STAT.
18435         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
18436         (gl_PREREQ_RMDIR): Remove.
18437         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
18438         mention stat-macros.h or AC_HEADER_STAT, since we'll make
18439         the stat-macros module a prerequisite.
18440         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
18441         * m4/filemode.m4 (gl_FILEMODE): Likewise.
18442         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
18443         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
18444         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
18445         variable names.
18446         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
18447         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
18448         variable prefixes.
18449         * m4/fcntl-safer.m4: Remove.
18450         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
18451         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
18452         Invoke gl_PREREQ_FD_SAFER.
18453         (gl_PREREQ_FD_SAFER): New macro.
18454         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
18455         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
18456         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
18457         Remove duplicate call to AC_LIBOBJ(readutmp).
18458         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
18459
18460         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
18461         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
18462
18463 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
18464
18465         * MODULES.html.sh (Misc): Add byteswap.
18466
18467 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
18468
18469         * modules/getcwd (Depends-on): Add extensions.
18470         * modules/openat (Depends-on): Likewise.
18471
18472 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
18473
18474         * modules/byteswap: New file.
18475
18476 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
18477
18478         * m4/byteswap.m4: New file.
18479
18480 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
18481
18482         * lib/byteswap_.h: New file.
18483
18484 2005-04-25  Karl Berry  <karl@gnu.org>
18485
18486         * m4/gettext.m4: Update from GNU gettext 0.14.4.
18487
18488 2005-04-25  Albert Chin  <china@thewrittenword.com>
18489
18490         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
18491         Toolkit C bug.
18492
18493 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
18494
18495         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
18496         (func_ln_if_changed) Remove forcibly for no error message
18497         in case file does not exist.
18498
18499 2005-04-19  Simon Josefsson  <jas@extundo.com>
18500
18501         * gnulib-tool (Options): Make --symlink mean --symbolic.
18502
18503 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
18504
18505         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
18506
18507 2005-04-16  Simon Josefsson  <jas@extundo.com>
18508
18509         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
18510
18511 2005-04-15  Simon Josefsson  <jas@extundo.com>
18512
18513         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
18514
18515 2005-04-15  Simon Josefsson  <jas@extundo.com>
18516
18517         * gnulib-tool: Rename --symlink to --symbolic.
18518
18519 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
18520
18521         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
18522         symbolic links to files instead of copying/moving.  Add --aux-dir,
18523         specifying directory relative --dir where auxiliary build tools
18524         are placed.
18525
18526 2005-04-14  Bruno Haible  <bruno@clisp.org>
18527
18528         * modules/allocsa (License): Change to LGPL.
18529         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
18530
18531 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
18532
18533         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
18534         that "UTC +1 second" continues to work.  Problem reported
18535         by Dmitry V. Levin.
18536         (relunit_snumber): New rule.
18537         (relunit): Use it.
18538
18539 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
18540
18541         * lib/getdate.y (universal_time_zone_table): New constant.
18542         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
18543         universal_time_zone_table.
18544         (lookup_zone): Prefer universal_time_zone_table to
18545         local_time_zone_table, so that "GMT" time stamps are allowed in
18546         London during the summer.  Problem reported by Ian Abbott.
18547
18548 2005-04-12  Jim Meyering  <jim@meyering.net>
18549
18550         * lib/human.c (humblock): Set *options even when returning due to
18551         xstrtoumax conversion failure.  Thanks to a used-uninitialized
18552         warning from gcc-4.
18553
18554 2005-04-09  Jim Meyering  <jim@meyering.net>
18555
18556         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
18557         -Wuninitialized: initialize tm0.tm_year.
18558
18559 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
18560
18561         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
18562         count, since there's no maximum.  All uses changed.
18563         Add member dsts_seen.
18564         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
18565         not being INT_MAX.
18566         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
18567         Use pc_rels_seen to decide whther a date is absolute.
18568
18569         * lib/getdate.y (number): Don't overwrite year.
18570         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
18571         check.
18572
18573 2005-04-02  Simon Josefsson  <jas@extundo.com>
18574
18575         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
18576         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
18577
18578 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
18579
18580         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
18581         where no absolute path name can be longer than PATH_MAX.
18582
18583 2005-03-27  Jim Meyering  <jim@meyering.net>
18584
18585         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
18586
18587 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
18588
18589         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
18590         "one's complement" -> "ones' complement" in comment, as per Knuth.
18591         "value of type" -> "type or expression" in comment.
18592         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
18593
18594 2005-03-26  Jim Meyering  <jim@meyering.net>
18595
18596         Comment nits.
18597         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
18598         Correct typos: s/or/of/.
18599
18600 2005-03-26  Jim Meyering  <jim@meyering.net>
18601
18602         * modules/check-include-files: Move to ../ and rename to...
18603         * check-module: ...this.
18604
18605 2005-03-25  Jim Meyering  <jim@meyering.net>
18606
18607         * modules/xvasprintf (Files): Add xalloc.h.
18608
18609 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
18610
18611         * modules/gettext (Files): config/config.rpath ->
18612         build-aux/config.rpath
18613         * modules/iconv (Files): Likewise.
18614         Problem reported by Oskar Liljeblad.
18615
18616 2005-03-23  Jim Meyering  <jim@meyering.net>
18617
18618         * modules/check-include-files: New script to check for
18619         missing dependencies, multiple includes, etc.
18620
18621         * modules/c-strtold (Depends-on): Add xalloc.
18622         * modules/c-strtod (Depends-on): Add xalloc.
18623         * modules/hash (Depends-on): Add xalloc.
18624         (Files): Remove lib/xalloc.h.
18625
18626         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
18627         * modules/userspec (Files): Add lib/inttostr.h.
18628
18629 2005-03-23  Jim Meyering  <jim@meyering.net>
18630
18631         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
18632
18633 2005-03-22  Jim Meyering  <jim@meyering.net>
18634
18635         * modules/stat-macros: New module.
18636         * modules/canonicalize, modules/euidaccess, modules/file-type,
18637         * modules/filemode, modules/lchown, modules/makepath,
18638         * modules/rmdir, modules/stat: Depend on new stat-macros module
18639         rather than listing lib/stat-macros.h manually.
18640         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
18641
18642 2005-03-22  Jim Meyering  <jim@meyering.net>
18643
18644         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
18645
18646 2005-03-22  Bruno Haible  <bruno@clisp.org>
18647
18648         * config/srclist.txt: Replace target directory 'config' with
18649         'build-aux'.
18650         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
18651         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
18652         ../build-aux/.
18653
18654 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
18655
18656         * modules/chdir-long (Depends-on): Add mempcpy.
18657
18658         * modules/acl, modules/backupfile, modules/c-strtod,
18659         modules/c-strtold, modules/canon-host, modules/canonicalize,
18660         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
18661         modules/exclude, modules/exitfail, modules/file-type,
18662         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
18663         modules/getdate, modules/getline, modules/getpagesize,
18664         modules/getpass, modules/getugroups, modules/group-member,
18665         modules/hard-locale, modules/hash, modules/human, modules/idcache,
18666         modules/inttostr, modules/long-options, modules/makepath,
18667         modules/md5, modules/memcasecmp, modules/memcoll,
18668         modules/modechange, modules/mountlist, modules/path-concat,
18669         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
18670         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
18671         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
18672         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
18673         modules/strftime, modules/strndup, modules/strverscmp,
18674         modules/timespec, modules/unlocked-io, modules/userspec,
18675         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
18676         modules/yesno:
18677         Remove lib_SOURCES line from Makefile.am section, as this is now
18678         done automatically by the corresponding Autoconf macro.
18679
18680 2005-03-21  Jim Meyering  <jim@meyering.net>
18681
18682         Changes imported from coreutils.
18683
18684         * lib/cycle-check.c: Don't include xalloc.h.
18685
18686         * lib/path-concat.c: Don't include assert.h.
18687         (path_concat): Remove assertion that would have triggered
18688         for ABASE starting with more than one slash.
18689         Reported by Andreas Schwab.
18690
18691         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
18692         properly when ABASE is an absolute file name.
18693         Correct the description of this function.
18694         Include <assert.h>.
18695         Add an assertion and a test driver.
18696         This fixes a bug introduced on 2004-07-02.
18697         Andreas Schwab reported the resulting failure of cp --parents:
18698         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
18699
18700 2005-03-21  Jim Meyering  <jim@meyering.net>
18701
18702         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
18703         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
18704
18705 2005-03-21  Jim Meyering  <jim@meyering.net>
18706         and  Paul Eggert  <eggert@cs.ucla.edu>
18707
18708         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
18709         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
18710         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
18711         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
18712         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
18713         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
18714         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
18715         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
18716         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
18717         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
18718         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
18719         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
18720         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
18721         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
18722         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
18723         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
18724         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
18725         for these modules.
18726
18727 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
18728
18729         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
18730         (which shouldn't happen), generate nothing instead of returning 0
18731         immediately, so that nstrftime (NULL, ...) doesn't return 0.
18732
18733 2005-03-16  Bruno Haible  <bruno@clisp.org>
18734
18735         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
18736         HAVE_LONGLONG_64BIT.
18737
18738 2005-03-16  Bruno Haible  <bruno@clisp.org>
18739
18740         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
18741         HAVE_LONGLONG_64BIT.
18742
18743 2005-03-16  Bruno Haible  <bruno@clisp.org>
18744
18745         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
18746         HAVE_LONGLONG_64BIT.
18747
18748 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
18749
18750         * lib/strftime.c (my_strftime): Prepend space to format so that we can
18751         reliably distinguish strftime failure from empty output on POSIX
18752         hosts.
18753
18754 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
18755
18756         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
18757         (iconv_string): Don't guess a size-zero buffer, as that might cause
18758         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
18759         result would be 'too large', where 'too large' is (heuristically)
18760         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
18761         overflow concerns.  This will prevent some unwanted malloc failures
18762         when the inputs are very large.
18763
18764 2005-03-15  Karl Berry  <karl@gnu.org>
18765
18766         * config/srclist.txt (config.rpath): from gettext.
18767         * config/config.rpath: update.
18768
18769 2005-03-15  Bruno Haible  <bruno@clisp.org>
18770
18771         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
18772         to 'negate'.
18773
18774         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
18775         variable.
18776
18777         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
18778         results.
18779
18780 2005-03-14  Simon Josefsson  <jas@extundo.com>
18781
18782         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
18783         <fx@gnu.org>.
18784
18785 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
18786
18787         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
18788         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
18789         intprops.h.
18790         * lib/strtol.c: Likewise.
18791
18792 2005-03-14  Jim Meyering  <jim@meyering.net>
18793
18794         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
18795         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
18796         to be nonzero so that we (and caller) can detect the difference
18797         between a valid zero-length expansion and an error return, even
18798         when the underlying strftime fails before writing anything into
18799         that location.
18800
18801 2005-03-14  Bruno Haible  <bruno@clisp.org>
18802
18803         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
18804         Update from GNU gettext 0.14.3.
18805
18806 2005-03-10  Jim Meyering  <jim@meyering.net>
18807
18808         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
18809
18810 2005-03-10  Jim Meyering  <jim@meyering.net>
18811
18812         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
18813         so that this module works on systems without fchdir.
18814
18815 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
18816
18817         Factor int-properties macros into a single file, except for
18818         glibc-related files.
18819         * lib/intprops.h: New file.
18820         * lib/getloadavg.c: Include it instead of limits.h.
18821         (INT_STRLEN_BOUND): Remove.
18822         * lib/human.c: Include intprops.h.
18823         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
18824         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
18825         302/1000.
18826         * lib/inttostr.h: Include intprops.h instead of limits.h.
18827         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
18828         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
18829         for consistency with intprops.h.
18830         (time_t_is_integer, twos_complement_arithmetic): Use them.
18831         * lib/sig2str.h: Include <signal.h>, intprops.h.
18832         (INT_STRLEN_BOUND): Remove.
18833         * lib/strftime.c (TYPE_SIGNED): Remove.
18834         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
18835         * lib/strtol.c: Adjust comments to match intprops.h.
18836         * lib/userspec.c: Include intprops.h.
18837         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
18838         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
18839         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
18840         instead of rolling our own expressions.
18841         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
18842
18843         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
18844         instead of int.
18845         (my_strftime): Do not mishandle years close to INT_MAX, by doing
18846         the right thing even if adding 1900 would overflow.  Similarly
18847         for tm_mon + 1 and tm_yday + 1.
18848         Make %Y always equivalent to %C%y, and similarly for %G and %g.
18849         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
18850         (DO_SIGNED_NUMBER): New macro.
18851         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
18852
18853 2005-03-07  Bruno Haible  <bruno@clisp.org>
18854
18855         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
18856
18857 2005-03-07  Bruno Haible  <bruno@clisp.org>
18858
18859         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
18860
18861 2005-03-04  Derek R. Price  <derek@ximbiot.com>
18862
18863         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
18864         (func_import): Only replace files via --import when they have actually
18865         changed.
18866
18867 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18868
18869         * m4/mmap-anon.m4: New file.
18870         * m4/pagealign_alloc.m4: New file.
18871
18872 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18873             Bruno Haible  <bruno@clisp.org>
18874
18875         * modules/pagealign_alloc: New file.
18876         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
18877
18878 2005-03-03  Derek R. Price  <derek@ximbiot.com>
18879             Bruno Haible  <bruno@clisp.org>
18880
18881         * lib/pagealign_alloc.h: New file.
18882         * lib/pagealign_alloc.c: New file.
18883
18884 2005-03-03  Bruno Haible  <bruno@clisp.org>
18885
18886         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
18887         Use an all-permissive copyright notice, recommended by RMS.
18888
18889 2005-03-02  Bruno Haible  <bruno@clisp.org>
18890
18891         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
18892         of AIX, the replacement has to be done only after <string.h> is
18893         included, therefore not in config.h. stpncpy.h does the replacement,
18894         and stpncpy.c uses it.
18895
18896 2005-03-02  Bruno Haible  <bruno@clisp.org>
18897
18898         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
18899         stpncpy.c uses it.
18900
18901 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18902
18903         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
18904         The workaround isn't strictly needed for POSIX conformance, and
18905         it's too much of a pain to configure and maintain.  We'll ask
18906         people to fix their kernels instead.
18907         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
18908         (NANOSLEEP_BUG_WORKAROUND): Remove.
18909         (xnanosleep): Remove the workaround.
18910
18911 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18912
18913         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
18914         Reported by Derek Price.
18915         (Include): Add "timespec.h".
18916
18917         * modules/xnanosleep (Depends-on): Remove gethrxtime.
18918
18919 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
18920
18921         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
18922         to detect nanosleep bug.
18923
18924 2005-03-01  Bruno Haible  <bruno@clisp.org>
18925
18926         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
18927
18928 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
18929
18930         * modules/gethrxtime: New file.
18931         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
18932         (Depends-on): Add gethrxtime.
18933         (configure.ac): Add gl_XNANOSLEEP.
18934         (Makefile.am): Remove lib_SOURCES line.
18935
18936 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
18937
18938         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
18939         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
18940
18941 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
18942
18943         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
18944         * lib/timespec.h (gettime): Return void, since it always
18945         succeeds now.  All uses changed.
18946         * lib/gettime.c (gettime) Likewise.
18947         [HAVE_NANOTIME]: Prefer nanotime.
18948         Assume gettimeofday succeeds, as POSIX requires.
18949         Assime time () succeeds, since other code already does.
18950         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
18951         (timespec_subtract): Remove.
18952         (NANOSLEEP_BUG_WORKAROUND): New constant.
18953         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
18954         things considerably.  Use it only on GNU/Linux hosts, since the
18955         workaround shouldn't be needed elsewhere.
18956
18957 2005-02-24  Bruno Haible  <bruno@clisp.org>
18958
18959         * modules/gettext (Files): Add m4/glibc2.m4.
18960
18961 2005-02-24  Bruno Haible  <bruno@clisp.org>
18962
18963         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
18964         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
18965         * m4/progtest.m4:
18966         Update from GNU gettext 0.14.2.
18967         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
18968
18969 2005-02-24  Bruno Haible  <bruno@clisp.org>
18970
18971         * lib/localcharset.c: Update from GNU gettext 0.14.2.
18972         * lib/config.charset: Update from GNU gettext 0.14.2.
18973
18974 2005-02-24  Bruno Haible  <bruno@clisp.org>
18975
18976         * lib/gettext.h: Update from GNU gettext 0.14.2.
18977
18978 2005-02-23  Simon Josefsson  <jas@extundo.com>
18979
18980         * m4/iconvme.m4: New file.
18981
18982 2005-02-23  Jim Meyering  <jim@meyering.net>
18983
18984         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
18985         change.
18986         Thanks to Bruno Haible for catching it.
18987
18988 2005-02-22  Simon Josefsson  <jas@extundo.com>
18989
18990         * modules/iconvme: New file.
18991
18992         * MODULES.html.sh: Add iconvme.
18993
18994 2005-02-22  Simon Josefsson  <jas@extundo.com>
18995
18996         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
18997
18998 2005-02-22  Simon Josefsson  <jas@extundo.com>
18999
19000         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
19001
19002 2005-02-22  Jim Meyering  <jim@meyering.net>
19003
19004         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
19005         s/ifndef/ifdef/.
19006
19007 2005-02-20  Neil Conway  <neilc@samurai.com>
19008
19009         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
19010         returned by OSX/Darwin if the specified buffer is not large
19011         enough for the hostname.
19012
19013 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19014
19015         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
19016         pass it to _help, otherwise the latter coredumps trying to
19017         dereference state.root_argp.
19018
19019 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
19020
19021         * modules/chdir-long (Depends-on): Add memrchr.
19022         * modules/memrchr (Files): Add lib/memrchr.h.
19023         (Include): "memrchr.h".
19024
19025 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
19026
19027         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
19028
19029 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
19030
19031         * lib/memrchr.h: New file.
19032         * lib/chdir-long.c: Include it.
19033         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
19034         Don't bother including stddef.h.
19035
19036 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
19037
19038         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
19039         inclusion.
19040         Include <sys/types.h>, for dev_t.
19041         (ME_DUMMY, ME_REMOTE): Move from here....
19042         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
19043         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
19044         Dmitry V. Levin.
19045         Include mountlist.h first, to test the interface.
19046
19047 2005-01-29  Bruno Haible  <bruno@clisp.org>
19048
19049         * lib/progname.c (program_name): Initialize.
19050         Needed when linking statically on MacOS X.
19051
19052 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
19053
19054         Sync from coreutils.
19055         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
19056         (Depends-on): Add c-strtod.
19057         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
19058
19059 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
19060
19061         Sync from coreutils.
19062         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
19063
19064         Remove files that are specific to coreutils.
19065         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
19066
19067 2005-01-28  Bruno Haible  <bruno@clisp.org>
19068
19069         * modules/javacomp: New file.
19070         * MODULES.html.sh (Java): Add javacomp.
19071
19072 2005-01-28  Bruno Haible  <bruno@clisp.org>
19073
19074         * m4/javacomp.m4: New file, from GNU gettext.
19075
19076 2005-01-28  Bruno Haible  <bruno@clisp.org>
19077
19078         * lib/javacomp.sh.in: New file, from GNU gettext.
19079         * lib/javacomp.h: New file, from GNU gettext.
19080         * lib/javacomp.c: New file, from GNU gettext.
19081
19082 2005-01-26  Simon Josefsson  <jas@extundo.com>
19083
19084         * lib/gai_strerror.c: Use GPL in header.
19085
19086 2005-01-26  Bruno Haible  <bruno@clisp.org>
19087
19088         * modules/javaexec: New file.
19089         * MODULES.html.sh (Java): Add javaexec.
19090
19091 2005-01-26  Bruno Haible  <bruno@clisp.org>
19092
19093         * m4/javaexec.m4: New file, from GNU gettext.
19094
19095 2005-01-26  Bruno Haible  <bruno@clisp.org>
19096
19097         * lib/javaexec.sh.in: New file, from GNU gettext.
19098         * lib/javaexec.h: New file, from GNU gettext.
19099         * lib/javaexec.c: New file, from GNU gettext.
19100
19101 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19102
19103         * modules/lchown (Depends-on): Remove lchown.h
19104
19105 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19106
19107         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
19108         must be defined if the header file was not found, in order
19109         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
19110
19111 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19112
19113         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
19114         initializers for struct pentry_state.
19115         (__argp_error): Check return value of __asprintf
19116         (__argp_failure): Translate error message
19117
19118         * lib/argp-parse.c: Removed braces around the expansion of N_()
19119
19120 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
19121
19122         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
19123         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
19124         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
19125         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
19126         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
19127         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
19128         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
19129         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
19130         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
19131         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
19132         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
19133         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
19134         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
19135         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
19136         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
19137         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
19138         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
19139         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
19140         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
19141         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
19142         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
19143         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
19144         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
19145         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
19146         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
19147         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
19148         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
19149         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
19150         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
19151         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
19152         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
19153         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
19154         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
19155         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
19156         xstrtol.m4, xstrtoumax.m4, yesno.m4:
19157         Use an all-permissive copyright notice, recommended by RMS.
19158
19159 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
19160
19161         * modules/chdir-long (Depends-on): Remove mempcpy.
19162
19163 2005-01-21  Jim Meyering  <jim@meyering.net>
19164
19165         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
19166         same value as for Solaris 9.
19167
19168         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
19169         component length.  This included changing the parameter to be
19170         of type `char *' rather than `char const *'.
19171         * lib/chdir-long.h (chdir_long): Update prototype.
19172
19173         * lib/openat.c (fdopendir, fstatat): New functions.
19174         * lib/openat.h: Include headers required for use of DIR and struct
19175         stat.
19176         [AT_SYMLINK_NOFOLLOW]: Define.
19177         (fdopendir, fstatat): Add prototypes.
19178
19179 2005-01-21  Bruno Haible  <bruno@clisp.org>
19180
19181         * modules/classpath: New file.
19182         * MODULES.html.sh (Java): Add classpath.
19183
19184 2005-01-21  Bruno Haible  <bruno@clisp.org>
19185
19186         * lib/classpath.h: New file, from GNU gettext.
19187         * lib/classpath.c: New file, from GNU gettext.
19188
19189 2005-01-20  Simon Josefsson  <jas@extundo.com>
19190
19191         * modules/version-etc-fsf: New file.
19192
19193 2005-01-20  Simon Josefsson  <jas@extundo.com>
19194
19195         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
19196         * lib/version-etc.c: Remove version_etc_copyright.
19197         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
19198         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
19199
19200 2005-01-20  Simon Josefsson  <jas@extundo.com>
19201
19202         * lib/base64.h (isbase64): Add.
19203
19204         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
19205         using a unsigned prototype, don't inline.
19206         (base64_decode): Use it.
19207
19208 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
19209
19210         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
19211         it.
19212
19213 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
19214
19215         * lib/save-cwd.c (save_cwd): Remove code to support the case
19216         where fchdir is missing or flaky.
19217
19218 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
19219
19220         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
19221
19222 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
19223
19224         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
19225         AC_LIBSOURCES now does this.
19226         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
19227         with new ullong_max module.
19228
19229 2005-01-19  Bruno Haible  <bruno@clisp.org>
19230
19231         * modules/sh-quote: New file.
19232         * MODULES.html.sh (Executing programs): Add sh-quote.
19233
19234 2005-01-19  Bruno Haible  <bruno@clisp.org>
19235
19236         * lib/sh-quote.h: New file, from GNU gettext.
19237         * lib/sh-quote.c: New file, from GNU gettext.
19238
19239 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
19240
19241         Merge from coreutils.
19242         * m4/ullong_max.m4: New file.
19243         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
19244         (gl_MACROS): Assume localeconv exists.
19245
19246 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
19247
19248         Merge changes from coreutils, as described below in several
19249         changelogs dated today.
19250
19251         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
19252         (O_DIRECTORY): Remove; not needed here, since "." must be
19253         a directory.  All uses removed.
19254         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
19255         universal on Suns, and we also need to test for IRIX.
19256         Revamp code to use 'if' rather than '#if'.
19257         Avoid unnecessary comparison of cwd->desc to 0.
19258
19259         * lib/utimens.c (futimens): Robustify the previous patch, by checking
19260         for known valid error numbers rather than observed invalid ones.
19261
19262 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
19263
19264         * modules/ullong_max: New file.
19265
19266         * modules/chdir-long, modules/openat: New files.
19267         * modules/save-cwd (Depends-on): Depend on chdir-long.
19268         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
19269
19270 2005-01-18  Jim Meyering  <jim@meyering.net>
19271
19272         Merge from coreutils.
19273         * m4/chdir-long.m4, m4/openat.m4: New files.
19274         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
19275         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
19276         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
19277         is sane and DOES follow symlinks.  Besides, testing 20 different
19278         systems found no broken chown implementations.
19279         Prompted by a change in rsync's copy of this macro.
19280         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
19281
19282         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
19283
19284         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
19285         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
19286         NULL-means-set-to-current-time semantics.
19287         Remove temporary file immediately, rather than waiting
19288         for configure's at-exit trap code to do it.
19289
19290 2005-01-18  Jim Meyering  <jim@meyering.net>
19291
19292         * lib/version-etc.c (version_etc_copyright): Update copyright date.
19293
19294         * lib/utimens.c (futimens): Account for the fact that futimes
19295         can also fail with errno == ENOSYS or errno == ENOENT.
19296         Patch from Dmitry V. Levin.
19297
19298         Change the name of the robust chdir function from chdir to chdir_long.
19299         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
19300         (restore_cwd): Use chdir_long, not chdir.
19301         * lib/chdir-long.c: Renamed from chdir.c.
19302         * lib/chdir-long.h: Renamed from chdir.h.
19303         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
19304         Hurd.
19305
19306 2005-01-18  Bruno Haible  <bruno@clisp.org>
19307
19308         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
19309         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
19310         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
19311         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
19312         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
19313         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
19314         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
19315         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
19316         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
19317         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
19318         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
19319         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
19320         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
19321         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
19322         Use an all-permissive copyright notice, recommended by RMS.
19323
19324 2005-01-18  Bob Proulx  <bob@proulx.com>
19325
19326         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
19327         simplify offsetof() macro construct to avoid compile failure with
19328         native HP-UX 11.0 ANSI C compiler.
19329
19330 2005-01-17  Bruno Haible  <bruno@clisp.org>
19331
19332         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
19333         redundant because stpncpy.m4 takes care of it.
19334
19335 2005-01-17  Bruno Haible  <bruno@clisp.org>
19336
19337         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
19338
19339 2005-01-17  Bruno Haible  <bruno@clisp.org>
19340
19341         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
19342         used.
19343
19344 2005-01-17  Bruno Haible  <bruno@clisp.org>
19345
19346         * lib/fwriteerror.h (fwriteerror): Change specification to include
19347         fclose.
19348         * lib/fwriteerror.c: Include <stdbool.h>.
19349         (fwriteerror): At the end, close the file stream. Record whether
19350         stdout was already closed.
19351
19352 2005-01-17  Bruno Haible  <bruno@clisp.org>
19353
19354         * lib/execute.c (environ): Declare if needed.
19355         * lib/pipe.c (environ): Likewise.
19356         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
19357
19358 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19359
19360         * modules/argp: Depend on vsnprintf
19361
19362 2005-01-10  Jim Meyering  <jim@meyering.net>
19363
19364         * modules/closeout (Depends-on): Add atexit.
19365
19366 2005-01-06  Bruno Haible  <bruno@clisp.org>
19367
19368         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
19369
19370 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
19371
19372         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
19373         definitions to be after all include files, to avoid collisions.
19374         Problem reported by Bob Proulx.
19375
19376 2005-01-04  Jim Meyering  <jim@meyering.net>
19377
19378         Changes imported from coreutils.
19379         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
19380         as the mkstemp template, use a temporary directory and an
19381         8.3-friendly template to avoid trouble on systems like DJGPP.
19382         Reported by Juan M. Guerrero via Stepan Kasal.
19383         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
19384         close. Remove the temporary directory right away, rather than waiting
19385         for configure's at-exit trap code to do it.
19386         Suggestion from Stepan Kasal.
19387
19388 2005-01-01  Simon Josefsson  <jas@extundo.com>
19389
19390         * gnulib-tool: Print #include directives when --import'ing.
19391
19392 2004-12-28  Simon Josefsson  <jas@extundo.com>
19393
19394         * tests/test-base64.c: Include required header files.  Remove
19395         unused variables.
19396
19397 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
19398
19399         * modules/error (Depends-on): Remove gettext.
19400
19401 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
19402
19403         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
19404         not needed.  This removes a dependency on the gettext module.
19405         [defined _LIBC]: Do not include <libintl.h>; not needed.
19406
19407 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
19408
19409         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
19410         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
19411
19412 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
19413
19414         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
19415         HAVE_DECL_STRTOLD.
19416
19417 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
19418
19419         * modules/getdate (Depends-on): Remove alloca-opt.
19420
19421 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
19422
19423         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
19424
19425 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
19426
19427         * lib/argp-parse.c: Include <stddef.h>.
19428         (alignof, alignto): New macros.
19429         (parser_init): Don't assume that void * is aligned sufficiently
19430         for struct option.
19431
19432         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
19433         need to extend the stack.
19434         (YYINITDEPTH): New macro, so that the initial stack isn't overly
19435         large.
19436
19437 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19438
19439         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
19440
19441 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
19442
19443         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
19444         (2004-10-24) change.  Apparently this was a false alarm.
19445
19446         * modules/getdate: Depend on alloca-opt, not alloca.
19447
19448 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
19449
19450         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
19451         Remove now-obsolete comment about AIX.
19452         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
19453         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
19454         (YYMAXDEPTH): New macro.
19455
19456 2004-12-18  Simon Josefsson  <jas@extundo.com>
19457
19458         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
19459
19460 2004-12-18  Bruno Haible  <bruno@clisp.org>
19461
19462         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
19463
19464 2004-12-18  Bruno Haible  <bruno@clisp.org>
19465
19466         * lib/fatal-signal.c (fatal_signals): Make non-const.
19467         (init_fatal_signals): New function.
19468         (uninstall_handlers, install_handlers): Ignore signals that were set to
19469         SIG_IGN.
19470         (at_fatal_signal): Call init_fatal_signals.
19471         (init_fatal_signal_set): Likewise. Ignore signals that were set to
19472         SIG_IGN.
19473         Reported by Paul Eggert.
19474
19475 2004-12-18  Bruno Haible  <bruno@clisp.org>
19476
19477         * doc/alloca.texi: New file.
19478         * doc/alloca-opt.texi: New file.
19479
19480 2004-12-17  Jim Meyering  <jim@meyering.net>
19481
19482         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
19483         Otherwise, install-sh could exit with improper exit status when
19484         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
19485
19486 2004-12-16  Simon Josefsson  <jas@extundo.com>
19487
19488         * tests/test-base64.c: Add license.
19489
19490 2004-12-15  Stepan Kasal  <address@hidden>
19491
19492         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
19493
19494 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
19495
19496         * modules/getcwd (Files): Add m4/d-ino.m4.
19497         Suggested by Mark D. Baushke.
19498
19499 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
19500
19501         * lib/getdate.y (textint): New member "negative".
19502         (time_zone_hhmm): New function.
19503         Expect 14 shift-reduce conflicts, not 13.
19504         (o_colon_minutes): New rule.
19505         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
19506         (yylex): Set the "negative" member of signed numbers.
19507
19508 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
19509
19510         * doc/getdate.texi (Time of day items, Time zone items):
19511         Describe new formats +00:00, UTC+00:00.
19512
19513 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
19514
19515         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
19516         spurious "-l"s.  Problem reported by Stepan Kasal.
19517
19518 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
19519
19520         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
19521         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
19522
19523 2004-12-04  Simon Josefsson  <jas@extundo.com>
19524
19525         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
19526         Vandoorselaere <yoann@prelude-ids.org>.
19527
19528 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19529
19530         Changes imported from coreutils.
19531         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
19532         exist.
19533         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
19534
19535 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19536
19537         Changes imported from coreutils.
19538         * lib/hard-locale.c: Assume <locale.h> exists.
19539         Include "strdup.h".
19540         (GLIBC_VERSION): New macro.
19541         (hard_locale): Assume setlocale exists.
19542         Rewrite to avoid #ifdef.
19543         Use strdup rather than malloc + strcpy.
19544         * lib/human.c: Assume <locale.h> exists.
19545         (human_readable): Assume localeconv exists.
19546
19547 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
19548
19549         * modules/hard-locale (Depends-on): Add strdup.
19550
19551 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
19552
19553         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
19554         convert T2, not T.  (Imported from libc.)
19555
19556 2004-11-30  Simon Josefsson  <jas@extundo.com>
19557
19558         * modules/restrict (License): Change to LGPL.
19559
19560 2004-11-30  Simon Josefsson  <jas@extundo.com>
19561
19562         * m4/restrict.m4: Add copyright and copying conditions.
19563
19564 2004-11-30  Simon Josefsson  <jas@extundo.com>
19565
19566         * m4/base64.m4: New file.
19567
19568 2004-11-30  Simon Josefsson  <jas@extundo.com>
19569
19570         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
19571         base64.
19572
19573         * tests/test-base64.c: New file.
19574
19575         * modules/base64: New file.
19576
19577 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
19578
19579         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
19580         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
19581
19582         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
19583
19584 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
19585
19586         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
19587         (__getcwd.c): Don't restore errno; glibc doesn't.
19588         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
19589         first, falling back to our code only if its results look suspicious.
19590         Ensure that the resulting buffer is only as large as necessary.
19591
19592         * lib/readutmp.c: Include readutmp.h first.
19593         Include <errno.h>, since readutmp.h no longer does that.
19594         * lib/readutmp.h: Don't include <errno.h>,
19595         <sys/param.h>, <time.h>; not needed to establish interface.
19596         (errno): Remove decl.
19597         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
19598         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
19599         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
19600
19601 2004-11-28  Simon Josefsson  <jas@extundo.com>
19602
19603         * lib/base64.h, base64.c: New file.
19604
19605 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
19606
19607         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
19608
19609 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
19610
19611         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
19612         (Depends-on): Remove pathmax, same.  Add mempcpy.
19613         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
19614         (Makefile.am): Append getcwd.h to lib_SOURCES.
19615         (Include): Add getcwd.h.
19616         (Maintainer): Change from Jim Meyering to "all, glibc",
19617         since getdate now uses intended-for-glibc code.
19618         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
19619         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
19620
19621 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
19622
19623         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
19624         HP's ANSI C compiler.
19625         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
19626         Declaring int functions causes warnings on some modern systems and
19627         shouldn't be needed to compile on ancient ones.
19628         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
19629         defined.
19630
19631         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
19632         with the following changes.
19633         (__set_errno): Parenthesize properly.
19634         Include <stdbool.h>.
19635         (MIN, MAX, MATCHING_INO): New macros.
19636         (__getcwd): Define with prototype, not K&R form.
19637         Use heuristics to allocate default buffer on stack if possible.
19638         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
19639         behavior, and to avoid the PATH_MAX limit when computing
19640         ../../../../...
19641         Use MATCHING_INO to compare inode number to file.
19642         Check for arithmetic overflow in size calculations.
19643         Fix bug in reallocation of dot array that caused getcwd to fail
19644         on directories nested deeper than 75.
19645         Be more careful about saving errno on error.
19646         Do not use realloc; use only free+malloc, as this is a bit
19647         more flexible and avoids a needless copy operation.
19648         Do not inspect st_dev and st_ino for symbolic links; POSIX
19649         doesn't specify the latter.
19650         Check for closedir errors.
19651         Avoid needless casts.
19652         Use "#ifdef weak_alias" around weak_alias, to be like other
19653         glibc code.
19654         The following changes to getcwd.c have effect only when used in
19655         gnulib; they have no effect inside glibc proper.
19656         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
19657         as alloca isn't used.
19658         (alloca, __alloca): Likewise.
19659         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
19660         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
19661         unconditionally, as gnulib assumes C89 or better.
19662         Do not include <sys/param.h>.
19663         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
19664         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
19665         better.
19666         (NULL) [!defined NULL]: Remove; we assume C89 or better.
19667         Include <dirent.h> in a way that is compatible with modern Autoconf.
19668         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
19669         New macros, if not already defined.
19670         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
19671         Use "_LIBC", not "defined _LIBC", for consistency.
19672         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
19673         a mempcpy module.
19674         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
19675         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
19676         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
19677         credit only to Jim Meyering and adjust the copyright dates.
19678         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
19679         <stdlib.h>, <unistd.h>, "pathmax.h".
19680         Instead, include "xgetcwd.h" (first) and "getcwd.h".
19681         (INITIAL_BUFFER_SIZE): Remove.
19682         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
19683
19684 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
19685
19686         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
19687         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
19688         Use the _ONCE methods, for efficiency.
19689         Check for fcntl.h.  In test program, include <errno.h>
19690         and <fcntl.h> if available.  Remove old K&R cruft from
19691         test program.  Check for common errors in GNU/Linux,
19692         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
19693         don't do AC_LIBOBJ, as that's getcwd.m4's job.
19694         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
19695         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
19696         name accordingly.
19697         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
19698         accommodate new getcwd.c.
19699         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
19700         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
19701         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
19702         that's all we need now.
19703
19704 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19705
19706         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
19707         argp-parse.c depends on getopt internals, that means we should
19708         always use our getopt, to be on the safe side.
19709         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
19710         order not to spoil the result of an eventual previous invocation
19711         of gl_GETOPT_SUBSTITUTE.
19712
19713 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19714
19715         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
19716         redefinition warnings. To avoid them, include the defines
19717         in `#if !defined __need_getopt ... #endif'. The only place
19718         where __getopt_argv_const is used is in definitions
19719         of getopt_long and getopt_long_only below, which are as well
19720         protected by `#ifndef __need_getopt'.
19721         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
19722         __need_getopt after including <stdio.h> and <unistd.h> These
19723         headers might have defined it.
19724
19725 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
19726
19727         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
19728
19729 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
19730
19731         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
19732         (futimens): New function, which uses futimes if available.
19733         (futimens, utimens): Support timespec==NULL, with same semantics
19734         as utime and utimens.
19735         * lib/utimens.h (futimens): New decl.
19736
19737 2004-11-23  Jim Meyering  <jim@meyering.net>
19738
19739         * lib/getopt_.h: Remove trailing blanks.
19740
19741 2004-11-23  Jim Meyering  <jim@meyering.net>
19742
19743         * lib/__fpending.c: Add comment.
19744
19745 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
19746
19747         * modules/canonicalize (Depends-on): Add xreadlink.
19748         Problem reported by James Youngman.
19749
19750 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
19751
19752         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
19753         New macros.
19754         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
19755         optopt): Use them instead of invoking ## directly; otherwise, the
19756         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
19757
19758 2004-11-19  Bruno Haible  <bruno@clisp.org>
19759
19760         * lib/strtok_r.c: Move comments from here...
19761         * lib/strtok_r.h: ... to here.
19762
19763 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
19764
19765         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
19766         implementations that mishandle size_t overflow.
19767
19768 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
19769
19770         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
19771         might fail.  Problem reported by Yoann Vandoorselaere.
19772         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
19773         implementations that mishandle size_t overflow.
19774
19775 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19776
19777         * modules/canon-host (Depends-on): Add strdup.
19778
19779 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19780
19781         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
19782
19783 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19784
19785         * lib/canon-host.c: Include "strdup.h".
19786         (canon_host): Use getaddrinfo if available, so that IPv6 works.
19787         Use strdup instead of malloc/strcpy to duplicate strings.
19788
19789         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
19790         (human_space_before_unit): New constant.
19791         * lib/human.c (human_readable): Support it.
19792
19793         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
19794         (xgetcwd): Set errno correctly when failing.
19795         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
19796         the failure is actually due to a PATH_MAX problem.
19797
19798         Further getopt changes to make it more likely that glibc will
19799         buy the changes back.
19800         * lib/getopt.c (POSIXLY_CORRECT): New constant.
19801         (getopt): Use it, so to preserve glibc semantic
19802         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
19803         when compiling for libc.
19804         * lib/getopt_.h (__getopt_argv_const): Bring it back.
19805         (getopt_long, getopt_long_only): Use it.
19806
19807         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
19808         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
19809         (getopt): Argv is now char * const *, as per standard.
19810         (_getopt_internal_r, _getopt_internal): Argv is now char **,
19811         not char *__getopt_argv_const *.
19812         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
19813         _getopt_long_only_r): Likewise.
19814         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
19815         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
19816         _getopt_long_r, _getopt_long_only_r): Likewise.
19817         * lib/getopt_.h (__getopt_argv_const): Remove.
19818         (getopt): Argv is now char * const *, as per standard.
19819
19820         * lib/getdate.y (tORDINAL): New token.
19821         (day, relunit): Allow it for relative times.
19822         (relative_time_table): Use tORDINAL for ordinals.
19823
19824 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
19825
19826         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
19827         Document that "second" isn't allowed as an ordinal number.
19828
19829 2004-11-16  Jim Meyering  <jim@meyering.net>
19830
19831         * modules/closeout (Depends-on): Add fpending.
19832
19833 2004-11-15  Jim Meyering  <jim@meyering.net>
19834
19835         * lib/closeout.c: Include "__fpending.h" once again.
19836         Include <stdbool.h>.
19837         (close_stdout): Don't fail just because stdout was closed initially,
19838         since some programs don't write to stdout in the normal course of
19839         operation (other than --version and --help), and we don't want this
19840         function to make e.g. `touch file >&-' fail.
19841         But do fail if it was closed and someone has tried to write to it.
19842         E.g., `printf foo >&-' must fail.
19843
19844 2004-11-13  Jim Meyering  <jim@meyering.net>
19845
19846         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
19847
19848 2004-11-12  Simon Josefsson  <jas@extundo.com>
19849
19850         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
19851         small doc fix is still pending.
19852
19853 2004-11-11  Simon Josefsson  <jas@extundo.com>
19854
19855         * modules/strtok_r: New file.
19856
19857         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19858         strtok_r.
19859
19860 2004-11-11  Simon Josefsson  <jas@extundo.com>
19861
19862         * m4/strtok_r.m4: New file.
19863
19864         * m4/getopt.m4: Replace opterr.
19865
19866 2004-11-11  Simon Josefsson  <jas@extundo.com>
19867
19868         * lib/strtok_r.h, strtok_r.c: New file.
19869
19870 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
19871
19872         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
19873         of replacing opterr, getopt, etc.  This should handle the
19874         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
19875
19876 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
19877
19878         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
19879         we can stop lying to compilers about the constness of argv when we
19880         are compiled outside glibc.
19881         (getopt, getopt_long, getopt_long_only): Use it.
19882         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
19883         _getopt_internal, getopt): Likewise.
19884         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
19885         _getopt_long_only_r): Likewise.
19886         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
19887         _getopt_long_r, _getopt_long_only_r): Likewise.
19888
19889         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
19890         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
19891         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
19892         the other external symbols.
19893         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
19894         declaration, since the above renaming now works around collisions.
19895
19896 2004-11-11  Jim Meyering  <jim@meyering.net>
19897
19898         * lib/linebreak.c: Remove trailing blanks.
19899         * lib/alloca_.h: Likewise.
19900         * lib/acosl.c: Likewise.
19901         * lib/euidaccess.c: Likewise.
19902         * lib/allocsa.h: Likewise.
19903
19904 2004-11-10  Simon Josefsson  <jas@extundo.com>
19905
19906         * m4/getaddrinfo.m4: New file.
19907
19908 2004-11-10  Simon Josefsson  <jas@extundo.com>
19909
19910         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
19911
19912 2004-11-10  Simon Josefsson  <jas@extundo.com>
19913
19914         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19915         getaddrinfo.
19916
19917         * modules/getaddrinfo: New file.
19918
19919 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
19920
19921         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
19922
19923 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
19924
19925         * lib/mktime.c (SHR): New macro, which is a portable
19926         substitute for >> that should work even on Crays.
19927         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
19928         Problem reported by Mark D. Baushke in
19929         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
19930         * lib/getdate.y (SHR): Likewise.
19931         (tm_diff): Use it.
19932         * lib/strftime.c (SHR): Likewise.
19933         (tm_diff): Use it.
19934         * lib/quotearg.c (struct quoting_options): Use unsigned int for
19935         quote_these_too, so that right shifts are well defined.  All uses
19936         changed.
19937
19938 2004-11-10  Jim Meyering  <jim@meyering.net>
19939
19940         Ensure that no close failure goes unreported.
19941         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
19942         return early when it seems there's nothing to flush.
19943         Don't include __fpending.h.
19944
19945 2004-11-10  Jim Meyering  <jim@meyering.net>
19946
19947         * modules/closeout (Depends-on): Remove fpending.
19948
19949 2004-11-10  Jim Meyering  <jim@meyering.net>
19950
19951         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
19952
19953 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
19954
19955         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
19956         gl_FUNC_STRFTIME.
19957         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
19958         and AC_REQUIRE when possible, to avoid duplicate checks.
19959         Check for <wchar.h>.
19960
19961 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
19962
19963         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
19964
19965 2004-11-09  Bruno Haible  <bruno@clisp.org>
19966
19967         * m4/sockpfaf.m4: New file.
19968
19969 2004-11-05  Bruno Haible  <bruno@clisp.org>
19970
19971         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
19972         Reported by Mark D. Baushke <mdb@cvshome.org>.
19973
19974 2004-11-04  Bruno Haible  <bruno@clisp.org>
19975
19976         2004-09-11  Bruno Haible  <bruno@clisp.org>
19977                 * allocsa.valgrind: New file.
19978         2004-02-06  Bruno Haible  <bruno@clisp.org>
19979                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
19980                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
19981                 Reported by Christopher Seip <chris.seip@hp.com>.
19982
19983 2004-11-04  Bruno Haible  <bruno@clisp.org>
19984
19985         * modules/allocsa (Files): Add lib/allocsa.valgrind.
19986         (Makefile.am): Distribute it.
19987
19988 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
19989
19990         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
19991         with errno == ERANGE if the buffer is too small.
19992         Problem reported by Mark D. Baushke.
19993
19994 2004-11-03  Albert Chin  <china@thewrittenword.com>
19995             Paul Eggert  <eggert@cs.ucla.edu>
19996
19997         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
19998         equivalent, substitute $ac_type for equivalent type rather than
19999         blindly using uint32_t *always* which won't work if uint32_t is not
20000         available.  Define _UINT32_T to work around typedef of uint32_t if
20001         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
20002         2.5.1.
20003
20004 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
20005
20006         * m4/jm-macros.m4: Sync from coreutils.
20007         (gl_MACROS): Check for mbrlen, for pathchk.
20008         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
20009
20010 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
20011
20012         * lib/xreadlink.c (MAXSIZE): New macro.
20013         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
20014         size does not exceed MAXSIZE.  Avoid cast.
20015         As suggested by Mark D. Baushke in
20016         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
20017         if readlink fails with buffer size just under MAXSIZE, try again
20018         with MAXSIZE.
20019
20020 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
20021
20022         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
20023
20024 2004-11-02  Derek R. Price  <derek@ximbiot.com>
20025         and  Paul Eggert  <eggert@cs.ucla.edu>
20026
20027         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
20028         (get_date): Overparenthesize to avoid GCC warning.
20029
20030 2004-11-02  Bruno Haible  <bruno@clisp.org>
20031
20032         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
20033         returns void.
20034
20035 2004-11-02  Bruno Haible  <bruno@clisp.org>
20036
20037         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
20038         function returns void.
20039
20040 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
20041
20042         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
20043         fflush_unlocked, flockfile, funlockfile, funlockfile,
20044         fputs_unlocked, putc_unlocked.
20045
20046 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
20047
20048         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
20049         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
20050         already declared.
20051
20052 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
20053
20054         * modules/getdate (Files): Add doc/getdate.texi.
20055         (Depends-on): Add setenv, xalloc.
20056
20057 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
20058
20059         * lib/getdate.y: Add support for TZ="foo" within a date string.
20060         Fix some bugs near time_t boundaries.  Reject dates with
20061         out-of-range components, e.g., "Sept 31".
20062         Include <stdlib.h>, "setenv.h", "xalloc.h".
20063         (ISDIGIT_LOCALE): Remove; unused.
20064         Note that the TZ and time functions used here are not reentrant.
20065         (mktime_ok, get_tz): New functions.
20066         (TZBUFSIZE): New constant.
20067         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
20068         This requires that we sometimes generate our own TZ="XXX..." setting.
20069
20070 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
20071
20072         * doc/getdate.texi: New file, from coreutils with modifications for
20073         the new TZ parsing.
20074
20075 2004-10-27  Derek R. Price  <derek@ximbiot.com>
20076
20077         * lib/mktime.c (not_equal_tm): Remove redundant check.
20078
20079 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
20080
20081         * modules/regex (lib_SOURCES): Add regex.c.
20082         Reported by James Youngman in
20083         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
20084
20085 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
20086
20087         * lib/getdate.y: Use Bison 1.875 features, and some minor
20088         code cleanups.  This change does not affect semantics.
20089         Don't include <stdlib.h>; no longer needed.
20090         Don't include unlocked-io.h; only the "#if TEST" code uses
20091         stdio, and performance isn't crucial there.
20092         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
20093         Bison 1.875 features as described below.
20094         All uses of "PC." replaced by "pc->".
20095         (YYSTYPE): Add a forward declaration.
20096         (yylex, yyerror): Use full prototypes in forward decls.
20097         Use "%pure-parser" rather than obsolescent "%pure_parser".
20098         Use %parse-param and %lex-param instead of obsolescent
20099         YYPARSE_PARAM and YYLEX_PARAM.
20100         (meridian_table, month_and_day_table, time_units_table,
20101         relative_time_table, time_zone_table, military_table,
20102         lookup_zone, lookup_word, get_date):
20103         Use NULL instead of 0 where appropriate.
20104         (to_hour): Avoid abort (), to avoid a dependency on
20105         stdlib.h.
20106         (yyerror, yylex): Now accepts parser_control * arg.
20107         (main) [TEST]: Use '\0' rather than 0 for char.
20108
20109 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
20110
20111         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
20112
20113 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
20114
20115         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
20116         It's now the caller's responsibility to handle the case where
20117         !HAVE_GETPAGESIZE && !defined getpagesize.
20118
20119         * lib/mktime.c (leapyear): Arg is long int, not int.
20120
20121 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
20122
20123         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
20124
20125 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
20126
20127         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
20128         missing.  Problem reported by James Youngman.
20129
20130 2004-10-16  Simon Josefsson  <jas@extundo.com>
20131
20132         * gnulib-tool: Fix comments.  Fix parse problem.
20133         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
20134
20135 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
20136
20137         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
20138         implementation of getopt_long.  Problem reported by Alexander Taler in:
20139         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
20140
20141 2004-10-15  Bruno Haible  <bruno@clisp.org>
20142
20143         * gnulib-tool: Untabify. Initialize supplied_libname.
20144         (func_usage): More homogenous output.
20145         (func_modules_transitive_closure, func_modules_to_filelist,
20146         func_emit_lib_Makefile_am): New functions.
20147         (func_import): New function, extracted from big case statement. Use
20148         func_get_license, func_modules_transitive_closure,
20149         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
20150         opt_lgpl. Don't use test -a, as it's not portable.
20151         (func_create_testdir): Use func_modules_transitive_closure,
20152         func_modules_to_filelist, func_emit_lib_Makefile_am.
20153
20154 2004-10-15  Bruno Haible  <bruno@clisp.org>
20155
20156         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
20157
20158 2004-10-15  Bruno Haible  <bruno@clisp.org>
20159
20160         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
20161         the portions belonging to each module.
20162         Suggested by Derek Robert Price <derek@ximbiot.com>.
20163
20164 2004-10-12  Simon Josefsson  <jas@extundo.com>
20165
20166         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
20167         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
20168         to real functions.
20169
20170 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20171
20172         * modules/vsnprintf: New file.
20173
20174 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20175
20176         * m4/vsnprintf.m4: New file.
20177
20178 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20179
20180         * lib/vsnprintf.h: New file.
20181         * lib/vsnprintf.c: New file.
20182
20183 2004-10-11  Bruno Haible  <bruno@clisp.org>
20184
20185         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
20186         vsnprintf.
20187
20188 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
20189
20190         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
20191
20192 2004-10-07  Bruno Haible  <bruno@clisp.org>
20193
20194         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
20195         fits into the provided buffer.
20196
20197 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
20198
20199         * lib/diacrit.c, diacrit.h: Add GPL notice.
20200
20201         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
20202         notice.
20203         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
20204         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
20205         This avoids a potential constant-folding bug.
20206
20207 2004-10-05  Bruno Haible  <bruno@clisp.org>
20208
20209         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
20210         for the declaration of strsep.
20211
20212 2004-10-05  Bruno Haible  <bruno@clisp.org>
20213
20214         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
20215
20216 2004-10-04  Simon Josefsson  <jas@extundo.com>
20217
20218         * modules/memmem: New file.
20219         * tests/test-memmem.c: New file.
20220         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
20221
20222 2004-10-04  Simon Josefsson  <jas@extundo.com>
20223
20224         * m4/memmem.m4: New file.
20225
20226 2004-10-04  Simon Josefsson  <jas@extundo.com>
20227
20228         * lib/memmem.h: New file.
20229         * lib/memmem.c: New file, taken from glibc.
20230
20231 2004-10-04  Simon Josefsson  <jas@extundo.com>
20232
20233         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
20234         '#ifdef USE_UNLOCKED_IO'.
20235
20236 2004-10-04  Simon Josefsson  <jas@extundo.com>
20237
20238         * config/srclist.txt: Add memmem from glibc.
20239
20240 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
20241
20242         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
20243
20244         * modules/argmatch, modules/argp, modules/closeout, modules/error,
20245         modules/exclude, modules/getdate, modules/getline,
20246         modules/getndelim2, modules/getpass, modules/getpass-gnu,
20247         modules/getusershell, modules/linebuffer, modules/md5,
20248         modules/mountlist, modules/posixtm, modules/readtokens,
20249         modules/readutmp, modules/regex, modules/sha1,
20250         modules/version-etc, modules/yesno:
20251         Remove dependency on unlocked-io.
20252
20253 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
20254
20255         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
20256
20257         * m4/unlocked-io.m4: Add copyright notice.
20258         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
20259
20260 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
20261
20262         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
20263         * lib/xmalloc.c (xmemdup): Likewise.
20264         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
20265         XFREE): Remove these long-obsolescent macros.
20266         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
20267         * lib/xstrdup.c: Remove.
20268
20269         * lib/regex.c (re_comp): Cast gettext return value to char *,
20270         Problem reported by Martin Neitzel via Mark D. Baushke.
20271
20272 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
20273
20274         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
20275         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
20276         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
20277         regex.c, sha1.c, version-etc.c, yesno.c:
20278         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
20279         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
20280         the includer's responsibility.
20281
20282         Sync from coreutils.
20283
20284         * lib/modechange.c (mode_compile): Don't decrement a pointer that
20285         points to the start of a string, as the C Standard says the
20286         resulting behavior is undefined.
20287
20288         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
20289         simple -> simple_backups, numbered_existing ->
20290         numbered_existing_backups, numbered -> numbered_backups
20291         to avoid shadowing problems.  All uses changed.
20292         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
20293         * lib/backupfile.c (check_extension, numbered_backup):
20294         Rename locals to avoid shadowing 'basename'.
20295         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
20296         once.
20297
20298         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
20299         * lib/.cvsignore: Add getopt.h.
20300
20301 2004-10-04  Bruno Haible  <bruno@clisp.org>
20302
20303         * modules/README: New file.
20304         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
20305         not a module.
20306
20307 2004-10-02  Jim Meyering  <jim@meyering.net>
20308
20309         * lib/dirfd.h, getpagesize.h: Add copyright notice.
20310
20311 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20312
20313         * modules/strsep: New file.
20314
20315 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20316
20317         * m4/strsep.m4: New file.
20318
20319 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
20320
20321         * lib/strsep.h: New file.
20322         * lib/strsep.c: New file.
20323
20324 2004-10-01  Simon Josefsson  <jas@extundo.com>
20325
20326         * lib/snprintf.c (snprintf): Handle size==0.
20327
20328 2004-10-01  Simon Josefsson  <jas@extundo.com>
20329             Bruno Haible  <bruno@clisp.org>
20330
20331         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
20332         (snprintf): Declare 'args'.
20333
20334 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
20335
20336         * lib/snprintf.c: Remove comments as to why each header is needed.
20337
20338 2004-10-01  Bruno Haible  <bruno@clisp.org>
20339
20340         * MODULES.html.sh: Add strsep.
20341
20342 2004-09-30  Simon Josefsson  <jas@extundo.com>
20343
20344         * modules/snprintf: New file.
20345
20346 2004-09-30  Simon Josefsson  <jas@extundo.com>
20347
20348         * m4/snprintf.m4: New file.
20349
20350 2004-09-30  Simon Josefsson  <jas@extundo.com>
20351
20352         * lib/snprintf.h, lib/snprintf.c: New files.
20353
20354 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
20355
20356         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
20357         (hol_entry_help): Never translate an empty string.
20358         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
20359         * lib/argp.h (OPTION_NO_TRANS): New option.
20360
20361 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
20362
20363         * modules/argp (Maintainer): Replace Simon Josefsson
20364         by Sergey Poznyakoff.
20365
20366 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
20367
20368         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
20369         changes merged back into glibc.
20370
20371 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
20372
20373         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
20374
20375 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
20376
20377         * lib/xvasprintf.c: Include xalloc.h.
20378         (xvasprintf): Use xalloc_die, not xmalloc_die.
20379
20380 2004-09-29  Bruno Haible  <bruno@clisp.org>
20381
20382         * modules/alloca-opt: New file, derived from modules/alloca.
20383         * modules/allocsa: Depend on alloca-opt instead of alloca.
20384         * modules/setenv: Likewise.
20385         * modules/vasnprintf: Likewise.
20386         * MODULES.html.sh: Add alloca-opt.
20387
20388 2004-09-28  Simon Josefsson  <jas@extundo.com>
20389
20390         * gnulib-tool: New parameter --lgpl, to asseert that modules are
20391         LGPL, and to replace license template from GPL to LGPL.
20392
20393 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
20394
20395         * modules/dummy: Change license to LGPL.
20396
20397 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
20398
20399         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
20400
20401 2004-09-24  Simon Josefsson  <jas@extundo.com>
20402
20403         * modules/minmax (License): Change from GPL to LGPL.
20404
20405 2004-09-23  Simon Josefsson  <jas@extundo.com>
20406
20407         * gnulib-tool (--import): Typo.
20408
20409 2004-09-23  Simon Josefsson  <jas@extundo.com>
20410
20411         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
20412
20413 2004-09-22  Bruno Haible  <bruno@clisp.org>
20414
20415         * modules/*: Add 'License' field.
20416         * gnulib-tool: Accept --extract-license option.
20417         (func_get_license): New function.
20418
20419 2004-09-21  Bruno Haible  <bruno@clisp.org>
20420
20421         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
20422         Reported by Simon Josefsson.
20423
20424 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
20425
20426         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
20427         gl_AC_TYPE_LONG_LONG.
20428
20429 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
20430
20431         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
20432
20433 2004-09-18  Simon Josefsson  <jas@extundo.com>
20434         and  Paul Eggert  <eggert@cs.ucla.edu>
20435
20436         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
20437         calls with autoreconf.  Define GL_LIB.
20438
20439 2004-09-14  Karl Berry  <karl@gnu.org>
20440
20441         * config/srclist.txt: unsync setenv.c, sigh.
20442
20443 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
20444
20445         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
20446         Problem reported by Bruno Haible in:
20447         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
20448
20449 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
20450
20451         * config/srclist.txt: Comment out argp-pvh.c.
20452
20453 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
20454
20455         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
20456         in case some system header has #define'd it.  Problem reported by
20457         Soeren D. Schulze in
20458         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
20459
20460 2004-09-09  Karl Berry  <karl@gnu.org>
20461
20462         * regex.[ch]: delete from the root.  These were supposed to be
20463                 synced with emacs cvs, but this has not happened for about
20464                 a year, and anyway nothing else uses emacs regex.[ch].
20465                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
20466                 lib/regex[.ch] is untouched.
20467
20468 2004-09-09  Bruno Haible  <bruno@clisp.org>
20469
20470         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
20471
20472 2004-09-09  Bruno Haible  <bruno@clisp.org>
20473
20474         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
20475         modifications.
20476         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
20477
20478 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
20479
20480         * modules/xvasprintf: New file.
20481         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
20482
20483 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
20484
20485         * lib/xvasprintf.h: New file.
20486         * lib/xvasprintf.c: New file.
20487         * lib/xasprintf.c: New file.
20488
20489 2004-09-08  Bruno Haible  <bruno@clisp.org>
20490
20491         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
20492
20493 2004-09-08  Bruno Haible  <bruno@clisp.org>
20494
20495         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
20496         length is > INT_MAX.
20497         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
20498         more.
20499
20500 2004-09-08  Bruno Haible  <bruno@clisp.org>
20501
20502         * lib/stdint_.h: New file, taken from GNU clisp.
20503
20504 2004-09-08  Bruno Haible  <bruno@clisp.org>
20505             Oskar Liljeblad  <oskar@osk.mine.nu>
20506
20507         * modules/stdint: New file.
20508         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
20509
20510 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20511
20512         Import from coreutils.
20513         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
20514         strings on unbounded length.  alloca's performance benefits aren't
20515         that important here.
20516         (V_STRDUP): Remove.
20517         (parse_with_separator): New function, with most of the internals
20518         of the old parse_user_spec.  Allow user to omit both user and group,
20519         for compatibility with FreeBSD.
20520         Clone only the user name, not the entire spec.
20521         Do not set *uid, *gid unless entirely successful.
20522         Avoid memory leak in some failing cases.
20523         Fix regression for USER.GROUP reported by Dmitry V. Levin in
20524         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
20525         (parse_user_spec): Rewrite to use parse_with_separator.
20526
20527 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20528
20529         * modules/userspec: Don't depend on alloca.
20530
20531 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
20532
20533         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
20534
20535 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
20536
20537         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
20538         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
20539         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
20540
20541 2004-08-16  Simon Josefsson  <jas@extundo.com>
20542
20543         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
20544         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
20545         Add --dry-run for --import.
20546         Let user provided command line parameters override configure.ac
20547         settings.
20548
20549 2004-08-12  Simon Josefsson  <jas@extundo.com>
20550
20551         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
20552         as discussed with Paul Eggert in threads rooted at
20553         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
20554         and
20555         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
20556         Before, the test was empty, and relied on ELIDE_CODE in source
20557         code.)
20558         (gl_PREREQ_GETOPT): New macro.
20559         (gl_GETOPT): Use them.
20560
20561 2004-08-12  Simon Josefsson  <jas@extundo.com>
20562
20563         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
20564         * lib/getopt_.h: Renamed from getopt.h.
20565
20566 2004-08-12  Simon Josefsson  <jas@extundo.com>
20567
20568         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
20569         Change default library name from libfoo to libgnu.
20570         Now, if you have a configure.ac that says:
20571                 gl_SOURCE_BASE(gl)
20572                 gl_M4_BASE(gl/m4)
20573                 gl_MODULES(error getopt etcetera)
20574                 gl_INIT
20575         you can import all you need by running:
20576                 ../gnulib/gnulib-tool --import
20577
20578         * modules/getopt (Files): Rename getopt.h to getopt_.h.
20579         (Makefile.am): Rewrite, use logic from argz.
20580         (Include): Use <getopt.h> instead of "getopt.h".
20581
20582 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20583
20584         * modules/argp (Files): Add m4/unlocked-io.m4.
20585         (Depends-on): Add extensions.
20586
20587 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20588
20589         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
20590         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
20591         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
20592         Check for program_invocation_name, program_invocation_short_name,
20593         flockfile, funlockfile, features.h, _getopt_long_only_r.
20594
20595 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20596
20597         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
20598         its complicated substitute.
20599         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
20600         and program_invocation_name.
20601         (__argp_basename) [!_LIBC]: Remove; the only use was
20602         replaced by its body.
20603         (__argp_short_program_name): Change condition from
20604         !defined __argp_short_program_name to
20605         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
20606         to match argp-namefrob.h.
20607         (__argp_failure): Don't assume strerror_r returns char *.
20608         * lib/argp-parse.c (N_): Define unconditionally.
20609         (argp_default_options): Fill out initializers with 0 to avoid
20610         gcc warnings.
20611
20612 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
20613
20614         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
20615         getopt1.c.
20616
20617 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20618
20619         Merge from coreutils.
20620
20621         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
20622
20623         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
20624         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
20625
20626 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20627
20628         Merge from coreutils.
20629
20630         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
20631         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
20632         for Reliant Unix 5.43.
20633
20634         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
20635         (union fooround): Use uintmax_t, not long int.
20636         The rest is a merge from libc:
20637         [defined _LIBC]: Include <shlib-compat.h>.
20638         (_obstack) [defined _LIBC]: Remove after 2.3.4.
20639
20640         * lib/settime.c (settime): Recode to avoid warning with
20641         Sun Forte C 6U2.
20642
20643         * lib/strverscmp.c: Convert to UTF-8.
20644
20645 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
20646
20647         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
20648         m4/uintmax_t.m4.
20649
20650 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20651
20652         * modules/xalloc-die: New file.
20653         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
20654
20655         * modules/md5 (Files): Add m4/uint32_t.m4.
20656         * modules/sha1: Renamed from modules/sha.
20657         (Files):
20658         Rename lib/sha.h to lib/sha1.h.
20659         Rename lib/sha.c to lib/sha1.c.
20660         Rename m4/sha.m4 to m4/sha1.m4.
20661         (lib_SOURCES): Likewise.
20662         (configure.ac): Rename gl_SHA to gl_SHA1.
20663         (Include): sha.h -> sha1.h.
20664
20665 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20666
20667         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
20668         * m4/sha1.m4: Renamed from sha.m4.
20669         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
20670
20671 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
20672
20673         * lib/obstack.h (obstack_empty_p):
20674         Don't assume that chunk->contents is suitably aligned.
20675         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
20676         Likewise. Problem reported by Benno in
20677         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
20678
20679         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
20680         readable.  This could be improved further but it'd take some work.
20681
20682 2004-08-08  Simon Josefsson  <jas@extundo.com>
20683
20684         * modules/xgethostname (Depends-on): Remove exit and error (not
20685         used).
20686
20687         * modules/getpass-gnu: Add getpass.h.
20688         (Depends-on): Add stdbool.
20689         * modules/getpass: Add getpass.h.
20690
20691 2004-08-08  Simon Josefsson  <jas@extundo.com>
20692
20693         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
20694         Check getpass declaration.
20695
20696 2004-08-08  Simon Josefsson  <jas@extundo.com>
20697
20698         * lib/xgethostname.c: Don't include error.h (not used).
20699
20700         * lib/getpass.h: Add.
20701         * lib/getpass.c: Include getpass.h first.
20702
20703 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
20704
20705         * lib/xalloc-die.c: New file.
20706         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
20707         All uses removed.
20708         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
20709         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
20710         xalloc-die.c.
20711         (_, N_, xalloc_die): Move to xalloc-die.c.
20712         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
20713         so that we needn't mess with xalloc_msg_memory_exhausted.
20714
20715         * lib/sha1.h: Renamed from sha.h.
20716         (SHA1_H): Renamed from _SHA_H.
20717         (sha1_ctx): Renamed from sha_ctx.
20718         (sha1_init_ctx): Renamed from sha_init_ctx.
20719         (sha1_process_block): Renamed from sha_process_block.
20720         (sha1_process_bytes): Renamed from sha_process_bytes.
20721         (sha1_finish_ctx): Renamed from sha_finish_ctx.
20722         (sha1_read_ctx): Renamed from sha_read_ctx.
20723         (sha1_stream): Renamed from sha_stream.
20724         (sha1_buffer): Renamed from sha_buffer.
20725         * lib/sha1.c: Likewise; renamed from sha.c.
20726         Do not include <sys/types.h>.
20727         Include <stddef.h> rather than <stdlib.h>.
20728
20729 2004-08-08  Bruno Haible  <bruno@clisp.org>
20730
20731         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
20732         FILESYSTEM_PREFIX_LEN.
20733         * lib/progreloc.c: Likewise.
20734         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
20735
20736 2004-08-06  Simon Josefsson  <jas@extundo.com>
20737
20738         * modules/progname (Depends-on): Don't depend on stdbool.
20739
20740 2004-08-06  Simon Josefsson  <jas@extundo.com>
20741
20742         * modules/getsubopt: New file.
20743         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
20744         getsubopt.
20745
20746 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20747
20748         More merge from coreutils.
20749
20750         * m4/utimens.m4, m4/utimecmp.m4: New files.
20751         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
20752         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
20753         prereq.m4, sha.m4: Import changes from coreutils.
20754
20755 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20756
20757         More merge from coreutils.
20758         * modules/raise, modules/readtokens0, modules/utimens:
20759         * modules/utimecmp, module/xnanosleep: New files.
20760         * modules/strftime: Add lib/strftime.h.
20761         Change include from <time.h> to "strftime.h".
20762         * modules/yesno: Add lib/yesno.h.
20763         * modules/backupfile: Remove lib/addext.c.
20764         * modules/euidaccess: Add stat-macros.h.
20765         * modules/canonicalize, modules/euidaccess,
20766         modules/filemode, modules/lchown, modules/makepath,
20767         modules/rmdir, modules/stat: Likewise.
20768
20769 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
20770
20771         Merge from tar.
20772         * lib/argp-help.c (make_hol, hol_append): Don't assume that
20773         SIZE_MAX is a valid preprocessor constant.
20774         (__argp_basename): Change from "#ifndef _LIBC"
20775         to "#ifndef __argp_short_program_name", so that
20776         we don't compile these functions for tar.
20777
20778         More merges from coreutils.
20779         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
20780         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
20781         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
20782         * lib/addext.c: Remove; no longer needed.
20783         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
20784         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
20785         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
20786         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
20787         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
20788         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
20789         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
20790         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
20791         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
20792         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
20793         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
20794         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
20795         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
20796         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
20797         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
20798         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
20799         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
20800         Import changes from coreutils.
20801
20802 2004-08-05  Simon Josefsson  <jas@extundo.com>
20803
20804         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
20805
20806 2004-08-05  Simon Josefsson  <jas@extundo.com>
20807
20808         * m4/getsubopt.m4: New file.
20809
20810 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20811
20812         Merge from coreutils.
20813
20814         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
20815         * m4/getcwd-path-max.m4: New files.
20816
20817         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
20818         FILESYSTEM_PREFIX_LEN ->
20819         FILE_SYSTEM_PREFIX_LEN.
20820         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
20821         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
20822         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
20823         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
20824
20825         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
20826         prerequisite modules now handle the DOS stuff.
20827         Don't check for unistd.h.
20828
20829 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20830
20831         Merge from coreutils.
20832
20833         * lib/.gdb-history: Remove; this doesn't belong here.
20834
20835         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
20836         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
20837         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
20838         * lib/getcwd.c: New files.
20839
20840         * lib/dirname.h: Include <stdbool.h>.
20841         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
20842         for consistency with POSIX terminology.  All uses changed.
20843         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
20844         (strip_trailing_slashes): Use bool for booleans.
20845         * lib/stripslash.c (strip_trailing_slashes): Likewise.
20846
20847         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
20848         sometimes returns a positive errno value even when it succeeds.
20849         (print_errno_message) [!LIBC]: Fall back on strerror if
20850         __strerror_r fails.
20851
20852         * lib/path-concat.c (mempcpy): Don't define if a system header defines
20853         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
20854         (longest_relative_suffix): New function.
20855         (path_concat): Use it.  Assume first argument is not NULL.
20856         Port to DOS.  Omit redundant separators.
20857         Report an error instead of returning NULL.
20858         Use mempcpy instead of memcpy.
20859         (xpath_concat): Remove: not declared or used.
20860
20861         * lib/same.h: Include <stdbool.h>
20862         (same_name): Return bool, not int.
20863         * lib/same.c (same_name): Likewise.
20864         (errno): Don't declare; we assume C89 or better now.
20865
20866         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
20867         if not already defined.
20868
20869         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
20870         * lib/dup-safer.c (errno): Likewise.
20871
20872 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
20873
20874         Merge from coreutils.
20875         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
20876         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
20877         * modules/path-concat: Don't depend on strdup.
20878
20879 2004-08-03  Simon Josefsson  <jas@extundo.com>
20880
20881         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
20882         * lib/progname.h: Don't include stdbool.h.
20883
20884 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20885
20886         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
20887         * MODULES.html.sh (func_all_modules): Remove fatal.
20888
20889 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20890
20891         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
20892
20893 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
20894
20895         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
20896         working.
20897
20898 2004-08-02  Simon Josefsson  <jas@extundo.com>
20899
20900         * lib/getsubopt.h: New file, with comments from Bruno Haible.
20901         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
20902         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
20903
20904 2004-08-01  Simon Josefsson  <jas@extundo.com>
20905
20906         * lib/xgetdomainname.c: Include stdlib.h, for free().
20907
20908 2004-07-19  Bruno Haible  <bruno@clisp.org>
20909
20910         * MODULES.html.sh (func_all_modules): Add dummy.
20911
20912 2004-07-16  Simon Josefsson  <jas@extundo.com>
20913
20914         * modules/dummy: New file.
20915
20916 2004-07-16  Simon Josefsson  <jas@extundo.com>
20917
20918         * lib/dummy.c: New file.
20919
20920 2004-07-16  Bruno Haible  <bruno@clisp.org>
20921
20922         * lib/backupfile.h: Add extern "C" for C++.
20923         * lib/closeout.h: Likewise.
20924         * lib/copy-file.h: Likewise.
20925         * lib/findprog.h: Likewise.
20926         * lib/full-write.h: Likewise.
20927         * lib/pathname.h: Likewise.
20928         * lib/progname.h: Likewise.
20929         * lib/stpcpy.h: Likewise.
20930         * lib/stpncpy.h: Likewise.
20931         * lib/strcase.h: Likewise.
20932         * lib/strstr.h: Likewise.
20933         * lib/xalloc.h: Likewise.
20934
20935         * lib/mbswidth.h: Add extern "C" for C++.
20936         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
20937
20938 2004-07-13  Robert Millan  <robertmh@gnu.org>
20939
20940         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
20941
20942 2004-07-09  Simon Josefsson  <jas@extundo.com>
20943
20944         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
20945         failed without this.)
20946
20947 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
20948
20949         * modules/chown (Files): Add lib/fchown-stub.c, since
20950         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
20951
20952 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
20953
20954         * lib/fchown-stub.c: New file.
20955
20956 2004-06-24  Jim Meyering  <jim@meyering.net>
20957
20958         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
20959
20960 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20961
20962         * modules/argz: Omit "#include".
20963
20964         * MODULES.html.sh (func_all_modules): Add calloc, to match
20965         2004-06-01 addition of calloc module.
20966
20967 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20968
20969         * m4/argz.m4: New file, which is autoupdated from libtool.
20970
20971 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20972
20973         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
20974         libtool.
20975
20976 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
20977
20978         * config/srclist-update: Don't insist on "USA." before the
20979         close-comment, as libtool omits the period and puts the */ on a
20980         separate line.
20981         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
20982         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
20983
20984 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
20985
20986         * modules/argz: New file.
20987         * MODULES.html.sh (func_all_modules): Add argz.
20988
20989 2004-06-12  Jim Meyering  <jim@meyering.net>
20990         and  Paul Eggert  <eggert@cs.ucla.edu>
20991
20992         * modules/hash (Files): Add lib/xalloc.h.
20993         * modules/pipe (Depends-on): Add wait-process.
20994         * modules/stat (Depends-on): Add xalloc.
20995         * modules/userspec (Files): Add lib/userspec.h.
20996         * modules/xstrto
20997
20998         Upgrade from gettext-0.13.
20999         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
21000         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
21001         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
21002
21003 2004-06-10  Jim Meyering  <jim@meyering.net>
21004
21005         * lib/calloc.c: New file.
21006
21007 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
21008
21009         * lib/getdate.y (yylex): Allow space between sign and number.
21010         Problem reported by Dan Jacobson.
21011
21012 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
21013
21014         Merge from coreutils CVS.
21015
21016         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
21017         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
21018         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
21019         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
21020         xstrtol.m4: Fix copyright date and/or serial number.
21021
21022         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
21023         See if we need an fchown replacement.
21024         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
21025         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
21026         and use the replacement function if we detect either defect.
21027
21028         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
21029         gl_UTIMECMP.
21030
21031 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
21032         and  Jim Meyering  <jim@meyering.net>
21033
21034         Merge from coreutils CVS.
21035
21036         * lib/stat-macros.h: New file, with contents from file-type.h
21037         and coreutils' system.h.
21038         * lib/file-type.c: Include "stat-macros.h".
21039         * lib/file-type.h (file_type): Move all macro definitions to new file,
21040         stat-macros.h.
21041
21042         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
21043         Wrap old code with this conditional.
21044         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
21045         function that does not dereference symlinks.
21046         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
21047
21048         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
21049         dependency problems.
21050         (xreadlink): Accept new arg SIZE, for efficiency.
21051         All decls and uses changed.
21052         * lib/xreadlink.h: Include <stddef.h>, for size_t.
21053
21054         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
21055         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
21056
21057         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
21058         sysexits.h.
21059
21060 2004-06-01  Jim Meyering  <jim@meyering.net>
21061
21062         * m4/calloc.m4: New file.
21063
21064 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
21065
21066         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
21067         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
21068         Also, fix a typo in a diagnostic.
21069
21070 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
21071
21072         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
21073         or AC_FUNC_REALLOC.
21074
21075 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
21076
21077         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
21078         macros to be defined.
21079         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
21080         the allocator returns NULL because the requested size is zero.
21081
21082 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
21083
21084         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
21085         var.  Add comment explaining why libc still defines it.  This
21086         merges the following patch from glibc:
21087         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
21088
21089 2004-05-20  Andreas Schwab  <schwab@suse.de>
21090
21091         * m4/free.m4: Replace free if it not known to work, not the other
21092         way round.
21093
21094 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
21095
21096         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
21097         present in glibc since revision 1.1 of this file.
21098         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
21099         obstack_alignment_mask, obstack_alloc, obstack_base,
21100         obstack_blank, obstack_blank_fast, obstack_chunk_size,
21101         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
21102         obstack_grow0, obstack_init, obstack_int_grow,
21103         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
21104         obstack_next_free, obstack_object_size, obstack_ptr_grow,
21105         obstack_ptr_grow_fast, obstack_room): Remove declarations of
21106         nonexistent functions.
21107
21108 2004-05-18  Karl Berry  <karl@gnu.org>
21109
21110         * config/srclist.txt: break link for vasnprintf.c.
21111
21112 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
21113
21114         Port obstack to the AS/400, where pointers are 16 bytes wide and
21115         you cannot cast an integer to a valid pointer.  This patch is
21116         currently waiting to be integrated into glibc; see
21117         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
21118
21119         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
21120         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
21121         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
21122         (struct obstack): temp member is now a union of a pointer and
21123         an integer, instead of an integer.  All integer uses changed.
21124         This does not affect the physical layout of struct obstack,
21125         except on hosts (like the AS/400) where the size or alignment of
21126         void * is greater than that of ptrdiff_t.
21127         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
21128         __STDC__)]: Store temporary in pointer member of union, not
21129         integer member.
21130         * lib/obstack.c: Include <stddef.h>, for offsetof.
21131         (struct fooalign): Remove; it doesn't need a name.
21132         (union fooround): Change double to long double, and add void *.
21133         (DEFAULT_ALIGNMENT): Use offsetof to compute.
21134         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
21135         not a macro.  Hence the values are always int; so remove all
21136         casts-to-int in uses.
21137
21138 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
21139
21140         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
21141         we can get this patch merged into glibc.
21142
21143 2004-05-17  Derek R. Price  <derek@ximbiot.com>
21144             Paul Eggert  <eggert@cs.ucla.edu>
21145
21146         * m4/argp: Depend on alloca.
21147
21148 2004-05-17  Derek R. Price  <derek@ximbiot.com>
21149             Paul Eggert  <eggert@cs.ucla.edu>
21150
21151         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
21152         freecoding.
21153
21154 2004-05-17  Bruno Haible  <bruno@clisp.org>
21155
21156         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
21157         precision that consists of a '.' followed by an empty digit string.
21158         Patch by Tor Lillqvist <tml@iki.fi>.
21159
21160 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
21161
21162         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
21163         for backward compatibility with older code.  We need our own
21164         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
21165         it under some other name, and our alloca.h will define it.
21166
21167 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
21168             Derek Price  <derek@ximbiot.com>
21169
21170         * lib/alloca.c: Include <alloca.h>, to get our interface.
21171         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
21172         include <alloca.h> first.  Use C89 prototype for alloca; this
21173         requires including <stddef.h> for size_t.  Use extern "C" if C++.
21174         Use #elif for simplicity, since we can assume C89 now.
21175         Don't try to source the system alloca.h since it will not be found
21176         and to prevent recursively including its replacement.
21177         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
21178         * lib/regex.c: Likewise.
21179
21180 2004-05-16  Derek Price  <derek@ximbiot.com>
21181             Paul Eggert  <eggert@cs.ucla.edu>
21182
21183         getline cleanup.  This changes the getndelim2 API: both order of
21184         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
21185         no delimiter).
21186
21187         * lib/getline.c: Don't include stddef.h or stdio.h, since our
21188         interface does that.
21189         (getline): Always use getdelim, so that we don't have two
21190         copies of this code.
21191         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
21192         if available.
21193         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
21194         (GETNDELIM2_MAXIMUM): New macro.
21195         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
21196         instead of the old practice of delim2==0.  All callers changed.
21197         Return -1 on overflow, instead of returning junk.
21198         Do not set *linesize unless allocation succeeds.
21199         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
21200         that we include sys/types.h.
21201         * lib/getnline.h: Likewise.
21202         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
21203         (getndelim2): Reorder arguments.
21204         * lib/getnline.c (getnline, getndelim):
21205         Don't discard the NMAX argument.
21206         (getnline): Invoke getndelim, to avoid code duplication.
21207         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
21208         of (size_t) -1 by callers of the getnline family.
21209
21210 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
21211
21212         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
21213         Check for gettimeofday.
21214         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
21215         Check for settimeofday, stime.
21216
21217 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
21218
21219         * lib/nanosleep.c (suspended): Change its type from int to
21220         sig_atomic_t volatile.
21221         (first_call): Make it private to rpl_nanosleep, and have it
21222         be zero initially as that's a bit faster.
21223         (my_usleep): Round up fractional times instead of truncating them,
21224         as this is the usual meaning for 'sleep'.
21225
21226         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
21227         doesn't work.
21228         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
21229         (ENOSYS): Define if not defined.
21230         (settime): Fall back on stime if it exists and settimeofday fails.
21231         But don't bother with fallbacks if a method fails with errno == EPERM.
21232
21233 2004-05-11  Jim Meyering  <jim@meyering.net>
21234
21235         Prior to this change, the save_cwd caller required read access to the
21236         current directory on most systems (ones with the fchdir function).
21237
21238         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
21239         fails, try write-only, and finally, resort to using xgetcwd.
21240
21241 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
21242
21243         * lib/obstack.c, obstack.h: Import changes from libc.
21244
21245 2004-04-28  Bruno Haible  <bruno@clisp.org>
21246
21247         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
21248         also implicitly appends .exe to executables.
21249         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
21250         accepts Windows pathnames.
21251         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
21252         Treat Cygwin like Windows, since it now accepts Windows pathnames.
21253         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
21254         Treat Cygwin like Windows, since it now accepts Windows pathnames.
21255         Reported by Derek Robert Price <derek@ximbiot.com>.
21256
21257 2004-04-21  Karl Berry  <karl@gnu.org>
21258
21259         * config/srclist.txt (localcharset.c): break sync.
21260
21261 2004-04-20  Paul Eggert  <eggert@twinsun.com>
21262
21263         * m4/host-os.m4: Add a copyright notice.
21264
21265 2004-04-20  Jim Meyering  <jim@meyering.net>
21266
21267         Change UTILS_ to gl_ in AC_DEFINE'd names.
21268         Change utils_- and jm_-prefixed variables, too.
21269         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
21270         UTILS_FUNC_MKDIR_TRAILING_SLASH.
21271         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
21272
21273         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
21274         Don't emit trailing blanks.
21275         Also rename jm_-prefixed variables to have gl_ prefix.
21276
21277         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
21278         Also rename jm_-prefixed variables to have gl_ prefix.
21279
21280         * m4/jm-macros.m4: Reflect the renamings.
21281         * m4/prereq.m4: Likewise.
21282
21283 2004-04-20  Jim Meyering  <jim@meyering.net>
21284
21285         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
21286         memory.
21287
21288 2004-04-20  Jim Meyering  <jim@meyering.net>
21289             Bruno Haible  <bruno@clisp.org>
21290
21291         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
21292         memory when realloc fails.
21293
21294 2004-04-19  Jim Meyering  <jim@meyering.net>
21295
21296         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
21297         now that readutmp.c may call `free (0)'.
21298
21299 2004-04-19  Bruno Haible  <bruno@clisp.org>
21300
21301         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
21302         * m4/inttypes_h.m4: Likewise.
21303         * m4/stdint_h.m4: Likewise.
21304         * m4/intmax_t.m4: Likewise.
21305         * m4/uintmax_t.m4: Likewise.
21306
21307 2004-04-18  Jim Meyering  <jim@meyering.net>
21308
21309         * m4/prereq.m4: Don't forbid jm_ prefix.
21310
21311         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
21312         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
21313         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
21314         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
21315         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
21316         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
21317         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
21318         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
21319         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
21320         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
21321         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
21322         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
21323         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
21324         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
21325         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
21326         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
21327         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
21328         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
21329         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
21330
21331 2004-04-18  Jim Meyering  <jim@meyering.net>
21332
21333         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
21334         failure, don't leak memory and do call END_UTMP_ENT.
21335
21336 2004-04-16  Jim Meyering  <jim@meyering.net>
21337
21338         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
21339         coreutils' stat program.
21340         (gl_PREREQ): Don't require jm_PREREQ_STAT.
21341
21342 2004-04-11  Paul Eggert  <eggert@twinsun.com>
21343
21344         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
21345         C89.
21346         (CHAR_BIT): Remove, since we assume C89.
21347         Include <stdint.h> if available, as per current Autoconf CVS advice.
21348
21349 2004-03-31  Jim Meyering  <jim@meyering.net>
21350
21351         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
21352         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
21353         * m4/xalloc.m4: Likewise.
21354
21355 2004-03-30  Paul Eggert  <eggert@twinsun.com>
21356
21357         Merge from coreutils.
21358
21359         * m4/inttostr.m4: New file.
21360         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
21361         Require AM_STDBOOL_H and gl_TIMESPEC instead.
21362         Require gl_CLOCK_TIME.
21363         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
21364
21365 2004-03-30  Paul Eggert  <eggert@twinsun.com>
21366
21367         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
21368         not bool, to be more consistent with Unix conventions.
21369         Suggested by Bruno Haible.
21370
21371         Merge from coreutils.
21372
21373         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
21374         * lib/umaxtostr.c: New files.
21375
21376         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
21377         the usual <time.h> dance.
21378         (get_date): Change signature to support fractional time stamps.
21379         All callers changed.
21380         * lib/getdate.y: Include "getdate.h" first, as we can now
21381         assume C89 and don't need to worry about 'const'.
21382         Similarly, include "unlocked-io.h" near start, not in middle.
21383         Include <limits.h>.
21384         (textint.value): Use long int rather than int.
21385         (textint.digits): Use size_t rather than int.
21386         (BILLION, LOG10_BILLION): New constants.
21387         (parser_control): New member rel_ns.  Members day_ordinal,
21388         time_zone, month, day, hour, minutes, rel_year, rel_month,
21389         rel_day, rel_hour, rel_minutes, rel_seconds
21390         are now long int, not int.  Member seconds is now struct timespec,
21391         not int.  New member timespec_seen.  Members dates_seen, days_seen,
21392         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
21393         not int.
21394         (%union.intval): Now long int, not int.
21395         New member timespec.
21396         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
21397         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
21398         (spec): Now is a timespec or an item list.
21399         (timespec, items): New nonterminals.
21400         (time, rel, relunit, number, get_date):
21401         Add support for fractional seconds.
21402         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
21403         (gmtime, localtime, mktime): Remove decls; not needed with C89.
21404         (to_hour): First arg is now long int, not int.
21405         (to_year): Returns long int, not int.
21406         Don't treat year -70 like 70.
21407         (tm_diff): Returns long int, not int.
21408         (lookup_word): Use bool instead of int when appropriate.
21409         (yylex): Use size_t for count, not int.
21410         Detect overflow when parsing large integer constants.
21411         Add support for fractions.
21412         (get_date): Make pointers 'const' if possible.
21413         Use more-portable code to detect integer overflow.
21414         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
21415         Don't use ctime; it's not reliable if the year has >4 digits.
21416
21417         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
21418         This is for compatibility with BSD.
21419
21420         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
21421         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
21422         From coreutils' system.h.
21423
21424         * lib/userspec.c: Don't include "posixver.h".
21425         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
21426         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
21427         compatible extension.  Simplify code by removing a boolean int
21428         that was always nonzero if a string was nonnull.
21429
21430 2004-03-30  Jim Meyering  <jim@meyering.net>
21431
21432         Merge from coreutils.
21433
21434         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
21435         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
21436         on some systems one must include <grp.h> before it.
21437         Reported by Christian Krackowizer.
21438
21439 2004-03-30  Jim Meyering  <jim@meyering.net>
21440
21441         Merge from coreutils.
21442
21443         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
21444
21445         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
21446         an empty input stream.
21447
21448         * lib/readtokens.c: Include <stdbool.h>.
21449         (readtoken): Use `size_t' rather than int/long.
21450         All callers adjusted.
21451         Use `bool' rather than `int' where appropriate.
21452         Use memset rather than an explicit loop.
21453         Use x2nrealloc rather than xrealloc.
21454         Allow the use of `\0' as a delimiter.
21455         (readtokens): Likewise.
21456         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
21457
21458 2004-03-30  Jim Meyering  <jim@meyering.net>
21459
21460         * m4/realloc.m4: Remove file, since now it does no more than
21461         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
21462         the `configure.ac' section of module/realloc.
21463         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
21464
21465 2004-03-30  Bruno Haible  <bruno@clisp.org>
21466
21467         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
21468         nonnull.
21469
21470 2004-03-29  Paul Eggert  <eggert@twinsun.com>
21471
21472         Merge changes to getloadavg.c from coreutils and Emacs.
21473
21474         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
21475         Define to an expression, not to the empty string.
21476         Include cloexec.h and xalloc.h.
21477         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
21478         Use set_cloexec_flag rather than rolling our own.
21479         * lib/cloexec.c, lib/cloexec.h: New files.
21480
21481 2004-03-29  Paul Eggert  <eggert@twinsun.com>
21482
21483         * m4/cloexec.m4: New file.
21484
21485 2004-03-18  Paul Eggert  <eggert@twinsun.com>
21486
21487         * lib/getopt.h: Sync with libc CVS.
21488
21489 2004-03-18  Paul Eggert  <eggert@twinsun.com>
21490             Bruno Haible  <bruno@clisp.org>
21491
21492         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
21493         mbswidth.
21494
21495 2004-03-18  Paul Eggert  <eggert@twinsun.com>
21496             Bruno Haible  <bruno@clisp.org>
21497
21498         * lib/mbswidth.h: Include <wchar.h> only if
21499         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
21500         <wchar.h>.
21501         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
21502
21503 2004-03-09  Paul Eggert  <eggert@twinsun.com>
21504
21505         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
21506         Sync with libc CVS.
21507         * lib/getopt_int.h: New file, also synced from libc.
21508
21509 2004-03-09  Paul Eggert  <eggert@twinsun.com>
21510
21511         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
21512         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
21513         Bring back getopt.c, getopt.h, getopt1.c.
21514
21515 2004-03-07  Paul Eggert  <eggert@twinsun.com>
21516
21517         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
21518         All uses changed.  Check for sa_sigaction member; this fixes
21519         a bug first reported by Jason Andrade in
21520         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
21521
21522 2004-03-07  Paul Eggert  <eggert@twinsun.com>
21523
21524         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
21525         '#if' expressions.  Unlike the code it replaces, it does not
21526         depend on (defined _SC_PAGESIZE).  However, it does depend on
21527         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
21528         first reported by Jason Andrade in
21529         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
21530
21531 2004-02-25  Simon Josefsson  <jas@extundo.com>
21532
21533         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
21534
21535 2004-02-25  Simon Josefsson  <jas@extundo.com>
21536
21537         * lib/strdup.h: New file.
21538         * lib/strdup.c: Include it.
21539         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
21540         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
21541
21542 2004-02-23  Karl Berry  <karl@gnu.org>
21543
21544         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
21545         (from fencepost.gnu.org:/gd/gnuorg).
21546
21547 2004-02-23  Karl Berry  <karl@gnu.org>
21548
21549         * config/srclistvars.sh (GNUORG) [karl]: redefine.
21550         * config/srclist.txt: add maintain/standards documents.
21551
21552 2004-02-18  Bruno Haible  <bruno@clisp.org>
21553
21554         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
21555         Reported by Derek Robert Price <derek@ximbiot.com>.
21556
21557 2004-02-16  Karl Berry  <karl@gnu.org>
21558
21559         * config/mkinstalldirs, install-sh: update from automake.
21560
21561 2004-02-06  Karl Berry  <karl@gnu.org>
21562
21563         * m4/po.m4: update from gettext 0.14.1.
21564
21565 2004-02-06  Karl Berry  <karl@gnu.org>
21566
21567         * lib/config.charset: update from gettext 0.14.1.
21568
21569 2004-02-05  Paul Eggert  <eggert@twinsun.com>
21570
21571         Add comments and code, prompted by suggestions from Bruno Haible
21572         for sh-quote.
21573         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
21574         describing the enum quoting_style values.
21575         * lib/quotearg.c (quotearg_alloc): New function.
21576         (quotearg_buffer_restyled): Treat lone { and } as special.
21577         Treat = as special.  Work around bug with older shells
21578         that "see" a '\' that is really the 2nd byte of a multibyte char.
21579         Quote empty string with shell_quoting_style.
21580
21581 2004-02-03  Bruno Haible  <bruno@clisp.org>
21582
21583         * m4/pipe.m4: New file, from GNU gettext.
21584
21585 2004-02-03  Bruno Haible  <bruno@clisp.org>
21586
21587         * lib/pipe.h: New file, from GNU gettext.
21588         * lib/pipe.c: New file, from GNU gettext.
21589
21590 2004-01-27  Bruno Haible  <bruno@clisp.org>
21591
21592         * m4/execute.m4: New file, from GNU gettext.
21593
21594 2004-01-27  Bruno Haible  <bruno@clisp.org>
21595
21596         * lib/execute.h: New file, from GNU gettext.
21597         * lib/execute.c: New file, from GNU gettext.
21598         * lib/w32spawn.h: New file, from GNU gettext.
21599
21600 2004-01-24  Paul Eggert  <eggert@twinsun.com>
21601
21602         Merge from diffutils.
21603
21604         * lib/file-type.c (file_type): Add typed memory objects.
21605         * lib/file-type.h (S_TYPEISTMO): New macro.
21606
21607         * lib/c-stack.h (c_stack_action): Remove argv argument.
21608         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
21609         (die): Don't calculate message unless segv_action returns.
21610         (get_stack_location, min_address_from_argv, max_address_from_argv,
21611         volatile stack_base, volatile_stack_size): Remove.
21612         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
21613         that every segmentation violation is a stack overflow.  (Ouch!)
21614         See Debian bug 136249 (still outstanding) for more info about why
21615         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
21616
21617 2004-01-24  Paul Eggert  <eggert@twinsun.com>
21618
21619         Exit-status fix from coreutils.
21620
21621         Use exit_failure consistently in place of EXIT_FAILURE,
21622         so that program exit statuses are consistent on failure.
21623
21624         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
21625         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
21626         * lib/argmatch.h: Comment fix to match the above.
21627         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
21628         Now a macro referring to exit_failure, instead of a separate
21629         variable.  Include "exitfail.h" to get it.
21630         * lib/xstrtol.h: Include "exitfail.h".
21631         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
21632
21633         * lib/long-options.c (parse_long_options): Use prototype
21634         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
21635         for clarity.
21636
21637 2004-01-21  Jim Meyering  <jim@meyering.net>
21638
21639         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
21640         so as not to conflict with a different-sized __mktime_internal
21641         function in GNU libc.
21642         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
21643         Problem building statically-linked `ls' reported by Michael Brunnbauer.
21644
21645 2004-01-20  Karl Berry  <karl@gnu.org>
21646
21647         * config/config.guess: update from config.
21648
21649         * config/srclistvars.sh: GNUWWWLICENSES for karl.
21650
21651 2004-01-20  Bruno Haible  <bruno@clisp.org>
21652
21653         Safer stack allocation.
21654         * lib/setenv.c: Include allocsa.h.
21655         (alloca): Remove fallback definition.
21656         (freea): Remove macro.
21657         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
21658         instead of freea.
21659
21660 2004-01-20  Bruno Haible  <bruno@clisp.org>
21661
21662         * m4/eealloc.m4: New file, from GNU gettext.
21663
21664 2004-01-20  Bruno Haible  <bruno@clisp.org>
21665
21666         * m4/allocsa.m4: New file, from GNU gettext.
21667
21668 2004-01-20  Bruno Haible  <bruno@clisp.org>
21669
21670         * lib/xallocsa.h: New file, from GNU gettext.
21671         * lib/xallocsa.c: New file, from GNU gettext.
21672
21673 2004-01-20  Bruno Haible  <bruno@clisp.org>
21674
21675         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
21676
21677 2004-01-20  Bruno Haible  <bruno@clisp.org>
21678
21679         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
21680         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
21681         specially.
21682
21683 2004-01-20  Bruno Haible  <bruno@clisp.org>
21684
21685         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
21686         patch.
21687
21688 2004-01-20  Bruno Haible  <bruno@clisp.org>
21689
21690         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
21691
21692 2004-01-20  Bruno Haible  <bruno@clisp.org>
21693
21694         * lib/eealloc.h: New file.
21695
21696 2004-01-20  Bruno Haible  <bruno@clisp.org>
21697
21698         * lib/binary-io.h: Avoid warnings on Cygwin.
21699
21700 2004-01-20  Bruno Haible  <bruno@clisp.org>
21701
21702         * lib/allocsa.h: New file, from GNU gettext.
21703         * lib/allocsa.c: New file, from GNU gettext.
21704
21705 2004-01-18  Karl Berry  <karl@gnu.org>
21706
21707         * doc/gpl.texi, doc/lgpl.texi: new files.
21708
21709 2004-01-18  Karl Berry  <karl@gnu.org>
21710
21711         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
21712         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
21713
21714 2004-01-15  Paul Eggert  <eggert@twinsun.com>
21715
21716         Merge from coreutils.
21717
21718         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
21719         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
21720         (gl_DEFAULT_POSIX2_VERSION): Move
21721         the documentation from 'configure' into 'config.hin',
21722         so that 'configure --help' isn't burdened by it and
21723         we don't have to worry about its formatting there.
21724         Reword the documentation so that it's more succinct
21725         and can be run together into a single paragraph.
21726         * m4/same.m4 (gl_SAME): Check for pathconf.
21727
21728 2004-01-15  Paul Eggert  <eggert@twinsun.com>
21729
21730         Merge from coreutils.
21731
21732         * lib/posixver.c: Include posixver.h.
21733
21734         * lib/same.c: Include <stdbool.h>, <limits.h>.
21735         (_POSIX_NAME_MAX): Define if not defined.
21736         (MIN): New macro.
21737         (same_name): If file names are silently truncated, report
21738         that the file names are the same if they are the same after
21739         the silent truncation.
21740
21741         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
21742         conversion function.
21743         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
21744         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
21745         longer needed.
21746
21747 2004-01-15  Jim Meyering  <jim@meyering.net>
21748
21749         Merge from coreutils.
21750
21751         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
21752         if no library is required.
21753         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
21754         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
21755         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
21756         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
21757         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
21758         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
21759         value, $ac_cv_search_crypt, if it's "none required".
21760         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
21761         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
21762         not gl_FUNC_GETLOADAVG.
21763         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
21764         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
21765
21766 2004-01-15  Jim Meyering  <jim@meyering.net>
21767
21768         Merge from coreutils.
21769
21770         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
21771         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
21772         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
21773
21774         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
21775         optional configure-time default.
21776
21777         * lib/version-etc.c (version_etc_copyright): Update copyright date.
21778
21779         * lib/xreadlink.c (xreadlink): Correct outdated comment.
21780
21781 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
21782
21783         Merge from coreutils.
21784
21785         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
21786         value, $ac_cv_search_nanosleep, if it's "none required".
21787
21788 2004-01-14  Paul Eggert  <eggert@twinsun.com>
21789
21790         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
21791         with like-named macro in fnmatch.c.
21792         (EXT): Use an internal constant instead.
21793
21794         Merge fnmatch patches from glibc.
21795         * lib/fnmatch.c (mbsinit): Remove define.
21796         Add libc_hidden_ver (__fnmatch, fnmatch).
21797         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
21798         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
21799
21800 2004-01-14  Karl Berry  <karl@gnu.org>
21801
21802         * config/install-sh: update from automake.
21803
21804 2004-01-13  Karl Berry  <karl@gnu.org>
21805
21806         * config/install-sh: update from automake.
21807
21808 2004-01-09  Karl Berry  <karl@gnu.org>
21809
21810         * config/install-sh: update from automake.
21811
21812 2004-01-05  Karl Berry  <karl@gnu.org>
21813
21814         * config/config.{sub,guess}: update from config.
21815
21816 2003-12-31  Karl Berry  <karl@gnu.org>
21817
21818         * config/depcomp: update from automake.
21819
21820 2003-12-14  Karl Berry  <karl@gnu.org>
21821
21822         * lib/config.charset: update from gettext-runtime.
21823
21824 2003-12-03  Paul Eggert  <eggert@twinsun.com>
21825
21826         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
21827         Bug reported by Alfred M. Szmidt.
21828
21829 2003-12-03  Bruno Haible  <bruno@clisp.org>
21830
21831         * m4/gettext.m4: Upgrade from gettext-0.13.
21832         * m4/po.m4: Upgrade from gettext-0.13.
21833         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
21834         * m4/intmax.m4: New file, from gettext-0.13.
21835         * m4/printf-posix.m4: New file, from gettext-0.13.
21836
21837 2003-11-29  Karl Berry  <karl@gnu.org>
21838
21839         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
21840
21841 2003-11-25  Paul Eggert  <eggert@twinsun.com>
21842             Bruno Haible  <bruno@clisp.org>
21843
21844         * lib/printf-parse.h: Don't include sys/types.h.
21845         (ARG_NONE): New macro.
21846         (char_directive): Change type of *arg_index fields to size_t.
21847         * lib/printf-parse.c: Don't include sys/types.h.
21848         (SSIZE_MAX): Remove macro.
21849         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
21850         Remove unnecessary overflow check.
21851         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
21852         fields.
21853
21854 2003-11-25  Bruno Haible  <bruno@clisp.org>
21855
21856         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
21857
21858 2003-11-25  Bruno Haible  <bruno@clisp.org>
21859
21860         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
21861         gt_TYPE_SSIZE_T.
21862
21863 2003-11-24  Paul Eggert  <eggert@twinsun.com>
21864
21865         * modules/alloca: Remove dependency on xalloc.
21866
21867 2003-11-24  Paul Eggert  <eggert@twinsun.com>
21868
21869         * lib/alloca.c: Remove dependency on xalloc module.
21870         (xalloc_die): Remove.
21871         (memory_full) [!defined emacs]: New macro.
21872         [!defined emacs]: Don't include xalloc.h.
21873         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
21874         address arithmetic overflows.  Change datatypes a bit to avoid
21875         unnecessary casts.
21876
21877 2003-11-22  Jim Meyering  <jim@meyering.net>
21878
21879         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
21880         s/size/size_t/.
21881
21882 2003-11-21  Karl Berry  <karl@gnu.org>
21883
21884         * config/config.{sub,guess}: update from config.
21885
21886 2003-11-18  Karl Berry  <karl@gnu.org>
21887
21888         * config/config.{sub,guess}: update from config.
21889
21890         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
21891
21892 2003-11-17  Paul Eggert  <eggert@twinsun.com>
21893
21894         * README: Mention that S+T cannot overflow if S is the size of
21895         an existing object and T is sufficiently small.
21896
21897 2003-11-17  Jim Meyering  <jim@meyering.net>
21898
21899         On systems without utime and without a utimes function capable of
21900         dealing with a NULL struct utimbuf* argument, this utime replacement
21901         could -- in unusual circumstances -- leak a file descriptor.
21902         * lib/utime.c: Include <unistd.h> and <errno.h>.
21903         (utime_null): Be sure to close `fd' and to preserve errno.
21904         Reported by Geoff Collyer via Arnold Robbins.
21905
21906 2003-11-17  Bruno Haible  <bruno@clisp.org>
21907
21908         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
21909         (Depends-on): Add xsize.
21910
21911 2003-11-17  Bruno Haible  <bruno@clisp.org>
21912
21913         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
21914
21915 2003-11-17  Bruno Haible  <bruno@clisp.org>
21916
21917         * lib/vasnprintf.c (alloca): Remove fallback definition.
21918         (freea): Remove definition.
21919         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
21920         Reported by Paul Eggert.
21921
21922 2003-11-16  Paul Eggert  <eggert@twinsun.com>
21923             Bruno Haible  <bruno@clisp.org>
21924
21925         Protect against address arithmetic overflow.
21926         * lib/printf-args.h: Include stddef.h.
21927         (arguments): Change type of field 'count' to size_t.
21928         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
21929         'unsigned int' where appropriate.
21930         * lib/printf-parse.h: Include sys/types.h.
21931         (char_directive): Change type of *arg_index fields to ssize_t.
21932         (char_directives): Change type of fields 'count', max_*_length to
21933         size_t.
21934         * lib/printf-parse.c: Include sys/types.h and xsize.h.
21935         (SSIZE_MAX): Define fallback value.
21936         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
21937         instead of 'int' where appropriate. Check a_allocated, d_allocated
21938         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
21939         * lib/vasnprintf.c: Include xsize.h.
21940         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
21941         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
21942         overflow. Avoid wraparound when converting a width or precision from
21943         decimal to binary.
21944
21945 2003-11-16  Bruno Haible  <bruno@clisp.org>
21946
21947         Update from GNU gettext.
21948         * lib/printf-parse.c: Generalize to it can be compiled for wide
21949         strings.
21950         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
21951         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
21952         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
21953         SNPRINTF): New macros.
21954         Don't include <alloca.h> if the file is used inside libintl.
21955         (local_wcslen): New function, for Solaris 2.5.1.
21956         (VASNPRINTF): Use it instead of wcslen.
21957
21958 2003-11-16  Bruno Haible  <bruno@clisp.org>
21959
21960         * lib/xsize.h (xmax): New function.
21961         (xsum, xsum3, xsum4): Declare as "pure" functions.
21962
21963 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21964
21965         * modules/xalloc (Files): Undo latest change, since xalloc.h
21966         no longer needs SIZE_MAX or PTRDIFF_MAX.
21967
21968 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21969
21970         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
21971         gl_PTRDIFF_MAX.
21972
21973 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21974
21975         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
21976         "return", to pacify some unknown compiler.  Problem reported
21977         by Joerg Schilling.
21978
21979 2003-11-12  Paul Eggert  <eggert@twinsun.com>
21980
21981         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
21982         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
21983         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
21984         heuristic is just as accurate as far as we know, and it removes a
21985         dependency on size_max.m4 and ptrdiff_max.m4.
21986
21987 2003-11-11  Bruno Haible  <bruno@clisp.org>
21988
21989         * modules/xsize (Files): Add m4/size_max.m4.
21990         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
21991
21992 2003-11-11  Bruno Haible  <bruno@clisp.org>
21993
21994         * m4/size_max.m4: New file.
21995         * m4/ptrdiff_max.m4: New file.
21996         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
21997         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
21998         (gl_XALLOC): Invoke it.
21999
22000 2003-11-11  Bruno Haible  <bruno@clisp.org>
22001
22002         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
22003         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
22004         defined.
22005
22006 2003-11-10  Paul Eggert  <eggert@twinsun.com>
22007
22008         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
22009         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
22010         rejected some allocations of exactly SIZE_MAX - 2 bytes.
22011         From Bruno Haible.
22012         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
22013         not (size_t) -1, since it's defined here.
22014
22015 2003-11-09  Karl Berry  <karl@gnu.org>
22016
22017         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
22018
22019 2003-11-06  Paul Eggert  <eggert@twinsun.com>
22020
22021         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
22022         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
22023         Reject sizes of exactly SIZE_MAX bytes.
22024         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
22025         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
22026
22027 2003-11-05  Bruno Haible  <bruno@clisp.org>
22028
22029         * lib/xsize.h: Include limits.h, to avoid a possible collision with
22030         SIZE_MAX defined in <limits.h> on Solaris.
22031
22032 2003-11-04  Jim Meyering  <jim@meyering.net>
22033
22034         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
22035         variable names, rather than @VAR@.
22036         * modules/poll: Likewise.
22037
22038 2003-11-04  Bruno Haible  <bruno@clisp.org>
22039
22040         * modules/xsize: New file.
22041         * modules/linebreak: Depend on xsize.
22042         * MODULES.html.sh (func_all_modules): Add xsize.
22043
22044 2003-11-04  Bruno Haible  <bruno@clisp.org>
22045
22046         * m4/xsize.m4: New file.
22047
22048 2003-11-04  Bruno Haible  <bruno@clisp.org>
22049
22050         * lib/xsize.h: New file.
22051         * lib/linebreak.c: Include xsize.h.
22052         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
22053         argument for overflow.
22054         Suggested by Paul Eggert.
22055
22056 2003-11-03  Karl Berry  <karl@gnu.org>
22057
22058         * config/config.{guess,sub}: update from config.
22059
22060 2003-11-03  Jim Meyering  <jim@meyering.net>
22061
22062         * modules/userspec (lib_SOURCES): Add userspec.h.
22063         (Include): Add "userspec.h".
22064         Improve description.
22065
22066 2003-11-03  Jim Meyering  <jim@meyering.net>
22067
22068         * lib/userspec.c: Include "userspec.h".
22069         * lib/userspec.h: New file.
22070
22071 2003-11-03  Bruno Haible  <bruno@clisp.org>
22072
22073         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
22074
22075 2003-11-03  Bruno Haible  <bruno@clisp.org>
22076
22077         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
22078         available, to avoid (extremely rare) race condition.
22079         Suggested by Paul Eggert.
22080
22081 2003-11-02  Karl Berry  <karl@gnu.org>
22082
22083         * config/srclist.txt (vasprintf.c): sync broken, sigh.
22084
22085 2003-10-31  Paul Eggert  <eggert@twinsun.com>
22086
22087         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
22088         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
22089         (read_filesystem_list): Set and use me_type_malloced.
22090         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
22091         whatever the type happens to be), for brevity and consistency.
22092         Check for size calculation overflow on Alphas running OSF/1.
22093
22094 2003-10-31  Jim Meyering  <jim@meyering.net>
22095
22096         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
22097
22098         * lib/linebuffer.c: Include <string.h> for declaration of memset.
22099
22100 2003-10-30  Paul Eggert  <eggert@twinsun.com>
22101             Bruno Haible  <bruno@clisp.org>
22102
22103         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
22104         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
22105
22106 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
22107
22108         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
22109         netbsd*-gnu*.  Suggested by Robert Millan.
22110
22111 2003-10-29  Paul Eggert  <eggert@twinsun.com>
22112
22113         * modules/group-member: Depend on stdbool.
22114
22115 2003-10-29  Paul Eggert  <eggert@twinsun.com>
22116
22117         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
22118
22119 2003-10-29  Paul Eggert  <eggert@twinsun.com>
22120
22121         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
22122         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
22123         after the 'gnu' in these cases.  This fixes some bugs in the
22124         previous change, and is based on suggestions by Robert Millan.
22125
22126 2003-10-29  Paul Eggert  <eggert@twinsun.com>
22127
22128         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
22129         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
22130         no longer needed.
22131         * lib/quotearg.c (quotearg_n_options): Use it.
22132         * lib/group-member.c: Include <stdbool.h>.
22133         (free_group_info): Arg is now const *; don't free arg.
22134         (get_group_info): Now returns bool and accepts struct group_info *,
22135         rather than returning a malloc'ed struct group_info *.
22136         All uses changed.  Check for overflow in internal size calculation.
22137
22138         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
22139         rather than xmalloc/xrealloc.
22140         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
22141         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
22142         conformance bug: the old code used a pointer after freeing the
22143         storage that it addressed.
22144         * lib/hash.c (hash_initialize): Simplify the code by using
22145         xalloc_oversized rather than doing it by hand.
22146         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
22147         the buffer preserved.  Use free and xmalloc instead.
22148         * lib/quotearg.c (quotearg_n_options): Likewise.
22149         Use a simpler test for size overflow.  Don't use xalloc_oversized
22150         because unsigned int might be wider than size_t (!); this suggests
22151         that we should switch from unsigned int to size_t for slot numbers.
22152
22153 2003-10-28  Paul Eggert  <eggert@twinsun.com>
22154
22155         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
22156         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
22157         NetBSD kernels.  Requested by Richard Stallman.
22158
22159 2003-10-27  Paul Eggert  <eggert@twinsun.com>
22160
22161         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
22162         to allocate the returned structure.  Do not allocate a subarray,
22163         as x2nrealloc will do that.
22164         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
22165         instead of xnrealloc.
22166         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
22167
22168 2003-10-27  Bruno Haible  <bruno@clisp.org>
22169
22170         * lib/stdbool_.h: Better support for BeOS.
22171
22172 2003-10-26  Paul Eggert  <eggert@twinsun.com>
22173
22174         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
22175         now uses inline.
22176
22177 2003-10-26  Paul Eggert  <eggert@twinsun.com>
22178
22179         * lib/xalloc.h (xalloc_oversized): New static inline function, for
22180         callers that want to do their own size-overflow checking.  Include
22181         <stdbool.h>, since xalloc_oversized returns bool.
22182         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
22183         to use xalloc_oversized.
22184
22185         Add two functions x2realloc, x2nrealloc, for programs that grow
22186         arrays dynamically by doubling their sizes.
22187         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
22188         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
22189         New functions.
22190
22191         Port to C99 semantics for 'inline' of external functions.
22192         Bug reported by Bruno Haible.
22193         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
22194         with the old contents of xnmalloc.
22195         (xnmalloc, xmalloc): Use it.
22196         (xnrealloc_inline): New static inline function,
22197         with the old contents of xnrealloc.
22198         (xnrealloc, xrealloc): Use it.
22199
22200         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
22201         that.
22202
22203 2003-10-26  Karl Berry  <karl@gnu.org>
22204
22205         * config/srclist.txt (COPYING.DOC): no longer available from
22206         /gd/gnuorg; don't know where the ultimate source is.
22207
22208 2003-10-25  Paul Eggert  <eggert@twinsun.com>
22209
22210         Fix several address-calculation bugs in the hash modules,
22211         plus some minor code cleanup.
22212
22213         * lib/hash.h: Include <stdbool.h>, for bool.
22214         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
22215         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
22216         hash_get_n_entries, hash_get_max_bucket_length,
22217         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
22218         hash_rehash): Use size_t rather than unsigned.
22219         * lib/hash.c (struct hash_table, hash_get_n_buckets,
22220         hash_get_n_buckets_used, hash_get_n_entries,
22221         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
22222         hash_get_entries, hash_do_for_each, hash_string, is_prime,
22223         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
22224         Likewise.
22225         (SIZE_MAX): Define if not defined.
22226         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
22227         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
22228         hash_print):
22229         Use const * when possible.
22230         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
22231         (check_tuning): Fix bug: if tuning parameters were very close to
22232         0 or 1, rounding errors could have caused subscript violations.
22233         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
22234         (hash_initialize): Add 'fail:' label
22235         to free table and return NULL, and use it to simplify code.
22236         Use calloc rather than clearing the storage ourself.
22237         (hash_initialize, hash_rehash): Check for arithmetic overflow in
22238         buffer size calculations.
22239         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
22240         Include <stddef.h>, for size_t.
22241         * lib/hash-pjw.c (hash_pjw): Likewise.
22242         Switch to method described by Bruno Haible.
22243         Include <limits.h>, for CHAR_BIT.
22244         (SIZE_BITS): New macro.
22245
22246 2003-10-23  Paul Eggert  <eggert@twinsun.com>
22247
22248         * m4/getline.m4 (AM_FUNC_GETLINE):
22249         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
22250         hosts.  Problem reported by Derek Robert Price in
22251         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
22252         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
22253         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
22254
22255 2003-10-21  Paul Eggert  <eggert@twinsun.com>
22256
22257         * lib/getndelim2.c (getndelim2): When size calculation overflows,
22258         ceiling the allocation at NMAX bytes rather than silently
22259         discarding input bytes before NMAX is reached.  This makes
22260         a difference only if NMAX exceeds SIZE_MAX / 2.
22261
22262         * lib/obstack.c: Merge from glibc.
22263         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
22264         Add libc_hidden_def (_obstack_newchunk).
22265         (_obstack_free) [! defined _LIBC]: Remove.
22266         [defined _LIBC]: Make a strong alias from obstack_free, rather than
22267         a clone of the function body.
22268         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
22269         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
22270
22271         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
22272         glibc.
22273         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
22274         arg to memcpy.
22275
22276         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
22277         (obstack_ptr_grow_fast, obstack_int_grow_fast):
22278         Don't use lvalue casts, as GCC plans to remove support for them
22279         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
22280         was also present in the non-GCC version, indicating that this
22281         code had always been buggy and had never been widely used.
22282         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
22283         Use the fast variant of each macro, rather than copying the
22284         definiens of the fast variant; that way, we'll be more likely to
22285         catch future bugs in the fast variants.
22286
22287 2003-10-20  Bruno Haible  <bruno@clisp.org>
22288
22289         * modules/wait-process: New file.
22290         * MODULES.html.sh (func_all_modules): Add wait-process.
22291
22292 2003-10-20  Bruno Haible  <bruno@clisp.org>
22293
22294         * m4/wait-process.m4: New file.
22295
22296 2003-10-20  Bruno Haible  <bruno@clisp.org>
22297
22298         * lib/wait-process.h: New file, from GNU gettext.
22299         * lib/wait-process.c: New file, from GNU gettext.
22300
22301 2003-10-19  Jim Meyering  <jim@meyering.net>
22302
22303         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
22304         HPUX 10.20.
22305
22306 2003-10-18  Karl Berry  <karl@gnu.org>
22307
22308         * config/config.guess: update from config.
22309
22310 2003-10-16  Paul Eggert  <eggert@twinsun.com>
22311
22312         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
22313         (getgroups): First arg is int, not size_t.
22314         Don't let 'free' mangle errno.
22315
22316 2003-10-16  Paul Eggert  <eggert@twinsun.com>
22317
22318         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
22319
22320 2003-10-16  Karl Berry  <karl@gnu.org>
22321
22322         * config/config.{guess,sub}: update from config.
22323
22324 2003-10-16  Jim Meyering  <jim@meyering.net>
22325
22326         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
22327         memcpy.
22328
22329 2003-10-15  Paul Eggert  <eggert@twinsun.com>
22330
22331         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
22332         (SIZE_MAX): Remove.
22333         (new_exclude, add_exclude_file): Initial size no longer needs to
22334         be a power of 2.
22335         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
22336         our own address arithmetic overflow checking.
22337
22338         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
22339         (fnmatch): Do not alloca more than 2000 wide characters;
22340         instead, use malloc for large buffers.
22341         Check for address arithmetic overflow, and return -1
22342         with errno set to ENOMEM in that case.
22343         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
22344         (NEW_PATTERN): Do not alloca more than 8000 bytes;
22345         instead, return -1.  Check for address arithmetic overflow.
22346
22347 2003-10-14  Paul Eggert  <eggert@twinsun.com>
22348
22349         Handle invalid suffixes and overflow independently, so that
22350         callers can treat them independently as needed.  Fix some bugs in
22351         suffix handling, e.g., "100k@" was not diagnosed as an invalid
22352         suffix for a human-readable blocksize.  The major caller-visible
22353         change is the addition of a new
22354         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
22355         that both overflow and suffix chars were found.
22356
22357         * lib/human.c (humblock): Don't check separately for invalid suffix
22358         char; that is xstrtoumax's job (now that its bug is fixed).
22359         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
22360         INTMAX_MAX]: New macros.
22361         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
22362         TYPE_MAXIMUM): New macros.
22363         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
22364         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
22365         if overflow occurs, as it's what __strtol does and it's more useful
22366         in practice.
22367         (__xstrtol): If __strtol reports some error other than ERANGE,
22368         reflect it to the caller as LONGINT_INVALID.  If it reports
22369         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
22370         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
22371         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
22372         value.
22373         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
22374         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
22375         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
22376         [defined UINTMAX_MAX]: New macros.
22377
22378 2003-10-14  Bruno Haible  <bruno@clisp.org>
22379
22380         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
22381
22382 2003-10-14  Bruno Haible  <bruno@clisp.org>
22383
22384         * m4/sig_atomic_t: New file, from GNU gettext.
22385         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
22386
22387 2003-10-14  Bruno Haible  <bruno@clisp.org>
22388
22389         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
22390         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
22391         Also use volatile where needed.
22392
22393 2003-10-12  Paul Eggert  <eggert@twinsun.com>
22394
22395         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
22396         Change maintainer from Bruno Haible to 'all'.
22397
22398 2003-10-12  Paul Eggert  <eggert@twinsun.com>
22399
22400         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
22401
22402 2003-10-12  Paul Eggert  <eggert@twinsun.com>
22403
22404         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
22405         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
22406         and define in terms of the other primitives.
22407         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
22408         (SIZE_MAX): Define if not already defined.
22409         (array_size_overflow): New function.
22410         (xalloc_die): Abort instead of exiting if 'error' returns.
22411         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
22412         (xmalloc, xrealloc): Use them.
22413         (xcalloc): Check for address arithmetic overflow.
22414         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
22415         a bit faster than strcpy.
22416
22417 2003-10-10  Simon Josefsson  <jas@extundo.com>
22418
22419         * modules/argp (Depends-on): Add restrict and strcase.
22420
22421 2003-10-10  Simon Josefsson  <jas@extundo.com>
22422
22423         * m4/argp.m4: Add AC_C_INLINE.
22424
22425 2003-10-08  Paul Eggert  <eggert@twinsun.com>
22426
22427         Merge getpass from libc, plus a few fixes.
22428
22429         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
22430         Include <stdbool.h>.
22431         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
22432         __fsetlocking to empty.
22433         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
22434         do include <bits/libc-lock.h>.
22435         Do not include <fcntl.h>; not needed.
22436         [_LIBC]: Include <wchar.h>.
22437         (NOTCANCEL_MODE): New macro.
22438         (flockfile, funlockfile) [_LIBC]: New macros.
22439         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
22440         [!_LIBC]: New macros.
22441         (call_fclose): New function.
22442         (getpass): Use it.  Save tty stream separately; this simplifies the
22443         code and makes it more reliable if stdin happens to equal stdout.
22444         Invoke __fsetlocking on tty.
22445         Handle thread cancellation if needed.
22446         Namespace cleanup (use __tcgetattr, __getline).
22447         Use bool for Booleans.
22448         [USE_IN_LIBIO]: Handle wide streams.
22449         [!_LIBC]: Unconditionally do the fseek, since we don't know what
22450         stream might go where.
22451
22452         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
22453         doesn't have to include <stdio.h> before us.
22454         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
22455         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
22456         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
22457         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
22458         if not declared, so that we can use getpass.c code from libc without
22459         rewriting it.
22460         (flockfile, ftrylockfile, funlockfile): New macros.
22461
22462 2003-10-08  Paul Eggert  <eggert@twinsun.com>
22463
22464         * modules/getpass: Depend on stdbool.
22465
22466 2003-10-08  Paul Eggert  <eggert@twinsun.com>
22467
22468         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
22469
22470 2003-10-07  Karl Berry  <karl@gnu.org>
22471
22472         * config/config.{guess,sub}: update from config.
22473
22474 2003-10-06  Jim Meyering  <jim@meyering.net>
22475             Bruno Haible  <bruno@clisp.org>
22476
22477         This lets translators provide better translations for the
22478         "Written by ..." part of --version output.
22479         * lib/version-etc.h: Include stdarg.h.
22480         (version_etc_copyright): Declare as readonly.
22481         (version_etc): Make this function variadic with a NULL-terminated list
22482         of author name strings.
22483         (version_etc_va): New declaration.
22484         * lib/version-etc.c: Include stdarg.h, stdlib.h.
22485         (version_etc_copyright): Declare as readonly.
22486         (version_etc_va): New function. Provide a different translatable string
22487         for each possible number of authors < 10. Abbreviate when there are 10
22488         authors or more.
22489         (version_etc): Make this function variadic. Call version_etc_va.
22490         Suggestion from Gary V. Vaughan.
22491
22492         * lib/long-options.h (parse_long_options): Change prototype: the
22493         authors string is moved to the end and becomes variadic.
22494         * lib/long-options.c: Include stdarg.h.
22495         (parse_long_options): Make this function variadic, too.
22496         Call version_etc_va, not version_etc.
22497
22498 2003-10-06  Bruno Haible  <bruno@clisp.org>
22499
22500         * modules/version-etc-2: Remove file.
22501         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
22502
22503 2003-10-06  Bruno Haible  <bruno@clisp.org>
22504
22505         * modules/fatal-signal: New file.
22506         * MODULES.html.sh (func_all_modules): Add fatal-signal.
22507
22508 2003-10-06  Bruno Haible  <bruno@clisp.org>
22509
22510         * m4/fatal-signal.m4: New file.
22511         * m4/signalblocking.m4: New file, from GNU gettext.
22512
22513 2003-10-06  Bruno Haible  <bruno@clisp.org>
22514
22515         * lib/version-etc-2.h: Remove file.
22516         * lib/version-etc-2.c: Remove file.
22517
22518 2003-10-06  Bruno Haible  <bruno@clisp.org>
22519
22520         * lib/fatal-signal.h: New file, from GNU gettext.
22521         * lib/fatal-signal.c: New file, from GNU gettext.
22522
22523 2003-10-05  Paul Eggert  <eggert@twinsun.com>
22524
22525         * README: Rework advice for preventing empty .o files.
22526         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
22527         not <sys/types.h>.
22528
22529 2003-10-04  Karl Berry  <karl@gnu.org>
22530
22531         * lib/argp*: update from libc.
22532
22533 2003-10-04  Karl Berry  <karl@gnu.org>
22534
22535         * config/config.{guess,sub}: update from config.
22536
22537 2003-10-02  Bruno Haible  <bruno@clisp.org>
22538
22539         * modules/lchown (Include): Add lchown.h.
22540         * modules/time_r (Include): Use "..." syntax.
22541         * modules/xgetdomainname (Include): Add xgetdomainname.h.
22542
22543 2003-10-01  Simon Josefsson  <jas@extundo.com>
22544
22545         * MODULES.html.sh (func_all_modules): Move gethostname from section
22546         'based on' to section 'lacking' POSIX:2001.
22547
22548 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
22549
22550         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
22551         to output mode on the same stream.
22552
22553 2003-09-29  Paul Eggert  <eggert@twinsun.com>
22554
22555         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
22556         Fix arg typo in previous patch.
22557
22558 2003-09-28  Jim Meyering  <jim@meyering.net>
22559
22560         * lib/error.c: Correct cpp indentation.
22561
22562 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22563
22564         * modules/free: New file.
22565
22566 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22567
22568         * m4/free.m4: New file.
22569
22570 2003-09-27  Paul Eggert  <eggert@twinsun.com>
22571
22572         * lib/minmax.h (MIN, MAX)
22573         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
22574         Omit the special code that used __typeof__, since we worry that
22575         it could be more trouble than it's worth.  See:
22576         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
22577         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
22578
22579         * lib/free.c: New file.
22580
22581 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
22582
22583         Trivial fixes to Makefile.am parts of module listings.
22584         * modules/strstr: Append strstr.h to lib_SOURCES.
22585         * modules/strcase: Likewise, for strcase.h.
22586
22587 2003-09-27  Karl Berry  <karl@gnu.org>
22588
22589         * config/mkinstalldirs: update from automake.
22590
22591 2003-09-26  Paul Eggert  <eggert@twinsun.com>
22592
22593         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
22594         (error_tail): Do not loop, reallocating temporary buffer, since
22595         the output cannot contain more wide characters than the input
22596         contains bytes, the size must be big enough already.  This avoids
22597         one potential size overflow calculation.  Check for size overflow
22598         when calculating temporary buffer size.  Free temporary buffer
22599         when done, if it was allocated with malloc; this plugs a memory
22600         leak.  Remove casts from void * to pointers, that are no longer
22601         needed now that we're assuming C89 or better.
22602
22603         Merge error changes from glibc.
22604
22605         * lib/error.c, error.h: Update copyright notice header to match glibc.
22606         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
22607         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
22608         Disable cancellation while printing error.
22609         * lib/error.h: Prepend __ to parameter names.
22610
22611 2003-09-26  Jim Meyering  <jim@meyering.net>
22612
22613         * lib/error.c (error_tail): Move some declarations
22614         into inner scope where the local variables are used.
22615
22616 2003-09-26  Bruno Haible  <bruno@clisp.org>
22617
22618         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
22619         stpncpy().
22620         Don't define stpncpy through config.h; it's now done through stpncpy.h.
22621
22622 2003-09-26  Bruno Haible  <bruno@clisp.org>
22623
22624         * lib/stpncpy.h (gnu_stpncpy): New declaration.
22625         (stpncpy): Define as alias for gnu_stpncpy.
22626         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
22627
22628 2003-09-25  Simon Josefsson  <jas@extundo.com>
22629
22630         * lib/xgetdomainname.h: New file.
22631         * lib/xgetdomainname.c: New file.
22632
22633 2003-09-25  Simon Josefsson  <jas@extundo.com>
22634             Bruno Haible  <bruno@clisp.org>
22635
22636         * modules/getdomainname: New file.
22637         * modules/xgetdomainname: New file.
22638         * MODULES.html.sh (func_all_modules): Add getdomainname,
22639         xgetdomainname.
22640
22641 2003-09-25  Simon Josefsson  <jas@extundo.com>
22642             Bruno Haible  <bruno@clisp.org>
22643
22644         * m4/getdomainname.m4: New file.
22645
22646 2003-09-25  Simon Josefsson  <jas@extundo.com>
22647             Bruno Haible  <bruno@clisp.org>
22648
22649         * lib/getdomainname.h: New file.
22650         * lib/getdomainname.c: New file.
22651
22652 2003-09-25  Karl Berry  <karl@gnu.org>
22653
22654         * lib/argp-fmtstream.c, argp-help.c: update from libc.
22655
22656 2003-09-25  Karl Berry  <karl@gnu.org>
22657
22658         * config/install-sh: update from automake.
22659
22660 2003-09-25  Bruno Haible  <bruno@clisp.org>
22661
22662         * modules/version-etc-2: New file, from modules/version-etc with
22663         modifications.
22664         * MODULES.html.sh (func_all_modules): Add version-etc-2.
22665
22666 2003-09-25  Bruno Haible  <bruno@clisp.org>
22667
22668         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
22669         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
22670
22671 2003-09-24  Simon Josefsson  <jas@extundo.com>
22672
22673         * modules/xgethostname: Add xgethostname.h.
22674
22675 2003-09-24  Paul Eggert  <eggert@twinsun.com>
22676
22677         * lib/linebuffer.c (freebuffer): Don't free the argument, just
22678         the buffer associated with the argument.  Bug reported by
22679         Simon Josefsson.
22680
22681 2003-09-24  Paul Eggert  <eggert@twinsun.com>
22682
22683         * README: Document assumptions that 'int' is at least 32 bits
22684         wide, that integer arithmetic is 2's complement without overflow,
22685         that there are no holes in integer values, that adding sizes of
22686         two nonoverlapping objects can't overflow, and that all-bits-zero
22687         yields scalar zero.  Fix spelling and capitalization typos.
22688
22689 2003-09-19  Karl Berry  <karl@gnu.org>
22690
22691         * lib/argp.h: update from libc.
22692
22693 2003-09-17  Paul Eggert  <eggert@twinsun.com>
22694
22695         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
22696         to avoid spurious warnings like "AC_RUN_IFELSE was called before
22697         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
22698
22699 2003-09-17  Paul Eggert  <eggert@twinsun.com>
22700
22701         * gnulib-tool: Use "test -h", not "test -L", for portability
22702         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
22703         (tags_regexp): Remove, since \| doesn't conform to POSIX.
22704         (sed_extract_prog): Issue s commands one-by-one, rather than
22705         using \| in one s command.
22706
22707 2003-09-16  Paul Eggert  <eggert@twinsun.com>
22708
22709         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
22710         input error, instead of returning NULL the next time we are called
22711         (and therefore losing track of errno).
22712
22713 2003-09-16  Bruno Haible  <bruno@clisp.org>
22714
22715         * gnulib-tool (func_create_testdir): Warn about duplicated
22716         dependencies.
22717
22718 2003-09-15  Paul Eggert  <eggert@twinsun.com>
22719
22720         * modules/argmatch, modules/fatal, modules/obstack,
22721         modules/xalloc, modules/xgethostname: Sort dependencies by
22722         importance, not alphabetically.
22723
22724 2003-09-15  Paul Eggert  <eggert@twinsun.com>
22725
22726         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
22727         fails, so that the caller gets the proper errno.
22728
22729         * lib/readutmp.c (read_utmp): Likewise.
22730         Check for fstat error.  Close stream and free storage
22731         when failing.
22732
22733 2003-09-14  Karl Berry  <karl@gnu.org>
22734
22735         * config/srclist.txt (strdup.c): disable for c89 changes.
22736
22737 2003-09-14  Jim Meyering  <jim@meyering.net>
22738
22739         * lib/getloadavg.c: Correct cpp indentation.
22740         * lib/strdup.c: Likewise.
22741         * lib/vasnprintf.c: Likewise.
22742
22743 2003-09-14  Bruno Haible  <bruno@clisp.org>
22744
22745         * modules/fwriteerror: New file.
22746         * MODULES.html.sh (func_all_modules): Add fwriteerror.
22747
22748 2003-09-14  Bruno Haible  <bruno@clisp.org>
22749
22750         * lib/fwriteerror.h: New file.
22751         * lib/fwriteerror.c: New file.
22752
22753 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22754
22755         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
22756         modules/xgethostname, modules/xalloc: Depend on exit.
22757
22758 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22759
22760         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
22761
22762         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
22763         and AC_MINIX, too, so that their extensions are available.
22764
22765         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
22766         This macro has been superseded by gl_BACKUPFILE.
22767
22768         More patches to assume C89 or better.
22769
22770         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
22771
22772         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
22773         unconditionally.
22774         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
22775         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
22776         Include <string.h>, <stdlib.h> unconditionally.
22777         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
22778         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
22779         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
22780         headers or for string.h.
22781         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
22782         or strtoul.
22783
22784         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
22785         headers.
22786         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
22787         * m4/userspec.m4 (gl_USERSPEC): Likewise.
22788         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
22789         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
22790         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
22791         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
22792         memcpy, memset.
22793         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
22794         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
22795         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
22796         strtol.
22797         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
22798         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
22799         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
22800         strtoul.
22801
22802 2003-09-12  Paul Eggert  <eggert@twinsun.com>
22803
22804         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
22805         * lib/obstack.c [!defined _LIBC]: Likewise.
22806         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
22807         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
22808         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
22809
22810         More changes to assume C89 or better.
22811
22812         * lib/error.c (error_tail): Assume vprintf.
22813
22814         * lib/argmatch.c (getenv): Remove decl.
22815         * lib/progreloc.c (get_full_program_name): Define via prototype.
22816         * lib/setenv.c (clearenv): Likewise.
22817         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
22818         needed.
22819         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
22820         (malloc, memcpy): Remove decls.
22821         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
22822         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
22823         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
22824         (memcpy): Remove macro.
22825         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
22826         (__P): Remove.  All uses removed.
22827         (PTR): Remove.  All uses changed to void *.
22828         (CHAR_BIT, NULL): Remove.
22829         (spaces, zeros, memset_space, memset_zero)
22830         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
22831         Remove.
22832         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
22833         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
22834         Define with prototype.
22835         Remove now-unnecessary prototype decl.
22836         (extra_args_spec): Assume ANSI C.  All uses changed.
22837         (extra_args_spec_iso): Remove.
22838         (my_strftime, emacs_strftimeu): Define via prototype.
22839         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
22840         unconditionally.
22841         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
22842         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
22843         (strtoul, strtol): Remove decls.
22844         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
22845         LONG_MAX): Remove.
22846         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
22847         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
22848         (LOCALE_PARAM_PROTO): New macro.
22849         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
22850         (INTERNAL (strtol), strtol): Define with a prototype.
22851         (PARAMS): Remove.  All uses removed.
22852         * lib/tempname.c: Include <string.h> unconditionally.
22853         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
22854         * lib/xgethostname.c (main): Define with a prototype.
22855         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
22856         Include <stdlib.h> unconditionally.
22857         (calloc, malloc, realloc, free): Remove decls.
22858         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
22859         Include <stdlib.h> unconditionally.  Sort include file names.
22860         (strtod): Remove.
22861         (xstrtod): Define with a prototype.
22862         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
22863         (strtol, strtoul): Remove decls.
22864
22865 2003-09-11  Paul Eggert  <eggert@twinsun.com>
22866
22867         More patches to assume C89 or better.
22868         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
22869         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
22870         string.h, memchr, STDC_HEADERS.
22871
22872 2003-09-11  Paul Eggert  <eggert@twinsun.com>
22873
22874         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
22875         Include <stdlib.h>, <string.h> unconditionally.
22876         Remove now-unnecessary cast to char *.
22877         * lib/strnlen.c: Include <string.h> unconditionally.
22878         * lib/yesno.c (yesno): Define with a prototype.
22879
22880 2003-09-11  Bruno Haible  <bruno@clisp.org>
22881
22882         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
22883
22884 2003-09-10  Jim Meyering  <jim@meyering.net>
22885
22886         * lib/error.c: Correct indentation of cpp directives.
22887
22888 2003-09-10  Bruno Haible  <bruno@clisp.org>
22889
22890         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
22891         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
22892         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
22893         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
22894         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
22895         <stdlib.h> and <string.h> checks.
22896         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
22897         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
22898
22899 2003-09-10  Bruno Haible  <bruno@clisp.org>
22900
22901         * lib/strcspn.c: Include <string.h> unconditionally.
22902         * lib/strpbrk.c: Include <string.h> unconditionally.
22903         * lib/strstr.c: Include <string.h> unconditionally.
22904         * lib/unicodeio.c: Include <string.h> unconditionally.
22905         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
22906         * lib/unsetenv.c: Likewise.
22907         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
22908         * lib/yesno.c: Include <stdlib.h> unconditionally.
22909         (rpmatch): Add prototype.
22910
22911 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22912
22913         More patches to assume C89 or better.
22914         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
22915         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
22916         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
22917         or for string.h.
22918         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
22919         stdlib.h.
22920         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
22921         C headers.
22922         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
22923         string.h.
22924         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
22925         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
22926         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
22927         or for string.h.
22928         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
22929         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
22930         C headers.
22931         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
22932         memcpy.
22933         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
22934         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
22935         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
22936         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
22937         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
22938         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
22939         string.h, free.
22940         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
22941         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
22942         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
22943         C headers, or for string.h.
22944         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
22945         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
22946         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
22947         headers, memory.h, stdlib.h, string.h, strings.h.
22948         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
22949         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
22950         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
22951         strchr.
22952         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
22953         headers, memory.h, string.h.
22954         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
22955         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
22956         free.
22957         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
22958         headers.
22959         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
22960         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
22961         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
22962         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
22963         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
22964
22965 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22966
22967         More K&R removal.
22968
22969         * lib/acosl.c (main): Use a prototype.
22970         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
22971         tanl.c: Likewise.
22972
22973         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
22974
22975         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
22976         (getopt, etopt_long, getopt_long_only, _getopt_internal)
22977         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
22978         with a prototype.
22979         * lib/getopt.c (const): Remove macro.
22980         Include <string.h> unconditionally.
22981         (my_index): Remove; all uses changed to strchr.
22982         (strlen): Remove decl.
22983         (exchange): Remove forward decl; no longer needed.
22984         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
22985         Define with prototype.
22986         * lib/getopt1.c (const): Remove macro.
22987         (getopt_long, getopt_long_only, main): Define with prototype.
22988
22989         * lib/getugroups.c: Include <string.h> unconditionally.
22990
22991         * lib/getusershell.c: Include <stdlib.h> unconditionally.
22992         (getusershell, setusershell, endusershell, readname, main):
22993         Define with prototypes.
22994
22995         * lib/group-member.c: Include group-member.h first.
22996         Include <stdlib.h> unconditionally.
22997
22998         * lib/hard-locale.c: Include hard-locale.h first.
22999         Include <stdlib.h>, <string.h> unconditionally.
23000
23001         * lib/hash.c (free, malloc): Remove decls.
23002         Include <stdlib.h> unconditionally.
23003
23004         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
23005         (getenv): Do not declare.
23006
23007         * lib/idcache.c: Include <string.h> unconditionally.
23008
23009         * lib/long-options.c: Include long-options.h first, to test interface.
23010         Include <stdlib.h> unconditionally.
23011
23012         * lib/makepath.c: Include makepath.h first, to test interface.
23013         Include <stdlib.h> and <string.h> unconditionally.
23014
23015         * lib/linebuffer.c: Include <stdlib.h>.
23016         (free): Remove decl.
23017
23018         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
23019         stddef.h. rpl_malloc returns void *, not char *.
23020         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
23021         prototype.
23022
23023         * lib/md5.h: Include <limits.h> unconditionally.
23024         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
23025         (__P): Remove; all uses removed.
23026         * lib/md5.c: Include "md5.h" first.
23027         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
23028         md5_buffer, md5_process_bytes, md5_process_block):
23029         Define with prototypes.
23030         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
23031         * lib/sha.c: Include "sha.h" first.
23032         Include <stdlib.h>, <string.h> unconditionally.
23033
23034         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
23035         * lib/memcmp.c (__ptr_t): Likewise.
23036         * lib/memrchr.c (__ptr_t): Likewise.
23037         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
23038         Include <string.h> unconditionally.
23039         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
23040         * lib/memchr.c: Include <stdlib.h> unconditionally.
23041         * lib/memchr.c (LONG_MAX): Remove.
23042         * lib/memrchr.c (LONG_MAX): Likewise.
23043         * lib/memchr.c (__memchr): Define via a prototype.
23044         * lib/memrchr.c (__memrchr): Likewise.
23045         * lib/memcmp.c (__P): Remove, and remove all uses.
23046         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
23047         Remove forward decls; no longer needed.
23048         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
23049         Use types required by C89 in prototype.
23050
23051         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
23052         * lib/savedir.c: Likewise.
23053         * lib/mkdir.c (free): Remove decl.
23054         * lib/rmdir.c (rmdir): Define with a prototype.
23055         * lib/savedir.c: Include savedir.h first, to test interface.
23056
23057         * lib/mktime.c (STDC_HEADERS): Remove.
23058         Include <stdlib.h>, <string.h> unconditionally.
23059
23060         * lib/modechange.c: Include <stdlib.h> unconditionally.
23061         (malloc): Remove decl.
23062
23063         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
23064         (free): Remove decl.
23065
23066         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
23067         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
23068         (This type really should be intptr_t, but that's a C99ism.)
23069         (_obstack_memcpy): Remove: all uses changed to memcpy.
23070         Include <string.h> unconditionally.
23071         (struct obstack): Assume __STDC__ for types of members
23072         chunkfun, freefun, extra_arg.
23073         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
23074         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
23075         obstack_begin, obstack_specify_allocation,
23076         obstack_specify_allocation_with_arg, obstack_chunkfun,
23077         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
23078         Remove unprototyped decls and the macros that use them.
23079         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
23080         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
23081         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
23082         (defined __STDC__ && __STDC__)]:
23083         Remove nonprototyped code.
23084         Include <stdlib.h> unconditionally.
23085         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
23086         _obstack_allocated_p, _obstack_free, obstack_free,
23087         _obstack_memory_used, print_and_abort):
23088         Define using prototypes.
23089         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
23090         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
23091         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
23092         obstack_next_free, obstack_object_size, obstack_room) [0]:
23093         Remove unused, unprototyped code.
23094
23095         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
23096
23097         * lib/physmem.c (physmem_total, physmem_available, main): Define
23098         with prototypes.
23099
23100         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
23101         (main): Define with a prototype.
23102
23103         * lib/posixver.c (getenv): Remove decl.
23104
23105         * lib/putenv.c (malloc): Returns void *, not char *.
23106         Include <string.h> unconditionally.
23107         (strchr, memcpy, NULL): Do not define.
23108
23109         * lib/readtokens.c: Include readtokens.h first, to test interface.
23110         Include <stdlib.h>, <string.h> unconditionally.
23111         (init_tokenbuffer): Define with a prototype.
23112
23113         * lib/regex.c (PARAMS): Remove.  All uses removed.
23114         All uses of _RE_ARGS removed, too.
23115         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
23116         unconditionally.
23117         (bzero): Assume memset exists.
23118         (memcmp, memcpy, NULL): Remove.
23119         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
23120         char, or assignments to local vars of type signed char.
23121         (init_syntax_once, PREFIX(extract_number_and_incr),
23122         PREFIX(print_partial_compiled_pattern),
23123         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
23124         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
23125         PREFIX(regex_grow_registers), PREFIX(regex_compile),
23126         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
23127         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
23128         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
23129         wcs_compile_range, byte_compile_range, truncate_wchar,
23130         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
23131         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
23132         count_mbs_length, wcs_re_match_2_internal,
23133         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
23134         PREFIX(alt_match_null_string_p),
23135         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
23136         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
23137         regfree, PREFIX(extract_number)): Define with prototype.  Remove
23138         now-unnecessary declaration, if any.
23139         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
23140         regcomp, regexec):
23141         Remove now-unnecessary casts among pointer types.
23142         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
23143
23144         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
23145         (free): Remove decl.
23146
23147         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
23148
23149         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
23150         (free): Remove decl.
23151
23152         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
23153         * lib/xgetcwd.c: Likewise.
23154
23155         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
23156         (free): Remove decl.
23157
23158         * lib/strchrnul.c (strchrnul): Define with a prototype.
23159         Fix bug: c_in was not converted to char before searching.
23160
23161         The following changes are not K&R related:
23162
23163         * lib/group-member.h: Include <sys/types.h>, so that this file is
23164         self-contained.
23165         * lib/makepath.h: Likewise.
23166
23167         * lib/getusershell.c (readname, default_index, line_size, readname):
23168         Use size_t, not int, for sizes.
23169         (readname): If the size overflows, report an error instead of
23170         looping forever.
23171
23172 2003-09-09  Paul Eggert  <eggert@twinsun.com>
23173
23174         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
23175         libc.
23176
23177 2003-09-09  Paul Eggert  <eggert@twinsun.com>
23178
23179         * README: New section: portability guidelines.
23180
23181 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
23182
23183         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
23184         C89 spec.
23185
23186 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
23187
23188         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
23189
23190 2003-09-08  Paul Eggert  <eggert@twinsun.com>
23191
23192         Assume C89 or better; remove K&R cruft.
23193         A few of these changes were first proposed by Derek Robert Price
23194         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
23195
23196         * lib/addext.c: Include <string.h> unconditionally.
23197         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
23198         Don't declare getenv or malloc.
23199
23200         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
23201         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
23202         (NULL): Remove.
23203         (find_stack_direction, alloca): Use prototypes.
23204
23205         * lib/atexit.c (atexit): Define using a prototype.
23206
23207         * lib/basename.c, dirname.c, stripslash.c:
23208         Include <string.h> unconditionally.
23209
23210         * lib/bcopy.c: Include <stddef.h>.
23211         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
23212
23213         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
23214
23215         * lib/error.h (error, error_at_line, error_print_progname)
23216         [! (defined (__STDC__) && __STDC__)]: Remove decls.
23217         * lib/error.c: Include error.h first, to check interface.
23218         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
23219         (VA_START): Remove; all uses changeed to va_start.
23220         (exit, strerror): Remove decls.
23221         (error_print_progname): Prototype uncondionally.
23222         Don't include <errno.h>; no longer needed.
23223         (private_strerror): Remove.
23224         (error_tail): Always define.
23225         (error, error_at_line): Assume C89 or better; always use prototypes.
23226         * lib/fatal.c: Include "fatal.h" first, to test interface.
23227         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
23228         (VA_START): Remove; all uses changed to va_start.
23229         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
23230         this case.
23231         (exit): Remove decl.
23232         (fatal): Prototype unconditionally.  Assume va_start works.
23233         Abort at end, to pacify gcc.
23234
23235         * lib/euidaccess.c (main): Define with a prototype.
23236
23237         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
23238
23239         * lib/exitfail.c: Include <stdlib.h> unconditionally.
23240
23241         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
23242         prototypes.
23243         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
23244         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
23245         (getenv): Remove decl.
23246         (fnmatch): Define using a prototype.
23247         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
23248         (FCT): Define using a prototype.
23249
23250         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
23251
23252         * lib/gethostname.c: Include <stddef.h>.
23253         (gethostname): Define with prototype.  Length is size_t, not int.
23254
23255 2003-09-08  Paul Eggert  <eggert@twinsun.com>
23256
23257         Assume C89 or better; remove K&R cruft.
23258         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
23259         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
23260         string.h, getenv, malloc.
23261         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
23262         headers.
23263         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
23264         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
23265         do not check for strerror.
23266         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
23267         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
23268         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
23269         do not check for doprnt or vprintf.
23270         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
23271         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
23272
23273 2003-09-08  Paul Eggert  <eggert@twinsun.com>
23274
23275         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
23276         getversion.c should have been removed then, but was accidentally
23277         preserved.
23278
23279         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
23280         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
23281
23282 2003-09-08  Karl Berry  <karl@gnu.org>
23283
23284         * config/config.sub, config.guess, srclistvars.sh: update from savannah
23285                 config, forget about prep.
23286
23287         * config/depcomp, missing: update from automake.
23288
23289 2003-09-07  Paul Eggert  <eggert@twinsun.com>
23290
23291         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
23292         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
23293
23294 2003-09-07  Paul Eggert  <eggert@twinsun.com>
23295
23296         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
23297         copy_tm_result.  Bug reported by Simon Josefsson in
23298         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
23299
23300 2003-09-06  Paul Eggert  <eggert@twinsun.com>
23301
23302         * m4/time_r.m4: New file.
23303         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
23304         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
23305         is. Check for timegm declaration.
23306         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
23307         Do not check for gmtime_r.
23308         Replace mktime if __mktime_internal does not exist and if mktime
23309         hasn't been replaced already.
23310
23311 2003-09-06  Paul Eggert  <eggert@twinsun.com>
23312
23313         * lib/time_r.c, lib/time_r.h: New files.
23314
23315         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
23316         __localtime_r.
23317         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
23318         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
23319
23320         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
23321         __gmtime_r.
23322         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
23323         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
23324         Include <time_r.h>.
23325
23326         * lib/timegm.c: Switch to glibc implementation, with the following
23327         changes:
23328         [defined HAVE_CONFIG_H]: Include <config.h>.
23329         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
23330         (__mktime_internal) [!defined _LIBC]: New decl.
23331         (__gmtime_r) [!defined _LIBC]: New macro and function.
23332         (timegm): Use a prototype, since gnulib assumes C89.
23333         Do not bother declaring tmp to be const, as it's not really usefu.
23334         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
23335         (timegm): Declare only if HAVE_DECL_TIMEGM.
23336
23337 2003-09-06  Paul Eggert  <eggert@twinsun.com>
23338
23339         * MODULES.html.sh (func_all_modules): Add time_r.
23340         * modules/time_r: New file.
23341         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
23342         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
23343
23344 2003-09-03  Paul Eggert  <eggert@twinsun.com>
23345
23346         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
23347         Bug reported by Lute Kamstra in
23348         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
23349
23350         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
23351         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
23352         course with correspondingly smaller numbers for tomorrow and
23353         yesterday.  From Tadayoshi Funaba.  Originally installed into
23354         sh-utils on 1999-08-07, but the patch got lost (I guess during the
23355         coreutils merge?).
23356
23357 2003-08-31  Simon Josefsson  <jas@extundo.com>
23358
23359         * modules/timegm: New file.
23360         * MODULES.html.sh (func_all_modules): Add timegm.
23361
23362 2003-08-31  Simon Josefsson  <jas@extundo.com>
23363
23364         * m4/timegm.m4: New file.
23365
23366 2003-08-31  Simon Josefsson  <jas@extundo.com>
23367
23368         * lib/timegm.h: New file.
23369         * lib/timegm.c: New file.  Based on
23370         wget-1.8.2/src/http.c:mktime_from_utc.
23371
23372 2003-08-31  Karl Berry  <karl@gnu.org>
23373
23374         * lib/argp.h: update from libc.
23375
23376 2003-08-28  Bruno Haible  <bruno@clisp.org>
23377
23378         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
23379         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
23380         followed by '#define fnmatch fnmatch_posix' gives an error.
23381
23382 2003-08-28  Bruno Haible  <bruno@clisp.org>
23383
23384         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
23385         warning on QNX, which defines O_BINARY to 000000.
23386
23387 2003-08-27  Jim Meyering  <jim@meyering.net>
23388
23389         * m4/mkstemp.m4: Require that the system mkstemp be able to create
23390         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
23391         would fail after 32.  Reported by Danny Levinson.  Details here:
23392         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
23393
23394 2003-08-24  Bruno Haible  <bruno@clisp.org>
23395
23396         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
23397         MSVC7 <stdio.h> is included later.
23398
23399 2003-08-22  Simon Josefsson  <jas@extundo.com>
23400
23401         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
23402
23403 2003-08-20  Karl Berry  <karl@gnu.org>
23404
23405         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
23406
23407 2003-08-20  Bruno Haible  <bruno@clisp.org>
23408
23409         * modules/progname: New file.
23410         * MODULES.html.sh (func_all_modules): Add progname.
23411
23412 2003-08-20  Bruno Haible  <bruno@clisp.org>
23413
23414         * lib/progname.h: New file, from GNU gettext.
23415         * lib/progname.c: New file, from GNU gettext.
23416         * lib/progreloc.c: New file, from GNU gettext.
23417
23418 2003-08-19  Jim Meyering  <jim@meyering.net>
23419
23420         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
23421         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
23422
23423 2003-08-19  Bruno Haible  <bruno@clisp.org>
23424
23425         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
23426         more.
23427
23428 2003-08-19  Bruno Haible  <bruno@clisp.org>
23429
23430         * lib/xstrdup.c: Assume <string.h> exists.
23431
23432 2003-08-18  Paul Eggert  <eggert@twinsun.com>
23433
23434         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
23435         in makefile rules.
23436
23437 2003-08-18  Jim Meyering  <jim@meyering.net>
23438
23439         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
23440         * m4/lib-ld.m4: Likewise.
23441
23442 2003-08-18  Jim Meyering  <jim@meyering.net>
23443
23444         * lib/setenv.h: Indent nested cpp directive.
23445         * lib/vasnprintf.c: Remove trailing blanks.
23446
23447 2003-08-17  Simon Josefsson  <jas@extundo.com>
23448
23449         * modules/xstrndup: New file.
23450         * MODULES.html.sh (func_all_modules): Add xstrndup.
23451
23452 2003-08-17  Simon Josefsson  <jas@extundo.com>
23453
23454         * modules/argp: Fix autoconf macro name. Add more dependencies.
23455
23456 2003-08-17  Simon Josefsson  <jas@extundo.com>
23457
23458         * m4/xstrndup.m4: New file.
23459
23460 2003-08-17  Simon Josefsson  <jas@extundo.com>
23461
23462         * m4/argp.m4: New file.
23463
23464 2003-08-17  Simon Josefsson  <jas@extundo.com>
23465             Bruno Haible  <bruno@clisp.org>
23466
23467         * lib/xstrndup.h: New file.
23468         * lib/xstrndup.c: New file.
23469
23470 2003-08-17  Bruno Haible  <bruno@clisp.org>
23471
23472         * modules/strndup (Files, Include): Add lib/strndup.h.
23473
23474 2003-08-17  Bruno Haible  <bruno@clisp.org>
23475
23476         * modules/euidaccess (Files): Add lib/euidaccess.h.
23477
23478 2003-08-17  Bruno Haible  <bruno@clisp.org>
23479
23480         * lib/strndup.h: New file.
23481
23482 2003-08-17  Bruno Haible  <bruno@clisp.org>
23483
23484         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
23485         like AC_GNU_SOURCE.
23486         * modules/extensions (configure.ac): Comment out the invocation of
23487         gl_USE_SYSTEM_EXTENSIONS.
23488
23489 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23490
23491         Merges from coreutils, etc.
23492         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
23493         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
23494         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
23495         fixing a typo.
23496         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
23497         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
23498
23499 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23500
23501         Document merge from coreutils.
23502         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
23503         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
23504         * modules/utime: Add m4/utimes-null.m4.
23505
23506 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23507
23508         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
23509         space, undoing this 2003-08-12 change:
23510         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
23511
23512 2003-08-16  Paul Eggert  <eggert@twinsun.com>
23513
23514         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
23515         strtoul.c from libc, undoing this 2003-08-12 change:
23516         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
23517
23518 2003-08-16  Jim Meyering  <jim@meyering.net>
23519
23520         Merges from coreutils.
23521         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
23522         prefix.  Adjust cache variables similarly.  Create 500 rather than
23523         just 300 files, to exercise bug on Darwin6.5, too.
23524         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
23525         $missing_dir.
23526         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
23527         AM_SYS_POSIX_TERMIOS.
23528         Reported by mkc@mathdogs.com.
23529         Also change use of $am_cv_sys_posix_termios
23530         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
23531         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
23532         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
23533         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
23534         in /proc/mounts until it finds one with matching device number.  This
23535         is unnecessary when the FILE argument *is* a mount point.  No stat call
23536         is necessary in that case.  So, disable the statvfs-testing code on
23537         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
23538         as RedHat bug# 84846.
23539         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
23540         to 1MB, so as not to render systems with no stack size limit (e.g.,
23541         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
23542         Include <unistd.h>.  On some systems,
23543         it is required for the definition of _SC_PAGESIZE.
23544
23545 2003-08-16  Jim Meyering  <jim@meyering.net>
23546
23547         Merge from coreutils.
23548         * lib/xstrtoimax.c: #else #if -> #elif.
23549         * lib/xstrtoumax.c: Likewise.
23550
23551 2003-08-16  Jim Meyering  <jim@meyering.net>
23552
23553         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
23554         * m4/utimes.m4: Removed.
23555         * m4/utimes-null.m4: Renamed from utimes.m4.
23556
23557         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
23558         to 1MB, so as not to render systems with no stack size limit (e.g.,
23559         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
23560         Include <unistd.h>.  On some systems,
23561         it is required for the definition of _SC_PAGESIZE.
23562
23563 2003-08-16  Jim Meyering  <jim@meyering.net>
23564         and Paul Eggert  <eggert@cs.ucla.edu>
23565
23566         Merges from coreutils, etc.
23567
23568         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
23569         using the latest version from cvs.  This avoids problems with #line
23570         directives using a vendor (Sun) compiler.
23571         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
23572         Don't set GETGROUPS_LIB here; now it's
23573         done via getgroups.m4's wrapper function.
23574         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
23575         rather than just in sh-util/configure.in, so that the
23576         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
23577         same.
23578         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
23579         AC_FUNC_GETLOADAVG where to find getloadavg.c.
23580         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
23581         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
23582         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
23583         Remove code that is now done by the newly-required macros.
23584         Append $(EXEEXT) to DF_PROG.
23585         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
23586         Do not invoke or require the following here,
23587         since prereq.m4 or some gnulib .m4 now does this for us:
23588         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
23589         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
23590         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
23591         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
23592         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
23593         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
23594         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
23595         AC_FUNC_OBSTACK.
23596         Do not replace the following functions, as this is now the job
23597         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
23598         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
23599         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
23600         atexit getpass, strdup, getpagesize.
23601         Replace 'raise'.
23602         Do not check for the following functions, as this is now the job
23603         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
23604         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
23605         setregid.
23606         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
23607         Check for sys/sysctl.h.
23608         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
23609         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
23610         of checking for ssize_t ourselves.
23611
23612         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
23613         Require every macro that gnulib/modules/* suggests for us.
23614         (jm_PREREQ_ADDEXT): New macro.
23615         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
23616         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
23617
23618         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
23619         (gl_PHYSMEM): Use it.
23620         Also check for `table' function.
23621         Check for new headers and functions.
23622         Add check for sys/sysmp.h.
23623         With suggestions from Kaveh Ghazi.
23624         Ignore headers that are present but cannot be compiled.  This
23625         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
23626         C 5.4.
23627
23628 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23629
23630         Document merge from coreutils.
23631         * modules/userspec: Depend on posixver.
23632         * modules/strftime: Depend on tzset.
23633
23634 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23635
23636         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
23637         rather than tab, after '#' in shell-script copyright notices.
23638         Suggested by Bruno Haible.
23639
23640 2003-08-15  Paul Eggert  <eggert@twinsun.com>
23641
23642         * config/srclist-update: Use three spaces, rather than tab, after '#'
23643         in shell-script copyright notices.  Suggested by Bruno Haible.
23644         Remove unnecessary parenthesization in regular expression.
23645
23646 2003-08-15  Jim Meyering  <jim@meyering.net>
23647
23648         Merge from coreutils.
23649         * lib/xgethostname.c: Include <stdlib.h>.
23650         (xghostname): Don't exit for anything other than memory-related
23651         failure; just return NULL.
23652         * lib/userspec.c: Include "posixver.h".
23653         (parse_user_spec): Accept `.' as a separator only
23654         in pre-POSIX-200112 mode.
23655         * lib/strtoimax.c: Use #elif rather than #else #if.
23656         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
23657         Remove function, now that we can rely on a working tzset function.
23658         [!_LIBC]: Ensure that the required autoconf test has been run.
23659         [!defined _NL_CURRENT && HAVE_STRFTIME]:
23660         Use underlying_strftime for %r.
23661         * lib/sha.c: Merge in some clean-up and optimization changes from
23662         glibc.
23663         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
23664         Ensure that it is a multiple of 64.
23665         Rearrange loop exit tests so as to avoid performing an
23666         additional fread after encountering an error or EOF.
23667         * lib/realloc.c: Update copyright date.
23668
23669 2003-08-15  Jim Meyering  <jim@meyering.net>
23670         and Paul Eggert  <eggert@twinsun.com>
23671
23672         Merge from coreutils.
23673         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
23674         member but strut utmpx does not.  Needed for AIX 4.3.3.
23675         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
23676
23677 2003-08-15  Jim Meyering  <jim@meyering.net>
23678         and Paul Eggert  <eggert@cs.ucla.edu>
23679
23680         Merges from coreutils, etc.
23681         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
23682         Require gl_FUNC_TZSET_CLOBBER.
23683         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
23684         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
23685         members.
23686
23687 2003-08-14  Paul Eggert  <eggert@twinsun.com>
23688
23689         Help the merge from coreutils.
23690         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
23691         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
23692         * m4/tzset.m4: Use it too.
23693
23694 2003-08-14  Paul Eggert  <eggert@twinsun.com>
23695
23696         * modules/tzset: New file.
23697
23698 2003-08-14  Jim Meyering  <jim@meyering.net>
23699
23700         Merges from coreutils.
23701         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
23702         variable names, rather than @FNMATCH_H@.
23703         * modules/alloca: Likewise for $(ALLOCA_H).
23704
23705         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
23706         the three copies of the literal target, `fnmatch.h'.
23707         * modules/alloca (alloca.h): Likewise.
23708
23709 2003-08-14  Jim Meyering  <jim@meyering.net>
23710
23711         Merge from coreutils.
23712         * m4/tzset.m4: New file.
23713         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
23714         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
23715         otherwise, AIX 5.1 systems would end up using the latter.
23716         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
23717         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
23718         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
23719         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
23720
23721 2003-08-14  Jim Meyering  <jim@meyering.net>
23722
23723         Merge from coreutils.
23724         * lib/obstack.h: Whitespace changes.
23725         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
23726         and xcalloc return values.
23727         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
23728         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
23729         hang on OSF/1 5.1 for DIR on both local and remote file systems.
23730         Reported by (and fix confirmed by) Nelson H. F. Beebe.
23731         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23732         error from mntctl.
23733         Use mntctl's return value to drive the entry-processing loop, since
23734         we can't rely on the value of the vmt_length member in the last
23735         entry.  On some systems doing so could result in exhausting
23736         virtual memory.  Based in part on a patch from Mike Jetzer.
23737
23738 2003-08-14  Jim Meyering  <jim@meyering.net>
23739         and Paul Eggert  <eggert@twinsun.com>
23740
23741         Merges from coreutils, plus other fixes.
23742         * lib/physmem.c: Merge in portability changes from gcc/libiberty
23743         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
23744         for credits and details.  Thanks to Kaveh Ghazi for helping
23745         to keep these files in sync.
23746         (ARRAY_SIZE): Define it.
23747         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
23748         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
23749         (memcasecmp): Don't assume size_t fits in unsigned int.
23750         Remove casts and duplicate code.
23751         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
23752         (memcpy): Remove definition.
23753         Merge in some clean-up and optimization changes from glibc.
23754         [BLOCKSIZE]: Move definition to top of file.
23755         Ensure that it is a multiple of 64.
23756         Rearrange loop exit tests so as to avoid performing an
23757         additional fread after encountering an error or EOF.
23758         * lib/md5.h (md5_uintptr): Define.
23759         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
23760         return to the initial working directory.  Preserve errno
23761         for caller.
23762         * lib/idcache.c: Include "xalloc.h".
23763         (xmalloc, xrealloc): Remove decls.
23764         (getuser): Remove casts no longer required in C89.
23765         * lib/human.c: Include stdio.h, for sprintf.
23766         * lib/group-member.c: Include "xalloc.h".
23767         (xmalloc, xrealloc): Remove decls.
23768         (get_group_info): Remove casts no longer required in C89.
23769         * lib/getusershell.c (readname): Remove casts no longer required in
23770         C89.
23771         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
23772         * lib/getline.c: Whitespace fix, from coreutils.
23773
23774 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23775
23776         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
23777         Check for isascii.
23778
23779         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
23780         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
23781         Undo previous (whitespace-only) change.
23782
23783 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23784
23785         * lib/exclude.c: Include <ctype.h>
23786         (IN_CTYPE_DOMAIN): New macro.
23787         (is_space): New fn.
23788         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
23789         and empty lines.
23790
23791         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
23792         Undo previous (whitespace-only) change.
23793
23794 2003-08-13  Paul Eggert  <eggert@twinsun.com>
23795
23796         * config/srclist-update: Change update back to the old behavior,
23797         leaving whitespace alone.  Use one 'sed' command rather than a
23798         pipeline.
23799         (fixlicense): Now a variable, not a function.
23800         (remove_trailing_blanks): Remove.
23801         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
23802         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
23803         Undo previous (whitespace-only) change.
23804
23805 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23806
23807         Merge from coreutils.
23808         * modules/euidaccess: Add lib_SOURCES, include for new
23809         file euidaccess.h
23810
23811 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23812
23813         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
23814         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
23815         Normalize leading white space and remove trailing white space.
23816
23817         Merge from coreutils
23818         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
23819
23820         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
23821         0.12.1.  These files are now being upgraded automatically by
23822         ../config/srclist-update.
23823
23824 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23825
23826         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
23827         Normalize leading white space and remove trailing white space.
23828         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
23829         notice, as per ../config/srclist-update.
23830
23831         Merge from coreutils.
23832         * lib/euidaccess.h: New file.
23833         * lib/euidaccess.c: Include it.
23834         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
23835         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
23836         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
23837
23838 2003-08-12  Paul Eggert  <eggert@twinsun.com>
23839
23840         * config/srclist-update: Add copyright notice.
23841         (remove_id_lines, remove_trailing_blanks): New constants.
23842         (fixfile): Use them to normalize spacing a bit in copied files.
23843         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
23844         Normalize leading white space and remove trailing white space.
23845
23846         * config/texinfo.tex: Sync with texinfo.
23847
23848         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
23849         strtoul.c from libc, to merge coreutils whitespace changes.
23850
23851         * config/srclist.txt: Get the following m4 files from gettext:
23852         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
23853         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
23854         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
23855         wint_t.m4.
23856
23857 2003-08-12  Karl Berry  <karl@gnu.org>
23858
23859         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
23860         been made.
23861
23862 2003-08-11  Paul Eggert  <eggert@twinsun.com>
23863
23864         * modules/gnu-source, m4/gnu-source.m4:
23865         Remove; we're assuming Autoconf 2.54 or later now.
23866         Suggested by Bruno Haible.
23867         * MODULES.html.sh (func_all_modules): Remove gnu-source.
23868
23869 2003-08-11  Bruno Haible  <bruno@clisp.org>
23870
23871         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
23872
23873 2003-08-11  Bruno Haible  <bruno@clisp.org>
23874
23875         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
23876         (vasnprintf): Use it instead of wcslen.
23877
23878 2003-08-11  Bruno Haible  <bruno@clisp.org>
23879
23880         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
23881         value to ensure that _Bool promotes to int. Use #define for _Bool when
23882         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
23883
23884 2003-08-10  Karl Berry  <karl@gnu.org>
23885
23886         * lib/regex.h: update from libc (whitespace fix).
23887
23888 2003-08-09  Paul Eggert  <eggert@twinsun.com>
23889
23890         Merge some files from coreutils.  These changes were
23891         originally made by Jim Meyering.
23892         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
23893         many older Unixes require this.
23894         * lib/alloca.c (alloca): Remove cast to argument of free;
23895         no longer needed in C89.
23896         * lib/alloca_.h, regex.h: Fix white space to match
23897         what GNU indent does.
23898
23899 2003-08-09  Paul Eggert  <eggert@twinsun.com>
23900
23901         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
23902         apparently Emacs's Unicode mode got confused before my 2003-08-05
23903         checkin.
23904
23905 2003-08-08  Paul Eggert  <eggert@twinsun.com>
23906
23907         * m4/extensions.m4: New file.
23908         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
23909         Require gl_USE_SYSTEM_EXTENSIONS.
23910         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
23911         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
23912
23913 2003-08-08  Paul Eggert  <eggert@twinsun.com>
23914
23915         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
23916         * modules/extensions, modules/gnu-source: New files.
23917         * modules/timespec, modules/unlocked-io: Depend on extensions.
23918
23919 2003-08-07  Paul Eggert  <eggert@twinsun.com>
23920
23921         * modules/restrict: New file.
23922         * MODULES.html.sh (func_all_modules): Add restrict.
23923         * modules/regex: Depend on restrict.
23924
23925 2003-08-07  Paul Eggert  <eggert@twinsun.com>
23926
23927         * m4/restrict.m4: New file.
23928         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
23929
23930 2003-08-07  Bruno Haible  <bruno@clisp.org>
23931
23932         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
23933         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
23934
23935 2003-08-07  Bruno Haible  <bruno@clisp.org>
23936
23937         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
23938         makes the module 'getndelim2' compatible with the module 'getline'.
23939
23940 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23941
23942         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
23943         byte with "\201" to avoid glitches when editing that source file
23944         with multi-gnome-terminal.
23945
23946 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23947
23948         * lib/bumpalloc.h: Remove.
23949
23950 2003-08-05  Paul Eggert  <eggert@twinsun.com>
23951
23952         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
23953         * modules/bumpalloc: Remove.
23954
23955 2003-08-04  Paul Eggert  <eggert@twinsun.com>
23956
23957         * lib/getloadavg.c: Change copyright notice and spacing to conform to
23958         GNU coding style.
23959
23960         Merge from coreutils.
23961         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
23962         1. From glibc.
23963         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
23964         from Karl Berry, implemented by Jim Meyering.
23965         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
23966         from Dmitry V. Levin.
23967         Remove anachronistic cast of xrealloc.
23968         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
23969         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
23970         type. Otherwise, it wouldn't compile with at least /bin/cc on
23971         ymp-cray-unicos9.0.2.X.
23972         Combine two mostly-identical uses of alloca into one.
23973         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
23974
23975 2003-08-04  Dave Love  <d.love@dl.ac.uk>
23976
23977         [From Emacs.]
23978
23979         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
23980         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
23981         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
23982         obsolete NLIST_NAME_UNION.
23983         [__GNU__]: Undef BSD and FSCALE.
23984         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
23985
23986 2003-08-03  Paul Eggert  <eggert@twinsun.com>
23987
23988         * lib/stdbool_.h (_Bool): Make it signed char, instead of
23989         an enum type, so that it's guaranteed to promote to int.  See:
23990         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
23991
23992 2003-08-03  Karl Berry  <karl@gnu.org>
23993
23994         * config/depcomp: update from automake.
23995
23996 2003-07-31  Paul Eggert  <eggert@twinsun.com>
23997
23998         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
23999         (strerror): Don't assume that a printable int fits in 14 bytes.
24000
24001 2003-07-31  Bruno Haible  <bruno@clisp.org>
24002
24003         * modules/getpass-gnu: New file.
24004         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
24005
24006 2003-07-31  Bruno Haible  <bruno@clisp.org>
24007
24008         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
24009
24010 2003-07-24  Karl Berry  <karl@gnu.org>
24011
24012         * config/missing: update from automake.
24013
24014 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
24015             Bruno Haible  <bruno@clisp.org>
24016
24017         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
24018         * lib/getline.c (getline, getdelim): Likewise.
24019         Remove _GNU_SOURCE define; now it's defined in config.h through
24020         m4/getline.m4.
24021
24022 2003-07-23  Karl Berry  <karl@gnu.org>
24023
24024         * config/config.sub: update from prep.
24025
24026 2003-07-22  Paul Eggert  <eggert@twinsun.com>
24027
24028         * modules/xalloc (Depends-on): Add exitfail.
24029         * modules/xmemcoll: Likewise.
24030
24031 2003-07-22  Paul Eggert  <eggert@twinsun.com>
24032
24033         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
24034         over-parenthesization in macros.
24035
24036         Sync with coreutils.
24037
24038         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
24039         required by C99.
24040
24041         Use `exit_failure' for xalloc and xmemcoll instead of their own
24042         private exit-failure variables.
24043         * lib/xalloc.h (xalloc_exit_failure): Remove.
24044         * lib/xmalloc.c: Likewise.  Include exitfail.h.
24045         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
24046         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
24047         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
24048         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
24049
24050 2003-07-20  Jim Meyering  <jim@meyering.net>
24051
24052         * modules/closeout (Depends-on): Add exitfail.
24053         Suggestion from Bruno Haible.
24054
24055 2003-07-19  Karl Berry  <karl@gnu.org>
24056
24057         * config/config.sub: update from prep.
24058
24059 2003-07-18  Paul Eggert  <eggert@twinsun.com>
24060
24061         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
24062         Remove.
24063         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
24064         to test that it can stand by itself.  Include "exitfail.h".
24065         Clients should set exit_failure instead.
24066         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
24067
24068 2003-07-18  Bruno Haible  <bruno@clisp.org>
24069
24070         * modules/getndelim2: New file.
24071         * modules/getline: Share files with module getndelim2.
24072         * modules/getnline: Depend on getndelim2 instead of sharing files with
24073         it. Add getnline.c to lib_SOURCES.
24074         * MODULES.html.sh (func_all_modules): Add getndelim2.
24075
24076 2003-07-18  Bruno Haible  <bruno@clisp.org>
24077
24078         * m4/getndelim2.m4: New file.
24079         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
24080         invoke gl_PREREQ_GETNDELIM2.
24081         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
24082         gl_PREREQ_GETNDELIM2.
24083         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
24084         gl_GETNDELIM2.
24085
24086 2003-07-18  Bruno Haible  <bruno@clisp.org>
24087
24088         * lib/getndelim2.h: New file.
24089         * lib/getndelim2.c: Make into a module of its own. Include config.h,
24090         getndelim2.h.
24091         (getndelim2): Make non-static. Change return type to ssize_t.
24092         * lib/getline.h: Change argument names.
24093         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
24094         * lib/getnline.c: Include getndelim2.h.
24095
24096 2003-07-18  Andreas Schwab  <schwab@suse.de>
24097
24098         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
24099
24100 2003-07-17  Karl Berry  <karl@gnu.org>
24101
24102         * config/config.sub: update from prep.
24103
24104 2003-07-17  Bruno Haible  <bruno@clisp.org>
24105
24106         * modules/getnline: New file.
24107         * modules/getline: Add lib/getndelim2.c to source file list.
24108         * MODULES.html.sh (func_all_modules): Add getnline.
24109
24110 2003-07-17  Bruno Haible  <bruno@clisp.org>
24111
24112         * m4/getnline.m4: New file.
24113
24114 2003-07-17  Bruno Haible  <bruno@clisp.org>
24115
24116         * m4/Makefile.am.in: Remove file.
24117         * m4/Makefile.am: Remove file.
24118         * m4/Makefile.in: Remove file.
24119
24120 2003-07-17  Bruno Haible  <bruno@clisp.org>
24121
24122         * lib/getnline.h: New file.
24123         * lib/getnline.c: New file.
24124         * lib/getndelim2.c: New file, extracted from getline.c.
24125         (getndelim2): Renamed from getdelim2, with added nmax argument.
24126         * lib/getline.c: Include getndelim2.c.
24127         (getdelim2): Moved out to getndelim2.c.
24128         (getline, getdelim): Update.
24129
24130 2003-07-17  Bruno Haible  <bruno@clisp.org>
24131
24132         * lib/Makefile.am: Remove file.
24133         * lib/Makefile.in: Remove file.
24134
24135 2003-07-17  Bruno Haible  <bruno@clisp.org>
24136
24137         * configure.in: Remove file.
24138         * Makefile.in: Remove file.
24139
24140 2003-07-17  Bruno Haible  <bruno@clisp.org>
24141
24142         * MODULES.html.sh: Put the </BODY> right before </HTML>.
24143
24144 2003-07-16  Karl Berry  <karl@gnu.org>
24145
24146         * config/srclist-update: was running fixlicense twice, which caused
24147                 texinfo.tex to be nullified for some reason.  Simplify,
24148                 $gplsrc is no longer needed as far as I can see?
24149
24150 2003-07-16  Jim Meyering  <jim@meyering.net>
24151
24152         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
24153
24154 2003-07-15  Paul Eggert  <eggert@twinsun.com>
24155
24156         * config/srclist.txt: Get the following files from gettext-runtime/intl
24157         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
24158         ref-del.sin.  From Bruno Haible.
24159         * config/srclist-update (fixfile): Change grep pattern again, since the
24160         previous fix didn't work (there was another trailing $).  Use
24161         '[$]' to escape the $s.
24162
24163 2003-07-15  Karl Berry  <karl@gnu.org>
24164
24165         * lib/vasnprintf.c: update from gettext.
24166
24167 2003-07-15  Karl Berry  <karl@gnu.org>
24168
24169         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
24170         gets expanded when surrounded by '$'.
24171
24172 2003-07-15  Jim Meyering  <jim@meyering.net>
24173
24174         * modules/save-cwd: Don't depend on error.  From Derek Price.
24175
24176 2003-07-15  Jim Meyering  <jim@meyering.net>
24177
24178         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
24179
24180 2003-07-14  Simon Josefsson  <jas@extundo.com>
24181
24182         * modules/mempcpy: New file.
24183         * MODULES.html.sh (func_all_modules): Add mempcpy.
24184
24185 2003-07-14  Simon Josefsson  <jas@extundo.com>
24186
24187         * m4/mempcpy.m4: New file.
24188
24189 2003-07-14  Simon Josefsson  <jas@extundo.com>
24190
24191         * lib/mempcpy.h: New file.
24192         * lib/mempcpy.c: New file.
24193
24194 2003-07-14  Paul Eggert  <eggert@twinsun.com>
24195
24196         * modules/getdate, modules/posixtm: Depend on mktime.
24197
24198 2003-07-14  Paul Eggert  <eggert@twinsun.com>
24199
24200         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
24201         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
24202         unicodeio.c, unicodeio.h, unlocked-io.h:
24203         Switch from LGPL to GPL.
24204
24205 2003-07-14  Paul Eggert  <eggert@twinsun.com>
24206
24207         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
24208         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
24209         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
24210         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
24211         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
24212         updated automatically by ../config/srclist-update.  This changes
24213         their license from LPGL to GPL.
24214
24215 2003-07-14  Paul Eggert  <eggert@twinsun.com>
24216
24217         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
24218         assumed to refer to the root of the most recent stable gettext version.
24219         * config/srclistvars.sh: Add defaults for eggert.
24220         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
24221         Match "This program" as well as "The program".  This is needed
24222         for gettext.
24223
24224 2003-07-14  Jim Meyering  <jim@meyering.net>
24225
24226         Don't emit diagnostics.  Let callers do that.
24227         * lib/save-cwd.c: Don't include "error.h".
24228         (save_cwd): Don't call error.  Ensure that errno is valid
24229         when returning nonzero.
24230
24231         * lib/save-cwd.h (restore_cwd): Update prototype.
24232         * lib/save-cwd.c (restore_cwd): Remove two parameters.
24233         Simplify.  Don't call error upon failure.  Let callers do that.
24234         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
24235         when auditing is enabled.  But don't bother updating the #if.
24236
24237 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
24238
24239         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
24240         it breaks C++ compilation.
24241         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
24242
24243 2003-07-10  Simon Josefsson  <jas@extundo.com>
24244
24245         * modules/strchrnul (Makefile.am): Add strchrnul.h.
24246
24247 2003-07-10  Jim Meyering  <jim@meyering.net>
24248
24249         * m4/clock_time.m4: Remove trailing blank.
24250         * m4/intmax_t.m4: Likewise.
24251
24252 2003-07-10  Jim Meyering  <jim@meyering.net>
24253
24254         * lib/vasnprintf.c: Remove trailing blanks.
24255         Make cpp indentation consistent.
24256
24257 2003-07-09  Paul Eggert  <eggert@twinsun.com>
24258
24259         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
24260         posixver.c, strftime.c, strnlen.c, strverscmp.c:
24261         Switch from LGPL to GPL.
24262
24263 2003-07-09  Paul Eggert  <eggert@twinsun.com>
24264
24265         * config/srclist.txt: Sort sublists.  Add
24266         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
24267         that differ from gnulib for one reason or another; we'd like this list
24268         to be smaller but for now let's document what we have.
24269
24270 2003-07-08  Paul Eggert  <eggert@twinsun.com>
24271
24272         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
24273         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
24274         and sweeter "eval x=$x".
24275         * config/srclist.txt: Get lib/argp* from glibc.
24276
24277 2003-07-07  Paul Eggert  <eggert@twinsun.com>
24278
24279         * lib/mktime.c: Fix some boundary cases and remove need for floating
24280         point.
24281
24282         Issue a compile-time diagnostic if time_t is floating point, or if
24283         two's complement arithmetic is not in effect, or if arithmetic
24284         right shift does not propagate the sign.  These assumptions were
24285         all in the original code but they weren't checked.
24286
24287         (TIME_T_MIDPOINT, verify): New macros.
24288         (__isleap): Remove; it has integer overflow problems.
24289         (leapyear): New function, without those problems.
24290         (ydhms_tm_diff): Remove; splitting into two parts.
24291         (ydhms_diff): New function, containing the arithmetic part of
24292         the old ydhms_tm_diff function.  Issue a compile-time
24293         diagnostic if we are not using C99 integer division.
24294         Avoid casts when possible.
24295         (guess_time_tm): New function, containing the checking part of
24296         the old ydhms_tm_diff function.  Return the new value, rather than
24297         the difference between it and the old.  Accept a new argument T
24298         so that *T specifies the old value.  Check for overflow in the result.
24299
24300         (__mktime_internal): Use a time_t offset, not a long int offset.
24301         This undoes the 2003-06-04 change, which is no longer needed now
24302         that we have better overflow checking.
24303         (localtime_offset): Likewise.
24304
24305         (__mktime_internal): Avoid harmful overflow on hosts where time_t
24306         and long are 64-bit but int is only 32-bit.
24307         (ydhms_diff): Use long int to store year1 and yday1.
24308         Issue a compile-time diagnostic if long int is not wide enough.
24309
24310         (__mktime_internal): Use long int to store adjusted year and yday.
24311         Use plain C rather than preprocessor commands, if that doesn't
24312         affect efficiency.
24313         Check for overflow (and try to repair) after each probe
24314         rather than checking only at the very end.  This avoids some bugs
24315         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
24316         does not equal GMT offset at maximum time).
24317         Use integer to check for overflow rather than floating point; this
24318         is more portable to non-IEEE hosts, and is a tad faster.
24319         When we detect that we are oscillating between two values,
24320         don't check whether tm_isdst has the requested value, since
24321         we already know the answer.  When tm_isdst has the wrong value,
24322         use a different heuristic to find the right one, based on the
24323         extreme values actually observed in practice in tz2003a,
24324         rather than the (overly optimistic) "previous 3 calendar quarters".
24325
24326         (not_equal_tm, print_tm, check_result): Use "const T" rather than
24327         "T const" to accommodate glibc style.
24328         (check_result): Use less-confusing report format.  "long" -> "long int.
24329         (main): Likewise.
24330         Don't loop if the iteration overflows time_t.
24331         Allow a negative step in the iteration.
24332
24333 2003-07-06  Karl Berry  <karl@gnu.org>
24334
24335         * config/depcomp: update from automake.
24336         * config/config.sub: update from prep.
24337
24338 2003-07-03  Karl Berry  <karl@gnu.org>
24339
24340         * config/config.guess: update from prep.
24341
24342 2003-07-01  Paul Eggert  <eggert@twinsun.com>
24343
24344         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
24345         xreadlink.c now includes it unconditionally.
24346
24347 2003-07-01  Paul Eggert  <eggert@twinsun.com>
24348
24349         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
24350         having it depend on HAVE_SYS_TYPES_H.
24351
24352 2003-07-01  Bruno Haible  <bruno@clisp.org>
24353
24354         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
24355         <sys/types.h> should be sufficient.
24356         Reported by Paul Eggert.
24357
24358 2003-06-26  Karl Berry  <karl@gnu.org>
24359
24360         * config/depcomp: update from automake.
24361
24362 2003-06-26  Bruno Haible  <bruno@clisp.org>
24363
24364         * modules/human: Depend on module stdbool.
24365
24366 2003-06-25  Bruno Haible  <bruno@clisp.org>
24367
24368         * modules/readlink: New file.
24369         * modules/xreadlink: Depend on it.
24370         * MODULES.html.sh (func_all_modules): Add readlink.
24371
24372 2003-06-25  Bruno Haible  <bruno@clisp.org>
24373
24374         * m4/readlink.m4: New file.
24375
24376 2003-06-25  Bruno Haible  <bruno@clisp.org>
24377
24378         * lib/readlink.c: New file.
24379
24380 2003-06-22  Karl Berry  <karl@gnu.org>
24381
24382         * config/srclist.txt: update mkinstalldirs from automake.
24383         * config/mkinstalldirs: update.
24384
24385 2003-06-22  Bruno Haible  <bruno@clisp.org>
24386
24387         Portability to mingw32.
24388         * m4/ssize_t.m4: New file, from GNU gettext.
24389         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
24390         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
24391
24392 2003-06-22  Bruno Haible  <bruno@clisp.org>
24393
24394         * modules/safe-read: Add m4/ssize_t.m4.
24395         * modules/xreadlink: Add m4/ssize_t.m4.
24396
24397 2003-06-20  Bruno Haible  <bruno@clisp.org>
24398
24399         Assume C89, so PARAMS isn't needed.
24400         * lib/unicodeio.h (PARAMS): Remove.
24401         * lib/unicodeio.c: Don't use PARAMS.
24402
24403 2003-06-18  Karl Berry  <karl@gnu.org>
24404
24405         * config/config.{guess,sub}: update from prep.
24406
24407 2003-06-18  Jim Meyering  <jim@meyering.net>
24408
24409         Merge changes from coreutils.
24410         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
24411         Remove explicit declarations of xmalloc and realloc.
24412         Include xalloc.h.
24413         (read_utmp): Remove anachronistic cast of xmalloc.
24414
24415 2003-06-17  Paul Eggert  <eggert@twinsun.com>
24416
24417         Assume C89, so PARAMS isn't needed.
24418         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
24419         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
24420         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
24421         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
24422         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
24423         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
24424         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
24425         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
24426         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
24427         lib/xstrtod.h, lib/xstrtol.h: Likewise.
24428         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
24429         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
24430         no longer needed. Anyway, config.h should always be included before any
24431         other file.
24432
24433 2003-06-11  Simon Josefsson  <jas@extundo.com>
24434
24435         * modules/sysexits: New file.
24436         * MODULES.html.sh (func_all_modules): Add sysexits.
24437
24438 2003-06-11  Simon Josefsson  <jas@extundo.com>
24439
24440         * lib/sysexit_.h: New file.
24441
24442 2003-06-11  Derek Price  <derek@ximbiot.com>
24443
24444         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
24445         necessary.
24446
24447 2003-06-11  Bruno Haible  <bruno@clisp.org>
24448
24449         * m4/sysexits.m4: New file.
24450
24451 2003-06-10  Simon Josefsson  <jas@extundo.com>
24452
24453         * lib/argp.h: New file, from glibc.
24454         * lib/argp-ba.c: New file, from glibc.
24455         * lib/argp-eexst.c: New file, from glibc.
24456         * lib/argp-fmtstream.c: New file, from glibc.
24457         * lib/argp-fmtstream.h: New file, from glibc.
24458         * lib/argp-fs-xinl.c: New file, from glibc.
24459         * lib/argp-help.c: New file, from glibc.
24460         * lib/argp-namefrob.h: New file, from glibc.
24461         * lib/argp-parse.c: New file, from glibc.
24462         * lib/argp-pv.c: New file, from glibc.
24463         * lib/argp-pvh.c: New file, from glibc.
24464         * lib/argp-xinl.c: New file, from glibc.
24465
24466 2003-06-10  Simon Josefsson  <jas@extundo.com>
24467
24468         * modules/strchrnul: New file.
24469
24470 2003-06-10  Simon Josefsson  <jas@extundo.com>
24471
24472         * modules/argp: New file.
24473
24474 2003-06-10  Simon Josefsson  <jas@extundo.com>
24475
24476         * m4/strchrnul.m4: New file.
24477
24478 2003-06-10  Simon Josefsson  <jas@extundo.com>
24479
24480         * lib/strchrnul.h: New file.
24481         * lib/strchrnul.c: New file.
24482
24483 2003-06-10  Bruno Haible  <bruno@clisp.org>
24484
24485         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
24486
24487 2003-06-07  Karl Berry  <karl@gnu.org>
24488
24489         * config/config.{guess,sub}: update from prep.
24490
24491 2003-06-07  Jim Meyering  <jim@meyering.net>
24492
24493         * modules/strtod: Use $(...) notation, not @...@ for
24494         AC_REPLACE'd variables.
24495         * modules/localcharset: Likewise.
24496
24497 2003-06-07  Jim Meyering  <jim@meyering.net>
24498
24499         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
24500         in place of my name in the copyright comment.
24501         Remove definition and uses of __P.
24502
24503         From coreutils.
24504         * lib/stat.c: Don't declare xmalloc explicitly.
24505         Instead, include "xalloc.h".
24506         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
24507         xrealloc, and xcalloc return values.
24508         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
24509         Improve comment.
24510         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
24511
24512 2003-06-07  Bruno Haible  <bruno@clisp.org>
24513
24514         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
24515         avoid AC_CONFIG_LINKS.
24516         * modules/fnmatch (Makefile.am): Use explicit creation rule for
24517         fnmatch.h, to avoid AC_CONFIG_LINKS.
24518         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
24519
24520 2003-06-07  Bruno Haible  <bruno@clisp.org>
24521
24522         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
24523         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
24524         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
24525         directory.
24526         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
24527         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
24528         directory.
24529
24530 2003-06-06  Jim Meyering  <jim@meyering.net>
24531
24532         Merge from coreutils.
24533         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
24534         Consolidate declarations and initializations of *_base* locals.
24535
24536         Merge from coreutils.
24537         This avoids a core dump on systems without GNU putenv,
24538         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
24539         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
24540         (unsetenv): New static function, from GNU libc.
24541         (rpl_putenv): Use it.
24542
24543         * lib/modechange.c: Remove trailing blanks.
24544
24545         Merge from coreutils.
24546         * lib/fsusage.c: Remove declaration of statfs.
24547         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
24548
24549         * lib/posixtm.c: Include <stdbool.h> unconditionally.
24550
24551 2003-06-06  Jim Meyering  <jim@meyering.net>
24552
24553         * lib/stdbool_.h: Renamed from stdbool.h.in.
24554
24555 2003-06-06  Jim Meyering  <jim@meyering.net>
24556             Bruno Haible  <bruno@clisp.org>
24557
24558         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
24559         Adjust Makefile.am snippet not to redirect directly to target.
24560         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
24561
24562 2003-06-05  Paul Eggert  <eggert@twinsun.com>
24563
24564         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
24565         mismatch, look in future quarters as well as past.  This fixes a
24566         bug when processing fall-backwards gaps immediately after a long
24567         period of daylight-saving time.
24568
24569         * lib/mktime.c: Assume freestanding C89 or better.
24570         (HAVE_LIMITS_H): Remove.  Assume it's 1.
24571         (__P): Remove; not used.
24572         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
24573         (mktime, not_equal_tm, print_tm, check_result,
24574         main): Use prototypes.  Use const * where appropriate.
24575         (main): Fix typo in testing code that uncovered by above changes.
24576         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
24577
24578 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24579
24580         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
24581         locale.h, localeconv.  This merges changes from coreutils.
24582
24583         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
24584         It can be removed after the next Autoconf is released.
24585         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
24586         needed.
24587
24588 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24589
24590         * lib/mktime.c: Fix Debian bug 177940
24591         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
24592         (localtime_offset): Now long int, not time_t, because we want it
24593         to be guaranteed to be signed.  All uses changed.
24594         (__mktime_internal): If overflow would occur when adding offset,
24595         don't add it.
24596
24597         Merge 'human' changes from coreutils.  Rewrite to support
24598         locale-specific notations like thousands separators.
24599         * lib/human.c: Simplify authorship notice.
24600         Include human.h immediately after config.h.
24601         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
24602         <limits.h>: Do not include, since human.h does.
24603         (SIZE_MAX, UINTMAX_MAX): New macros.
24604         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
24605         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
24606         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
24607         (power_letter): Renamed from suffixes.
24608         (generate_suffix_backwards): Remove.
24609         (adjust_value): Now takes int style (because of human.h changes)
24610         and long double value (for greater precision on some platforms).
24611         (group_number): New function.
24612         (human_readable): Use it.  Use integer options, not enum.
24613         Put the options before the sizes in the arg list.
24614         Support all the new options.
24615         The old human_readable function has been removed;
24616         use inttostr.h instead.
24617         (human_readable, default_block_size, humblock):
24618         Use uintmax_t, not int, for block sizes.
24619         (human_readable_inexact, block_size_types): Remove.
24620         (block_size_opts): New constant.
24621         (human_options): Renamed from human_block_size, with new signature
24622         that allows block sizes up to UINTMAX_MAX.  All callers changed.
24623         * lib/human.h: Add copyright and authorship notice.
24624         Include <limits.h> and <stdbool.h> unconditionally.
24625         (PARAMS): Remove.  All uses removed.
24626         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
24627         (enum human_inexact_style): Remove tag; now a nameless enum.
24628         (human_floor, human_ceiling, human_round_to_even): Now have
24629         values 2, 0, 1 rather than -1, 1, 0.
24630         (human_group_digits, human_suppress_point_zero, human_autoscale,
24631         human_base_1024, human_SI, human_B): New constants.
24632         (human_readable_inexact, human_block_size): Remove.
24633         (human_readable): Size args are now uintmax_t, not int.
24634         (human_options): New decl.
24635
24636         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
24637         unnecessary now that we assume C89 or better.  This change
24638         imported from coreutils.
24639
24640         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
24641         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
24642         in the 2003-05-30 sync from glibc.
24643
24644         .h files should stand alone, but we shouldn't include <sys/types.h>
24645         if we can get away with just <stddef.h>.
24646
24647         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
24648         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
24649         rather than <sys/types.h>, as we merely need size_t.
24650         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
24651         to get size_t.
24652         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
24653         Include <stdio.h>, to get FILE.
24654         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
24655         memcasecmp.h has included <stddef.h> and all we need is size_t.
24656         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
24657         our interface, instead of including <sys/types.h>
24658
24659 2003-06-04  Paul Eggert  <eggert@twinsun.com>
24660
24661         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
24662         now, as glibc mktime is buggy on non-glibc systems.
24663
24664 2003-06-03  Karl Berry  <karl@gnu.org>
24665
24666         * config/config.sub: update from prep.
24667
24668 2003-06-02  Paul Eggert  <eggert@twinsun.com>
24669
24670         [from coreutils]
24671         Fix some minor time-related bugs with POSIX time arguments.
24672         Some valid time stamps were being rejected (notably -1, and
24673         time stamps before 1900 on 64-bit hosts).  And some invalid
24674         time stamps were being accepted, e.g. September 31.
24675
24676         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
24677         that we can return (time_t) -1 successfully.
24678         * lib/posixtm.c: Likewise.
24679         [HAVE_STDBOOL_H]: Include <stdbool.h>.
24680         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
24681         (t): Remove static var.
24682         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
24683         of static var.  All uses changed.
24684         (year): Do not reject years before 1900; they can occur with
24685         64-bit time_t.
24686         (posix_time_parse): Do not check for out-of-range components;
24687         that is now the caller's responsibility, since our checks were
24688         only approximations.
24689         (posixtime): Use mktime to check for out-of-range components,
24690         since it knows them exactly.
24691         If mktime returns (time_t) -1, check whether an error actually occurred
24692         by invoking localtime on -1.
24693         (main) [TEST_POSIXTIME]: Check for input data errors, and report
24694         posixtime failures better.
24695         Improve the test data (in comments only).
24696
24697 2003-06-02  Karl Berry  <karl@gnu.org>
24698
24699         * config/mkinstalldirs (version): new variable.
24700         (--version): new option.
24701         (usage): improve message.
24702
24703 2003-05-30  Karl Berry  <karl@gnu.org>
24704
24705         * lib/mktime.c: update from libc.
24706
24707 2003-05-30  Bruno Haible  <bruno@clisp.org>
24708
24709         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
24710         * config/config.rpath: Upgrade to gettext-0.12.1.
24711
24712 2003-05-30  Bruno Haible  <bruno@clisp.org>
24713
24714         * m4/gettext.m4: Upgrade to gettext-0.12.1.
24715         * m4/nls.m4: New file, from gettext-0.12.1.
24716         * m4/po.m4: New file, from gettext-0.12.1.
24717         * m4/progtest.m4: Upgrade to gettext-0.12.1.
24718
24719 2003-05-30  Bruno Haible  <bruno@clisp.org>
24720
24721         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
24722         * lib/localcharset.h: Likewise.
24723         * lib/localcharset.c: Likewise.
24724
24725 2003-05-29  Karl Berry  <karl@gnu.org>
24726
24727         * config/config.rpath: update from gettext.
24728
24729 2003-05-28  Paul Eggert  <eggert@twinsun.com>
24730
24731         Assume the headers required for C89 freestanding compilers.
24732         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
24733         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
24734         * m4/human.m4 (gl_HUMAN): Likewise.
24735         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
24736         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
24737         * m4/userspec.m4 (gl_USERSPEC): Likewise.
24738         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
24739         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
24740         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
24741
24742 2003-05-28  Paul Eggert  <eggert@twinsun.com>
24743
24744         Assume the headers required for C89 freestanding compilers.
24745         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
24746         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
24747         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
24748         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
24749         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
24750         define, since <limits.h> is guaranteed to do that.
24751         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
24752         * lib/exclude.c: Include <stdbool.h> unconditionally.
24753         * lib/tempname.c: Include <stddef.h> unconditionally.
24754         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
24755         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
24756         <stddef.h> does that.
24757         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
24758         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
24759         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
24760         needed.
24761         * lib/xstrtol.c: Likewise.
24762         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
24763         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
24764
24765         * lib/addext.c (addext): Use assignment rather than cast, to avoid
24766         warnings on some platforms.
24767
24768         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
24769         arbitrarily.
24770
24771 2003-05-26  Jim Meyering  <jim@meyering.net>
24772
24773         Merge in a change from coreutils:
24774         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
24775         that is guaranteed to be `no'.  Use `no_such_member' to indicate
24776         that condition, rather than `-1' which is slightly misleading.
24777         Change the name of the cache variable to have the gl_ prefix.
24778         Prompted by a patch from Richard Dawe for DJGPP.
24779
24780 2003-05-24  Karl Berry  <karl@gnu.org>
24781
24782         * config/config.guess: update from prep.
24783
24784 2003-05-22  Karl Berry  <karl@gnu.org>
24785
24786         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
24787
24788 2003-05-20  Karl Berry  <karl@gnu.org>
24789
24790         * config/config.guess: update from prep.
24791
24792 2003-05-18  Karl Berry  <karl@gnu.org>
24793
24794         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
24795         might actually be set by the user.
24796
24797         * config/depcomp, install-sh, mdate-sh: update from automake.
24798
24799 2003-05-17  Bruno Haible  <bruno@clisp.org>
24800
24801         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
24802         invalid expansion for AC_EGREP_CPP.
24803         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
24804         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
24805         Suggested by Akim Demaille <akim@epita.fr> in
24806         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
24807
24808 2003-05-12  Jim Meyering  <jim@meyering.net>
24809
24810         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
24811         the space-padded-by-default conversion specifiers, %e, %k, %l.
24812
24813 2003-05-12  Bruno Haible  <bruno@clisp.org>
24814
24815         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
24816         the string is longer than 4 KB.
24817
24818 2003-05-11  Karl Berry  <karl@gnu.org>
24819
24820         * config/config.{guess,sub}: update from prep.
24821
24822 2003-05-09  Bruno Haible  <bruno@clisp.org>
24823
24824         * modules/error: Add m4/strerror_r.m4 to file list.
24825
24826 2003-05-03  Bruno Haible  <bruno@clisp.org>
24827
24828         Upgrade to Unicode-4.0.
24829         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
24830         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
24831         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
24832         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
24833         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
24834         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
24835         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
24836         Change width of U+E0100..U+E01EF from 1 to 0.
24837
24838 2003-04-25  Jim Meyering  <jim@meyering.net>
24839
24840         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
24841         of type size_t, not int.
24842
24843 2003-04-25  Bruno Haible  <bruno@clisp.org>
24844
24845         * lib/copy-file.c: Include <stddef.h>, for size_t.
24846
24847 2003-04-21  Paul Eggert  <eggert@twinsun.com>
24848
24849         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
24850         code which expansion is under static control.  Patch imported from
24851         Akim Demaille's patch to Bison; see
24852         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
24853
24854 2003-04-14  Bruno Haible  <bruno@clisp.org>
24855
24856         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
24857
24858 2003-04-11  Jim Meyering  <jim@meyering.net>
24859
24860         Merge changes from Coreutils.
24861
24862         2003-03-22  Jim Meyering  <jim@meyering.net>
24863
24864         * lib/strftime.c (widen): Cast alloca return value to proper type.
24865
24866         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
24867
24868         From GNU libc.
24869         * lib/strftime.c (my_strftime): Handle very large width
24870         specifications for numeric values correctly.  Improve checks for
24871         overflow.
24872
24873         2003-01-19  Jim Meyering  <jim@meyering.net>
24874
24875         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
24876         definitions.
24877         (nl_get_alt_digit) [! defined my_strftime]: Define.
24878         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
24879         _nl_get_alt_digit and _nl_get_walt_digit.
24880
24881         * lib/strftime.c (my_strftime): Merge in locale-related changes from
24882         libc. These changes have no effect outside of _LIBC.
24883
24884 2003-04-10  Bruno Haible  <bruno@clisp.org>
24885
24886         * modules/findprog: New file.
24887         * MODULES.html.sh (func_all_modules): Add it.
24888
24889 2003-04-10  Bruno Haible  <bruno@clisp.org>
24890
24891         * m4/findprog.m4: New file.
24892         * m4/eaccess.m4: New file.
24893
24894 2003-04-10  Bruno Haible  <bruno@clisp.org>
24895
24896         * lib/findprog.h: New file, from GNU gettext.
24897         * lib/findprog.c: New file, from GNU gettext.
24898
24899 2003-04-05  Jim Meyering  <jim@meyering.net>
24900
24901         Merge changes from Coreutils.
24902
24903         * lib/exclude.h (PARAMS): Remove definition and uses.
24904         * lib/exclude.c: Remove uses of `PARAMS'.
24905
24906         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
24907         Add test-cases for DOS filenames. Declare program_name.
24908         (main): Set up program_name.  Patch by Rich Dawe.
24909
24910         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
24911         error from mntctl.
24912         Use mntctl's return value to drive the entry-processing loop, since
24913         we can't rely on the value of the vmt_length member in the last
24914         entry.  On some systems doing so could result in exhausting
24915         virtual memory.  Based in part on a patch from Mike Jetzer.
24916
24917 2003-04-04  Bruno Haible  <bruno@clisp.org>
24918
24919         * modules/linebreak: New file.
24920         * MODULES.html.sh (func_all_modules): Add it.
24921
24922 2003-04-04  Bruno Haible  <bruno@clisp.org>
24923
24924         * m4/linebreak.m4: New file.
24925
24926 2003-04-04  Bruno Haible  <bruno@clisp.org>
24927
24928         * lib/linebreak.h: New file, from GNU gettext.
24929         * lib/linebreak.c: New file, from GNU gettext with slight
24930         modifications.
24931         * lib/lbrkprop.h: New file, from GNU gettext.
24932
24933 2003-04-03  Bruno Haible  <bruno@clisp.org>
24934
24935         * modules/utf8-ucs4: New file.
24936         * modules/utf16-ucs4: New file.
24937         * modules/ucs4-utf8: New file.
24938         * modules/ucs4-utf16: New file.
24939         * MODULES.html.sh (func_all_modules): Add them.
24940
24941 2003-04-03  Bruno Haible  <bruno@clisp.org>
24942
24943         * m4/utf-ucs4.m4: New file.
24944         * m4/ucs4-utf.m4: New file.
24945
24946 2003-04-03  Bruno Haible  <bruno@clisp.org>
24947
24948         * lib/utf8-ucs4.h: New file, from GNU gettext.
24949         * lib/utf16-ucs4.h: New file, from GNU gettext.
24950         * lib/ucs4-utf8.h: New file, from GNU gettext.
24951         * lib/ucs4-utf16.h: New file, from GNU gettext.
24952
24953 2003-04-02  Bruno Haible  <bruno@clisp.org>
24954
24955         * modules/binary-io: New file.
24956         * MODULES.html.sh (func_all_modules): Add it.
24957
24958 2003-04-02  Bruno Haible  <bruno@clisp.org>
24959
24960         * lib/binary-io.h: New file, from GNU gettext.
24961
24962 2003-04-01  Bruno Haible  <bruno@clisp.org>
24963
24964         * modules/pathname: New file.
24965         * MODULES.html.sh (func_all_modules): Add it.
24966
24967 2003-04-01  Bruno Haible  <bruno@clisp.org>
24968
24969         * lib/pathname.h: New file, from GNU gettext.
24970         * lib/concatpath.c: New file, from GNU gettext.
24971
24972 2003-03-30  Bruno Haible  <bruno@clisp.org>
24973
24974         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
24975
24976 2003-03-30  Bruno Haible  <bruno@clisp.org>
24977
24978         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
24979         function chown() doesn't exist.
24980
24981 2003-03-28  Bruno Haible  <bruno@clisp.org>
24982
24983         * modules/copy-file: New file.
24984         * MODULES.html.sh (func_all_modules): Add it.
24985
24986 2003-03-28  Bruno Haible  <bruno@clisp.org>
24987
24988         * m4/copy-file.m4: New file.
24989
24990 2003-03-28  Bruno Haible  <bruno@clisp.org>
24991
24992         * lib/copy-file.h: New file, from GNU gettext.
24993         * lib/copy-file.c: New file, from GNU gettext.
24994
24995 2003-03-18  Jim Meyering  <jim@meyering.net>
24996
24997         * lib/quote.c (quote_n): Fix typo in comment.
24998
24999 2003-03-18  Bruno Haible  <bruno@clisp.org>
25000
25001         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
25002         checking.
25003         * m4/onceonly_2_57.m4: Likewise.
25004
25005 2003-03-17  Bruno Haible  <bruno@clisp.org>
25006
25007         * m4/onceonly.m4: Require autoconf 2.54 or newer.
25008         (m4_quote): Remove macro.
25009         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
25010
25011 2003-03-14  Jim Meyering  <jim@meyering.net>
25012
25013         Merge changes from Coreutils.
25014         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
25015         to be const, in order to avoid warnings.
25016         (obstack_room): Likewise.
25017         (obstack_empty_p): Likewise.
25018
25019 2003-03-14  Bruno Haible  <bruno@clisp.org>
25020
25021         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
25022         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
25023
25024 2003-03-13  Paul Eggert  <eggert@twinsun.com>
25025
25026         Merge changes from Bison.
25027         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
25028         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
25029         when compiling Bison 1.875's `bitset bset = obstack_alloc
25030         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
25031         * lib/hash.c: Include <stdbool.h> unconditionally.
25032
25033 2003-03-13  Paul Eggert  <eggert@twinsun.com>
25034
25035         * m4/onceonly.m4 (m4_quote): New macro.
25036         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
25037         Quote AC_FOREACH variable-expansions properly.
25038
25039 2003-03-13  Paul Eggert  <eggert@twinsun.com>
25040
25041         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
25042
25043 2003-03-09  Paul Eggert  <eggert@twinsun.com>
25044
25045         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
25046         Reported by Bruce Becker; see:
25047         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
25048
25049 2003-03-03  Paul Eggert  <eggert@twinsun.com>
25050             Bruno Haible  <bruno@clisp.org>
25051
25052         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
25053         Reported by John Hughes, see
25054         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
25055
25056 2003-02-20  Bruno Haible  <bruno@clisp.org>
25057
25058         * MODULES.html.sh (func_all_modules): Add poll.
25059
25060 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
25061
25062         * modules/poll: New file.
25063
25064 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
25065
25066         * lib/poll_.h: New file.
25067         * lib/poll.c: New file.
25068
25069 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
25070
25071         * m4/poll.m4: New file.
25072
25073 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
25074
25075         * modules/mathl: New file.
25076
25077 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
25078
25079         * lib/mathl.h: New file.
25080         * lib/acosl.c: New file.
25081         * lib/asinl.c: New file.
25082         * lib/atanl.c: New file.
25083         * lib/ceill.c: New file.
25084         * lib/cosl.c: New file.
25085         * lib/expl.c: New file.
25086         * lib/floorl.c: New file.
25087         * lib/frexpl.c: New file.
25088         * lib/ldexpl.c: New file.
25089         * lib/logl.c: New file.
25090         * lib/sincosl.c: New file.
25091         * lib/sinl.c: New file.
25092         * lib/sqrtl.c: New file.
25093         * lib/tanl.c: New file.
25094         * lib/trigl.c: New file.
25095         * lib/trigl.h: New file.
25096
25097 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
25098
25099         * m4/mathl.m4: New file.
25100
25101 2003-02-18  Bruno Haible  <bruno@clisp.org>
25102
25103         * MODULES.html.sh (func_all_modules): Add mathl.
25104
25105 2003-02-17  Bruno Haible  <bruno@clisp.org>
25106
25107         * modules/mkdtemp: New module.
25108         * MODULES.html.sh (func_all_modules): Add it.
25109
25110 2003-02-17  Bruno Haible  <bruno@clisp.org>
25111
25112         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
25113
25114 2003-02-17  Bruno Haible  <bruno@clisp.org>
25115
25116         * lib/mkdtemp.h: New file, from GNU gettext.
25117         * lib/mkdtemp.c: New file, from GNU gettext.
25118
25119 2003-02-02  Jim Meyering  <jim@meyering.net>
25120
25121         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
25122         e.g. glibc-2.2.93.
25123
25124 2003-01-31  Bruno Haible  <bruno@clisp.org>
25125
25126         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
25127         'rpl_rename'.
25128         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
25129         'rpl_strnlen'.
25130         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
25131         'rpl_strtod'.
25132         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
25133         'rpl_utime'.
25134
25135 2003-01-31  Bruno Haible  <bruno@clisp.org>
25136
25137         * lib/rename.c: #undef rename before defining rpl_rename.
25138         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
25139
25140 2003-01-30  Bruno Haible  <bruno@clisp.org>
25141
25142         * modules/vasnprintf, modules/vasprintf: New modules.
25143         * MODULES.html.sh (func_all_modules): Add them.
25144
25145 2003-01-30  Bruno Haible  <bruno@clisp.org>
25146
25147         * m4/signed.m4: New file, from GNU gettext.
25148         * m4/longdouble.m4: New file, from GNU gettext.
25149         * m4/wchar_t.m4: New file, from GNU gettext.
25150         * m4/wint_t.m4: New file, from GNU gettext.
25151         * m4/vasnprintf.m4: New file.
25152         * m4/vasprintf.m4: New file.
25153
25154 2003-01-30  Bruno Haible  <bruno@clisp.org>
25155
25156         * lib/printf-args.h: New file, from GNU gettext.
25157         * lib/printf-args.c: New file, from GNU gettext.
25158         * lib/printf-parse.h: New file, from GNU gettext.
25159         * lib/printf-parse.c: New file, from GNU gettext.
25160         * lib/vasnprintf.h: New file, from GNU gettext.
25161         * lib/vasnprintf.c: New file, from GNU gettext.
25162         * lib/asnprintf.c: New file, from GNU gettext.
25163         * lib/vasprintf.h: New file, from GNU gettext with modifications.
25164         * lib/vasprintf.c: New file, from GNU gettext.
25165         * lib/asprintf.c: New file, from GNU gettext.
25166
25167 2003-01-29  Bruno Haible  <bruno@clisp.org>
25168
25169         * modules/stpncpy: New module.
25170         * MODULES.html.sh (func_all_modules): Add it.
25171
25172 2003-01-29  Bruno Haible  <bruno@clisp.org>
25173
25174         * m4/stpncpy.m4: New file.
25175
25176 2003-01-29  Bruno Haible  <bruno@clisp.org>
25177
25178         * lib/stpncpy.h: New file, from GNU gettext with modifications.
25179         * lib/stpncpy.c: New file, from GNU gettext with modifications.
25180
25181 2003-01-28  Bruno Haible  <bruno@clisp.org>
25182
25183         * modules/c-ctype: New module.
25184         * MODULES.html.sh (func_all_modules): Add it.
25185
25186 2003-01-28  Bruno Haible  <bruno@clisp.org>
25187
25188         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
25189         Paul Eggert.
25190         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
25191         Paul Eggert.
25192
25193 2003-01-27  Bruno Haible  <bruno@clisp.org>
25194
25195         * modules/xsetenv: New module.
25196         * MODULES.html.sh (func_all_modules): Add it.
25197
25198 2003-01-27  Bruno Haible  <bruno@clisp.org>
25199
25200         * lib/xsetenv.h: New file, from GNU gettext.
25201         * lib/xsetenv.c: New file, from GNU gettext.
25202
25203 2003-01-23  Jim Meyering  <jim@meyering.net>
25204
25205         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
25206         from working on systems without dirfd (at least Irix and OSF1/Tru64).
25207
25208 2003-01-23  Bruno Haible  <bruno@clisp.org>
25209
25210         * modules/minmax: New module.
25211         * MODULES.html.sh (func_all_modules): Add it.
25212
25213 2003-01-23  Bruno Haible  <bruno@clisp.org>
25214
25215         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
25216         Eggert.
25217
25218 2003-01-22  Bruno Haible  <bruno@clisp.org>
25219
25220         * modules/exit: New module.
25221         * MODULES.html.sh (func_all_modules): Add it.
25222
25223 2003-01-22  Bruno Haible  <bruno@clisp.org>
25224
25225         * lib/exit.h: New file, from GNU gettext.
25226
25227 2003-01-19  Bruno Haible  <bruno@clisp.org>
25228
25229         * gnulib-tool: Recognize option --extract-maintainer.
25230         (func_get_maintainer): New function.
25231         * modules/*: Add Maintainer entry.
25232
25233 2003-01-16  Jim Meyering  <jim@meyering.net>
25234
25235         * m4/regex.m4: The `regex' struct is both input and output.
25236         Initialize it before each use.  Patch by Tim Waugh.
25237
25238 2003-01-16  Bruno Haible  <bruno@clisp.org>
25239
25240         * MODULES.html.sh: Add a table of contents. Add the module name as
25241         leftmost column. Add hyperlinks.
25242
25243 2003-01-15  Bruno Haible  <bruno@clisp.org>
25244
25245         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
25246
25247 2003-01-15  Bruno Haible  <bruno@clisp.org>
25248
25249         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
25250         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
25251         suffix.
25252
25253 2003-01-15  Bruno Haible  <bruno@clisp.org>
25254
25255         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
25256
25257 2003-01-15  Bruno Haible  <bruno@clisp.org>
25258
25259         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
25260         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
25261
25262 2003-01-14  Jim Meyering  <jim@meyering.net>
25263
25264         * lib/same.c (same_name): Tweak a comment.
25265
25266 2003-01-14  Bruno Haible  <bruno@clisp.org>
25267
25268         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
25269         when a string comparison is sufficient.
25270
25271 2003-01-14  Bruno Haible  <bruno@clisp.org>
25272
25273         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
25274         'unsigned int'.
25275
25276 2003-01-14  Bruno Haible  <bruno@clisp.org>
25277
25278         * lib/hash-pjw.c: Add comment about low quality of this function.
25279
25280 2003-01-13  Bruno Haible  <bruno@clisp.org>
25281
25282         * modules/stpcpy: Distribute lib/stpcpy.h.
25283         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
25284
25285 2003-01-13  Bruno Haible  <bruno@clisp.org>
25286
25287         * modules/*: Add a description.
25288         * modules/strpbrk: Fix Makefile.am snippet.
25289         * modules/strtoimax: Fix dependencies.
25290         * modules/strtoumax: Likewise.
25291
25292 2003-01-13  Bruno Haible  <bruno@clisp.org>
25293
25294         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
25295         * modules/alloca (Makefile.am): All object files depend on alloca.h.
25296         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
25297
25298 2003-01-13  Bruno Haible  <bruno@clisp.org>
25299
25300         * gnulib-tool (func_create_testdir): Store config/* files in the main
25301         directory.
25302         * config.rpath: Move to ...
25303         * config/config.rpath: ... here.
25304         * modules/gettext: Contains config/config.rpath, not config.rpath.
25305         * modules/iconv: Likewise.
25306
25307 2003-01-12  Paul Eggert  <eggert@twinsun.com>
25308
25309         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
25310         to avoid collisions with libcurses and libreadline.
25311
25312         * m4/getstr.m4: Remove.
25313         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
25314
25315 2003-01-12  Paul Eggert  <eggert@twinsun.com>
25316
25317         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
25318         to avoid collisions with libcurses and libreadline.
25319
25320         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
25321         * lib/getstr.h, getstr.c: Remove.
25322         * lib/getline.c: Include "getline.h", to check interface.
25323         Move body of old getstr.c here: this defines MIN_CHUNK and
25324         declares getdelim2, which is renamed from getstr.
25325         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
25326
25327         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
25328         All uses changed.
25329         * lib/linebuffer.h: Likewise.
25330         (readline): Remove backward-compatibility macro.
25331
25332 2003-01-12  Paul Eggert  <eggert@twinsun.com>
25333
25334         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
25335         to avoid collisions with libcurses and libreadline.
25336         * getstr: Remove.
25337         * MODULES.html.sh: Remove getstr.
25338         * modules/getline: Depend on unlocked-io, not getstr.
25339
25340 2003-01-12  Jim Meyering  <jim@meyering.net>
25341
25342         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
25343
25344 2003-01-10  Bruno Haible  <bruno@clisp.org>
25345
25346         * modules/alloca: Change Makefile.am requirements. Simplify Include
25347         requirements. Add lib/alloca_.h to file list.
25348
25349 2003-01-10  Bruno Haible  <bruno@clisp.org>
25350
25351         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
25352
25353 2003-01-10  Bruno Haible  <bruno@clisp.org>
25354
25355         * lib/alloca_.h: New file.
25356         * lib/getdate.y: Unconditionally include alloca.h.
25357         * lib/makepath.c: Likewise.
25358         * lib/setenv.c: Likewise.
25359         * lib/userspec.c: Likewise.
25360
25361 2003-01-09  Karl Berry  <karl@gnu.org>
25362
25363         * MODULES.html.sh: include `dirname $0` in PATH, to find
25364         gnulib-tool.
25365
25366 2003-01-09  Bruno Haible  <bruno@clisp.org>
25367
25368         * modules/stdbool: Change configure.ac, Makefile.am requirements.
25369         Simplify Include requirements. Add lib/stdbool.h.in to file list.
25370
25371 2003-01-09  Bruno Haible  <bruno@clisp.org>
25372
25373         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
25374
25375 2003-01-09  Bruno Haible  <bruno@clisp.org>
25376
25377         * lib/stdbool.h.in: New file.
25378
25379 2003-01-09  Bruno Haible  <bruno@clisp.org>
25380
25381         * gnulib-tool (func_all_modules): Ignore files ending in ~.
25382         * MODULES.html.sh: Likewise.
25383
25384 2003-01-08  Jim Meyering  <jim@meyering.net>
25385
25386         * lib/full-write.c: Undefine and define-away `const' after inclusion
25387         of errno.h, not before.  Suggestion from Bruno Haible.
25388
25389 2003-01-08  Bruno Haible  <bruno@clisp.org>
25390
25391         * modules/full-read: Depend on full-write.
25392
25393 2003-01-08  Bruno Haible  <bruno@clisp.org>
25394
25395         * lib/safe-read.c: Include specification header first, to ensure its
25396         selfcontainedness.
25397         * lib/full-write.c: Likewise.
25398
25399 2003-01-07  Jim Meyering  <jim@meyering.net>
25400
25401         * lib/full-write.c: Rework so that it may serve to define full_read,
25402         too.
25403         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
25404
25405 2003-01-07  Bruno Haible  <bruno@clisp.org>
25406
25407         * lib/strtoimax.c: Include <stdint.h> as an alternative to
25408         <inttypes.h>.
25409         * lib/xstrtol.h: Likewise.
25410         * lib/xstrtoimax.c: Likewise.
25411         * lib/xstrtoumax.c: Likewise.
25412         * lib/human.h: Likewise.
25413
25414         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
25415         on systems that have <inttypes.h> but not <stdint.h>.
25416
25417 2003-01-07  Bruno Haible  <bruno@clisp.org>
25418
25419         * MODULES.html.sh: Add copyright notice.
25420         (missed_files): Omit CVS directory entries.
25421         (func_module): Make it work with sed-3.02.
25422         * MODULES.txt: Remove file.
25423
25424 2003-01-06  Jim Meyering  <jim@meyering.net>
25425
25426         * lib/version-etc.c: Update year in translatable copyright string.
25427
25428 2003-01-03  Karl Berry  <karl@gnu.org>
25429
25430         * config/config.{guess,sub}: update from prep.
25431
25432 2003-01-02  Karl Berry  <karl@gnu.org>
25433
25434         * doc/COPYING.DOC: belatedly updated to 1.2.
25435
25436 2003-01-01  Karl Berry  <karl@gnu.org>
25437
25438         * gnulib-tool (func_verify_module): report module name $module in
25439         error message, not $1.
25440         * gnulib-tool (create-testdir): don't complain if destdir couldn't
25441         be created, only if it doesn't exist.
25442         * gnulib-tool (last_checkin_date): don't expand the $Date here.
25443
25444 2002-12-31  Paul Eggert  <eggert@twinsun.com>
25445
25446         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
25447
25448 2002-12-31  Paul Eggert  <eggert@twinsun.com>
25449
25450         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
25451         memcmp if strcoll doesn't work.
25452
25453 2002-12-31  Bruno Haible  <bruno@clisp.org>
25454
25455         * lib/utime.c (utime_null): No need to call ftruncate if the file was
25456         nonempty.
25457
25458 2002-12-31  Bruno Haible  <bruno@clisp.org>
25459
25460         * lib/memcoll.c (STRCOLL): New macro.
25461         (memcoll): Use it.
25462
25463 2002-12-31  Bruno Haible  <bruno@clisp.org>
25464
25465         * lib/localcharset.h: New file.
25466         * lib/localcharset.c: Include it.
25467         * lib/unicodeio.c: Likewise.
25468
25469 2002-12-31  Bruno Haible  <bruno@clisp.org>
25470
25471         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
25472         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
25473
25474 2002-12-31  Bruno Haible  <bruno@clisp.org>
25475
25476         * lib/getline.h: Include <stddef.h>, for size_t.
25477
25478         * lib/unicodeio.h: Include <stddef.h>, for size_t.
25479         * lib/unicodeio.c: Don't include <stddef.h>.
25480
25481 2002-12-31  Bruno Haible  <bruno@clisp.org>
25482
25483         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
25484         HAVE_TM_ZONE.
25485
25486 2002-12-24  Karl Berry  <karl@gnu.org>
25487
25488         * config/config.guess: update from prep.
25489
25490 2002-12-24  Bruno Haible  <bruno@clisp.org>
25491
25492         General infrasructure.
25493         * m4/README: Rewritten.
25494         * m4/onceonly.m4: New file.
25495         * m4/onceonly_2_57.m4: New file.
25496
25497         Module atexit.
25498         * m4/atexit.m4: New file.
25499
25500         Module strtod.
25501         * m4/strtod.m4: New file.
25502
25503         Module strtol.
25504         * m4/strtol.m4: New file.
25505
25506         Module strtoul.
25507         * m4/strtoul.m4: New file.
25508
25509         Module memchr.
25510         * m4/memchr.m4: New file.
25511
25512         Module memcmp.
25513         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
25514         (jm_FUNC_MEMCMP): Invoke it.
25515
25516         Module memcpy.
25517         * m4/memcpy.m4: New file.
25518
25519         Module memmove.
25520         * m4/memmove.m4: New file.
25521
25522         Module memset.
25523         * m4/memset.m4: New file.
25524
25525         Module strcspn.
25526         * m4/strcspn.m4: New file.
25527
25528         Module strpbrk.
25529         * m4/strpbrk.m4: New file.
25530
25531         Module strstr.
25532         * m4/strstr.m4: New file.
25533
25534         Module strerror.
25535         * m4/strerror.m4: New file.
25536
25537         Module mktime.
25538         * m4/mktime.m4: Renamed from jm-mktime.m4.
25539         (gl_PREREQ_MKTIME): New macro.
25540         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
25541
25542         Module malloc.
25543         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
25544         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
25545         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
25546
25547         Module realloc.
25548         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
25549         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
25550         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
25551
25552         Module strftime.
25553         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
25554         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
25555         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
25556         gl_TM_GMTOFF.
25557         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
25558
25559         Module xalloc.
25560         * m4/xalloc.m4: New file.
25561
25562         Module alloca.
25563         * m4/alloca.m4: New file.
25564
25565         Module putenv.
25566         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
25567         (jm_FUNC_PUTENV): Invoke it.
25568
25569         Module setenv.
25570         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
25571         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
25572         when invoked twice.
25573         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
25574         gt_FUNC_SETENV.
25575
25576         Module memrchr.
25577         * m4/memrchr.m4: New file.
25578
25579         Module stpcpy.
25580         * m4/stpcpy.m4: New file.
25581
25582         Module strcase.
25583         * m4/strcase.m4: New file.
25584
25585         Module strdup.
25586         * m4/strdup.m4: New file.
25587
25588         Module strnlen.
25589         * m4/strnlen.m4: New file.
25590
25591         Module strndup.
25592         * m4/strndup.m4: New file.
25593
25594         Module xstrtod.
25595         * m4/xstrtod.m4: New file.
25596
25597         Module xstrtol.
25598         * m4/xstrtol.m4: New file.
25599
25600         Module getdate.
25601         * m4/getdate.m4: New file.
25602
25603         Module unlocked-io.
25604         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
25605         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
25606         * m4/jm-glibc-io.m4n: Remove file.
25607
25608         Module long-options.
25609         * m4/long-options.m4: New file.
25610
25611         Module md5.
25612         * m4/md5.m4: New file.
25613
25614         Module sha.
25615         * m4/sha.m4: New file.
25616
25617         Module getstr.
25618         * m4/getstr.m4: New file.
25619
25620         Module getline.
25621         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
25622         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
25623         <sys/types.h>, for size_t. Use the function name gnu_getline, not
25624         simply getline. Infoke gl_PREREQ_GETLINE.
25625
25626         Module obstack.
25627         * m4/obstack.m4: New file.
25628
25629         Module hash.
25630         * m4/hash.m4: New file.
25631
25632         Module readtokens.
25633         * m4/readtokens.m4: New file.
25634
25635         Module strverscmp.
25636         * m4/strverscmp.m4: New file.
25637
25638         Module stdbool.
25639         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
25640         OSF/1.
25641
25642         Module strtoll.
25643         * m4/strtoll.m4: New file.
25644
25645         Module strtoull.
25646         * m4/strtoull.m4: New file.
25647
25648         Module strtoimax.
25649         * m4/strtoimax.m4: New file.
25650
25651         Module strtoumax.
25652         * m4/strtoumax.m4: New file.
25653
25654         Module xstrtoimax.
25655         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
25656         jm_AC_PREREQ_XSTRTOIMAX.
25657         Moved the strtol prerequisites to strtol.m4.
25658         Moved the strtoll prerequisites to strtoll.m4.
25659         Moved the strtoimax prerequisites to strtoimax.m4.
25660
25661         Module xstrtoumax.
25662         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
25663         jm_AC_PREREQ_XSTRTOUMAX.
25664         Moved the strtoul prerequisites to strtoul.m4.
25665         Moved the strtoull prerequisites to strtoull.m4.
25666         Moved the strtoumax prerequisites to strtoumax.m4.
25667
25668         Module chown.
25669         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
25670         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
25671
25672         Module dup2.
25673         * m4/dup2.m4: New file.
25674
25675         Module ftruncate.
25676         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
25677         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
25678
25679         Module getgroups.
25680         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
25681         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
25682
25683         Module gettimeofday.
25684         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
25685         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
25686         gl_PREREQ_GETTIMEOFDAY.
25687
25688         Module mkdir.
25689         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
25690         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
25691
25692         Module mkstemp.
25693         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
25694         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
25695         jm_AC_TYPE_UINTMAX_T.
25696         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
25697
25698         Module stat.
25699         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
25700         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
25701
25702         Module lstat.
25703         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
25704         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
25705
25706         Module timespec.
25707         * m4/timespec.m4 (gl_TIMESPEC): New macro.
25708         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
25709         * m4/st_mtim.m4: Indentation.
25710
25711         Module nanosleep.
25712         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
25713         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
25714         gl_PREREQ_NANOSLEEP.
25715
25716         Module regex.
25717         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
25718         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
25719         (gl_REGEX): New macro.
25720
25721         Module rename.
25722         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
25723         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
25724
25725         Module rmdir.
25726         * m4/rmdir.m4: New file.
25727
25728         Module utime.
25729         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
25730         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
25731         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
25732
25733         Module dirname.
25734         * m4/dirname.m4: New file.
25735
25736         Module getopt.
25737         * m4/getopt.m4: New file.
25738
25739         Module unistd-safer.
25740         * m4/unistd-safer.m4: New file.
25741
25742         Module fnmatch.
25743         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
25744         declaration.
25745         (gl_PREREQ_FNMATCH_EXTRA): New macro.
25746         (gl_FUNC_FNMATCH_POSIX): New macro.
25747         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
25748         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
25749         simply fnmatch.
25750
25751         Module exclude.
25752         * m4/exclude.m4: New file.
25753
25754         Module human.
25755         * m4/human.m4: New file.
25756
25757         Module acl.
25758         * m4/acl.m4: Nop.
25759
25760         Module backupfile.
25761         * m4/backupfile.m4: New file.
25762         * m4/d-ino.m4: Indentation.
25763
25764         Module fsusage.
25765         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
25766         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
25767         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
25768
25769         Module dirfd.
25770         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
25771         requirements.
25772
25773         Module euidaccess.
25774         * m4/euidaccess.m4: New file.
25775
25776         Module file-type.
25777         * m4/file-type.m4: New file.
25778
25779         Module fileblocks.
25780         * m4/fileblocks.m4: New file.
25781
25782         Module filemode.
25783         * m4/filemode.m4: New file.
25784
25785         Module isdir.
25786         * m4/isdir.m4: New file.
25787
25788         Module lchown.
25789         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
25790         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
25791
25792         Module makepath.
25793         * m4/makepath.m4: New file.
25794
25795         Module modechange.
25796         * m4/modechange.m4: New file.
25797
25798         Module mountlist.
25799         * m4/mountlist.m4: New file.
25800         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
25801         Indentation.
25802
25803         Module path-concat.
25804         * m4/path-concat.m4: New file.
25805
25806         Module pathmax.
25807         * m4/pathmax.m4: New file.
25808
25809         Module same.
25810         * m4/same.m4: New file.
25811
25812         Module save-cwd.
25813         * m4/save-cwd.m4: New file.
25814
25815         Module savedir.
25816         * m4/savedir.m4: New file.
25817
25818         Module xgetcwd.
25819         * m4/xgetcwd.m4: New file.
25820         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
25821
25822         Module xreadlink.
25823         * m4/xreadlink.m4: New file.
25824
25825         Module safe-read.
25826         * m4/safe-read.m4: New file.
25827
25828         Module safe-write.
25829         * m4/safe-write.m4: New file.
25830
25831         Module closeout.
25832         * m4/closeout.m4: New file.
25833
25834         Module stdio-safer.
25835         * m4/stdio-safer.m4: New file.
25836
25837         Module getpass.
25838         * m4/getpass.m4: New file.
25839
25840         Module getugroups.
25841         * m4/getugroups.m4: New file.
25842
25843         Module group-member.
25844         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
25845         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
25846
25847         Module idcache.
25848         * m4/idcache.m4: New file.
25849
25850         Module userspec.
25851         * m4/userspec.m4: New file.
25852
25853         Module gettime.
25854         * m4/clock_time.m4: New file.
25855         * m4/gettime.m4: New file.
25856
25857         Module settime.
25858         * m4/settime.m4: New file.
25859
25860         Module posixtm.
25861         * m4/posixtm.m4: New file.
25862
25863         Module gethostname.
25864         * m4/gethostname.m4: New file.
25865
25866         Module canon-host.
25867         * m4/canon-host.m4: New file.
25868
25869         Module gettext.
25870         * m4/codeset.m4: New file, from gettext-0.11.5.
25871         * m4/gettext.m4: New file, from gettext-0.11.5.
25872         * m4/glibc21.m4: New file, from gettext-0.11.5.
25873         * m4/iconv.m4: New file, from gettext-0.11.5.
25874         * m4/intdiv0.m4: New file, from gettext-0.11.5.
25875         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
25876         * m4/inttypes.m4: New file, from gettext-0.11.5.
25877         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
25878         * m4/isc-posix.m4: New file, from gettext-0.11.5.
25879         * m4/lcmessage.m4: New file, from gettext-0.11.5.
25880         * m4/lib-ld.m4: New file, from gettext-0.11.5.
25881         * m4/lib-link.m4: New file, from gettext-0.11.5.
25882         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
25883         * m4/progtest.m4: New file, from gettext-0.11.5.
25884         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
25885         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
25886         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
25887
25888         Module localcharset.
25889         * m4/localcharset.m4: New file.
25890
25891         Module hard-locale.
25892         * m4/hard-locale.m4: New file.
25893
25894         Module mbswidth.
25895         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
25896         onceonly macros.
25897         * m4/mbrtowc.m4: Add comment.
25898
25899         Module memcasecmp.
25900         * m4/memcasecmp.m4: New file.
25901
25902         Module memcoll.
25903         * m4/memcoll.m4: New file.
25904
25905         Module unicodeio.
25906         * m4/unicodeio.m4: New file.
25907
25908         Module rpmatch.
25909         * m4/rpmatch.m4: New file.
25910
25911         Module yesno.
25912         * m4/yesno.m4: New file.
25913
25914         Module exitfail.
25915         * m4/exitfail.m4: New file.
25916
25917         Module c-stack.
25918         * m4/c-stack.m4 (gl_C_STACK): New macro.
25919         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
25920
25921         Module error.
25922         * m4/error.m4 (gl_ERROR): New macro.
25923         (jm_PREREQ_ERROR): Use onceonly macros.
25924
25925         Module fatal.
25926         * m4/fatal.m4: New file.
25927
25928         Module getloadavg.
25929         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
25930         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
25931
25932         Module getpagesize.
25933         * m4/getpagesize.m4: New file.
25934
25935         Module getusershell.
25936         * m4/getusershell.m4: New file.
25937
25938         Module physmem.
25939         * m4/physmem.m4: New file.
25940
25941         Module posixver.
25942         * m4/posixver.m4: New file.
25943
25944         Module quotearg.
25945         * m4/quotearg.m4: New file.
25946
25947         Module quote.
25948         * m4/quote.m4: New file.
25949
25950         Module readutmp.
25951         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
25952
25953         Module sig2str.
25954         * m4/sig2str.m4: New file.
25955
25956         Other.
25957         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
25958         ulonglong.m4.
25959         * m4/intmax_t.m4: New file.
25960         * m4/d-type.m4: Indentation.
25961         * m4/jm-macros.m4: Update.
25962         * m4/prereq.m4 (jm_PREREQ): Update.
25963         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
25964         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
25965         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
25966         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
25967         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
25968         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
25969         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
25970         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
25971         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
25972         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
25973         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
25974         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
25975         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
25976         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
25977         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
25978         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
25979         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
25980         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
25981         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
25982
25983 2002-12-24  Bruno Haible  <bruno@clisp.org>
25984
25985         * MODULES.txt: Update according to m4/ changes.
25986
25987         Module gettext.
25988         * config.rpath: New file, from gettext-0.11.5.
25989
25990         * modules/*: New module descriptions.
25991         * gnulib-tool: New file.
25992         * MODULES.html.sh: New file.
25993
25994 2002-12-21  Karl Berry  <karl@gnu.org>
25995
25996         * doc/fdl.texi: update to version 1.2.
25997
25998 2002-12-19  Karl Berry  <karl@gnu.org>
25999
26000         * config/config.guess: update from prep.
26001
26002 2002-12-18  Bruno Haible  <bruno@clisp.org>
26003
26004         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
26005         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
26006
26007 2002-12-17  Bruno Haible  <bruno@clisp.org>
26008
26009         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
26010         stdlib.h, string.h.
26011
26012 2002-12-17  Bruno Haible  <bruno@clisp.org>
26013
26014         * lib/canon-host.c (strdup): Remove unused declaration.
26015
26016         * lib/fsusage.c: Include full_read.h.
26017         (get_fs_usage): Use full_read instead of safe_read.
26018
26019         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
26020
26021 2002-12-12  Karl Berry  <karl@gnu.org>
26022
26023         * config/config.guess: update from prep.
26024
26025 2002-12-11  Bruno Haible  <bruno@clisp.org>
26026
26027         * m4/setenv.m4: New file, from gettext-0.11.5.
26028
26029 2002-12-11  Bruno Haible  <bruno@clisp.org>
26030
26031         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
26032         not unsetenv().
26033         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
26034         modifications:
26035
26036         2002-12-11  Bruno Haible  <bruno@clisp.org>
26037
26038                 * setenv.c (alloca): Fall back to malloc.
26039                 (freea): New macro.
26040                 (setenv): Use freea() to free memory allocated with alloca().
26041
26042         2002-11-13  Bruno Haible  <bruno@clisp.org>
26043
26044                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
26045                 function declarations.
26046                 * unsetenv.c (unsetenv): Likewise.
26047
26048         2002-03-04  Bruno Haible  <bruno@clisp.org>
26049
26050                 Portability to AIX 4.3.3.
26051                 * unsetenv.c: New file, extracted from setenv.c.
26052                 * setenv.c: Move the unsetenv() function to unsetenv.c.
26053
26054         2001-12-20  Bruno Haible  <bruno@clisp.org>
26055
26056                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
26057                 use malloc instead. For SunOS 4.
26058
26059         2001-12-11  Bruno Haible  <bruno@clisp.org>
26060
26061                 * setenv.c: Declare alloca.
26062                 (compar_fn_t): New typedef.
26063                 (KNOWN_VALUE, STORE_VALUE): Use it.
26064
26065         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
26066         setenv.h.
26067
26068 2002-12-10  Paul Eggert  <eggert@twinsun.com>
26069
26070         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
26071         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
26072         Choose values that are less likely to collide with system fnmatch
26073         options.
26074         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
26075         defined (e.g., a pure POSIX system).
26076         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
26077         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
26078
26079 2002-12-06  Paul Eggert  <eggert@twinsun.com>
26080
26081         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
26082         a pain in practice to deal with generated m4 files.  This change
26083         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
26084
26085         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
26086         and jm-glibc-io.m4, as they are no longer a special case.
26087         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
26088         kludge and the auto-generation stuff.  Check only whether the
26089         functions are declared, not whether they exist, since older hosts
26090         that don't declare the functions can't use the optimization anyway.
26091
26092 2002-12-06  Jim Meyering  <jim@meyering.net>
26093
26094         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
26095
26096         Merge in changes from libc's misc/error.c, in preparation
26097         for the merge of gnulib's changes back into libc.
26098
26099         * lib/error.c (_): Define only if not already defined.
26100         Move definition to follow all #include directives.
26101         Include unlocked-io.h only if !_LIBC.
26102         [_LIBC]: Include <libio/libioP.h>.
26103         [USE_IN_LIBIO]: Include <libio/iolibio.h>
26104         (fflush): Tweak definition to use INTUSE.
26105         (putc): Define.
26106
26107 2002-12-05  Paul Eggert  <eggert@twinsun.com>
26108
26109         * lib/alloca.c [defined emacs]: Include "lisp.h".
26110         (xalloc_die) [defined emacs]: New macro.
26111         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
26112         [! defined emacs]: Include <xalloc.h>.
26113         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
26114         (pointer): Typedef to POINTER_TYPE *.
26115         (malloc): Remove decl; we now always use xmalloc.
26116         (alloca): Use old-style definition, since Emacs needs this.
26117         Check for arithmetic overflow when computing combined size.
26118
26119 2002-12-04  Paul Eggert  <eggert@twinsun.com>
26120
26121         Do not generate unlocked-io.h automatically, since it's easier to
26122         maintain it by hand.
26123
26124         * lib/unlocked-io.h: New file, from GNU diffutils,
26125         but with proper copyright notice and attribution.
26126         * lib/gen-uio: Remove.
26127         * lib/Makefile.am: Add copyright notice.
26128         (libfetish_a_SOURCES): Add unlocked-io.h.
26129         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
26130         (DISTCLEANFILES, io_functions): Remove macros.
26131         (EXTRA_DIST): Remove gen_uio.
26132         (unlocked-io.h): Remove rule.
26133
26134 2002-12-04  Jim Meyering  <jim@meyering.net>
26135
26136         Reflect the fact that stat.c and lstat.c are no longer generated.
26137         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
26138         (DISTCLEANFILES): Likewise.
26139         (EXTRA_DIST): Likewise.
26140         (all_local): Don't depend on stat.c or lstat.c.
26141         (stat.c, lstat.c): Remove rules.
26142         (EXTRA_DIST): Remove xstat.in.
26143
26144         * lib/xstat.in: Remove file.  Contents moved into stat.c.
26145         * lib/stat.c: New file.  Contents mostly from xstat.in.
26146         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
26147         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
26148
26149         * lib/safe-read.c: Rework so that it may serve to define safe_write,
26150         too.
26151         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
26152
26153 2002-12-03  Jim Meyering  <jim@meyering.net>
26154
26155         * lib/safe-read.c, safe-write.c: Change variable names and comments,
26156         but not semantics, to minimize the differences between these two files.
26157         (safe_read): Change comment to mention SAFE_READ_ERROR.
26158
26159         * lib/safe-read.c (IS_EINTR): Define.
26160         (safe_read): Use IS_EINTR in place of in-function cpp directives.
26161
26162 2002-12-02  Jim Meyering  <jim@meyering.net>
26163
26164         * lib/safe-read.c (EINTR): Define.
26165         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
26166         (INT_MAX): Provide fallback.
26167         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
26168
26169         * lib/safe-read.h (SAFE_READ_ERROR): Define.
26170
26171 2002-12-02  Bruno Haible  <bruno@clisp.org>
26172
26173         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
26174         Define, taken from safe-read.c.
26175         (INT_MAX): Provide fallback.
26176         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
26177         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
26178
26179         * lib/safe-read.c (EINTR): Remove definition.
26180         (safe_read): Don't use EINTR if it is absent.
26181
26182 2002-12-01  Jim Meyering  <jim@meyering.net>
26183
26184         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
26185         zero.
26186         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
26187
26188 2002-11-27  Paul Eggert  <eggert@twinsun.com>
26189
26190         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
26191         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
26192         with `if (! (value < limit)) abort ();', for readability.
26193
26194 2002-11-26  Karl Berry  <karl@gnu.org>
26195
26196         * lib/strdup.c: copy from libc again, with jim's ok.
26197         * lib/.cppi-disable: re-add strdup.c
26198
26199 2002-11-25  Karl Berry  <karl@gnu.org>
26200
26201         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
26202         instead of "strtol.c".
26203
26204 2002-11-25  Karl Berry  <karl@gnu.org>
26205
26206         * config/install-sh: update from automake for variable quoting, $0 in
26207         error msgs, etc.
26208
26209         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
26210         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
26211         entry.
26212
26213 2002-11-25  Jim Meyering  <jim@meyering.net>
26214
26215         * lib/mktime.c: Sync from libc, now that it has the latest fix.
26216
26217 2002-11-24  Karl Berry  <karl@gnu.org>
26218
26219         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
26220         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
26221
26222 2002-11-24  Jim Meyering  <jim@meyering.net>
26223
26224         Update from coreutils:
26225
26226         * lib/mktime.c: Merge in changes from libc.
26227
26228         Avoid a link-time failure on some Linux systems.
26229         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
26230         (otherwise).
26231         (__mon_yday): Declare with the STATIC attribute.
26232         (__mktime_internal): Likewise.
26233         Based on a report from Greg Schafer.
26234
26235 2002-11-23  Jim Meyering  <jim@meyering.net>
26236
26237         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
26238         Use `unsigned', not `int', as type of index.
26239
26240         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
26241
26242         * lib/fsusage.c: Remove unneeded parentheses around operands of
26243         `defined'.
26244
26245 2002-11-22  Paul Eggert  <eggert@twinsun.com>
26246
26247         * lib/quotearg.h: Allow multiple inclusion by surrounding with
26248         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
26249         so that we can be included first.
26250         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
26251         * lib/quotearg.c: Include quotearg.h immediately after config.h.
26252         No need to include stddef.h or sys/types.h any more.
26253         Surround local include files with "", not "<>".
26254         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
26255         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
26256         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
26257         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
26258         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
26259         (ISPRINT): Remove; no longer needed now that we assume C89.
26260
26261         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
26262         Preserve errno.
26263
26264         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
26265         quotearg_char): Use SIZE_MAX rather than
26266         (size_t) -1 when we are talking about "infinity".
26267
26268         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
26269
26270 2002-11-22  Paul Eggert  <eggert@twinsun.com>
26271
26272         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
26273         hint that one should use `if (! x) abort ();' rather than `assert
26274         (x);', and anyway it's one less thing to worry about configuring.
26275         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
26276         hash_rehash, hash_insert): Use abort rather than assert.
26277
26278 2002-11-22  Bruno Haible  <bruno@clisp.org>
26279
26280         * lib/safe-read.h: Assume C89. Add comments.
26281         (safe_read): Change return type to size_t.
26282         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
26283         byte counts > SSIZE_MAX correctly.
26284         * lib/safe-write.h: New file.
26285         * lib/safe-write.c: New file.
26286         * lib/full-read.h: New file.
26287         * lib/full-read.c: New file.
26288         * lib/full-write.h: Assume C89. Add comments.
26289         * lib/full-write.c: Include safe-write.h.
26290         (full_write): Rewritten to use safe_write.
26291         Suggested by Jim Meyering and Paul Eggert.
26292
26293 2002-11-21  Jim Meyering  <jim@meyering.net>
26294
26295         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
26296
26297         Merge in changes from the coreutils.
26298
26299         2002-09-25  Paul Eggert  <eggert@twinsun.com>
26300         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
26301         <stdint.h>.
26302         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
26303         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
26304         int.  Work more efficiently if X is the same width as uintmax_t.
26305         Do not compare X to -1, to avoid bogus compiler warning.
26306         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
26307         Don't assume that f_frsize and f_bsize are the same type.
26308
26309         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
26310         warning on FreeBSD.
26311
26312         * lib/makepath.c (make_path): Restore umask *before* creating the final
26313         component.
26314         (make_path): Minor reformatting.
26315
26316         * lib/xmalloc.c: Adjust to work with new autoconf macros,
26317         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
26318         HAVE_MALLOC/HAVE_REALLOC.
26319
26320         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
26321         dummy ones.  At least on GNU/Linux systems, `auto' means something
26322         else.
26323         From Michael Stone.
26324
26325 2002-11-21  Bruno Haible  <bruno@clisp.org>
26326
26327         Remove case insensitive option matching.
26328         * lib/argmatch.h (argcasematch): Remove declaration.
26329         (ARGCASEMATCH): Remove macro.
26330         (__xargmatch_internal): Remove case_sensitive argument.
26331         (XARGMATCH): Update.
26332         (XARGCASEMATCH): Remove macro.
26333         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
26334         case_sensitive argument.
26335         (argcasematch): Remove function.
26336         (__xargmatch_internal): Remove case_sensitive argument.
26337         (main): Use XARGMATCH instead of XARGCASEMATCH.
26338
26339         * lib/xmalloc.c: Change compile-time error message. Add comment about
26340         required autoconf version.
26341
26342 2002-11-20  Paul Eggert  <eggert@twinsun.com>
26343
26344         Merge argmatch cleanups from Bison.  Assume C89.
26345
26346         * lib/argmatch.c: Include config.h here, not in argmatch.h.
26347         Include stdlib.h, for EXIT_FAILURE.
26348         Always include <string.h>, since we assume C89.
26349         (EXIT_FAILURE): Remove pre-C89 bug workaround.
26350         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
26351         Include <stddef.h> instead, since it's all we need for size_t.
26352         (PARAMS): Remove.  All uses removed.
26353         (ARRAY_CARDINALITY): Do not bother to #undef.
26354         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
26355         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
26356         Remove unnecessary parentheses.
26357         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
26358         Insert necessary parentheses.
26359         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
26360         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
26361
26362 2002-11-19  Bruno Haible  <bruno@clisp.org>
26363
26364         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
26365         * lib/mbswidth.h: Include <stddef.h>, for size_t.
26366
26367         * lib/mbswidth.h (PARAMS): Remove macro.
26368         (mbswidth, mbsnwidth): Use ANSI C function declarations.
26369         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
26370
26371         * lib/gcd.h (PARAMS): Remove macro.
26372         (gcd): Use ANSI C function declarations.
26373         * lib/gcd.c (gcd): Likewise.
26374
26375 2002-11-15  Bruno Haible  <bruno@clisp.org>
26376
26377         * lib/strcspn.c: Include <stddef.h>.
26378         (strcspn): Use ANSI C function declaration. Change return type to
26379         size_t. Use NULL.
26380         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
26381         (strpbrk): Use NULL.
26382         * lib/strpbrk.h (PARAMS): Remove macro.
26383         (strpbrk): Use ANSI C function declaration.
26384         * lib/strstr.c: Don't include <sys/types.h>.
26385         * lib/strstr.h (PARAMS): Remove macro.
26386         (strstr): Use ANSI C function declarations.
26387
26388 2002-11-14  Karl Berry  <karl@gnu.org>
26389
26390         * config/mkinstalldirs: `do' on separate line, instead of
26391         `for var; do'.
26392
26393 2002-11-06  Bruno Haible  <bruno@clisp.org>
26394
26395         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
26396         * lib/gcd.c (gcd): Likewise.
26397
26398 2002-11-05  Bruno Haible  <bruno@clisp.org>
26399
26400         * lib/gcd.h: New file, from gettext-0.11.5.
26401         * lib/gcd.c: New file, from gettext-0.11.5.
26402
26403 2002-11-05  Bruno Haible  <bruno@clisp.org>
26404
26405         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
26406         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
26407         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
26408         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
26409
26410         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
26411         <libintl.h>.
26412         * lib/makepath.c: Include gettext.h instead of <locale.h> and
26413         <libintl.h>.
26414
26415         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
26416         * lib/human.c: Include gettext.h instead of <libintl.h>.
26417         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
26418         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
26419         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
26420         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
26421         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
26422         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
26423         (textdomain): Remove definition.
26424         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
26425
26426         * lib/long-options.c: Remove include of <libintl.h> and definition of
26427         _.
26428         * lib/same.c: Remove include of <libintl.h> and definition of _.
26429
26430 2002-11-04  Owen Taylor  <otaylor@redhat.com>
26431
26432         * lib/config.charset: A few additions for Solaris.
26433
26434 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
26435
26436         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
26437         * lib/localcharset.c (locale_charset): Declare as extern "C".
26438
26439 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
26440
26441         * lib/config.charset: msdos in uk_UA uses CP1125.
26442
26443 2002-11-04  Bruno Haible  <bruno@clisp.org>
26444
26445         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
26446         * lib/strcase.h: New file, from GNU gettext-0.11.5.
26447         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
26448         * lib/strstr.h: New file, from GNU gettext-0.11.5.
26449         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
26450
26451 2002-11-04  Bruno Haible  <bruno@clisp.org>
26452
26453         * lib/localcharset.c (locale_charset): Don't return an empty string.
26454
26455 2002-11-04  Bruno Haible  <bruno@clisp.org>
26456
26457         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
26458         aliases.
26459
26460 2002-11-04  Bruno Haible  <bruno@clisp.org>
26461
26462         * lib/config.charset: Update for newest glibc. Add canonical names
26463         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
26464
26465 2002-11-04  Bruno Haible  <bruno@clisp.org>
26466
26467         * lib/config.charset: Add support for NetBSD.
26468
26469 2002-11-04  Bruno Haible  <bruno@clisp.org>
26470
26471         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
26472
26473 2002-11-01  Bruno Haible  <bruno@clisp.org>
26474
26475         * configure.in: Add AC_CONFIG_AUX_DIR call.
26476         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
26477         test/Makefile.
26478         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
26479
26480 2002-09-28  Karl Berry  <karl@gnu.org>
26481
26482         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
26483         installed automake until the next release, since changes have been
26484         made.
26485
26486 2002-09-25  Karl Berry  <karl@gnu.org>
26487
26488         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
26489         * lib/getopt*: copy from libc/posix.
26490         * lib/gettext.h: copy from gettext.
26491         * lib/.cppi-disable: add strdup.c, gettext.h.
26492
26493 2002-09-25  Karl Berry  <karl@gnu.org>
26494
26495         * config/srclist.txt: enable gettext.h check.
26496         * config/config.{guess,sub}: update from prep.
26497         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
26498                 from automake 1.6.3.
26499         See srclist*.
26500
26501 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
26502
26503         * regex.c (PATFETCH): Remove the translating fetch.
26504         (PATFETCH_RAW): Rename to PATFETCH.
26505         (set_image_of_range): New fun.
26506         (SET_RANGE_TABLE_WORK_AREA): Use it.
26507         (regex_compile): Don't translate the pattern chars so eagerly.
26508         Only do it when inserting an `exactn' bytecode or when handling
26509         a char-range.
26510         (mutually_exclusive_p): Avoid empty statement.
26511
26512 2002-07-06  Jim Meyering  <meyering@lucent.com>
26513
26514         * m4/README: Don't mention Makefile.am.in.
26515         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
26516
26517 2002-07-01  Jim Meyering  <meyering@lucent.com>
26518
26519         * lib/c-stack.c: Include sys/time.h.
26520         From Volker Borchert.
26521
26522 2002-06-26  Paul Eggert  <eggert@twinsun.com>
26523
26524         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
26525
26526 2002-06-26  Paul Eggert  <eggert@twinsun.com>
26527
26528         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
26529         New macro.  Use it uniformly instead of
26530         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
26531         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
26532         reported by Vin Shelton.
26533
26534 2002-06-22  Paul Eggert  <eggert@twinsun.com>
26535
26536         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
26537         Do not assume SA_SIGINFO behavior.
26538         Bug reported by Jim Meyering on NetBSD 1.5.2.
26539
26540 2002-06-22  Jim Meyering  <meyering@lucent.com>
26541
26542         * m4/c-stack.m4: New file, from diffutils-2.8.2.
26543         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
26544
26545         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
26546         now that configure.ac uses AC_GNU_SOURCE.
26547         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
26548         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
26549
26550         Update to latest tools.  Suggestions from Paul Eggert.
26551         * m4/stdbool.m4: New file, from diffutils-2.8.2.
26552         * m4/gnu-source.m4: Update from diffutils-2.8.2.
26553         * m4/fnmatch.m4: Likewise.
26554         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
26555         to AC_HEADER_STDBOOL
26556
26557 2002-06-22  Jim Meyering  <meyering@lucent.com>
26558
26559         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
26560         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
26561
26562 2002-06-22  Jim Meyering  <meyering@lucent.com>
26563
26564         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
26565
26566         * lib/exitfail.c, exitfail.h: Likewise.
26567         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
26568
26569         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
26570         of fnmatch.h.
26571         (EXTRA_DIST): Add fnmatch_loop.c.
26572         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
26573
26574         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
26575         * lib/fnmatch.c: Update from diffutils-2.8.2.
26576         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
26577         * lib/fnmatch.h: Remove file.
26578
26579 2002-06-21  Jim Meyering  <meyering@lucent.com>
26580
26581         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
26582         * m4/mbrtowc.m4: Likewise.
26583
26584         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
26585         * m4/mbswidth.m4: Reflect name change:
26586         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
26587         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
26588
26589         * m4/lib-link.m4: Update from gettext-0.11.2.
26590         * m4/gettext.m4: Likewise.
26591
26592         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
26593         From Alfred M. Szmidt.
26594
26595 2002-06-18  Paul Eggert  <eggert@twinsun.com>
26596
26597         * lib/file-type.h: Report an error if neither S_ISREG nor
26598         S_IFREG is defined, instead of using a test specific to glibc
26599         2.2.  This should be safe, since POSIX requires S_ISREG and
26600         Unix Version 7 had S_IFREG.  We don't need to check for
26601         <sys/types.h> since we don't use any symbols that it defines.
26602
26603 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
26604
26605         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
26606         $@-t, so that each temporary file name is unique and valid in the first
26607         8 characters, for operation under DOS.
26608
26609 2002-06-15  Paul Eggert  <eggert@twinsun.com>
26610
26611         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
26612
26613 2002-06-15  Jim Meyering  <meyering@lucent.com>
26614
26615         Work even with DJGPP 2.03, which lacks support for symlinks.
26616         From Richard Dawe.
26617         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
26618         is defined.
26619         * lib/lchown.c (S_ISLNK): Likewise.
26620
26621 2002-06-15  Jim Meyering  <meyering@lucent.com>
26622
26623         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
26624         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
26625         have been included before this file.
26626
26627 2002-06-14  Jim Meyering  <meyering@lucent.com>
26628
26629         * lib/file-type.h: Use the version from diffutils-2.8.2.
26630         * lib/file-type.c: Likewise.
26631
26632 2002-06-07  Jim Meyering  <meyering@lucent.com>
26633
26634         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
26635         They're needed at least for NetBSD 1.5.2.
26636         ($statxfs_includes): Include those same headers.
26637         ($statxfs_includes): Include sys/vfs.h if available.
26638         ($statxfs_includes): Likewise for sys/statvfs.h.
26639         Check for the following members in both structs statfs and statvfs:
26640         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
26641
26642 2002-06-01  Jim Meyering  <meyering@lucent.com>
26643
26644         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
26645         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
26646
26647 2002-05-28  Jim Meyering  <meyering@lucent.com>
26648
26649         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
26650         Reported by Volker Borchert.
26651
26652 2002-05-27  Jim Meyering  <meyering@lucent.com>
26653
26654         Fix a problem seen only on nonconforming systems whereby ls.c's
26655         use of localtime, and then of gettimeofday would cause trouble:
26656         the localtime call used to initialize rpl_gettimeofday's save
26657         mechanism would clobber ls's current local time information so
26658         that in any long listing the first file would always be listed
26659         with date 1970-01-01.  Analysis by Volker Borchert.
26660
26661         * lib/gettimeofday.c (localtime): Undefine.
26662         (rpl_localtime): New function.
26663
26664 2002-05-27  Jim Meyering  <meyering@lucent.com>
26665
26666         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
26667         localtime.
26668
26669         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
26670         use the replacement function; it wouldn't resolve at link time.
26671         Reported by Volker Borchert.
26672
26673 2002-05-22  Jim Meyering  <meyering@lucent.com>
26674
26675         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
26676         file-type.h.
26677         * lib/file-type.h: New file.
26678         * lib/file-type.c (file_type): New file/function.  Extracted from
26679         diffutils.
26680
26681 2002-04-30  Jim Meyering  <meyering@lucent.com>
26682
26683         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
26684
26685 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26686
26687         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
26688
26689 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26690
26691         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
26692         Do not check for alloca.h (no longer used) or stdbool.h (was never
26693         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
26694
26695 2002-04-29  Paul Eggert  <eggert@twinsun.com>
26696
26697         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
26698
26699 2002-04-29  Jim Meyering  <meyering@lucent.com>
26700
26701         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
26702         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
26703         Use AC_FUNC_STRNLEN here instead.
26704
26705         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
26706         With autoconf-2.53a, it's part of AC_PROG_CC.
26707
26708 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26709
26710         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
26711         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
26712
26713 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26714
26715         * lib/sig2str.h, lib/sig2str.c: New files.
26716         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
26717
26718 2002-04-28  Paul Eggert  <eggert@twinsun.com>
26719
26720         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
26721         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
26722         of 127, since 64 is the largest conceivable number for ancient
26723         nonstandard hosts.
26724         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
26725
26726 2002-04-28  Jim Meyering  <meyering@lucent.com>
26727
26728         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
26729
26730 2002-04-24  Jim Meyering  <meyering@lucent.com>
26731
26732         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
26733         (jm_PREREQ): Use it.
26734
26735         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
26736         mach/mach.h fcntl.h.
26737         Check for this function: setlocale.
26738
26739 2002-04-24  Jim Meyering  <meyering@lucent.com>
26740
26741         * lib/gettext.h: New file, from Gettext.
26742         * lib/Makefile.am (INCLUDES): Remove -I../intl.
26743         (libfetish_a_SOURCES): Add gettext.h.
26744
26745 2002-04-16  Jim Meyering  <meyering@lucent.com>
26746
26747         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
26748         ut_pid, ut_id, ut_exit.
26749
26750 2002-04-16  Jim Meyering  <meyering@lucent.com>
26751
26752         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
26753         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
26754         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
26755
26756 2002-04-12  Jim Meyering  <meyering@lucent.com>
26757
26758         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
26759         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
26760         existence of the getmntinfo function.  Needed for Darwin 5.3.
26761
26762         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
26763         This is necessary at least on Darwin 5.3.
26764
26765         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
26766         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
26767         strnlen.o in the library, and that makes some versions of ranlib
26768         object.
26769
26770 2002-04-12  Jim Meyering  <meyering@lucent.com>
26771
26772         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
26773
26774 2002-04-09  Jim Meyering  <meyering@lucent.com>
26775
26776         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
26777         to be more precise.  Rather than saying we're checking whether the
26778         function `works', say what we're testing.
26779         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
26780         Reported by Bruno Haible.
26781
26782 2002-03-10  Jim Meyering  <meyering@lucent.com>
26783
26784         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
26785         Suggestion from Santiago Vila.
26786
26787 2002-03-08  Jim Meyering  <meyering@lucent.com>
26788
26789         * lib/rename.c: Mention that this wrapper is needed also on
26790         mips-dec-ultrix4.4 systems.
26791
26792 2002-03-02  Jim Meyering  <meyering@lucent.com>
26793
26794         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
26795         not HAVE_CLOCK_SETTIME.
26796
26797 2002-02-27  Paul Eggert  <eggert@twinsun.com>
26798
26799         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
26800         Check for clock_settime.
26801
26802 2002-02-27  Paul Eggert  <eggert@twinsun.com>
26803
26804         * lib/nanosleep.h: Rename to....
26805         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
26806
26807         * lib/gettime.c: New file.
26808         * lib/settime.c: New file.
26809         * lib/stime.c: Remove.
26810
26811         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
26812         timespec.h.  Remove nanosleep.h.
26813
26814 2002-02-25  Paul Eggert  <eggert@twinsun.com>
26815
26816         * m4/acl.m4: New file.
26817         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
26818         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
26819
26820 2002-02-25  Paul Eggert  <eggert@twinsun.com>
26821
26822         * lib/acl.c, lib/acl.h: New files.
26823         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
26824
26825 2002-02-24  Jim Meyering  <meyering@lucent.com>
26826
26827         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
26828         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
26829         cause trouble.  Reported by Nelson Beebe.
26830
26831 2002-02-23  Paul Eggert  <eggert@twinsun.com>
26832
26833         * lib/path-concat.c (xpath_concat): Reorder code to pacify
26834         compilers that don't know that xalloc_die never returns.
26835
26836 2002-02-20  Jim Meyering  <meyering@lucent.com>
26837
26838         * lib/getdate.c: Regenerate using bison-1.33.
26839
26840 2002-02-17  Jim Meyering  <meyering@lucent.com>
26841
26842         * config/config.guess (main): Don't use `head -1'; it's no longer
26843         portable. Use `sed 1q' instead.
26844
26845 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
26846
26847         * m4/codeset.m4: Upgrade to gettext-0.11.
26848         * m4/gettext.m4: Upgrade to gettext-0.11.
26849         * m4/glibc21.m4: Upgrade to gettext-0.11.
26850         * m4/iconv.m4: Upgrade to gettext-0.11.
26851         * m4/isc-posix.m4: Upgrade to gettext-0.11.
26852         * m4/lcmessage.m4: Upgrade to gettext-0.11.
26853         * m4/lib-ld.m4: New file, from gettext-0.11.
26854         * m4/lib-link.m4: New file, from gettext-0.11.
26855         * m4/lib-prefix.m4: New file, from gettext-0.11.
26856         * m4/progtest.m4: Upgrade to gettext-0.11.
26857
26858 2002-02-15  Paul Eggert  <eggert@twinsun.com>
26859
26860         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
26861         (jm_PREREQ): Use it.
26862
26863 2002-02-15  Paul Eggert  <eggert@twinsun.com>
26864
26865         * lib/posixver.c, lib/posixver.h: New files.
26866         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
26867
26868 2002-02-02  Paul Eggert  <eggert@twinsun.com>
26869             Bruno Haible  <bruno@clisp.org>
26870
26871         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
26872         (fwrite_success_callback): New declaration.
26873         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
26874         print_unicode_char. Call failure callback instead of error.
26875         (fwrite_success_callback): New function.
26876         (exit_failure_callback): New function.
26877         (fallback_failure_callback): New function.
26878         (print_unicode_char): Call unicode_to_mb.
26879
26880 2002-01-26  Jim Meyering  <meyering@lucent.com>
26881
26882         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
26883         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
26884
26885 2002-01-26  Jim Meyering  <meyering@lucent.com>
26886
26887         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
26888
26889 2002-01-22  Paul Eggert  <eggert@twinsun.com>
26890
26891         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
26892
26893 2002-01-22  Jim Meyering  <meyering@lucent.com>
26894
26895         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
26896         Otherwise, some versions of automake would omit the rule that makes
26897         Makefile from Makefile.in.
26898
26899 2002-01-21  Paul Eggert  <eggert@twinsun.com>
26900
26901         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
26902         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
26903         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
26904         (memcoll): Set errno to zero if there is no error.
26905
26906         * lib/quotearg.c (quotearg_buffer_restyled):
26907         Fix bug with quoting buffers containing NUL when backslashing escapes.
26908         This bug was exposed by the other changes in this patch.
26909         (quotearg_n_options): New arg ARGSIZE.
26910         All callers changed.
26911         (quoting_options_from_style): New function.
26912         (quotearg_n_style): Use it.
26913         (quotearg_n_style_mem): New function.
26914
26915         * lib/quotearg.h (quotearg_n_style_mem): New function.
26916
26917 2002-01-19  Jim Meyering  <meyering@lucent.com>
26918
26919         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
26920         Remove useless quotes: DF_PROG="df".
26921         * m4/strnlen.m4: New file.
26922
26923 2002-01-16  Paul Eggert  <eggert@twinsun.com>
26924
26925         * lib/backupfile.c (ISDIGIT): Comment fix.
26926         * lib/getdate.y (ISDIGIT): Likewise.
26927         * lib/posixtm.c (ISDIGIT, year): Likewise.
26928         * lib/strverscmp.c (ISDIGIT): Likewise.
26929         * lib/userspec.c (ISDIGIT): Likewise.
26930
26931 2002-01-16  Jim Meyering  <meyering@lucent.com>
26932
26933         * lib/getdate.y: Add three semicolons, each just before a closing
26934         brace. Bison (as of version 1.31) no longer papers over that mistake.
26935
26936 2002-01-05  Jim Meyering  <meyering@lucent.com>
26937
26938         * lib/version-etc.c (version_etc_copyright): Update copyright year.
26939
26940 2001-12-19  Paul Eggert  <eggert@twinsun.com>
26941
26942         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
26943         not silently exit merely because the output buffer happens to
26944         have nothing pending.
26945
26946 2001-12-18  Paul Eggert  <eggert@twinsun.com>
26947
26948         See the big note in ../ChangeLog.
26949         * lib/human.c (suffixes): Prefer K to k for 1024.
26950         (generate_suffix_backwards): New function.
26951         (human_readable_inexact): Use it.
26952         * lib/xstrtol.c (__xstrtol): If there is no number but there
26953         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
26954         Accept 'K' as well as 'k'.
26955
26956 2001-12-15  Jim Meyering  <meyering@lucent.com>
26957
26958         * lib/regex.h (__restrict_arr): Update from libc.
26959
26960         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
26961         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
26962         (STREQ): Define.
26963
26964 2001-12-14  Jim Meyering  <meyering@lucent.com>
26965
26966         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
26967         Suggestion from Bruno Haible.
26968
26969 2001-12-10  Jim Meyering  <meyering@lucent.com>
26970
26971         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
26972         xrealloc, Instead, include "xalloc.h".
26973         (initbuffer): Don't cast xmalloc return value to char*.
26974         (readline): Reword comment.
26975         Don't cast xrealloc return value to char*
26976         Return NULL, not 0.
26977
26978 2001-12-09  Jim Meyering  <meyering@lucent.com>
26979
26980         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
26981         about `signed and unsigned type in conditional expression'.
26982         * lib/posixtm.c (posix_time_parse): Likewise.
26983
26984         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
26985
26986         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
26987         to avoid a pedantic warning.
26988
26989         * lib/getstr.c: Don't include assert.h.
26990         (getstr): Remove warning-evoking assertions.
26991         Return -1 if offset parameter is out of bounds.
26992         Change the type of a local from int to size_t.
26993
26994         * lib/strftime.c (my_strftime_localtime_r): Include this function
26995         definition in the `#if ! HAVE_TM_GMTOFF' block.
26996
26997         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
26998         Include xalloc.h instead.
26999
27000 2001-12-02  Jim Meyering  <meyering@lucent.com>
27001
27002         * lib/tempname.c: Don't declare getenv, thus reverting the change of
27003         2001-11-18.  It's no longer necessary, now that stdlib.h is always
27004         included.
27005
27006         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
27007         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
27008
27009 2001-11-30  Akim Demaille  <akim@epita.fr>
27010
27011         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
27012         before being defined.
27013
27014 2001-11-27  Paul Eggert  <eggert@twinsun.com>
27015
27016         * lib/quotearg.h (quotearg_n, quotearg_n_style):
27017         First arg is int, not unsigned.
27018         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
27019         (SIZE_MAX, UINT_MAX): New macros.
27020         (quotearg_n_options): Abort if N is negative.
27021         Avoid overflow check on hosts where size_t is 64 bits and int
27022         is 32 bits, as overflow is impossible there.
27023         Fix off-by-one typo that caused unnecessary reallocation.
27024
27025 2001-11-27  Jim Meyering  <meyering@lucent.com>
27026
27027         * lib/tempname.c: Merge with version from libc.
27028         * lib/regex.c: Likewise.
27029
27030         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
27031         systems for which STDC_HEADERS is 0, it was not included, resulting in
27032         a warning about an integer-to-pointer conversion problem with getenv.
27033         Reported by Volker Borchert.
27034
27035 2001-11-26  Jim Meyering  <meyering@lucent.com>
27036
27037         * lib/gtod.h: Remove file.
27038         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
27039         * lib/gettimeofday.c: Don't include gtod.h.
27040         (GTOD_init): Remove function.
27041         (rpl_gettimeofday): Do its job here instead, rather than aborting.
27042         Suggestion from Volker Borchert.
27043
27044 2001-11-23  Jim Meyering  <meyering@lucent.com>
27045
27046         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
27047         it.
27048         * lib/hash.c (struct hash_table): Define it here instead.
27049
27050 2001-11-22  Jim Meyering  <meyering@lucent.com>
27051
27052         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
27053
27054 2001-11-20  Jim Meyering  <meyering@lucent.com>
27055
27056         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
27057         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
27058
27059 2001-11-19  Jim Meyering  <meyering@lucent.com>
27060
27061         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
27062         directory.  Use "conftestXXXXXX" as the template.
27063         Suggestion from Paul Eggert.
27064
27065         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
27066         immediately, so the test doesn't mistakenly hit the max-open-files
27067         limit.
27068
27069 2001-11-18  Paul Eggert  <eggert@twinsun.com>
27070
27071         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
27072         (TEMPORARIES): New macro.
27073         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
27074         removes an artificial limitation (e.g. HP-UX 10.20, where
27075         TMP_MAX is 17576).
27076
27077 2001-11-18  Jim Meyering  <meyering@lucent.com>
27078
27079         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
27080
27081 2001-11-18  Jim Meyering  <meyering@lucent.com>
27082
27083         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
27084         on SunOS 4.
27085
27086         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
27087         files will be created before anything else.
27088
27089 2001-11-17  Paul Eggert  <eggert@twinsun.com>
27090
27091         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
27092         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
27093
27094 2001-11-17  Jim Meyering  <meyering@lucent.com>
27095
27096         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
27097         Prompted by a report from Bob Proulx.
27098
27099         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
27100         Instead, require UTILS_FUNC_MKSTEMP.
27101
27102 2001-11-17  Jim Meyering  <meyering@lucent.com>
27103
27104         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
27105         Now, that's done as part of AC_FUNC_STRTOD.
27106
27107 2001-11-17  Jim Meyering  <meyering@lucent.com>
27108
27109         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
27110         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
27111         rather than group writable.  Patch by Juan F. Codagnone.
27112
27113         * lib/readtokens.c: Remove explicit declarations of xmalloc and
27114         xrealloc, Instead, include "xalloc.h".
27115
27116         * lib/mountlist.c: Include unlocked-io.h after all system headers.
27117         Remove explicit declarations of xmalloc, xrealloc,
27118         and xstrdup.  Instead, include "xalloc.h".
27119
27120         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
27121         unlocked-io.h.
27122         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
27123         Likewise.
27124         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
27125
27126         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
27127         Reported by Padraig Brady.
27128
27129         * lib/mkstemp.c: #undef mkstemp.
27130         Include config.h.
27131         (rpl_mkstemp): Rename from mkstemp.
27132         Protoize.
27133
27134 2001-11-16  Jim Meyering  <meyering@lucent.com>
27135
27136         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
27137         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
27138         determine the amount of total physical memory, use pstat_getstatic.
27139         HPUX-11 doesn't define _SC_PHYS_PAGES.
27140         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
27141         If sysconf couldn't be used to determine the amount of available
27142         physical memory, use both pstat_getstatic and pstat_getdynamic.
27143         Based on a patch from Bob Proulx.
27144
27145 2001-11-10  Jim Meyering  <meyering@lucent.com>
27146
27147         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
27148         (jm_PREREQ): Use it.
27149
27150 2001-11-09  Jim Meyering  <meyering@lucent.com>
27151
27152         * m4/jm-macros.m4: Require autoconf-2.52f.
27153         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
27154         Use these AC_-prefixed names, not the AM_-prefixed ones.
27155
27156         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
27157
27158 2001-11-05  Jim Meyering  <meyering@lucent.com>
27159
27160         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
27161
27162 2001-11-04  Jim Meyering  <meyering@lucent.com>
27163
27164         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
27165         $DEFS.
27166
27167 2001-11-03  Jim Meyering  <meyering@lucent.com>
27168
27169         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
27170         of AC_DEFUN.
27171
27172         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
27173         know the name of the variable in the macro definition.
27174
27175 2001-11-03  Jim Meyering  <meyering@lucent.com>
27176
27177         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
27178         in argmatch_to_argument call.
27179
27180         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
27181         argument.
27182
27183         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
27184         e.g., a fault due to an attempt to free a NULL pointer.
27185
27186 2001-11-01  Jim Meyering  <meyering@lucent.com>
27187
27188         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
27189         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
27190
27191 2001-11-01  Jim Meyering  <meyering@lucent.com>
27192
27193         * lib/dirfd.c, lib/dirfd.h: New files.
27194         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
27195
27196         * lib/hash.c (hash_print) [TESTING]: Clean up.
27197
27198 2001-10-22  Paul Eggert  <eggert@twinsun.com>
27199
27200         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
27201         to avoid a warning if -Wall.
27202
27203 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
27204
27205         * README: New file
27206         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
27207         (per RMS's instructions, this is now the canonical source)
27208         * lgpl/, gpl/: New directories.
27209
27210 2001-10-21  Paul Eggert  <eggert@twinsun.com>
27211
27212         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
27213
27214 2001-10-21  Jim Meyering  <meyering@lucent.com>
27215
27216         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
27217         this code would end up calling gettext even in packages built
27218         with --disable-nls.
27219         * lib/getopt.c (_): Likewise.
27220         * lib/regex.c (_): Likewise.
27221
27222 2001-10-20  Paul Eggert  <eggert@twinsun.com>
27223
27224         * m4/error.m4 (jm_PREREQ_ERROR):
27225         Do not invoke AC_CHECK_FUNCS with strerror_r, as
27226         AC_FUNC_STRERROR_R does that.
27227         Check for strerror declaration.
27228
27229         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
27230         are supposed to have them these days.
27231         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
27232         Merge changes from latest Autoconf CVS.
27233         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
27234         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
27235         POSIX decided to standardize on the int flavor of strerror_r.
27236
27237 2001-10-20  Paul Eggert  <eggert@twinsun.com>
27238
27239         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
27240         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
27241         Use strerror_r that is only a macro, even if it is not a function.
27242         (strerror): Check for HAVE_DECL_STRERROR before declaring.
27243         (private_strerror): Use prototypes, not old-style function definition.
27244         (print_errno_message): New function.
27245         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
27246         char*-flavored one.
27247         (error_tail, error, error_at_line): Use it.
27248
27249 2001-10-11  Jim Meyering  <meyering@lucent.com>
27250
27251         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
27252         and quote_n (1, ... to avoid clobbering a buffer.
27253
27254 2001-10-05  Jim Meyering  <meyering@lucent.com>
27255
27256         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
27257         hash-pjw.h.
27258         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
27259         * lib/hash-pjw.h: New file.
27260
27261 2001-09-30  Jim Meyering  <meyering@lucent.com>
27262
27263         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
27264         `struct fsstat' has the `f_fstypename' member.
27265         Use that to define FS_TYPE, which is now used to make
27266         the getfsstat link test tighter.
27267
27268 2001-09-30  Jim Meyering  <meyering@lucent.com>
27269
27270         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
27271         Include <sys/ucred.h>, for Apple Darwin.
27272         Include sys/mount.h and sys/fs_types.h only if available.
27273         (FS_TYPE): Define.
27274         (read_filesystem_list): Use FS_TYPE.
27275
27276 2001-09-29  Paul Eggert  <eggert@twinsun.com>
27277
27278         * lib/exclude.c (excluded_filename): 0 -> false, since it's
27279         a boolean context.
27280
27281 2001-09-29  Jim Meyering  <meyering@lucent.com>
27282
27283         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
27284         [one-argument getmntent function]): Include stdio.h before mntent.h.
27285         SunOS 4.1.x needs it for the declaration of `FILE'.
27286         Patch by Volker Borchert.
27287
27288         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
27289         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
27290         sys/fs_types.h, and make the link-test for getfsstat guard #include
27291         directives with appropriate #if HAVE_*_H tests so that we can
27292         detect getfsstat on Apple Darwin1.3.7 systems.
27293         Reported by Nelson Beebe.
27294         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
27295
27296 2001-09-28  Paul Eggert  <eggert@twinsun.com>
27297
27298         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
27299         #defines strtoimax.  Also treat the other strto* functions
27300         like strtoimax.
27301
27302         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
27303         Check for strtoul and strtoumax,
27304         as those declarations are made even in the signed case.
27305         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
27306         Likewise, for strtol and strtoimax.
27307
27308 2001-09-28  Paul Eggert  <eggert@twinsun.com>
27309
27310         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
27311         #defines strtoimax.  Also treat the other strto* functions
27312         like strtoimax.
27313
27314         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
27315         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
27316         (strtoimax, strtoumax): Do not declare if already defined as a macro.
27317
27318 2001-09-26  Jim Meyering  <meyering@lucent.com>
27319
27320         Most macros in unlocked-io.h had the wrong number of arguments.
27321         * lib/gen-uio: New script.
27322         (USE_UNLOCKED_IO): Define to 1 if not already defined.
27323         * lib/unlocked-io.hin: Remove file.
27324         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
27325         rather than trying to embed it here.
27326         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
27327         Reported by Padraig Brady.
27328
27329 2001-09-25  Volker Borchert  <bt@teknon.de>
27330
27331         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
27332         `result'.
27333
27334 2001-09-24  Jim Meyering  <meyering@lucent.com>
27335
27336         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
27337
27338 2001-09-23  Jim Meyering  <meyering@lucent.com>
27339
27340         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
27341         instead of the mere test for existence of mntent.h.  The latter
27342         would get a false-positive on AIX 3.4 systems.
27343         In the outer getmntent if-block, don't die if neither of the getmntent
27344         tests succeeds.  Instead, just fall through and continue with the
27345         remaining tests.
27346
27347 2001-09-23  Jim Meyering  <meyering@lucent.com>
27348
27349         * lib/mountlist.c: Remove useless parentheses in #if directives.
27350         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
27351         the deprecated MOUNTED symbol is no longer defined in mntent.h.
27352
27353 2001-09-22  Jim Meyering  <meyering@lucent.com>
27354
27355         * m4/gettext.m4: New file.  From gettext.
27356         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
27357         * m4/progtest.m4: Likewise
27358         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
27359         * m4/glibc21.m4: Likewise.
27360
27361         * m4/libintl.m4: Remove.  No longer used.
27362
27363 2001-09-22  Jim Meyering  <meyering@lucent.com>
27364
27365         * lib/localcharset.c: Update from latest gettext.
27366         * lib/config.charset: Likewise.
27367
27368 2001-09-20  Jim Meyering  <meyering@lucent.com>
27369
27370         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
27371         strtoimax.
27372         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
27373         strtoumax.
27374
27375 2001-09-20  Jim Meyering  <meyering@lucent.com>
27376
27377         * lib/xstrtol.c (strtoimax): Guard declaration with
27378         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
27379         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
27380         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
27381         (strtoumax): Likewise, for completeness (it wasn't necessary).
27382
27383 2001-09-17  Paul Eggert  <eggert@twinsun.com>
27384
27385         * lib/strtoimax.c (HAVE_LONG_LONG):
27386         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
27387         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
27388         to work around bug in IBM C compiler.
27389
27390 2001-09-17  Jim Meyering  <meyering@lucent.com>
27391
27392         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
27393         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
27394         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
27395         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
27396         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
27397         whenever the right hand side need not be expanded by the shell.
27398
27399 2001-09-16  Paul Eggert  <eggert@twinsun.com>
27400
27401         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
27402         library.  It's not correct, as some older glibcs are buggy.
27403         fnmatch wasn't fixed until glibc 2.2.
27404
27405         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
27406         special shell magic here.
27407
27408 2001-09-16  Jim Meyering  <meyering@lucent.com>
27409
27410         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
27411         * m4/jm-macros.m4: Require it.
27412
27413 2001-09-16  Jim Meyering  <meyering@lucent.com>
27414
27415         * lib/mkdir.c: New file.
27416
27417 2001-09-15  Jim Meyering  <meyering@lucent.com>
27418
27419         * m4/jm-macros.m4: Check for help2man.
27420
27421 2001-09-11  Jim Meyering  <meyering@lucent.com>
27422
27423         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
27424         The body, by Paul Eggert, was moved here from configure.in.
27425         * m4/jm-macros.m4: Require UTILS_HOST_OS.
27426
27427 2001-09-04  Paul Eggert  <eggert@twinsun.com>
27428
27429         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
27430         (jm_PREREQ): Use it.
27431
27432 2001-09-04  Paul Eggert  <eggert@twinsun.com>
27433
27434         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
27435         Use ssize_t, not int, to store result of readlink.
27436         Check for ssize_t overflow as well as size_t overflow,
27437         as POSIX says the result of readlink is implementation-defined
27438         when ssize_t overflows.
27439         Remove unnecessary cast to char*.
27440         Use free+malloc instead of realloc, as the storage doesn't need
27441         to be preserved and it's clearer and can be more efficient that way.
27442         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
27443         * lib/xreadlink.h (xreadlink): Update prototype.
27444
27445 2001-09-04  Paul Eggert  <eggert@twinsun.com>
27446
27447         * lib/xgetcwd.c: Revert some of the previous change; intead,
27448         fix the HAVE_GETCWD_NULL code to behave more like the
27449         !HAVE_GETCWD_NULL code used to.
27450
27451         Include "xalloc.h".
27452         (xgetcwd): Do not return NULL when memory is exhausted; instead,
27453         invoke xalloc_die.
27454
27455 2001-09-03  Paul Eggert  <eggert@twinsun.com>
27456
27457         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
27458         sys/param.h, as pathmax.h includes them.
27459
27460 2001-09-03  Paul Eggert  <eggert@twinsun.com>
27461
27462         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
27463         (jm_PREREQ_XGETCWD): New macro.
27464
27465         * m4/getcwd.m4: New file.
27466
27467 2001-09-03  Paul Eggert  <eggert@twinsun.com>
27468
27469         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
27470         like the HAVE_GETCWD_NULL code.
27471         Include pathmax.h if not HAVE_GETCWD.
27472         Do not include xalloc.h.
27473         (INITIAL_BUFFER_SIZE): New symbol.
27474         Do not use xmalloc / xrealloc, since the caller is responsible for
27475         handling errors.  Preserve errno around `free' during failure.
27476         Do not overrun buffer when using getwd.
27477
27478 2001-09-03  Paul Eggert  <eggert@twinsun.com>
27479
27480         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
27481         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
27482         getcwd (NULL, 0).
27483
27484 2001-09-03  Paul Eggert  <eggert@twinsun.com>
27485
27486         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
27487         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
27488         spotted by Jim Meyering.
27489
27490 2001-09-03  Jim Meyering  <meyering@lucent.com>
27491
27492         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
27493         failure.
27494
27495 2001-09-02  Jim Meyering  <meyering@lucent.com>
27496
27497         * lib/error.c: Update from GNU libc.
27498
27499 2001-09-01  Jim Meyering  <meyering@lucent.com>
27500
27501         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
27502         Used by df.
27503
27504 2001-09-01  Jim Meyering  <meyering@lucent.com>
27505
27506         * lib/xreadlink.c: New file.
27507         * lib/xreadlink.h: New file.
27508         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
27509         xreadlink.h.
27510
27511         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
27512         doesn't conflict with sparc Solaris 7's definition in
27513         /usr/include/sys/int_types.h.
27514
27515         * lib/exclude.c: Use `""', not `<>' to #include non-system header
27516         files.
27517         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
27518         and strncasecmp as r-values.  Unixware didn't have declarations.
27519
27520 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27521
27522         * lib/xstrtol.h: Add copyright notice.
27523         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
27524         LONGINT_INVALID_SUFFIX_CHAR.
27525
27526 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27527
27528         * lib/xstrtol.c (strtoimax): New decl.
27529
27530 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27531
27532         * lib/xgetcwd.c: Don't include pathmax.h.
27533         Include stdlib.h and unistd.h if available.
27534         Include xalloc.h.
27535         (xmalloc, xstrdup, free): Remove decls.
27536         (xgetcwd): Don't assume sizes fit in unsigned.
27537         Check for overflow when computing sizes.
27538         Simplify reallocation code.
27539
27540 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27541
27542         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
27543         a directory's st_size can have an arbitrary value, so the old
27544         usage could waste an arbitrary amount of memory.  All uses
27545         changed.
27546         * lib/savedir.h: Update prototype.
27547
27548 2001-08-31  Paul Eggert  <eggert@twinsun.com>
27549
27550         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
27551
27552         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
27553         old strtoimax.c.
27554
27555         Also, make the following further changes to make this file's
27556         configuration more similar to that of strtol.c:
27557         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
27558         (strtoumax, uintmax_t, strtoull, strtol): Remove.
27559         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
27560         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
27561         changed to signed values.
27562
27563         And make the following changes as well:
27564         Fix copyright notice, as 1999 was missing.
27565         (verify): New macro.
27566         (strtoimax): Check sizes at compile-time, not run-time.
27567         Prefer strtol to strtoll if both work.
27568         (main): Remove; it was not that useful and was a pain to maintain.
27569
27570         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
27571
27572 2001-08-31  Jim Meyering  <meyering@lucent.com>
27573
27574         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
27575         Use an initial, malloc'd, buffer of length 128 rather than
27576         a statically allocated one of length 1024.
27577
27578 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27579
27580         Simplify code, partly by assuming autoconf 2.52 semantics.
27581
27582         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
27583
27584         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
27585         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
27586         All uses removed.
27587         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
27588         Move AC_REQUIRE to next-to-top level, to avoid confusion.
27589         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
27590         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
27591         jm_AC_HEADER_INTTYPES_H.
27592         * m4/jm-macros.m4 (jm_MACROS): Likewise.
27593
27594         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
27595
27596         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
27597         Quote first arg of AC_DEFUN.
27598         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
27599         since they are needed to parse the include file even if we need
27600         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
27601         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
27602         but with opposite signedness.
27603
27604 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27605
27606         Merge 'exclude' changes from tar 1.13.22.
27607         This fixes one or two unlikely storage allocation overflow bugs,
27608         but doesn't change user-visible behavior otherwise.
27609
27610 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27611
27612         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
27613         (jm_PREREQ_EXCLUDE): New macro.
27614
27615 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27616
27617         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
27618         tm to be declared.
27619
27620 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27621
27622         * lib/hash.c: Remove '2001' from copyright notice.
27623
27624 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27625
27626         * lib/full-write.h: New file.
27627         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
27628         * lib/full-write.c: Correct credits, as cccp.c no longer
27629         exists and anyway it was so heavily changed from the old cccp
27630         code as to be unrecognizable.  Include full-write.h.
27631         (full_write) Return size_t, with short writes meaning failure.
27632         All callers changed.  This fixes a bug with large buffers
27633         on 64-bit hosts.
27634         * lib/utime.c: Include full-write.h.
27635
27636 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27637
27638         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
27639         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
27640         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
27641         Include if available.
27642         (<xalloc.h>): Include
27643         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
27644         (verify): New macro.  Use it to verify that EXCLUDE macros do not
27645         collide with FNM macros.
27646         (struct patopts): New struct.
27647         (struct exclude): Use it, as exclude patterns now come with options.
27648         (new_exclude): Support above changes.
27649         (new_exclude, add_exclude_file):
27650         Initial size must now be a power of two to simplify overflow checking.
27651         (free_exclude, fnmatch_no_wildcards): New function.
27652         (excluded_filename): No longer requires options arg, as the options
27653         are determined by add_exclude.  Now returns bool, not int.
27654         (excluded_filename, add_exclude):
27655         Add support for the fancy new exclusion options.
27656         (add_exclude, add_exclude_file): Now takes int options arg.
27657         Check for arithmetic overflow when computing sizes.
27658         (add_exclude_file): xrealloc might modify errno, so don't
27659         realloc until after errno might be used.
27660
27661         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
27662         New macros.
27663         (free_exclude): New decl.
27664         (add_exclude, add_exclude_file): Now takes int options arg.
27665         (excluded_filename): No longer requires options arg, as the options
27666         are determined by add_exclude.  Now returns bool, not int.
27667
27668 2001-08-30  Paul Eggert  <eggert@twinsun.com>
27669
27670         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
27671
27672 2001-08-27  Jim Meyering  <meyering@lucent.com>
27673
27674         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
27675
27676         * lib/version-etc.c (N_): Remove definition.
27677         Revert most of last change.
27678         Instead, simply don't mark the `Copyright...' string for translation.
27679         Based on advice from Paul Eggert.
27680
27681         * lib/strtoxmax.c: Tweak comment.
27682
27683 2001-08-26  Jim Meyering  <meyering@lucent.com>
27684
27685         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
27686
27687         * m4/xstrtoimax.m4: New file.
27688         * m4/xstrtoumax.m4: Add comments explaining why we
27689         AC_REPLACE_FUNCS(strtol).
27690
27691 2001-08-26  Jim Meyering  <meyering@lucent.com>
27692
27693         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
27694         of copyright with `%s' so translators don't get an untranslated
27695         message in 2002.
27696         (COPYRIGHT_YEAR): Define.
27697         (version_etc): Use fprintf rather than fputs.
27698         Suggestion from Ulrich Drepper.
27699
27700         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
27701
27702         * lib/strtoll.c: New file, from GNU libc.
27703         * lib/xstrtoimax.c: New file.
27704
27705         * lib/xstrtol.h: Add xstrtoimax.
27706         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
27707         * lib/strtoimax.c: New file.  Likewise, but first define
27708         STRTOUXMAX_SIGNED.
27709
27710         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
27711         ...
27712         * lib/strtoxmax.c: ... then renamed to this.
27713
27714 2001-08-18  Paul Eggert  <eggert@twinsun.com>
27715
27716         * m4/inttypes.m4: Add AC_PREREQ(2.13).
27717         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
27718         (jm_AC_TYPE_INTMAX_T): New macro.
27719         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
27720
27721         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
27722
27723         * m4/longlong.m4: Renamed from ulonglong.m4.
27724         * m4/inttypes.m4: Renamed from inttypes_h.m4.
27725         * m4/uintmax_t.m4: Removed.
27726
27727 2001-08-13  Paul Eggert  <eggert@twinsun.com>
27728
27729         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
27730         Port to Solaris 8, where 'sed' requires a space after the 'r'
27731         command, and where sh dislikes "$/".  Clean up the spacing a bit.
27732         Redirect output to $tmp just once.
27733
27734 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
27735
27736         * lib/addext.c (<errno.h>): Include.
27737         (errno): Declare if not defined.
27738         (addext): Work correctly when pathconf returns -1 and leaves
27739         errno alone because there is no limit.  Also, work even if
27740         pathconf returns a value greater than SIZE_MAX.
27741
27742 2001-08-12  Jim Meyering  <meyering@lucent.com>
27743
27744         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
27745         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
27746         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
27747         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
27748         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
27749         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
27750         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
27751         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
27752         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
27753         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
27754         utime.m4, utimes.m4, xstrtoumax.m4:
27755         Quote the first argument in each use of AC_DEFUN.
27756
27757 2001-08-12  Jim Meyering  <meyering@lucent.com>
27758
27759         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
27760         Simply `return getcwd (NULL, 0);'.
27761         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
27762         Use 1300 as initial value for length, not PATH_MAX.
27763
27764         * lib/pathmax.h: Clean up cpp syntax.
27765
27766 2001-08-12  Jim Meyering  <meyering@lucent.com>
27767
27768         * lib/gettimeofday.c: New file.
27769         * lib/gtod.h: New file.
27770         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
27771
27772 2001-08-05  Jim Meyering  <meyering@lucent.com>
27773
27774         * m4/jm-macros.m4: Require autoconf-2.52.
27775
27776 2001-08-04  Jim Meyering  <meyering@lucent.com>
27777
27778         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
27779         stmt, to get in sync with glibc.
27780
27781 2001-08-03  Paul Eggert  <eggert@twinsun.com>
27782
27783         The following changes are from gettext 0.10.39 as maintained by
27784         Bruno Haible.
27785
27786         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
27787         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
27788         with inverted sense.  All uses changed.
27789
27790         * lib/mbswidth.c: Don't include <limits.h>.
27791         Include <stdlib.h> and <string.h> unconditionally.
27792         (iswcntrl, mbsinit, ISCNTRL): New macros.
27793         (mbsnwidth): Use K&R style function declarations.
27794         Don't bother checking for MB_LEN_MAX == 1, since the compiler
27795         can optimize it when MB_CUR_MAX == 1.
27796         The width of control characters is zero, not 1.
27797
27798 2001-08-03  Paul Eggert  <eggert@twinsun.com>
27799
27800         The following changes are from gettext 0.10.39 as maintained by
27801         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
27802
27803         * m4/codeset.m4: Upgrade to serial AM1.
27804         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
27805         all uses changed.  Quote first arg of AC_DEFUN.
27806         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
27807
27808         * m4/iconv.m4: Upgrade to serial AM2.
27809         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
27810         Add --with-libconv-prefix.
27811         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
27812         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
27813         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
27814         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
27815         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
27816
27817         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
27818         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
27819         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
27820         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
27821         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
27822         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
27823         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
27824         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
27825         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
27826
27827         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
27828         string.h any more.
27829
27830         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
27831         not the default value.
27832
27833         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
27834         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
27835         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
27836         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
27837         Also check for iswcntrl, used for wcwidth fallback.
27838         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
27839         to Autoconf 2.13.
27840
27841 2001-08-03  Jim Meyering  <meyering@lucent.com>
27842
27843         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
27844         as it was in the original.  Reported by Paul Eggert.
27845
27846 2001-07-16  Jim Meyering  <meyering@lucent.com>
27847
27848         * m4/gettimeofday.m4: New file.
27849         Prompted by a report from Bernhard Baehr.
27850
27851 2001-07-15  Jim Meyering  <meyering@lucent.com>
27852
27853         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
27854         stuff. Now it's in ../Makefile.cfg.
27855
27856 2001-07-15  Jim Meyering  <meyering@lucent.com>
27857
27858         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
27859         (BUILT_SOURCES): Add unlocked-io.h.
27860         (io_functions): Define.
27861         (unlocked-io.h): New rule.
27862         (DISTCLEANFILES): Add unlocked-io.h.
27863         (all-local): Depend on unlocked-io.h, to ensure it is created.
27864
27865         * lib/unlocked-io.hin: New file
27866
27867         * lib/regex.c: Update from glibc.
27868
27869 2001-07-05  Jim Meyering  <meyering@lucent.com>
27870
27871         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
27872         recommendation.
27873         (libfetish_a_SOURCES): Put all .h files here instead.
27874         Remove a thus-exposed (better checks in automake) duplicate and
27875         two unnecessary .h files.
27876
27877 2001-07-04  Jim Meyering  <meyering@lucent.com>
27878
27879         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
27880         that generates jm-glibc-io.m4 so that it doesn't trigger any make
27881         distcheck failure.
27882
27883 2001-07-02  Jim Meyering  <meyering@lucent.com>
27884
27885         The following changes were prompted by suggestions from Bruno Haible.
27886
27887         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
27888         is now generated.
27889         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
27890         definition of EXTRA_DIST.
27891         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
27892         ensure that the generated file is created/updated whenever the list
27893         of $(unlocked_functions) is changed.
27894         (jm-glibc-io.m4): New rule.
27895         (unlocked-io.h): New rule -- currently unused.
27896
27897 2001-06-24  Jim Meyering  <meyering@lucent.com>
27898
27899         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
27900         unmatched right bracket, rather than kludging it with an extra,
27901         falsely-matching quote in a comment.  Patch by Akim Demaille.
27902
27903 2001-06-11  Jim Meyering  <meyering@lucent.com>
27904
27905         * lib/regex.c: Update from GNU libc.
27906
27907 2001-05-27  Jim Meyering  <meyering@lucent.com>
27908
27909         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
27910         Check for ut_type in struct utmp.
27911
27912 2001-05-27  Jim Meyering  <meyering@lucent.com>
27913
27914         * lib/readutmp.h (UT_TYPE): Define.
27915
27916 2001-05-24  Jim Meyering  <meyering@lucent.com>
27917
27918         * lib/argmatch.c: Include "quote.h".
27919         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
27920         quote function.  Reported by Göran Uddeborg.
27921
27922 2001-05-22  Jim Meyering  <meyering@lucent.com>
27923
27924         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
27925         now that we use the package-supplied version unconditionally.
27926         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
27927
27928 2001-05-21  Jim Meyering  <meyering@lucent.com>
27929
27930         * m4/regex.m4: Change a couple backticks to single quotes to avoid
27931         shell syntax errors.
27932
27933 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
27934
27935         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
27936
27937 2001-05-20  Paul Eggert  <eggert@twinsun.com>
27938
27939         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
27940         Don't bother to check library strftime, since
27941         we'll be using our own my_strftime function anyway.
27942         Define my_strftime instead of strftime.
27943
27944 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
27945
27946         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
27947         which is not yet declared.
27948
27949 2001-05-15  Jim Meyering  <meyering@lucent.com>
27950
27951         * m4/regex.m4: Use proper quoting so brackets appear in the test
27952         program.
27953         Reported by, and with help from, Bruno Haible.
27954
27955 2001-05-13  Jim Meyering  <meyering@lucent.com>
27956
27957         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
27958         undefined.
27959
27960 2001-05-11  Paul Eggert  <eggert@twinsun.com>
27961
27962         dirname code cleanup.  base_name now behaves more compatibly
27963         with POSIX basename when given file names that have trailing
27964         slashes, and similarly for dir_name.  Add new primitives
27965         base_len and dir_len.  Put the directory-name-related decls
27966         into dirname.h.
27967
27968         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
27969         * lib/backupfile.c (base_name): Likewise.
27970         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
27971         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
27972         * lib/makepath.c (strip_trailing_slashes): Likewise.
27973         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
27974         ISSLASH): Likewise.
27975         * lib/rename.c (strip_trailing_slashes): Likewise.
27976         * lib/same.c (base_name): Likewise.
27977         * lib/stripslash.c (ISSLASH): Likewise.
27978
27979         * lib/addext.c: Include <dirname.h> after size_t is defined.
27980         * lib/backupfile.c: Likewise.
27981
27982         * lib/addext.c (addext): Use base_len to trim redundant
27983         trailing slashes instead of doing it ourselves.
27984         But do not trim the last slash if it is not redundant.
27985
27986         * lib/backupfile.c (find_backup_file_name,
27987         max_backup_version): Use base_len instead of rolling it ourselves.
27988         Handle the case of "" and (on DOS) "C:" correctly.
27989
27990         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
27991         needed. Include <string.h>, <dirname.h>.
27992         (base_name): Allow file names ending in slashes, other than names
27993         that are all slashes.  In this case, return the basename followed
27994         by the slashes.  This is more general, and can be used in places
27995         where the original base_name purposely had an assertion failure.
27996         (base_len): New function.
27997
27998         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
27999         Do not include <assert.h>; no longer needed.
28000         Include xalloc.h.
28001         (memrchr): Remove decl.
28002         (dir_name_r): Remove.
28003         (dir_len): Renamed from dirlen.  All callers changed.
28004         Rewrite in terms of base_name, for simplicity and consistency.
28005         (dir_name): Never return NULL.  All callers changed.
28006         Do not include <stdlib.h> in test program; no longer needed.
28007         return 0; is fine for test program.
28008
28009         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
28010         New macros.
28011         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
28012
28013         * lib/path-concat.c (path_concat): Use base_len to compute
28014         base length, not strlen; this means we cannot rely on memcpy
28015         to null-terminate.
28016
28017         * lib/same.c (STREQ): Remove.
28018         (same_name): Handle the case where the basename ends in trailing '/'.
28019
28020         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
28021         a slash was stripped.  Do not strip the last slash after a
28022         file system prefix.
28023
28024 2001-05-11  Paul Eggert  <eggert@twinsun.com>
28025
28026         * lib/Makefile.am (libfetish_a_SOURCES):
28027         Add strftime.c, since we now compile it on all hosts.
28028
28029         * lib/strftime.c (my_strftime):
28030         Define to nstrftime if emacs, but only if my_strftime is not defined.
28031         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
28032         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
28033         Add one more extra argument: a nanoseconds value.
28034         All uses changed.
28035         (ns): New macro.
28036         (my_strftime function): Add %N format.
28037         (emacs_strftimeu): Renamed from emacs_strftime,
28038         with extra ut argument.
28039
28040 2001-05-09  Paul Eggert  <eggert@twinsun.com>
28041
28042         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
28043
28044 2001-04-21  Jim Meyering  <meyering@lucent.com>
28045
28046         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
28047         doesn't interfere.
28048
28049 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
28050
28051         * m4/ftruncate.m4: Check for chsize.
28052         Link with ftruncate.o unconditionally if ftruncate is missing.
28053         This was required when cross-compiling to i586-mingw32msvc.
28054
28055 2001-04-08  Jim Meyering  <meyering@lucent.com>
28056
28057         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
28058         recomputed; that's necessary when the offset spans a DST transition.
28059         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
28060
28061 2001-04-02  Jim Meyering  <meyering@lucent.com>
28062
28063         * lib/regex.h, regex.c: Update from GNU libc.
28064
28065 2001-03-24  Jim Meyering  <meyering@lucent.com>
28066
28067         * m4/jm-macros.m4: Require autoconf-2.49d.
28068
28069 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
28070
28071         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
28072
28073 2001-03-19  Paul Eggert  <eggert@twinsun.com>
28074
28075         * lib/version-etc.c (version_etc_copyright): Update to 2001.
28076
28077 2001-03-17  Jim Meyering  <meyering@lucent.com>
28078
28079         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
28080         now that the version in autoconf is equivalent.
28081         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
28082
28083         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
28084         Suggestion from Akim Demaille.
28085
28086         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
28087         (jm_PREREQ_TEMPNAME): New function.
28088
28089 2001-03-16  Paul Eggert  <eggert@twinsun.com>
28090
28091         * lib/tempname.c (uint64_t): Define to uintmax_t if
28092         not defined, and if UINT64_MAX is not defined.
28093         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
28094         Reported by John David Anglin.
28095
28096 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
28097
28098         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
28099         resolve alias if codeset is empty.
28100         * lib/config.charset (BeOS): Use wildcard syntax.
28101
28102 2001-03-13  Jim Meyering  <meyering@lucent.com>
28103
28104         * lib/path-concat.c (path_concat)
28105         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
28106         concatenating e.g., `C:' and `foo'.
28107         From Bruno Haible.
28108
28109 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
28110
28111         * lib/localcharset.c (locale_charset): Don't use
28112         setlocale(LC_CTYPE,NULL). Don't return NULL.
28113         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
28114
28115 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
28116
28117         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
28118         support for DOS/DJGPP.
28119
28120 2001-03-01  Paul Eggert  <eggert@twinsun.com>
28121
28122         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
28123         lacks mkstemp.  Compile our own tempname.c if we compile our own
28124         mkstemp.c, as mkstemp relies on tempname.
28125
28126 2001-03-01  Jim Meyering  <meyering@lucent.com>
28127
28128         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
28129         AH_VERBATIM really does output its argument verbatim.
28130
28131 2001-02-28  Paul Eggert  <eggert@twinsun.com>
28132
28133         * lib/Makefile.am (libfetish_a_SOURCES):
28134         Add dup-safer.c, fopen-safer.c.
28135         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
28136
28137         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
28138         * lib/unistd-safer.h: New files.
28139
28140 2001-02-25  Paul Eggert  <eggert@twinsun.com>
28141
28142         The mkstemp replacement is taken from glibc 2.2.2, with some
28143         portability fixes for use outside glibc, as follows:
28144
28145         * lib/tempname.c (struct_stat64): New macro.
28146         (direxists, __gen_tempname): Use it.
28147         This avoids a portability problem with Solaris 8.
28148
28149         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
28150         (<stddef.h>, <stdint.h>, <string.h>):
28151         Include only if STDC_HEADERS || _LIBC.
28152         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
28153         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
28154         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
28155         (__set_errno): Define this macro if <errno.h> doesn't.
28156         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
28157         Define these macros if <stdio.h> doesn't.
28158         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
28159         Define these macros if <sys/stat.h>
28160         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
28161         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
28162         __xstat64): Define if not _LIBC.
28163         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
28164         (__gen_tempname): Invoke gettimeofday only if
28165         HAVE_GETTIMEOFDAY || _LIBC;
28166         otherwise, fall back on plain "time".
28167         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
28168
28169         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
28170
28171         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
28172
28173 2001-02-18  Paul Eggert  <eggert@twinsun.com>
28174
28175         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
28176
28177 2001-02-17  Paul Eggert  <eggert@twinsun.com>
28178
28179         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
28180         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
28181         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
28182         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
28183
28184 2001-02-17  Paul Eggert  <eggert@twinsun.com>
28185
28186         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
28187         Remove workaround macros for hosts that have mbrtowc but not
28188         mbstate_t, as we now insist on proper declarations for both
28189         before using mbrtowc.
28190
28191 2001-02-17  Jim Meyering  <meyering@lucent.com>
28192
28193         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
28194         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
28195         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
28196         UnixWare 7.1.1.
28197
28198         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
28199         rather than AC_CACHE_VAL.
28200
28201 2001-02-17  Jim Meyering  <meyering@lucent.com>
28202
28203         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
28204         around included file name.
28205
28206         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
28207
28208         * lib/strftime.c: Update from GNU libc (the only changes were to
28209         comments).
28210
28211 2001-02-17  Jim Meyering  <meyering@lucent.com>
28212
28213         * lib/regex.c: Update from libc.
28214
28215 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
28216
28217         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
28218         clash.
28219
28220 2001-02-16  Paul Eggert  <eggert@twinsun.com>
28221
28222         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
28223         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
28224         Reported by Mark Hounschell via Paul Eggert.
28225
28226 2001-02-07  Jim Meyering  <meyering@lucent.com>
28227
28228         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
28229
28230 2001-02-05  Jim Meyering  <meyering@lucent.com>
28231
28232         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
28233         it includes the patch required for `large file' support with at least
28234         HP-UX's 10.20 /bin/cc.
28235
28236 2001-02-03  Jim Meyering  <meyering@lucent.com>
28237
28238         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
28239         AS_IF, now that it works once again (mysteriously).
28240         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
28241
28242 2001-01-30  Jim Meyering  <meyering@lucent.com>
28243
28244         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
28245         * m4/chown.m4: Rename conftestchown to conftest.chown.
28246         * m4/rename.m4: s/conftestdir/conftest.d1/ and
28247         s/conftestdir2/conftest.d2/.
28248         * m4/utimes.m4: s/conftestdata/conftest.data/
28249         Inspired by Pavel Roskin's change in autoconf.
28250
28251 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
28252
28253         * lib/config.charset: Update for FreeBSD 4.2.
28254
28255 2001-01-27  Jim Meyering  <meyering@lucent.com>
28256
28257         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
28258         a use of AS_IF.
28259         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
28260
28261 2001-01-26  Jim Meyering  <meyering@lucent.com>
28262
28263         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
28264         quotearg.c includes it.
28265
28266 2001-01-26  Jim Meyering  <meyering@lucent.com>
28267
28268         * lib/quotearg.c: Include stddef.h.
28269         * lib/quote.c: Include stddef.h.
28270         Reported by Axel Kittenberger.
28271
28272         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
28273         line in double quotes so that it evokes a better diagnostic.
28274         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
28275         Reported by Axel Kittenberger.
28276
28277 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
28278
28279         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
28280         as if it was a `charset'.
28281
28282 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
28283
28284         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
28285         has const.
28286
28287 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
28288
28289         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
28290         to avoid a warning.  Add back 'const' to inptr.
28291
28292 2001-01-20  Jim Meyering  <meyering@lucent.com>
28293
28294         Be sure that headers are checked before used in code compiled
28295         for the type checks.
28296         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
28297         In place of that, invoke jm_CHECK_ALL_TYPES.
28298         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
28299         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
28300         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
28301         The check for ssize_t was mistakenly run before the test for unistd.h.
28302
28303         The configure-time check for stdbool.h was missing.
28304         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
28305         (jm_PREREQ_HASH): New function.
28306
28307 2001-01-17  Jim Meyering  <meyering@lucent.com>
28308
28309         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
28310         for autoconf-2.49c.
28311         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
28312
28313 2001-01-16  Jim Meyering  <meyering@lucent.com>
28314
28315         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
28316         From Bruno Haible.
28317
28318 2001-01-14  Jim Meyering  <meyering@lucent.com>
28319
28320         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
28321         foo and bar.  Create conftestdir/ in the script, not in the C code.
28322         Remove directories in the script, not in the C code.
28323         Remove conftestdir{,2} before trying to create the directory.
28324         Make the entire configure script fail if the mkdir fails.
28325
28326 2001-01-14  Jim Meyering  <meyering@lucent.com>
28327
28328         * lib/rename.c: New file.  From Volker Borchert.
28329         Include stdlib.h, string.h or strings.h, and xalloc.h.
28330         Use strip_trailing_slashes rather than open-coding it.
28331
28332 2001-01-03  Paul Eggert  <eggert@twinsun.com>
28333
28334         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
28335
28336 2001-01-03  Jim Meyering  <meyering@lucent.com>
28337
28338         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
28339         of local `inptr' to avoid warning with some system declarations of
28340         iconv.
28341
28342 2001-01-02  Volker Borchert  <bt@teknon.de>
28343
28344         * m4/rename.m4: New file.
28345         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
28346
28347 2001-01-01  Jim Meyering  <meyering@lucent.com>
28348
28349         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
28350         even on systems with utmpx.h.  It's necessary for the declaration of
28351         utmp's ut_user member.  Reported by Andreas Jaeger.
28352
28353         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
28354         available. They are required for the declarations of getgrgid and
28355         getpwuid resp.
28356         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
28357         Reported by Andreas Jaeger.
28358
28359 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
28360
28361         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
28362         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
28363         so `make install' also works in VPATH builds.
28364
28365 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
28366
28367         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
28368         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
28369         can be used in subdirectories.
28370
28371 2000-12-29  Paul Eggert  <eggert@twinsun.com>
28372
28373         * lib/modechange.c: Do not assume that mode_t uses the
28374         traditional octal encoding.  E.g. "chmod 1 FOO" should set
28375         the other-execute bit of FOO even if S_IXOTH != 1.
28376
28377         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
28378         WOTH, XOTH, ALLM): New macros.
28379         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
28380          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
28381         Use them.
28382         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
28383         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
28384         (mode_compile):
28385         No need to use uintmax_t; unsigned long is long enough.
28386         Don't bother to get suffix since we don't use it.
28387
28388 2000-12-26  Jim Meyering  <meyering@lucent.com>
28389
28390         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
28391         better with autoheader.
28392
28393 2000-12-24  Jim Meyering  <meyering@lucent.com>
28394
28395         * lib/hash.c (is_prime): Return explicit boolean values.
28396         (hash_get_first): Return NULL to appease Irix5.6's 89.
28397         Reported by Nelson Beebe.
28398
28399 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
28400
28401         * lib/localcharset.c (locale_charset): Add support for Win32.
28402
28403 2000-12-18  Paul Eggert  <eggert@twinsun.com>
28404
28405         * lib/physmem.h, lib/physmem.c: New files.
28406
28407         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
28408         (noinst_HEADERS): Add physmem.h.
28409
28410         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
28411         't' for compatibility with Solaris 8 sort.
28412
28413 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
28414
28415         * lib/config.charset: Add support for BeOS.
28416
28417 2000-12-17  Jim Meyering  <meyering@lucent.com>
28418
28419         * m4/dos.m4 (jm_AC_DOS): New file and macro.
28420         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
28421
28422 2000-12-16  Jim Meyering  <meyering@lucent.com>
28423
28424         This bug had a serious impact on chown: `chown N:M FILE' (for integer
28425         N and M) would have treated it like `chown N:N FILE'.
28426
28427         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
28428
28429 2000-12-16  Jim Meyering  <meyering@lucent.com>
28430
28431         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
28432         SHELLS_FILE to a file name that's useful on djgpp systems.
28433         Include stdlib.h.
28434         (ADDITIONAL_DEFAULT_SHELLS): Define.
28435         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
28436         Based mostly on a patch from Prashant TR.
28437
28438 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
28439
28440         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
28441         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
28442         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
28443
28444 2000-12-08  Andreas Schwab  <schwab@suse.de>
28445
28446         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
28447         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
28448
28449 2000-12-07  Jim Meyering  <meyering@lucent.com>
28450
28451         * lib/stripslash.c (ISSLASH): Define.
28452         (strip_trailing_slashes): Use ISSLASH rather than comparing against
28453         `/'.
28454         From Prashant TR.
28455
28456         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
28457         (dir_name_r): Declare this function as static.
28458         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
28459         manifest itself on a name containing a mix of slashes and
28460         backslashes.
28461         Make this function work with names starting with a DOS-style
28462         drive letter and colon prefix.
28463         (dir_name): Append `.' if necessary.
28464         Based mostly on patches from Prashant TR and Eli Zaretskii.
28465
28466         * lib/dirname.h (dir_name_r): Remove prototype.
28467
28468 2000-12-06  Paul Eggert  <eggert@twinsun.com>
28469
28470         * m4/off_t-format.m4: Remove this file.
28471         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
28472
28473 2000-12-06  Jim Meyering  <meyering@lucent.com>
28474
28475         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
28476         replacement strtoull, we may well need the replacement strtoul, too.
28477         Check for declarations of strtoul and strtoull.
28478         Check for strtol.  Mainly as a cue to cause automake to include
28479         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
28480         Check for limits.h -- strtol.c needs it.
28481
28482 2000-12-05  Jim Meyering  <meyering@lucent.com>
28483
28484         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
28485
28486 2000-12-04  Jim Meyering  <meyering@lucent.com>
28487
28488         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
28489         Also include memory.h, stdlib.h, unistd.h if appropriate.
28490         Reported by Andreas Jaeger (conflicting declaration of malloc).
28491
28492 2000-12-02  Jim Meyering  <meyering@lucent.com>
28493
28494         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
28495         * m4/jm-macros.m4 (jm_MACROS): require it.
28496
28497 2000-12-02  Jim Meyering  <meyering@lucent.com>
28498
28499         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
28500
28501 2000-12-01  Paul Eggert  <eggert@twinsun.com>
28502
28503         * lib/memrchr.c: Include <config.h> before any system include file.
28504
28505 2000-11-30  Jim Meyering  <meyering@lucent.com>
28506
28507         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
28508
28509 2000-11-30  Jim Meyering  <meyering@lucent.com>
28510
28511         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
28512
28513 2000-11-29  Paul Eggert  <eggert@twinsun.com>
28514
28515         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
28516
28517 2000-11-26  Jim Meyering  <meyering@lucent.com>
28518
28519         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
28520
28521 2000-11-22  Paul Eggert  <eggert@twinsun.com>
28522
28523         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
28524         size of (size_t) -1; it's not portable.
28525
28526 2000-11-17  Jim Meyering  <meyering@lucent.com>
28527
28528         * lib/strstr.c: Update from GNU libc.
28529
28530 2000-11-17  Akim Demaille  <akim@epita.fr>
28531
28532         * lib/obstack.h: Formatting changes.
28533         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
28534         prevent type checking.
28535         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
28536         cast the value to (void *): assigning a `foo *' to a `void *'
28537         variable is valid.
28538         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
28539
28540 2000-11-16  Jim Meyering  <meyering@lucent.com>
28541
28542         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
28543
28544 2000-11-11  Jim Meyering  <meyering@lucent.com>
28545
28546         * lib/error.c: Add a couple #includes, merging from GNU libc version.
28547
28548 2000-11-10  Jim Meyering  <meyering@lucent.com>
28549
28550         * lib/obstack.h: Update from GNU libc.
28551         * lib/obstack.c: Likewise.
28552
28553 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
28554
28555         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
28556
28557 2000-11-06  Paul Eggert  <eggert@twinsun.com>
28558
28559         * lib/getusershell.c (setusershell): Use rewind rather than
28560         fseek/fseeko, to avoid configuration hassles with fseeko.
28561         Don't bother opening SHELLS_FILE if shellstream is NULL;
28562         it's not necessary.
28563
28564 2000-11-05  Jim Meyering  <meyering@lucent.com>
28565
28566         * lib/makepath.h (make_dir): Declare.
28567         * lib/makepath.c (make_dir): Remove `static' attribute.
28568         Tweak a comment.
28569
28570 2000-11-04  Jim Meyering  <meyering@lucent.com>
28571
28572         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
28573
28574 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
28575
28576         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
28577         last one in a bucket, advance to the next bucket.
28578
28579 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
28580
28581         * lib/fnmatch.c: Do not comment out all the code if we are using
28582         the GNU C library, because in some cases we are replacing buggy
28583         code in the GNU C library itself.
28584
28585 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
28586
28587         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
28588         (regex_compile): Catch bogus \(\1\).
28589
28590 2000-10-30  Paul Eggert  <eggert@twinsun.com>
28591
28592         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
28593         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
28594         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
28595
28596 2000-10-30  Paul Eggert  <eggert@twinsun.com>
28597
28598         * lib/error.h, getline.h, modechange.h:
28599         Remove "2000" from Copyright line, as the file hasn't been
28600         changed this year other than in the copyright notice.
28601
28602         * lib/xalloc.h: Add "2000" to Copyright line, as this file
28603         was changed this year.
28604
28605 2000-10-29  Jim Meyering  <meyering@lucent.com>
28606
28607         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
28608         renaming.
28609         * m4/ls-mntd-fs.m4: Likewise
28610
28611 2000-10-29  Jim Meyering  <meyering@lucent.com>
28612
28613         * lib/xstat.in: Fix grammar in comment.
28614
28615 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
28616
28617         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
28618         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
28619         doesn't define __restrict_arr.
28620
28621 2000-10-28  Jim Meyering  <meyering@lucent.com>
28622
28623         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
28624         (jm_PREREQ_MEMCHR): New function.
28625
28626 2000-10-28  Jim Meyering  <meyering@lucent.com>
28627
28628         * lib/memchr.c: Update from libc.
28629         Adjust for portability:
28630         [HAVE_STDLIB_H]: Include stdlib.h.
28631         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
28632         Undef __memchr, too.
28633         [!weak_alias]: Define __memchr to memchr.
28634
28635         * lib/regex.c: Update from libc.
28636         * lib/regex.h: Likewise.
28637         * lib/getopt1.c: Likewise.
28638         * lib/memcmp.c: Likewise.
28639
28640         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
28641         Avoid using fseek, when possible -- it's broken by design.
28642         Patch by Ulrich Drepper.
28643
28644 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
28645
28646         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
28647         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
28648         Giving in to popular pressure to shut up the compiler with casts.
28649
28650 2000-10-26  Jim Meyering  <meyering@lucent.com>
28651
28652         * lib/strftime.c: Update from libc.
28653
28654 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
28655
28656         * regex.c: More `unsigned char' -> `re_char' changes.
28657         Also change several `int' into `re_wchar_t'.
28658         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
28659         (PUSH_FAILURE_POINTER): Don't cast any more.
28660         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
28661         We want GCC to complain, since this piece of code makes
28662         re_match non-reentrant, which *should* be fixed.
28663         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
28664         (EXTEND_BUFFER): Use RETALLOC.
28665         (SET_LIST_BIT): Don't cast.
28666         (re_wchar_t): New type.
28667         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
28668         that those two functions will always properly return.
28669         (IMMEDIATE_QUIT_CHECK): Cast to void.
28670         (analyse_first): Use recursion rather than an explicit stack.
28671         (re_compile_fastmap): Can't fail anymore.
28672         (re_search_2): Don't check re_compile_fastmap for failure.
28673         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
28674         Now also sets the new value (passed in a new argument).
28675         (re_match_2_internal): Use it.
28676         Also, use a new var `reg' of type size_t when looping through regs
28677         rather than reuse the inappropriate `mcnt'.
28678
28679 2000-10-25  Jim Meyering  <meyering@lucent.com>
28680
28681         * lib/obstack.c: Update from libc.
28682
28683 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
28684
28685         * regex.c (regex_compile): Change the way of handling a range from
28686         a char less than 256 to a char not less than 256.
28687
28688 2000-10-24  Andrew Innes  <andrewi@gnu.org>
28689
28690         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
28691         NT-Emacs only.
28692         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
28693         so that re_search functions only quit when callers expect them to.
28694
28695 2000-10-23  Jim Meyering  <meyering@lucent.com>
28696
28697         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
28698         wrong.  That set_locale call must not have any side effects.
28699         From Paul Eggert.
28700
28701 2000-10-22  Jim Meyering  <meyering@lucent.com>
28702
28703         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
28704         [CYCLIC]: Remove now-unused definition.
28705
28706         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
28707         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
28708         Suggestion from Ulrich Drepper.
28709
28710 2000-10-21  Jim Meyering  <meyering@lucent.com>
28711
28712         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
28713         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
28714         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
28715
28716 2000-10-21  Jim Meyering  <meyering@lucent.com>
28717
28718         * lib/dirname.c (memrchr): Declare if necessary.
28719         (dir_name): Remove the restriction that there be no
28720         trailing slashes.  Now, this code skips past them, effectively
28721         ignoring them.
28722         [TEST_DIRNAME] (main): New unit tests.
28723
28724         * lib/memrchr.c: New file from GNU libc.
28725         Undef __memrchr, too.
28726         [!weak_alias]: Define __memrchr to memrchr.
28727         Guard weak_alias use with `#ifdef weak_alias'.
28728
28729 2000-10-21  Jim Meyering  <meyering@lucent.com>
28730
28731         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
28732         (dir_name): Use dir_name_r.
28733         * lib/dirname.h (dir_name_r): Declare it.
28734
28735 2000-10-17  Jim Meyering  <meyering@lucent.com>
28736
28737         * lib/quote.h (PARAMS): Define and use.
28738         Reported by Akim Demaille.
28739
28740         * lib/getopt.c: Update from libc.
28741
28742 2000-10-16  Jim Meyering  <meyering@lucent.com>
28743
28744         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
28745         setlocale.
28746         From Jan Fedak.
28747
28748 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
28749
28750         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
28751
28752 2000-09-25  Jim Meyering  <meyering@lucent.com>
28753
28754         * lib/md5.h (rol): Define (from GnuPG).
28755
28756         * lib/sha.c: Give credit (GnuPG) where due.
28757         (M): Use rol rather than open-coding it.
28758         Add a FIXME comment.
28759
28760 2000-09-21  Jim Meyering  <meyering@lucent.com>
28761
28762         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
28763         Reported by Michael Stone.
28764
28765 2000-09-20  Jim Meyering  <meyering@lucent.com>
28766
28767         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
28768         (noinst_HEADERS): Add sha.h.
28769         Based on code from Scott G. Miller and from GnuPG.
28770
28771 2000-09-18  Jim Meyering  <meyering@lucent.com>
28772
28773         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
28774         LIBS. Otherwise, everyone ends up linking with -lelf for some
28775         configurations.
28776         Reported by Mike Stone.
28777
28778 2000-09-15  Jim Meyering  <meyering@lucent.com>
28779
28780         * lib/regex.c: Update from libc.
28781
28782 2000-09-10  Jim Meyering  <meyering@lucent.com>
28783
28784         * lib/getopt.c (_getopt_internal): Update from glibc.
28785
28786 2000-09-09  Jim Meyering  <meyering@lucent.com>
28787
28788         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
28789         think it should be used as a general replacement for isascii.
28790         * lib/fnmatch.c: Likewise.
28791         * lib/mbswidth.c: Likewise
28792         * lib/regex.c: Likewise.
28793
28794         Don't use atoi.
28795         * lib/userspec.c: Include sys/param.h and limits.h.
28796         Include xstrtol.h.
28797         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
28798         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
28799         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
28800         UID, GID.  Check range.
28801
28802 2000-09-06  Jim Meyering  <meyering@lucent.com>
28803
28804         * lib/getopt.c (_getopt_internal): Update from glibc.
28805
28806 2000-08-30  Jim Meyering  <meyering@lucent.com>
28807
28808         * lib/strftime.c: Merge in changes from GNU libc.
28809
28810 2000-08-26  Jim Meyering  <meyering@lucent.com>
28811
28812         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
28813         * m4/fpending.m4: New file.
28814
28815 2000-08-26  Jim Meyering  <meyering@lucent.com>
28816
28817         * lib/closeout.c: Include "__fpending.h".
28818         (close_stdout_status): Return right away if there's nothing to flush.
28819
28820         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
28821         * lib/__fpending.c: New file.
28822         * lib/__fpending.h: New file.
28823
28824 2000-08-20  Jim Meyering  <meyering@lucent.com>
28825
28826         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
28827         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
28828         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
28829
28830 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
28831
28832         Improve fileutils installation on systems where running
28833         programs (like install) can't be unlinked.
28834         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
28835         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
28836
28837 2000-08-07  Paul Eggert  <eggert@twinsun.com>
28838
28839         Standardize on "memory exhausted" instead of "Memory exhausted"
28840         or "virtual memory exhausted".
28841         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
28842         "virtual memory exhausted".
28843         * lib/same.c (same_name): Invoke xalloc_die instead of printing
28844         our own message.
28845         * lib/userspec.c (parse_user_spec): Likewise.
28846         * lib/bumpalloc.h: comment fix
28847         * lib/same.c, userspec.c: Include xalloc.h.
28848
28849         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
28850         not char *const and pointing to a constant array.
28851         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
28852         (xrealloc): Comment fix.
28853
28854         * lib/userspec.c (parse_user_spec):
28855         Don't translate a message until just before returning,
28856         to avoid unnecessary translation.
28857
28858 2000-08-07  Jim Meyering  <meyering@lucent.com>
28859
28860         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
28861         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
28862         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
28863         getgroups.c, gethostname.c, getopt.h, group-member.c,
28864         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
28865         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
28866         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
28867         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
28868         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
28869         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
28870         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
28871         yesno.c: Back out Copyright date changes for each file with no change
28872         this year.  This eases coordination with other programs using the same
28873         source code modules.  From Paul Eggert.
28874
28875 2000-08-06  Paul Eggert  <eggert@twinsun.com>
28876
28877         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
28878         not char, for compatibility with glibc 2.1.3 strftime.c.
28879
28880 2000-08-03  Greg McGary  <greg@mcgary.org>
28881
28882         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
28883         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
28884         (EXTEND_BUFFER): Use them.
28885
28886 2000-08-01  Jim Meyering  <meyering@lucent.com>
28887
28888         * lib/dirname.c (ISSLASH): Define.
28889         (BACKSLASH_IS_PATH_SEPARATOR): Define.
28890         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
28891         both `\' and `/' may be use as path separators.
28892         Based on a patch from Prashant TR.
28893
28894 2000-07-31  Paul Eggert  <eggert@twinsun.com>
28895
28896         * lib/quotearg.c (quotearg_n_options): Don't make the initial
28897         slot vector a constant, since it might get modified.
28898
28899 2000-07-31  Jim Meyering  <meyering@lucent.com>
28900
28901         * lib/xmalloc.c: Use `virtual memory exhausted', not
28902         `Memory exhausted'.
28903         * lib/obstack.c (print_and_abort): Likewise.
28904
28905 2000-07-30  Paul Eggert  <eggert@twinsun.com>
28906
28907         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
28908         buffer, so that the caller can always quote one small
28909         component of a "memory exhausted" message in slot 0.
28910         From a suggestion by Jim Meyering.
28911
28912 2000-07-30  Jim Meyering  <meyering@lucent.com>
28913
28914         * lib/makepath.c (make_path): Quote the other instance, too.
28915
28916         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
28917         (STATIC_BUF_SIZE): Define.
28918         (quotearg_n_options): Use only statically allocated storage when
28919         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
28920         than STATIC_BUF_SIZE.
28921
28922 2000-07-29  Jim Meyering  <meyering@lucent.com>
28923
28924         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
28925         * lib/dirname.c (dir_name): Likewise.
28926
28927         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
28928         `/'.
28929
28930         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
28931         (dir_name): Assert that there are no trailing slashes.
28932
28933 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
28934
28935         * lib/mbswidth.h (mbswidth): Add a flags argument.
28936         (mbswidth): New declaration.
28937         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
28938         * lib/mbswidth.c (mbswidth): Add a flags argument.
28939         (mbsnwidth): New function.
28940
28941 2000-07-24  Jim Meyering  <meyering@lucent.com>
28942
28943         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
28944
28945 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28946
28947         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
28948
28949 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28950
28951         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
28952         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
28953         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
28954         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
28955         invoke multibyte primitives.
28956
28957 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28958
28959         * lib/quotearg.c:
28960         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
28961         so that mbstate_t is always defined.
28962
28963         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
28964         be 1 in at least one GCC installation, and this configuration
28965         error is likely to be common.  Ignoring MB_LEN_MAX hurts
28966         performance on hosts that have mbrtowc but have only unibyte
28967         locales, but I assume these hosts are rare.
28968
28969 2000-07-23  Paul Eggert  <eggert@twinsun.com>
28970
28971         * lib/mbswidth.c (_XOPEN_SOURCE):
28972         Don't define; this causes problems on Solaris 7.
28973         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
28974
28975 2000-07-23  Jim Meyering  <meyering@lucent.com>
28976
28977         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
28978         too: getgrgid, getpwuid, getuid.
28979
28980 2000-07-23  Jim Meyering  <meyering@lucent.com>
28981
28982         * lib/basename.c (base_name): Add an assertion.
28983
28984 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
28985
28986         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
28987         shadow its mbsinit function.
28988
28989 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
28990
28991         * lib/mbswidth.h: New file.
28992         * lib/mbswidth.c: New file.
28993         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
28994         (noinst_HEADERS): Add mbswidth.h.
28995
28996 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
28997
28998         * lib/config.charset: Add support for FreeBSD. Improve support for
28999         HP-UX and IRIX 6.
29000
29001 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
29002
29003         * m4/mbswidth.m4: New file.
29004         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
29005
29006 2000-07-15  Jim Meyering  <meyering@lucent.com>
29007
29008         * lib/makepath.c: Include quote.h.
29009         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
29010         corresponding argument in a `quote (...)' call.
29011         Give better diagnostics.
29012
29013         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
29014         (noinst_HEADERS): Add quote.h.
29015
29016         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
29017         from tar's src/misc.c.
29018         * lib/quote.h: New file.  Prototypes for same.
29019
29020 2000-07-14  Paul Eggert  <eggert@twinsun.com>
29021
29022         From a suggestion by Bruno Haible.
29023         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
29024         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
29025         to decide whether to define the BeOS workaround macro;
29026         this adjusts to the change to AC_MBSTATE_T.
29027
29028 2000-07-14  Jim Meyering  <meyering@lucent.com>
29029
29030         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
29031         jm_AC_TYPE_UINTMAX_T.
29032
29033 2000-07-13  Paul Eggert  <eggert@twinsun.com>
29034
29035         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
29036
29037         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
29038         quotearg_buffer_restyled): Add support for
29039         clocale_quoting_style.  Undo previous change to
29040         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
29041         and "{RIGHT QUOTATION MARK}" msgids.
29042
29043 2000-07-10  Paul Eggert  <eggert@twinsun.com>
29044
29045         From a suggestion by Bruno Haible.
29046         * m4/mbstate_t.m4 (AC_MBSTATE_T):
29047         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
29048         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
29049         and mbstate_t, to a single-part test that simply defines mbstate_t.
29050         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
29051         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
29052
29053 2000-07-10  Jim Meyering  <meyering@lucent.com>
29054
29055         * m4/strerror_r.m4: Mirror the correction made in autoconf.
29056
29057         * m4/gnu-source.m4: Output to confdefs.h directly.
29058         Suggestion from Akim Demaille.
29059
29060 2000-07-09  Paul Eggert  <eggert@twinsun.com>
29061
29062         The old behavior of quoting `like this' doesn't look good with
29063         newer, ISO-style fonts.  See:
29064         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
29065
29066         Instead, quote "like this" by default.  Let the translator
29067         tailor the locale-specific quoting behavior by providing
29068         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
29069
29070         * lib/quotearg.c (N_): New macro.
29071         (gettext_default): New function.
29072         (quotearg_buffer_restyled): Use
29073         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
29074         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
29075
29076 2000-07-09  Jim Meyering  <meyering@lucent.com>
29077
29078         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
29079         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
29080
29081         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
29082         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
29083
29084 2000-07-09  Jim Meyering  <meyering@lucent.com>
29085
29086         * lib/Most files: Update copyright dates to include 2000.
29087
29088 2000-07-08  Jim Meyering  <meyering@lucent.com>
29089
29090         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
29091         if not defined.
29092         (xgethostname): Remove now-unnecessary #ifdef.
29093         Move declaration of `err' into loop where it's used.
29094
29095 2000-07-05  Paul Eggert  <eggert@twinsun.com>
29096         and Bruno Haible  <haible@clisp.cons.org>
29097
29098         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
29099         only if the test for an object-type mbstate_t fails.  This
29100         prevents us from mistakenly reporting that mbstate_t is a
29101         system object type after we "#define mbstate_t int" to work
29102         around its lack.
29103
29104 2000-07-05  Paul Eggert  <eggert@twinsun.com>
29105         and Bruno Haible  <haible@clisp.cons.org>
29106
29107         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
29108
29109 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
29110
29111         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
29112         to strerror_r.
29113         Include <ctype.h> for use of isalpha.
29114
29115 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
29116
29117         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
29118         by allocating a larger buffer. Test the gethostname return value for
29119         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
29120         returns an error and ENAMETOOLONG isn't defined.
29121
29122 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
29123
29124         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
29125         dimension.
29126
29127 2000-07-04  Jim Meyering  <meyering@lucent.com>
29128
29129         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
29130         of the deprecated AC_CHECKING.
29131
29132 2000-07-04  Jim Meyering  <meyering@lucent.com>
29133
29134         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
29135         Reported by Bruno Haible.
29136
29137 2000-07-04  Jim Meyering  <meyering@lucent.com>
29138
29139         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
29140         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
29141         lacks mbrtowc.
29142
29143 2000-07-03  Paul Eggert  <eggert@twinsun.com>
29144
29145         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
29146         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
29147
29148 2000-07-03  Paul Eggert  <eggert@twinsun.com>
29149         and Bruno Haible  <haible@clisp.cons.org>
29150
29151         * lib/quotearg.c (mbrtowc):
29152         Assign to *pwc, and return 1 only if result is nonzero.
29153         (iswprint): Use ISPRINT when substituting our own mbrtowc.
29154
29155 2000-07-03  Jim Meyering  <meyering@lucent.com>
29156
29157         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
29158
29159 2000-07-03  Jim Meyering  <meyering@lucent.com>
29160
29161         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
29162         This is necessary to get a definition of e.g., UTMP_FILE on
29163         HP-UX 10.20.
29164         From Bob Proulx.
29165
29166 2000-07-02  Jim Meyering  <meyering@lucent.com>
29167
29168         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
29169
29170         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
29171         AC_LIBOBJ(function_name).
29172         * m4/chown.m4: Likewise.
29173         * m4/fnmatch.m4: Likewise.
29174         * m4/ftruncate.m4: Likewise.
29175         * m4/getgroups.m4: Likewise.
29176         * m4/getline.m4: Likewise.
29177         * m4/group-member.m4: Likewise.
29178         * m4/jm-macros.m4: Likewise.
29179         * m4/lstat.m4: Likewise.
29180         * m4/malloc.m4: Likewise.
29181         * m4/memcmp.m4: Likewise.
29182         * m4/nanosleep.m4: Likewise.
29183         * m4/putenv.m4: Likewise.
29184         * m4/realloc.m4: Likewise.
29185         * m4/regex.m4: Likewise.
29186         * m4/stat.m4: Likewise.
29187         * m4/strftime.m4: Likewise.
29188
29189 2000-07-02  Jim Meyering  <meyering@lucent.com>
29190
29191         * lib/quotearg.c (mbstate_t): Don't define here.
29192
29193 2000-07-02  Jim Meyering  <meyering@lucent.com>
29194
29195         * lib/nanosleep.c (SIGCONT): Define if not already defined.
29196
29197 2000-07-01  Jim Meyering  <meyering@lucent.com>
29198
29199         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
29200
29201 2000-07-01  Jim Meyering  <meyering@lucent.com>
29202
29203         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
29204         problem.
29205
29206 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
29207
29208         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
29209         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
29210
29211 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
29212
29213         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
29214         per change in ../m4/ls-mntd-fs.m4.
29215         (read_filesystem_list): Ignore symbolic links.
29216
29217 2000-06-29  Jim Meyering  <meyering@lucent.com>
29218
29219         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
29220         for declaration of strcmp.
29221
29222         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
29223
29224         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
29225         Avoid warning by casting result to `char *' to remove `const'.
29226
29227 2000-06-28  Jim Meyering  <meyering@lucent.com>
29228
29229         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
29230         included by quotearg.c, for which we perform this test.  From
29231         Bruno Haible.
29232
29233 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
29234
29235         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
29236         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
29237         <utmpx.h> exists, put readutmp.o into LIBOBJS.
29238
29239 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
29240
29241         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
29242
29243 2000-06-26  Paul Eggert  <eggert@twinsun.com>
29244
29245         savedir now sets errno on failure and invokes xmalloc to get memory.
29246         Fix a couple of other minor bugs while we're at it.
29247
29248         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
29249         (NAMLEN): Remove macro.
29250         (malloc, realloc): Remove decls.
29251         (stpcpy): Likewise.
29252         ("xalloc.h"): Include.
29253         (NAME_SIZE_DEFAULT): New macro.
29254         (savedir): Use xmalloc / xrealloc to allocate memory.
29255         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
29256         Skip "" directory entries.
29257         Use strlen to calculate directory entry length, since the old method
29258         is rarely used these days and isn't worth supporting.
29259         Don't use a pointer after freeing it.
29260         Check for integer overflow when calculating allocation size.
29261         Use memcpy to copy entries, instead of stpcpy.
29262         Set errno properly when returning NULL.
29263         Check for readdir error.
29264
29265 2000-06-26  Jim Meyering  <meyering@lucent.com>
29266
29267         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
29268
29269 2000-06-25  Jim Meyering  <meyering@lucent.com>
29270
29271         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
29272         Linux header bug when _XOPEN_SOURCE is defined to 500.
29273
29274 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
29275
29276         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
29277         deficiency.
29278
29279 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
29280
29281         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
29282         Include xalloc.h.
29283         Don't include <stdlib.h>.  Don't declare malloc, realloc.
29284
29285 2000-06-24  Jim Meyering  <meyering@lucent.com>
29286
29287         * m4/strerror_r.m4: Revive this file -- to try out an experimental
29288         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
29289         for which strerror does return char*, but which lacks a conveniently
29290         accessible declaration of the function.  If the compile-test says
29291         strerror_r doesn't work, then resort to a `run'-test that works on
29292         BeOS and segfaults on DEC Unix.
29293
29294 2000-06-24  Jim Meyering  <meyering@lucent.com>
29295
29296         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
29297
29298 2000-06-23  Paul Eggert  <eggert@twinsun.com>
29299
29300         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
29301         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
29302
29303 2000-06-23  Paul Eggert  <eggert@twinsun.com>
29304
29305         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
29306         (mbrtowc, mbstate_t): Define substitutes if
29307         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
29308         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
29309         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
29310
29311 2000-06-23  Jim Meyering  <meyering@lucent.com>
29312
29313         * m4/afs.m4: Add missing AC_MSG_RESULT.
29314         Reported by Bruno Haible.
29315
29316         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
29317         Suggestion from Bruno Haible.
29318
29319 2000-06-23  Jim Meyering  <meyering@lucent.com>
29320
29321         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
29322
29323 2000-06-21  Jim Meyering  <meyering@lucent.com>
29324
29325         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
29326
29327 2000-06-21  Jim Meyering  <meyering@lucent.com>
29328
29329         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
29330         (noinst_HEADERS): Add getstr.h.
29331
29332         * lib/getline.c (getstr): Move into a separate file.
29333         * lib/getstr.c (getstr): New file, extracted from getline.c, with
29334         the following changes: new parameter, delim2; both delim[12]
29335         parameters have type `int', not `char'.  The latter would lose
29336         with 8-bit delimiters.
29337         * lib/getstr.h: New file.
29338
29339 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
29340
29341         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
29342         than 1024, return a memory chunk of least possible size, instead
29343         of size PATH_MAX + 2. In the loop, increment the size proportionally.
29344         Use free/xmalloc instead of xrealloc to avoid copying for very long
29345         paths.
29346
29347 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
29348
29349         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
29350         the empty string.
29351
29352 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
29353
29354         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
29355         address, not strdup.  Include <stdlib.h> and don't declare free().
29356
29357 2000-06-19  Jim Meyering  <meyering@lucent.com>
29358
29359         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
29360
29361 2000-06-18  Jim Meyering  <meyering@lucent.com>
29362
29363         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
29364
29365         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
29366         `checking whether...' message to be consistent with that of the
29367         lstat test.
29368
29369 2000-06-18  Jim Meyering  <meyering@lucent.com>
29370
29371         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
29372         Besides, these days every porting target provides a mkdir function.
29373
29374         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
29375         needed. (this snippet comes from src/system.h).
29376
29377 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
29378
29379         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
29380
29381 2000-06-15  Paul Eggert  <eggert@twinsun.com>
29382
29383         * lib/human.c (adjust_value): New function.
29384         (human_readable_inexact): Apply rounding style even when
29385         printing approximate values.
29386
29387 2000-06-14  Paul Eggert  <eggert@twinsun.com>
29388
29389         * lib/human.c (human_readable_inexact): Allow an input block
29390         size that is not a multiple of the output block size, and vice versa.
29391         Reported by Piergiorgio Sartor.
29392
29393 2000-06-14  Paul Eggert  <eggert@twinsun.com>
29394
29395         * lib/getdate.y (get_date): Apply relative times after time
29396         zone indicator, not before.  Reported by Todd A. Jacobs.
29397
29398 2000-06-13  Jim Meyering  <meyering@lucent.com>
29399
29400         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
29401
29402         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
29403
29404 2000-06-12  Paul Eggert  <eggert@twinsun.com>
29405
29406         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
29407
29408 2000-06-12  Jim Meyering  <meyering@lucent.com>
29409
29410         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
29411         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
29412         optional argument.
29413         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
29414         the optional argument, `lib'.
29415
29416 2000-06-08  Jim Meyering  <meyering@lucent.com>
29417
29418         * m4/largefile.m4: Remove file (now that it's part of autoconf).
29419
29420 2000-06-04  Paul Eggert  <eggert@twinsun.com>
29421
29422         Rewrite largefile configuration so that we don't need to run
29423         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
29424         AC_CANONICAL_HOST in configure.in -- jmm]
29425
29426         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
29427         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
29428         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
29429         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
29430         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
29431         All uses changed.
29432         Instead of inspecting the output of getconf, try to compile the
29433         test program without and with the macro definition.
29434         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
29435         for getconf.  Instead, check for the needed flags by compiling
29436         test programs.
29437
29438 2000-06-04  Paul Eggert  <eggert@twinsun.com>
29439
29440         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
29441
29442 2000-06-04  Jim Meyering  <meyering@lucent.com>
29443
29444         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
29445         SunOS 4.1.4 for which gid_t is an unsigned type.
29446
29447 2000-06-03  Jim Meyering  <meyering@lucent.com>
29448
29449         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
29450         now that autoconf requires that.
29451
29452         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
29453         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
29454         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
29455
29456 2000-06-03  Jim Meyering  <meyering@lucent.com>
29457
29458         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
29459
29460 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
29461
29462         * m4/glibc21.m4: New file.
29463         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
29464
29465 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
29466
29467         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
29468         newer, don't install charset.alias.
29469         * lib/config.charset: Change the Linux/glibc rules so they become empty
29470         on glibc-2.1 or newer.
29471
29472 2000-06-02  Jim Meyering  <meyering@lucent.com>
29473
29474         * lib/mountlist.c: Back out last change.  Instead, do this...
29475         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
29476         me_dummy member using the same `ignore'-testing code.
29477         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
29478         fs_type strings.
29479         From Mark D. Roth.
29480
29481 2000-05-29  Jim Meyering  <meyering@lucent.com>
29482
29483         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
29484         mounts with the `ignore' attribute.  Based on a patch from
29485         Mark D. Roth.
29486
29487 2000-05-28  Jim Meyering  <meyering@lucent.com>
29488
29489         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
29490         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29491         * m4/stat.m4: Likewise.
29492         * m4/lstat.m4: Likewise.
29493         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
29494
29495         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
29496         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
29497
29498 2000-05-26  Jim Meyering  <meyering@lucent.com>
29499
29500         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
29501
29502 2000-05-24  Jim Meyering  <meyering@lucent.com>
29503
29504         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
29505         autoconf requires that.
29506         * m4/lib-check.m4: Likewise.
29507         * m4/jm-macros.m4: Likewise.
29508         * m4/strftime.m4: Likewise.
29509
29510         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
29511         AC_CHECK_DECLS, now that autoconf requires that.
29512
29513 2000-05-22  Jim Meyering  <meyering@lucent.com>
29514
29515         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29516         * m4/lstat.m4: Likewise.
29517
29518 2000-05-22  Jim Meyering  <meyering@lucent.com>
29519
29520         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
29521
29522 2000-05-20  Jim Meyering  <meyering@lucent.com>
29523
29524         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
29525         (jm_PREREQ): Use it.
29526
29527 2000-05-18  Jim Meyering  <meyering@lucent.com>
29528
29529         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
29530         back, too, since it may have been modified by allocate_entry.
29531         (hash_delete): Rewrite to use neither the assignment operator
29532         nor the comma operator in an if-expression.
29533
29534 2000-05-15  Paul Eggert  <eggert@twinsun.com>
29535
29536         * lib/closeout.c:
29537         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
29538         Remove; no longer needed.
29539         "quotearg.h": Add include.
29540         (file_name): Do not bother to explicitly initialize to NULL; it's less
29541         efficient on some hosts.
29542         (close_stdout_status): Remove test as to whether stdout was already
29543         closed; it breaks for the case "echo x | sort >&-".
29544         Quote file name colons.
29545         Do not assume that _("write error") lacks format strings.
29546
29547 2000-05-15  Jim Meyering  <meyering@lucent.com>
29548
29549         * lib/version-etc.c (version_etc_copyright): Update the copyright
29550         string used in all --version output.
29551
29552 2000-05-14  Jim Meyering  <meyering@lucent.com>
29553
29554         * lib/closeout.c (close_stdout_set_file_name): New function.
29555         (close_stdout_status): Use new file-scoped global.
29556         Return right away if fstat says the stdout file descriptor is invalid.
29557         * lib/closeout.h (close_stdout_set_file_name): Declare.
29558
29559 2000-05-10  Jim Meyering  <meyering@lucent.com>
29560
29561         * lib/closeout.c [default_exit_status]: New file-scoped variable.
29562         (close_stdout_set_status): New function.
29563         * lib/closeout.h (close_stdout_set_status): Declare.
29564
29565 2000-05-09  Jim Meyering  <meyering@lucent.com>
29566
29567         * m4/gettext.m4: Rename this...
29568         * m4/libintl.m4: ...to this.
29569
29570 2000-05-08  Jim Meyering  <meyering@lucent.com>
29571
29572         * lib/long-options.c: Don't include closeout.h.
29573         (parse_long_options): Don't call close_stdout for --version.
29574
29575 2000-05-06  Paul Eggert  <eggert@twinsun.com>
29576
29577         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
29578         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
29579         2.1.3 bug.  This avoids a clash when files like regex.c define
29580         _GNU_SOURCE.
29581
29582 2000-05-06  Jim Meyering  <meyering@lucent.com>
29583
29584         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
29585         (AC_REPLACE_FUNCS): Add strnlen.
29586
29587         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
29588         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
29589
29590         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
29591         AC_SEARCH_LIBS call for nanosleep.
29592         (LIB_NANOSLEEP): Set and AC_SUBST.
29593
29594 2000-05-06  Jim Meyering  <meyering@lucent.com>
29595
29596         * lib/strnlen.c: Undefine __strnlen and strnlen.
29597         [!weak_alias]: Define __strnlen to strnlen.
29598
29599         * lib/atexit.c: New file, from libiberty.
29600
29601 2000-05-06  Jim Meyering  <meyering@lucent.com>
29602
29603         * lib/closeout.c (close_stdout_status): Also check for errors on the
29604         stderr stream.
29605
29606 2000-05-05  Jim Meyering  <meyering@lucent.com>
29607
29608         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
29609         AC_SEARCH_LIBS call for clock_gettime.
29610         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
29611
29612         * m4/search-libs.m4: Update from autoconf.
29613
29614         su doesn't work on Solaris 2.6.
29615         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
29616         <shadow.h>.  Reported by Dragos Harabor.
29617
29618 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
29619
29620         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
29621         memcpy instead of xmalloc, xrealloc, path_concat.
29622         (locale_charset): Treat empty environment variables as absent.
29623         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
29624
29625 2000-05-04  Jim Meyering  <meyering@lucent.com>
29626
29627         * lib/getopt.c: Update from glibc.
29628         * lib/obstack.c: Likewise.
29629         * lib/obstack.h: Likewise.
29630         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
29631         file
29632
29633         * lib/regex.h: Likewise.
29634         * lib/strndup.c: Likewise.
29635         * lib/strnlen.c: New file, from glibc.
29636
29637 2000-05-03  Jim Meyering  <meyering@lucent.com>
29638
29639         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
29640
29641 2000-05-02  Paul Eggert  <eggert@twinsun.com>
29642
29643         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
29644         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
29645         compile-time test, rather than inspecting host and OS, to
29646         decide whether to define _LARGEFILE_SOURCE.
29647
29648 2000-05-01  Jim Meyering  <meyering@lucent.com>
29649
29650         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
29651
29652         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
29653         Based on a patch from Bruno Haible.
29654
29655 2000-05-01  Jim Meyering  <meyering@lucent.com>
29656
29657         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
29658
29659 2000-04-29  Jim Meyering  <meyering@lucent.com>
29660
29661         * lib/path-concat.c: Declare strdup only if it's not defined.
29662         * lib/canon-host.c: Likewise.
29663
29664 2000-04-28  Jim Meyering  <meyering@lucent.com>
29665
29666         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
29667         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
29668         is included first, then limits.h is included by locale.h by libintl.h.
29669         From John David Anglin.
29670
29671 2000-04-25  Jim Meyering  <meyering@lucent.com>
29672
29673         * lib/makepath.c (S_IRWXUGO): Define.
29674         (make_path): Always perform explicit chmod if MODE specifies any
29675         of the `special' permission bits.  Prompted by a bug report against
29676         install from Mate Wierdl and Joost van Baal.
29677
29678 2000-04-18  Jim Meyering  <meyering@lucent.com>
29679
29680         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
29681         (jm_PREREQ): Use it.
29682
29683 2000-04-18  Jim Meyering  <meyering@lucent.com>
29684
29685         * lib/README: New file.
29686
29687         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
29688         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
29689
29690 2000-04-17  Jim Meyering  <meyering@lucent.com>
29691
29692         Get it right :-)
29693         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
29694         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
29695         Suggestion from Akim Demaille.
29696
29697 2000-04-17  Jim Meyering  <meyering@lucent.com>
29698
29699         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
29700         the definition of it to rpl_strftime also defined-away the system's
29701         declaration.
29702
29703 2000-04-15  Jim Meyering  <meyering@lucent.com>
29704
29705         Use `C' to denote so-called `contiguous' files, the same way
29706         that tar does.
29707         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
29708         (ftypelet): Use S_ISCTG.
29709         From Michael Deutschmann.
29710
29711 2000-04-14  Jim Meyering  <meyering@lucent.com>
29712
29713         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
29714         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
29715         clobbered.
29716
29717 2000-04-14  Jim Meyering  <meyering@lucent.com>
29718
29719         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
29720
29721 2000-04-13  Jim Meyering  <meyering@lucent.com>
29722
29723         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
29724         AH_VERBATIM to insert required #ifndef into config.h.in.
29725         Suggestion from Akim Demaille.
29726
29727 2000-04-12  Jim Meyering  <meyering@lucent.com>
29728
29729         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
29730         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
29731         Christian Krackowizer.
29732
29733         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
29734         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
29735         (AC_SYS_LARGEFILE): Require.
29736         (AM_C_PROTOTYPES): Require.
29737
29738 2000-04-08  Jim Meyering  <meyering@lucent.com>
29739
29740         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
29741         names don't conflict.  Reported by Eli Zaretskii.
29742
29743 2000-04-07  Jim Meyering  <meyering@lucent.com>
29744
29745         * lib/putenv.c: Move inclusion of errno.h so it follows that of
29746         sys/types.h, to work around system header problems on AIX 3.2.5.
29747         From Bruno Haible.
29748
29749 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
29750
29751         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
29752         bug.  Deal with the different error behavior of Irix iconv.
29753
29754 2000-04-05  Paul Eggert  <eggert@twinsun.com>
29755
29756         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
29757         IRIX if the installer said otherwise.
29758
29759 2000-04-05  Jim Meyering  <meyering@lucent.com>
29760
29761         Portability tweaks required for ultrix4.3.
29762         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
29763         (jm_CHECK_DECLS): Add getutent to the list of functions.
29764         (_jm_DECL_HEADERS): Add utmpx.h.
29765         From John David Anglin.
29766
29767         * m4/strftime.m4: Back out the 2000-04-02 change.
29768         Instead of that change, simply undefine putenv in the test program.
29769
29770 2000-04-05  Jim Meyering  <meyering@lucent.com>
29771
29772         Portability tweaks required for ultrix4.3.
29773         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
29774         getutent.
29775         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
29776         * lib/canon-host.c: Declare strdup.
29777         * lib/path-concat.c: Likewise.
29778         From John David Anglin.
29779
29780 2000-04-04  Jim Meyering  <meyering@lucent.com>
29781
29782         Be more DOS 8.3-friendly.
29783         * lib/ref-add.sin: Renamed from ref-add.sed.in.
29784         * lib/ref-del.sin: Renamed from ref-del.sed.in.
29785         * lib/Makefile.am: Reflect renaming.
29786         Reported by Eli Zaretskii.
29787
29788         Use a temporary file name that won't clash with `charset.alias'
29789         in the DOS 8.3 name space.
29790         * lib/Makefile.am (charset_tmp): Define.
29791         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
29792         (uninstall-local): Likewise.
29793         Reported by Eli Zaretskii.
29794
29795 2000-04-03  Jim Meyering  <meyering@lucent.com>
29796
29797         * m4/gettext.m4: Fix typo in comment.
29798
29799         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
29800         textutils/configure.in).  Suggestion from Paul Eggert.
29801         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
29802
29803 2000-04-02  Paul Eggert  <eggert@twinsun.com>
29804
29805         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
29806         variable in the shell rather than using putenv, which isn't
29807         portable.  This avoids the configure-time inter-test dependency
29808         on the potentially-renamed putenv function.
29809
29810 2000-03-30  Paul Eggert  <eggert@twinsun.com>
29811
29812         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
29813         before checking struct stat.st_blksize, so that
29814         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
29815
29816 2000-03-29  Paul Eggert  <eggert@twinsun.com>
29817
29818         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
29819         since strftime.c uses HAVE_STRFTIME to decide whether to use
29820         the underlying strftime.
29821
29822 2000-03-29  Paul Eggert  <eggert@twinsun.com>
29823
29824         * lib/time/strftime.c (my_strftime): Make sure we call the system
29825         strftime, not ourselves, when invoking the underlying strftime.
29826
29827 2000-03-24  Jim Meyering  <meyering@lucent.com>
29828
29829         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
29830         (charset_alias): Define.
29831         (install-exec-local): Factor out common code.
29832         (uninstall-local): Split lines longer than 80.
29833         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
29834         (SUFFIXES): Define.
29835         (.sed.in.sed): New rule.  Don't redirect directly to $@.
29836         (CLEANFILES): Add ref-add.sed and ref-del.sed.
29837
29838 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
29839
29840         * lib/config.charset: Output a line containing "Packages using this
29841         file".
29842         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
29843         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
29844         ref-del.sed): New rules.
29845
29846 2000-03-17  Jim Meyering  <meyering@lucent.com>
29847
29848         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
29849         Otherwise, include <strings.h>
29850
29851 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
29852
29853         * lib/unicodeio.c (utf8_wctomb): New function.
29854         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
29855         format instead of in UCS-4 with platform dependent endianness.
29856
29857 2000-03-10  Jim Meyering  <meyering@lucent.com>
29858
29859         * m4/lib-check.m4: Look for getspnam in -lgen, too.
29860         From Marco Franzen.
29861
29862 2000-03-07  Paul Eggert  <eggert@twinsun.com>
29863
29864         * lib/savedir.c (savedir): Work even if directory size is
29865         negative; this can happen with some screwy NFS configurations.
29866
29867 2000-03-06  Jim Meyering  <meyering@lucent.com>
29868
29869         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
29870         if it's NULL (because we ran out of memory).  From Bruno Haible.
29871
29872 2000-03-05  Jim Meyering  <meyering@lucent.com>
29873
29874         * lib/localcharset.c ("path-concat.h"): Include.
29875         (get_charset_aliases): Use path_concat instead of ANSI string
29876         concatenation.
29877
29878         * lib/unicodeio.h (PARAMS): Define.
29879         Use it to guard prototype.
29880
29881 2000-03-04  Jim Meyering  <meyering@lucent.com>
29882
29883         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
29884         for lib/localcharset.c.
29885
29886 2000-03-04  Jim Meyering  <meyering@lucent.com>
29887
29888         * lib/Makefile.am (install-exec-local): Create $(libdir) before
29889         installing into it.
29890         (uninstall-local): Uncomment this rule so `make distcheck' works
29891         once again.
29892
29893         * lib/unicodeio.c (<errno.h>): Include it.
29894         (errno): Declare if not defined.
29895
29896         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
29897
29898         * lib/config.charset: New version, incorporating remarks from a linux
29899         i18n mailing list.  From Bruno Haible.
29900
29901 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
29902
29903         * m4/codeset.m4: New file.
29904         * m4/iconv.m4: New file.
29905         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
29906
29907 2000-03-03  Jim Meyering  <meyering@lucent.com>
29908
29909         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
29910
29911 2000-03-02  Jim Meyering  <meyering@lucent.com>
29912
29913         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
29914         the messages come out on separate lines.
29915
29916         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
29917         rather than jm_CHECK_DECLARATIONS.
29918         * m4/decl.m4: Remove now-unused file.
29919
29920         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
29921         geteuid.
29922
29923 2000-03-02  Jim Meyering  <meyering@lucent.com>
29924
29925         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
29926
29927 2000-03-01  Jim Meyering  <meyering@lucent.com>
29928
29929         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
29930         * lib/unicodeio.c: Likewise.
29931
29932 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
29933
29934         * lib/config.charset: New file.
29935         * lib/localcharset.c: New file.
29936         * lib/unicodeio.h, lib/unicodeio.c: New files.
29937         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
29938         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
29939         (noinst_HEADERS): Add unicodeio.h.
29940         (all-local, install-exec-local, charset.alias): New targets.
29941
29942 2000-02-28  Paul Eggert  <eggert@twinsun.com>
29943
29944         * lib/quotearg.c (ALERT_CHAR): New macro.
29945         (quotearg_buffer_restyled): Use it.
29946
29947 2000-02-27  Jim Meyering  <meyering@lucent.com>
29948
29949         * m4/check-decl.m4: Add getenv to the list.
29950
29951 2000-02-27  Jim Meyering  <meyering@lucent.com>
29952
29953         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
29954         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
29955
29956         * lib/backupfile.c: Guard inclusion of stdlib.h with
29957         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
29958         Declare malloc if needed.
29959
29960         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
29961         `#ifndef HAVE_DECL..'
29962         now that autoconf always defines the HAVE_DECL_ symbols.
29963         * lib/human.c: Likewise.
29964         * lib/same.c: Likewise.
29965         * lib/strtoumax.c: Likewise.
29966
29967         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
29968         declaration check was not run.
29969         * lib/hash.c: Likewise.
29970         * lib/human.c: Likewise.
29971         * lib/same.c: Likewise.
29972         * lib/strtoumax.c: Likewise.
29973
29974         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
29975         `.', then first look up the entire `.'-containing string as a login
29976         name.
29977
29978 2000-02-23  Jim Meyering  <meyering@lucent.com>
29979
29980         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
29981         in place of my hack.
29982
29983 2000-02-18  Paul Eggert  <eggert@twinsun.com>
29984
29985         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
29986         (textint): New typedef.
29987         (parser_control): Member year changed from int to textint.
29988         All uses changed.
29989         (YYSTYPE): Removed; replaced by %union with int and textint members.
29990         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
29991         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
29992         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
29993         (tSNUMBER, tUNUMBER): Now of type <textintval>.
29994         (date, number, to_year): Use width of number in digits, not its value,
29995         to determine whether it's a 2-digit year, or a 2-digit time.
29996         (yylex): Store number of digits of numeric tokens.
29997         Reported by John Kendall.
29998
29999         (parser_control): Changed from struct parser_control to typedef (for
30000         consistency).  All uses changed.
30001
30002         (tID): Removed; not used.
30003         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
30004
30005 2000-02-14  Paul Eggert  <eggert@twinsun.com>
30006
30007         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
30008         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
30009
30010 2000-02-12  Jim Meyering  <meyering@lucent.com>
30011
30012         * lib/userspec.c (ISDIGIT): Define it.
30013         (isdigit): Remove definition.
30014         (is_number): Use ISDIGIT, not isdigit.
30015         <libintl.h>: Include.
30016         (_ and N_): Define.
30017         (parse_user_spec): Mark translatable strings.
30018
30019 2000-02-10  Jim Meyering  <meyering@lucent.com>
30020
30021         With these changes, nanosleep.[ch] are finally enough like the other
30022         lib/* replacement files to compile on a few more losing systems.
30023
30024         * lib/nanosleep.h: Don't include config.h.
30025         Remove prototype from declaration of nanosleep.
30026         (PARAMS): Remove now-unneeded definition.
30027         * lib/nanosleep.c: #undef nanosleep.
30028         (rpl_nanosleep): Rename from nanosleep.
30029
30030 2000-02-10  Jim Meyering  <meyering@lucent.com>
30031
30032         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
30033         gnu_nanosleep to rpl_nanosleep.
30034
30035 2000-02-09  Jim Meyering  <meyering@lucent.com>
30036
30037         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
30038         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
30039
30040 2000-02-08  Akim Demaille  <akim@epita.fr>
30041
30042         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
30043         `[' and `]' and remove uses of `changequote'.
30044         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
30045         (AC_SYS_LARGEFILE): Likewise.
30046         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
30047         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
30048         of changequote.
30049         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
30050         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
30051         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
30052         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
30053
30054 2000-02-05  Jim Meyering  <meyering@lucent.com>
30055
30056         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
30057         Remove explicit use of AC_HEADER_TIME.  It is required by
30058         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
30059         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
30060         in autoconf whereby the expansion of the latter ended up preceding
30061         the expansion of its prerequisite, AC_HEADER_TIME.
30062         Reported by Volker Borchert.
30063
30064 2000-02-03  Jim Meyering  <meyering@lucent.com>
30065
30066         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
30067
30068 2000-02-03  Jim Meyering  <meyering@lucent.com>
30069
30070         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
30071         rather than with `#if HAVE_UTMPNAME'.
30072
30073 2000-02-02  Jim Meyering  <meyering@lucent.com>
30074
30075         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
30076         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
30077         Reported by Eli Zaretskii.
30078
30079 2000-02-01  Jim Meyering  <meyering@lucent.com>
30080
30081         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
30082
30083 2000-01-31  Jim Meyering  <meyering@lucent.com>
30084
30085         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
30086         functions.  Add the time.h and sys/time.h headers along with the
30087         AC_REQUIRE'ment of AC_HEADER_TIME.
30088
30089 2000-01-31  Jim Meyering  <meyering@lucent.com>
30090
30091         * lib/nanosleep.h (nanosleep): Guard declaration with
30092         `#if ! HAVE_DECL_NANOSLEEP'.
30093         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
30094         the declaration in that vendor's sys/timers.h.
30095         Reported by Christian Krackowizer.
30096
30097         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
30098         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
30099         (ISPRINT): Likewise.
30100         Reported by Tom Tromey.
30101
30102 2000-01-30  Jim Meyering  <meyering@lucent.com>
30103
30104         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
30105
30106         * m4/prereq.m4 (utmp_includes): Define.
30107         Check for ut_user and ut_name members in both struct utmpx
30108         and struct utmp.
30109
30110 2000-01-30  Jim Meyering  <meyering@lucent.com>
30111
30112         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
30113         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
30114         header files where only utmpx.ut_user is declared.
30115
30116         * lib/readutmp.h (UT_USER): Define.
30117
30118 2000-01-29  Jim Meyering  <meyering@lucent.com>
30119
30120         * m4/lib-check.m4: New file containing library-related checks from
30121         fileutils and sh-utils (textutils had none).
30122
30123 2000-01-28  Jim Meyering  <meyering@lucent.com>
30124
30125         * m4/perl.m4: Change format of warning message to look more like that
30126         from the missing script.  Suggestion from François Pinard.
30127
30128 2000-01-25  Jim Meyering  <meyering@lucent.com>
30129
30130         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
30131         well as time.h in the compile check.
30132         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
30133         Fix typo in cross-compiling case: s/yes/no/.
30134
30135 2000-01-23  Jim Meyering  <meyering@lucent.com>
30136
30137         * m4/jm-macros.m4: Move df-related tests here from
30138         fileutils/configure.in
30139
30140         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
30141         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
30142
30143         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
30144         s/space/ac_fsusage_space/.
30145         (jm_FILE_SYSTEM_USAGE): Take two parameters.
30146
30147         * m4/ftruncate.m4: New file (derived from part of
30148         fileutils/configure.in).
30149         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
30150         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
30151
30152         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
30153         AC_SUBST these here, rather than just in sh-util/configure.in, so
30154         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
30155         all the same.
30156         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
30157         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
30158         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
30159         (AC_SUBST(POW_LIBM)): Likewise.
30160         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
30161
30162 2000-01-23  Jim Meyering  <meyering@lucent.com>
30163
30164         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
30165         obstack.c.
30166
30167 2000-01-22  Jim Meyering  <meyering@lucent.com>
30168
30169         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
30170
30171         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
30172
30173         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
30174         configure.in
30175         (AC_CHECK_HEADERS): Likewise for sh-utils.
30176         (AC_CHECK_HEADERS): Likewise for textutils.
30177         Merge the three lists of headers.
30178
30179         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
30180         from fileutils' configure.in.
30181
30182         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
30183         code. Moved tests into their own function (_jm_DECL_HEADERS) in
30184         check-decl.m4.
30185
30186         * m4/check-decl.m4: Use #if rather than #ifdef.
30187         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
30188         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
30189         (_jm_DECL_HEADERS): Define new function.
30190         (jm_CHECK_DECLARATIONS): Require it.
30191
30192 2000-01-22  Jim Meyering  <meyering@lucent.com>
30193
30194         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
30195         [! HAVE_DECL_STRTOULL]: Declare strtoull.
30196         Required for some AIX systems.  Reported by Christian Krackowizer.
30197         [TESTING] (main): New function.
30198
30199         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
30200         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
30201         letters.
30202
30203         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
30204         iswprint.
30205
30206         * lib/strverscmp.c (ISDIGIT): Define.
30207         (strverscmp): Use ISDIGIT, not isdigit.
30208
30209 2000-01-19  Jim Meyering  <meyering@lucent.com>
30210
30211         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
30212         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
30213         defines `struct timespec' in <sys/time.h>
30214
30215         * m4/c-bs-a.m4: Remove uses of changequote altogether.
30216         Thanks to Akim for explaining.
30217
30218 2000-01-17  Paul Eggert  <eggert@twinsun.com>
30219
30220         * lib/nanosleep.c (nanosleep):
30221         Don't use SA_INTERRUPT to decide whether to call sigaction, as
30222         POSIX.1 doesn't require SA_INTERRUPT and some systems
30223         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
30224         it's been part of POSIX.1 since day 1 (in 1988).
30225
30226 2000-01-17  Jim Meyering  <meyering@lucent.com>
30227
30228         * lib/interlock: Remove unused file.  Reported by François Pinard.
30229
30230 2000-01-16  Paul Eggert  <eggert@twinsun.com>
30231
30232         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
30233         alert, backslash, formfeed, and vertical tab unnecessarily in
30234         shell quoting style.
30235
30236 2000-01-16  Jim Meyering  <meyering@lucent.com>
30237
30238         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
30239         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
30240         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
30241         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
30242
30243 2000-01-16  Jim Meyering  <meyering@lucent.com>
30244
30245         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
30246         because the latter didn't work.
30247
30248 2000-01-15  Jim Meyering  <meyering@lucent.com>
30249
30250         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
30251         (AC_REPLACE_FUNCS): Add memcpy and memset.
30252         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
30253         Add strpbrk.
30254         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
30255
30256 2000-01-12  Jim Meyering  <meyering@lucent.com>
30257
30258         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
30259         (jm_PREREQ): Use it.
30260         (jm_PREREQ_READUTMP): New macro.
30261         (jm_PREREQ): Use it.
30262
30263 2000-01-11  Paul Eggert  <eggert@twinsun.com>
30264
30265         Quote multibyte characters correctly.
30266         * m4/c-bs-a.m4: New file.
30267         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
30268         (jm_PREREQ): Use it.
30269
30270 2000-01-11  Paul Eggert  <eggert@twinsun.com>
30271
30272         * m4/uintmax_t.m4: Port to autoconf 2.13.
30273
30274 2000-01-08  Jim Meyering  <meyering@ascend.com>
30275
30276         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
30277         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
30278
30279 2000-01-04  Jim Meyering  <meyering@ascend.com>
30280
30281         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
30282         jm_STRUCT_DIRENT_D_TYPE.
30283         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
30284         jm_STRUCT_DIRENT_D_INO.
30285         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
30286         jm_STRUCT_UTIMBUF.
30287         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
30288         renamings.
30289         * m4/utime.m4: Likewise.
30290
30291         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
30292         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
30293
30294 2000-01-03  Paul Eggert  <eggert@twinsun.com>
30295
30296         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
30297         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
30298
30299 2000-01-02  Jim Meyering  <meyering@ascend.com>
30300
30301         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
30302         remember if this is necessary.
30303
30304 1999-12-26  Jim Meyering  <meyering@ascend.com>
30305
30306         * m4/jm-macros.m4: Use it here.
30307         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
30308
30309 1999-12-23  Jim Meyering  <meyering@ascend.com>
30310
30311         * m4/jm-macros.m4: Check for clock_gettime (moved from
30312         fileutils/configure.in)
30313         Check for gettimeofday.
30314
30315 1999-12-20  Jim Meyering  <meyering@ascend.com>
30316
30317         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
30318         autoconf-2.14a-1999-12-20.
30319
30320 1999-12-19  Jim Meyering  <meyering@ascend.com>
30321
30322         * m4/lstat-slash.m4: New file.
30323         * m4/jm-macros.m4: Use the new macro:
30324         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
30325
30326 1999-12-07  Jim Meyering  <meyering@ascend.com>
30327
30328         * m4/perl.m4: Require that File::Compare be available, too.
30329         Too many systems seem to lack it.
30330
30331         * m4/strftime.m4: Add checks for most of the cpp macros tested in
30332         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
30333
30334 1999-11-18  Paul Eggert  <eggert@twinsun.com>
30335
30336         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
30337         problem with the QNX 4.25 shell, which doesn't propagate exit
30338         status of failed commands inside shell assignments.
30339
30340 1999-11-17  Jim Meyering  <meyering@ascend.com>
30341
30342         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
30343
30344 1999-11-07  Jim Meyering  <meyering@ascend.com>
30345
30346         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
30347
30348 1999-11-06  Jim Meyering  <meyering@ascend.com>
30349
30350         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
30351         * m4/jm-macros.m4 (jm_MACROS): Use it here.
30352
30353 1999-11-05  Jim Meyering  <meyering@ascend.com>
30354
30355         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
30356         configure.in of textutils, fileutils, and sh-utils into this one
30357         (shared between those packages) file.
30358         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
30359         AC_STRUCT_ST_BLKSIZE.
30360
30361 1999-11-03  Jim Meyering  <meyering@ascend.com>
30362
30363         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
30364         of AC_CHECK_TYPE checks includes unistd.h.
30365         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
30366         Suggestion from Akim Demaille.
30367
30368 1999-10-30  Jim Meyering  <meyering@ascend.com>
30369
30370         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
30371         m4-quoted string.
30372         * m4/ls-mntd-fs.m4: Likewise.
30373         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
30374         * m4/jm-winsz1.m4: Likewise.
30375
30376         * m4/const.m4: Remove file, since the fix made it into the experimental
30377         version of autoconf.
30378         * m4/mktime.m4: Likewise.
30379
30380         * m4/check-type.m4: Remove file, now that the latest version of
30381         AC_CHECK_TYPE takes a third arg to specify additional #includes.
30382
30383         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
30384         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
30385         AC_CHECK_TYPE.
30386
30387 1999-10-04  Jim Meyering  <meyering@ascend.com>
30388
30389         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
30390
30391 1999-09-22  Paul Eggert  <eggert@twinsun.com>
30392
30393         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
30394         2.95.1 bug with HP-UX 10.20.
30395
30396 1999-09-17  Jim Meyering  <meyering@ascend.com>
30397
30398         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
30399         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
30400         due to missing strdup (against sh-utils-2.0).
30401
30402 1999-08-29  Jim Meyering  <meyering@ascend.com>
30403
30404         * m4/jm-macros.m4: Require jm_BISON.
30405         * m4/bison.m4: New file.
30406
30407 1999-08-17  Paul Eggert  <eggert@twinsun.com>
30408
30409         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
30410         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
30411
30412 1999-08-05  Jim Meyering  <meyering@ascend.com>
30413
30414         * m4/getline.m4: Rename test file from conftestdata to conftest.data
30415         to avoid conflicts with `conftest' on 8+3 filesystems.
30416         Suggestion from Eli Zaretskii.
30417
30418 1999-08-04  Jim Meyering  <meyering@ascend.com>
30419
30420         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
30421         fileutils and sh-utils (textutils's getline test was inadequate).
30422         (AM_FUNC_GETLINE): Run this test.
30423         (AC_CHECK_FUNCS): Check for getdelim.
30424         Reported by Bob Proulx.
30425
30426 1999-08-02  Jim Meyering  <meyering@ascend.com>
30427
30428         * m4/jm-macros.m4: Add a comment.
30429
30430 1999-08-01  Paul Eggert  <eggert@twinsun.com>
30431
30432         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
30433         <inttypes.h> defines strtoumax as a macro (and not as a
30434         function).
30435
30436 1999-08-01  Paul Eggert  <eggert@twinsun.com>
30437
30438         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
30439         that we can shift, multiply and divide unsigned long long
30440         values; Ultrix cc can't do it.
30441
30442 1999-08-01  Paul Eggert  <eggert@twinsun.com>
30443
30444         * m4/mktime.m4: New file, which is a preview of what should appear
30445         in the next public autoconf release.
30446
30447 1999-08-01  Paul Eggert  <eggert@twinsun.com>
30448
30449         * m4/lfs.m4: Remove this file.
30450         * m4/largefile.m4: New file.  It contains the old contents of
30451         lfs.m4, except that all names with prefix AC_LFS have been
30452         changed to use the prefix AC_SYS_LARGEFILE instead, to be
30453         compatible with future autoconf versions.  Also, some minor m4
30454         quoting problems have been fixed.
30455
30456 1999-08-01  Paul Eggert  <eggert@twinsun.com>
30457
30458         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
30459         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
30460         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
30461         and simplify the shell code.
30462
30463 1999-08-01  Jim Meyering  <meyering@ascend.com>
30464
30465         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
30466         m4.
30467
30468 1999-07-20  Jim Meyering  <meyering@ascend.com>
30469
30470         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
30471
30472 1999-07-15  Jim Meyering  <meyering@ascend.com>
30473
30474         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
30475
30476 1999-05-22  Jim Meyering  <meyering@ascend.com>
30477
30478         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
30479
30480 1999-05-20  Jim Meyering  <meyering@ascend.com>
30481
30482         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
30483         Add a colon after each `then' in case $4 is empty.
30484
30485 1999-05-16  Jim Meyering  <meyering@ascend.com>
30486
30487         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
30488
30489 1999-05-10  Jim Meyering  <meyering@ascend.com>
30490
30491         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
30492
30493         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
30494         AC_FUNC_MKTIME.
30495
30496 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
30497
30498         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
30499
30500 1999-05-04  Paul Eggert  <eggert@twinsun.com>
30501
30502         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
30503         not CPPFLAGS, so that linking works correctly in IRIX.
30504
30505 1999-04-30  Paul Eggert  <eggert@twinsun.com>
30506
30507         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
30508
30509 1999-04-20  Paul Eggert  <eggert@twinsun.com>
30510
30511         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
30512         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
30513         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
30514         jm_AC_TYPE_UNSIGNED_LONG_LONG.
30515         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
30516
30517         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
30518
30519 1999-04-20  Jim Meyering  <meyering@ascend.com>
30520
30521         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
30522         AC_REPLACE xstroull if necessary.  From Paul Eggert.
30523         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
30524
30525 1999-04-18  Jim Meyering  <meyering@ascend.com>
30526
30527         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
30528         * m4/jm-macros.m4: Use it.
30529
30530 1999-04-06  Jim Meyering  <meyering@ascend.com>
30531
30532         * m4/strftime.m4: Remove test for %f.
30533
30534 1999-03-29  Jim Meyering  <meyering@ascend.com>
30535
30536         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
30537         superset of the AC_TYPE_* checks in the textutils, fileutils,
30538         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
30539         AC_TYPE_PID_T.
30540
30541 1999-03-28  Jim Meyering  <meyering@ascend.com>
30542
30543         * m4/jm-macros.m4: Define GNU_PACKAGE here.
30544         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
30545         replaced e.g., in the *.sh files of the sh-utils.
30546
30547 1999-03-20  Jim Meyering  <meyering@ascend.com>
30548
30549         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
30550         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
30551         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
30552
30553 1999-03-19  Jim Meyering  <meyering@ascend.com>
30554
30555         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
30556
30557 1999-03-12  Jim Meyering  <meyering@ascend.com>
30558
30559         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
30560
30561 1999-03-07  Jim Meyering  <meyering@ascend.com>
30562
30563         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
30564         declared.
30565
30566 1999-02-17  Jim Meyering  <meyering@ascend.com>
30567
30568         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
30569         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
30570
30571 1999-02-07  Jim Meyering  <meyering@ascend.com>
30572
30573         * m4/group-member.m4: New file -- extracted from sh-utils'
30574         configure.in.
30575
30576         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
30577         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
30578
30579 1999-02-06  Jim Meyering  <meyering@ascend.com>
30580
30581         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
30582         * m4/fnmatch.m4: Likewise.
30583         * m4/getgroups.m4: Likewise.
30584         * m4/lstat.m4: Likewise.
30585         * m4/malloc.m4: Likewise.
30586         * m4/putenv.m4: Likewise.
30587         * m4/realloc.m4: Likewise.
30588         * m4/regex.m4: Likewise.
30589         * m4/stat.m4: Likewise.
30590         * m4/strftime.m4: Likewise.
30591         Suggestion from Alain Magloire.
30592
30593         * m4/chown.m4: Use `.$ac_objext', not `.o'.
30594         * m4/fnmatch.m4: Likewise.
30595         * m4/getgroups.m4: Likewise.
30596         * m4/getline.m4: Likewise.
30597         * m4/lstat.m4: Likewise.
30598         * m4/malloc.m4: Likewise.
30599         * m4/memcmp.m4: Likewise.
30600         * m4/putenv.m4: Likewise.
30601         * m4/realloc.m4: Likewise.
30602         * m4/regex.m4: Likewise.
30603         * m4/stat.m4: Likewise.
30604         * m4/strftime.m4: Likewise.
30605         Suggestion from Alain Magloire.
30606
30607         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
30608         an argument.
30609
30610         * m4/regex.m4: Add a run-time Test for proper operation of
30611         re_compile_pattern.
30612
30613 1999-01-31  Jim Meyering  <meyering@ascend.com>
30614
30615         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
30616
30617 1999-01-30  Jim Meyering  <meyering@ascend.com>
30618
30619         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
30620
30621         * m4/jm-mktime.m4: Make this a wrapper around the official
30622         AM_FUNC_MKTIME rather than my private copy, now that the official one
30623         is up to date.
30624         * m4/mktime.m4: Remove file.
30625
30626         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
30627         * m4/uptime.m4: Likewise.
30628         * m4/uintmax_t.m4: Likewise.
30629
30630 1999-01-28  Jim Meyering  <meyering@ascend.com>
30631
30632         * m4/jm-macros.m4: Use jm_AFS.
30633         * m4/afs.m4: New file (from fileutils' configure.in).
30634
30635         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
30636         * m4/chown.m4: Likewise.
30637         * m4/d-ino.m4: Likewise.
30638         * m4/d-type.m4: Likewise.
30639         * m4/fnmatch.m4: Likewise.
30640         * m4/getgroups.m4: Likewise.
30641         * m4/gettext.m4: Likewise.
30642         * m4/jm-mktime.m4: Likewise.
30643         * m4/jm-winsz2.m4: Likewise.
30644         * m4/lcmessage.m4: Likewise.
30645         * m4/ls-mntd-fs.m4: Likewise.
30646         * m4/malloc.m4: Likewise.
30647         * m4/memcmp.m4: Likewise.
30648         * m4/putenv.m4: Likewise.
30649         * m4/realloc.m4: Likewise.
30650         * m4/st_mtim.m4: Likewise.
30651         * m4/strftime.m4: Likewise.
30652
30653 1999-01-16  Jim Meyering  <meyering@ascend.com>
30654
30655         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
30656         (ARGMATCH_DIE_DECL): Define.
30657
30658 1999-01-12  Jim Meyering  <meyering@ascend.com>
30659
30660         * m4/Makefile.am.in: Rewrite to avoid using fmt.
30661         Reported by Lars Hecking.
30662
30663 1999-01-10  Jim Meyering  <meyering@ascend.com>
30664
30665         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
30666         gross kludge.
30667         * m4/inttypes_h.m4: Likewise.
30668         * m4/lstat.m4: Likewise.
30669         * m4/malloc.m4: Likewise.
30670         * m4/readdir.m4: Likewise.
30671         * m4/realloc.m4: Likewise.
30672         * m4/st_dm_mode.m4: Likewise.
30673         * m4/stat.m4: Likewise.
30674         * m4/utimbuf.m4: Likewise.
30675         * m4/utimes.m4: Likewise.
30676
30677         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
30678         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
30679         comments in config.h.in are meaningful.
30680
30681         * m4/jm-macros.m4: Require autoconf-2.13 here.
30682
30683         * m4/regex.m4: By default, don't use the included regex.c on systems
30684         with glibc 2.  Suggestion from Uli Drepper.
30685
30686 1999-01-02  Jim Meyering  <meyering@ascend.com>
30687
30688         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
30689
30690 1998-12-18  Jim Meyering  <meyering@ascend.com>
30691
30692         * m4/Makefile.am.in (Makefile.am): Simplify rule.
30693         Based on a suggestion from Lars Hecking.
30694
30695 1998-11-16  Paul Eggert  <eggert@twinsun.com>
30696
30697         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
30698
30699 1998-11-16  Jim Meyering  <meyering@ascend.com>
30700
30701         * m4/lfs.m4: Double-quote the `uname...` expression.
30702
30703 1998-11-14  Jim Meyering  <meyering@ascend.com>
30704
30705         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
30706         * m4/stat.m4: Likewise.
30707
30708 1998-11-03  Jim Meyering  <meyering@ascend.com>
30709
30710         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
30711         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
30712
30713 1998-10-18  Jim Meyering  <meyering@ascend.com>
30714
30715         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
30716
30717 1998-10-17  Jim Meyering  <meyering@ascend.com>
30718
30719         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
30720         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
30721         calls for those previously hard-coded headers.  Instead, take a new
30722         parameter.
30723         (jm_CHECK_DECLARATIONS): Reflect interface change.
30724         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
30725         (jm_CHECK_DECL_LOCALTIME_R): New macro.
30726
30727         * m4/mktime.m4: Test for spring-forward gap before long-running test.
30728
30729 1998-10-14  Jim Meyering  <meyering@ascend.com>
30730
30731         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
30732         instead of "TZ=America/Vancouver".  From Paul Eggert.
30733
30734 1998-10-11  Jim Meyering  <meyering@ascend.com>
30735
30736         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
30737         This adds a test for a recently added compatibility fix for mktime.c.
30738         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
30739
30740 1998-09-27  Jim Meyering  <meyering@ascend.com>
30741
30742         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
30743
30744         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
30745         ../configure.in, including a change from Gordon Matzigkeit to allow
30746         cross-compiling for the Hurd.
30747
30748         * m4/glibc.m4: New file/macro to test for the GNU C Library
30749         versions 1 and 2.  From Gordon Matzigkeit.
30750         Indent.
30751
30752 1998-09-21  Jim Meyering  <meyering@ascend.com>
30753
30754         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
30755
30756 1998-08-18  Paul Eggert  <eggert@twinsun.com>
30757
30758         Port nanosecond-resolution times to UnixWare 2.1.2 and
30759         pedantic Solaris 2.6.
30760
30761         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
30762         AC_STRUCT_ST_MTIM.
30763         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
30764         Generate name of ns member, instead of just 1 or undef.
30765         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
30766
30767 1998-08-15  Jim Meyering  <meyering@ascend.com>
30768
30769         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
30770         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
30771         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
30772         instead of jm_TYPE_SSIZE_T.
30773
30774 1998-08-12  Jim Meyering  <meyering@ascend.com>
30775
30776         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
30777
30778 1998-08-02  Jim Meyering  <meyering@ascend.com>
30779
30780         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
30781         in acconfig.h manually.
30782
30783 1998-07-31  Paul Eggert  <eggert@twinsun.com>
30784
30785         * m4/st_mtim.m4: New file.
30786
30787 1998-07-28  Jim Meyering  <meyering@ascend.com>
30788
30789         * m4/utimes.m4: Undef stat.
30790
30791 1998-07-25  Jim Meyering  <meyering@ascend.com>
30792
30793         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
30794         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
30795
30796 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
30797
30798         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
30799         uid and gid actually remain unchanged.
30800
30801 1998-07-07  Jim Meyering  <meyering@ascend.com>
30802
30803         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
30804
30805 1998-07-04  Jim Meyering  <meyering@ascend.com>
30806
30807         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
30808         to prove that this macro can be used in packages without regex.c.
30809
30810 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
30811
30812         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
30813         is to be used.
30814
30815 1998-07-03  Jim Meyering  <meyering@ascend.com>
30816
30817         * m4/gettext.m4: Add -lintl if it's found to be necessary.
30818
30819         * m4/gettext.m4: New file -- from gettext-0.10.35.
30820         * m4/lcmessage.m4: Likewise.
30821         * m4/progtest.m4: Likewise.
30822
30823         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
30824         * m4/jm-macros.m4: Require the new macro.
30825
30826 1998-06-29  Jim Meyering  <meyering@ascend.com>
30827
30828         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
30829         for the definition of NGROUPS (used in a system header included
30830         by sys/mount.h).
30831
30832 1998-06-28  Jim Meyering  <meyering@ascend.com>
30833
30834         * m4/ls-mntd-fs.m4: New file.
30835         * m4/fstypename.m4: New file.
30836
30837         * m4/jm-macros.m4: Require the new macro.
30838         * m4/jm-glibc-io.m4: New file.
30839
30840 1998-05-19  Jim Meyering  <meyering@ascend.com>
30841
30842         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
30843         * m4/lchown.m4: New file.
30844
30845         * m4/Makefile.am.in: New file.
30846         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
30847
30848 1998-05-14  Jim Meyering  <meyering@ascend.com>
30849
30850         * m4/Makefile.am (EXTRA_DIST): Add them.
30851         * m4/jm-macros.m4: New file.
30852         * m4/utimbuf.m4: New file.
30853
30854 1998-05-12  Jim Meyering  <meyering@ascend.com>
30855
30856         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
30857
30858 1998-05-11  Jim Meyering  <meyering@ascend.com>
30859
30860         * m4/isc-posix.m4: New file.
30861
30862 1998-05-10  Jim Meyering  <meyering@ascend.com>