Tests for module 'fpurge'.
[gnulib.git] / ChangeLog
1 2007-04-13  Bruno Haible  <bruno@clisp.org>
2
3         * modules/fpurge-tests: New file.
4         * tests/test-fpurge.c: New file.
5
6         * modules/fpurge: New file.
7         * lib/fpurge.h: New file.
8         * lib/fpurge.c: New file.
9         * m4/fpurge.m4: New file.
10
11 2007-04-13  Bruno Haible  <bruno@clisp.org>
12
13         * modules/fbufmode-tests: New file.
14         * tests/test-fbufmode.c: New file.
15
16         * modules/fbufmode: New file.
17         * lib/fbufmode.h: New file.
18         * lib/fbufmode.c: New file.
19         * m4/fbufmode.m4: New file.
20
21 2007-04-13  Bruno Haible  <bruno@clisp.org>
22
23         * modules/fwritable-tests: New file.
24         * tests/test-fwritable.c: New file.
25
26         * modules/fwritable: New file.
27         * lib/fwritable.h: New file.
28         * lib/fwritable.c: New file.
29         * m4/fwritable.m4: New file.
30
31 2007-04-13  Bruno Haible  <bruno@clisp.org>
32
33         * modules/freadable-tests: New file.
34         * tests/test-freadable.c: New file.
35
36         * modules/freadable: New file.
37         * lib/freadable.h: New file.
38         * lib/freadable.c: New file.
39         * m4/freadable.m4: New file.
40
41 2007-04-13  Bruno Haible  <bruno@clisp.org>
42
43         * modules/fflush-tests (Makefile.am): Remove EXTRA_DIST. Augment
44         MOSTLYCLEANFILES.
45
46 2007-04-13  Paul Eggert  <eggert@cs.ucla.edu>
47
48         * build-aux/bootstrap (gnulib_tool_option_extras): New var, used by
49         gzip bootstrap.conf to avoid dragging in i18n machinery.
50         (gnulib_tool_option): Use it.
51
52 2007-04-13  Bruno Haible  <bruno@clisp.org>
53
54         * tests/test-vasnprintf-posix.c (test_function): Add tests for %f and
55         %F directives.
56         * tests/test-vasprintf-posix.c (test_function): Likewise.
57         * tests/test-snprintf-posix.h (test_function): Likewise.
58         * tests/test-sprintf-posix.h (test_function): Likewise.
59         * tests/test-fprintf-posix.h (test_function): Likewise.
60         * tests/test-printf-posix.h (test_function): Likewise.
61         * tests/test-fprintf-posix.out: Likewise.
62
63 2007-04-13  Bruno Haible  <bruno@clisp.org>
64
65         * modules/lock-tests (configure.ac): For LIBSCHED, try also -lposix4.
66         * modules/tls-tests (configure.ac): Likewise.
67         Reported by Arto C. Nirkko <anirkko@insel.ch>.
68
69 2007-04-13  Bruno Haible  <bruno@clisp.org>
70
71         * lib/tls.c (glthread_tls_get): Fix return type.
72         Patch by Arto C. Nirkko <anirkko@insel.ch>.
73
74 2007-04-12  Eric Blake  <ebb9@byu.net>
75
76         * modules/gettime (Depends-on): Remove gettime.
77         Reported by Dmitry V. Levin.
78
79 2007-04-12  Bruno Haible  <bruno@clisp.org>
80
81         * modules/fflush (Include): Mention <stdio.h>.
82         * modules/strtoimax (Include): Mention <inttypes.h>.
83         * modules/strtoumax (Include): Likewise.
84
85 2007-04-12  Eric Blake  <ebb9@byu.net>
86
87         * .cvsignore: New file.
88         * .gitignore: Likewise.
89
90 2007-04-12  Bruno Haible  <bruno@clisp.org>
91
92         * modules/iconv-tests (test_iconv_LDADD): Mention -liconv after LDADD,
93         not before, since $(LDADD) often contains libgnu.a.
94         * modules/striconv-tests (test_striconv_LDADD): Likewise.
95         * modules/striconveh-tests (test_striconveh_LDADD): Likewise.
96         * modules/striconveha-tests (test_striconveha_LDADD): Likewise.
97         Needed on Cygwin.
98
99 2007-04-12  Eric Blake  <ebb9@byu.net>
100
101         Work around glibc's failure to flush stdin on fclose.
102         * lib/closein.c (close_stdin): Flush stdin before closing.
103
104         Work around glibc's failure to reset seekable stdin on exit.
105         * modules/closein: New module.
106         * lib/closein.c: New file.
107         * lib/closein.h: Likewise.
108         * m4/closein.m4: Likewise.
109         * MODULES.html.sh (File stream based Input/Output): Document it.
110
111 2007-04-12  Simon Josefsson  <simon@josefsson.org>
112
113         * gnulib-tool: Rename generated 'autobuild' script to
114         'do-autobuild' in --create-megatestdir output.
115
116         * doc/gnulib.texi (Build robot for gnulib): Fix.
117
118 2007-04-12  Simon Josefsson  <simon@josefsson.org>
119
120         * modules/sysexits (Depends-on): Add absolute-header.
121
122 2007-04-12  Eric Blake  <ebb9@byu.net>
123
124         No need to preserve errno on success.
125         * lib/fflush.c (rpl_fflush): Simplify errno tracking.
126         Reported by Bruno Haible.
127
128 2007-04-12  Simon Josefsson  <simon@josefsson.org>
129
130         * MODULES.html.sh (Support for maintaining and releasing
131         projects): Add autobuild.  Suggested by Eric Blake <ebb9@byu.net>.
132
133 2007-04-12  Simon Josefsson  <simon@josefsson.org>
134
135         * gnulib-tool (func_modules_add_dummy): Respect --avoid=dummy.
136
137 2007-04-12  Simon Josefsson  <simon@josefsson.org>
138
139         * modules/autobuild: New module.
140
141         * m4/autobuild.m4: New file.
142
143 2007-04-11  Bruno Haible  <bruno@clisp.org>
144
145         * lib/vasnprintf.c (VASNPRINTF): Implement the %F directive using the
146         %f directive, if NEED_PRINTF_DIRECTIVE_F is defined.
147         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_F): New macro.
148         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_F): New macro.
149         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke
150         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
151         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
152         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Invoke
153         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
154         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
155         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Invoke
156         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
157         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
158         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Invoke
159         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
160         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
161         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Invoke
162         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
163         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
164         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Invoke
165         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
166         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
167         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Invoke
168         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
169         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
170         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Invoke
171         gl_PRINTF_DIRECTIVE_F. Test gl_cv_func_printf_directive_f. Invoke
172         gl_PREREQ_VASNPRINTF_DIRECTIVE_F for the replacement.
173         Reported by Eric Blake.
174
175 2007-04-11  Bruno Haible  <bruno@clisp.org>
176
177         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Fix test. It always failed.
178
179 2007-04-10  Bruno Haible  <bruno@clisp.org>
180
181         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct result
182         for NaN and Infinity. Needed on FreeBSD 6.1.
183         * tests/test-vasnprintf-posix.c (test_function): Undo last change
184         regarding results for "%010a" of Infinity and NaN.
185         * tests/test-vasprintf-posix.c (test_function): Likewise.
186         * tests/test-snprintf-posix.h (test_function): Likewise.
187         * tests/test-sprintf-posix.h (test_function): Likewise.
188         * tests/test-fprintf-posix.h (test_function): Likewise.
189         * tests/test-printf-posix.h (test_function): Likewise.
190         * tests/test-fprintf-posix.out: Likewise.
191
192 2007-04-10  Bruno Haible  <bruno@clisp.org>
193
194         * modules/locale-tests: New file.
195         * tests/test-locale.c: New file.
196
197         * modules/locale: New file.
198         * lib/locale_.h: New file.
199         * m4/locale_h.m4: New file.
200
201 2007-04-10  Paul Eggert  <eggert@cs.ucla.edu>
202             Bruno Haible  <bruno@clisp.org>
203
204         * m4/signbit.m4 (gl_SIGNBIT): When the sign bit position could not
205         be determined, test for availability of the copysignf, copysign,
206         copysignl functions.
207         * lib/signbitf.c (gl_signbitf): Use copysignf if available in libc.
208         * lib/signbitd.c (gl_signbitd): Use copysign if available in libc.
209         * lib/signbitl.c (gl_signbitl): Use copysignl if available in libc.
210
211 2007-04-09  Eric Blake  <ebb9@byu.net>
212
213         * lib/stdio_.h [REPLACE_FFLUSH]: Declare rpl_fflush.
214         * modules/stdio (Makefile.am): Support fflush.
215         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
216         * modules/fflush: New file.
217         * lib/fflush.c: Likewise.
218         * m4/fflush.m4: Likewise.
219         * modules/fflush-tests: New test.
220         * tests/test-fflush.c: Likewise.
221         * MODULES.html.sh (Input/output <stdio.h>): Document new module.
222
223 2007-04-06  Bruno Haible  <bruno@clisp.org>
224
225         * lib/vasnprintf.c: Include <math.h>. Don't include float+.h.
226         (VASNPRINTF): Use signbit for faster determination whether to print a
227         minus sign.
228         * modules/vasnprintf (Files): Remove lib/float+.h.
229         * modules/fprintf-posix (Depends-on): Add signbit.
230         * modules/snprintf-posix (Depends-on): Likewise.
231         * modules/sprintf-posix (Depends-on): Likewise.
232         * modules/vasnprintf-posix (Depends-on): Likewise.
233         * modules/vasprintf-posix (Depends-on): Likewise.
234         * modules/vfprintf-posix (Depends-on): Likewise.
235         * modules/vsnprintf-posix (Depends-on): Likewise.
236         * modules/vsprintf-posix (Depends-on): Likewise.
237
238 2007-04-06  Bruno Haible  <bruno@clisp.org>
239
240         * tests/test-frexp.c (main): Test also the sign bit of zero results.
241         * tests/test-frexpl.c (main): Likewise.
242         * tests/test-ldexpl.c (main): Likewise.
243         * modules/frexp-tests (Depends-on): Add signbit.
244         * modules/frexpl-tests (Depdends-on): Likewise.
245         * modules/ldexpl-tests (Depdends-on): Likewise.
246
247 2007-04-06  Bruno Haible  <bruno@clisp.org>
248
249         * modules/signbit-tests: New file.
250         * tests/test-signbit.c: New file.
251
252         * modules/signbit: New file.
253         * lib/signbitf.c: New file.
254         * lib/signbitd.c: New file.
255         * lib/signbitl.c: New file.
256         * m4/signbit.m4: New file.
257         * lib/math_.h (gl_signbitf, gl_signbitd, gl_signbitl): New declarations.
258         (signbit): New macro.
259         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_SIGNBIT and
260         REPLACE_SIGNBIT.
261         * modules/math (Makefile.am) Substibute also GNULIB_SIGNBIT and
262         REPLACE_FREXPL into math.h.
263
264 2007-04-06  Bruno Haible  <bruno@clisp.org>
265
266         * modules/isnanf-nolibm-tests: New file.
267         * tests/test-isnanf.c: New file.
268
269         * modules/isnanf-nolibm: New file.
270         * lib/isnanf.h: New file.
271         * lib/isnanf.c: New file.
272         * lib/isnan.c: Consider the USE_FLOAT macro.
273         * m4/isnanf.m4: New file.
274
275 2007-04-06  Bruno Haible  <bruno@clisp.org>
276
277         * modules/gettext-h (configure.ac): AC_SUBST LIBINTL and LTLIBINTL.
278         (Link): New section.
279
280         * modules/canonicalize-lgpl-tests (Makefile.am): Undo last change.
281
282 2007-04-06  Bruno Haible  <bruno@clisp.org>
283
284         Assume the 'long double' type.
285         * m4/longdouble.m4: Remove file.
286         * config/srclist.txt: Don't mention longdouble.m4.
287         * lib/allocsa.h: Assume HAVE_LONG_DOUBLE to be true.
288         * lib/float+.h: Likewise.
289         * lib/frexp.c: Likewise.
290         * lib/printf-args.h: Likewise.
291         * lib/printf-args.c: Likewise.
292         * lib/printf-frexp.c: Likewise.
293         * lib/printf-parse.c: Likewise.
294         * lib/vasnprintf.c: Likewise.
295         * m4/allocsa.m4: Remove gt_TYPE_LONGDOUBLE invocation.
296         * m4/intl.m4: Likewise.
297         * m4/isnanl.m4: Likewise.
298         * m4/printf.m4: Likewise.
299         * m4/printf-frexpl.m4: Likewise.
300         * m4/vasnprintf.m4: Likewise.
301         * modules/allocsa (Files): Remove m4/longdouble.m4.
302         * modules/gettext (Files): Likewise.
303         * modules/relocatable-prog-wrapper (Files): Likewise.
304         * modules/vasnprintf (Files): Likewise.
305         * modules/isnanl (Files): Likewise.
306         (Include): Simplify.
307         * modules/isnanl-nolibm (Files): Remove m4/longdouble.m4.
308         (Include): Simplify.
309         * modules/printf-frexpl (Files): Remove m4/longdouble.m4.
310         (Include): Simplify.
311         * modules/snprintf-posix-tests (Files): Remove m4/longdouble.m4.
312         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
313         * modules/sprintf-posix-tests (Files): Remove m4/longdouble.m4.
314         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
315         * modules/vasnprintf-posix-tests (Files): Remove m4/longdouble.m4.
316         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
317         * modules/vasprintf-posix-tests (Files): Remove m4/longdouble.m4.
318         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
319         * modules/vsnprintf-posix-tests (Files): Remove m4/longdouble.m4.
320         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
321         * modules/vsprintf-posix-tests (Files): Remove m4/longdouble.m4.
322         (configure.ac): Remove gt_TYPE_LONGDOUBLE invocation.
323         * tests/test-isnanl-nolibm.c: Assume HAVE_LONG_DOUBLE to be true.
324         * tests/test-isnanl.c: Likewise.
325         * tests/test-snprintf-posix.h: Likewise.
326         * tests/test-sprintf-posix.h: Likewise.
327         * tests/test-vasnprintf-posix.c: Likewise.
328         * tests/test-vasnprintf-posix2.c: Likewise.
329         * tests/test-vasprintf-posix.c: Likewise.
330
331 2007-04-06  Bruno Haible  <bruno@clisp.org>
332
333         Fix problem with Compaq (ex-DEC) Desktop C compiler on Tru64.
334         * lib/math_.h [__DECC]: Include the overridden include file through
335         #include_next, outside the double-inclusion guard.
336         * lib/stdio_.h [__DECC]: Likewise.
337         * lib/stdlib_.h [__DECC]: Likewise.
338         * lib/string_.h [__DECC]: Likewise.
339         * lib/time_.h [__DECC]: Likewise.
340         * lib/wchar_.h [__DECC]: Likewise.
341         * lib/wctype_.h [__DECC]: Likewise.
342         * lib/inttypes_.h [__DECC]: Likewise.
343         Reported by Albert Chin <china@thewrittenword.com> in
344         <http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00088.html>.
345
346 2007-04-04  Eric Blake  <ebb9@byu.net>
347
348         * m4/stdint.m4 (gl_STDINT_H): Detect WINT_MAX bug in cygwin
349         1.5.x.
350
351 2007-04-04  Bruno Haible  <bruno@clisp.org>
352
353         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Add a test for correct
354         rounding. Don't assume that FreeBSD 6 and NetBSD 4 pass this test.
355
356 2007-04-04  Bruno Haible  <bruno@clisp.org>
357
358         * tests/test-vasnprintf-posix.c (test_function): Allow two possible
359         results for "%010a" of Infinity and NaN.
360         * tests/test-vasprintf-posix.c (test_function): Likewise.
361         * tests/test-snprintf-posix.h (test_function): Likewise.
362         * tests/test-sprintf-posix.h (test_function): Likewise.
363         * tests/test-fprintf-posix.h (test_function): Remove these tests.
364         * tests/test-printf-posix.h (test_function): Likewise.
365         * tests/test-fprintf-posix.out: Update.
366         Needed for FreeBSD 6.1.
367
368 2007-04-04  Bruno Haible  <bruno@clisp.org>
369
370         * DEPENDENCIES: Remove mentions of tar and gzip, since they are not
371         directly used by the gnulib modules nor by gnulib-tool.
372
373 2007-04-04  Paul Eggert  <eggert@cs.ucla.edu>
374
375         * DEPENDENCIES: Give overall description of version dependency
376         desirability.  Use more-typical names for apps.
377         Add shell, coreutils, diffutils, grep, tar, gzip.
378
379 2007-04-04  Simon Josefsson  <simon@josefsson.org>
380
381         * MODULES.html.sh: Rename crypto modules.  Remove iconvme.
382
383 2007-04-04  Karl Berry  <karl@gnu.org>
384
385         * MODULES.html.sh (func_module): missing '.
386
387 2007-04-03  Bruno Haible  <bruno@clisp.org>
388
389         * modules/argmatch-tests (Makefile.am): New variable
390         test_argmatch_LDADD.
391         * modules/argp-tests (Makefile.am): New variable test_argp_LDADD.
392         * modules/array-list-tests (Makefile.am): New variable
393         test_array_list_LDADD.
394         * modules/array-oset-tests (Makefile.am): New variable
395         test_array_oset_LDADD.
396         * modules/avltree-list-tests (Makefile.am): New variable
397         test_avltree_list_LDADD.
398         * modules/avltree-oset-tests (Makefile.am): New variable
399         test_avltree_oset_LDADD.
400         * modules/avltreehash-list-tests (Makefile.am): New variable
401         test_avltreehash_list_LDADD.
402         * modules/canonicalize-lgpl-tests (Makefile.am): New variable
403         test_canonicalize_lgpl_LDADD.
404         * modules/carray-list-tests (Makefile.am): New variable
405         test_carray_list_LDADD.
406         * modules/dirname-tests (Makefile.am): New variable
407         test_dirname_LDADD.
408         * modules/linked-list-tests (Makefile.am): New variable
409         test_linked_list_LDADD.
410         * modules/linkedhash-list-tests (Makefile.am): New variable
411         test_linkedhash_list_LDADD.
412         * modules/rbtree-list-tests (Makefile.am): New variable
413         test_rbtree_list_LDADD.
414         * modules/rbtree-oset-tests (Makefile.am): New variable
415         test_rbtree_oset_LDADD.
416         * modules/rbtreehash-list-tests (Makefile.am): New variable
417         test_rbtreehash_list_LDADD.
418         * modules/xvasprintf-tests (Makefile.am): New variable
419         test_xvasprintf_LDADD.
420         Reported by Eric Blake.
421
422 2007-04-03  Eric Blake  <ebb9@byu.net>
423
424         * DEPENDENCIES: Weaken m4 requirements.
425
426 2007-04-03  Bruno Haible  <bruno@clisp.org>
427
428         * modules/frexp-tests (configure.ac): Remove AC_SUBST.
429         * modules/isnanl-tests (configure.ac): Likewise.
430
431 2007-04-03  Ben Pfaff  <blp@gnu.org>
432
433         * modules/iconv_open: Add $(srcdir)/ to source directory
434         references in Makefile fragments that call gperf, to fix VPATH
435         builds.
436
437 2007-04-03  Bruno Haible  <bruno@clisp.org>
438
439         * modules/ldexpl (Depends-on): Add isnanl, remove isnanl-nolibm.
440         * lib/ldexpl.c: Undo last change.
441
442 2007-04-03  Bruno Haible  <bruno@clisp.org>
443
444         * modules/printf-frexpl (Depends-on): Undo last change.
445         (Files): Add m4/ldexpl.m4.
446
447 2007-04-03  Bruno Haible  <bruno@clisp.org>
448
449         * m4/isnanl.m4 (gl_FUNC_ISNANL): Substitute ISNANL_LIBM.
450         * modules/isnanl (Link): New section.
451
452         * m4/frexp.m4 (gl_FUNC_FREXP): Substitute FREXP_LIBM.
453         * modules/frexp (Link): New section.
454
455         * m4/frexpl.m4 (gl_FUNC_FREXPL): Substitute FREXPL_LIBM.
456         * modules/frexpl (Link): New section.
457
458         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Substitute LDEXPL_LIBM.
459         * modules/ldexpl (Link): New section.
460
461 2007-04-03  Bruno Haible  <bruno@clisp.org>
462
463         * modules/TEMPLATE-EXTENDED: New file.
464         * gnulib-tool (func_all_modules, func_verify_module): Exclude it.
465
466 2007-04-03  Bruno Haible  <bruno@clisp.org>
467
468         * DEPENDENCIES: New file.
469         Suggested by Simon Josefsson.
470
471 2007-04-03  Bruno Haible  <bruno@clisp.org>
472
473         * doc/gnulib.texi: Escape @.
474
475 2007-04-03  James Youngman  <jay@gnu.org>
476         and Paul Eggert  <eggert@cs.ucla.edu>
477
478         * lib/stat-time.h (get_stat_birthtime): Check for zero-valued
479         birthtime on all systems that have birthtime, not just those which
480         use st_birthtimensec rather than st_birthtim.  Putting zero in
481         st_birthtim.tv_sec is how (for example) FreeBSD/x86 6.1 indicates
482         that the birth time is not available for files on an NFS mount.
483
484 2007-04-03  Simon Josefsson  <simon@josefsson.org>
485
486         * modules/memxor: Move back from crypto/, suggested by Bruno.
487         * modules/crypto/hmac-sha1: Fix memxor dependency.
488
489         * modules/crypto/gc: Moved from ../.
490
491 2007-04-02  Eric Blake  <ebb9@byu.net>
492
493         * lib/ldexpl.c (includes): Avoid libm.
494
495         * modules/printf-frexpl (Depends-on): Depend on ldexpl.
496
497 2007-04-02  Bruno Haible  <bruno@clisp.org>
498
499         * lib/sysexit_.h (EX_OK): Disable the EX_OK definition from <unistd.h>
500         on IRIX.
501
502 2007-04-02  Bruno Haible  <bruno@clisp.org>
503
504         * m4/intdiv0.m4 (gt_INTDIV0): Avoid performing the test for real on
505         x86 or x86_64 platforms running MacOS X.
506         Reported by Ryan Schmidt <@ryandesign.com>.
507
508 2007-04-02  Bruno Haible  <bruno@clisp.org>
509
510         * m4/intdiv0.m4 (gt_INTDIV0): When cross-compiling, treat x86_64 like
511         i386.
512
513 2007-04-01  Simon Josefsson  <simon@josefsson.org>
514
515         * modules/crypto/arcfour: Moved from ../.
516         * modules/crypto/arcfour-tests: Moved from ../.
517         * modules/crypto/arctwo: Moved from ../.
518         * modules/crypto/arctwo-tests: Moved from ../.
519         * modules/crypto/des: Moved from ../.
520         * modules/crypto/des-tests: Moved from ../.
521         * modules/crypto/gc-arcfour: Moved from ../.
522         * modules/crypto/gc-arcfour-tests: Moved from ../.
523         * modules/crypto/gc-arctwo: Moved from ../.
524         * modules/crypto/gc-arctwo-tests: Moved from ../.
525         * modules/crypto/gc-des: Moved from ../.
526         * modules/crypto/gc-des-tests: Moved from ../.
527         * modules/crypto/gc-hmac-md5: Moved from ../.
528         * modules/crypto/gc-hmac-md5-tests: Moved from ../.
529         * modules/crypto/gc-hmac-sha1: Moved from ../.
530         * modules/crypto/gc-hmac-sha1-tests: Moved from ../.
531         * modules/crypto/gc-md2: Moved from ../.
532         * modules/crypto/gc-md2-tests: Moved from ../.
533         * modules/crypto/gc-md4: Moved from ../.
534         * modules/crypto/gc-md4-tests: Moved from ../.
535         * modules/crypto/gc-md5: Moved from ../.
536         * modules/crypto/gc-md5-tests: Moved from ../.
537         * modules/crypto/gc-pbkdf2-sha1: Moved from ../.
538         * modules/crypto/gc-pbkdf2-sha1-tests: Moved from ../.
539         * modules/crypto/gc-random: Moved from ../.
540         * modules/crypto/gc-rijndael: Moved from ../.
541         * modules/crypto/gc-rijndael-tests: Moved from ../.
542         * modules/crypto/gc-sha1: Moved from ../.
543         * modules/crypto/gc-sha1-tests: Moved from ../.
544         * modules/crypto/gc-tests: Moved from ../.
545         * modules/crypto/hmac-md5: Moved from ../.
546         * modules/crypto/hmac-md5-tests: Moved from ../.
547         * modules/crypto/hmac-sha1: Moved from ../.
548         * modules/crypto/hmac-sha1-tests: Moved from ../.
549         * modules/crypto/md2: Moved from ../.
550         * modules/crypto/md2-tests: Moved from ../.
551         * modules/crypto/md4: Moved from ../.
552         * modules/crypto/md4-tests: Moved from ../.
553         * modules/crypto/md5: Moved from ../.
554         * modules/crypto/md5-tests: Moved from ../.
555         * modules/crypto/memxor: Moved from ../.
556         * modules/crypto/rijndael: Moved from ../.
557         * modules/crypto/rijndael-tests: Moved from ../.
558         * modules/crypto/sha1: Moved from ../.
559
560 2007-03-30  James Youngman  <jay@gnu.org>
561
562         * tests/test-stat-time.c (prepare_test): use chmod() rather than
563         rename() to change the ctime of a file (because ctime is unaffected
564         by rename on jfs2 on AIX 5.1).
565         (main): Start by doing cleanup, in case a previous run failed leaving
566         test files behind.
567
568 2007-03-31  Bruno Haible  <bruno@clisp.org>
569
570         Support old proprietary implementations of iconv.
571         * modules/iconv_open: New file.
572         * lib/iconv_.h: New file.
573         * m4/iconv_h.m4: New file.
574         * lib/iconv_open.c: New file.
575         * lib/iconv_open-aix.gperf: New file.
576         * lib/iconv_open-hpux.gperf: New file.
577         * lib/iconv_open-irix.gperf: New file.
578         * lib/iconv_open-osf.gperf: New file.
579         * m4/iconv_open.m4: New file.
580         * modules/linebreak (Depends-on): Add iconv_open.
581         * modules/striconv (Depends-on): Likewise.
582         * modules/striconveh (Depends-on): Likewise.
583         * modules/unicodeio (Depends-on): Likewise.
584         * lib/striconveh.h (mem_cd_iconveh, str_cd_iconveh): Allow cd to be
585         (iconv_t)(-1).
586         * lib/striconveh.c (mem_cd_iconveh_internal): Use an indirect
587         conversion if cd is (iconv_t)(-1).
588         (mem_iconveh, str_iconveh): Don't fail just because a direct conversion
589         is not possible.
590
591 2007-03-31  Bruno Haible  <bruno@clisp.org>
592
593         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
594         work on Solaris either. Protect also second use of "autodetect_jp".
595
596 2007-03-31  Bruno Haible  <bruno@clisp.org>
597
598         * m4/frexpl.m4 (gl_FUNC_FREXPL): Set HAVE_DECL_FREXPL to 0 when
599         the function is not present.
600
601 2007-03-31  Bruno Haible  <bruno@clisp.org>
602
603         * m4/ldexpl.m4 (gl_FUNC_LDEXPL): Set HAVE_DECL_LDEXPL to 0 when
604         the function is not present.
605
606 2007-03-31  Bruno Haible  <bruno@clisp.org>
607
608         * m4/iconv.m4 (AM_ICONV_LINK): Fix 2007-03-29 patch. Test also against
609         a bug in HP-UX iconv_open().
610
611 2007-03-31  Bruno Haible  <bruno@clisp.org>
612
613         * MODULES.html.sh (func_module): Don't show gnulib-common.m4.
614         (Mathematics <math.h>): New section, add fpieee.
615         (Input/output <stdio.h>): Add fseterr.
616         (Mathematics <math.h>): New section, add printf-frexp.
617         (Container data structures): Add sublist.
618         (Core language properties): Add fpucw, inline.
619         (Functions for greatest-width integer types <inttypes.h>): Add
620         imaxabs, imaxdiv, inttypes.
621         (Mathematics <math.h>): Add frexp, frexpl, isnan-nolibm, isnanl,
622         isnanl-nolibm, ldexp.
623         (Mathematics <math.h>): New section, add printf-frexpl.
624         (Support for systems lacking POSIX:2001): Add fprintf-posix,
625         printf-posix, snprintf-posix, sprintf-posix, string, search, socklen,
626         sys_select, sys_socket, vasnprintf-posix, vasprintf-posix,
627         vfprintf-posix, vprintf-posix, vsnprintf-posix, vsprintf-posix.
628         (Unicode string functions): Add unistr/u*-mbtoucr.
629         (Java): Add javacomp-script, javaexec-script.
630         (C#): Add csharpcomp-script, csharpexec-script.
631         (Support for building libraries and executables): Add havelib,
632         relocatable-*.
633         (Support for maintaining and releasing projects): Renamed from
634         'Support for maintaining and release projects'. Add announce-gen.
635
636 2007-03-31  Bruno Haible  <bruno@clisp.org>
637
638         * README: Talk primarily about git.
639         (git and CVS): Renamed from CVS.
640         * doc/gnulib.texi (Introduction, Build robot for gnulib): Mention that
641         gnulib is available through git.
642         * doc/gnulib-tool.texi (CVS Issues): Mention git and svn as well.
643
644 2007-03-30  Bruno Haible  <bruno@clisp.org>
645
646         * lib/alloca_.h: Change prefix of double-inclusion guard macro to _GL_.
647         * lib/poll_.h: Likewise.
648         * lib/stat_.h: Likewise.
649         * lib/sys_time_.h: Likewise.
650         * lib/sysexit_.h: Likewise.
651         * lib/glob_.h: Prefix double-inclusion guard macro with _GL_.
652         * lib/stdbool_.h: Likewise.
653         * lib/byteswap_.h: Add double-inclusion guard.
654
655 2007-03-30  Sergey Poznyakoff  <gray@mirddin.farlep.net>
656
657         * lib/sysexit_.h: Prefix double-inclusion guard macro with _GNULIB.
658
659 2007-03-30  Karl Berry  <karl@gnu.org>
660
661         * config/srclist-update: double space after USA in the license
662         substitution, since that's how it's usually (?) written.
663
664 2007-03-30  Paul Eggert  <eggert@cs.ucla.edu>
665
666         * lib/write-any-file.c (can_write_any_file): Fix else-else bug
667         reported by Bruno Haible.
668
669 2007-03-29  Bruno Haible  <bruno@clisp.org>
670
671         * m4/iconv.m4 (AM_ICONV_LINK): Require AC_CANONICAL_HOST. Test against
672         a bug in AIX iconv().
673
674 2007-03-29  Bruno Haible  <bruno@clisp.org>
675
676         * modules/ldexpl-tests: New file.
677         * tests/test-ldexpl.c: New file.
678
679 2007-03-29  Bruno Haible  <bruno@clisp.org>
680
681         * lib/ldexpl.c: Include fpucw.h.
682         (ldexpl): Use BEGIN/END_LONG_DOUBLE_ROUNDING. Skip the last unneeded
683         multiplication.
684         * modules/ldexpl (Depends-on): Add fpucw.
685
686 2007-03-29  Bruno Haible  <bruno@clisp.org>
687
688         * modules/ldexpl: New file.
689         * m4/ldexpl.m4: New file.
690         * lib/math_.h (ldexpl): Define to a replacement if REPLACE_LDEXPL is
691         set.
692         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize also GNULIB_LDEXPL,
693         REPLACE_LDEXPL.
694         * modules/math (Makefile.am): Substitute also GNULIB_LDEXPL,
695         REPLACE_LDEXPL.
696         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Invoke
697         gl_FUNC_LDEXPL_WORKS.
698         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Remove test for ldexpl.
699         * modules/mathl (Files): Remove lib/ldexpl.c.
700         (Depends-on): Add ldexpl.
701
702 2007-03-29  Bruno Haible  <bruno@clisp.org>
703
704         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Declare frexpl.
705
706 2007-03-29  Bruno Haible  <bruno@clisp.org>
707
708         * tests/test-striconveh.c (main): Don't assume that a direct conversion
709         between ISO-8859-1 and ISO-8859-2 is possible. Needed for OSF/1, IRIX
710         and possibly also HP-UX.
711         * tests/test-striconveha.c (main): Don't expect "autodetect_jp" to
712         work on AIX, IRIX, HP-UX, OSF/1.
713         * tests/uniconv/test-u16-conv-from-enc.c (main): Likewise.
714         * tests/uniconv/test-u16-strconv-from-enc.c (main): Likewise.
715         * tests/uniconv/test-u32-conv-from-enc.c (main): Likewise.
716         * tests/uniconv/test-u32-strconv-from-enc.c (main): Likewise.
717         * tests/uniconv/test-u8-conv-from-enc.c (main): Likewise.
718         * tests/uniconv/test-u8-strconv-from-enc.c (main): Likewise.
719
720 2007-03-29  Bruno Haible  <bruno@clisp.org>
721
722         * tests/test-stat-time.c: Include <fcntl.h>, not <sys/fcntl.h>.
723
724 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
725
726         * lib/acl-internal.h (acl_get_fd, acl_set_fd): undef before defining,
727         to work around a problem on OSF/1 5.1 reported by Bruno Haible.
728
729 2007-03-29  Eric Blake  <ebb9@byu.net>
730
731         * lib/acl-internal.h: Remove redundant include.
732         (ACL_NOT_WELL_SUPPORTED): Also filter on EBUSY, returned by
733         Cygwin when a file is locked.
734
735 2007-03-29  Bruno Haible  <bruno@clisp.org>
736
737         * lib/vasprintf.c [IN_LIBASPRINTF]: Include different specification
738         file.
739         * lib/asprintf.c [IN_LIBASPRINTF]: Likewise.
740
741 2007-03-29  Paul Eggert  <eggert@cs.ucla.edu>
742
743         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Don't bother to
744         try to remove a parent directory if the child couldn't be removed
745         (except for the first rmdir, which could fail because the child
746         doesn't exist).  Problem reported by Jeff Blaine in
747         <http://lists.gnu.org/archive/html/bug-tar/2007-03/msg00014.html>.
748
749 2007-03-28  Bruno Haible  <bruno@clisp.org>
750
751         * lib/striconveh.c (utf8conv_carefully): New function.
752         (mem_cd_iconveh_internal): Invoke it.
753
754 2007-03-28  Bruno Haible  <bruno@clisp.org>
755
756         * lib/striconveh.c (mem_cd_iconveh_internal): Use u8_mbtoucr instead
757         of u8_mbtouc in order to distinguish invalid and incomplete UTF-8
758         input.
759         * modules/striconveh (Depends-on): Add unistr/u8-mbtoucr. Replace
760         utf8-ucs4 with unistr/u8-mbtouc. Replace ucs4-utf8 with
761         unistr/u8-uctomb.
762
763 2007-03-28  Bruno Haible  <bruno@clisp.org>
764
765         * modules/unistr/u8-mbtoucr: New file.
766         * lib/unistr/u8-mbtoucr.c: New file.
767         * modules/unistr/u16-mbtoucr: New file.
768         * lib/unistr/u16-mbtoucr.c: New file.
769         * modules/unistr/u16-mbtoucr: New file.
770         * lib/unistr/u16-mbtoucr.c: New file.
771         * lib/unistr.h (u8_mbtoucr, u16_mbtoucr, u32_mbtoucr): New declarations.
772
773 2007-03-27  Simon Josefsson  <simon@josefsson.org>
774             Bruno Haible  <bruno@clisp.org>
775
776         * m4/vasprintf.m4: Convert AC_SUBST into shell variable for
777         REPLACE_VASPRINTF.  Set HAVE_VASPRINTF.  Add
778         AC_REQUIRE([gl_STDIO_H_DEFAULTS]).
779
780         * m4/stdio_h.m4: Add stubs for vasprintf too.
781
782         * modules/stdio: Support vasprintf in sed command.
783
784         * modules/vasprintf: Depend on stdio for prototypes.  Remove
785         vasprintf.h.  Add stdio module indicator.
786
787         * lib/stdio_.h: Declare asprintf and vasprintf, based on
788         vasprintf.h.
789
790         * lib/vasprintf.h: File removed.
791
792         * lib/asprintf.c: Use stdio.h instead of vasprintf.h.
793         * lib/vasprintf.c: Ditto.
794         * lib/xvasprintf.c: Ditto.
795         * tests/test-vasprintf-posix.c: Ditto.
796         * tests/test-vasprintf.c: Ditto.
797
798 2007-03-27  Bruno Haible  <bruno@clisp.org>
799
800         Make vasnprintf multithread-safe.
801         * lib/vasnprintf.c (decimal_point_char): New function.
802         (VASNPRINTF): Use it.
803         Suggested by Simon Josefsson.
804
805 2007-03-27  Eric Blake  <ebb9@byu.net>
806
807         Support sub-second birthtime on cygwin.
808         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Also check for st_birthtim.
809         * lib/stat-time.h (STAT_TIMESPEC): Adjust comments.
810         (get_stat_birthtime): Also work with st_birthtim.
811
812 2007-03-27  Paul Eggert  <eggert@cs.ucla.edu>
813
814         * lib/stat-time.h (USE_BIRTHTIME): Remove.
815         (get_stat_atime_ns, get_stat_ctime_ns, get_stat_mtime_ns):
816         (get_stat_birthtime_ns): Do not try to use "spare" fields.
817         (get_stat_birthtime_ns): Simplify compile-time tests.
818         (get_stat_birthtime): Change the API to look like
819         get_stat_mtime etc., except return a negative tv_nsec on error.
820         * m4/stat-time.m4 (gl_STAT_TIME, gl_STAT_BIRTHTIME):
821         Don't check for "spare" fields.
822         (gl_STAT_BIRTHTIME): Don't check for struct stat.st_birthtimespec.tv_sec
823         or for struct stat.st_birthtime, as these tests aren't used.
824         * tests/test-stat-time.c (test_birthtime): Adjust to new API.
825
826 2007-03-27  Bruno Haible  <bruno@clisp.org>
827
828         * lib/stat-time.h: Include <sys/stat.h>.
829
830 2007-03-27  James Youngman  <jay@gnu.org>
831
832         * lib/stat-time.h (get_stat_birthtime): New function for
833           retrieving st_birthtime as provided by UFS2 (hence *BSD).
834         * m4/stat-time.m4 (gl_STAT_BIRTHTIME): Probe for st_birthtime
835           and its variants.
836         * modules/stat-time (configure.ac): call gl_STAT_BIRTHTIME.
837         * modules/stat-time-test: New file.
838         * tests/test-stat-time.c: New test, devised by Bruno Haible.
839
840 2007-03-26  Bruno Haible  <bruno@clisp.org>
841
842         Better support of signalling NaNs.
843         * lib/atanl.c: Include isnanl.h.
844         (atanl): Perform test for NaN at the beginning of the function and
845         through a call to isnanl.
846         * lib/cosl.c: Include isnanl.h.
847         (cosl): Perform test for NaN at the beginning of the function and
848         through a call to isnanl.
849         * lib/ldexpl.c: Include isnanl.h.
850         (ldexpl): Perform test for NaN through a call to isnanl.
851         * lib/logl.c: Include isnanl.h.
852         (logl): Perform test for NaN at the beginning of the function and
853         through a call to isnanl.
854         * lib/sinl.c: Include isnanl.h.
855         (sinl): Perform test for NaN at the beginning of the function and
856         through a call to isnanl.
857         * lib/sqrtl.c: Include isnanl.h.
858         (sqrtl): Perform test for NaN at the beginning of the function and
859         through a call to isnanl.
860         * lib/tanl.c: Include isnanl.h.
861         (tanl): Perform test for NaN at the beginning of the function and
862         through a call to isnanl.
863         * lib/trigl.c (ieee754_rem_pio2l): Remove test for NaN.
864         * modules/mathl (Depends-on): Add isnanl.
865
866 2007-03-26  Eric Blake  <ebb9@byu.net>
867
868         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Fix
869         regression in logic sense of previous patch.
870
871 2007-03-26  Bruno Haible  <bruno@clisp.org>
872
873         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): Don't use
874         unportable shell command "if ! ...".
875         Reported by Ralf Wildenhues.
876
877 2007-03-25  Bruno Haible  <bruno@clisp.org>
878
879         * lib/sysexit_,h: If HAVE_SYSEXITS_H is defined, include the original
880         <sysexits.h> file, and only add EX_CONFIG.
881         * m4/sysexits.m4 (gl_SYSEXITS): If <sysexits.h> exists, check its
882         absolute file name and whether it is sufficient. Substitute also
883         HAVE_SYSEXITS_H and ABSOLUTE_SYSEXITS_H.
884         * modules/sysexits (Makefile.am): Substitute HAVE_SYSEXITS_H and
885         ABSOLUTE_SYSEXITS_H into sysexits.h.
886
887 2007-03-25  Bruno Haible  <bruno@clisp.org>
888
889         * lib/getaddrinfo.c (getaddrinfo): Don't access hints->ai_flags when
890         hints is NULL.
891
892 2007-03-25  Bruno Haible  <bruno@clisp.org>
893
894         * lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Add a cast.
895         * lib/uniconv/u8-strconv-to-enc.c (u8_strconv_to_encoding): Likewise.
896
897 2007-03-25  Bruno Haible  <bruno@clisp.org>
898
899         * lib/vasnprintf.c: Include langinfo.h.
900         (VASNPRINTF): Prefer nl_langinfo over localeconv, since it's more
901         multithread-safe.
902         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF_DIRECTIVE_A): New macro.
903         * m4/fprintf-posix.m4 (gl_FUNC_FPRINTF_POSIX): Invoke it.
904         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Likewise.
905         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
906         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
907         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
908         * m4/vfprintf-posix.m4 (gl_FUNC_VFPRINTF_POSIX): Likewise.
909         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX: Likewise.
910         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
911         Reported by Simon Josefsson.
912
913 2007-03-25  Bruno Haible  <bruno@clisp.org>
914
915         * lib/printf-parse.c [!IN_LIBINTL]: Include <stdint.h>, for intmax_t.
916         (PRINTF_PARSE): Make the support for size specifier 'j' unconditional.
917         * modules/vasnprintf (Depends-on): Add stdint.
918
919 2007-03-25  Bruno Haible  <bruno@clisp.org>
920
921         * modules/fpieee: New file.
922         * m4/fpieee.m4: New file.
923         * modules/isnan-nolibm (Depends-on): Add fpieee.
924         * modules/isnanl-nolibm (Depends-on): Add fpieee.
925         * modules/isnanl (Depends-on): Add fpieee.
926
927 2007-03-25  Bruno Haible  <bruno@clisp.org>
928
929         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): Test also finite numbers.
930
931 2007-03-25  Bruno Haible  <bruno@clisp.org>
932
933         Avoid test failures on IRIX 6.5.
934         * tests/test-frexpl.c (MIN_NORMAL_EXP): New macro.
935         (main): Use it.
936         * tests/test-printf-frexpl.c (MIN_NORMAL_EXP, MIN_SUBNORMAL_EXP): New
937         macros.
938         (main): Use them.
939
940 2007-03-25  Bruno Haible  <bruno@clisp.org>
941
942         * m4/frexpl.m4 (gl_FUNC_FREXPL_WORKS): New macro.
943         (gl_FUNC_FREXPL): Invoke it. Set REPLACE_FREXPL to 1 if it frexpl
944         exists but doesn't work.
945         * lib/math_.h (frexpl): Define as a replacement macro if REPLACE_FREXPL
946         is set. Don't provide a prototype if REPLACE_FREXPL is not set.
947         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize REPLACE_FREXPL.
948         * modules/math (Makefile.am) Substibute also REPLACE_FREXPL into math.h.
949
950 2007-03-25  Bruno Haible  <bruno@clisp.org>
951
952         * m4/frexp.m4 (gl_FUNC_FREXP_WORKS): Add check whether frexp(inf)
953         returns inf. Needed on IRIX 6.5.
954
955 2007-03-25  Bruno Haible  <bruno@clisp.org>
956
957         * tests/test-frexpl.c: Include isnanl-nolibm.h.
958         (main): Use isnanl instead of x != x idiom.
959         * modules/frexpl-tests (Depends-on): Add isnanl-nolibm.
960
961         * tests/test-frexp.c: Include isnan.h.
962         (main): Use isnan instead of x != x idiom.
963         * modules/frexp-tests (Depends-on): Add isnan-nolibm.
964
965 2007-03-25  Bruno Haible  <bruno@clisp.org>
966
967         * tests/test-frexp.c (NaN): New function/macro.
968         (main): Use it instead of 0.0 / 0.0.
969         * tests/test-isnan.c (NaN): New function/macro.
970         (main): Use it instead of 0.0 / 0.0.
971         * tests/test-vasnprintf-posix.c (NaN): New function/macro.
972         (test_function): Use it instead of 0.0 / 0.0.
973         * tests/test-vasprintf-posix.c (NaN): New function/macro.
974         (test_function): Use it instead of 0.0 / 0.0.
975         * tests/test-snprintf-posix.h (NaN): New function/macro.
976         (test_function): Use it instead of 0.0 / 0.0.
977         * tests/test-sprintf-posix.h (NaN): New function/macro.
978         (test_function): Use it instead of 0.0 / 0.0.
979         * tests/test-fprintf-posix.h (NaN): New function/macro.
980         (test_function): Use it instead of 0.0 / 0.0.
981         * tests/test-printf-posix.h (NaN): New function/macro.
982         (test_function): Use it instead of 0.0 / 0.0.
983
984         * lib/isnan.c (FUNC): Work around a DEC C compiler bug.
985
986 2007-03-25  Bruno Haible  <bruno@clisp.org>
987
988         * lib/glob_.h: Include <sys/stat.h>. Avoids warnings on AIX 5.1.
989
990 2007-03-25  Bruno Haible  <bruno@clisp.org>
991
992         * lib/regexec.c (merge_state_with_log): Make static.
993
994 2007-03-25  Bruno Haible  <bruno@clisp.org>
995
996         * lib/trigl.c (kernel_rem_pio2): Make static.
997
998 2007-03-25  Bruno Haible  <bruno@clisp.org>
999
1000         * lib/sincosl.c (sincosl_table): Make static.
1001
1002 2007-03-25  Bruno Haible  <bruno@clisp.org>
1003
1004         * lib/argp.h (__restrict): Define to empty, rather than to 'restrict',
1005         if the compiler does not support C99.
1006
1007 2007-03-25  Bruno Haible  <bruno@clisp.org>
1008
1009         * modules/time (Makefile.am): Ensure all rule action lines start with a
1010         tab.
1011
1012 2007-03-24  Bruno Haible  <bruno@clisp.org>
1013
1014         * modules/tsearch-tests: New file.
1015         * tests/test-tsearch.sh: New file.
1016         * tests/test-tsearch.c: New file, mostly copied from glibc.
1017
1018         * modules/search-tests: New file.
1019         * tests/test-search.c: New file.
1020
1021         * modules/search: New file.
1022         * lib/search_.h: New file, incorporating lib/tsearch.h.
1023         * m4/search_h.m4: New file.
1024         * lib/tsearch.h: Remove file.
1025         * lib/tsearch.c: Include search.h instead of tsearch.h.
1026         * m4/tsearch.m4 (gl_FUNC_TSEARCH): Require gl_SEARCH_H_DEFAULTS. Set
1027         HAVE_TSEARCH.
1028         * modules/tsearch (Files): Remove lib/tsearch.h.
1029         (Depends-on): Add search.
1030         (configure.ac): Invoke gl_SEARCH_MODULE_INDICATOR.
1031         (Include): Change tsearch.h into search.h.
1032
1033 2007-03-24  Bruno Haible  <bruno@clisp.org>
1034
1035         * modules/fpucw: New file.
1036         * lib/fpucw.h: New file.
1037         * lib/frexp.c: Include fpucw.h.
1038         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
1039         (FUNC): Use them.
1040         * lib/printf-frexp.c: Include fpucw.h.
1041         (DECL_ROUNDING, BEGIN_ROUNDING, END_ROUNDING): New macros.
1042         (FUNC): Use them.
1043         * lib/vasnprintf.c: Include fpucw.h.
1044         (VASNPRINTF): Invoke BEGIN/END_LONG_DOUBLE_ROUNDING around the
1045         'long double' calculations.
1046         * tests/test-frexpl.c: Include fpucw.h.
1047         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
1048         * tests/test-printf-frexpl.c: Include fpucw.h.
1049         (main): Invoke BEGIN_LONG_DOUBLE_ROUNDING.
1050         * modules/frexpl (Depends-on): Add fpucw.
1051         * modules/printf-frexpl (Depends-on): Likewise.
1052         * modules/fprintf-posix (Depends-on): Likewise.
1053         * modules/snprintf-posix (Depends-on): Likewise.
1054         * modules/sprintf-posix (Depends-on): Likewise.
1055         * modules/vasnprintf-posix (Depends-on): Likewise.
1056         * modules/vasprintf-posix (Depends-on): Likewise.
1057         * modules/vfprintf-posix (Depends-on): Likewise.
1058         * modules/vsnprintf-posix (Depends-on): Likewise.
1059         * modules/vsprintf-posix (Depends-on): Likewise.
1060         * modules/frexpl-tests (Depends-on): Likewise.
1061         * modules/printf-frexpl-tests (Depends-on): Likewise.
1062
1063 2007-03-24  Bruno Haible  <bruno@clisp.org>
1064
1065         * lib/float+.h: New file.
1066         * lib/isnan.c: Include float+.h.
1067         (SIZE): New macro.
1068         (FUNC): Compare only SIZE bytes of the value.
1069         * lib/vasnprintf.c: Include float+.h.
1070         (VASNPRINTF): When comparing agains +0.0L or +0.0, compare only
1071         SIZEOF_LDBL or SIZEOF_DBL bytes.
1072         * modules/isnan-nolibm (Files): Add lib/float+.h.
1073         * modules/isnanl-nolibm (Files): Add lib/float+.h.
1074         * modules/isnanl (Files): Add lib/float+.h.
1075         * modules/vasnprintf (Files): Add lib/float+.h.
1076
1077 2007-03-24  Bruno Haible  <bruno@clisp.org>
1078
1079         * lib/vasnprintf.c [!HAVE_LONG_DOUBLE]: Include printf-frexp.h. Don't
1080         include isnanl-nolibm.h.
1081
1082 2007-03-24  Bruno Haible  <bruno@clisp.org>
1083
1084         * tests/test-read-file.c (main): Don't produce spurious output for
1085         expected situations. Make the test fail if it encountered unexpected
1086         results.
1087
1088 2007-03-24  Bruno Haible  <bruno@clisp.org>
1089
1090         * m4/locale-fr.m4 (gt_LOCALE_FR): Remove the special-casing of NetBSD,
1091         since its fr_FR.ISO8859-1 locale wouldn't pass the tests.
1092
1093 2007-03-24  Bruno Haible  <bruno@clisp.org>
1094
1095         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Fix last change.
1096
1097 2007-03-24  Bruno Haible  <bruno@clisp.org>
1098
1099         * modules/unistr/base (Depends-on): Remove utf8-ucs4-unsafe,
1100         utf16-ucs4-unsafe, utf8-ucs4, utf16-ucs4, ucs4-utf8, ucs4-utf16.
1101
1102         * modules/unistr/u8-mbtouc: Add source files from module utf8-ucs4.
1103         * modules/utf8-ucs4: Turn into a symbolic link to module
1104         unistr/u8-mbtouc.
1105
1106         * modules/unistr/u8-mbtouc-unsafe: Add source files from module
1107         utf8-ucs4-unsafe.
1108         * modules/utf8-ucs4-unsafe: Turn into a symbolic link to module
1109         unistr/u8-mbtouc-unsafe.
1110
1111         * modules/unistr/u16-mbtouc: Add source files from module utf16-ucs4.
1112         * modules/utf16-ucs4: Turn into a symbolic link to module
1113         unistr/u16-mbtouc.
1114
1115         * modules/unistr/u16-mbtouc-unsafe: Add source files from module
1116         utf16-ucs4-unsafe.
1117         * modules/utf16-ucs4-unsafe: Turn into a symbolic link to module
1118         unistr/u16-mbtouc-unsafe.
1119
1120         * modules/unistr/u8-uctomb: Add source files from module utf4-utf8.
1121         * modules/ucs4-utf8: Turn into a symbolic link to module
1122         unistr/u8-ubtomb.
1123
1124         * modules/unistr/u16-uctomb: Add source files from module utf4-utf16.
1125         * modules/ucs4-utf16: Turn into a symbolic link to module
1126         unistr/u16-ubtomb.
1127
1128 2007-03-24  Bruno Haible  <bruno@clisp.org>
1129
1130         * lib/unistr/u8-mbtouc-aux.c: Renamed from lib/unistr/utf8-ucs4.c.
1131         Enable the function only if HAVE_INLINE.
1132         * lib/unistr/u8-mbtouc-unsafe-aux.c: Renamed from
1133         lib/unistr/utf8-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
1134         * lib/unistr/u16-mbtouc-aux.c: Renamed from lib/unistr/utf16-ucs4.c.
1135         Enable the function only if HAVE_INLINE.
1136         * lib/unistr/u16-mbtouc-unsafe-aux.c: Renamed from
1137         lib/unistr/utf16-ucs4-unsafe.c. Enable the function only if HAVE_INLINE.
1138         * lib/unistr/u8-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf8.c.
1139         Enable the function only if HAVE_INLINE.
1140         * lib/unistr/u16-uctomb-aux.c: Renamed from lib/unistr/ucs4-utf16.c.
1141         Enable the function only if HAVE_INLINE.
1142         * modules/utf8-ucs4: Update.
1143         * modules/utf8-ucs4-unsafe: Update.
1144         * modules/utf16-ucs4: Update.
1145         * modules/utf16-ucs4-unsafe: Update.
1146         * modules/ucs4-utf8: Update.
1147         * modules/ucs4-utf16: Update.
1148
1149 2007-03-24  Bruno Haible  <bruno@clisp.org>
1150
1151         * lib/utf8-ucs4.h: Remove file.
1152         * lib/utf8-ucs4-unsafe.h: Remove file.
1153         * lib/utf16-ucs4.h: Remove file.
1154         * lib/utf16-ucs4-unsafe.h: Remove file.
1155         * lib/ucs4-utf8.h: Remove file.
1156         * lib/ucs4-utf16.h: Remove file.
1157         * lib/unistr.h: Include their previous contents.
1158         * m4/utf-ucs4.m4: Remove file.
1159         * m4/ucs4-utf.m4: Remove file.
1160         * modules/utf8-ucs4 (Files): Remove lib/utf8-ucs4.h.
1161         (Depends-on): Add unistr/base.
1162         (configure.ac): Remove gl_UTF_UCS4.
1163         (Makefile.am): Update.
1164         (Include): Change to unistr.h.
1165         * modules/utf8-ucs4-unsafe (Files): Remove lib/utf8-ucs4-unsafe.h.
1166         (Depends-on): Add unistr/base.
1167         (configure.ac): Remove gl_UTF_UCS4.
1168         (Makefile.am): Update.
1169         (Include): Change to unistr.h.
1170         * modules/utf16-ucs4 (Files): Remove lib/utf16-ucs4.h.
1171         (Depends-on): Add unistr/base.
1172         (configure.ac): Remove gl_UTF_UCS4.
1173         (Makefile.am): Update.
1174         (Include): Change to unistr.h.
1175         * modules/utf16-ucs4-unsafe (Files): Remove lib/utf16-ucs4-unsafe.h.
1176         (Depends-on): Add unistr/base.
1177         (configure.ac): Remove gl_UTF_UCS4.
1178         (Makefile.am): Update.
1179         (Include): Change to unistr.h.
1180         * modules/ucs4-utf8 (Files): Remove lib/ucs4-utf8.h.
1181         (Depends-on): Add unistr/base.
1182         (configure.ac): Remove gl_UCS4_UTF.
1183         (Makefile.am): Update.
1184         (Include): Change to unistr.h.
1185         * modules/ucs4-utf16 (Files): Remove lib/ucs4-utf16.h.
1186         (Depends-on): Add unistr/base.
1187         (configure.ac): Remove gl_UCS4_UTF.
1188         (Makefile.am): Update.
1189         (Include): Change to unistr.h.
1190         * lib/unistr/utf8-ucs4.c: Include unistr.h instead of utf8-ucs4.h.
1191         * lib/unistr/utf8-ucs4-unsafe.c: Include unistr.h instead of
1192         utf8-ucs4-unsafe.h.
1193         * lib/unistr/utf16-ucs4.c: Include unistr.h instead of utf16-ucs4.h.
1194         * lib/unistr/utf16-ucs4-unsafe.c: Include unistr.h instead of
1195         utf16-ucs4-unsafe.h.
1196         * lib/unistr/ucs4-utf8.c: Include unistr.h instead of ucs4-utf8.h.
1197         * lib/unistr/ucs4-utf16.c: Include unistr.h instead of ucs4-utf16.h.
1198         * lib/unistr/u8-chr.c: Don't include ucs4-utf8.h.
1199         * lib/unistr/u8-strchr.c: Likewise.
1200         * lib/unistr/u8-strrchr.c: Likewise.
1201         * lib/unistr/u16-chr.c: Don't include ucs4-utf16.h.
1202         * lib/unistr/u16-strchr.c: Likewise.
1203         * lib/unistr/u16-strrchr.c: Likewise.
1204         * lib/striconveh.c: Update.
1205         * lib/linebreak.c: Update.
1206
1207 2007-03-24  Bruno Haible  <bruno@clisp.org>
1208
1209         * lib/argp-help.c (fill_in_uparams, canon_doc_option): Cast the
1210         arguments of isspace, isalpha, isalnum, isdigit to 'unsigned char'.
1211
1212 2007-03-22  Bruno Haible  <bruno@clisp.org>
1213
1214         * lib/strptime.c (__strptime_internal): Use ANSI C syntax.
1215
1216 2007-03-23  Paul Eggert  <eggert@cs.ucla.edu>
1217
1218         * MODULES.html.sh (File system functions): New module write-any-file.
1219         * modules/write-any-file, lib/write-any-file.c, lib/write-any-file.h:
1220         * m4/write-any-file.m4: New files.
1221
1222 2007-03-23  Eric Blake  <ebb9@byu.net>
1223
1224         * gnulib-tool: Rearrange space-tab sequences, since some editors
1225         like to eat them.
1226
1227 2007-03-23  Eric Blake  <ebb9@byu.net>
1228
1229         * lib/version-etc.c (version_etc_va): Update license wording to
1230         be more concise.  Recommended by Richard Stallman.
1231
1232 2007-03-22  Bruno Haible  <bruno@clisp.org>
1233
1234         * lib/poll.c (MSG_PEEK): New fallback definition.
1235
1236 2007-03-22  Bruno Haible  <bruno@clisp.org>
1237
1238         * modules/sys_socket-tests (configure.ac): Check for shutdown function.
1239         * tests/test-sys_socket.c (a): Test only if shutdown() exists.
1240         (main): Update.
1241         Fixes a compilation error on BeOS.
1242
1243 2007-03-22  Bruno Haible  <bruno@clisp.org>
1244
1245         * modules/frexpl-tests: New file.
1246         * tests/test-frexpl.c: New file.
1247
1248         * modules/frexpl: New file.
1249         * m4/frexpl.m4: New file.
1250         * modules/math (Makefile.am): Also substitute GNULIB_FREXPL into math.h.
1251         * lib/math_.h (frexpl): Test GNULIB_FREXPL instead of GNULIB_MATHL.
1252         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Initialize GNULIB_FREXPL.
1253         * modules/mathl (Files): Remove lib/frexpl.c, lib/frexp.c.
1254         (Depends-on): Add frexpl. Remove isnanl-nolibm.
1255         * m4/mathl.m4 (gl_FUNC_LONG_DOUBLE_MATH): Don't test for frexpl.
1256
1257 2007-03-22  Bruno Haible  <bruno@clisp.org>
1258
1259         * lib/frexpl.c: Share code with lib/frexp.c.
1260         * modules/mathl (Files): Add lib/frexp.c.
1261         (Depends-on): Add isnanl-nolibm.
1262
1263 2007-03-22  Bruno Haible  <bruno@clisp.org>
1264
1265         * modules/printf-frexp (Files): Add m4/frexp.m4.
1266         * m4/printf-frexp.m4 (gl_FUNC_PRINTF_FREXP): Define HAVE_FREXP_IN_LIBC
1267         only if the found frexp function actually works.
1268
1269 2007-03-22  Bruno Haible  <bruno@clisp.org>
1270
1271         * lib/frexp.c: Remove older implementation that uses divisions.
1272
1273 2007-03-21  Bruno Haible  <bruno@clisp.org>
1274
1275         * modules/frexp-tests: New file.
1276         * tests/test-frexp.c: New file.
1277
1278         * modules/frexp: New file.
1279         * lib/frexp.c: New file.
1280         * m4/frexp.m4: New file.
1281         * lib/math_.h (frexp): New declaration.
1282         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Also initialize GNULIB_FREXP and
1283         REPLACE_FREXP.
1284         * modules/math (math.h): Also substitute GNULIB_FREXP, REPLACE_FREXP.
1285
1286 2007-03-21  Bruno Haible  <bruno@clisp.org>
1287
1288         * modules/isnanl-tests: New file.
1289         * tests/test-isnanl.c: New file.
1290
1291         * modules/isnanl: New file.
1292         * lib/isnanl.h: New file.
1293         * m4/isnanl.m4 (gl_FUNC_ISNANL): New macro.
1294         (gl_FUNC_ISNANL_NO_LIBM): Invoke gl_HAVE_ISNANL_NO_LIBM,
1295         gl_FUNC_ISNANL_WORKS.
1296         (gl_HAVE_ISNANL_NO_LIBM, gl_HAVE_ISNANL_IN_LIBM, gl_FUNC_ISNANL_WORKS):
1297         New macros.
1298
1299 2007-03-21  Bruno Haible  <bruno@clisp.org>
1300
1301         * modules/isnanl-nolibm (Files): Add lib/isnanl-nolibm.h, remove
1302         lib/isnanl.h.
1303         (Include): Update.
1304         * lib/isnanl-nolibm.h: Renamed from lib/isnanl.h.
1305         * lib/vasnprintf.c: Update.
1306         * modules/isnanl-nolibm-tests (Files): Add tests/test-isnanl-nolibm.c,
1307         tests/test-isnanl.h, remove tests/test-isnanl.c.
1308         (Makefile.am): Update.
1309         * tests/test-isnanl-nolibm.c: New file.
1310         * tests/test-isnanl.h: New file.
1311         * tests/test-isnanl.c: Remove file.
1312
1313 2007-03-21  Jim Meyering  <jim@meyering.net>
1314
1315         When trying to open ".", treat ESTALE like EACCES.
1316         * lib/savewd.c (savewd_save): Resort to forking not just upon
1317         failure with EACCES, but also when errno is ESTALE.
1318
1319 2007-03-20  Bruno Haible  <bruno@clisp.org>
1320
1321         * lib/string_.h (strndup): Enable declaration also if HAVE_STRNDUP.
1322         Needed on AIX 5.1. Reported by Matthew Woehlke.
1323
1324 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1325
1326         Suggestions by Bruno Haible:
1327         * lib/acl-internal.h: Include "gettext.h" rather than rolling
1328         our own.
1329         (ACL_NOT_WELL_SUPPORTED): Parenthesize arg when used.
1330         * modules/acl (Depends-on): Add gettext.
1331
1332 2007-03-19  Bruno Haible  <bruno@clisp.org>
1333
1334         * modules/iconvme: Remove file.
1335         * lib/iconvme.h: Remove file.
1336         * lib/iconvme.c: Remove file.
1337         * m4/iconvme.m4: Remove file.
1338
1339 2007-03-19  Bruno Haible  <bruno@clisp.org>
1340
1341         * doc/relocatable-maint.texi: Break long shell script line.
1342         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1343
1344 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1345
1346         Add limited support for Solaris 10 ZFS-style ACLs: just enough to
1347         handle file_has_acl.
1348         * lib/acl-internal.h, lib/acl_entries.c, lib/file-has-acl.c: New files.
1349         * lib/acl.c: Move header inclusions and related macro defns into
1350         lib/acl-internal.h.
1351         (S_ISLNK): Remove defn, since that's now done for us.
1352         (file_has_acl): Move to lib/file-has-acl.c.
1353         Call acl_trivial if available.  This is the crucial part of the fix.
1354         (acl_entries): Move to lib/acl_entries.c.  Now extern, since it's
1355         shared within the library.  Rewrite a bit, partly to make it compatible
1356         with the GNU coding style.
1357         * m4/acl.m4 (AC_FUNC_ACL): Add AC_LIBOBJ([file-has-acl]).
1358         Remove unnecessary double-quotes.
1359         Don't test for acl_to_text; the build will catch that.
1360         Replace acl_entries if it doesn't exist and it is needed.
1361         Check for -lsec and acl_trivial (as used on Solaris 10).
1362         * modules/acl (Files): Add lib/acl-internal.h, lib/acl_entries.c,
1363         lib/file-has-acl.c.
1364         (Depends-on): Add sys_stat, for S_ISLNK.
1365
1366 2007-03-19  Ben Pfaff  <blp@gnu.org>
1367
1368         * doc/gnulib.texi: Fix typos.
1369         Suggested by Thien-Thi Nguyen <ttn@gnuvola.org>.
1370
1371 2007-03-19  Paul Eggert  <eggert@cs.ucla.edu>
1372
1373         * lib/getcwd.c (__getcwd): Remove redundant comparison of buf to NULL.
1374         If size is zero here, buf must be zero.
1375
1376 2007-03-19  Simon Josefsson  <simon@josefsson.org>
1377
1378         * des.c: Remove weak_keys_chksum.  Reported by Bruno Haible
1379         <bruno@clisp.org>.
1380
1381 2007-03-18  Bruno Haible  <bruno@clisp.org>
1382
1383         * lib/vasnprintf.c (VASNPRINTF): Undo first part of last patch.
1384         Suggested by Eric Blake.
1385
1386 2007-03-18  Ben Pfaff  <blp@gnu.org>
1387
1388         * doc/relocatable.texi: Recommend using as prefix a directory
1389         that does not exist and will never be created.  Based on
1390         discussion with Bruno Haible, Ralf Wildenhues, Matthew Woehlke,
1391         and others.
1392
1393 2007-03-17  Bruno Haible  <bruno@clisp.org>
1394
1395         * lib/fchownat.c: Include lchown.h.
1396
1397 2007-03-17  Bruno Haible  <bruno@clisp.org>
1398
1399         Fix endless loop when the given allocated size was > INT_MAX.
1400         * lib/vasnprintf.c (EOVERFLOW): New fallback definition.
1401         (VASNPRINTF): Fail with EOVERFLOW when the given allocated size is
1402         larger than INT_MAX, or when it grow to a value larger than INT_MAX.
1403         * lib/vsprintf.c (vsprintf): Don't pass a size > INT_MAX to vasnprintf.
1404         * lib/sprintf.c (sprintf): Likewise.
1405
1406 2007-03-17  Bruno Haible  <bruno@clisp.org>
1407
1408         * tests/test-argp-2.sh (func_compare): Output a context diff.
1409
1410 2007-03-17  Bruno Haible  <bruno@clisp.org>
1411
1412         * m4/locale-fr.m4 (gt_LOCALE_FR, gt_LOCALE_FR_UTF8): Check also the
1413         locale's decimal-point character.
1414
1415 2007-03-17  Bruno Haible  <bruno@clisp.org>
1416
1417         * lib/vasnprintf.c (VASNPRINTF): Clear out the memory used for arg_mem
1418         before comparing it. Needed because on some platforms (e.g. x86) a
1419         'long double' occupies less bytes than sizeof (long double).
1420
1421 2007-03-17  Bruno Haible  <bruno@clisp.org>
1422
1423         * tests/test-crc.c (main): Make printf statements 64-bit clean.
1424         * tests/test-gc-pbkdf2-sha1.c (main): Likewise.
1425         * tests/test-getaddrinfo.c (simple): Likewise.
1426         * tests/test-read-file.c (main): Likewise.
1427
1428 2007-03-17  Bruno Haible  <bruno@clisp.org>
1429
1430         * tests/test-dirname.c (main): Make printf statements 64-bit clean.
1431
1432 2007-03-17  Bruno Haible  <bruno@clisp.org>
1433
1434         * tests/test-xvasprintf.c (test_xvasprintf, test_xasprintf): Remove
1435         unused variable.
1436
1437 2007-03-17  Bruno Haible  <bruno@clisp.org>
1438
1439         * tests/test-c-strcasecmp.c: Include c-strcase.h.
1440         * tests/test-c-strncasecmp.c: Likewise.
1441
1442 2007-03-17  Bruno Haible  <bruno@clisp.org>
1443
1444         * modules/stdlib (Depends-on): Add unistd.
1445         * lib/stdlib_.h: Include <unistd.h> if mkstemp is desired.
1446         Needed for MacOS X 10.3.
1447
1448 2007-03-17  Bruno Haible  <bruno@clisp.org>
1449
1450         * lib/unistr/u-strdup.h: Include <stdlib.h>.
1451
1452 2007-03-17  Bruno Haible  <bruno@clisp.org>
1453
1454         * lib/unistr/u-cpy-alloc.h: Include <stdlib.h>.
1455
1456 2007-03-17  Bruno Haible  <bruno@clisp.org>
1457
1458         * gnulib-tool (func_import): Update .cvsignore and .gitignore files
1459         to reflect files copied from gnulib (with or without modifications).
1460         Suggested by Jim Meyering.
1461
1462 2007-03-17  Eric Blake  <ebb9@byu.net>
1463
1464         * NEWS: Document stdlib change from 2007-02-18.
1465
1466 2007-03-17  Jim Meyering  <jim@meyering.net>
1467
1468         Detect use of AC_CONFIG_AUX_DIR also when its argument is quoted.
1469         * build-aux/bootstrap: Put ""s around use of $build_aux, in case
1470         someone uses a name containing shell meta-characters.
1471         Reported by Alfred M. Szmidt.
1472
1473         * build-aux/bootstrap: Don't use \> in grep regexp.  For HP-UX.
1474
1475 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
1476
1477         * build-aux/bootstrap (with_gettext): New variable.  Run autopoint
1478         and copy gettext configuration files only if configure.ac contains
1479         a use of AM_GNU_GETTEXT_VERSION.
1480
1481 2007-03-16  Alfred M. Szmidt  <ams@gnu.org>
1482
1483         * build-aux/bootstrap (gnulib_name): New variable.
1484         (gnulib_tool_options): Use it.
1485
1486 2007-03-13  Simon Josefsson  <simon@josefsson.org>
1487
1488         * tests/test-des.c: Use new namespace.
1489
1490 2007-03-15  Bruno Haible  <bruno@clisp.org>
1491
1492         * lib/dummy.c (gl_dummy_symbol): Renamed from 'dummy'.
1493         Reported by James Youngman <jay@gnu.org>.
1494
1495 2007-03-15  Bruno Haible  <bruno@clisp.org>
1496
1497         * lib/glob.c (glob): Add 'restrict' so that prototype matches the
1498         declared prototype. Needed with cc on OSF/1 5.1.
1499
1500 2007-03-15  Bruno Haible  <bruno@clisp.org>
1501
1502         * lib/gl_list.h (gl_listelement_dispose_fn): New type.
1503         (gl_list_create_empty, gl_list_create): Add dispose_fn argument.
1504         (struct gl_list_implementation): Add dispose_fn argument to the
1505         'create_empty', 'create' methods.
1506         (struct gl_list_impl_base): Add field 'dispose_fn'.
1507         * lib/gl_list.c (gl_list_create_empty, gl_list_create): Add dispose_fn
1508         argument.
1509         * lib/gl_array_list.c (gl_array_create_empty, gl_array_create): Add
1510         dispose_fn argument.
1511         (gl_array_remove_node, gl_array_remove_at, gl_array_list_free): Call
1512         dispose_fn on the dropped values.
1513         * lib/gl_carray_list.c (gl_carray_create_empty, gl_carray_create): Add
1514         dispose_fn argument.
1515         (gl_carray_remove_at, gl_carray_list_free): Call dispose_fn on the
1516         dropped values.
1517         * lib/gl_anyavltree_list2.h (gl_tree_create): Add dispose_fn argument.
1518         (gl_tree_remove_node): Call dispose_fn on the dropped value.
1519         * lib/gl_anyrbtree_list2.h (gl_tree_create): Add dispose_fn argument.
1520         (gl_tree_remove_node): Call dispose_fn on the dropped value.
1521         * lib/gl_anytree_list2.h (gl_tree_create_empty): Add dispose_fn
1522         argument.
1523         (gl_tree_list_free): Call dispose_fn on the dropped values.
1524         * lib/gl_anytreehash_list2.h (gl_tree_list_free): Call dispose_fn on
1525         the dropped values.
1526         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
1527         Add dispose_fn argument.
1528         (gl_linked_remove_node, gl_linked_remove_at, gl_linked_list_free):
1529         Call dispose_fn on the dropped values.
1530         * lib/gl_sublist.c (gl_sublist_create_empty, gl_sublist_create_fill):
1531         Add dispose_fn argument.
1532         (gl_sublist_create): Initialize the 'dispose_fn' field.
1533         * lib/clean-temp.c (create_temp_dir, register_fd): Update.
1534         * tests/test-array_list.c (main): Update.
1535         * tests/test-carray_list.c (main): Update.
1536         * tests/test-avltree_list.c (main): Update.
1537         * tests/test-rbtree_list.c (main): Update.
1538         * tests/test-avltreehash_list.c (main): Update.
1539         * tests/test-rbtreehash_list.c (main): Update.
1540         * tests/test-linked_list.c (main): Update.
1541         * tests/test-linkedhash_list.c (main): Update.
1542         * tests/test-array_oset.c (main): Update.
1543
1544 2007-03-15  Bruno Haible  <bruno@clisp.org>
1545
1546         * lib/gl_oset.h (gl_setelement_dispose_fn): New type.
1547         (gl_oset_create_empty): Add dispose_fn argument.
1548         (struct gl_oset_implementation): Add dispose_fn argument to
1549         'create_empty' method.
1550         (struct gl_oset_impl_base): Add dispose_fn field.
1551         * lib/gl_oset.c (gl_oset_create_empty): Add dispose_fn argument.
1552         * lib/gl_array_oset.c (gl_array_create_empty): Add dispose_fn argument.
1553         (gl_array_remove_at, gl_array_free): Call dispose_fn on the dropped
1554         values.
1555         * lib/gl_anytree_oset.h (gl_tree_create_empty): Add dispose_fn argument.
1556         (gl_tree_oset_free): Call dispose_fn on the dropped values.
1557         * lib/gl_avltree_oset.c (gl_tree_remove_node): Call dispose_fn on the
1558         dropped value.
1559         * lib/gl_rbtree_oset.c (gl_tree_remove_node): Call dispose_fn on the
1560         dropped value.
1561         * tests/test-array_oset.c (main): Update.
1562         * tests/test-avltree_oset.c (main): Update.
1563         * tests/test-rbtree_oset.c (main): Update.
1564         * lib/gl_anytreehash_list1.h (add_to_bucket): Update.
1565
1566 2007-03-13  Bruno Haible  <bruno@clisp.org>
1567
1568         * tests/test-stdbool.c (i): Update after last patch.
1569
1570 2007-03-12  Bruno Haible  <bruno@clisp.org>
1571
1572         * lib/quotearg.c: Include <wctype.h> early, before the definition of
1573         the iswprint macro. Needed on Solaris 2.5.1.
1574
1575 2007-03-12  Bruno Haible  <bruno@clisp.org>
1576
1577         * tests/test-printf-frexp.c (main): Declare x as volatile.
1578
1579 2007-03-12  Simon Josefsson  <simon@josefsson.org>
1580
1581         * doc/gnulib.texi (Build robot for gnulib): New section.
1582
1583 2007-03-12  Jim Meyering  <jim@meyering.net>
1584
1585         * build-aux/bootstrap: New file.
1586         * build-aux/bootstrap.conf: New file, from coreutils.
1587
1588 2007-03-11  Bruno Haible  <bruno@clisp.org>
1589
1590         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Require AC_C_INLINE.
1591
1592 2007-03-12  Simon Josefsson  <simon@josefsson.org>
1593
1594         * lib/des.h, lib/des.c, lib/gc-gnulib.c: Use gl_ namespace, to
1595         avoid collisions with 'des_setkey'.  Reported by Bruno Haible
1596         <bruno@clisp.org>.  Also change 'tripledes_' to '3des_'.
1597
1598 2007-03-11  Bruno Haible  <bruno@clisp.org>
1599
1600         * m4/locale-tr.m4 (gt_LOCALE_TR_UTF8): If the test program fails to
1601         compile, set LOCALE_TR_UTF8 to 'none' instead of empty.
1602
1603 2007-03-11  Bruno Haible  <bruno@clisp.org>
1604
1605         * lib/stdint_.h (INT64_MIN, INTMAX_MIN): Avoid using the ~INT..._MAX
1606         formula. Needed for SunPRO C 5.0.
1607
1608 2007-03-11  Bruno Haible  <bruno@clisp.org>
1609
1610         * modules/long-options (Depends-on): Add getopt.
1611
1612 2007-03-11  Bruno Haible  <bruno@clisp.org>
1613
1614         * modules/modechange (Depends-on): Add stdbool.
1615
1616 2007-03-11  Bruno Haible  <bruno@clisp.org>
1617
1618         * modules/i-ring (Depends-on): Add stdbool.
1619
1620 2007-03-11  Bruno Haible  <bruno@clisp.org>
1621
1622         * modules/gc-des (Depends-on): Add stdbool.
1623
1624 2007-03-11  Bruno Haible  <bruno@clisp.org>
1625
1626         * m4/mktime.m4 (gl_PREREQ_MKTIME): Require AC_C_INLINE.
1627
1628 2007-03-11  Bruno Haible  <bruno@clisp.org>
1629
1630         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Require AC_C_RESTRICT.
1631
1632 2007-03-11  Bruno Haible  <bruno@clisp.org>
1633
1634         * lib/unistr/u32-mbtouc-unsafe.c (u32_mbtouc_unsafe): Fix syntax error.
1635
1636 2007-03-11  Bruno Haible  <bruno@clisp.org>
1637
1638         * lib/vasnprintf.c (sprintf): Undefine.
1639
1640 2007-03-11  Bruno Haible  <bruno@clisp.org>
1641
1642         * lib/isnan.c (rpl_isnan, rpl_isnanl): Work around bug regarding
1643         initializers in SunPRO C and Compaq C compilers.
1644
1645 2007-03-11  Bruno Haible  <bruno@clisp.org>
1646
1647         * lib/gl_array_oset.c (gl_array_iterator_next): Make pointer
1648         decrementing code ANSI C compliant.
1649
1650 2007-03-11  Bruno Haible  <bruno@clisp.org>
1651
1652         * lib/dummy.c [__sun]: Define a dummy variable, not just a typedef.
1653         Needed for Solaris 2.5.1 ranlib and SunPRO C 5.0.
1654
1655 2007-03-11  Bruno Haible  <bruno@clisp.org>
1656
1657         * tests/test-stdbool.c (s, d, e, xlcbug): Disable checks that gnulib's
1658         <stdbool.h> substitute doesn't pass.
1659
1660 2007-03-11  Bruno Haible  <bruno@clisp.org>
1661
1662         * lib/vasnprintf.c (snprintf): Undefine. Avoids an endless recursion.
1663
1664 2007-03-11  Bruno Haible  <bruno@clisp.org>
1665
1666         * gnulib-tool (func_create_megatestdir): Create also an autobuild
1667         script, for submission to autobuild.josefsson.org.
1668
1669 2007-03-10  Bruno Haible  <bruno@clisp.org>
1670
1671         * modules/canonicalize-lgpl-tests: New file.
1672         * tests/test-canonicalize-lgpl.sh: New file.
1673         * tests/test-canonicalize-lgpl.c: New file.
1674
1675         * modules/c-strcase-tests: New file.
1676         * tests/test-c-strcase.sh: New file.
1677         * tests/test-c-strcasecmp.c: New file.
1678         * tests/test-c-strncasecmp.c: New file.
1679
1680         * modules/atexit-tests: New file.
1681         * tests/test-atexit.sh: New file.
1682         * tests/test-atexit.c: New file.
1683
1684 2007-03-10  Bruno Haible  <bruno@clisp.org>
1685
1686         * tests/test-binary-io.sh: Use temporary filenames that are not so
1687         likely to clash with those of other tests (in a parallel make).
1688         * tests/test-binary-io.c: Likewise.
1689
1690 2007-03-10  Bruno Haible  <bruno@clisp.org>
1691
1692         * lib/fseterr.c (fseterr): Port to Solaris/SPARC64. Deactivate the
1693         fallback; use #error instead.
1694         Suggested by Simon Josefsson.
1695
1696 2007-03-10  Bruno Haible  <bruno@clisp.org>
1697
1698         * gnulib-tool (func_create_testdir): Treat MOSTLYCLEANFILES like
1699         CLEANFILES. Put spaces in each line of $cleaned_files, not only the
1700         first and the last.
1701
1702 2007-03-10  Bruno Haible  <bruno@clisp.org>
1703
1704         * lib/stdint_.h (uint_least64_t): Fix typo in last patch.
1705
1706 2007-03-10  Bruno Haible  <bruno@clisp.org>
1707
1708         * modules/snprintf-posix-tests (EXTRA_DIST): New variable. Needed for
1709         "make distcheck".
1710         * modules/sprintf-posix-tests (EXTRA_DIST): Likewise.
1711         * modules/vsnprintf-posix-tests (EXTRA_DIST): Likewise.
1712         * modules/vsprintf-posix-tests (EXTRA_DIST): Likewise.
1713
1714 2007-03-10  Bruno Haible  <bruno@clisp.org>
1715
1716         * modules/allocsa-tests (test_allocsa_SOURCES): Remove redundant
1717         variable.
1718         * modules/dirname-tests (test_dirname_SOURCES): Remove redundant
1719         variable.
1720
1721 2007-03-09  Eric Blake  <ebb9@byu.net>
1722         and Matthew Woehlke  <mw_triad@users.sourceforge.net>  (tiny change)
1723
1724         * lib/stdint_.h (int64_t, uint64_t): Don't undefine if 64-bit
1725         types are not being provided by gnulib.
1726         (GL_INT64_T, GL_UINT64_T): New witnesses of whether gnulib 64-bit
1727         types are supported.
1728
1729 2007-03-10  Bruno Haible  <bruno@clisp.org>
1730
1731         * lib/stdio_.h (__attribute__): New macro.
1732         (fprintf, vfprintf, printf, vprintf, snprintf, vsnprintf, sprintf,
1733         vsprintf): Specify __attribute__ __format__ for GCC.
1734         Suggested by Eric Blake.
1735
1736 2007-03-09  Bruno Haible  <bruno@clisp.org>
1737
1738         * modules/printf-posix-tests: New file.
1739         * tests/test-printf-posix.sh: New file.
1740         * tests/test-printf-posix.c: New file.
1741
1742         * modules/printf-posix: New file.
1743         * lib/printf.c: New file.
1744         * m4/printf-posix-rpl.m4: New file.
1745         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_PRINTF_POSIX,
1746         REPLACE_PRINTF.
1747         * lib/stdio_.h (printf): New declaration.
1748         (format, __format__, ____printf____, ____scanf____, ____strftime____,
1749         ____strfmon____): New macros.
1750         * modules/stdio (Makefile.am): Substitute also GNULIB_PRINTF_POSIX,
1751         REPLACE_PRINTF.
1752
1753 2007-03-09  Bruno Haible  <bruno@clisp.org>
1754
1755         * tests/test-vasnprintf-posix2.sh: New file.
1756         * tests/test-vasnprintf-posix2.c: New file.
1757         * modules/vasnprintf-posix-tests (Files): Add them and m4/locale-fr.m4.
1758         (configure.ac): Invoke gt_LOCALE_FR and gt_LOCALE_FR_UTF8.
1759         (Makefile.am): Activate test-vasnprintf-posix2.sh.
1760
1761         * lib/vasnprintf.c (VASNPRINTF): For the 'a' and 'A' directives, use
1762         a locale dependent decimal point, rather than always '.'.
1763
1764 2007-03-09  Eric Blake  <ebb9@byu.net>
1765
1766         * lib/stdlib_.h (EXIT_FAILURE): GNU code expects this to be 1, in
1767         spite of platforms like Tandem/NSK that define it to -1.
1768
1769 2007-03-08  Bruno Haible  <bruno@clisp.org>
1770
1771         * modules/vprintf-posix-tests: New file.
1772         * tests/test-vprintf-posix.sh: New file.
1773         * tests/test-vprintf-posix.c: New file.
1774         * tests/test-printf-posix.h: New file.
1775
1776         * modules/vprintf-posix: New file.
1777         * lib/vprintf.c: New file.
1778         * m4/vprintf-posix.m4: New file.
1779         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VPRINTF_POSIX,
1780         REPLACE_VPRINTF.
1781         * lib/stdio_.h (vprintf): New declaration.
1782         * modules/stdio (Makefile.am): Substitute also GNULIB_VPRINTF_POSIX,
1783         REPLACE_VPRINTF.
1784
1785 2007-03-08  Bruno Haible  <bruno@clisp.org>
1786
1787         * modules/fprintf-posix-tests: New file.
1788         * tests/test-fprintf-posix.sh: New file.
1789         * tests/test-fprintf-posix.c: New file.
1790
1791         * modules/fprintf-posix: New file.
1792         * lib/fprintf.c: New file.
1793         * m4/fprintf-posix.m4: New file.
1794         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_FPRINTF_POSIX,
1795         REPLACE_FPRINTF.
1796         * lib/stdio_.h (fprintf): New declaration.
1797         * modules/stdio (Makefile.am): Substitute also GNULIB_FPRINTF_POSIX,
1798         REPLACE_FPRINTF.
1799
1800 2007-03-08  Bruno Haible  <bruno@clisp.org>
1801
1802         * modules/vfprintf-posix-tests: New file.
1803         * tests/test-vfprintf-posix.sh: New file.
1804         * tests/test-vfprintf-posix.c: New file.
1805         * tests/test-fprintf-posix.h: New file.
1806         * tests/test-fprintf-posix.out: New file.
1807
1808         * modules/vfprintf-posix: New file.
1809         * lib/vfprintf.c: New file.
1810         * m4/vfprintf-posix.m4: New file.
1811         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VFPRINTF_POSIX,
1812         REPLACE_VFPRINTF.
1813         * lib/stdio_.h (vfprintf): New declaration.
1814         * modules/stdio (Makefile.am): Substitute also GNULIB_VFPRINTF_POSIX,
1815         REPLACE_VFPRINTF.
1816
1817 2007-03-08  Bruno Haible  <bruno@clisp.org>
1818
1819         * lib/stdio_.h: Treat __need___FILE like __need_FILE.
1820
1821 2007-03-08  Bruno Haible  <bruno@clisp.org>
1822
1823         * m4/snprintf-posix.m4 (gl_FUNC_SNPRINTF_POSIX): Use 'case' statements
1824         instead of 'expr' invocations.
1825         * m4/sprintf-posix.m4 (gl_FUNC_SPRINTF_POSIX): Likewise.
1826         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Likewise.
1827         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): Likewise.
1828         * m4/vsnprintf-posix.m4 (gl_FUNC_VSNPRINTF_POSIX): Likewise.
1829         * m4/vsprintf-posix.m4 (gl_FUNC_VSPRINTF_POSIX): Likewise.
1830         Suggested by Paul Eggert.
1831
1832 2007-03-08  Bruno Haible  <bruno@clisp.org>
1833
1834         * modules/fseterr-tests: New file.
1835         * tests/test-fseterr.c: New file.
1836
1837         * modules/fseterr: New file.
1838         * lib/fseterr.h: New file.
1839         * lib/fseterr.c: New file.
1840
1841 2007-03-08  Bruno Haible  <bruno@clisp.org>
1842
1843         * lib/fnmatch_.h: Convert tabs in the middle of lines to spaces.
1844         * lib/getopt_.h: Likewise.
1845         * lib/mbswidth.h: Likewise.
1846         * lib/setenv.h: Likewise.
1847         * lib/vasnprintf.h: Likewise.
1848         * lib/vasprintf.h: Likewise.
1849         * lib/verror.h: Likewise.
1850         * lib/xsetenv.h: Likewise.
1851         * lib/xvasprintf.h: Likewise.
1852
1853 2007-03-08  Jim Meyering  <jim@meyering.net>
1854
1855         * users.txt: Add parted.
1856
1857         * ChangeLog: Restore 1500 lines mistakenly removed from the end.
1858
1859 2007-03-07  Bruno Haible  <bruno@clisp.org>
1860
1861         * m4/printf.m4: Make the shell script snippets copy&pastable.
1862
1863 2007-03-02  Bruno Haible  <bruno@clisp.org>
1864
1865         * lib/netinet_in_.h: New file.
1866         * m4/netinet_in_h.m4 (gl_HEADER_NETINET_IN): Test whether netinet/in.h
1867         is self-contained. Set ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H.
1868         * modules/netinet_in (Files): Add lib/netinet_in_.h.
1869         (Depends-on): Add absolute-header.
1870         (Makefile.am): Substitute ABSOLUTE_NETINET_IN_H, HAVE_NETINET_IN_H
1871         into netinet/in.h.
1872
1873 2007-03-03  Bruno Haible  <bruno@clisp.org>
1874
1875         * lib/sys_select_.h: New file.
1876         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SELECT): Test whether sys/select.h
1877         is self-contained. Set ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H.
1878         * modules/sys_select (Files): Add lib/sys_select_.h.
1879         (Depends-on): Add absolute-header.
1880         (Makefile.am): Substitute ABSOLUTE_SYS_SELECT_H, HAVE_SYS_SELECT_H
1881         into sys/select.h.
1882
1883 2007-03-02  Bruno Haible  <bruno@clisp.org>
1884
1885         * lib/socket_.h: If sys/socket.h exists, include that and <sys/types.h>
1886         before it. Turn HAVE_WINSOCK2_H and HAVE_WS2TCPIP_H into configute-time
1887         values.
1888         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Test also whether
1889         <sys/socket.h> is self-contained. Set ABSOLUTE_SYS_SOCKET_H,
1890         HAVE_SYS_SOCKET_H, HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H.
1891         * modules/sys_socket (Depends-on): Add absolute-header.
1892         (Makefile.am): Substitute ABSOLUTE_SYS_SOCKET_H, HAVE_SYS_SOCKET_H,
1893         HAVE_WINSOCK2_H, HAVE_WS2TCPIP_H into sys/socket.h.
1894         (Include): Remove requirement of inclusion of <sys/types.h>.
1895
1896 2007-03-02  Bruno Haible  <bruno@clisp.org>
1897
1898         * lib/byteswap_.h (bswap_32): Fix formula.
1899
1900 2007-03-06  Bruno Haible  <bruno@clisp.org>
1901
1902         * modules/sprintf-posix-tests: New file.
1903         * tests/test-sprintf-posix.c: New file.
1904
1905         * modules/sprintf-posix: New file.
1906         * lib/sprintf.c: New file.
1907         * m4/sprintf-posix.m4: New file.
1908         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_SPRINTF_POSIX,
1909         REPLACE_SPRINTF.
1910         * lib/stdio_.h (sprintf): New declaration.
1911         * modules/stdio (Makefile.am): Substitute also GNULIB_SPRINTF_POSIX,
1912         REPLACE_SPRINTF.
1913
1914 2007-03-06  Bruno Haible  <bruno@clisp.org>
1915
1916         * modules/vsprintf-posix-tests: New file.
1917         * tests/test-vsprintf-posix.c: New file.
1918         * tests/test-sprintf-posix.h: New file.
1919
1920         * modules/vsprintf-posix: New file.
1921         * lib/vsprintf.c: New file.
1922         * m4/vsprintf-posix.m4: New file.
1923         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also GNULIB_VSPRINTF_POSIX,
1924         REPLACE_VSPRINTF.
1925         * lib/stdio_.h (vsprintf): New declaration.
1926         * modules/stdio (Makefile.am): Substitute also GNULIB_VSPRINTF_POSIX,
1927         REPLACE_VSPRINTF.
1928
1929 2007-03-06  Bruno Haible  <bruno@clisp.org>
1930
1931         * modules/vsnprintf (Depend-on): Remove minmax.
1932
1933 2007-03-06  Bruno Haible  <bruno@clisp.org>
1934
1935         * modules/snprintf-posix-tests: New file.
1936         * tests/test-snprintf-posix.c: New file.
1937
1938         * modules/snprintf-posix: New file.
1939         * m4/snprintf-posix.m4: New file.
1940         * m4/snprintf.m4 (gl_REPLACE_SNPRINTF): New macro, extracted from
1941         gl_FUNC_SNPRINTF.
1942         (gl_FUNC_SNPRINTF): Invoke it.
1943         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_SNPRINTF.
1944         * lib/stdio_.h (snprintf): Define as a replacement if REPLACE_SNPRINTF
1945         is set.
1946         * modules/stdio (Makefile.am): Substitute also REPLACE_SNPRINTF.
1947
1948 2007-03-06  Bruno Haible  <bruno@clisp.org>
1949
1950         * modules/vsnprintf-posix-tests: New file.
1951         * tests/test-vsnprintf-posix.c: New file.
1952         * tests/test-snprintf-posix.h: New file.
1953
1954         * modules/vsnprintf-posix: New file.
1955         * m4/vsnprintf-posix.m4: New file.
1956         * m4/vsnprintf.m4 (gl_REPLACE_VSNPRINTF): New macro, extracted from
1957         gl_FUNC_VSNPRINTF.
1958         (gl_FUNC_VSNPRINTF): Invoke it.
1959         * m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Set also REPLACE_VSNPRINTF.
1960         * lib/stdio_.h (vsnprintf): Define as a replacement if
1961         REPLACE_VSNPRINTF is set.
1962         * modules/stdio (Makefile.am): Substitute also REPLACE_VSNPRINTF.
1963
1964 2007-03-06  Bruno Haible  <bruno@clisp.org>
1965
1966         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Test for vasnprintf here.
1967         * m4/vasprintf-posix.m4 (gl_FUNC_VASPRINTF_POSIX): ... not here.
1968
1969 2007-03-06  Bruno Haible  <bruno@clisp.org>
1970
1971         * lib/math_.h (acosl): Declare also if HAVE_DECL_ACOSL is set.
1972         (asinl): Declare also if HAVE_DECL_ASINL is set.
1973         (atanl): Declare also if HAVE_DECL_ATANL is set.
1974         (ceill): Declare also if HAVE_DECL_CEILL is set.
1975         (cosl): Declare also if HAVE_DECL_COSL is set.
1976         (expl): Declare also if HAVE_DECL_EXPL is set.
1977         (floorl): Declare also if HAVE_DECL_FLOORL is set.
1978         (frexpl): Declare also if HAVE_DECL_FREXPL is set.
1979         (ldexpl): Declare also if HAVE_DECL_LDEXPL is set.
1980         (logl): Declare also if HAVE_DECL_LOGL is set.
1981         (sinl): Declare also if HAVE_DECL_SINL is set.
1982         (sqrtl): Declare also if HAVE_DECL_SQRTL is set.
1983         (tanl): Declare also if HAVE_DECL_TANL is set.
1984         * modules/math (Makefile.am): Substitute the values of HAVE_DECL_*.
1985         * m4/math_h.m4 (gl_MATH_H_DEFAULTS): Set HAVE_DECL_* to 1.
1986         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Fix tests for the
1987         declaration of frexpl, ldexpl.
1988         * modules/printf-frexpl (Depends-on): Add math.
1989         * lib/printf-frexp.c (frexpl, ldexpl): Undo last change.
1990
1991 2007-03-05  Bruno Haible  <bruno@clisp.org>
1992
1993         * m4/printf-frexpl.m4 (gl_FUNC_PRINTF_FREXPL): Also test whether
1994         frexpl and ldexpl are declared.
1995         * lib/printf-frexp.c (frexpl, ldexpl): Provide fallback declarations.
1996
1997 2007-03-05  Bruno Haible  <bruno@clisp.org>
1998
1999         * gnulib-tool (func_get_automake_snippet): Don't synthesize an
2000         EXTRA_lib_SOURCES augmentation for the relocatable-prog-wrapper module.
2001
2002 2007-03-05  Bruno Haible  <bruno@clisp.org>
2003
2004         * lib/stdio_.h: Include <stddef.h>.
2005
2006 2007-03-05  Bruno Haible  <bruno@clisp.org>
2007
2008         * m4/printf.m4 (gl_SNPRINTF_DIRECTIVE_N): New macro.
2009
2010 2007-03-05  Bruno Haible  <bruno@clisp.org>
2011
2012         * m4/printf.m4: Update with info about OpenBSD 3.9, HP-UX 10.20,
2013         NetBSD 4, from Ralf Wildenhues.
2014
2015 2007-03-04  Bruno Haible  <bruno@clisp.org>
2016
2017         * lib/vasprintf.h: Update #if logic for the case when the functions
2018         exist but are overridden.
2019
2020 2007-03-04  Bruno Haible  <bruno@clisp.org>
2021
2022         * m4/printf.m4 (gl_PRINTF_DIRECTIVE_A): Exclude two buggy
2023         implementations: glibc-2.4 and MacOS X 10.3.
2024         * tests/test-vasnprintf-posix.c (test_function): Test also the case
2025         that exhibits the bugs in glibc-2.4 and MacOS X 10.3.
2026         * tests/test-vasprintf-posix.c (test_function): Likewise.
2027
2028 2007-03-04  Bruno Haible  <bruno@clisp.org>
2029
2030         * modules/vasprintf-posix-tests: New file.
2031         * tests/test-vasprintf-posix.c: New file.
2032
2033         * modules/vasprintf-posix: New file.
2034         * lib/vasprintf.h (asprintf, vasprintf): Rename if REPLACE_VASPRINTF is
2035         defined.
2036         * m4/vasprintf-posix.m4: New file.
2037         * m4/vasprintf.m4 (gl_REPLACE_VASPRINTF): New macro, extracted from
2038         gl_FUNC_VASPRINTF.
2039         (gl_FUNC_VASPRINTF): Invoke it.
2040         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): Define REPLACE_VASNPRINTF
2041         here.
2042         * m4/vasnprintf-posix.m4 (gl_FUNC_VASNPRINTF_POSIX): Not here.
2043
2044 2007-03-04  Bruno Haible  <bruno@clisp.org>
2045
2046         * lib/sys_time_.h: Rename GETTIMEOFDAY_REPLACEMENT to
2047         REPLACE_GETTIMEOFDAY.
2048         * modules/sys_time (Makefile.am): Likewise.
2049         * m4/sys_time_h.m4: Likewise.
2050         * m4/gettimeofday.m4: Likewise.
2051
2052 2007-03-04  Bruno Haible  <bruno@clisp.org>
2053
2054         * modules/vasnprintf-posix-tests: New file.
2055         * tests/test-vasnprintf-posix.c: New file.
2056
2057         * modules/vasnprintf-posix: New file.
2058         * lib/vasnprintf.c: Include isnan.h, isnanl.h, printf-frexp.h,
2059         printf-frexpl.h.
2060         (VASNPRINTF): Handle the 'a' and 'A' directives here, if needed.
2061         * lib/vasnprintf.h (asnprintf, vasnprintf): Rename if
2062         REPLACE_VASNPRINTF is defined.
2063         * m4/vasnprintf.m4 (gl_REPLACE_VASNPRINTF): New macro, extracted from
2064         gl_FUNC_VASNPRINTF.
2065         (gl_FUNC_VASNPRINTF): Invoke it.
2066         * m4/vasnprintf-posix.m4: New file.
2067         * m4/printf.m4: New file.
2068
2069 2007-03-04  Bruno Haible  <bruno@clisp.org>
2070
2071         Compile progreloc.c only if --enable-relocatable is specified.
2072         * m4/relocatable.m4 (gl_RELOCATABLE): Arrange to compile progreloc.c
2073         if --enable-relocatable was specified.
2074         * modules/relocatable-prog (Makefile.am): Remove progreloc.c from
2075         lib_SOURCES.
2076
2077 2007-03-04  Jim Meyering  <jim@meyering.net>
2078
2079         * lib/acl.c (ACL_NOT_WELL_SUPPORTED): New macro.
2080         Use it consistently, rather than enumerating errno constants.
2081
2082 2007-03-04  Bruno Haible  <bruno@clisp.org>
2083
2084         * modules/xvasprintf-tests: New file.
2085         * tests/test-xvasprintf.c: New file.
2086
2087         * modules/vasprintf-tests: New file.
2088         * tests/test-vasprintf.c: New file.
2089
2090         * modules/vasnprintf-tests: New file.
2091         * tests/test-vasnprintf.c: New file.
2092
2093         * modules/vsnprintf-tests: New file.
2094         * tests/test-vsnprintf.c: New file.
2095
2096         * modules/snprintf-tests: New file.
2097         * tests/test-snprintf.c: New file.
2098
2099 2007-03-04  Bruno Haible  <bruno@clisp.org>
2100
2101         Compile relocatable.c only if --enable-relocatable is specified.
2102         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY_BODY): Renamed from
2103         gl_RELOCATABLE_LIBRARY.
2104         (gl_RELOCATABLE_LIBRARY, gl_RELOCATABLE_LIBRARY_SEPARATE): New macros.
2105         * m4/relocatable.m4 (gl_RELOCATABLE): Invoke gl_RELOCATABLE_LIBRARY.
2106         (gl_RELOCATABLE_BODY): Require gl_RELOCATABLE_LIBRARY_BODY instead of
2107         gl_RELOCATABLE_LIBRARY.
2108         * modules/relocatable-lib (configure.ac): Invoke gl_RELOCATABLE_LIBRARY.
2109         (Makefile.am): Remove lib_SOURCES.
2110         * modules/relocatable-lib-lgpl (configure.ac): Invoke
2111         gl_RELOCATABLE_LIBRARY.
2112         (Makefile.am): Remove lib_SOURCES.
2113         * modules/relocatable-prog (Makefile.am): Don't compile relocatable.c
2114         always.
2115         * modules/relocatable-prog-wrapper (configure.ac): Invoke
2116         gl_RELOCATABLE_LIBRARY_SEPARATE instead of gl_RELOCATABLE_LIBRARY.
2117
2118 2007-03-04  Bruno Haible  <bruno@clisp.org>
2119
2120         * modules/argmatch-tests: New file.
2121         * tests/test-argmatch.c: New file.
2122
2123         * tests/test-allocsa.c (main): Halve the number of loop runs.
2124
2125         * modules/alloca-opt-tests: New file.
2126         * tests/test-alloca-opt.c: New file.
2127
2128 2007-03-04  Jim Meyering  <jim@meyering.net>
2129
2130         Work around difference between Linux ACLs and Solaris 10 ZFS.
2131         * lib/acl.c (set_acl): Revert to using chmod_or_fchmod also
2132         for EINVAL.
2133
2134 2007-03-03  Bruno Haible  <bruno@clisp.org>
2135
2136         * modules/relocatable-prog (Depends-on): Add back progreloc's
2137         dependencies: canonicalize-lgpl, xalloc, xreadlink, stdbool, unistd.
2138
2139 2007-03-03  Bruno Haible  <bruno@clisp.org>
2140
2141         * modules/relocatable-lib-lgpl: Renamed from modules/relocatable-lib.
2142         * modules/relocatable-lib: New file.
2143
2144 2007-03-03  Bruno Haible  <bruno@clisp.org>
2145
2146         * modules/relocatable-prog: Renamed from modules/relocatable.
2147         * doc/relocatable-maint.texi: Talk about module 'relocatable-prog'.
2148
2149 2007-03-03  Bruno Haible  <bruno@clisp.org>
2150
2151         * modules/relocatable-script (Files): Add doc/relocatable.texi,
2152         m4/relocatable-lib.m4.
2153         (Depends-on): Remove 'relocatable'.
2154         (configure.ac): Add gl_RELOCATABLE_NOP.
2155
2156 2007-03-03  Bruno Haible  <bruno@clisp.org>
2157
2158         * modules/relocatable-prog-wrapper: New file.
2159         * modules/relocatable (Depends-on): Add it. Remove all other
2160         dependencies except progname.
2161         (Files): Remove build-aux/install-reloc, lib/relocwrapper.c.
2162
2163         * m4/strerror.m4 (gl_FUNC_STRERROR_SEPARATE): New macro.
2164         (gl_FUNC_STRERROR): Nop.
2165         * lib/strerror.c: Compile the file only if !HAVE_STRERROR.
2166
2167         * m4/setenv.m4 (gl_FUNC_SETENV_SEPARATE): New macro.
2168         * lib/setenv.c: Compile the file only if _LIBC || !HAVE_SETENV.
2169
2170         * m4/readlink.m4 (gl_FUNC_READLINK_SEPARATE): New macro.
2171         (gl_FUNC_READLINK): Update.
2172
2173         * m4/canonicalize-lgpl.m4 (gl_CANONICALIZE_LGPL_SEPARATE): New macro.
2174
2175 2007-03-03  Bruno Haible  <bruno@clisp.org>
2176
2177         * lib/xreadlink.c: Include <unistd.h> unconditionally.
2178         * modules/xreadlink (Depends-on): Add unistd.
2179         * modules/xreadlink-with-size (Depends-on): Likewise.
2180
2181 2007-03-03  Bruno Haible  <bruno@clisp.org>
2182
2183         * m4/setenv.m4 (gl_FUNC_SETENV, gl_FUNC_UNSETENV): New macros,
2184         extracted from gt_FUNC_SETENV.
2185         (gt_FUNC_SETENV): Remove macro.
2186         * modules/setenv (configure.ac): Add gl_FUNC_SETENV, gl_FUNC_UNSETENV,
2187         remove gt_FUNC_SETENV.
2188
2189 2007-03-03  Bruno Haible  <bruno@clisp.org>
2190
2191         * m4/relocatable-lib.m4 (gl_RELOCATABLE_LIBRARY): Define
2192         ENABLE_RELOCATABLE here.
2193         * m4/relocatable.m4 (gl_RELOCATABLE_BODY): Don't define it here.
2194
2195 2007-03-03  Bruno Haible  <bruno@clisp.org>
2196
2197         * modules/rbtreehash-list-tests (Depends-on): Add progname.
2198         * tests/test-rbtreehash_list.c: Include progname.h.
2199         (main): Call set_program_name.
2200
2201         * modules/rbtree-oset-tests (Depends-on): Add progname.
2202         * tests/test-rbtree_oset.c: Include progname.h.
2203         (main): Call set_program_name.
2204
2205         * modules/rbtree-list-tests (Depends-on): Add progname.
2206         * tests/test-rbtree_list.c: Include progname.h.
2207         (main): Call set_program_name.
2208
2209         * modules/linked-list-tests (Depends-on): Add progname.
2210         * tests/test-linked_list.c: Include progname.h.
2211         (main): Call set_program_name.
2212
2213 2007-03-03  Bruno Haible  <bruno@clisp.org>
2214
2215         * lib/glob-libc.h (_Restrict_): New macro, copied from lib/regex.h.
2216         All uses of __restrict changed to _Restrict_.
2217         * lib/glob_.h (__restrict): Remove macro.
2218
2219 2007-03-02  Bruno Haible  <bruno@clisp.org>
2220
2221         * modules/gettext (configure.ac): Require gettext infrastructure
2222         from version 0.16.1.
2223
2224 2007-03-02  Bruno Haible  <bruno@clisp.org>
2225
2226         * modules/linkedhash-list-tests (Depends-on): Add progname.
2227         * tests/test-linkedhash_list.c: Include progname.h.
2228         (main): Call set_program_name.
2229
2230         * modules/carray-list-tests (Depends-on): Add progname.
2231         * tests/test-carray_list.c: Include progname.h.
2232         (main): Call set_program_name.
2233
2234         * modules/avltreehash-list-tests (Depends-on): Add progname.
2235         * tests/test-avltreehash_list.c: Include progname.h.
2236         (main): Call set_program_name.
2237
2238         * modules/avltree-oset-tests (Depends-on): Add progname.
2239         * tests/test-avltree_oset.c: Include progname.h.
2240         (main): Call set_program_name.
2241
2242         * modules/avltree-list-tests (Depends-on): Add progname.
2243         * tests/test-avltree_list.c: Include progname.h.
2244         (main): Call set_program_name.
2245
2246         * modules/array-oset-tests (Depends-on): Add progname.
2247         * tests/test-array_oset.c: Include progname.h.
2248         (main): Call set_program_name.
2249
2250         * modules/array-list-tests (Depends-on): Add progname.
2251         * tests/test-array_list.c: Include progname.h.
2252         (main): Call set_program_name.
2253
2254         * modules/argp-tests (Depends-on): Add progname.
2255         * tests/test-argp.c: Include argp.h first. Include progname.h.
2256         (main): Call set_program_name.
2257
2258 2007-03-02  Paul Eggert  <eggert@cs.ucla.edu>
2259
2260         * doc/gnulib-tool.texi (Initial import): Reword description of
2261         _FILE_OFFSET_BITS and _GNU_SOURCE, since they sometimes have a
2262         limited effect even if defined after the first system include.
2263
2264 2007-03-01  Bruno Haible  <bruno@clisp.org>
2265
2266         * build-aux/config.libpath: Update to libtool-1.5.22.
2267         Reported by Albert Chin <bug-gnulib@mlists.thewrittenword.com>.
2268
2269 2007-03-01  Bruno Haible  <bruno@clisp.org>
2270
2271         * doc/relocatable-maint.texi: Recommend to set foo_CPPFLAGS, not
2272         foo_CFLAGS.
2273         Reported by Ralf Wildenhues.
2274
2275 2007-03-01  Bruno Haible  <bruno@clisp.org>
2276
2277         * build-aux/install-reloc: Remove object files left over by some
2278         compilers.
2279         Reported by Ralf Wildenhues.
2280
2281 2007-03-01  Bruno Haible  <bruno@clisp.org>
2282
2283         * build-aux/install-reloc: Break long lines.
2284
2285 2007-03-01  Bruno Haible  <bruno@clisp.org>
2286
2287         * doc/relocatable.texi: Document that it may not work on OpenBSD.
2288         Reported by Ralf Wildenhues.
2289
2290 2007-03-01  Bruno Haible  <bruno@clisp.org>
2291
2292         * doc/gnulib-tool.texi (Initial import): Remove paragraph about
2293         include ordering constraints.
2294
2295 2007-03-01  Paul Eggert  <eggert@cs.ucla.edu>
2296
2297         Followup to the 2007-02-12 patch, using suggestions from Bruno Haible in
2298         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00136.html>.
2299         * doc/gnulib-tool.texi (Initial import): Mention _FILE_OFFSET_BITS
2300         as another example.
2301         * lib/time_.h: Fix misspelling.
2302         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
2303         Require gl_HEADER_TIME_H_DEFAULTS.
2304         * m4/strptime.m4 (gl_FUNC_STRPTIME): Likewise.
2305         * m4/time_r.m4 (gl_TIME_R): Likewise.
2306         * m4/timegm.m4 (gl_FUNC_TIMEGM): Likewise.
2307
2308 2007-03-01  Bruno Haible  <bruno@clisp.org>
2309
2310         * m4/utimecmp.m4 (gl_UTIMECMP): Don't require gl_TIMESPEC.
2311         * m4/utimens.m4 (gl_UTIMENS): Likewise.
2312
2313 2007-03-01  Jim Meyering  <jim@meyering.net>
2314
2315         * modules/xreadlink (Maintainer): Add my name.
2316         * modules/xreadlink-with-size (Depends-on): Alphabetize.
2317
2318 2007-02-26  Ben Pfaff  <blp@cs.stanford.edu>
2319             Bruno Haible  <bruno@clisp.org>
2320
2321         * build-aux/install-reloc: Compile also c-ctype.c.
2322         * build-aux/relocatable.sh.in: New file.
2323         * doc/relocatable.texi: New file.
2324         * doc/relocatable-maint.texi: New file.
2325         * doc/gnulib.texi: Include relocatable-maint.texi.
2326         * lib/progreloc.c: Include unistd.h unconditionally.
2327         * lib/relocwrapper.c: Include unistd.h unconditionally.
2328         Include c-ctype.h.
2329         (add_dotbin): Use c_tolower.
2330         * m4/relocatable-lib.m4: New file, extracted from m4/relocatable.m4.
2331         (gl_RELOCATABLE_LIBRARY): Renamed from AC_RELOCATABLE_LIBRARY.
2332         (gl_RELOCATABLE_NOP): Renamed from AC_RELOCATABLE_NOP.
2333         * m4/relocatable.m4 (AC_RELOCATABLE_LIBRARY, AC_RELOCATABLE_NOP): Move
2334         to m4/relocatable-lib.m4.
2335         (gl_RELOCATABLE): Renamed from AC_RELOCATABLE. Set also
2336         RELOCATABLE_CONFIG_H_DIR, RELOCATABLE_SRC_DIR, RELOCATABLE_BUILD_DIR.
2337         (gl_RELOCATABLE_BODY): Renamed from AC_RELOCATABLE_BODY. Don't
2338         require obsolete macro AC_EXEEXT. Don't check for unistd.h. Don't set
2339         SET_RELOCATABLE. Instead set RELOCATABLE_LDFLAGS, INSTALL_PROGRAM_ENV.
2340         * modules/relocatable: New file.
2341         * modules/relocatable-lib: New file.
2342         * modules/relocatable-script: New file.
2343
2344 2007-02-28  Bruno Haible  <bruno@clisp.org>
2345
2346         Import --enable-relocatable infrastructure.
2347         * build-aux/config.libpath: New file, from GNU gettext.
2348         * build-aux/install-reloc: New file, from GNU gettext.
2349         * build-aux/reloc-ldflags: New file, from GNU gettext.
2350         * lib/relocatable.h: New file, from GNU gettext.
2351         * lib/relocatable.c: New file, from GNU gettext.
2352         * lib/relocwrapper.c: New file, from GNU gettext.
2353         * m4/relocatable.m4: New file, from GNU gettext.
2354
2355 2007-02-28  Bruno Haible  <bruno@clisp.org>
2356
2357         * MODULES.html.sh (File system functions): Add xreadlink-with-size.
2358
2359         * modules/xreadlink: New file, from GNU gettext with modifications.
2360         * lib/xreadlink.c: New file, from GNU gettext.
2361         * lib/xreadlink.h: Add comments.
2362         (xreadlink): New declaration.
2363
2364         * modules/xreadlink-with-size: Renamed from modules/xreadlink.
2365         (Files): Remove m4/xreadlink.m4. Replace lib/xreadlink.c with
2366         lib/xreadlink-with-size.c.
2367         (configure.ac): Remove gl_XREADLINK invocation.
2368         (Makefile.am): Augment lib_SOURCES.
2369         * m4/xreadlink.m4: Remove file.
2370         * lib/xreadlink-with-size.c: Renamed from lib/xreadlink.c.
2371         (xreadlink_with_size): Renamed from xreadink.
2372         * lib/xreadlink.h (xreadlink_with_size): Renamed from xreadink.
2373         * modules/canonicalize (Depends-on): Replace xreadlink with
2374         xreadlink-with-size.
2375         * lib/canonicalize.c (canonicalize_filename_mode): Update.
2376
2377 2007-02-25  Jim Meyering  <jim@meyering.net>
2378
2379         * build-aux/announce-gen: When complaining about excess arguments,
2380         list them.
2381
2382 2007-02-25  Paul Eggert  <eggert@cs.ucla.edu>
2383
2384         * README: Document signed integer overflow situation more
2385         accurately.
2386
2387 2007-02-25  Bruno Haible  <bruno@clisp.org>
2388
2389         * lib/vasnprintf.c (VASNPRINTF): Fix estimate of size needed for a
2390         'a' or 'A' conversion.
2391
2392 2007-02-25  Bruno Haible  <bruno@clisp.org>
2393
2394         * modules/filename: Renamed from modules/pathname.
2395         (Files): Replace lib/pathname.h with lib/filename.h. Replace
2396         lib/concatpath.c with lib/concat-filename.c.
2397         (Makefile.am): Update.
2398         (Include): Replace pathname.h with filename.h.
2399         * lib/filename.h: Renamed from lib/pathname.h.
2400         (concatenated_filename): Renamed from concatenated_pathname.
2401         * lib/concat-filename.c: Renamed from lib/concatpath.c.
2402         (concatenated_filename): Renamed from concatenated_pathname.
2403         * lib/findprog.c: Include filename.h instead of pathname.h.
2404         (find_in_path): Update.
2405         * lib/javacomp.c: Include filename.h instead of pathname.h.
2406         (is_envjavac_gcj43_usable, is_envjavac_oldgcj_14_14_usable,
2407         is_envjavac_oldgcj_14_13_usable, is_envjavac_nongcj_usable,
2408         is_gcj_present, is_gcj43_usable, is_oldgcj_14_14_usable,
2409         is_oldgcj_14_13_usable, is_javac_usable): Update.
2410         * lib/javaexec.c: Include filename.h instead of pathname.h.
2411         (execute_java_class): Update.
2412         * modules/findprog: Update.
2413         * modules/javacomp: Update.
2414         * modules/javaexec: Update.
2415         * MODULES.html.sh (File system functions): Add 'filename', remove
2416         'pathname'.
2417
2418 2007-02-25  Bruno Haible  <bruno@clisp.org>
2419
2420         * modules/printf-frexpl-tests: New file.
2421         * tests/test-printf-frexpl.c: New file.
2422
2423         * modules/printf-frexpl: New file.
2424         * lib/printf-frexpl.h: New file.
2425         * lib/printf-frexpl.c: New file.
2426         * m4/printf-frexpl.m4: New file.
2427
2428 2007-02-25  Bruno Haible  <bruno@clisp.org>
2429
2430         * modules/printf-frexp-tests: New file.
2431         * tests/test-printf-frexp.c: New file.
2432
2433         * modules/printf-frexp: New file.
2434         * lib/printf-frexp.h: New file.
2435         * lib/printf-frexp.c: New file.
2436         * m4/printf-frexp.m4: New file.
2437
2438 2007-02-25  Bruno Haible  <bruno@clisp.org>
2439
2440         Assume automake >= 1.10 for the tests.
2441         * modules/arcfour-tests (TESTS): Remove $(EXEEXT) suffix.
2442         * modules/arctwo-tests: Likewise.
2443         * modules/argp-tests: Likewise.
2444         * modules/avltree-list-tests: Likewise.
2445         * modules/avltree-oset-tests: Likewise.
2446         * modules/avltreehash-list-tests: Likewise.
2447         * modules/carray-list-tests: Likewise.
2448         * modules/crc-tests: Likewise.
2449         * modules/des-tests: Likewise.
2450         * modules/gc-arcfour-tests: Likewise.
2451         * modules/gc-arctwo-tests: Likewise.
2452         * modules/gc-des-tests: Likewise.
2453         * modules/gc-hmac-md5-tests: Likewise.
2454         * modules/gc-hmac-sha1-tests: Likewise.
2455         * modules/gc-md2-tests: Likewise.
2456         * modules/gc-md4-tests: Likewise.
2457         * modules/gc-md5-tests: Likewise.
2458         * modules/gc-pbkdf2-sha1-tests: Likewise.
2459         * modules/gc-rijndael-tests: Likewise.
2460         * modules/gc-sha1-tests: Likewise.
2461         * modules/gc-tests: Likewise.
2462         * modules/getaddrinfo-tests: Likewise.
2463         * modules/hmac-md5-tests: Likewise.
2464         * modules/hmac-sha1-tests: Likewise.
2465         * modules/linked-list-tests: Likewise.
2466         * modules/linkedhash-list-tests: Likewise.
2467         * modules/lock-tests: Likewise.
2468         * modules/md2-tests: Likewise.
2469         * modules/md4-tests: Likewise.
2470         * modules/md5-tests: Likewise.
2471         * modules/rbtree-list-tests: Likewise.
2472         * modules/rbtree-oset-tests: Likewise.
2473         * modules/rbtreehash-list-tests: Likewise.
2474         * modules/read-file-tests: Likewise.
2475         * modules/rijndael-tests: Likewise.
2476         * modules/stdint-tests: Likewise.
2477         * modules/tls-tests: Likewise.
2478
2479 2007-02-24  Bruno Haible  <bruno@clisp.org>
2480
2481         * lib/isnanl.h (isnanl): Define through isnan if isnan is a macro.
2482         * m4/isnan.m4 (gl_FUNC_ISNAN_NO_LIBM): Don't check for isnan as a
2483         function; instead check whether isnan with a double argument links.
2484         * m4/isnanl.m4 (gl_FUNC_ISNANL_NO_LIBM): Don't check for isnanl as a
2485         function; instead check whether isnan with a 'long double' argument
2486         links.
2487         Reported by Eric Blake <ebb9@byu.net>.
2488
2489 2007-02-24  Bruno Haible  <bruno@clisp.org>
2490
2491         * lib/isnan.c: Support the 'long double' case if USE_LONG_DOUBLE is
2492         defined.
2493         * lib/isnanl.c: Remove all code. Just include isnan.c.
2494         * modules/isnanl-nolibm (Files): Add lib/isnan.c.
2495
2496 2007-02-25  Jim Meyering  <jim@meyering.net>
2497
2498         Avoid conflicting types for 'unsetenv' on FreeBSD.
2499         * lib/putenv.c (_unsetenv): Rename from "unsetenv", to avoid
2500         conflicting with FreeBSD's (5.0 and 6.1) function declaration
2501         in stdlib.h.
2502
2503 2007-02-24  Bruno Haible  <bruno@clisp.org>
2504
2505         * modules/isnanl-nolibm-tests: New file.
2506         * tests/test-isnanl.c: New file.
2507
2508         * modules/isnanl-nolibm: New file.
2509         * lib/isnanl.h: New file.
2510         * lib/isnanl.c: New file.
2511         * m4/isnanl.m4: New file.
2512
2513 2007-02-24  Bruno Haible  <bruno@clisp.org>
2514
2515         * modules/isnan-nolibm-tests: New file.
2516         * tests/test-isnan.c: New file.
2517
2518         * modules/isnan-nolibm: New file.
2519         * lib/isnan.h: New file.
2520         * lib/isnan.c: New file.
2521         * m4/isnan.m4: New file.
2522
2523 2007-02-24  Bruno Haible  <bruno@clisp.org>
2524
2525         * lib/frexpl.c (frexpl): Correct return values for x = 1.0L. Don't
2526         assume that an exponent fits in 20 bits.
2527
2528 2007-02-24  Jim Meyering  <jim@meyering.net>
2529
2530         * m4/regex.m4: Update the description of the configure-time option,
2531         --without-included-regex, to state accurately what the defaults are,
2532         and perhaps to give people an idea why using this option is risky.
2533
2534 2007-02-24  Paul Eggert  <eggert@cs.ucla.edu>
2535
2536         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check for a nanosleep that
2537         loops on small arguments.  This attempts to avoid the problem
2538         Bruno Haible reported for AIX 4.3.2 in
2539         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00309.html>.
2540
2541 2007-02-23  Bruno Haible  <bruno@clisp.org>
2542
2543         * m4/perl.m4 (gl_PERL): Require version 5.005, not 5.003.
2544         Needed for help2man.
2545
2546 2007-02-23  Karl Berry  <karl@gnu.org>
2547
2548         * doc/gnulib-tool.texi (CVS Issues): mention that when foo_.h
2549         exists, foo.h should be cvs-ignored, not committed.
2550
2551 2007-02-23  Eric Blake  <ebb9@byu.net>
2552
2553         * lib/getdate.h (includes):  Include <time.h>, not "timespec.h".
2554         * lib/stat-time.h (includes): Likewise.
2555         * lib/utimecmp.c (includes): Likewise.
2556         * lib/utimens.h (includes): Likewise.
2557         * lib/getdate.y (includes): Also include "timespec.h" for use
2558         internal to the module.
2559         * modules/utimens (Depends-on): Revert yesterday's patch.
2560         * modules/nanosleep (Depends-on): Add missing dependency.
2561
2562 2007-02-22  Bruno Haible  <bruno@clisp.org>
2563
2564         * lib/glob.c: Don't include getlogin_r.h.
2565
2566 2007-02-22  Jim Meyering  <jim@meyering.net>
2567
2568         * modules/utimens (Depends-on): Add timespec, required for
2569         utimens.h's inclusion of timespec.h.
2570
2571 2007-02-21  Paul Eggert  <eggert@cs.ucla.edu>
2572
2573         * lib/getcwd.c (__getcwd): Undo previous change; it mishandled
2574         long unreadable paths in GNU/Linux.  Problem reported by Andreas
2575         Schwab in
2576         <http://lists.gnu.org/archive/html/bug-gnulib/2007-02/msg00261.html>.
2577         I'll try to think of a better way to fix the Solaris problem.
2578
2579         * lib/getcwd.c (__getcwd): Don't assume getcwd (NULL, 0) works
2580         like glibc; on Solaris 10, it fails with errno == EINVAL.
2581         POSIX says the behavior is unspecified if the first argument is NULL,
2582         so play it safe and never pass NULL to the system getcwd.
2583
2584 2007-02-21  Jim Meyering  <jim@meyering.net>
2585
2586         * lib/gettimeofday.c (rpl_gettimeofday): Remove declaration
2587         of gettimeofday.  It would conflict with the one now always
2588         provided via sys_time_.h.  Reported by Matthew Woehlke, as
2589         an IRIX 6.5 build failure.
2590
2591 2007-02-20  Paul Eggert  <eggert@cs.ucla.edu>
2592
2593         Minor fixups to port to Solaris 10 with Sun C 5.8.
2594         * lib/getcwd.c [!_LIBC]: Include dirfd.h, since we use dirfd.
2595         * modules/getcwd (Depends-on): Add dirfd.
2596         * lib/putenv.c (putenv): #undef it.
2597         (rpl_putenv): New decl.
2598         (malloc, free): Include <stdlib.h> rather than prototyping separately.
2599
2600 2007-02-20  Bruno Haible  <bruno@clisp.org>
2601
2602         * modules/stdio-tests: New file.
2603         * tests/test-stdio.c: New file.
2604
2605         * modules/vsnprintf (Files): Remove lib/vsnprintf.h.
2606         (Depends-on): Add stdio.
2607         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
2608         (Include): Use <stdio.h> instead of vsnprintf.h.
2609         * m4/vsnprintf.m4 (gl_FUNC_VSNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
2610         HAVE_DECL_VSNPRINTF.
2611         * lib/vsnprintf.c: Include <stdio.h> instead of vsnprintf.h.
2612
2613         * modules/snprintf (Files): Remove lib/snprintf.h.
2614         (Depends-on): Add stdio.
2615         (configure.ac): Invoke gl_STDIO_MODULE_INDICATOR.
2616         (Include): Use <stdio.h> instead of snprintf.h.
2617         * m4/snprintf.m4 (gl_FUNC_SNPRINTF): Require gl_STDIO_H_DEFAULTS. Set
2618         HAVE_DECL_SNPRINTF.
2619         * lib/snprintf.c: Include <stdio.h> instead of snprintf.h.
2620         * lib/getaddrinfo.c: Likewise.
2621
2622         * modules/stdio: New file.
2623         * lib/stdio_.h: New file, incorporating snprintf.h and vsnprintf.h.
2624         * lib/snprintf.h: Remove file.
2625         * lib/vsnprintf.h: Remove file.
2626         * lib/.cppi-disable: Remove snprintf.h.
2627         * m4/stdio_h.m4: New file.
2628         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdio.
2629
2630 2007-02-20  Jim Meyering  <jim@meyering.net>
2631
2632         * lib/ftruncate.c [HAVE_CHSIZE]: Document that this code is
2633         used by e.g., mingw.  From Bruno Haible.
2634
2635 2007-02-19  Bruno Haible  <bruno@clisp.org>
2636
2637         * lib/string_.h: Use "#pragma GCC system_header" to suppress some gcc
2638         warnings.
2639         Reported by Ben Pfaff <blp@cs.stanford.edu>.
2640
2641 2007-02-19  Bruno Haible  <bruno@clisp.org>
2642
2643         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Don't request a complaint mail
2644         from mingw users.
2645
2646 2007-02-19  Bruno Haible  <bruno@clisp.org>
2647
2648         * lib/stdlib_.h: Use "#pragma GCC system_header" to suppress some gcc
2649         warnings.
2650         Reported by Joel E. Denny <jdenny@ces.clemson.edu> via Paul Eggert.
2651
2652 2007-02-19  Jim Meyering  <jim@meyering.net>
2653
2654         Don't use FD after a successful "fdopendir (fd)".
2655         * lib/getcwd.c (__getcwd) [AT_FDCWD]: fdopendir (fd) usually closes fd.
2656         Reset it by calling dirfd on the just-obtained DIR*.
2657
2658         * m4/ftruncate.m4: Adjust comment to give this module a 3-year reprieve.
2659         Prompted by a report from Bruno Haible that mingw lacks ftruncate.
2660
2661 2007-02-18  Bruno Haible  <bruno@clisp.org>
2662
2663         * lib/readlink.c: Include <unistd.h>.
2664         * m4/readlink.m4 (gl_FUNC_READLINK): Require gl_UNISTD_H_DEFAULTS. Set
2665         HAVE_READLINK.
2666         * modules/readlink (Depends-on): Add unistd.
2667         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2668         (Include): Add <unistd.h>.
2669
2670         * lib/getlogin_r.h: Remove file.
2671         * lib/getlogin_r.c: Include <unistd.h> instead of getlogin_r.h.
2672         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE): Remove macro.
2673         (gl_GETLOGIN_R): Inline it here. Require gl_UNISTD_H_DEFAULTS. Set
2674         HAVE_DECL_GETLOGIN_R.
2675         * modules/getlogin_r (Files): Remove lib/getlogin_r.h.
2676         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2677         (Include): Use <unistd.h> instead of getlogin_r.h.
2678
2679         * lib/getcwd.h: Remove file.
2680         * lib/getcwd.c: Include <unistd.h> instead of getcwd.h.
2681         * lib/xgetcwd.c: Likewise.
2682         * m4/getcwd.m4 (gl_FUNC_GETCWD): Require gl_UNISTD_H_DEFAULTS. Set
2683         REPLACE_GETCWD. Don't define __GETCWD_PREFIX.
2684         * modules/getcwd (Files): Remove lib/getcwd.h.
2685         (Depends-on): Add unistd.
2686         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2687         (Include): Use <unistd.h> instad of getcwd.h.
2688
2689         * lib/ftruncate.c: Include <unistd.h> first.
2690         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): Require gl_UNISTD_H_DEFAULTS.
2691         Set HAVE_FTRUNCATE.
2692         * modules/ftruncate (Depends-on): Add unistd.
2693         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2694
2695         * lib/fchdir.c: Include <unistd.h> first.
2696         * lib/dirent_.h: Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT.
2697         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_UNISTD_H_DEFAULTS instead
2698         of gl_HEADER_UNISTD_DEFAULTS. Set REPLACE_FCHDIR. Don't set UNISTD_H.
2699         * modules/fchdir (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2700         (Makefile.am): Substitute also REPLACE_FCHDIR into dirent.h.
2701
2702         * lib/dup2.c: Include <unistd.h> first.
2703         * m4/dup2.m4 (gl_FUNC_DUP2): Require gl_UNISTD_H_DEFAULTS. Set
2704         HAVE_DUP2.
2705         * modules/dup2 (Depends-on): Add unistd.
2706         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2707
2708         * lib/chown.c: Include <unistd.h> first. Undefine chown later.
2709         * m4/chown.m4 (gl_FUNC_CHOWN): Require gl_UNISTD_H_DEFAULTS. Set
2710         REPLACE_CHOWN. Don't define chown as a macro here.
2711         * modules/chown (Depends-on): Add unistd.
2712         (configure.ac): Invoke gl_UNISTD_MODULE_INDICATOR.
2713
2714         * lib/unistd_.h: Test HAVE_UNISTD_H determined at configure time.
2715         Add definition for GL_LINK_WARNING.
2716         (chown, dup2): New declarations.
2717         (fchdir): Test REPLACE_FCHDIR, not FCHDIR_REPLACEMENT. Provide optional
2718         link warning.
2719         (ftruncate): New declaration.
2720         (getcwd): New declaration, taken from old getcwd.h.
2721         (getlogin_r): New declaration, taken from old getlogin_r.h.
2722         (readlink): New declaration.
2723         * m4/unistd_h.m4 (gl_UNISTD_H): Renamed from gl_HEADER_UNISTD. Don't
2724         set UNISTD_H. Inline gl_PREREQ_UNISTD. Set HAVE_UNISTD_H.
2725         (gl_PREREQ_UNISTD): Remove macro.
2726         (gl_UNISTD_MODULE_INDICATOR): New macro.
2727         (gl_UNISTD_H_DEFAULTS): Renamed from gl_HEADER_UNISTD_DEFAULTS. Set
2728         many new variables. Don't set UNISTD_H.
2729         * modules/unistd (Description): Change.
2730         (Depends-on): Add link-warning.
2731         (configure.ac): Update.
2732         (Makefile.am): Create unistd.h always. Substitute many new variables
2733         into it.
2734
2735 2007-02-18  Bruno Haible  <bruno@clisp.org>
2736
2737         * lib/stdlib_.h (getsubopt): New declaration, copied from getsubopt.h.
2738         * modules/stdlib (stdlib.h): Also substitute GNULIB_GETSUBOPT and
2739         HAVE_GETSUBOPT.
2740         * m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Also initialize
2741         GNULIB_GETSUBOPT and HAVE_GETSUBOPT.
2742         * lib/getsubopt.h: Remove file.
2743         * modules/getsubopt (Files): Remove lib/getsubopt.h.
2744         (Depends-on): Add stdlib.
2745         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2746         (Includes): Use <stdlib.h> instead of getsubopt.h.
2747         * m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Require gl_STDLIB_H_DEFAULTS.
2748         Set HAVE_GETSUBOPT.
2749         * lib/getsubopt.c: Don't include getsubopt.h.
2750
2751 2007-02-18  Bruno Haible  <bruno@clisp.org>
2752
2753         * modules/fchdir (Depends-on): Add dup2.
2754
2755 2007-02-18  Bruno Haible  <bruno@clisp.org>
2756
2757         * lib/stdlib_.h: Handle glibc's special invocation convention
2758         specially.
2759
2760 2007-02-18  Bruno Haible  <bruno@clisp.org>
2761
2762         * modules/stdlib-tests: New file.
2763         * tests/test-stdlib.c: New file.
2764
2765         * modules/mkstemp (Files): Remove lib/mkstemp.h.
2766         (Depends-on): Add stdlib.
2767         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2768         (Includes): Use <stdlib.h> instead of mkstemp.h.
2769         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2770         REPLACE_MKSTEMP. Remove definition of __MKSTEMP_PREFIX.
2771         * lib/mkstemp.c: Don't include mkstemp.h.
2772         * lib/mkstemp-safer.c: Include <stdlib.h> instead of mkstemp.h.
2773         * lib/stdlib--.h: Don't include mkstemp.h.
2774
2775         * modules/mkdtemp (Files): Remove lib/mkdtemp.h.
2776         (Depends-on): Add stdlib.
2777         (configure.ac): Invoke gl_STDLIB_MODULE_INDICATOR.
2778         (Includes): Use <stdlib.h> instead of mkdtemp.h.
2779         * m4/mkdtemp.m4 (gt_FUNC_MKDTEMP): Require gl_STDLIB_H_DEFAULTS. Set
2780         HAVE_MKDTEMP.
2781         * lib/mkdtemp.c: Don't include mkdtemp.h.
2782         * lib/clean-temp.c: Don't include mkdtemp.h.
2783
2784         * modules/exit (Files): Remove lib/exit.h.
2785         (Depends-on): Add stdlib.
2786         (Makefile.am): Remove lib_SOURCES.
2787         (Include): Use <stdlib.h> instead of exit.h.
2788         * lib/argmatch.c: Don't include exit.h.
2789         * lib/execute.c: Likewise.
2790         * lib/pagealign_alloc.c: Likewise.
2791         * lib/pipe.c: Likewise.
2792         * lib/wait-process.c: Likewise.
2793         * lib/copy-file.c: Include <stdlib.h> instead of exit.h.
2794         * lib/exitfail.c: Likewise.
2795         * lib/savewd.c: Likewise.
2796         * lib/xsetenv.c: Likewise.
2797
2798         * modules/stdlib: New file.
2799         * lib/stdlib_.h: New file, incorporating exit.h, mkdtemp.h, mkstemp.h
2800         and extra comments about mkstemp().
2801         * lib/exit.h: Remove file.
2802         * lib/mkdtemp.h: Remove file.
2803         * lib/mkstemp.h: Remove file.
2804         * m4/stdlib_h.m4: New file.
2805         * MODULES.html.sh (Support for systems lacking ANSI C 89): Add stdlib.
2806
2807 2007-02-18  Bruno Haible  <bruno@clisp.org>
2808
2809         * modules/math-tests: New file.
2810         * tests/test-math.c: New file.
2811
2812         * modules/math: New file.
2813         * modules/mathl (Files): Remove lib/mathl.h.
2814         (Depends-on): Add math.
2815         (Makefile.am): Don't mention mathl.h.
2816         (Include): Use <math.h> instead of mathl.h.
2817         * lib/math_.h: New file.
2818         * lib/mathl.h: Remove file.
2819         * lib/acosl.c: Include <config.h> and <math.h> first. Don't include
2820         mathl.h.
2821         * lib/asinl.c: Likewise.
2822         * lib/atanl.c: Likewise.
2823         * lib/ceill.c: Likewise.
2824         * lib/cosl.c: Likewise.
2825         * lib/expl.c: Likewise.
2826         * lib/floorl.c: Likewise.
2827         * lib/frexpl.c: Likewise.
2828         * lib/ldexpl.c: Likewise.
2829         * lib/logl.c: Likewise.
2830         * lib/sincosl.c: Likewise.
2831         * lib/sinl.c: Likewise.
2832         * lib/sqrtl.c: Likewise.
2833         * lib/tanl.c: Likewise.
2834         * lib/trigl.c: Likewise.
2835         * m4/math_h.m4: New file.
2836         * MODULES.html.sh (Mathematics): Add math.
2837
2838 2007-02-17  Bruno Haible  <bruno@clisp.org>
2839
2840         * modules/wctype-tests: New file.
2841         * tests/test-wctype.c: New file.
2842
2843         * modules/wchar-tests: New file.
2844         * tests/test-wchar.c: New file.
2845
2846         * modules/unistd-tests: New file.
2847         * tests/test-unistd.c: New file.
2848
2849         * modules/time-tests: New file.
2850         * tests/test-time.c: New file.
2851
2852         * modules/sysexits-tests: New file.
2853         * tests/test-sysexits.c: New file.
2854
2855         * modules/sys_time-tests: New file.
2856         * tests/test-sys_time.c: New file.
2857
2858         * modules/sys_stat-tests: New file.
2859         * tests/test-sys_stat.c: New file.
2860
2861         * modules/sys_socket-tests: New file.
2862         * tests/test-sys_socket.c: New file.
2863
2864         * modules/sys_select-tests: New file.
2865         * tests/test-sys_select.c: New file.
2866
2867         * modules/string-tests: New file.
2868         * tests/test-string.c: New file.
2869
2870         * modules/stdbool-tests: New file.
2871         * tests/test-stdbool.c: New file.
2872
2873         * modules/netinet_in-tests: New file.
2874         * tests/test-netinet_in.c: New file.
2875
2876         * modules/inttypes-tests: New file.
2877         * tests/test-inttypes.c: New file.
2878
2879         * modules/fcntl-tests: New file.
2880         * tests/test-fcntl.c: New file.
2881
2882         * modules/byteswap-tests: New file.
2883         * tests/test-byteswap.c: New file.
2884
2885         * modules/arpa_inet-tests: New file.
2886         * tests/test-arpa_inet.c: New file.
2887
2888 2007-02-17  Bruno Haible  <bruno@clisp.org>
2889
2890         * lib/inttypes_.h: Add definition for GL_LINK_WARNING.
2891         (imaxabs, imaxdiv, strtoimax, strtoumax): Don't declare the function
2892         if the corresponding module is not enabled. Emit link warnings if
2893         the function is used nevertheless.
2894         * m4/inttypes.m4 (gl_INTTYPES_H): Never use the existing <inttypes.h>.
2895         Don't AC_SUBST HAVE_DECL_IMAXABS, HAVE_DECL_IMAXDIV,
2896         HAVE_DECL_STRTOIMAX, HAVE_DECL_STRTOUMAX.
2897         (gl_INTTYPES_MODULE_INDICATOR, gl_INTTYPES_H_DEFAULTS): New macros.
2898         * modules/inttypes (Depends-on): Add link-warning.
2899         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2900         inttypes.h. Substitute also GNULIB_IMAXABS, GNULIB_IMAXDIV,
2901         GNULIB_STRTOIMAX, GNULIB_STRTOUMAX.
2902         * modules/imaxabs (configure.ac): Invoke gl_INTTYPES_MODULE_INDICATOR.
2903         * modules/imaxdiv (configure.ac): Likewise.
2904         * modules/strtoimax (configure.ac): Likewise.
2905         * modules/strtoumax (configure.ac): Likewise.
2906
2907 2007-02-17  Bruno Haible  <bruno@clisp.org>
2908
2909         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Include the contents of
2910         gl_STRING_MODULE_INDICATOR_DEFAULTS.
2911         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Remove macro.
2912         (gl_HEADER_STRING_H_BODY, gl_STRING_MODULE_INDICATOR): Update.
2913
2914 2007-02-17  Bruno Haible  <bruno@clisp.org>
2915
2916         * modules/link-warning: New file.
2917         * build-aux/link-warning.h: New file, extracted from lib/string_.h.
2918         * lib/string_.h (GL_LINK_WARNING): Remove definition.
2919         * modules/string (Depends-on): Add link-warning.
2920         (Makefile.am): Copy the contents of build-aux/link-warning.h into
2921         string.h.
2922         * MODULES.html.sh (Support for building libraries and executables): Add
2923         link-warning.
2924
2925 2007-02-17  Bruno Haible  <bruno@clisp.org>
2926
2927         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strcasecmp,
2928         strncasecmp, strchr, strchrnul, strdup, strndup, strnlen, strcspn,
2929         strpbrk, strspn, strrchr, strsep, strstr, strcasestr, strtok_r): Break
2930         long lines.
2931
2932 2007-02-17  Ben Pfaff  <blp@cs.stanford.edu>
2933             Bruno Haible  <bruno@clisp.org>
2934
2935         * modules/tmpfile: New file.
2936         * lib/tmpfile.c: New file.
2937         * m4/tmpfile.m4: New file.
2938         * MODULES.html.sh (func_all_modules): New section "Input/output".
2939
2940 2007-02-15  Bruno Haible  <bruno@clisp.org>
2941
2942         * lib/clean-temp.c [WIN32 && !CYGWIN]: Include <windows.h>.
2943         (supports_delete_on_close): New function.
2944         (open_temp, fopen_temp): Use _O_TEMPORARY when supported.
2945
2946 2007-02-14  Bruno Haible  <bruno@clisp.org>
2947
2948         * modules/mbspcasecmp-tests: New file.
2949         * tests/test-mbspcasecmp.sh: New file.
2950         * tests/test-mbspcasecmp.c: New file.
2951
2952         New module mbspcasecmp.
2953         * modules/mbspcasecmp: New file.
2954         * lib/mbspcasecmp.c: New file.
2955         * lib/string_.h (strncasecmp): Change warning message.
2956         (mbspcasecmp): New declaration.
2957         * m4/mbspcasecmp.m4: New file.
2958         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2959         GNULIB_MBSPCASECMP.
2960         * modules/string (string.h): Also substitute GNULIB_MBSPCASECMP.
2961         * MODULES.html.sh (Internationalization functions): Add mbspcasecmp.
2962
2963 2007-02-14  Bruno Haible  <bruno@clisp.org>
2964
2965         * modules/mbsncasecmp-tests: New file.
2966         * tests/test-mbsncasecmp.sh: New file.
2967         * tests/test-mbsncasecmp.c: New file.
2968
2969         New module mbsncasecmp.
2970         * modules/mbsncasecmp: New file.
2971         * lib/mbsncasecmp.c: New file.
2972         * lib/string_.h (mbsncasecmp): New declaration.
2973         * m4/mbsncasecmp.m4: New file.
2974         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
2975         GNULIB_MBSNCASECMP.
2976         * modules/string (string.h): Also substitute GNULIB_MBSNCASECMP.
2977         * MODULES.html.sh (Internationalization functions): Add mbsncasecmp.
2978
2979 2007-02-14  Paul Eggert  <eggert@cs.ucla.edu>
2980
2981         * lib/exclude.c (FNM_EXTMATCH): Define if system does not.
2982         Verify that it doesn't overlap with our flags.
2983         (fnmatch_no_wildcards): Don't use strcasecmp or strncasecmp, which
2984         do not have the desired effect in multibyte locales; instead, use
2985         mbscasecmp.
2986         * modules/exclude (Depends-on): Depend on mbscasecmp, not strcase.
2987         Add dependency on xalloc.  Depend on fnmatch, not fnmatch-gnu, since
2988         we don't require GNU fnmatch ourselves (if our users require it, they
2989         should do so explicitly).
2990
2991         Fix regex code so it doesn't rely on strcasecmp.
2992         * lib/regex_internal.h: Include <langinfo.h> only if _LIBC is defined.
2993         Otherwise, include gnulib's langinfo.h.
2994         * lib/regcomp.c (init_dfa): Don't use strcasecmp, as it can have
2995         undesirable behavior in non-C locales.  Instead, rely on localecharset.
2996         * m4/regex.m4 (gl_PREREQ_REGEX): Don't require AM_LANGINFO_CODESET.
2997         * modules/regex (FILES): Remove m4/codeset.m4.
2998         (Depends-on): Add localcharset.  Remove strcase.
2999
3000 2007-02-13  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3001
3002         * m4/unlinkdir.m4 (gl_UNLINKDIR): Fix m4 quoting bug.
3003         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Likewise.
3004
3005 2007-02-13  Bruno Haible  <bruno@clisp.org>
3006
3007         * m4/intdiv0.m4 (gt_INTDIV0): Assume ANSI C. Fix underquoting bug.
3008         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3009
3010 2007-02-12  Bruno Haible  <bruno@clisp.org>
3011
3012         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
3013         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): If
3014         GNULIB_POSIXCHECK and the gnulib module not enabled, provoke a link-
3015         time warning rather than a link error.
3016
3017 2007-02-12  Bruno Haible  <bruno@clisp.org>
3018
3019         * m4/locale-fr.m4 (gt_LOCALE_FR): Fix m4 quoting bug.
3020         * m4/locale-zh.m4 (gt_LOCALE_ZH_CN): Likewise.
3021         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
3022
3023 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
3024
3025         * lib/string_.h (strncasecmp): Fix typo: this macro takes 3
3026         args, not 2.
3027
3028 2007-02-12  Paul Eggert  <eggert@cs.ucla.edu>
3029
3030         New module 'time', so that apps can include <time.h> as per
3031         POSIX and GNU instead of separate include files like time_r.h
3032         and timegm.h.  This implementation tries out a simpler approach
3033         for replacing decls in standard include files (as compared to
3034         the string module), somewhat as an experiment.
3035
3036         * config/srclist.txt: Comment out mktime.c for now.
3037         * doc/gnulib-tool.texi (Initial import): Don't use time_r as an example
3038         since it doesn't apply any more.  Use generic wording instead.
3039         * MODULES.html.sh (Support for systems lacking POSIX:2001): New module
3040         'time'.
3041         * lib/time_.h, m4/time_h.m4, modules/time: New files.
3042         * lib/strptime.h, lib/time_r.h, lib/timegm.h: Remove.
3043         * lib/mktime.c: Include config.h depending on _LIBC, not HAVE_CONFIG_H.
3044         Don't include <sys/types.h>; no longer needed since we assume C89.
3045         * lib/mktime.c: Don't include "time_r.h"; no longer needed.
3046         * lib/strftime.c: Likewise.
3047         * lib/time_r.c: Likewise.
3048         * lib/nanosleep.c (nanosleep): #undef after include files, not before.
3049         * lib/nanosleep.c: Include <time.h> first, to check interface.
3050         * lib/strptime.c: Likewise.
3051         * lib/time_r.c: Likewise.
3052         * lib/timegm.c: Likewise.
3053         * lib/strptime.c: Don't include strptime.h or time_r.h; no longer
3054         needed.
3055         * lib/timegm.c: Don't include timegm.h; no longer needed.
3056         * lib/timespec.h: Don't include <sys/time.h> before <time.h>;
3057         time.h now handles any problems in that area.
3058         (struct timespec, nanosleep): Remove; time.h now arranges for these.
3059         * lib/xnanosleep.c: Don't include timespec.h; no longer needed now
3060         that time.h defines struct timespec.
3061         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Check that nanosleep is declared.
3062         Set REPLACE_NANOSLEEP.  Don't AC_DEFINE nanosleep; the time module now
3063         handles that.
3064         * m4/strptime.m4 (gl_FUNC_STPRTIME): Set REPLACE_STRPTIME.
3065         * m4/time_r.m4 (gl_TIME_R): Don't define HAVE_TIME_R_POSIX; no longer
3066         needed.  Set REPLACE_LOCALTIME.
3067         * m4/timegm.m4 (gl_FUNC_TIMEGM): Set REPLACE_TIMEGM.
3068         * m4/timespec.m4 (gl_CHECK_TYPE_STRUCT_TIMESPEC): Move to time_h.m4.
3069         (gl_TIMESPEC): Don't check for sys/time.h or struct timespec or
3070         nanosleep; time_h.m4 now does that.  Don't require
3071         gl_USE_SYSTEM_EXTENSIONS; no longer needed directly, and the time
3072         module handles this now.
3073         * modules/getdate (Depends-on): Remove timespec.  Add time.
3074         * modules/nanosleep (Depends-on): Likewise.
3075         * modules/stat-time (Depends-on): Likewise.
3076         * modules/nanosleep (Include): Include time.h, not timespec.h.
3077         * modules/strptime (Files): Remove lib/strptime.h.
3078         (Depends-on): Add extensions, time.
3079         (Include): Include time.h, not strptime.h.
3080         * modules/time_r (Files): Remove lib/time_r.h.
3081         (Depends-on): Add time.
3082         (Include): Include time.h, not time_r.h.
3083         * modules/timegm: Likewise.
3084         * modules/timespec (Description): Now does timespec-related decls
3085         of our own, instead of struct timespec itself.
3086         (Depends-on): Add time; remove extensions.
3087         (Maintainer): Add self.
3088         * modules/utimecmp (Depends-on): Add time; remove timespec.
3089         * modules/utimens (Depends-on): Likewise.
3090         * modules/xnanosleep (Depends-on): Likewise.
3091
3092 2007-02-11  Bruno Haible  <bruno@clisp.org>
3093
3094         * lib/c-strstr.c: Include allocsa.h.
3095         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3096         * lib/c-strcasestr.c: Include allocsa.h.
3097         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3098         * lib/strcasestr.c: Include allocsa.h.
3099         (knuth_morris_pratt): Use allocsa/freesa instead of malloc/free.
3100         * lib/mbsstr.c: Include allocsa.h.
3101         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
3102         allocsa/freesa instead of malloc/free.
3103         * lib/mbscasestr.c: Include allocsa.h.
3104         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): Use
3105         allocsa/freesa instead of malloc/free.
3106         * modules/c-strstr (Depends-on): Add allocsa.
3107         * modules/c-strcasestr (Depends-on): Likewise.
3108         * modules/strcasestr (Depends-on): Likewise.
3109         * modules/mbsstr (Depends-on): Likewise.
3110         * modules/mbscasestr (Depends-on): Likewise.
3111
3112 2007-02-11  Bruno Haible  <bruno@clisp.org>
3113
3114         * lib/mbsspn.c (mbsspn): Fix bug. Remove unnecessary strlen call.
3115
3116         * modules/mbsspn-tests: New file.
3117         * tests/test-mbsspn.sh: New file.
3118         * tests/test-mbsspn.c: New file.
3119
3120 2007-02-11  Bruno Haible  <bruno@clisp.org>
3121
3122         * lib/mbspbrk.c (mbspbrk): Remove unneeded cast.
3123
3124         * modules/mbspbrk-tests: New file.
3125         * tests/test-mbspbrk.sh: New file.
3126         * tests/test-mbspbrk.c: New file.
3127
3128 2007-02-11  Bruno Haible  <bruno@clisp.org>
3129
3130         * lib/mbscspn.c (mbscspn): Remove unnecessary strlen call and
3131         unneeded cast.
3132
3133         * modules/mbscspn-tests: New file.
3134         * tests/test-mbscspn.sh: New file.
3135         * tests/test-mbscspn.c: New file.
3136
3137 2007-02-11  Bruno Haible  <bruno@clisp.org>
3138
3139         * modules/mbscasecmp-tests: New file.
3140         * tests/test-mbscasecmp.sh: New file.
3141         * tests/test-mbscasecmp.c: New file.
3142
3143 2007-02-11  Bruno Haible  <bruno@clisp.org>
3144
3145         Ensure O(n) worst-case complexity of mbscasestr.
3146         * lib/mbscasestr.c: Include stdbool.h.
3147         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
3148         functions.
3149         (mbscasestr): Add some bookkeeping. Invoke knuth_morris_pratt_* when
3150         the bookkeeping indicates that it's worth it.
3151         * modules/mbscasestr (Depends-on): Add stdbool, mbslen, strnlen.
3152
3153         * modules/mbscasestr-tests: New file.
3154         * tests/test-mbscasestr1.c: New file.
3155         * tests/test-mbscasestr2.sh: New file.
3156         * tests/test-mbscasestr2.c: New file.
3157         * tests/test-mbscasestr3.sh: New file.
3158         * tests/test-mbscasestr3.c: New file.
3159         * tests/test-mbscasestr4.sh: New file.
3160         * tests/test-mbscasestr4.c: New file.
3161         * m4/locale-tr.m4: New file.
3162
3163 2007-02-11  Bruno Haible  <bruno@clisp.org>
3164
3165         Ensure O(n) worst-case complexity of mbsstr.
3166         * lib/mbsstr.c: Include stdbool.h.
3167         (knuth_morris_pratt_unibyte, knuth_morris_pratt_multibyte): New
3168         functions.
3169         (mbsstr): Add some bookkeeping. Invoke knuth_morris_pratt_* when the
3170         bookkeeping indicates that it's worth it.
3171         * modules/mbsstr (Depends-on): Add stdbool, mbslen, strnlen.
3172
3173         * modules/mbsstr-tests: New file.
3174         * tests/test-mbsstr1.c: New file.
3175         * tests/test-mbsstr2.sh: New file.
3176         * tests/test-mbsstr2.c: New file.
3177         * tests/test-mbsstr3.sh: New file.
3178         * tests/test-mbsstr3.c: New file.
3179         * m4/locale-fr.m4: New file.
3180
3181 2007-02-11  Bruno Haible  <bruno@clisp.org>
3182
3183         * lib/mbsrchr.c (mbsrchr): Fix bug.
3184
3185         * modules/mbsrchr-tests: New file.
3186         * tests/test-mbsrchr.sh: New file.
3187         * tests/test-mbsrchr.c: New file.
3188
3189 2007-02-11  Bruno Haible  <bruno@clisp.org>
3190
3191         * lib/mbschr.c (mbschr): Fix bug.
3192
3193         * modules/mbschr-tests: New file.
3194         * tests/test-mbschr.sh: New file.
3195         * tests/test-mbschr.c: New file.
3196         * m4/locale-zh.m4: New file.
3197
3198 2007-02-11  Bruno Haible  <bruno@clisp.org>
3199
3200         Support for copying multibyte string iterators.
3201         * lib/mbiter.h: Include <string.h>.
3202         (mbiter_multi_copy): New function.
3203         (mbi_copy): New macro.
3204         * lib/mbuiter.h: Include <string.h>.
3205         (mbuiter_multi_copy): New function.
3206         (mbui_copy): New macro.
3207
3208 2007-02-11  Bruno Haible  <bruno@clisp.org>
3209
3210         New module mbslen.
3211         * modules/mbslen: New file.
3212         * lib/mbslen.c: New file.
3213         * lib/string_.h (mbslen): New declaration.
3214         * m4/mbslen.m4: New file.
3215         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3216         GNULIB_MBSLEN.
3217         * modules/string (string.h): Also substitute GNULIB_MBSLEN.
3218         * MODULES.html.sh (Internationalization functions): Add mbslen.
3219
3220 2007-02-11  Bruno Haible  <bruno@clisp.org>
3221
3222         Ensure O(n) worst-case complexity of strcasestr substitute.
3223         * lib/strcasestr.c: Include stdbool.h.
3224         (knuth_morris_pratt): New function.
3225         (strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3226         bookkeeping indicates that it's worth it.
3227         * modules/strcasestr (Depends-on): Add stdbool, strnlen.
3228
3229         * modules/strcasestr-tests: New file.
3230         * tests/test-strcasestr.c: New file.
3231
3232 2007-02-11  Bruno Haible  <bruno@clisp.org>
3233
3234         Ensure O(n) worst-case complexity of c_strcasestr.
3235         * lib/c-strcasestr.c: Include stdbool.h, string.h.
3236         (knuth_morris_pratt): New function.
3237         (c_strcasestr): Add some bookkeeping. Invoke knuth_morris_pratt when
3238         the bookkeeping indicates that it's worth it.
3239         * modules/c-strcasestr (Depends-on): Add stdbool, strnlen.
3240
3241         * modules/c-strcasestr-tests: New file.
3242         * tests/test-c-strcasestr.c: New file.
3243
3244 2007-02-11  Bruno Haible  <bruno@clisp.org>
3245
3246         Ensure O(n) worst-case complexity of c_strstr.
3247         * lib/c-strstr.c: Include stdbool.h, string.h.
3248         (knuth_morris_pratt): New function.
3249         (c_strstr): Add some bookkeeping. Invoke knuth_morris_pratt when the
3250         bookkeeping indicates that it's worth it.
3251         * modules/c-strstr (Depends-on): Add stdbool, strnlen.
3252
3253         * lib/c-strstr.c: Complete rewrite for maintainability.
3254
3255         * modules/c-strstr-tests: New file.
3256         * tests/test-c-strstr.c: New file.
3257
3258 2007-02-11  Bruno Haible  <bruno@clisp.org>
3259
3260         * m4/javacomp.m4 (gt_JAVACOMP): Work around a 'tr' bug in coreutils
3261         5.2.1 and earlier, whereby \055 was treated just like the range
3262         delimiter '-'.
3263         Reported by Joel E. Denny <jdenny@ces.clemson.edu>.
3264
3265 2007-02-08  Bruno Haible  <bruno@clisp.org>
3266
3267         * modules/regex (Depends-on): Add stdbool.
3268         Reported by Dalibor Topic <robilad@kaffe.org>.
3269
3270 2007-02-05  Paul Eggert  <eggert@cs.ucla.edu>
3271
3272         * m4/regex.m4 (gl_REGEX): Check for glibc bug #3957.
3273         Prefer returning from main to exiting from it.
3274         Remove unnecessary parens after sizeof.
3275
3276 2007-02-05  Bruno Haible  <bruno@clisp.org>
3277
3278         New module mbssep.
3279         * modules/mbssep: New file.
3280         * lib/mbssep.c: New file.
3281         * lib/string_.h (strsep): Add a conditional link warning.
3282         (mbssep): New declaration.
3283         * m4/mbssep.m4: New file.
3284         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3285         GNULIB_MBSSEP.
3286         * modules/string (string.h): Also substitute GNULIB_MBSSEP.
3287         * MODULES.html.sh (Internationalization functions): Add mbssep.
3288
3289 2007-02-05  Bruno Haible  <bruno@clisp.org>
3290
3291         * lib/strsep.c (strsep): Fix actions in case of no delimiters.
3292         Optimize search in case of 1 delimiter.
3293
3294 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3295
3296         * lib/acl.h: Include sys/types.h before sys/acl.h.
3297
3298 2007-02-05  Paolo Bonzini  <bonzini@gnu.org>
3299
3300         Merge upstream fix for glibc bugzilla #3957:
3301
3302         2007-02-05  Jakub Jelinek  <jakub@redhat.com>
3303
3304         * lib/regcomp.c (parse_bracket_exp): Set '\n' bit rather than '\0'
3305         bit for RE_HAT_LISTS_NOT_NEWLINE.
3306         (build_charclass_op): Remove bogus comment.
3307
3308 2007-02-05  Simon Josefsson  <simon@josefsson.org>
3309
3310         * lib/gc.h, lib/gc-libgcrypt.c: Support SHA-256/384/512.
3311
3312 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
3313
3314         * lib/getsubopt.c [!_LIBC]: Include config.h and getsubopt.h.
3315         * lib/memmem.c [!defined _LIBC]: Include config.h.
3316
3317 2007-02-04  Bruno Haible  <bruno@clisp.org>
3318
3319         * lib/string_.h (GL_LINK_WARNING2): Put the word "warning:" into the
3320         warning message.
3321
3322 2007-02-04  Bruno Haible  <bruno@clisp.org>
3323
3324         New module mbstok_r.
3325         * modules/mbstok_r: New file.
3326         * lib/mbstok_r.c: New file.
3327         * lib/string_.h (strtok_r): Change argument names to match the
3328         comments. Add a conditional link warning.
3329         (mbstok_r): New declaration.
3330         * m4/mbstok_r.m4: New file.
3331         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3332         GNULIB_MBSTOK_R.
3333         * modules/string (string.h): Also substitute GNULIB_MBSTOK_R.
3334         * MODULES.html.sh (Internationalization functions): Add mbstok_r.
3335
3336 2007-02-04  Bruno Haible  <bruno@clisp.org>
3337
3338         New module mbsspn.
3339         * modules/mbsspn: New file.
3340         * lib/mbsspn.c: New file.
3341         * lib/string_.h (strspn): Add a conditional link warning.
3342         (mbsspn): New declaration.
3343         * m4/mbsspn.m4: New file.
3344         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3345         GNULIB_MBSSPN.
3346         * modules/string (string.h): Also substitute GNULIB_MBSSPN.
3347         * MODULES.html.sh (Internationalization functions): Add mbsspn.
3348
3349 2007-02-04  Bruno Haible  <bruno@clisp.org>
3350
3351         New module mbspbrk.
3352         * modules/mbspbrk: New file.
3353         * lib/mbspbrk.c: New file.
3354         * lib/string_.h (strpbrk): Add a conditional link warning.
3355         (mbspbrk): New declaration.
3356         * m4/mbspbrk.m4: New file.
3357         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3358         GNULIB_MBSPBRK.
3359         * modules/string (string.h): Also substitute GNULIB_MBSPBRK.
3360         * MODULES.html.sh (Internationalization functions): Add mbspbrk.
3361
3362 2007-02-04  Bruno Haible  <bruno@clisp.org>
3363
3364         New module mbscspn.
3365         * modules/mbscspn: New file.
3366         * lib/mbscspn.c: New file.
3367         * lib/string_.h (strcspn): Add a conditional link warning.
3368         (mbscspn): New declaration.
3369         * m4/mbscspn.m4: New file.
3370         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3371         GNULIB_MBSCSPN.
3372         * modules/string (string.h): Also substitute GNULIB_MBSCSPN.
3373         * MODULES.html.sh (Internationalization functions): Add mbscspn.
3374
3375 2007-02-04  Bruno Haible  <bruno@clisp.org>
3376
3377         New module mbscasestr, reduced goal of strcasestr.
3378         * modules/mbscasestr: New file.
3379         * lib/mbscasestr.c: New file, copied from lib/strcasestr.c.
3380         (mbscasestr): Renamed from strcasestr.
3381         * lib/strcasestr.c: Don't include mbuiter.h.
3382         (strcasestr): Remove support for multibyte locales.
3383         * lib/string_.h (strcasestr): Don`t rename. Declare only if missing.
3384         Change the conditional link warning.
3385         (mbscasestr): New declaration.
3386         * m4/mbscasestr.m4: New file.
3387         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Enable the replacement only if
3388         the system does not have strcasestr. Set HAVE_STRCASESTR instead of
3389         REPLACE_STRCASESTR.
3390         (gl_PREREQ_STRCASESTR): Don't require gl_FUNC_MBRTOWC.
3391         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
3392         HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3393         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSCASESTR.
3394         * modules/string (string.h): Also substitute GNULIB_MBSCASESTR.
3395         Substitute HAVE_STRCASESTR instead of REPLACE_STRCASESTR.
3396         * modules/strcasestr (Files): Remove m4/mbrtowc.m4.
3397         (Depends-on): Remove mbuiter.
3398         * MODULES.html.sh (Internationalization functions): Add mbscasestr.
3399
3400 2007-02-04  Bruno Haible  <bruno@clisp.org>
3401
3402         Simplify handling of strncasecmp.
3403         * lib/string_.h (strncasecmp): Remove test for GNULIB_STRCASE. Change
3404         the conditional link warning.
3405         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Initialize
3406         HAVE_STRCASECMP, not REPLACE_STRCASECMP.
3407         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Don't initialize GNULIB_STRCASE.
3408         * modules/strcase (configure.ac): Don't invoke
3409         gl_STRING_MODULE_INDICATOR.
3410         * modules/string (string.h): Don't substitute GNULIB_STRCASE.
3411
3412 2007-02-04  Bruno Haible  <bruno@clisp.org>
3413
3414         New module mbscasecmp, reduced goal of strcasecmp.
3415         * modules/mbscasecmp: New file.
3416         * lib/mbscasecmp.c: New file, copied from lib/strcasecmp.c.
3417         (mbscasecmp): Renamed from strcasecmp.
3418         * lib/strcasecmp.c: Don't include mbuiter.h.
3419         (strcasecmp): Remove support for multibyte locales.
3420         * lib/string_.h (strcasecmp): Don`t rename. Declare only if missing.
3421         Change the conditional link warning.
3422         (mbscasecmp): New declaration.
3423         * m4/mbscasecmp.m4: New file.
3424         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Enable the replacement only if
3425         the system lacks strcasecmp. Set HAVE_STRCASECMP instead of
3426         REPLACE_STRCASECMP.
3427         (gl_PREREQ_STRCASECMP): Don't require gl_FUNC_MBRTOWC.
3428         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3429         GNULIB_MBSCASECMP.
3430         * modules/string (string.h): Also substitute GNULIB_MBSCASECMP.
3431         Substitute HAVE_STRCASECMP instead of REPLACE_STRCASECMP.
3432         * modules/strcase (Files): Remove m4/mbrtowc.m4.
3433         (Depends-on): Remove mbuiter.
3434         * MODULES.html.sh (Internationalization functions): Add mbscasecmp.
3435
3436 2007-02-04  Bruno Haible  <bruno@clisp.org>
3437
3438         New module mbsstr. Remove module strstr.
3439         * modules/mbsstr: New file.
3440         * modules/strstr: Remove file.
3441         * lib/mbsstr.c: Renamed from lib/strstr.c.
3442         (mbsstr): Renamed from strstr.
3443         * lib/string_.h (strstr): Remove declaration. Change the conditional
3444         link warning.
3445         (mbsstr): New declaration.
3446         * m4/mbsstr.m4: New file.
3447         * m4/strstr.m4: Remove file.
3448         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Don't initialize
3449         REPLACE_STRSTR.
3450         (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize GNULIB_MBSSTR.
3451         Don't initialize GNULIB_STRSTR.
3452         * modules/string (string.h): Also substitute GNULIB_MBSSTR. Don't
3453         substitute GNULIB_STRSTR and REPLACE_STRSTR.
3454         * MODULES.html.sh (Internationalization functions): Add mbsstr.
3455         (Support for systems lacking ANSI C 89): Remove strstr.
3456
3457 2007-02-04  Bruno Haible  <bruno@clisp.org>
3458
3459         New module mbsrchr.
3460         * modules/mbsrchr: New file.
3461         * lib/mbsrchr.c: New file.
3462         * lib/string_.h (strrchr): Add a conditional link warning.
3463         (mbsrchr): New declaration.
3464         * m4/mbsrchr.m4: New file.
3465         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3466         GNULIB_MBSRCHR.
3467         * modules/string (string.h): Also substitute GNULIB_MBSRCHR.
3468         * MODULES.html.sh (Internationalization functions): Add mbsrchr.
3469
3470 2007-02-04  Bruno Haible  <bruno@clisp.org>
3471
3472         New module mbschr.
3473         * modules/mbschr: New file.
3474         * lib/mbschr.c: New file.
3475         * lib/string_.h (strchr): Add a conditional link warning.
3476         (mbschr): New declaration.
3477         * m4/mbschr.m4: New file.
3478         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR_DEFAULTS): Initialize
3479         GNULIB_MBSCHR.
3480         * modules/string (string.h): Also substitute GNULIB_MBSCHR.
3481         * MODULES.html.sh (Internationalization functions): Add mbschr.
3482
3483 2007-02-04  Paul Eggert  <eggert@cs.ucla.edu>
3484
3485         * lib/stdbool_.h: Mention that bool bit-fields aren't supported.
3486
3487         * modules/stdarg (configure.ac-early): Require AC_PROG_CC_STDC.
3488
3489 2007-02-04  Bruno Haible  <bruno@clisp.org>
3490
3491         New module description section 'configure.ac-early'.
3492         * gnulib-tool (sed_extract_prog): Recognize configure.ac-early.
3493         (func_get_autoconf_early_snippet): New function.
3494         (func_import, func_create_testdir): Use it. Remove special cases for
3495         modules 'extensions' and 'lock'.
3496         * modules/extensions (configure.ac-early): Require
3497         gl_USE_SYSTEM_EXTENSIONS.
3498         * modules/lock (configure.ac-early): Require gl_LOCK_EARLY.
3499
3500 2007-02-04  Bruno Haible  <bruno@clisp.org>
3501
3502         Make use of gcj-4.3's -fsource and -ftarget option.
3503         * m4/javacomp.m4 (gt_JAVACOMP): Test whether gcj is in version >= 4.3,
3504         and if so try the options -fsource and -ftarget.
3505         * lib/javacomp.c (compile_using_gcj): Add fsource_option,
3506         source_version, ftarget_option, target_version arguments.
3507         (is_envjavac_gcj43, is_envjavac_gcj43_usable): New functions.
3508         (is_envjavac_oldgcj_14_14_usable): Renamed from
3509         is_envjavac_gcj_14_14_usable.
3510         (is_envjavac_oldgcj_14_13_usable): Renamed from
3511         is_envjavac_gcj_14_13_usable.
3512         (is_gcj_present): Update.
3513         (is_gcj_43, is_gcj43_usable): New functions.
3514         (is_oldgcj_14_14_usable): Renamed from is_gcj_14_14_usable. Update.
3515         (is_oldgcj_14_13_usable): Renamed from is_gcj_14_13_usable. Update.
3516         (compile_java_class): Test whether gcj is in version >= 4.3, and if so
3517         try the options -fsource and -ftarget.
3518
3519 2007-02-03  Paul Eggert  <eggert@cs.ucla.edu>
3520
3521         * lib/xalloc.h (x2nrealloc): Fix an unlikely bug in the overflow
3522         checking code.  Set N = ceil (1.5 * N) rather than to a slightly
3523         larger value.
3524
3525 2007-02-03  Jim Meyering  <jim@meyering.net>
3526
3527         Give tools a better chance to allocate space for very large buffers.
3528         * lib/xalloc.h (x2nrealloc): Use 3/2, not 2, as buffer size factor.
3529
3530         Make pwd and readlink work also when run with an unreadable parent dir
3531         on systems with openat support.
3532         * lib/getcwd.c (__getcwd) [HAVE_PARTLY_WORKING_GETCWD]: Use the system
3533         provided getcwd function, even when we have openat support.
3534         Reported by Dmitry V. Levin in <http://bugzilla.redhat.com/227168>.
3535
3536 2007-02-02  Bruno Haible  <bruno@clisp.org>
3537
3538         * lib/string_.h (memmem, mempcpy, memrchr, stpcpy, stpncpy, strchrnul,
3539         strdup, strndup, strnlen, strpbrk, strsep, strtok_r): Provoke a link
3540         error only if GNULIB_POSIXCHECK is defined. Needed to avoid artificial
3541         portability problems if one of these functions is only used on specific
3542         platforms.
3543         Reported by Paul Eggert.
3544
3545 2007-02-02  Paul Eggert  <eggert@cs.ucla.edu>
3546
3547         Avoid mempcpy in the regex code, as the string.h mempcpy stuff
3548         is causing more trouble than it's curing.
3549         * lib/regex_internal.h (__mempcpy): Remove.
3550         * lib/regcomp.c (regerror): Rewrite to avoid the need for mempcpy
3551         (and make the code a tad smaller to boot).
3552         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for mempcpy.
3553
3554 2007-02-02  Jim Meyering  <jim@meyering.net>
3555
3556         * modules/arpa_inet: Put AC_PROG_MKDIR_P in the configure.ac:
3557         section, not in the Makefile.am: one.
3558
3559 2007-02-02  Eric Blake  <ebb9@byu.net>
3560
3561         * lib/strchrnul.c: Always include config.h first.
3562
3563         * modules/mountlist (Depends-on): Revert 2007-01-31 change,
3564         gnulib strstr is not necessary here.
3565
3566 2007-02-02  Simon Josefsson  <simon@josefsson.org>
3567
3568         * m4/socklen.m4: Fix typo.
3569
3570 2007-02-02  Eric Blake  <ebb9@byu.net>
3571
3572         * modules/arpa_inet (Makefile.am): Use MKDIR_P to avoid races.
3573         * modules/netinet_in (Makefile.am): Likewise.
3574
3575 2007-02-01  Bruno Haible  <bruno@clisp.org>
3576
3577         * lib/string_.h (GL_LINK_WARNING): New macro.
3578         (strcasecmp, strstr, strcasestr): If provided by the system,
3579         conditionally define as a macro that leads to a warning instead of to
3580         an error.
3581         (strncasecmp): Conditionally define as a macro that leads to a warning.
3582
3583 2007-02-01  Karl Berry  <karl@gnu.org>
3584
3585         * config/srclist.txt (strtok_r.c): lose sync, no more strtok_r.h.
3586
3587 2007-02-01  Bruno Haible  <bruno@clisp.org>
3588
3589         * MODULES.html.sh (Unicode string functions): Update after 2007-01-27
3590         renamings.
3591
3592 2007-02-01  Eric Blake  <ebb9@byu.net>
3593
3594         * modules/regex (Depends-on): Revert dependence on mempcpy.
3595         * lib/regex_internal.h [! _LIBC && !__mempcpy]: Undo string
3596         module's definition of mempcpy.
3597         Reported by Paul Eggert.
3598
3599 2007-02-01  Paul Eggert  <eggert@cs.ucla.edu>
3600
3601         * lib/string_.h: If the gnulib module XYZ is not present, undefine
3602         the symbol XYZ before redefining it.  This fixes a problem with
3603         programs that don't use XYZ, when compiled on systems that define
3604         XYZ to something else.
3605
3606 2007-01-31  Paul Eggert  <eggert@cs.ucla.edu>
3607
3608         * lib/mkdir-p.c (make_dir_parents): Close a race condition that
3609         occurs when "mkdir -m foo" creates a setgid directory that is (1)
3610         writeable to group or other and (2) is intended to have a special
3611         mode bit that is set or cleared.  In such a case, the directory
3612         should be neither group- nor other-writeable until the special
3613         mode bits are right.
3614
3615 2007-01-31  Eric Blake  <ebb9@byu.net>
3616
3617         * modules/mountlist (Depends-on): Add strstr.
3618
3619         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): Correct m4 usage
3620         bug.
3621         * modules/string (Makefile.am): Remove redundant replacement.
3622         * modules/regex (Depends-on): Add mempcpy.
3623
3624 2007-01-31  Bruno Haible  <bruno@clisp.org>
3625
3626         New module description field 'Link'.
3627         * gnulib-tool (func_usage): Document --extract-link-directive.
3628         (sed_extract_prog): Recognize 'Link' directive.
3629         (func_get_link_directive): New function.
3630         (func_import): Show summary of link directives.
3631         Handle --extract-link-directive option.
3632         * modules/acl (Link): New section.
3633         * modules/clock-time (Link): New section.
3634         * modules/euidaccess (Link): New section.
3635         * modules/gettext (Link): New section.
3636         * modules/iconv (Link): New section.
3637         * modules/lock (Link): New section.
3638         * modules/nanosleep (Link): New section.
3639         * modules/readline (Link): New section.
3640
3641 2007-01-27  Bruno Haible  <bruno@clisp.org>
3642
3643         Enforce the use of gnulib modules for unportable <string.h> functions.
3644         * m4/string_h.m4 (gl_STRING_MODULE_INDICATOR): New macro.
3645         (gl_STRING_MODULE_INDICATOR_DEFAULTS): New macro.
3646         (gl_HEADER_STRING_H_BODY): Require it.
3647         * lib/string_.h: If the gnulib module XYZ is not present, redefine
3648         the symbol XYZ to one that gives a link error.
3649         * modules/string (Makefile.am): Also substitute the GNULIB_* variables.
3650         * modules/memmem (configure.ac): Invoke gl_STRING_MODULE_INDICATOR.
3651         * modules/mempcpy (configure.ac): Likewise.
3652         * modules/memrchr (configure.ac): Likewise.
3653         * modules/stpcpy (configure.ac): Likewise.
3654         * modules/stpncpy (configure.ac): Likewise.
3655         * modules/strcase (configure.ac): Likewise.
3656         * modules/strcasestr (configure.ac): Likewise.
3657         * modules/strchrnul (configure.ac): Likewise.
3658         * modules/strdup (configure.ac): Likewise.
3659         * modules/strndup (configure.ac): Likewise.
3660         * modules/strnlen (configure.ac): Likewise.
3661         * modules/strpbrk (configure.ac): Likewise.
3662         * modules/strsep (configure.ac): Likewise.
3663         * modules/strstr (configure.ac): Likewise.
3664         * modules/strtok_r (configure.ac): Likewise.
3665
3666 2007-01-31  Jean-Louis Martineau  <martineau@zmanda.com>  (tiny change)
3667
3668         * lib/gai_strerror.c (values): Add EAI_OVERFLOW.
3669
3670 2007-01-30  Jim Meyering  <jim@meyering.net>
3671
3672         * lib/mpsort.c (mpsort): Remove spurious "return" in void function.
3673
3674 2007-01-29  Bruno Haible  <bruno@clisp.org>
3675
3676         * lib/allocsa.h: Use '#if HAVE_*' instead of '#ifdef HAVE_*'.
3677         * lib/execute.c: Likewise.
3678         * lib/pipe.c: Likewise.
3679         * lib/printf-args.h: Likewise.
3680         * lib/printf-args.c: Likewise.
3681         * lib/printf-parse.c: Likewise.
3682         * lib/vasnprintf.c: Likewise.
3683
3684 2007-01-29  Eric Blake  <ebb9@byu.net>
3685
3686         * lib/memrchr.c: Assume <string.h> unconditionally, to pull in
3687         declaration.
3688
3689 2007-01-29  Paul Eggert  <eggert@cs.ucla.edu>
3690
3691         * lib/strptime.h (strptime): Use 'restrict' for args where
3692         POSIX requires this.
3693         * lib/strptime.c (strptime): Likewise.
3694         Change license notice from LGPL to GPL, since gnulib-tool will
3695         change this as needed.
3696         Include <config.h> if _LIBC is not defined, not if HAVE_CONFIG_H is
3697         defined.
3698         Include "strptime.h" first, to check interface.
3699         Do not #undef _LIBC and _NL_CURRENT.
3700         Do not include <stdlib.h>; no longer needed.
3701         Include "time_r.h" and declare ptime_locale_status
3702         only if _LIBC is not defined.
3703         (__P): Remove unused macro.
3704         (match_string): Bring back glibc version, but use it only if _LIBC
3705         is defined.
3706         (__strptime_internal): Compile tm_gmtoff code if _LIBC is defined, too.
3707         Remove unnecessary assertion and abort() call.
3708         Use #ifdef _NL_CURRENT rather than #if 0, for benefit of glibc.
3709         * m4/strptime.m4: Fix serial number comment.
3710         (gl_FUNC_STRPTIME): Require AC_C_RESTRICT, gl_TM_GMTOFF.
3711         * modules/strptime (Files): Add m4/tm_gmtoff.m4.
3712         (Depends-on): Add time_r.
3713
3714 2007-01-29  Bruno Haible  <bruno@clisp.org>
3715
3716         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
3717         strptime.
3718         * modules/strptime (Depends-on): Add stdbool.
3719         * lib/strptime.h: Include <time.h> always. Add comments.
3720
3721 2007-01-29  Yoann Vandoorselaere  <yoann@prelude-ids.org>
3722
3723         * modules/strptime: New file.
3724         * lib/strptime.h: New file.
3725         * lib/strptime.c: New file.
3726         * m4/strptime.m4: New file.
3727
3728 2007-01-28  Paul Eggert  <eggert@cs.ucla.edu>
3729
3730         * MODULES.html.sh: New module mpsort.
3731         * lib/mpsort.c, lib/mpsort.h, m4/mpsort.m4, modules/mpsort: New files.
3732
3733         * lib/regex.h (_Restrict_): Renamed from __restrict, to avoid
3734         a circularity problem with HP-UX ia64 reported by Bob Proulx in
3735         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00394.html>.
3736         All uses changed.
3737         (_Restrict_arr_): Renamed from __restrict_arr, for similar reasons.
3738         All uses changed.
3739         * lib/regcomp.c, lib/regexec.c: Change all uses from __restrict
3740         to _Restrict_.
3741         * lib/regexec.c (regexec): Declare pmatch with _Restrict_arr_, so that
3742         the parameter matches the prototype.
3743
3744 2007-01-28  Jim Meyering  <jim@meyering.net>
3745
3746         * modules/sys_time (Makefile.am) [MOSTLYCLEANFILES]: Do use
3747         sys/time.h here, reverting that part of the previous patch:
3748         <http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/8959>.
3749
3750 2007-01-28  Bruno Haible  <bruno@clisp.org>
3751
3752         * modules/sys_time (Makefile.am): Build sys/time.h only when it's the
3753         value of $(SYS_TIME_H).
3754         [MOSTLYCLEANFILES]: Now that sys/time.h is created only when needed,
3755         remove it conditionally, too. [added by Jim Meyering]
3756         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Set SYS_TIME_H.
3757         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
3758         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Set SYS_TIME_H when setting
3759         GETTIMEOFDAY_REPLACEMENT to 1.
3760
3761 2007-01-28  Bruno Haible  <bruno@clisp.org>
3762
3763         * m4/unistd_h.m4 (gl_HEADER_UNISTD_DEFAULTS): New macro.
3764         (gl_HEADER_UNISTD): Require it. Don't set UNISTD_H to empty here.
3765         * m4/fchdir.m4 (gl_FUNC_FCHDIR): Require gl_HEADER_UNISTD_DEFAULTS.
3766         Set UNISTD_H instead of UNISTD_H2.
3767         * modules/fchdir (BUILT_SOURCES): Drop $(UNISTD_H2).
3768
3769 2007-01-28  Bruno Haible  <bruno@clisp.org>
3770
3771         * modules/mbchar (Makefile.am): Add mbchar.c to lib_SOURCES.
3772         * m4/mbchar.m4 (gl_MBCHAR): Remove AC_LIBOBJ invocation.
3773
3774 2007-01-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3775
3776         * gnulib-tool (func_emit_lib_Makefile_am, func_add_or_update)
3777         (func_create_testdir): Ensure C locale for `grep' and `tr'
3778         character ranges.
3779         (func_create_megatestdir): Avoid one `grep'.  Fix bug in
3780         ACLOCAL_AMFLAGS parsing state machine.
3781
3782 2007-01-27  Bruno Haible  <bruno@clisp.org>
3783
3784         * modules/unistr/base: Update.
3785
3786 2007-01-27  Bruno Haible  <bruno@clisp.org>
3787
3788         Rename u32-mbtouc -> u32-mbtouc-unsafe, u32-mbtouc-safe -> u32-mbtouc,
3789         u32_mbtouc -> u32_mbtouc_unsafe, u32_mbtouc_safe -> u32_mbtouc.
3790         * modules/unistr/u32-mbtouc-unsafe: Renamed from
3791         modules/unistr/u32-mbtouc.
3792         * lib/unistr/u32-mbtouc-unsafe.c: Renamed from lib/unistr/u32-mbtouc.c.
3793         * lib/unistr.h: Update.
3794         * lib/linebreak.c: Update.
3795         * modules/unistr/u32-mbtouc: Renamed from
3796         modules/unistr/u32-mbtouc-safe.
3797         * lib/unistr/u32-mbtouc.c: Renamed from lib/unistr/u32-mbtouc-safe.c.
3798         * lib/unistr.h: Update.
3799         * lib/unistr/u32-to-u8.c: Update.
3800         * lib/unistr/u32-to-u16.c: Update.
3801
3802 2007-01-27  Bruno Haible  <bruno@clisp.org>
3803
3804         Rename utf16-ucs4 -> utf16-ucs4-unsafe, utf16-ucs4-safe -> utf16-ucs4,
3805         u16_mbtouc -> u16_mbtouc_unsafe, u16_mbtouc_safe -> u16_mbtouc.
3806         * modules/utf16-ucs4-unsafe: Renamed from modules/utf16-ucs4.
3807         * lib/utf16-ucs4-unsafe.h: Renamed from lib/utf16-ucs4.h.
3808         * lib/unistr/utf16-ucs4-unsafe.c: Renamed from lib/unistr/utf16-ucs4.c.
3809         * modules/unistr/u16-mbtouc-unsafe: Renamed from
3810         modules/unistr/u16-mbtouc.
3811         * lib/unistr/u16-mbtouc-unsafe.c: Renamed from lib/unistr/u16-mbtouc.c.
3812         * lib/unistr.h: Update.
3813         * lib/linebreak.c: Update.
3814         * modules/linebreak: Update.
3815         * modules/utf16-ucs4: Renamed from modules/utf16-ucs4-safe.
3816         * lib/utf16-ucs4.h: Renamed from lib/utf16-ucs4-safe.h.
3817         * lib/unistr/utf16-ucs4.c: Renamed from lib/unistr/utf16-ucs4-safe.c.
3818         * modules/unistr/u16-mbtouc: Renamed from
3819         modules/unistr/u16-mbtouc-safe.
3820         * lib/unistr/u16-mbtouc.c: Renamed from lib/unistr/u16-mbtouc-safe.c.
3821         * lib/unistr.h: Update.
3822         * lib/unistr/u16-to-u8.c: Update.
3823         * modules/unistr/u16-to-u8: Update.
3824         * lib/unistr/u16-to-u32.c: Update.
3825         * modules/unistr/u16-to-u32: Update.
3826
3827 2007-01-27  Bruno Haible  <bruno@clisp.org>
3828
3829         Rename utf8-ucs4 -> utf8-ucs4-unsafe, utf8-ucs4-safe -> utf8-ucs4,
3830         u8_mbtouc -> u8_mbtouc_unsafe, u8_mbtouc_safe -> u8_mbtouc.
3831         * modules/utf8-ucs4-unsafe: Renamed from modules/utf8-ucs4.
3832         * lib/utf8-ucs4-unsafe.h: Renamed from lib/utf8-ucs4.h.
3833         * lib/unistr/utf8-ucs4-unsafe.c: Renamed from lib/unistr/utf8-ucs4.c.
3834         * modules/unistr/u8-mbtouc-unsafe: Renamed from
3835         modules/unistr/u8-mbtouc.
3836         * lib/unistr/u8-mbtouc-unsafe.c: Renamed from lib/unistr/u8-mbtouc.c.
3837         * lib/unistr.h: Update.
3838         * lib/striconveh.c: Update.
3839         * modules/striconveh: Update.
3840         * lib/linebreak.c: Update.
3841         * modules/linebreak: Update.
3842         * modules/utf8-ucs4: Renamed from modules/utf8-ucs4-safe.
3843         * lib/utf8-ucs4.h: Renamed from lib/utf8-ucs4-safe.h.
3844         * lib/unistr/utf8-ucs4.c: Renamed from lib/unistr/utf8-ucs4-safe.c.
3845         * modules/unistr/u8-mbtouc: Renamed from modules/unistr/u8-mbtouc-safe.
3846         * lib/unistr/u8-mbtouc.c: Renamed from lib/unistr/u8-mbtouc-safe.c.
3847         * lib/unistr.h: Update.
3848         * lib/striconveh.c: Update.
3849         * modules/striconveh: Update.
3850         * lib/unistr/u8-to-u16.c: Update.
3851         * modules/unistr/u8-to-u16: Update.
3852         * lib/unistr/u8-to-u32.c: Update.
3853         * modules/unistr/u8-to-u32: Update.
3854
3855 2007-01-27  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3856
3857         Sync from Libtool.
3858         * lib/argz.c: Do not include strings.h nor memory.h, include
3859         string.h unconditionally.  Patch by Simon Josefsson.
3860
3861 2007-01-27  Bruno Haible  <bruno@clisp.org>
3862
3863         * m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): New macro, extracted
3864         from gl_HEADER_STRING_H_BODY.
3865         (gl_HEADER_STRING_H_BODY): Require it.
3866         * m4/memmem.m4 (gl_FUNC_MEMMEM): Require gl_HEADER_STRING_H_DEFAULTS.
3867         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Likewise.
3868         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Likewise.
3869         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Likewise.
3870         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Likewise.
3871         * m4/strcase.m4 (gl_FUNC_STRCASECMP, gl_FUNC_STRNCASECMP): Likewise.
3872         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
3873         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Likewise.
3874         * m4/strdup.m4 (gl_FUNC_STRDUP): Likewise.
3875         * m4/strndup.m4 (gl_FUNC_STRNDUP): Likewise.
3876         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Likewise.
3877         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Likewise.
3878         * m4/strsep.m4 (gl_FUNC_STRSEP): Likewise.
3879         * m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
3880         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
3881
3882 2007-01-27  Bruno Haible  <bruno@clisp.org>
3883
3884         * gnulib-tool (func_emit_lib_Makefile_am): If $for_test is true, turn
3885         check_PROGRAMS into noinst_PROGRAMS.
3886         (func_emit_tests_Makefile_am): Likewise. Also don't initialize
3887         check_PROGRAMS in this case.
3888         (func_import): Set for_test to false.
3889         (func_create_testdir): Set for_test to true.
3890
3891 2007-01-27  Yoann Vandoorselaere <yoann.v@prelude-ids.com>
3892             Bruno Haible  <bruno@clisp.org>
3893
3894         * modules/strcasestr (Files): Remove lib/strcasestr.h.
3895         (Depends-on): Add string.
3896         (Includes): Use <string.h> instead of strcasestr.h.
3897         * modules/string (Makefile.am): Also substitute the value of
3898         REPLACE_STRCASESTR.
3899         * m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Don't define strcasestr here;
3900         assume strcasestr is declared in <string.h> not <strings.h>. Also
3901         set REPLACE_STRCASESTR.
3902         * m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Provide a default value for
3903         REPLACE_STRCASESTR.
3904         * lib/strcasestr.h: Remove file.
3905         * lib/strcasestr.c: Include <string.h> instead of strcasestr.h.
3906         * lib/string_.h (strcasestr): New declaration.
3907
3908 2007-01-27  Bruno Haible  <bruno@clisp.org>
3909
3910         * lib/string_.h: Use 'extern'.
3911
3912 2007-01-27  Jim Meyering  <jim@meyering.net>
3913
3914         * lib/regex_internal.c (re_string_reconstruct): Remove declaration
3915         of set-but-not-used local, "q".
3916
3917         * lib/mempcpy.c: Include <config.h> before <string.h>.
3918         This fixes a compilation error on HP-UX, due to the system's
3919         "restrict"-using mempcpy prototype.
3920
3921 2007-01-26  Bruno Haible  <bruno@clisp.org>
3922
3923         Small optimization.
3924         * lib/javacomp.c: Include c-strstr.h.
3925          (is_envjavac_gcj): Use c_strstr instead of strstr.
3926         * modules/javacomp (Depends-on): Add c-strstr, remove strstr.
3927
3928 2007-01-26  Bruno Haible  <bruno@clisp.org>
3929
3930         * MODULES.html.sh (Unicode string functions): Add the new modules.
3931
3932         * modules/uniconv/u32-strconv-to-locale: New file.
3933         * lib/uniconv/u32-strconv-to-locale.c: New file.
3934
3935         * modules/uniconv/u16-strconv-to-locale: New file.
3936         * lib/uniconv/u16-strconv-to-locale.c: New file.
3937
3938         * modules/uniconv/u8-strconv-to-locale: New file.
3939         * lib/uniconv/u8-strconv-to-locale.c: New file.
3940
3941         * modules/uniconv/u32-strconv-from-locale: New file.
3942         * lib/uniconv/u32-strconv-from-locale.c: New file.
3943
3944         * modules/uniconv/u16-strconv-from-locale: New file.
3945         * lib/uniconv/u16-strconv-from-locale.c: New file.
3946
3947         * modules/uniconv/u8-strconv-from-locale: New file.
3948         * lib/uniconv/u8-strconv-from-locale.c: New file.
3949
3950         * modules/uniconv/u32-strconv-to-enc: New file.
3951         * lib/uniconv/u32-strconv-to-enc.c: New file.
3952         * modules/uniconv/u32-strconv-to-enc-tests: New file.
3953         * tests/uniconv/test-u32-strconv-to-enc.c: New file.
3954
3955         * modules/uniconv/u16-strconv-to-enc: New file.
3956         * lib/uniconv/u16-strconv-to-enc.c: New file.
3957         * lib/uniconv/u-strconv-to-enc.h: New file.
3958         * modules/uniconv/u16-strconv-to-enc-tests: New file.
3959         * tests/uniconv/test-u16-strconv-to-enc.c: New file.
3960
3961         * modules/uniconv/u8-strconv-to-enc: New file.
3962         * lib/uniconv/u8-strconv-to-enc.c: New file.
3963         * modules/uniconv/u8-strconv-to-enc-tests: New file.
3964         * tests/uniconv/test-u8-strconv-to-enc.c: New file.
3965
3966         * modules/uniconv/u32-strconv-from-enc: New file.
3967         * lib/uniconv/u32-strconv-from-enc.c: New file.
3968         * modules/uniconv/u32-strconv-from-enc-tests: New file.
3969         * tests/uniconv/test-u32-strconv-from-enc.c: New file.
3970
3971         * modules/uniconv/u16-strconv-from-enc: New file.
3972         * lib/uniconv/u16-strconv-from-enc.c: New file.
3973         * modules/uniconv/u16-strconv-from-enc-tests: New file.
3974         * tests/uniconv/test-u16-strconv-from-enc.c: New file.
3975
3976         * modules/uniconv/u8-strconv-from-enc: New file.
3977         * lib/uniconv/u8-strconv-from-enc.c: New file.
3978         * lib/uniconv/u-strconv-from-enc.h: New file.
3979         * modules/uniconv/u8-strconv-from-enc-tests: New file.
3980         * tests/uniconv/test-u8-strconv-from-enc.c: New file.
3981
3982         * modules/uniconv/u32-conv-from-enc: New file.
3983         * lib/uniconv/u32-conv-from-enc.c: New file.
3984         * modules/uniconv/u32-conv-from-enc-tests: New file.
3985         * tests/uniconv/test-u32-conv-from-enc.c: New file.
3986
3987         * modules/uniconv/u16-conv-from-enc: New file.
3988         * lib/uniconv/u16-conv-from-enc.c: New file.
3989         * lib/uniconv/u-conv-from-enc.h: New file.
3990         * modules/uniconv/u16-conv-from-enc-tests: New file.
3991         * tests/uniconv/test-u16-conv-from-enc.c: New file.
3992
3993         * modules/uniconv/u8-conv-from-enc: New file.
3994         * lib/uniconv/u8-conv-from-enc.c: New file.
3995         * modules/uniconv/u8-conv-from-enc-tests: New file.
3996         * tests/uniconv/test-u8-conv-from-enc.c: New file.
3997
3998         * modules/uniconv/base: New file.
3999         * lib/uniconv.h: New file.
4000
4001 2007-01-26  Paul Eggert  <eggert@cs.ucla.edu>
4002
4003         * doc/gnulib-tool.texi (Initial import): Update to match current
4004         behavior with strdup module.
4005         * lib/.cppi-disable: Remove strcase.h, strdup.h, strndup.h, strnlen.h.
4006         * lib/memmem.h: Remove; all uses removed.  This is now done
4007         by <string.h>.
4008         * lib/mempcpy.h: Likewise.
4009         * lib/memrchr.h: Likewise.
4010         * lib/stpcpy.h: Likewise.
4011         * lib/stpncpy.h: Likewise.
4012         * lib/strcase.h: Likewise.
4013         * lib/strchrnul.h: Likewise.
4014         * lib/strdup.h: Likewise.
4015         * lib/strndup.h: Likewise.
4016         * lib/strnlen.h: Likewise.
4017         * lib/strpbrk.h: Likewise.
4018         * lib/strsep.h: Likewise.
4019         * lib/strstr.h: Likewise.
4020         * lib/strtok_r.h: Likewise.
4021         * lib/string_.h: New file.
4022         * lib/argp-namefrob.h: Don't include no-longer-existent include files.
4023         Rely on <string.h> instead.
4024         * lib/canon-host.c: Likewise.
4025         * lib/chdir-long.c: Likewise.
4026         * lib/concatpath.c: Likewise.
4027         * lib/exclude.c: Likewise.
4028         * lib/fchdir.c: Likewise.
4029         * lib/getaddrinfo.c: Likewise.
4030         * lib/getcwd.c: Likewise.
4031         * lib/getsubopt.c: Likewise.
4032         * lib/glob.c: Likewise.
4033         * lib/hard-locale.c: Likewise.
4034         * lib/iconvme.c: Likewise.
4035         * lib/javacomp.c: Likewise.
4036         * lib/mempcpy.c: Likewise.
4037         * lib/memrchr.c: Likewise.
4038         * lib/regex_internal.h: Likewise.
4039         * lib/stpncpy.c: Likewise.
4040         * lib/strcasecmp.c: Likewise.
4041         * lib/strchrnul.c: Likewise.
4042         * lib/strdup.c: Likewise.
4043         * lib/striconv.c: Likewise.
4044         * lib/striconveh.c: Likewise.
4045         * lib/striconveha.c: Likewise.
4046         * lib/strncasecmp.c: Likewise.
4047         * lib/strndup.c: Likewise.
4048         * lib/strnlen.c: Likewise.
4049         * lib/strsep.c: Likewise.
4050         * lib/strstr.c: Likewise.
4051         * lib/strtok_r.c: Likewise.
4052         * lib/userspec.c: Likewise.
4053         * lib/w32spawn.h: Likewise.
4054         * lib/xstrndup.c: Likewise.
4055         * lib/mountlist.c (strstr): Remove decl.
4056         * m4/string_h.m4: New file.
4057         * m4/memmem.m4 (gl_FUNC_MEMMEM): Set HAVE_DECL_MEMMEM if necessary.
4058         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY): Set HAVE_MEMPCPY if necessary.
4059         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Set HAVE_MEMRCHR
4060         * m4/stpcpy.m4 (gl_FUNC_STPCPY): Set HAVE_STPCPY if necessary.
4061         * m4/stpncpy.m4 (gl_PREREQ_STPNCPY): Set HAVE_STPNCPY if necessary.
4062         * m4/strcase.m4 (gl_FUNC_STRCASECMP):
4063         Set REPLACE_STRCASECMP if necessary.
4064         (gl_FUNC_STRNCASECMP): Set HAVE_DECL_STRNCASECMP if necessary.
4065         * m4/strchrnul.m4 (gl_FUNC_STRCHRNUL): Set HAVE_STRCHRNUL if necessary.
4066         * m4/strdup.m4 (gl_FUNC_STRDUP): Set HAVE_DECL_STRDUP if necessary.
4067         * m4/strndup.m4 (gl_FUNC_STRNDUP): Set HAVE_DECL_STRNLEN and
4068         HAVE_DECL_STRDUP if necessary.
4069         (gl_PREREQ_STRNLEN): Don't bother to check for strnlen decl,
4070         since gl_FUNC_STRNDUP does that now.
4071         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Set HAVE_DECL_STRNLEN if necessary.
4072         Check for decl here...
4073         (gl_PREREQ_STRNLEN): ... not here.
4074         * m4/strpbrk.m4 (gl_FUNC_STRPBRK): Set HAVE_STRPBRK if necessary.
4075         * m4/strsep.m4 (gl_FUNC_STRSEP): Set HAVE_STRSEP if necessary.
4076         * m4/strstr.m4 (gl_FUNC_STRSTR): Set REPLACE_STRSTR if necessary.
4077         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Set HAVE_DECL_STRTOK_R if
4078         necessary.
4079         * modules/string: New file.
4080         * modules/memmem (Files): Remove special-purpose include file.
4081         (Depends-on): Add string.
4082         (Include): Include <string.h>, not the removed file.
4083         * modules/mempcpy: Likewise.
4084         * modules/memrchr: Likewise.
4085         * modules/stpcpy: Likewise.
4086         * modules/stpncpy: Likewise.
4087         * modules/strcase: Likewise.
4088         * modules/strchrnul: Likewise.
4089         * modules/strdup: Likewise.
4090         * modules/strndup: Likewise.
4091         * modules/strnlen: Likewise.
4092         * modules/strpbrk: Likewise.
4093         * modules/strsep: Likewise.
4094         * modules/strstr: Likewise.
4095         * modules/strtok_r: Likewise.
4096         * tests/test-dirname.c: Don't include "strdup.h", since
4097         <string.h> now suffices.
4098         * tests/test-memmem.c: Don't include "memmem.h", since
4099         <string.h> now suffices.
4100
4101 2007-01-25  Bruno Haible  <bruno@clisp.org>
4102
4103         * lib/striconveh.c (mem_cd_iconveh_internal): Ignore *lengthp if
4104         *resultp is 0.
4105
4106         * lib/unistr/u16-to-u8.c (u16_to_u8): Fix u8_uctomb invocation.
4107         * lib/unistr/u32-to-u8.c (u32_to_u8): Likewise.
4108         * lib/unistr/u8-to-u16.c (u8_to_u16): Fix u16_uctomb invocation.
4109         * lib/unistr/u32-to-u16.c (u32_to_u16): Likewise.
4110
4111         * modules/unistr/u8-to-u16 (Depends-on): Add missing modules.
4112         * modules/unistr/u8-to-u32 (Depends-on): Add missing modules.
4113         * modules/unistr/u16-to-u8 (Depends-on): Add missing modules.
4114         * modules/unistr/u16-to-u32 (Depends-on): Add missing modules.
4115         * modules/unistr/u32-to-u8 (Depends-on): Add missing modules.
4116         * modules/unistr/u32-to-u16 (Depends-on): Add missing modules.
4117
4118 2007-01-24  Bruno Haible  <bruno@clisp.org>
4119
4120         Don't AC_REQUIRE autoconf macros that invoke AC_LIBOBJ. See
4121         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00279.html>.
4122         * m4/argp.m4 (gl_ARGP): Invoke, don't require, gl_GETOPT_SUBSTITUTE.
4123         * m4/fts.m4 (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): Invoke, don't require,
4124         gl_FUNC_FTS_CORE.
4125         (gl_FUNC_FTS_CORE): Invoke, don't require, gl_FUNC_OPENAT.
4126         * m4/lstat.m4 (gl_FUNC_LSTAT): Invoke, don't require,
4127         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
4128         * m4/memcmp.m4 (gl_FUNC_MEMCMP): Invoke, don't require, AC_FUNC_MEMCMP.
4129         * m4/mktime.m4 (gl_FUNC_MKTIME): Invoke, don't require, AC_FUNC_MKTIME.
4130         * m4/openat.m4 (gl_FUNC_OPENAT): Invoke, don't require,
4131         gl_FUNC_FCHOWNAT.
4132         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Invoke, don't require,
4133         gl_FUNC_STRFTIME.
4134         * m4/strtod.m4 (gl_FUNC_STRTOD): Invoke, don't require, AC_FUNC_STRTOD.
4135         Reported by Ralf Wildenhues.
4136
4137 2007-01-24  Bruno Haible  <bruno@clisp.org>
4138
4139         Drop AC_REQUIRE calls that are redundant with the module dependencies.
4140         * m4/canon-host.m4 (gl_PREREQ_CANON_HOST): Don't require
4141         gl_GETADDRINFO.
4142         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Don't require AM_STDBOOL_H,
4143         gl_FUNC_MEMPCPY, gl_FUNC_OPENAT, gl_FUNC_MEMRCHR.
4144         * m4/openat.m4 (gl_PREREQ_OPENAT): Don't require gl_SAVE_CWD.
4145
4146 2007-01-24  Paul Eggert  <eggert@cs.ucla.edu>
4147
4148         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Add test for glibc bug 361.
4149         Don't use 'exit'; just return from 'main'.
4150         (_AC_LIBOBJ_FNMATCH): Check for headers and functions just once.
4151
4152         * lib/fnmatch_.h: Readjust white space and comments to match
4153         glibc, to avoid spurious diffs.
4154
4155 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
4156
4157         * lib/fnmatch_loop.c (internal_fnmatch) [!_LIBC]: #if-out the
4158         2004-12-01 change by Jakub Jelinek, since this code won't compile
4159         if !LIBC.  Problem reported by Bob Proulx.
4160
4161 2007-01-23  Bruno Haible  <bruno@clisp.org>
4162
4163         * lib/striconveh.c: Include c-strcaseeq.h.
4164         (mem_iconveh, str_iconveh): Use STRCASEEQ instead of c_strcasecmp.
4165         * modules/striconveh (Depends-on): Add c-strcaseeq.
4166
4167 2007-01-23  Bruno Haible  <bruno@clisp.org>
4168
4169         * MODULES.html.sh (String handling): Add streq, c-strcaseeq.
4170
4171         * modules/c-strcaseeq: New file.
4172         * lib/c-strcaseeq.h: New file.
4173
4174         * modules/streq: New file.
4175         * lib/streq.h: New file.
4176
4177 2007-01-23  Bruno Haible  <bruno@clisp.org>
4178
4179         * modules/striconveha-tests: New file.
4180         * tests/test-striconveha.c: New file.
4181
4182         * lib/striconveha.h: Include <stdbool.h>.
4183         (mem_iconveha, str_iconveha): Add 'transliterate' argument.
4184         * lib/striconveha.c: Include allocsa.h, strdup.h, c-strcase.h.
4185         (mem_iconveha_notranslit): Renamed from mem_iconveha.
4186         (mem_iconveha): New function.
4187         (str_iconveha_notranslit): Renamed from str_iconveha.
4188         (str_iconveha): New function.
4189         * modules/striconveha (Depends-on): Add stdbool, allocsa, strdup,
4190         c-strcase.
4191
4192 2007-01-23  Bruno Haible  <bruno@clisp.org>
4193
4194         * lib/striconveha.c (mem_iconveha): Fix endless recursion. Try all
4195         encodings without forgiving before trying any encoding with handler.
4196         (str_iconveha): Try all encodings without forgiving before trying any
4197         encoding with handler.
4198
4199 2007-01-23  Paul Eggert  <eggert@cs.ucla.edu>
4200
4201         Import the following changes from libc.
4202
4203         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
4204
4205         * lib/fnmatch_loop.c: Adjust for changed secondary hash function.
4206
4207         2004-12-01  Jakub Jelinek  <jakub@redhat.com>
4208
4209         * lib/fnmatch_loop.c (internal_fnmatch): Clear is_seqval after
4210         normal_bracket label.
4211
4212         2004-09-01  Jakub Jelinek  <jakub@redhat.com>
4213
4214         [BZ #361]
4215         * lib/fnmatch_loop.c (FCT): For backslash between brackets, branch
4216         to normal_bracket after fetching the next character.
4217
4218 2007-01-22  Bruno Haible  <bruno@clisp.org>
4219
4220         * lib/striconveh.h (mem_cd_iconveh, mem_iconveh): Add 'offsets'
4221         argument.
4222         * lib/striconveh.c (iconv_carefully_1): New function.
4223         (mem_cd_iconveh_internal, mem_cd_iconveh, mem_iconveh): Add 'offsets'
4224         argument.
4225         (str_cd_iconveh): Update.
4226         * lib/striconveha.h (mem_iconveha): Add 'offsets' argument.
4227         * lib/striconveha.c (mem_iconveha): Add 'offsets' argument.
4228         * tests/test-striconveh.c (MAGIC): New macro.
4229         (new_offsets): New function.
4230         (main): Test call with and without offsets.
4231
4232 2007-01-22  Bruno Haible  <bruno@clisp.org>
4233
4234         * modules/sys_stat (Makefile.am): Use @MKDIR_P@ instead of $(MKDIR_P).
4235         * modules/sys_select (Makefile.am): Likewise.
4236         * modules/sys_socket (Makefile.am): Likewise.
4237         * modules/sys_time (Makefile.am): Likewise.
4238
4239 2007-01-22  Paul Eggert  <eggert@cs.ucla.edu>
4240
4241         * modules/gettimeofday (License): Change from GPL to LGPL, since
4242         gettimeofday is a library function.
4243
4244 2007-01-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4245
4246         * lib/poll.c (rpl_poll): Don't check against FD_SETSIZE under Win32.
4247
4248 2007-01-21  Bruno Haible  <bruno@clisp.org>
4249
4250         * m4/gnulib-common.m4 (AC_PROG_MKDIR_P): New macro.
4251
4252 2007-01-21  Bruno Haible  <bruno@clisp.org>
4253
4254         * modules/striconveha: New file.
4255         * lib/striconveha.h: New file.
4256         * lib/striconveha.c: New file.
4257         * MODULES.html.sh (Internationalization functions): Add striconveha.
4258         * lib/striconv.c (str_iconv): Optimize the case of an empty input
4259         string.
4260         * lib/striconveh.c (mem_iconveh, str_iconveh): Likewise.
4261
4262 2007-01-21  Bruno Haible  <bruno@clisp.org>
4263
4264         * lib/striconv.c (str_iconv): Guarantee errno is set when strdup fails.
4265         * lib/striconveh.c (str_iconveh): Likewise.
4266
4267 2007-01-21  Bruno Haible  <bruno@clisp.org>
4268
4269         * lib/striconveh.h (mem_iconveh): New declaration.
4270         * lib/striconveh.c (mem_iconveh): New function.
4271         * tests/test-striconveh.c (main): Add tests for mem_iconveh.
4272
4273 2007-01-21  Bruno Haible  <bruno@clisp.org>
4274
4275         * lib/xstriconv.h (xmem_cd_iconv): Change specification.
4276
4277         * lib/striconveh.h (mem_cd_iconveh): Change specification.
4278         * lib/striconveh.c (mem_cd_iconveh): Don't free the user-supplied
4279         original result buffer.
4280         (str_cd_iconveh): Update.
4281         * tests/test-striconveh.c (main): Update.
4282
4283         * lib/striconv.h (mem_cd_iconv): Change specification.
4284         * lib/striconv.c (mem_cd_iconv): Don't free the user-supplied original
4285         result buffer.
4286         (str_cd_iconv): Update.
4287         * tests/test-striconv.c (main): Update.
4288
4289 2007-01-21  Bruno Haible  <bruno@clisp.org>
4290
4291         * gnulib-tool: Fix test whether sed is GNU sed supporting --posix.
4292
4293 2007-01-20  Jim Meyering  <jim@meyering.net>
4294
4295         * lib/userspec.c (parse_with_separator): If a user or group string
4296         starts with "+", skip the corresponding name-to-ID look-up, since
4297         such a look-up must fail: user and group names may not include "+".
4298
4299 2007-01-19  Paul Eggert  <eggert@cs.ucla.edu>
4300
4301         * lib/poll.c: Include sys/time.h and time.h unconditionally,
4302         since we now assume the sys_time module.
4303         * m4/poll.m4 (gl_PREREQ_POLL): Don't require AC_HEADER_TIME or
4304         check for sys/time.h; no longer needed.
4305         * modules/poll (Depends-on): Depend on sys_time.
4306
4307 2007-01-18  Bruno Haible  <bruno@clisp.org>
4308
4309         * m4/mktime.m4 (AC_FUNC_MKTIME): Remove test for <sys/time.h>.
4310         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4311
4312         * m4/tempname.m4 (gl_PREREQ_TEMPNAME): Remove tests for sys/time.h and
4313         gettimeofday.
4314
4315         * tests/test-gettimeofday.c: Include <time.h>.
4316         (dummy): Remove variable.
4317
4318         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_BODY): Renamed from
4319         gl_HEADER_SYS_TIME_H.
4320         (gl_HEADER_SYS_TIME_H): New macro.
4321
4322         * lib/sys_time_.h: Test GETTIMEOFDAY_REPLACEMENT instead of
4323         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4324         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY,
4325         gl_FUNC_GETTIMEOFDAY_CLOBBER): Set GETTIMEOFDAY_REPLACEMENT instead of
4326         HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4327         * m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H): Initialize
4328         GETTIMEOFDAY_REPLACEMENT instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE
4329         and GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4330         * modules/sys_time (sys/time.h): Substitute GETTIMEOFDAY_REPLACEMENT
4331         instead of HAVE_GETTIMEOFDAY_POSIX_SIGNATURE and
4332         GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4333
4334         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Undo the
4335         last change; it caused a compilation error when cross-compiling to
4336         Cygwin.
4337
4338 2007-01-18  Jim Meyering  <jim@meyering.net>
4339
4340         Use "$(MKDIR_P) sys", not race-prone "test -d sys || mkdir sys".
4341         * modules/sys_stat (Makefile.am): Use "$(MKDIR_P) sys", rather
4342         than the race-prone "test -d sys || mkdir sys".
4343         (configure.ac): Use AC_PROG_MKDIR_P.
4344         * modules/sys_select: Likewise.
4345         * modules/sys_socket: Likewise.
4346         * modules/sys_time: Likewise.
4347
4348 2007-01-18  Eric Blake  <ebb9@byu.net>
4349
4350         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Also
4351         replace gettimeofday.
4352         * lib/gettimeofday.c (rpl_gettimeofday): Declare with replacement
4353         name, to avoid infinite recursion.
4354
4355 2007-01-17  Paul Eggert  <eggert@cs.ucla.edu>
4356
4357         * MODULES.html.sh (Support for systems lacking POSIX:2001): New
4358         module sys_time.
4359         * lib/gethrxtime.c: Include <sys/time.h>, since we can no longer
4360         assume timespec.h defines struct timeval.
4361         * lib/settime.c: Likewise.
4362         * lib/utimens.c: Likewise.
4363         * lib/gettime.c (gettime): Remove test against HAVE_GETTIMEOFDAY,
4364         since we now assume the gettimeofday module.
4365         * lib/tempname.c (__gen_tempname): Likewise.
4366         * lib/gettimeofday.h: Remove.
4367         * lib/gettimeofday.c: Include <sys/time.h> instead of "gettimeofday.h".
4368         Don't include <sys/types.h> and <stdlib.h>; shouldn't be needed.
4369         Include <time.h>, for 'time()'.
4370         (localtime_buffer_addr): Also use this workaround if
4371         TZSET_CLOBBERS_LOCALTIME.  Set to a dummy static variable by default,
4372         to simplify the uses.  All uses changed.
4373         (localtime, gmtime, tzset, gettimeofday): Reformat slightly so
4374         that #undef is inside {}, and 'const' follows type name consistently.
4375         (tzset): Define replacement only if TZSET_CLOBBERS_LOCALTIME.
4376         (gettimeofday): Do not use the maximum possible value for
4377         tv->tv_usec, since that might break usages other than ls.c.
4378         Instead, we'll leave ls.c alone.  This undoes today's patch
4379         by Bruno.  Add a compile-time warning for 1s-clock resolution;
4380         we've never observed the problem but might as well keep the
4381         canary.
4382         * lib/nanosleep.c: Include timespec.h first, for interface check.
4383         * lib/nanosleep.c: Include <sys/time.h> unconditionally, since we
4384         now assume the sys_time module.
4385         * lib/tempname.c: Likewise.
4386         * lib/timespec.h: Likewise.
4387         * lib/nanosleep.c: Don't worry about TIME_WITH_SYS_TIME; no longer
4388         needed.
4389         * lib/strftime.c: Likewise.
4390         * lib/timespec.h: Likewise.
4391         * lib/posixtm.c: Include posixtm.h first, for interface check.
4392         Don't worry about TM_IN_SYS_TIME; that's wayyy obsolete.
4393         * lib/posixtm.h: Include stdbool.h and time.h, for proper interface.
4394         * lib/strftime.c: Don't include <sys/types.h>; shouldn't be needed.
4395         * lib/sys_time_.h: New file.
4396         * lib/timespec.h (struct timespec): Use long int, not long.
4397         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY):
4398         (gl_FUNC_GETTIMEOFDAY_CLOBBER, gl_PREREQ_GETTIMEOFDAY):
4399         Remove obsolescent call to AC_HEADER_TIME.
4400         * m4/mktime.m4 (AC_FUNC_MKTIME): Likewise.
4401         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
4402         * m4/strftime.m4 (gl_FUNC_STRFTIME): Likewise.
4403         * m4/timespec.m4 (gl_TIMESPEC, gl_CHECK_TYPE_STRUCT_TIMESPEC):
4404         Likewise.
4405         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Likewise.
4406         * m4/utimbuf.m4 (gl_CHECK_TYPE_STRUCT_UTIMBUF): Likewise.
4407         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): Move sys/time.h tests
4408         into the sys_time module.  Check for gettimeofday just once.
4409         Prefix our variables with gl_, not with ac_ or jm_.  Tighten test
4410         for gettimeofday signature to just check the signature.  Merely
4411         compile it, since linking doesn't test signature.  Improve test for
4412         whether gettimeofday.o is actually needed.
4413         (gl_FUNC_GETTIMEOFDAY_CLOBBER): Renamed from
4414         AC_FUNC_GETTIMEOFDAY_CLOBBER.  All uses changed.  Use
4415         AC_RUN_IFELSE rather than AC_TRY_RUN.  If clobbering, set
4416         and define GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4417         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Don't define
4418         GETTIMEOFDAY_CLOBBERS_LOCALTIME; that's gl_FUNC_GETTIMEOFDAY_CLOBBER's
4419         job.  Don't define tzset; that's gl_FUNC_TZSET_CLOBBER's job.
4420         * m4/mktime.m4 (AC_FUNC_MKTIME): Just include <time.h> rather
4421         than worrying about sys/time.h.
4422         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
4423         Don't bother worrying about TIME_WITH_SYS_TIME.
4424         * m4/stat-time.m4 (gl_STAT_TIME): Likewise.
4425         * m4/posixtm.m4 (gl_POSIXTM): Remove obsolescent call to AC_STRUCT_TM.
4426         * m4/sys_time_h.m4: New file.
4427         * m4/tzset.m4 (gl_FUNC_TZSET_CLOBBER): Require gl_HEADER_SYS_TIME_H.
4428         Don't include sys/time.h.  Return from main rather than exiting.
4429         Define TZSET_CLOBBERS_LOCALTIME, for consistency with other names;
4430         all uses changed.
4431         * modules/gethrxtime (Depends-on): Add sys_time.
4432         * modules/gettime (Depends-on): Likewise.
4433         * modules/gettimeofday (Depends-on): Likewise.
4434         * modules/nanosleep (Depends-on): Likewise.
4435         * modules/settime (Depends-on): Likewise.
4436         * modules/tempname (Depends-on): Likewise.
4437         * modules/utimens (Depends-on): Likewise.
4438         * modules/gettimeofday (Files): Remove lib/gettimeofday.h.
4439         (Include:) Change back to <sys/time.h>.
4440         (Maintainer:) Add self.
4441         * modules/sys_time: New file.
4442         * modules/tempname (Depends-on): Add gettimeofday.
4443         * tests/test-gettimeofday.c: Include <sys/time.h>
4444         rather than gettimeofday.h.
4445
4446 2007-01-17  Bruno Haible  <bruno@clisp.org>
4447
4448         * gnulib-tool (func_get_license): Revert last patch. Instead, let
4449         the license default to GPL.
4450         (func_create_testdir): Don't complain if a module is LGPL and its
4451         tests module depends on GPLed modules.
4452
4453 2007-01-17  Bruno Haible  <bruno@clisp.org>
4454
4455         * lib/gettimeofday.c (gettimeofday): Add code for the case
4456         HAVE_GETTIMEOFDAY && !GETTIMEOFDAY_CLOBBERS_LOCALTIME. Use the
4457         maximum possible value for tv->tv_usec, rather than the minimum one.
4458
4459 2005-10-08  Martin Lambers  <marlam@marlam.de>
4460 2005-10-08  Paul Eggert  <eggert@cs.ucla.edu>
4461 2007-01-16  Bruno Haible  <bruno@clisp.org>
4462
4463         * modules/gettimeofday (Files): Add lib/gettimeofday.h.
4464         (configure.ac): Remove AC_FUNC_GETTIMEOFDAY_CLOBBER. Add
4465         gl_FUNC_GETTIMEOFDAY.
4466         (Include): Add gettimeofday.h.
4467         * m4/gettimeofday.m4 (gl_FUNC_GETTIMEOFDAY): New macro.
4468         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't invoke gl_PREREQ_GETTIMEOFDAY.
4469         (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): Define
4470         GETTIMEOFDAY_CLOBBERS_LOCALTIME. Invoke gl_PREREQ_GETTIMEOFDAY here.
4471         (gl_PREREQ_GETTIMEOFDAY): Check for <sys/timeb.h> and _ftime.
4472         * lib/gettimeofday.h: New file.
4473         * lib/gettimeofday.c: Include <sys/timeb.h>.
4474         (localtime_buffer_addr, rpl_localtime, rpl_gmtime, rpl_tzset): Define
4475         only if GETTIMEOFDAY_CLOBBERS_LOCALTIME.
4476         (rpl_gettimeofday) [!HAVE_GETTIMEOFDAY]: Use _ftime() when available;
4477         fall back on time().
4478
4479         * tests/test-gettimeofday.c: New file.
4480         * modules/gettimeofday-tests: New file.
4481
4482 2007-01-16  Eric Blake  <ebb9@byu.net>
4483
4484         * modules/fnmatch (Depends-on): Depend on wchar.
4485         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Assume <wchar.h>.
4486         * m4/fnmatch.m4: Likewise.
4487         * modules/mbchar (Makefile.am): Assume <wchar.h>.
4488         * m4/mbchar.m4: Likewise.
4489         * modules/mbswidth (Depends-on): Depend on wchar.
4490         * lib/mbswidth.c: Assume <wchar.h>.
4491         * m4/mbswidth.m4: Likewise.
4492         * modules/quotearg (Depends-on): Depend on wchar.
4493         * lib/quotearg.c: Assume <wchar.h>.
4494         * m4/quotearg.m4: Likewise.
4495         * modules/regex (Depends-on): Depend on wchar.
4496         * lib/regex_internal.h: Assume <wchar.h>.
4497         * m4/regex.m4: Likewise.
4498         * modules/stdint (Depends-on): Depend on wchar.
4499         * lib/stdint_.h [!defined WCHAR_MIN]: Assume <wchar.h>.
4500         * m4/stdint.m4: Likewise.
4501         * tests/test-stdint.c [HAVE_WINT_T]: Likewise.
4502         * modules/strftime (Depends-on): Depend on wchar.
4503         * lib/strftime.c (DO_MULTIBYTE): Assume <wchar.h>.
4504         * modules/strtol (Depends-on): Depend on wchar.
4505         * lib/strtol.c: Assume <wchar.h>.
4506         * modules/wcwidth (Depends-on): Depend on wchar.
4507         * lib/wcwidth.h: Assume <wchar.h>.
4508         * m4/wcwidth.m4: Likewise.
4509
4510 2007-01-16  Bruno Haible  <bruno@clisp.org>
4511
4512         * modules/csharpexec-script: New, created from...
4513         * modules/csharpexec: ... this.
4514
4515 2007-01-16  Paolo Bonzini  <bonzini@gnu.org>
4516
4517         * modules/javaexec-script: New, created from...
4518         * modules/javaexec: ... this.
4519
4520 2007-01-16  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
4521
4522         * modules/poll (Dependencies): Add sys_select.
4523
4524 2007-01-15  Jim Meyering  <jim@meyering.net>
4525
4526         * m4/readutmp.m4 (gl_READUTMP): Work around AIX 4.3 struct-
4527         redefinition bug when using both <utmp.h> and <utmpx.h> headers.
4528         * lib/readutmp.h: Likewise.  Reported by Daniel Richard G. in
4529         <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9415>.
4530
4531 2007-01-15  Bruno Haible  <bruno@clisp.org>
4532
4533         * modules/striconveh: New file.
4534         * lib/striconveh.h: New file.
4535         * lib/striconveh.c: New file.
4536         * MODULES.html.sh (Internationalization functions): Add striconveh.
4537
4538         * modules/striconveh-tests: New file.
4539         * tests/test-striconveh.c: New file.
4540
4541 2007-01-15  Bruno Haible  <bruno@clisp.org>
4542
4543         * lib/striconv.c (str_cd_iconv): Use the first algorithm if iconv is
4544         not from GNU libiconv or GNU libc.
4545
4546 2007-01-15  Bruno Haible  <bruno@clisp.org>
4547
4548         * doc/gnulib-intro.texi (Copyright): Explain the different license
4549         terms for module descriptions, autoconf macros, tests, documentation.
4550
4551 2007-01-14  Bruno Haible  <bruno@clisp.org>
4552
4553         * modules/striconv-tests: New file.
4554         * tests/test-striconv.c: New file.
4555
4556 2007-01-14  Bruno Haible  <bruno@clisp.org>
4557
4558         * modules/iconv-tests: New file.
4559         * tests/test-iconv.c: New file.
4560
4561 2007-01-14  Bruno Haible  <bruno@clisp.org>
4562
4563         * gnulib-tool (func_get_license): For test modules, use the license of
4564         the main module.
4565
4566 2007-01-14  Bruno Haible  <bruno@clisp.org>
4567
4568         * modules/iconv (Include): Clarify that <iconv.h> can only be included
4569         if iconv is found to exist.
4570
4571 2007-01-14  Bruno Haible  <bruno@clisp.org>
4572
4573         * modules/c-ctype-tests: New file.
4574         * tests/test-c-ctype.c: New file.
4575
4576 2007-01-14  Bruno Haible  <bruno@clisp.org>
4577
4578         * modules/binary-io-tests: New file.
4579         * tests/test-binary-io.sh: New file.
4580         * tests/test-binary-io.c: New file.
4581
4582 2007-01-14  Bruno Haible  <bruno@clisp.org>
4583
4584         * modules/array-oset-tests: New file.
4585         * tests/test-array_oset.c: New file.
4586
4587 2007-01-14  Bruno Haible  <bruno@clisp.org>
4588
4589         * modules/array-list-tests: New file.
4590         * tests/test-array_list.c: New file.
4591
4592 2007-01-14  Bruno Haible  <bruno@clisp.org>
4593
4594         * gnulib-tool (func_create_testdir): Don't unnecessarily run configure
4595         and make.
4596         Reported by Simon Josefsson in
4597         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00139.html>
4598
4599 2007-01-14  Bruno Haible  <bruno@clisp.org>
4600
4601         * modules/allocsa-tests: New file.
4602         * tests/test-allocsa.c: New file.
4603
4604 2007-01-14  Bruno Haible  <bruno@clisp.org>
4605
4606         * modules/fchdir (Depends-on): Add absolute-header.
4607         * modules/unistd (Depends-on): Likewise.
4608
4609 2006-12-30  Bruno Haible  <bruno@clisp.org>
4610
4611         * modules/fchdir: New file.
4612         * modules/unistd (Files): Add lib/unistd_.h.
4613         (Makefile.am): Generate unistd.h from unistd_.h.
4614         * lib/fchdir.c: New file.
4615         * lib/dirent_.h: New file.
4616         * lib/unistd_.h: New file.
4617         * lib/fcntl_.h (open) [FCHDIR_REPLACEMENT]: New replacement.
4618         * m4/fchdir.m4: New file.
4619         * m4/unistd_h.m4 (gl_PREREQ_UNISTD): New macro.
4620         (gl_HEADER_UNISTD): Invoke it.
4621         * lib/dup-safer.c (dup_safer) [FCHDIR_REPLACEMENT]: Use the dup
4622         function.
4623         * lib/backupfile.c (opendir, closedir): Undefine.
4624         * lib/chown.c (open, close): Undefine.
4625         * lib/clean-temp.c (open, close): Undefine.
4626         * lib/copy-file.c (open, close): Undefine.
4627         * lib/execute.c (open, close): Undefine.
4628         * lib/fsusage.c (open, close): Undefine.
4629         * lib/gc-gnulib.c (open, close): Undefine.
4630         * lib/getcwd.c (opendir, closedir): Undefine.
4631         * lib/glob.c (opendir, closedir): Undefine.
4632         * lib/javacomp.c (open, close): Undefine.
4633         * lib/mountlist.c (open, close, opendir, closedir): Undefine.
4634         * lib/openat-proc.c (open, close): Undefine.
4635         * lib/pagealign_alloc.c (open, close): Undefine.
4636         * lib/pipe.c (open, close): Undefine.
4637         * lib/progreloc.c (open, close): Undefine.
4638         * lib/savedir.c (opendir, closedir): Undefine.
4639         * lib/utime.c (open, close): Undefine.
4640         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add fchdir.
4641
4642 2007-01-10  Bruno Haible  <bruno@clisp.org>
4643
4644         * lib/striconv.c (mem_cd_iconv): Align the temporary buffer.
4645
4646 2007-01-12  Eric Blake  <ebb9@byu.net>
4647
4648         Provide a robust <wchar.h>.  Further simplifications are now
4649         possible in other modules, but not included here.
4650         * modules/wchar: New module.
4651         * m4/wchar.m4: New file.
4652         * lib/wchar_.h: Likewise.
4653         * modules/mbchar (Depends-on): Depend on wchar, as the first use
4654         of the new module.
4655         * MODULES.html.sh (Extended multibyte and wide character utilities):
4656         New section.
4657
4658 2007-01-12  Paul Eggert  <eggert@cs.ucla.edu>
4659
4660         * lib/xreadlink.c (SYMLINK_MAX) [!defined SYMLINK_MAX]: Define
4661         to a reasonable default for memory allocation.
4662         (xreadlink): Don't allocate a huge buffer, to work around a buggy
4663         file system that reports garbage st_size values for symlinks.
4664         Problem reported by Liyang Hu.
4665
4666 2007-01-11  Simon Josefsson  <simon@josefsson.org>
4667
4668         * gnulib-tool (func_all_modules): Exclude all .* files (e.g.,
4669         Emacs .#* auto-save files).
4670
4671 2007-01-11  Bruno Haible  <bruno@clisp.org>
4672
4673         * gnulib-tool (func_all_modules): Exclude all files inside the CVS
4674         directory.
4675
4676 2007-01-10  Paul Eggert  <eggert@cs.ucla.edu>
4677
4678         Use @...@ consistently in lib/wctype_.h.
4679         * lib/wctype_.h [HAVE_WINT_T]: Go back to using @...@, but rely
4680         on it being set to 1 or 0.
4681         * m4/wctype.m4 (gl_WCTYPE_H): Set HAVE_WINT_T to 1 or 0, and
4682         go back to AC_SUBSTing it.
4683         * modules/wctype (Makefile.am): Undo previous change.
4684
4685 2007-01-10  Eric Blake  <ebb9@byu.net>
4686
4687         * lib/wctype_.h [HAVE_WINT_T]: Rely on AC_DEFINE.
4688         * m4/wctype.m4 (gl_WCTYPE_H): No need to AC_SUBST(HAVE_WINT_T).
4689         * modules/wctype (Makefile.am): Likewise.
4690         Reported by Chris McGuire.
4691
4692 2007-01-10  Jim Meyering  <jim@meyering.net>
4693
4694         fts.c: a small readability/maintainability improvement
4695         * lib/fts.c (fts_read): Make this code slightly more readable and
4696         maintainable by hoisting the "sp->fts_cur = p" assignments to
4697         immediately follow the statements that set P.  Derived from
4698         the patch by Miloslav Trmac in http://bugzilla.redhat.com/222089.
4699
4700 2007-01-10  Eric Blake  <ebb9@byu.net>
4701
4702         * lib/wctype_.h [HAVE_WINT_T]: Include <stddef.h> before
4703         <wchar.h>, to work around BSDI bug in BSD/OS 4.0.1.
4704         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
4705         * m4/wint_t.m4 (gt_TYPE_WINT_T): Likewise.
4706         Reported by Chris McGuire.
4707
4708 2007-01-09  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
4709
4710         * gnulib-tool (func_all_modules): Use POSIX conforming escaping
4711         in sed script.
4712
4713 2007-01-09  Bruno Haible  <bruno@clisp.org>
4714
4715         * MODULES.html.sh: Accept options --cvs-urls, --git-urls.
4716         (repo_url_prefix, repo_url_suffix, repo_url_suffix_repl): New
4717         variables.
4718         (func_module): Use them.
4719
4720 2007-01-09  Bruno Haible  <bruno@clisp.org>
4721
4722         * modules/unistr/base: New file.
4723         * lib/unistr.h: New file.
4724
4725         * modules/unistr/u8-to-u16: New file.
4726         * lib/unistr/u8-to-u16.c: New file.
4727
4728         * modules/unistr/u8-to-u32: New file.
4729         * lib/unistr/u8-to-u32.c: New file.
4730
4731         * modules/unistr/u16-to-u8: New file.
4732         * lib/unistr/u16-to-u8.c: New file.
4733
4734         * modules/unistr/u16-to-u32: New file.
4735         * lib/unistr/u16-to-u32.c: New file.
4736
4737         * modules/unistr/u32-to-u8: New file.
4738         * lib/unistr/u32-to-u8.c: New file.
4739
4740         * modules/unistr/u32-to-u16: New file.
4741         * lib/unistr/u32-to-u16.c: New file.
4742
4743         * modules/unistr/u8-check: New file.
4744         * modules/unistr/u16-check: New file.
4745         * modules/unistr/u32-check: New file.
4746         * lib/unistr/u8-check.c: New file.
4747         * lib/unistr/u16-check.c: New file.
4748         * lib/unistr/u32-check.c: New file.
4749
4750         * modules/unistr/u8-chr: New file.
4751         * modules/unistr/u16-chr: New file.
4752         * modules/unistr/u32-chr: New file.
4753         * lib/unistr/u8-chr.c: New file.
4754         * lib/unistr/u16-chr.c: New file.
4755         * lib/unistr/u32-chr.c: New file.
4756
4757         * modules/unistr/u8-cmp: New file.
4758         * modules/unistr/u16-cmp: New file.
4759         * modules/unistr/u32-cmp: New file.
4760         * lib/unistr/u8-cmp.c: New file.
4761         * lib/unistr/u16-cmp.c: New file.
4762         * lib/unistr/u32-cmp.c: New file.
4763
4764         * modules/unistr/u8-cpy: New file.
4765         * modules/unistr/u16-cpy: New file.
4766         * modules/unistr/u32-cpy: New file.
4767         * lib/unistr/u8-cpy.c: New file.
4768         * lib/unistr/u16-cpy.c: New file.
4769         * lib/unistr/u32-cpy.c: New file.
4770         * lib/unistr/u-cpy.h: New file.
4771
4772         * modules/unistr/u8-cpy-alloc: New file.
4773         * modules/unistr/u16-cpy-alloc: New file.
4774         * modules/unistr/u32-cpy-alloc: New file.
4775         * lib/unistr/u8-cpy-alloc.c: New file.
4776         * lib/unistr/u16-cpy-alloc.c: New file.
4777         * lib/unistr/u32-cpy-alloc.c: New file.
4778         * lib/unistr/u-cpy-alloc.h: New file.
4779
4780         * modules/unistr/u8-endswith: New file.
4781         * modules/unistr/u16-endswith: New file.
4782         * modules/unistr/u32-endswith: New file.
4783         * lib/unistr/u8-endswith.c: New file.
4784         * lib/unistr/u16-endswith.c: New file.
4785         * lib/unistr/u32-endswith.c: New file.
4786         * lib/unistr/u-endswith.h: New file.
4787
4788         * modules/unistr/u8-mblen: New file.
4789         * modules/unistr/u16-mblen: New file.
4790         * modules/unistr/u32-mblen: New file.
4791         * lib/unistr/u8-mblen.c: New file.
4792         * lib/unistr/u16-mblen.c: New file.
4793         * lib/unistr/u32-mblen.c: New file.
4794
4795         * modules/unistr/u8-mbtouc: New file.
4796         * modules/unistr/u16-mbtouc: New file.
4797         * modules/unistr/u32-mbtouc: New file.
4798         * lib/unistr/u8-mbtouc.c: New file.
4799         * lib/unistr/u16-mbtouc.c: New file.
4800         * lib/unistr/u32-mbtouc.c: New file.
4801
4802         * modules/unistr/u8-mbtouc-safe: New file.
4803         * modules/unistr/u16-mbtouc-safe: New file.
4804         * modules/unistr/u32-mbtouc-safe: New file.
4805         * lib/unistr/u8-mbtouc-safe.c: New file.
4806         * lib/unistr/u16-mbtouc-safe.c: New file.
4807         * lib/unistr/u32-mbtouc-safe.c: New file.
4808
4809         * modules/unistr/u8-move: New file.
4810         * modules/unistr/u16-move: New file.
4811         * modules/unistr/u32-move: New file.
4812         * lib/unistr/u8-move.c: New file.
4813         * lib/unistr/u16-move.c: New file.
4814         * lib/unistr/u32-move.c: New file.
4815         * lib/unistr/u-move.h: New file.
4816
4817         * modules/unistr/u8-next: New file.
4818         * modules/unistr/u16-next: New file.
4819         * modules/unistr/u32-next: New file.
4820         * lib/unistr/u8-next.c: New file.
4821         * lib/unistr/u16-next.c: New file.
4822         * lib/unistr/u32-next.c: New file.
4823
4824         * modules/unistr/u8-prev: New file.
4825         * modules/unistr/u16-prev: New file.
4826         * modules/unistr/u32-prev: New file.
4827         * lib/unistr/u8-prev.c: New file.
4828         * lib/unistr/u16-prev.c: New file.
4829         * lib/unistr/u32-prev.c: New file.
4830
4831         * modules/unistr/u8-set: New file.
4832         * modules/unistr/u16-set: New file.
4833         * modules/unistr/u32-set: New file.
4834         * lib/unistr/u8-set.c: New file.
4835         * lib/unistr/u16-set.c: New file.
4836         * lib/unistr/u32-set.c: New file.
4837         * lib/unistr/u-set.h: New file.
4838
4839         * modules/unistr/u8-startswith: New file.
4840         * modules/unistr/u16-startswith: New file.
4841         * modules/unistr/u32-startswith: New file.
4842         * lib/unistr/u8-startswith.c: New file.
4843         * lib/unistr/u16-startswith.c: New file.
4844         * lib/unistr/u32-startswith.c: New file.
4845         * lib/unistr/u-startswith.h: New file.
4846
4847         * modules/unistr/u8-stpcpy: New file.
4848         * modules/unistr/u16-stpcpy: New file.
4849         * modules/unistr/u32-stpcpy: New file.
4850         * lib/unistr/u8-stpcpy.c: New file.
4851         * lib/unistr/u16-stpcpy.c: New file.
4852         * lib/unistr/u32-stpcpy.c: New file.
4853         * lib/unistr/u-stpcpy.h: New file.
4854
4855         * modules/unistr/u8-stpncpy: New file.
4856         * modules/unistr/u16-stpncpy: New file.
4857         * modules/unistr/u32-stpncpy: New file.
4858         * lib/unistr/u8-stpncpy.c: New file.
4859         * lib/unistr/u16-stpncpy.c: New file.
4860         * lib/unistr/u32-stpncpy.c: New file.
4861         * lib/unistr/u-stpncpy.h: New file.
4862
4863         * modules/unistr/u8-strcat: New file.
4864         * modules/unistr/u16-strcat: New file.
4865         * modules/unistr/u32-strcat: New file.
4866         * lib/unistr/u8-strcat.c: New file.
4867         * lib/unistr/u16-strcat.c: New file.
4868         * lib/unistr/u32-strcat.c: New file.
4869         * lib/unistr/u-strcat.h: New file.
4870
4871         * modules/unistr/u8-strchr: New file.
4872         * modules/unistr/u16-strchr: New file.
4873         * modules/unistr/u32-strchr: New file.
4874         * lib/unistr/u8-strchr.c: New file.
4875         * lib/unistr/u16-strchr.c: New file.
4876         * lib/unistr/u32-strchr.c: New file.
4877
4878         * modules/unistr/u8-strcmp: New file.
4879         * modules/unistr/u16-strcmp: New file.
4880         * modules/unistr/u32-strcmp: New file.
4881         * lib/unistr/u8-strcmp.c: New file.
4882         * lib/unistr/u16-strcmp.c: New file.
4883         * lib/unistr/u32-strcmp.c: New file.
4884
4885         * modules/unistr/u8-strcpy: New file.
4886         * modules/unistr/u16-strcpy: New file.
4887         * modules/unistr/u32-strcpy: New file.
4888         * lib/unistr/u8-strcpy.c: New file.
4889         * lib/unistr/u16-strcpy.c: New file.
4890         * lib/unistr/u32-strcpy.c: New file.
4891         * lib/unistr/u-strcpy.h: New file.
4892
4893         * modules/unistr/u8-strcspn: New file.
4894         * modules/unistr/u16-strcspn: New file.
4895         * modules/unistr/u32-strcspn: New file.
4896         * lib/unistr/u8-strcspn.c: New file.
4897         * lib/unistr/u16-strcspn.c: New file.
4898         * lib/unistr/u32-strcspn.c: New file.
4899         * lib/unistr/u-strcspn.h: New file.
4900
4901         * modules/unistr/u8-strdup: New file.
4902         * modules/unistr/u16-strdup: New file.
4903         * modules/unistr/u32-strdup: New file.
4904         * lib/unistr/u8-strdup.c: New file.
4905         * lib/unistr/u16-strdup.c: New file.
4906         * lib/unistr/u32-strdup.c: New file.
4907         * lib/unistr/u-strdup.h: New file.
4908
4909         * modules/unistr/u8-strlen: New file.
4910         * modules/unistr/u16-strlen: New file.
4911         * modules/unistr/u32-strlen: New file.
4912         * lib/unistr/u8-strlen.c: New file.
4913         * lib/unistr/u16-strlen.c: New file.
4914         * lib/unistr/u32-strlen.c: New file.
4915         * lib/unistr/u-strlen.h: New file.
4916
4917         * modules/unistr/u8-strmblen: New file.
4918         * modules/unistr/u16-strmblen: New file.
4919         * modules/unistr/u32-strmblen: New file.
4920         * lib/unistr/u8-strmblen.c: New file.
4921         * lib/unistr/u16-strmblen.c: New file.
4922         * lib/unistr/u32-strmblen.c: New file.
4923
4924         * modules/unistr/u8-strmbtouc: New file.
4925         * modules/unistr/u16-strmbtouc: New file.
4926         * modules/unistr/u32-strmbtouc: New file.
4927         * lib/unistr/u8-strmbtouc.c: New file.
4928         * lib/unistr/u16-strmbtouc.c: New file.
4929         * lib/unistr/u32-strmbtouc.c: New file.
4930
4931         * modules/unistr/u8-strncat: New file.
4932         * modules/unistr/u16-strncat: New file.
4933         * modules/unistr/u32-strncat: New file.
4934         * lib/unistr/u8-strncat.c: New file.
4935         * lib/unistr/u16-strncat.c: New file.
4936         * lib/unistr/u32-strncat.c: New file.
4937         * lib/unistr/u-strncat.h: New file.
4938
4939         * modules/unistr/u8-strncmp: New file.
4940         * modules/unistr/u16-strncmp: New file.
4941         * modules/unistr/u32-strncmp: New file.
4942         * lib/unistr/u8-strncmp.c: New file.
4943         * lib/unistr/u16-strncmp.c: New file.
4944         * lib/unistr/u32-strncmp.c: New file.
4945
4946         * modules/unistr/u8-strncpy: New file.
4947         * modules/unistr/u16-strncpy: New file.
4948         * modules/unistr/u32-strncpy: New file.
4949         * lib/unistr/u8-strncpy.c: New file.
4950         * lib/unistr/u16-strncpy.c: New file.
4951         * lib/unistr/u32-strncpy.c: New file.
4952         * lib/unistr/u-strncpy.h: New file.
4953
4954         * modules/unistr/u8-strnlen: New file.
4955         * modules/unistr/u16-strnlen: New file.
4956         * modules/unistr/u32-strnlen: New file.
4957         * lib/unistr/u8-strnlen.c: New file.
4958         * lib/unistr/u16-strnlen.c: New file.
4959         * lib/unistr/u32-strnlen.c: New file.
4960         * lib/unistr/u-strnlen.h: New file.
4961
4962         * modules/unistr/u8-strpbrk: New file.
4963         * modules/unistr/u16-strpbrk: New file.
4964         * modules/unistr/u32-strpbrk: New file.
4965         * lib/unistr/u8-strpbrk.c: New file.
4966         * lib/unistr/u16-strpbrk.c: New file.
4967         * lib/unistr/u32-strpbrk.c: New file.
4968         * lib/unistr/u-strpbrk.h: New file.
4969
4970         * modules/unistr/u8-strrchr: New file.
4971         * modules/unistr/u16-strrchr: New file.
4972         * modules/unistr/u32-strrchr: New file.
4973         * lib/unistr/u8-strrchr.c: New file.
4974         * lib/unistr/u16-strrchr.c: New file.
4975         * lib/unistr/u32-strrchr.c: New file.
4976
4977         * modules/unistr/u8-strspn: New file.
4978         * modules/unistr/u16-strspn: New file.
4979         * modules/unistr/u32-strspn: New file.
4980         * lib/unistr/u8-strspn.c: New file.
4981         * lib/unistr/u16-strspn.c: New file.
4982         * lib/unistr/u32-strspn.c: New file.
4983         * lib/unistr/u-strspn.h: New file.
4984
4985         * modules/unistr/u8-strstr: New file.
4986         * modules/unistr/u16-strstr: New file.
4987         * modules/unistr/u32-strstr: New file.
4988         * lib/unistr/u8-strstr.c: New file.
4989         * lib/unistr/u16-strstr.c: New file.
4990         * lib/unistr/u32-strstr.c: New file.
4991         * lib/unistr/u-strstr.h: New file.
4992
4993         * modules/unistr/u8-strtok: New file.
4994         * modules/unistr/u16-strtok: New file.
4995         * modules/unistr/u32-strtok: New file.
4996         * lib/unistr/u8-strtok.c: New file.
4997         * lib/unistr/u16-strtok.c: New file.
4998         * lib/unistr/u32-strtok.c: New file.
4999         * lib/unistr/u-strtok.h: New file.
5000
5001         * modules/unistr/u8-uctomb: New file.
5002         * modules/unistr/u16-uctomb: New file.
5003         * modules/unistr/u32-uctomb: New file.
5004         * lib/unistr/u8-uctomb.c: New file.
5005         * lib/unistr/u16-uctomb.c: New file.
5006         * lib/unistr/u32-uctomb.c: New file.
5007
5008         * MODULES.html.sh (Unicode string functions): Add the new modules.
5009
5010 2007-01-08  Bruno Haible  <bruno@clisp.org>
5011
5012         * gnulib-tool (func_all_modules): Use find, not ls, to traverse the
5013         modules directory. Filter out CVS, ChangeLog, COPYING, README also from
5014         subdirectories.
5015
5016 2007-01-08  Karl Berry  <karl@gnu.org>
5017
5018         * doc/error.texi: mention that main() fns must set program_name
5019         when progname is used.
5020
5021 2007-01-08  Paul Eggert  <eggert@cs.ucla.edu>
5022
5023         * m4/wctype.m4 (gl_WCTYPE_H): Compute ABSOLUTE_WCTYPE_H even if
5024         WCTYPE_H is empty, for the benefit of builds from non-distclean
5025         directories.  Problem reported by Eric Blake in
5026         <http://lists.gnu.org/archive/html/bug-gnulib/2007-01/msg00157.html>.
5027
5028 2007-01-08  Bruno Haible  <bruno@clisp.org>
5029
5030         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Remove
5031         PROVIDE_CANONICALIZE_FILENAME_MODE macro definition.
5032         * lib/canonicalize.h: Test GNULIB_CANONICALIZE instead of
5033         PROVIDE_CANONICALIZE_FILENAME_MODE.
5034         * modules/canonicalize (configure.ac): Use gl_MODULE_INDICATOR.
5035
5036 2007-01-08  Bruno Haible  <bruno@clisp.org>
5037
5038         * m4/fts.m4 (gl_FUNC_FTS_LGPL): Remove _LGPL_PACKAGE macro definition.
5039         * lib/fts_.h (_LGPL_PACKAGE): Remove macro.
5040         Use !GNULIB_FTS instead of _LGPL_PACKAGE.
5041         * lib/fts.c: Likewise.
5042         * modules/fts (configure.ac): Use gl_MODULE_INDICATOR.
5043
5044 2006-12-25  Bruno Haible  <bruno@clisp.org>
5045
5046         * modules/utf8-ucs4-safe: New file.
5047         * lib/utf8-ucs4-safe.h: New file.
5048         * lib/unistr/utf8-ucs4-safe.c: New file.
5049
5050         * modules/utf16-ucs4-safe: New file.
5051         * lib/utf16-ucs4-safe.h: New file.
5052         * lib/unistr/utf16-ucs4-safe.c: New file.
5053
5054         * MODULES.html.sh (Unicode string functions): Add the new modules.
5055
5056 2007-01-08  Bruno Haible  <bruno@clisp.org>
5057
5058         * modules/utf8-ucs4 (Files, lib_SOURCES): Add unistr/utf8-ucs4.c.
5059         (Depends-on): Add unitypes.
5060         * lib/utf8-ucs4.h: Add double-inclusion guard. Include unitypes.h.
5061         (u8_mbtouc_aux): Move out to separate file.
5062         (u8_mbtouc): Use ucs4_t, uint8_t types.
5063         * lib/unistr/utf8-ucs4.c: New file.
5064
5065         * modules/utf16-ucs4 (Files, lib_SOURCES): Add unistr/utf16-ucs4.c.
5066         (Depends-on): Add unitypes.
5067         * lib/utf16-ucs4.h: Add double-inclusion guard. Include unitypes.h.
5068         (u16_mbtouc_aux): Move out to separate file.
5069         (u16_mbtouc): Use ucs4_t, uint16_t types.
5070         * lib/unistr/utf16-ucs4.c: New file.
5071
5072         * modules/ucs4-utf8 (Files, lib_SOURCES): Add unistr/ucs4-utf8.c.
5073         (Depends-on): Add unitypes.
5074         * lib/ucs4-utf8.h: Add double-inclusion guard. Include unitypes.h.
5075         (u8_uctomb_aux): Move out to separate file.
5076         (u8_uctomb): Use ucs4_t, uint8_t types.
5077         * lib/unistr/ucs4-utf8.c: New file.
5078
5079         * modules/ucs4-utf16 (Files, lib_SOURCES): Add unistr/ucs4-utf16.c.
5080         (Depends-on): Add unitypes.
5081         * lib/ucs4-utf16.h: Add double-inclusion guard. Include unitypes.h.
5082         (u16_uctomb_aux): Move out to separate file.
5083         (u16_uctomb): Use ucs4_t, uint16_t types.
5084         * lib/unistr/ucs4-utf16.c: New file.
5085
5086 2006-12-25  Bruno Haible  <bruno@clisp.org>
5087
5088         * modules/unitypes: New file.
5089         * lib/unitypes.h: New file.
5090         * MODULES.html.sh (func_all_modules): New section "Unicode string
5091         functions". Move ucs4-utf8, ucs4-utf16, utf8-ucs4, utf16-ucs4 to
5092         this section. Add unitypes.
5093
5094 2007-01-08  Bruno Haible  <bruno@clisp.org>
5095
5096         Avoid variable names that conflict with those from libtool.
5097         * m4/lib-link.m4 (AC_LIB_RPATH, AC_LIB_LINKFLAGS_BODY,
5098         AC_LIB_LINKFLAGS_FROM_LIBS): Rename libext to acl_libext,
5099         shlibext to acl_shlibext, libname_spec to acl_libname_spec,
5100         library_names_spec to acl_library_names_spec, hardcode_* to
5101         acl_hardcode_*.
5102         Reported by Ralf Wildenhues.
5103
5104 2007-01-08  Bruno Haible  <bruno@clisp.org>
5105
5106         * m4/gc-arcfour.m4 (gl_GC_ARCFOUR): Remove GC_USE_ARCFOUR macro
5107         definition.
5108         * m4/gc-arctwo.m4 (gl_GC_ARCTWO): Remove GC_USE_ARCTWO macro
5109         definition.
5110         * m4/gc-des.m4 (gl_GC_DES): Remove GC_USE_DES macro definition.
5111         * m4/gc-hmac-md5.m4 (gl_GC_HMAC_MD5): Remove GC_USE_HMAC_MD5 macro
5112         definition.
5113         * m4/gc-hmac-sha1.m4 (gl_GC_HMAC_SHA1): Remove GC_USE_HMAC_SHA1 macro
5114         definition.
5115         * m4/gc-md2.m4 (gl_GC_MD2): Remove GC_USE_MD2 macro definition.
5116         * m4/gc-md4.m4 (gl_GC_MD4): Remove GC_USE_MD4 macro definition.
5117         * m4/gc-md5.m4 (gl_GC_MD5): Remove GC_USE_MD5 macro definition.
5118         * m4/gc-random.m4 (gl_GC_RANDOM): Remove GC_USE_RANDOM macro
5119         definition.
5120         * m4/gc-rijndael.m4 (gl_GC_RIJNDAEL): Remove GC_USE_RIJNDAEL macro
5121         definition.
5122         * m4/gc-sha1.m4 (gl_GC_SHA1): Remove GC_USE_SHA1 macro definition.
5123         * lib/gc-gnulib.c: Use GNULIB_GC_<algorithm> instead of
5124         GC_USE_<algorithm>.
5125         * lib/gc-libgcrypt.c: Likewise.
5126         * modules/gc-arcfour (configure.ac): Use gl_MODULE_INDICATOR.
5127         * modules/gc-arctwo (configure.ac): Likewise.
5128         * modules/gc-des (configure.ac): Likewise.
5129         * modules/gc-hmac-md5 (configure.ac): Likewise.
5130         * modules/gc-hmac-sha1 (configure.ac): Likewise.
5131         * modules/gc-md2 (configure.ac): Likewise.
5132         * modules/gc-md4 (configure.ac): Likewise.
5133         * modules/gc-md5 (configure.ac): Likewise.
5134         * modules/gc-random (configure.ac): Likewise.
5135         * modules/gc-rijndael (configure.ac): Likewise.
5136         * modules/gc-sha1 (configure.ac): Likewise.
5137
5138 2007-01-08  Bruno Haible  <bruno@clisp.org>
5139
5140         * m4/close-stream.m4 (gl_CLOSE_STREAM): Remove GNULIB_CLOSE_STREAM
5141         macro definition.
5142         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Remove GNULIB_FCNTL_SAFER macro
5143         definition.
5144         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Remove GNULIB_FOPEN_SAFER macro
5145         definition.
5146         * modules/close-stream (configure.ac): Invoke gl_MODULE_INDICATOR.
5147         * modules/fcntl-safer (configure.ac): Likewise.
5148         * modules/fopen-safer (configure.ac): Likewise.
5149         * modules/fwriteerror (configure.ac): Likewise. Remove explicit
5150         GNULIB_FWRITEERROR macro definition.
5151
5152 2007-01-08  Bruno Haible  <bruno@clisp.org>
5153
5154         * m4/gnulib-common.m4: New file.
5155         * gnulib-tool (func_get_autoconf_snippet): Undo last change.
5156         (func_get_filelist): Add m4/gnulib-common.m4.
5157
5158 2007-01-08  Bruno Haible  <bruno@clisp.org>
5159
5160         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Simplify the sorting
5161         command.
5162
5163 2007-01-08  Jim Meyering  <jim@meyering.net>
5164
5165         Use a more robust test for a "can't happen" condition.
5166         * lib/fts.c (fts_read): Revert the change of 2006-11-22, since it
5167         narrowed the st_size value.  Presuming the "can't happen" condition
5168         is true, that narrowing could conceivably convert an invalid st_size
5169         value into a valid one.  Instead, use a change based on Matthew
5170         Woehlke's original patch.
5171
5172         Slight readability improvement: use an assert-like macro
5173         in place of literal "abort ()" uses.
5174         * lib/fts.c (fts_assert): Define.
5175         (fts_set_stat_required, cwd_advance_fd, fts_read, fd_ring_check):
5176         Use this macro instead of a bare 'abort'.
5177
5178 2007-01-05  Paul Eggert  <eggert@cs.ucla.edu>
5179
5180         Don't worry about using IRIX 5.3's wctype.h broken definitions;
5181         simply work around them.
5182         * lib/wctype_.h: Remove test for HAVE_WCTYPE_CTMP_BUG.
5183         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph, iswlower):
5184         (iswprint, iswpunct, iswspace, iswupper, iswxdigit): Undef before
5185         declaring.
5186         Don't bother to define as macros, since the standard doesn't require it.
5187         * m4/wctype.m4 (WCTYPE_H, ABSOLUTE_WCTYPE_H): Simplify, since we no
5188         longer worry about IRIX 5.3.
5189         (HAVE_WCTYPE_CTMP_BUG): Remove.
5190
5191 2007-01-04  Paul Eggert  <eggert@cs.ucla.edu>
5192
5193         * lib/wctype_.h (_ctmp_) [HAVE_WCTYPE_CTMP_BUG]: Now of type wchar_t,
5194         not wint_t.  Also, include <ctype.h>, to fix another IRIX bug.
5195         * m4/wctype.m4 (gl_WCTYPE_H): Likewise.
5196         Problems reported by Georg Schwarz for IRIX 5.3.
5197
5198         * gnulib-tool (autoconf_minversion): Take the maximum version number
5199         found, not the minimum.  Problem reported by James Youngman.
5200
5201 2007-01-03  Karl Berry  <karl@gnu.org>
5202
5203         * doc/error.texi: new file, explaining interaction with progname.
5204         * doc/gnulib.texi: include it.  Update copyright.
5205
5206 2007-01-03  Simon Josefsson  <simon@josefsson.org>
5207
5208         * gnulib-tool (func_create_testdir): Run AC_CANONICAL_BUILD and
5209         AC_CANONICAL_HOST, to improve autobuild outputs.
5210
5211 2007-01-03  Paolo Bonzini  <bonzini@gnu.org>
5212             Yoann Vandoorselaere <yoann.v@prelude-ids.com>
5213
5214         * lib/poll.c (poll): Use recv on Mac OS X to distinguish connected
5215         sockets, server sockets, and other file descriptors.  Count errors
5216         to compute the return value.  Reorder the code a bit to be easier
5217         to follow.  Don't set event bits that were not requested (except
5218         POLLERR and POLLHUP).
5219
5220 2007-01-01  Bruno Haible  <bruno@clisp.org>
5221
5222         * modules/lchmod (Include): Require lchmod.h, not lchown.h.
5223
5224 2007-01-03  Jim Meyering  <jim@meyering.net>
5225
5226         * modules/fts-lgpl (Depends-on): Add i-ring.  Reported by Bruno Haible.
5227
5228 2007-01-02  Bruno Haible  <bruno@clisp.org>
5229
5230         * modules/settime (Include): Require timespec.h.
5231         * modules/nanosleep (Include): Likewise.
5232
5233 2007-01-01  Bruno Haible  <bruno@clisp.org>
5234
5235         * gnulib-tool (func_emit_copyright_notice): Bump year.
5236         (func_get_autoconf_snippet): Emit a GNULIB_<modulename> macro.
5237
5238 2007-01-01  Bruno Haible  <bruno@clisp.org>
5239
5240         Improve support for OpenBSD.
5241         * build-aux/config.rpath (libname_spec): Export.
5242         (library_names_spec): New variable. Export.
5243         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Extract libname_spec and
5244         library_names_spec from the config.rpath output. Locate shared library
5245         through the name pattern in library_names_spec.
5246
5247 2007-01-01  Eric Blake  <ebb9@byu.net>
5248
5249         * lib/version-etc.c (COPYRIGHT_YEAR): Bump for new year.
5250
5251 2006-12-30  Paul Eggert  <eggert@cs.ucla.edu>
5252
5253         * gnulib-tool (SORT): Remove, since we no longer assume GNU sort.
5254         Rewrite so as not to assume GNU sort or "tail -1".  Also, don't
5255         assume the C locale, and avoid an "eval" that could cause trouble.
5256         Problem with SORT reported by Bob Proulx.
5257
5258         * lib/getpagesize.h (getpagesize) [defined __amigaos4__]:
5259         Define.  Trivial patch from Henning Nielsen Lund, originally
5260         sent to bug-grep@gnu.org today.
5261
5262 2006-12-29  Paul Eggert  <eggert@cs.ucla.edu>
5263
5264         * lib/acl.h: Include sys/types.h and sys/stat.h, for mode_t and
5265         struct stat.  Problem reported by Henning Nielsen Lund.
5266         * lib/acl.c: Include acl.h first, to check interface.  Don't
5267         bother to include sys/types.h and sys/stat.h again.
5268
5269 2006-12-28  Paul Eggert  <eggert@cs.ucla.edu>
5270
5271         Import the following change from libc; problem reported by
5272         Sven Verdoolaege.
5273
5274         2005-10-13  Ulrich Drepper  <drepper@redhat.com>
5275
5276         [BZ #1373]
5277         * lib/argp.h: Remove __NTH for __argp_usage inline function.
5278
5279 2006-12-28  Jim Meyering  <jim@meyering.net>
5280
5281         * build-aux/announce-gen: Do not assume that the package
5282         builds any of tar.gz, tar.bz2, and .xdelta files.
5283         Suggestion from Simon Josefsson.
5284
5285 2006-12-28  Simon Josefsson  <simon@josefsson.org>
5286
5287         * modules/announce-gen: New file.
5288
5289 2006-12-27  Paul Eggert  <eggert@cs.ucla.edu>
5290
5291         * lib/mbchar.h: Just include <wctype.h>; the wctype module
5292         handles its gotchas now.
5293         * lib/mbswidth.c: Likewise.
5294         * lib/wcwidth.h: Likewise.
5295         * m4/mbchar.m4 (gl_MBCHAR): Don't bother checking for wctype.h
5296         and iswcntrl; the wctype module does this stuff now.
5297         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
5298         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Likewise.
5299         * modules/mbchar (Depends-on): Add wctype.
5300         * modules/mbswidth (Depends-on): Likewise.
5301         * modules/wcwidth (Depends-on): Likewise.
5302
5303 2006-12-27  Eric Blake  <ebb9@byu.net>
5304
5305         * lib/fnmatch.c: Reinstate inclusion of <wchar.h>, since this
5306         module uses more than what <wctype.h> is required to provide.
5307
5308 2006-12-26  Eric Blake  <ebb9@byu.net>
5309
5310         * gnulib-tool (sed_extract_prog): Avoid space-tab.
5311
5312 2006-12-26  Eric Blake  <ebb9@byu.net>
5313
5314         * modules/absolute-header: New module.
5315         * modules/fcntl (Depends-on): Depend on it.
5316         * modules/inttypes (Depends-on): Likewise.
5317         * modules/stdint (Depends-on): Likewise.
5318         * modules/sys_stat (Depends-on): Likewise.
5319         * modules/wctype (Depends-on): Likewise.
5320         * MODULES.html.sh (Support for building libraries and
5321         executables): Document it.
5322
5323 2006-12-25  Paul Eggert  <eggert@cs.ucla.edu>
5324
5325         * gnulib-tool (SED): Remove, undoing previous change.
5326         The problem was that it broke coreutils on Solaris, because
5327         "sed --posix" leaked into a makefile.
5328         (sed): New alias, if 'alias' and GNU sed.
5329
5330 2006-12-24  Jim Meyering  <jim@meyering.net>
5331
5332         Work around an fchownat bug in glibc-2.4:
5333         http://lists.ubuntu.com/archives/ubuntu-users/2006-September/093218.html
5334         This bug would cause "chown -RP ... DIR" to follow symlinks in DIR,
5335         in spite of the -P option.
5336         * m4/openat.m4 (gl_FUNC_FCHOWNAT, gl_FUNC_FCHOWNAT_DEREF_BUG):
5337         New macros.
5338         (gl_PREREQ_OPENAT): Require gl_FUNC_FCHOWNAT.
5339         * modules/openat (Files): Add lib/fchownat.c.
5340         * lib/openat.c (fchownat): Don't define here.  Move to...
5341         * lib/fchownat.c: ...this new file.
5342
5343 2006-12-23  Paul Eggert  <eggert@cs.ucla.edu>
5344
5345         Fix bug reported by Bruno Haible in
5346         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00228.html>
5347         where quotearg.c didn't compile on Mac OS X 10.2 because it
5348         lacks <wchar.h> and wint_t.
5349         * lib/wctype_.h (__wctype_wint_t): New type.
5350         Include <stdio.h>, <time.h>, <wchar.h> only if HAVE_WINT_T.
5351         (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit, iswgraph):
5352         (iswlower, iswprint, iswpunct, iswspace, iswupper, ixwxdigit):
5353         Arg is now of type __wctype_wint_t, not wint_t.
5354         * m4/wctype.m4 (gl_WCTYPE_H): Require gt_TYPE_WINT_T, and
5355         substitute HAVE_WINT_T.
5356         * modules/wctype (Files): Add m4/wint_t.m4.
5357         (wctype.h): Substitute HAVE_WINT_T.
5358
5359 2006-12-23  Bruno Haible  <bruno@clisp.org>
5360
5361         * lib/safe-read.h [C++]: Wrap declarations in extern "C".
5362
5363 2006-12-23  Bruno Haible  <bruno@clisp.org>
5364
5365         * lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
5366         S_ISLNK.
5367         Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
5368         mingw.
5369
5370 2006-12-22  Bruno Haible  <bruno@clisp.org>
5371
5372         * lib/copy-file.c: Include acl.h.
5373         (copy_file_preserving) [USE_ACL]: Use copy_acl instead of chmod.
5374         Close the file descriptors only after being done with copy_acl.
5375         * modules/copy-file (Depends-on): Add acl.
5376
5377 2006-12-22  Bruno Haible  <bruno@clisp.org>
5378
5379         * gnulib-tool (SED): New variable.
5380         Use $SED instead of sed everywhere.
5381
5382 2006-12-22  Bruno Haible  <bruno@clisp.org>
5383
5384         * modules/no-c++: New file.
5385         * m4/no-c++.m4: New file.
5386         * MODULES.html.sh (Support for building libraries and executables):
5387         Add no-c++.
5388
5389 2006-12-22  Paul Eggert  <eggert@cs.ucla.edu>
5390
5391         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
5392         Include <limits.h>, and use its INT_MAX to rewrite the
5393         j loop so that it does not overflow 'int'.  Problem reported by
5394         Ralf Wildenhues in
5395         <http://lists.gnu.org/archive/html/bug-gnulib/2006-12/msg00084.html>.
5396         Play it safe by shifting left by 1 rather than multiplying by 2,
5397         as GCC is less likely to optimize this away when the value
5398         is signed (when it assumes overflow leads to undefined behavior).
5399         Also, don't assume time_t uses two's complement.
5400
5401 2006-12-21  Paul Eggert  <eggert@cs.ucla.edu>
5402
5403         * MODULES.html.sh: New module wctype.
5404         * lib/wctype_.h, m4/wctype.m4, modules/wctype: New files.
5405         * lib/fnmatch.c: Don't bother to include <wchar.h> before
5406         <wctype.h>, since the new wctype module should fix this.
5407         * lib/quotearg.c: Include <wctype.h> unconditionally, since
5408         the wctype module should arrange for it.
5409         * lib/regex_internal.h: Likewise.
5410         * m4/quotearg.m4 (gl_QUOTEARG): Don't check for wctype.h or iswprint,
5411         since the wctype module should handle this now.
5412         * m4/regex.m4 (gl_PREREQ_REGEX): Don't check for wctype.h.
5413         * modules/fnmatch (Depends-on): Add wctype.
5414         * modules/quotearg (Depends-on): Likewise.
5415         * modules/regex (Depends-on): Likewise.
5416
5417 2006-12-19  Bruno Haible  <bruno@clisp.org>
5418
5419         * lib/strdup.h [C++]: Wrap definitions in extern "C".
5420         Suggested by Lorenzo Bettini <bettini@dsi.unifi.it>.
5421
5422 2006-12-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5423
5424         * modules/savewd (Depends-on): Fix dependency on fcntl.
5425
5426 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
5427
5428         * m4/stdint.m4 (gl_STDINT_H): Set STDINT_H to empty if stdint.h
5429         conforms to C99, rather than relying on the user's environment
5430         setting of STDINT_H.
5431
5432 2006-12-18  Paul Eggert  <eggert@cs.ucla.edu>
5433         and Eric Blake  <ebb9@byu.net>
5434
5435         * lib/dirname.h (DOUBLE_SLASH_IS_DISTINCT_ROOT): Default to 0, not 1.
5436         This is more consistent with the other defines here.
5437         * m4/double-slash-root.m4 (gl_DOUBLE_SLASH_ROOT):
5438         Port to z/OS.  Problem reported by Paul Gilmartin.
5439         Change local vars to use gl_ prefix rather than ac_.
5440         Don't define DOUBLE_SLASH_IS_DISTINCT_ROOT to 0, for consistency
5441         with other defines.
5442         * modules/double-slash-root: New module.
5443         * modules/dirname (Files): Remove m4/double-slash-root.m4.
5444         (Depends-on): Add double-slash-root.
5445         * MODULES.html.sh (File system functions): Mention new module.
5446
5447 2006-12-14  Paul Eggert  <eggert@cs.ucla.edu>
5448
5449         * lib/yesno.c [!ENABLE_NLS]: Don't include getline.h.
5450         (yesno) [!ENABLE_NLS]: Don't invoke getline or rpmatch.
5451         This is for the benefit of gzip, which doesn't do i18n.
5452
5453 2006-12-12  Jim Meyering  <jim@meyering.net>
5454
5455         * m4/acl.m4 (gl_ACL_GET_FILE): Fix logic error.
5456         Reported by Andreas Schwab <schwab@suse.de>.
5457
5458 2006-12-12  Bruno Haible  <bruno@clisp.org>
5459
5460         Merge these changes.
5461         2006-09-05  Bruno Haible  <bruno@clisp.org>
5462         * lib/iconvme.c (iconv_string): No need to save and restore errno when
5463         iconv_alloc succeeded.
5464         (iconv_alloc): Don't assume that malloc() or realloc(), when failing,
5465         sets errno to ENOMEM. (malloc on GNU/kFreeBSD doesn't.) No need to
5466         test for " && dest " at the end - dest is always != NULL there. Call
5467         iconv with 4xNULL arguments initially, to reset the state. Call iconv
5468         with 2xNULL arguments, also to flush the state storage. Handle the
5469         IRIX iconv behaviour. Realloc the final result, to throw away unused
5470         memory.
5471
5472 2006-12-11  Paul Eggert  <eggert@cs.ucla.edu>
5473
5474         * m4/openat.m4 (gl_FUNC_OPENAT): Don't compile mkdirat
5475         and fchmodat unconditionally, since glibc 2.4 has them.
5476         Problem reported by Arkadiusz Miskiewicz.
5477
5478 2006-12-10  Bruno Haible  <bruno@clisp.org>
5479
5480         * gnulib-tool (func_import): Show the include files only for those
5481         modules that are copied and specified.
5482         Reported by Karl Berry.
5483
5484 2006-12-08  Jim Meyering  <jim@meyering.net>
5485
5486         * build-aux/announce-gen ($VERSION): Don't use of $Revision...$.
5487         Instead, use Emacs' time-stamp write hook.  Note that the time is UTC.
5488
5489         * build-aux/announce-gen: Add two new options, both optional:
5490         --bootstrap-tools=TOOL_LIST
5491               a comma-separated list of tools, e.g.,
5492               autoconf,automake,bison,gnulib
5493         --gnulib-snapshot-date=DATE
5494               if gnulib is in the bootstrap tool list,
5495               then report this as the snapshot date.
5496               If not specified, use the current date/time.
5497               If you specify a date here, be sure it's UTC.
5498
5499 2006-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5500
5501         * tests/test-argp-2.sh: Fix test to match actual output.
5502         (func_compare): Fix sed script to be portable.
5503
5504 2006-12-05  Paul Eggert  <eggert@cs.ucla.edu>
5505
5506         * lib/utimens.c (futimens) [HAVE_BUGGY_NFS_TIME_STAMPS]: Add a
5507         workaround for this case.  It is not autoconfigured now; offhand
5508         it's hard to see how to autoconfigure it.
5509
5510 2006-12-03  Paul Eggert  <eggert@cs.ucla.edu>
5511
5512         * lib/mkdir-p.c (make_dir_parents): Fix race condition when making
5513         a directory that is about to be chowned.  Such a directory's
5514         initial file permissions should permit the owner only and this
5515         should not be changed until after the chown, since the group and
5516         other bits would be incorrect if they granted permission before
5517         the chown.
5518
5519         Fix porting problem for iswctype reported by Georg Schwarz in:
5520         http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00017.html
5521         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Require HAVE_ISWCTYPE, too.
5522         * lib/regex_internal.h (RE_ENABLE_I18N): Likewise.
5523         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for iswctype, too.
5524         * m4/regex.m4 (gl_PREREQ_REGEX): Likewise.
5525
5526 2006-12-03  Jim Meyering  <jim@meyering.net>
5527
5528         * lib/fts.c (fts_load): Don't set sp->fts_dev here, since
5529         p->fts_statp may not yet be defined.
5530         (fts_read): Instead, set it in the caller, once p->fts_statp is
5531         sure to be defined, and corresponds to a top-level directory.
5532         This bug made du -x fail.  Here's the coreutils test case:
5533         http://git.sv.gnu.org/gitweb/?p=coreutils.git;a=commit;h=ba45154d8e9f
5534         Reported by Mike Frysinger.
5535
5536 2006-12-01  Jim Meyering  <jim@meyering.net>
5537
5538         * modules/savewd (Depends-on): Add fcntl_h to avoid self-test
5539         build failure due to missing definition of HAVE_WORKING_O_NOFOLLOW.
5540         Reported by Simon Josefsson.
5541
5542 2006-11-30  Jim Meyering  <jim@meyering.net>
5543
5544         * m4/warning.m4: Use the all-permissive copyright notice
5545         recommended by RMS (rather than LGPL).
5546         * m4/vararrays.m4: Likewise.
5547         * m4/flexmember.m4: Likewise.
5548
5549 2006-11-29  Bruno Haible  <bruno@clisp.org>
5550
5551         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
5552         noinst_LIBRARIES. Augment noinst_LIBRARIES and noinst_LTLIBRARIES
5553         using +=.
5554         Reported by Simon Josefsson <simon@josefsson.org>.
5555
5556 2006-11-28  James Youngman <jay@gnu.org>
5557
5558         * README: Advise users that they might find the bug-gnulib@gnu.org
5559         and autotools-announce@gnu.org mailing lists useful.
5560
5561 2006-11-28  Bruno Haible  <bruno@clisp.org>
5562
5563         * m4/ptrdiff_max.m4: Remove file.
5564
5565 2006-11-21  Bruno Haible  <bruno@clisp.org>
5566
5567         * m4/eoverflow.m4 (gl_EOVERFLOW): Use AC_COMPUTE_INT instead of
5568         _AC_COMPUTE_INT.
5569         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5570         * m4/ptrdiff_max.m4 (gl_PTRDIFF_MAX): Use AC_COMPUTE_INT instead of
5571         _AC_COMPUTE_INT.
5572         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5573         * m4/size_max.m4 (gl_SIZE_MAX): Use AC_COMPUTE_INT instead of
5574         _AC_COMPUTE_INT.
5575         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5576
5577 2006-11-28  Jim Meyering  <jim@meyering.net>
5578
5579         * lib/regcomp.c (parse_branch): Rename local, exp->expr, to avoid
5580         warning from "gcc -Wshadow" about shadowing the builtin.
5581
5582 2006-11-27  Bruno Haible  <bruno@clisp.org>
5583
5584         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): Use AC_COMPUTE_INT instead of
5585         _AC_COMPUTE_INT.
5586         (AC_COMPUTE_INT): Add fallback definition for autoconf < 2.61.
5587
5588 2006-11-27  Bruno Haible  <bruno@clisp.org>
5589             Paul Eggert  <eggert@cs.ucla.edu>
5590
5591         * lib/regex.h (__restrict_arr): Redo logic of #if, for clarity.
5592
5593 2006-11-26  Bruno Haible  <bruno@clisp.org>
5594
5595         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
5596         noinst_LTLIBRARIES.
5597
5598 2006-11-27  Paul Eggert  <eggert@cs.ucla.edu>
5599             Bruno Haible  <bruno@clisp.org>
5600
5601         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to 0
5602         if compiling with "gcc -ansi".
5603
5604 2006-11-26  Paul Eggert  <eggert@cs.ucla.edu>
5605
5606         Fix some incompatibilities with gcc -ansi -pedantic.
5607         * lib/regex.h (__restrict_arr): Don't use the [restrict] syntax
5608         if compiling pedantically with GCC, unless it's C99 or later.
5609         Don't trust sys/cdefs.h's definition of __restrict_arr, either, as
5610         it mishandles gcc -ansi -pedantic as well.
5611         * lib/regex_internal.h (re_token_t): Don't use enum bitfields
5612         if gcc -pedantic.
5613         * lib/regexec.c (check_node_accept_bytes): Don't use auto
5614         initializers for struct if -pedantic, unless it's C99 or later.
5615
5616 2006-11-25  Nix  <nix@esperi.org.uk>  (tiny change)
5617
5618         * m4/fcntl_h.m4 (gl_FCNTL_H): Test the atime, not the mtime.
5619         Don't close an fd more than once. Identical atimes indicate
5620         success, not failure.
5621
5622 2006-11-22  Robinson Mittmann <bob@hoplon.com>  (tiny change)
5623
5624         * lib/sincosl.c (kernel_sinl): Fix typo in threshold.
5625
5626 2006-11-23  Jim Meyering  <jim@meyering.net>
5627
5628         * build-aux/announce-gen: New file.  From coreutils.
5629
5630 2006-11-22  Jim Meyering  <jim@meyering.net>
5631
5632         Work around a compile-time error from the HP-UX 11.00 /bin/cc.
5633         * lib/fts.c (enum Fts_stat): Give this previously-anon enum a name.
5634         (fts_read): Use a temporary to narrow the overused st_size member
5635         before using it in a switch statement.  Reported by Matthew Woehlke.
5636
5637         * m4/clock_time.m4 (gl_CLOCK_TIME): Quote AC_SUBST argument.
5638         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Likewise.
5639
5640 2006-11-20  Bruno Haible  <bruno@clisp.org>
5641
5642         * gettext.m4 (AM_GNU_GETTEXT): Revert 2005-07-28 patch: Use
5643         changequote instead of pairs of brackets.
5644         Reported by Andreas Schwab <schwab@suse.de>.
5645
5646 2006-11-21  Jim Meyering  <jim@meyering.net>
5647
5648         * lib/fts.c (fts_safe_changedir): Move a declaration "up",
5649         so as to remain compatible with older compilers.
5650         Patch from Michael Deutschmann.
5651
5652 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
5653
5654         * MODULES.html.sh (File system functions): Add openat.
5655
5656         * lib/openat.h (rpl_fstatat): New macro, if
5657         [HAVE_OPENAT && ! LSTAT_FOLLOWS_SLASHED_SYMLINK.
5658         (fstatat): Define to rpl_fstatat under the same conditions,
5659         unless COMPILING_FSTATAT.
5660         * m4/openat.m4 (gl_FUNC_OPENAT): Compile fstatat.c too, if fstatat
5661         seems to have the bug.
5662         * lib/fstatat.c: New file.
5663         * modules/openat (Files): Add it.
5664
5665 2006-11-20  Bruno Haible  <bruno@clisp.org>
5666
5667         * Makefile: New file.
5668
5669 2006-11-20  Jim Meyering  <jim@meyering.net>
5670
5671         The beginnings of syntax-related checks for gnulib.
5672         * lib/Makefile: New file.
5673         * lib/t-idcache: New script.  Ensure that the two halves of
5674         idcache.c stay in sync.
5675
5676         * lib/idcache.c: Adjust comments in user- and group- portions to
5677         be more accurate, and to be consistent with one another.
5678
5679 2006-11-20  Jim Meyering  <jim@meyering.net>
5680
5681         * lib/idcache.c: Restore most of the 2006-11-06 patch, so as to
5682         continue using the flexible array member (thus, this module performs
5683         half as many malloc calls), with the addition that...
5684         (getgroup, getuser): Consistently record a non-match via an empty
5685         "name" string, and map an empty string match to a NULL return value.
5686         * modules/idcache (Depends-on): Re-add flexmember.
5687
5688         * lib/idcache.c (getuser): Remove all uses of the register keyword.
5689         (getuidbyname, getgroup, getgidbyname): Likewise.
5690
5691         Use cleaner syntax: NULL rather than 0.
5692         * lib/idcache.c (getuidbyname, getgidbyname): Return NULL, not 0.
5693
5694 2006-11-20  Paul Eggert  <eggert@cs.ucla.edu>
5695
5696         * lib/idcache.c: Undo most recent patch, dated 2006-11-06.
5697         It mishandled the case where the group was missing.
5698         Problem reported by Greg Schafer.
5699         * modules/idcache: Likewise.
5700
5701 2006-11-18  Jim Meyering  <jim@meyering.net>
5702
5703         * check-module (%exempt_header): Add exception for some
5704         conditionally-included headers.
5705
5706         * modules/i-ring (Depends-on): Add verify.
5707         (License): Change to LGPL.
5708
5709 2006-11-16  Paul Eggert  <eggert@cs.ucla.edu>
5710
5711         * modules/getaddinfo (Depends-on): Remove inttostr; add snprintf.
5712         * lib/getaddrinfo.c: Include snprintf.h rather than intprops.h
5713         and inttostr.h.  Use snprintf rather than uinttostr, so that
5714         LGPLed code doesn't depend on GPLed.
5715
5716 2006-11-17  Paul Eggert  <eggert@cs.ucla.edu>
5717
5718         * modules/inline (License): Change from GPL to LGPL.
5719
5720 2006-11-17  Jim Meyering  <jim@meyering.net>
5721
5722         * modules/d-type (License): Switch to LGPL.
5723
5724 2006-11-15  Bruno Haible  <bruno@clisp.org>
5725
5726         * m4/alloca.m4 (gl_FUNC_ALLOCA): Fix the AC_CACHE_CHECK message.
5727
5728 2006-11-15  Eric Blake  <ebb9@byu.net>
5729
5730         * m4/allocsa.m4 (gl_ALLOCSA): Don't invoke macro already picked up by
5731         the module dependency.
5732
5733 2006-11-15  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
5734             Bruno Haible  <bruno@clisp.org>
5735
5736         * gnulib-tool (func_create_testdir): Add license consistency check.
5737
5738 2006-11-15  Eric Blake  <ebb9@byu.net>
5739
5740         * m4/alloca.m4 (gl_FUNC_ALLOCA): Use AC_CACHE_CHECK to avoid a
5741         random "(cached)" in configure output.
5742
5743 2006-11-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5744
5745         * m4/inttypes.m4 (gl_INTTYPES_H): Use AC_CACHE_CHECK so that the
5746         test for conforming inttypes.h is both announced and cached.
5747
5748         * MODULES.html.sh (seen_modules, seen_files): New variables.
5749         (func_module): Rewrite to use a few less gnulib-tool and sed
5750         invocations.  Avoid a couple of quadratic algorithms for ...
5751         (missed_modules, missed_files): ... these, with ...
5752         (func_append, func_tmpdir): ... these new functions, from
5753         gnulib-tool.  Analogously, install traps for cleanup.
5754
5755         * tests/test-gc.c (main): Remove unused variables.
5756         * tests/test-read-file.c: Include stdlib.h, for 'free'.
5757
5758 2006-11-14  Paul Eggert  <eggert@cs.ucla.edu>
5759
5760         * modules/inttostr (License): Change to LGPL.
5761
5762 2006-11-14  Eric Blake  <ebb9@byu.net>
5763
5764         * modules/tempname (License): Change to LGPL.
5765
5766 2006-11-14  Eric Blake  <ebb9@byu.net>
5767
5768         * doc/functions.texi (Function Portability): *printf functions on
5769         Cygwin now understand all POSIX size specifiers.
5770
5771 2006-11-14  Bruno Haible  <bruno@clisp.org>
5772
5773         * modules/c-ctype (License): Change to LGPL.
5774
5775 2006-11-12  Bruno Haible  <bruno@clisp.org>
5776
5777         * m4/lib-link.m4 (AC_LIB_LINKFLAGS, AC_LIB_HAVE_LINKFLAGS,
5778         AC_LIB_LINKFLAGS_BODY): Also set a LIB${NAME}_PREFIX variable. Needed
5779         for GNOME libraries, for which the include files are installed in
5780         subdirectories of $prefix/include.
5781
5782 2006-11-12  Bruno Haible  <bruno@clisp.org>
5783
5784         * m4/lib-link.m4: Require at least autoconf-2.54.
5785         (AC_LIB_LINKFLAGS_BODY) [autoconf < 2.61]: Turn dots into the library
5786         name to underscores for the --with option.
5787
5788 2006-11-13  Bruno Haible  <bruno@clisp.org>
5789
5790         * gnulib-tool (func_create_testdir): Set gl_source_base correctly in
5791         the tests directory.
5792         Reported by Ralf Wildenhues.
5793
5794 2006-11-13  Bruno Haible  <bruno@clisp.org>
5795
5796         * gnulib-tool (func_emit_initmacro_start): Also override AC_LIBSOURCES.
5797         (func_emit_initmacro_end): Undo the override here.
5798         (func_emit_initmacro_done): Emit a definition for gl_LIBSOURCES.
5799         Works around the famous automake error in coreutils.
5800
5801 2006-11-13  Eric Blake  <ebb9@byu.net>
5802
5803         * lib/gl_anytree_oset.h (gl_tree_search_atleast): Return the
5804         element, not its node.
5805
5806 2006-11-12  Bruno Haible  <bruno@clisp.org>
5807
5808         * gnulib-tool (func_emit_lib_Makefile_am): Replace occurrences of
5809         '$(top_srcdir)/build-aux/', taking into account the real auxdir.
5810
5811 2006-11-12  Bruno Haible  <bruno@clisp.org>
5812
5813         * gnulib-tool: New option --local-symlink.
5814         (func_usage): Document it.
5815         (lsymbolic): New variable.
5816         (func_import, func_create_testdir): If --symlink was not specified,
5817         test whether --local-symlink was specified and the file comes from
5818         the local_gnulib_dir.
5819
5820 2006-11-12  Bruno Haible  <bruno@clisp.org>
5821
5822         * gnulib-tool (func_ln): New function.
5823         (func_ln_if_changed, func_create_testdir): Use it instead of "ln -s".
5824
5825 2006-11-12  Bruno Haible  <bruno@clisp.org>
5826
5827         Finish support for source files in subdirectories.
5828         * gnulib-tool (func_emit_lib_Makefile_am): If some of the source files
5829         are in subdirectories, set uses_subdirs and add 'subdir-objects' to
5830         AUTOMAKE_OPTIONS.
5831         (func_import, func_create_testdir): Invoke AM_PROG_CC_C_O in this case.
5832
5833 2006-11-12  Bruno Haible  <bruno@clisp.org>
5834
5835         * gnulib-tool (func_get_automake_snippet): Synthesize also an
5836         EXTRA_lib_SOURCES augmentation.
5837         (func_emit_lib_Makefile_am): Initialize EXTRA_lib..._SOURCES to empty.
5838
5839 2006-11-12  Jim Meyering  <jim@meyering.net>
5840
5841         Make fts (in FTS_CWDFD mode) more efficient by caching a few open
5842         file descriptors.  This also averts a failure on systems with
5843         native openat support when a traversed directory lacks "x" access.
5844         * lib/fts_.h: Include "i-ring.h"
5845         (struct FTS) [fts_fd_ring]: New member.
5846         * lib/fts.c (RESTORE_INITIAL_CWD): Also call fd_ring_clear.
5847         (FCHDIR): Add parentheses.
5848         (fd_ring_check, fd_ring_print) [!FTS_DEBUG]: Define away.
5849         (cwd_advance_fd): Add a 3rd parameter.  Adjust all callers.
5850         When descending, rather than simply closing the previous
5851         fts_cwd_fd value, push that file descriptor onto the ring.
5852         (same_fd, fd_ring_print, fd_ring_check) [FTS_DEBUG]: New functions.
5853         (fts_open): Initialize the new fd_ring member.
5854         (fts_close): Clear the ring.
5855         (fts_safe_changedir): When possible, use our new fd_ring to skip
5856         the diropen and fstat and dev/ino comparison that would normally
5857         accompany a virtual `chdir ("..")'.
5858
5859         * modules/fts (Depends-on): Add i-ring.
5860         * modules/i-ring: New module.
5861         * lib/i-ring.c, lib/i-ring.h, lib/i-ring-test.c: New files.
5862         * m4/i-ring.m4: New file.
5863
5864 2006-11-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5865
5866         * gnulib-tool (func_create_testdir): Fix replacement of
5867         `build-aux' in configure.ac.  Run autotools in gltests
5868         subdirectory.
5869         (func_create_testdir, func_create_megatestdir, test): There is
5870         no need for '--force' in most autotool invocations in a new
5871         tree.  Actually fail the whole test if any of the tools, or the
5872         configure or make stages fail.
5873
5874         Sync from Automake.
5875         * build-aux/gnupload: Revert last change.  Add pointer to upload
5876         instructions of the GNU Maintenance Instructions.
5877         Suggestion by Karl Berry.
5878
5879 2006-11-10  Jim Meyering  <jim@meyering.net>
5880
5881         * lib/fts.c [FTS_DEBUG]: Don't try to print a pointer via %s.
5882
5883 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5884
5885         * lib/gettext.h (dgettext, dcgettext, ngettext) [! ENABLE_NLS]:
5886         (dngettext, dcngettext, bindtextdomain) [! ENABLE_NLS]:
5887         (bind_textdomain_codeset) [! ENABLE_NLS]:
5888         Evaluate all the arguments.  That way, callers get compatible behavior
5889         if the arguments have side effects.  Also, it avoids some GCC
5890         diagnostics in some cases; Joel E. Denny reported problems when Bison
5891         was configured with --enable-gcc-warnigs.
5892
5893 2006-11-10  Jim Meyering  <jim@meyering.net>
5894
5895         * m4/inline.m4 (gl_INLINE): Check with the compiler, not cpp, so that
5896         relevant options in CFLAGS (like -O, -fno-inline) are taken into
5897         account.
5898
5899 2006-11-10  Jim Meyering  <jim@meyering.net>
5900
5901         * modules/inline: New file/module.
5902         * modules/xalloc (Files): Remove m4/inline.m4.
5903         (Depends-on): Add inline, instead.
5904         * modules/oset: Likewise.
5905         * modules/list: Likewise.
5906
5907 2006-11-09  Paul Eggert  <eggert@cs.ucla.edu>
5908
5909         * lib/stdint_.h (uintmax_t): Fix typo: int64_t -> uint64_t.
5910         Problem reported by Matthew Woehlke.
5911
5912 2006-11-09  Bruno Haible  <bruno@clisp.org>
5913
5914         * lib/tempname.c (gen_tempname): Remove variant that invokes
5915         __gen_tempname.
5916         * m4/tempname.m4 (gl_FUNC_GEN_TEMPNAME): Don't test for
5917         __gen_tempname.
5918
5919 2006-11-08  Bruno Haible  <bruno@clisp.org>
5920
5921         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Set ac_cv_type_long_long_int
5922         to 'yes' instead of 'cross-compiling'.
5923
5924 2006-11-08  Paul Eggert  <eggert@cs.ucla.edu>
5925
5926         * lib/quotearg.h (quotearg_free): New decl.
5927         * lib/quotearg.c (quotearg_free): New function.
5928         (slot0, nslots, slotvec0, slotvec):
5929         Now file-scope so that quotearg_free can get at them.
5930
5931 2006-11-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5932
5933         Sync from Automake.
5934         * build-aux/gnupload: Add missing 'gnu' to example URL.
5935         Report by Karl Berry.
5936
5937 2006-11-08  Bruno Haible  <bruno@clisp.org>
5938
5939         * m4/inline.m4 (gl_INLINE): Also test __NO_INLINE__.
5940         Suggested by Paul Eggert.
5941
5942 2006-11-08  Jim Meyering  <jim@meyering.net>
5943
5944         * lib/fts.c [!_LGPL_PACKAGE]: Don't include fcntl--.h twice.
5945         It's already included if !_LIBC.
5946         (fts_safe_changedir): Add a comment.
5947
5948 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5949
5950         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Detect bug in
5951         Tandem NonStop Kernel (OSS) cc -O circa 2004, reported by
5952         Matthew Woehlke.
5953
5954         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Move
5955         definitions up, to avoid colliding with change below.
5956         (static_inline) [HAVE_INLINE]: New macro.
5957         (xnmalloc, xnrealloc, x2nrealloc, xcharalloc):
5958         Provide extern decls when !HAVE_INLINE.  Do not define unless
5959         static_inline is defined, either by us or by xmalloc.c.  Use
5960         static_inline rather than static inline.
5961         (XCALLOC): Optimize sizeof(T) = 1 case.
5962         * lib/xmalloc.c (static_inline) [!HAVE_INLINE]: New macro.
5963
5964 2006-11-07  Bruno Haible  <bruno@clisp.org>
5965
5966         * lib/xalloc.h (XNMALLOC): Restore optimization of sizeof(T) = 1 case.
5967         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require gl_INLINE instead of
5968         AC_C_INLINE.
5969         * modules/xalloc (Files): Add m4/inline.m4.
5970
5971 2006-11-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
5972
5973         * README: Fix typo.
5974         * doc/gnulib.texi (Miscellaneous Notes): Likewise, rename...
5975         (Miscellanous Notes): ...from this.
5976
5977 2006-11-07  Paul Eggert  <eggert@cs.ucla.edu>
5978
5979         * m4/flexmember.m4 (AC_C_FLEXIBLE_ARRAY_MEMBER):
5980         Mention that offsetof should be used instead of sizeof.
5981         From Bruno Haible.
5982
5983 2006-11-07  Bruno Haible  <bruno@clisp.org>
5984
5985         * lib/w32spawn.h (prepare_spawn): Use XNMALLOC instead of xmalloc.
5986
5987 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
5988
5989         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
5990         * lib/gl_anyavltree_list2.h (create_subtree_with_contents):
5991         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
5992         (gl_tree_add_before, gl_tree_add_after):
5993         Use XMALLOC instead of xmalloc, and XCALLOC instead of xzalloc.
5994         * lib/gl_anyhash_list2.h (hash_resize): Likewise.
5995         * lib/gl_anylinked_list2.h (gl_linked_create_empty, gl_linked_create):
5996         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before):
5997         (gl_linked_add_after, gl_linked_add_at): Likewise.
5998         * lib/gl_anyrbtree_list2.h (create_subtree_with_contents):
5999         (gl_tree_create, gl_tree_add_first, gl_tree_add_last):
6000         (gl_tree_add_before, gl_tree_add_after): Likewise.
6001         * lib/gl_anytree_list2.h (gl_tree_create_empty): Likewise.
6002         * lib/gl_anytree_oset.h (gl_tree_create_empty): Likewise.
6003         * lib/gl_anytreehash_list1.h (add_to_bucket): Likewise.
6004
6005 2006-11-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6006
6007         * lib/gl_oset.h: Use C comment style, not C++ comment style.
6008
6009 2006-11-06  Bruno Haible  <bruno@clisp.org>
6010
6011         * m4/inline.m4: New file.
6012         * m4/gl_list.m4 (gl_LIST): Require gl_INLINE.
6013         * modules/list (Files): Add m4/inline.m4.
6014         * modules/oset (Files): Likewise.
6015
6016 2006-11-06  Paul Eggert  <eggert@cs.ucla.edu>
6017
6018         * lib/idcache.c: Include <stddef.h>, for offsetof.
6019         (struct userid.name): Change from char * to a flexible array member.
6020         All uses changed.
6021         * modules/idcache (Depends-on): Add flexmember.
6022
6023         * MODULES.html.sh (Core language properties): New module flexmember.
6024         * modules/flexmember, m4/flexmember.m4: New files.
6025
6026         * lib/xalloc.h (xnmalloc, xnrealloc, x2nrealloc): Now static
6027         inline functions that are identical with the old xnmalloc_inline,
6028         xnrealloc_inline, x2nrealloc_inline of lib/xmalloc.c.  This is so
6029         that we can avoid some unnecessary integer multiplications and
6030         divisions in the common case where the element size is known at
6031         compile time.
6032         (XNMALLOC) [HAVE_INLINE]: Remove special case, which is no longer
6033         needed.
6034         (xnboundedmalloc): Remove.
6035         (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): Use lower-case letters for
6036         arguments, for consistency with rest of this header.
6037         (xcharalloc): Rewrite using XNMALLOC.
6038         * lib/xmalloc.c (xnmalloc_inline, xnmalloc, xnrealloc_inline):
6039         (xnrealloc, x2nrealloc_inline, x2nrealloc): Remove.  The *_inline
6040         versions have been moved to lib/xalloc.h and renamed to be the
6041         non-*_inline versions.
6042         (xmalloc, xrealloc): Implement without reference to the xnmalloc
6043         and xnrealloc functions, since those functions are now inline and
6044         now call us.
6045         (x2realloc): Invoke x2realloc, not x2realloc_inline, to accommodate
6046         renaming described above.
6047         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Remove AC_C_INLINE since
6048         xmalloc.c no longer uses inline directly.  gl_PREREQ_XALLOC now
6049         captures the dependency in AC_C_INLINE.
6050
6051         New module canonicalize-lgpl, proposed by Charles Wilson in
6052         <http://lists.gnu.org/archive/html/bug-gnulib/2006-11/msg00020.html>
6053         with a few small changes afterwards.
6054         * MODULES.html.sh (File system functions): New module
6055         canonicalize-lgpl.
6056         * lib/canonicalize.h: Add comments for canonicalize_filename_mode
6057         and canonicalize_file_name.
6058         * lib/canonicalize-lgpl.c, m4/canonicalize-lgpl.m4:
6059         * modules/canonicalize-lgpl: New files.
6060
6061 2006-11-05  Bruno Haible  <bruno@clisp.org>
6062
6063         * gnulib-tool (func_import, func_create_testdir): Create directories
6064         also for files in subdirectories of lib/.
6065
6066 2006-11-05  Bruno Haible  <bruno@clisp.org>
6067
6068         * lib/gl_array_list.c (gl_array_iterator_next): Make pointer decrement
6069         ANSI C compliant.
6070
6071 2006-11-03  Bruno Haible  <bruno@clisp.org>
6072
6073         Simplify xmalloc expressions. Add overflow check in xmalloc arguments.
6074         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Require AC_C_INLINE.
6075         * lib/xalloc.h (XMALLOC, XNMALLOC, XZALLOC, XCALLOC): New macros.
6076         (xnboundedmalloc): New inline function.
6077         * lib/classpath.c (new_classpath): Use XNMALLOC instead of xmalloc.
6078         * lib/clean-temp.c (create_temp_dir): Use XNMALLOC, XMALLOC instead of
6079         xmalloc.
6080         * lib/concatpath.c (concatenated_pathname): Use XNMALLOC instead of
6081         xmalloc.
6082         * lib/fatal-signal.c (at_fatal_signal): Use XNMALLOC instead of xmalloc.
6083         * lib/findprog.c (find_in_path): Use XNMALLOC instead of xmalloc.
6084         * lib/gl_array_list.c (gl_array_create_empty): Use XMALLOC instead of
6085         xmalloc.
6086         (gl_array_create): Use XNMALLOC, XMALLOC instead of xmalloc.
6087         * lib/gl_array_oset.c (gl_array_create_empty): Use XNMALLOC instead of
6088         xmalloc.
6089         * lib/gl_avltree_oset.c (gl_tree_add_first, gl_tree_add_before,
6090         gl_tree_add_after): Use XMALLOC instead of xmalloc.
6091         * lib/gl_carray_list.c (gl_carray_create_empty): Use XMALLOC instead of
6092         xmalloc.
6093         (gl_carray_create): Use XNMALLOC, XMALLOC instead of xmalloc.
6094         * lib/gl_rbtree_oset.c (gl_tree_add_first, gl_tree_add_before,
6095         gl_tree_add_after): Use XMALLOC instead of xmalloc.
6096         * lib/gl_sublist.c (gl_sublist_create): Use XMALLOC instead of xmalloc.
6097         * lib/pagealign_alloc.c (new_memnode): Use XMALLOC instead of xmalloc.
6098         * lib/sh-quote.c (shell_quote_argv): Use XNMALLOC instead of xmalloc.
6099         * lib/xvasprintf.c (xstrcat): Use XNMALLOC instead of xmalloc.
6100
6101 2006-11-03  Bruno Haible  <bruno@clisp.org>
6102
6103         * lib/c-ctype.h [C++]: Define functions without name mangling.
6104         * lib/fwriteerror.h [C++]: Likewise.
6105         * lib/gcd.h [C++]: Likewise.
6106         * lib/linebreak.h [C++]: Likewise.
6107
6108 2006-11-03  Paul Eggert  <eggert@cs.ucla.edu>
6109
6110         * lib/canonicalize.h: (canonicalize_mode_t, CAN_EXISTING):
6111         (CAN_ALL_BUT_LAST, CAN_MISSING, canonicalize_filename_mode):
6112         Define only if PROVIDE_CANONICALIZE_FILENAME_MODE is defined.
6113         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
6114         Check for functions and headers just once.
6115         Check for declaration of canonicalize_file_name.
6116         Define PROVIDE_CANONICALIZE_FILENAME_MODE.
6117
6118 2006-11-02  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6119
6120         * gnulib-tool (func_import): Fix typo in actioncmd.
6121
6122 2006-11-02  Bruno Haible  <bruno@clisp.org>
6123
6124         * gnulib-tool (func_get_automake_snippet): Interpret a backslash-
6125         newline sequence in the Makefile.am snippet as a space, like "make"
6126         does.
6127         Reported by Roger Persson <perrog@gmail.com>.
6128
6129 2006-11-01  Bruno Haible  <bruno@clisp.org>
6130
6131         * m4/strcase.m4 (gl_FUNC_STRNCASECMP): Check whether strncasecmp is
6132         already declared in <string.h>.
6133         * lib/strcase.h (strncasecmp): Don't declare it if yes.
6134
6135 2006-11-01  Bruno Haible  <bruno@clisp.org>
6136
6137         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Don't define strcasecmp here.
6138         * lib/strcase.h: Include <string.h>.
6139         (strcasecmp): Define to rpl_strcasecmp here.
6140
6141 2006-11-01  Bruno Haible  <bruno@clisp.org>
6142
6143         * lib/printf-parse.c (PRINTF_PARSE): Cast malloc/realloc results.
6144
6145 2006-11-01  Eric Blake  <ebb9@byu.net>
6146
6147         * lib/mkstemp-safer.c (mkstemp_safer): Allow C++ compilation.
6148
6149         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Allow C++ configuration.
6150
6151 2006-10-29  Bruno Haible  <bruno@clisp.org>
6152
6153         Make it compile in C++ mode.
6154         * lib/full-write.c (full_rw): Add a cast.
6155
6156 2006-11-01  Bruno Haible  <bruno@clisp.org>
6157
6158         * gnulib-tool (func_get_automake_snippet): Change sed_combine_lines to
6159         be POSIX compliant.
6160         Reported by Roger Persson <perrog@gmail.com>.
6161
6162 2006-11-01  Eric Blake  <ebb9@byu.net>
6163
6164         * lib/getopt_.h: Fix comments.
6165
6166 2006-10-31  Eric Blake  <ebb9@byu.net>
6167
6168         * modules/tmpdir (Depends-on): Add sys_stat.
6169         * modules/mkdtemp (Depends-on): Add tempname, drop unistd.
6170         * lib/mkdtemp.c (gen_tempname): Remove; tempname covers this.
6171         * lib/tmpdir.c (S_ISDIR): Simplify, thanks to sys_stat.
6172         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Simplify, thanks to
6173         tempname.
6174
6175 2006-10-31  Paul Eggert  <eggert@cs.ucla.edu>
6176
6177         Avoid some C++ diagnostics reported by Bruno Haible.
6178         * lib/quotearg.c (clone_quoting_options): Use xmemdup rather than
6179         xmalloc.
6180         (quotearg_alloc): Use xcharalloc rather than xmalloc.
6181         (struct slotvec): Move to top level.
6182         (quotearg_n_options): Rewrite to avoid xmalloc.
6183         * lib/xalloc.h (xcharalloc): New function.
6184         * (xrealloc, xnrealloc, x2realloc, x2nrealloc, xmemdup):
6185         [defined __cplusplus]: Add function template that provides result
6186         type propagation.  This part of the change is from Bruno Haible.
6187
6188 2006-10-29  Bruno Haible  <bruno@clisp.org>
6189
6190         Make it compile in C++ mode.
6191         * lib/striconv.c (mem_cd_iconv): Cast malloc/realloc result.
6192         * lib/strnlen1.c (strnlen1): Cast memchr result.
6193         * lib/mbchar.h (mb_copy): Rename arguments to 'new_mbc', 'old_mbc'.
6194         * lib/clean-temp.c (string_equals, string_hash): Add casts.
6195         (create_temp_dir): Rename local variable 'template'.
6196         (compile_csharp_using_sscli): Add cast.
6197         * lib/fatal-signal.c (at_fatal_signal): Cast xmalloc result.
6198         * lib/findprog.c (find_in_path): Likewise.
6199         * lib/linebreak.c (mbs_width_linebreaks): Cast malloc result.
6200         * lib/wait-process.c (register_slave_subprocess): Likewise.
6201
6202 2006-10-22  Bruno Haible  <bruno@clisp.org>
6203
6204         * modules/tsearch: New file.
6205         * lib/tsearch.h: New file.
6206         * lib/tsearch.c: New file, from glibc-2.5 with small modifications.
6207         * m4/tsearch.m4: New file.
6208         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add tsearch.
6209
6210 2006-10-29  Eric Blake  <ebb9@byu.net>
6211
6212         * lib/arcfour.c: Assume config.h.
6213         * lib/arctwo.c: Likewise.
6214         * lib/base64.c: Likewise.
6215         * lib/check-version.c: Likewise.
6216         * lib/crc.c: Likewise.
6217         * lib/des.c: Likewise.
6218         * lib/gc-gnulib.c: Likewise.
6219         * lib/gc-libgcrypt.c: Likewise.
6220         * lib/gc-pbkdf2-sha1.c: Likewise.
6221         * lib/getaddrinfo.c: Likewise.
6222         * lib/getdelim.c: Likewise.
6223         * lib/getline.c: Likewise.
6224         * lib/hmac-md5.c: Likewise.
6225         * lib/hmac-sha1.c: Likewise.
6226         * lib/iconvme.c: Likewise.
6227         * lib/md2.c: Likewise.
6228         * lib/md4.c: Likewise.
6229         * lib/memxor.c: Likewise.
6230         * lib/read-file.c: Likewise.
6231         * lib/readline.c: Likewise.
6232         * lib/rijndael-alg-fst.c: Likewise.
6233         * lib/rijndael-api-fst.c: Likewise.
6234         * lib/xgetdomainname.c: Likewise.
6235
6236 2006-10-28  Eric Blake  <ebb9@byu.net>
6237
6238         * lib/xstrndup.c: Assume config.h.
6239
6240 2006-10-27  Paul Eggert  <eggert@cs.ucla.edu>
6241
6242         Move stat.h-substitute stuff from lib/stat-macros.h to lib/stat_.h.
6243         stat-macros.h is now for our own macros, whereas stat_h is for
6244         macros in the <sys/stat.h> name space.
6245         * lib/stat-macros.h: Remove copyright notice, as this file is now tiny.
6246         (STAT_MACROS_H): Remove.
6247         (S_IFMT, S_ISBLK, S_ISCHR, S_ISDIR, S_ISFIFO, S_ISLNK, S_ISNAM):
6248         (S_ISMPB, S_ISMPC, S_ISNWK, S_ISREG, S_ISSOCK, S_ISDOOR, S_ISPORT):
6249         (S_TYPEISMQ, S_TYPEISTMO, S_TYPEISSEM, S_TYPEISSHM, S_ISCTG, S_ISOFD):
6250         (S_ISOFL, S_ISWHT, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IRGRP):
6251         (S_IROTH, S_IWUSR, S_IWGRP, S_IWOTH, S_IXUSR, S_IXGRP, S_IXOTH):
6252         (S_IRWXU, S_IRWXG, S_IRWXO, S_IXUGO, S_IRWXUGO):
6253         Move these macros to ...
6254         * lib/stat_.h: here.  Don't include stat-macros.h.
6255         * lib/canonicalize.c: Don't include stat-macros.h.
6256         * lib/chown.c: Likewise.
6257         * lib/euidaccess.c: Likewise.
6258         * lib/file-type.c: Likewise.
6259         * lib/filemode.c: Likewise.
6260         * lib/glob.c: Likewise.
6261         * lib/isapipe.c: Likewise.
6262         * lib/lchown.c: Likewise.
6263         * lib/lstat.c: Likewise.
6264         * lib/mkdir-p.c: Likewise.
6265         * lib/rmdir.c: Likewise.
6266         * m4/lchown.m4 (gl_FUNC_LCHOWN): Don't require gl_STAT_MACROS.
6267         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Don't check for io.h
6268         unless mkdir isn't declared, to speed up 'configure'.
6269         Always create sys/stat.h, since it's unlikely any real sys/stat.h
6270         would define all the S_* symbols.
6271         * modules/canonicalize (Depends-on):
6272         Depend on sys_stat, not stat-macros.
6273         * modules/chown: Likewise.
6274         * modules/euidaccess: Likewise.
6275         * modules/filemode: Likewise.
6276         * modules/file-type: Likewise.
6277         * modules/glob: Likewise.
6278         * modules/isapipe: Likewise.
6279         * modules/lchown: Likewise.
6280         * modules/lstat: Likewise.
6281         * modules/mkancesdirs: Likewise.
6282         * modules/rmdir: Likewise.
6283         * modules/mkdir-p (Depends-on): Also depend on sys_stat.
6284         * modules/modechange: Likewise.
6285         * modules/stat-macros (Files): Remove m4/stat-macros.m4.
6286         (configure.ac): Remove gl_STAT_MACROS.
6287         * modules/sys_stat (Depends-on): Remove stat-macros.
6288
6289 2006-10-27  Bruno Haible  <bruno@clisp.org>
6290
6291         * m4/signed.m4: Remove file.
6292         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS_: Remove bh_C_SIGNED
6293         invocation.
6294         * modules/vasnprintf (Files): Remove m4/signed.m4.
6295
6296 2006-10-27  Bruno Haible  <bruno@clisp.org>
6297
6298         Update to GNU gettext 0.16.
6299         * modules/gettext (Files): Add m4/intl.m4, m4/intldir.m4. Remove
6300         m4/inttypes-h.m4, m4/signed.m4.
6301         * m4/gettext.m4: Update to GNU gettext 0.16.
6302         * m4/intl.m4: New file, from GNU gettext.
6303         * m4/intldir.m4: New file, from GNU gettext.
6304         * config/srclist.txt: Update
6305
6306 2006-10-27  Eric Blake  <ebb9@byu.net>
6307
6308         * MODULES.html.sh: Document tempname.
6309         * modules/mkstemp (Depends-on): Add tempname, and drop transitive
6310         dependencies.
6311         (Files): Move lib/tempname.c...
6312         * modules/tempname: ...to this new module.
6313         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Remove tempname checks.
6314         (gl_PREREQ_TEMPNAME): Move...
6315         * m4/tempname.m4: ...to this new file.
6316         * lib/mkstemp.c (includes) [!_LIBC]: Use tempname.h.
6317         * modules/sys_stat (Depends-on): Add stat-macros.
6318         * lib/stat_.h (includes): Pick up stat macros.
6319         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Replace <sys/stat.h>
6320         if stat macros are broken.
6321         * lib/tempname.c (includes): No need to include "stat-macros.h".
6322         (__gen_tempname) [!_LIBC]: Expose as gen_tempname.
6323         (direxists, __path_search) [!_LIBC]: Don't compile these in
6324         gnulib; the tmpdir module covers that.
6325         * lib/tempname.h: New file.
6326
6327 2006-10-26  Paul Eggert  <eggert@cs.ucla.edu>
6328
6329         * COPYING: Explain how gnulib-tool converts licence headers.
6330         Almost all wording by Eric Blake.
6331
6332 2006-10-25  Paul Eggert  <eggert@cs.ucla.edu>
6333
6334         * lib/mbchar.h (is_basic_table): Make read-only.
6335         * lib/mbchar.c (is_basic_table): Likewise.
6336         Reported by John Darrington.
6337
6338 2006-10-25  Bruno Haible  <bruno@clisp.org>
6339
6340         * lib/progname.h (set_program_name): Undefine before defining.
6341
6342 2006-10-25  Bruno Haible  <bruno@clisp.org>
6343
6344         * lib/gettext.h (_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS): Define to
6345         false for non-gcc C++ compilers.
6346         Reported by Nelson H. F. Beebe <beebe@math.utah.edu>.
6347
6348 2006-10-24  Bruno Haible  <bruno@clisp.org>
6349
6350         * lib/striconv.c (mem_cd_iconv, str_cd_iconv): Treat all non-GNU
6351         iconv implementations like Irix iconv.
6352
6353 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6354
6355         * modules/vararrays: New file.
6356         * m4/vararrays.m4: New file, taken from diffutils.
6357         * MODULES.html.sh: New module vararrays.
6358
6359 2006-10-24  Karl Berry  <karl@gnu.org>
6360
6361         * doc/gnulib-intro.texi: --- instead of --; non-naive naive.
6362         Don't call GNU Unix.
6363
6364 2006-10-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6365
6366         * users.txt: Add Libtool.
6367
6368         Sync from Libtool:
6369
6370         2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6371
6372         * lib/argz.c: Remove check for HAVE_CONFIG_H, to conform
6373         to gnulib's policy of including config.h unconditionally.
6374
6375 2006-10-24  Bruno Haible  <bruno@clisp.org>
6376
6377         * modules/wcwidth (Files): Add m4/wint_t.m4.
6378         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Require gt_TYPE_WINT_T.
6379         * lib/wcwidth.h (iswprint): Use 'int' if 'wint_t' is not defined.
6380
6381 2006-10-24  Paul Eggert  <eggert@cs.ucla.edu>
6382
6383         * lib/getdate.y (yyerror): Make the arguments pointer-to-const,
6384         to pacify GCC with some -W flags enabled.  Problem reported by
6385         Bruno Haible.
6386
6387 2006-10-24  Jim Meyering  <jim@meyering.net>
6388
6389         * MODULES.html.sh: Remove uinttostr.  It's not a module.
6390         Reported by Karl Berry.
6391
6392 2006-10-23  Bruno Haible  <bruno@clisp.org>
6393
6394         * lib/fts.c (fts_build): Move variable declaration, for C89 compliance.
6395
6396 2006-10-24  Bruno Haible  <bruno@clisp.org>
6397
6398         * lib/gl_list.h: Use C comment style, not C++ comment style.
6399
6400 2006-10-23  Eric Blake  <ebb9@byu.net>
6401
6402         * lib/getaddrinfo.c (includes): Add missing include.
6403
6404 2006-10-23  Bruno Haible  <bruno@clisp.org>
6405             Paul Eggert  <eggert@cs.ucla.edu>
6406
6407         Ability to rename obstack_free.
6408         * lib/obstack.h (__obstack_free): New macro. Declare instead of
6409         obstack_free.
6410         (obstack_free): Invoke the __obstack_free macro.
6411         * lib/obstack.c (obstack_free): Use __obstack_free macro.
6412
6413 2006-10-23  Bruno Haible  <bruno@clisp.org>
6414             Paul Eggert  <eggert@cs.ucla.edu>
6415
6416         * lib/argp.h (argp_parse, __argp_parse): Comment out the identifiers
6417         __argc, __argv from the declaration. (They are defined as macros on
6418         mingw.)
6419
6420 2006-10-22  Bruno Haible  <bruno@clisp.org>
6421
6422         * doc/gnulib-intro.texi: New file.
6423         * doc/gnulib.texi: Include it.
6424
6425 2006-10-21  Bruno Haible  <bruno@clisp.org>
6426
6427         * doc/gnulib.texi: Split the chapter "Gnulib" into 3 chapters
6428         "Introduction", "Miscellanous Notes", "Particular Modules".
6429
6430 2006-10-21  Bruno Haible  <bruno@clisp.org>
6431
6432         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
6433         Change mostlyclean-local rule to avoid sh syntax error from bash
6434         versions 2.00..2.05 when $(MOSTLYCLEANDIRS) is empty.
6435
6436 2006-10-23  Jim Meyering  <jim@meyering.net>
6437
6438         * lib/getaddrinfo.c (getnameinfo): Use new lightweight uinttostr,
6439         in place of snprintf.
6440
6441         * modules/inttostr (Files): Add lib/uinttostr.c.
6442         * lib/uinttostr.c (inttostr): New file/function.
6443         * lib/inttostr.h (uinttostr): Declare.
6444         * m4/inttostr.m4: Add AC_LIBOBJ([uinttostr]).
6445         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
6446         Add uinttostr.
6447         * modules/getaddrinfo (Depends-on): Remove snprintf.  Add inttostr.
6448
6449 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
6450
6451         * lib/canonicalize.c (ELOOP): Define if not already defined.
6452         Problem reported by Bruno Haible in
6453         <http://lists.gnu.org/archive/html/bug-gnulib/2006-10/msg00282.html>.
6454
6455 2006-10-21  Paul Eggert  <eggert@cs.ucla.edu>
6456
6457         * lib/stdint_.h [defined _AIX]: Don't include <sys/types.h>.
6458         Problem reported by Perry Smith and Ville Laurikari.
6459
6460         * lib/getndelim2.c (SSIZE_MAX): Use same defn that getdelim.c
6461         uses.
6462
6463 2006-10-19  Bruno Haible  <bruno@clisp.org>
6464
6465         * lib/getndelim2.c (SSIZE_MAX): Provide fallback definition. Needed
6466         for mingw.
6467
6468 2006-10-19  Bruno Haible  <bruno@clisp.org>
6469
6470         * lib/openat-priv.h (EOPNOTSUPP): Provide fallback definition.
6471         Needed for mingw.
6472
6473 2006-10-19  Bruno Haible  <bruno@clisp.org>
6474
6475         * m4/size_max.m4 (gl_SIZE_MAX): Cache the result.
6476
6477 2006-10-19  Bruno Haible  <bruno@clisp.org>
6478
6479         * m4/allocsa.m4 (gl_ALLOCSA): Invoke gl_FUNC_ALLOCA, don't AC_REQUIRE
6480         it.
6481
6482 2006-10-19  Bruno Haible  <bruno@clisp.org>
6483
6484         * m4/alloca.m4 (gl_FUNC_ALLOCA): Cache the result of the AC_EGREP_CPP
6485         invocation.
6486
6487 2006-10-19  Bruno Haible  <bruno@clisp.org>
6488
6489         * gnulib-tool (func_create_testdir): Don't include ftruncate and
6490         mountlist by default.
6491
6492 2006-10-16  Bruno Haible  <bruno@clisp.org>
6493
6494         * lib/c-strstr.c: Include c-strstr.h.
6495
6496 2006-10-18  Charles Wilson  <cygwin@cwilson.fastmail.fm>
6497
6498         * gnulib-tool: Don't clobber $sourcebase when $local_gnulib_dir ends
6499         in a slash.
6500
6501 2006-10-18  Bruno Haible  <bruno@clisp.org>
6502
6503         * lib/lock.h [C++]: Wrap definitions in extern "C".
6504
6505 2006-10-18  Bruno Haible  <bruno@clisp.org>
6506
6507         * gnulib-tool (func_emit_initmacro_end): Remove duplicates from the
6508         gl_LIBOBJS list.
6509
6510 2006-10-18  Bruno Haible  <bruno@clisp.org>
6511
6512         * lib/findprog.c (find_in_path): Avoid "gcc -Wwrite-strings" warning.
6513
6514 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>
6515
6516         * lib/xstrtol.h: Include gettext.h.
6517         (_STRTOL_ERROR): Wrap English-language formats inside gettext.
6518         Problem reported by Eric Blake.
6519         * modules/xstrtol (Depends-on): Add gettext-h.
6520
6521 2006-10-19  Paul Eggert  <eggert@cs.ucla.edu>  (tiny change)
6522
6523         * lib/strftime.c (advance): New macro.
6524         (add): Use it to avoid adding 0 to a FILE *.  FILE can be an
6525         incomplete type, so you can't add 0 to it.  Problem and patch
6526         reported by Eelco Dolstra for dietlibc.
6527
6528 2006-10-18  Jim Meyering  <jim@meyering.net>
6529
6530         * lib/readutmp.c (desirable_utmp_entry): Use "bool" as the
6531         type for a local, and rename it: s/up/user_proc/.
6532
6533 2006-10-18  Sergey Poznyakoff  <gray@gnu.org.ua>
6534
6535         * lib/readutmp.c (desirable_utmp_entry): Implement new flag:
6536         READ_UTMP_USER_PROCESS.
6537         * lib/readutmp.h (READ_UTMP_USER_PROCESS): New flag
6538
6539 2006-10-17  Paul Eggert  <eggert@cs.ucla.edu>
6540
6541         * lib/localcharset.c: Do not check HAVE_SETLOCALE.
6542         * m4/localcharset.m4 (gl_LOCALCHARSET): Don't check for setlocale.
6543
6544 2006-10-17  Eric Blake  <ebb9@byu.net>
6545
6546         * lib/sigprocmask.c (sigprocmask): Fix typo.
6547
6548         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Fix typo.
6549
6550         * modules/clean-temp (Makefile.am): Don't add to make output...
6551         (configure.ac): ...instead define SIGNAL_SAFE_LIST inside
6552         config.h.
6553
6554 2006-10-17  Bruno Haible  <bruno@clisp.org>
6555
6556         * lib/gettext.h (gettext, ngettext, pgettext, npgettext): Define
6557         differently if DEFAULT_TEXT_DOMAIN is set.
6558
6559 2006-10-16  Bruno Haible  <bruno@clisp.org>
6560
6561         * lib/clean-temp.c: Include fwriteerror.h.
6562
6563 2006-10-16  Bruno Haible  <bruno@clisp.org>
6564
6565         * getndelim2.m4 (gl_GETNDELIM2): Remove 2003-10-23 hack.
6566
6567 2006-10-16  Bruno Haible  <bruno@clisp.org>
6568
6569         * m4/signalblocking.m4 (gl_PREREQ_SIGPROCMASK): Also test for sigset_t.
6570         * lib/sigprocmask.h: Include <sys/types.h>.
6571         (sigset_t): Use the system's definition if present.
6572
6573 2006-10-17  Eric Blake  <ebb9@byu.net>
6574
6575         * lib/xvasprintf.c (includes): Assume config.h.
6576         * lib/xasprintf.c (includes): Likewise.
6577
6578 2006-10-16  Paul Eggert  <eggert@cs.ucla.edu>
6579
6580         * lib/fsusage.c (PROPAGATE_ALL_ONES): Don't assume uintmax_t is
6581         at least as wide as intmax_t.
6582
6583 2006-10-16  Alexandre Duret-Lutz  <adl@gnu.org>
6584
6585         (Imported from Automake.)
6586         * build-aux/gnupload: Update to version 1.1 of directive file.
6587
6588 2006-10-16  Eric Blake  <ebb9@byu.net>
6589
6590         * modules/configmake (Makefile.am): Add pkglibexecdir support, to
6591         match Automake 1.10a.
6592
6593 2006-10-14  Bruno Haible  <bruno@clisp.org>
6594
6595         * modules/sigprocmask: New file.
6596         * lib/sigprocmask.h: New file.
6597         * lib/sigprocmask.c: New file.
6598         * m4/signalblocking.m4 (gl_SIGNALBLOCKING): Renamed from
6599         gt_SIGNALBLOCKING. When not defining HAVE_POSIX_SIGNALBLOCKING,
6600         request sigprocmask.o.
6601         (gl_PREREQ_SIGPROCMASK): New macro.
6602         * modules/fatal-signal (Files): Remove m4/signalblocking.m4.
6603         (Depends-on): Add sigprocmask.
6604         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Don't require
6605         gt_SIGNALBLOCKING. Test for 'raise' only once.
6606         * lib/fatal-signal.c: Include sigprocmask.h.
6607         (fatal_signal_set, init_fatal_signal_set, block_fatal_signals,
6608         unblock_fatal_signals): Define always.
6609         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
6610         sigprocmask.
6611
6612 2006-10-14  Paul Eggert  <eggert@cs.ucla.edu>
6613
6614         Sync from Automake.
6615         * build-aux/install-sh (posix_mkdir): Reject FreeBSD 6.1 mkdir -p -m,
6616         which incorrectly sets the mode of an existing destination
6617         directory.  In some cases the unpatched install-sh could do the
6618         equivalent of "chmod 777 /" or "chmod 0 /" on a buggy FreeBSD
6619         system.  We hope this is rare in practice, but it's clearly worth
6620         fixing.  Problem reported by Alex Unleashed in
6621         <http://lists.gnu.org/archive/html/bug-autoconf/2006-10/msg00012.html>.
6622         Also, don't bother to check for -m bugs unless we're using -m;
6623         suggested by Stepan Kasal.
6624
6625 2006-10-14  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
6626
6627         Sync from Automake.
6628         * build-aux/depcomp (gcc3): Put dependency extraction flags before the
6629         `-c' flag, so they appear at the same position as in %FASTDEP%
6630         mode in depend2.am.  Fixes build failure for FreeBSD's c89,
6631         which ignores unknown options only after the first non-option.
6632         Bug report against M4 by Nelson H. F. Beebe.
6633
6634 2006-10-13  Jim Meyering  <jim@meyering.net>
6635
6636         Fix a bug in yesterday's change.
6637         * lib/fts.c (fts_open): When using FTS_XDEV|FTS_NOSTAT,
6638         p->fts_statp->st_dev would be used uninitialized.
6639         Ensures that we always call fts_stat on the very first entry.
6640         Miklos Szeredi reported that find -xdev stopped working.
6641
6642 2006-10-12  Bruno Haible  <bruno@clisp.org>
6643
6644         * gnulib-tool (func_get_automake_snippet): Append an automatically
6645         computed EXTRA_DIST augmentation.
6646         * modules/acl (Makefile.am): Remove EXTRA_DIST augmentation.
6647         * modules/alloca-opt (Makefile.am): Likewise.
6648         * modules/allocsa (Makefile.am): Likewise.
6649         * modules/arcfour (Makefile.am): Likewise.
6650         * modules/arctwo (Makefile.am): Likewise.
6651         * modules/argmatch (Makefile.am): Likewise.
6652         * modules/argz (Makefile.am): Likewise.
6653         * modules/atexit (Makefile.am): Likewise.
6654         * modules/backupfile (Makefile.am): Likewise.
6655         * modules/byteswap (Makefile.am): Likewise.
6656         * modules/c-strtod (Makefile.am): Likewise.
6657         * modules/c-strtold (Makefile.am): Likewise.
6658         * modules/calloc (Makefile.am): Likewise.
6659         * modules/canon-host (Makefile.am): Likewise.
6660         * modules/canonicalize (Makefile.am): Likewise.
6661         * modules/chdir-long (Makefile.am): Likewise.
6662         * modules/chdir-safer (Makefile.am): Likewise.
6663         * modules/check-version (Makefile.am): Likewise.
6664         * modules/chown (Makefile.am): Likewise.
6665         * modules/cloexec (Makefile.am): Likewise.
6666         * modules/close-stream (Makefile.am): Likewise.
6667         * modules/closeout (Makefile.am): Likewise.
6668         * modules/crc (Makefile.am): Likewise.
6669         * modules/csharpexec (Makefile.am): Likewise.
6670         * modules/cycle-check (Makefile.am): Likewise.
6671         * modules/des (Makefile.am): Likewise.
6672         * modules/dev-ino (Makefile.am): Likewise.
6673         * modules/dirfd (Makefile.am): Likewise.
6674         * modules/dirname (Makefile.am): Likewise.
6675         * modules/dup2 (Makefile.am): Likewise.
6676         * modules/eealloc (Makefile.am): Likewise.
6677         * modules/error (Makefile.am): Likewise.
6678         * modules/euidaccess (Makefile.am): Likewise.
6679         * modules/exclude (Makefile.am): Likewise.
6680         * modules/exitfail (Makefile.am): Likewise.
6681         * modules/fcntl-safer (Makefile.am): Likewise.
6682         * modules/fcntl (Makefile.am): Likewise.
6683         * modules/file-type (Makefile.am): Likewise.
6684         * modules/fileblocks (Makefile.am): Likewise.
6685         * modules/filemode (Makefile.am): Likewise.
6686         * modules/filenamecat (Makefile.am): Likewise.
6687         * modules/fnmatch (Makefile.am): Likewise.
6688         * modules/fopen-safer (Makefile.am): Likewise.
6689         * modules/fpending (Makefile.am): Likewise.
6690         * modules/fprintftime (Makefile.am): Likewise.
6691         * modules/free (Makefile.am): Likewise.
6692         * modules/fsusage (Makefile.am): Likewise.
6693         * modules/ftruncate (Makefile.am): Likewise.
6694         * modules/fts (Makefile.am): Likewise.
6695         * modules/gc-arcfour (Makefile.am): Likewise.
6696         * modules/gc-des (Makefile.am): Likewise.
6697         * modules/gc-hmac-md5 (Makefile.am): Likewise.
6698         * modules/gc-hmac-sha1 (Makefile.am): Likewise.
6699         * modules/gc-md4 (Makefile.am): Likewise.
6700         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6701         * modules/gc-sha1 (Makefile.am): Likewise.
6702         * modules/gc (Makefile.am): Likewise.
6703         * modules/getaddrinfo (Makefile.am): Likewise.
6704         * modules/getcwd (Makefile.am): Likewise.
6705         * modules/getdelim (Makefile.am): Likewise.
6706         * modules/getdomainname (Makefile.am): Likewise.
6707         * modules/getgroups (Makefile.am): Likewise.
6708         * modules/gethostname (Makefile.am): Likewise.
6709         * modules/gethrxtime (Makefile.am): Likewise.
6710         * modules/getline (Makefile.am): Likewise.
6711         * modules/getloadavg (Makefile.am): Likewise.
6712         * modules/getlogin_r (Makefile.am): Likewise.
6713         * modules/getndelim2 (Makefile.am): Likewise.
6714         * modules/getopt (Makefile.am): Likewise.
6715         * modules/getpagesize (Makefile.am): Likewise.
6716         * modules/getpass-gnu (Makefile.am): Likewise.
6717         * modules/getpass (Makefile.am): Likewise.
6718         * modules/getsubopt (Makefile.am): Likewise.
6719         * modules/gettime (Makefile.am): Likewise.
6720         * modules/gettimeofday (Makefile.am): Likewise.
6721         * modules/getugroups (Makefile.am): Likewise.
6722         * modules/getusershell (Makefile.am): Likewise.
6723         * modules/glob (Makefile.am): Likewise.
6724         * modules/group-member (Makefile.am): Likewise.
6725         * modules/hard-locale (Makefile.am): Likewise.
6726         * modules/hash (Makefile.am): Likewise.
6727         * modules/hmac-md5 (Makefile.am): Likewise.
6728         * modules/hmac-sha1 (Makefile.am): Likewise.
6729         * modules/human (Makefile.am): Likewise.
6730         * modules/idcache (Makefile.am): Likewise.
6731         * modules/imaxabs (Makefile.am): Likewise.
6732         * modules/imaxdiv (Makefile.am): Likewise.
6733         * modules/inet_ntop (Makefile.am): Likewise.
6734         * modules/inet_pton (Makefile.am): Likewise.
6735         * modules/intprops (Makefile.am): Likewise.
6736         * modules/inttostr (Makefile.am): Likewise.
6737         * modules/inttypes (Makefile.am): Likewise.
6738         * modules/isapipe (Makefile.am): Likewise.
6739         * modules/javaversion (Makefile.am): Likewise.
6740         * modules/lchmod (Makefile.am): Likewise.
6741         * modules/lchown (Makefile.am): Likewise.
6742         * modules/localcharset (Makefile.am): Likewise.
6743         * modules/long-options (Makefile.am): Likewise.
6744         * modules/lstat (Makefile.am): Likewise.
6745         * modules/malloc (Makefile.am): Likewise.
6746         * modules/mathl (Makefile.am): Likewise.
6747         * modules/mbchar (Makefile.am): Likewise.
6748         * modules/md2 (Makefile.am): Likewise.
6749         * modules/md4 (Makefile.am): Likewise.
6750         * modules/md5 (Makefile.am): Likewise.
6751         * modules/memcasecmp (Makefile.am): Likewise.
6752         * modules/memchr (Makefile.am): Likewise.
6753         * modules/memcmp (Makefile.am): Likewise.
6754         * modules/memcoll (Makefile.am): Likewise.
6755         * modules/memcpy (Makefile.am): Likewise.
6756         * modules/memmem (Makefile.am): Likewise.
6757         * modules/memmove (Makefile.am): Likewise.
6758         * modules/mempcpy (Makefile.am): Likewise.
6759         * modules/memrchr (Makefile.am): Likewise.
6760         * modules/memset (Makefile.am): Likewise.
6761         * modules/memxor (Makefile.am): Likewise.
6762         * modules/mkancesdirs (Makefile.am): Likewise.
6763         * modules/mkdir-p (Makefile.am): Likewise.
6764         * modules/mkdir (Makefile.am): Likewise.
6765         * modules/mkdtemp (Makefile.am): Likewise.
6766         * modules/mkstemp (Makefile.am): Likewise.
6767         * modules/mktime (Makefile.am): Likewise.
6768         * modules/modechange (Makefile.am): Likewise.
6769         * modules/mountlist (Makefile.am): Likewise.
6770         * modules/nanosleep (Makefile.am): Likewise.
6771         * modules/obstack (Makefile.am): Likewise.
6772         * modules/openat (Makefile.am): Likewise.
6773         * modules/pagealign_alloc (Makefile.am): Likewise.
6774         * modules/pathmax (Makefile.am): Likewise.
6775         * modules/physmem (Makefile.am): Likewise.
6776         * modules/poll (Makefile.am): Likewise.
6777         * modules/posixtm (Makefile.am): Likewise.
6778         * modules/posixver (Makefile.am): Likewise.
6779         * modules/putenv (Makefile.am): Likewise.
6780         * modules/quote (Makefile.am): Likewise.
6781         * modules/quotearg (Makefile.am): Likewise.
6782         * modules/raise (Makefile.am): Likewise.
6783         * modules/read-file (Makefile.am): Likewise.
6784         * modules/readline (Makefile.am): Likewise.
6785         * modules/readlink (Makefile.am): Likewise.
6786         * modules/readtokens (Makefile.am): Likewise.
6787         * modules/readutmp (Makefile.am): Likewise.
6788         * modules/realloc (Makefile.am): Likewise.
6789         * modules/regex (Makefile.am): Likewise.
6790         * modules/rename-dest-slash (Makefile.am): Likewise.
6791         * modules/rename (Makefile.am): Likewise.
6792         * modules/rijndael (Makefile.am): Likewise.
6793         * modules/rmdir (Makefile.am): Likewise.
6794         * modules/rpmatch (Makefile.am): Likewise.
6795         * modules/safe-read (Makefile.am): Likewise.
6796         * modules/safe-write (Makefile.am): Likewise.
6797         * modules/same-inode (Makefile.am): Likewise.
6798         * modules/same (Makefile.am): Likewise.
6799         * modules/save-cwd (Makefile.am): Likewise.
6800         * modules/savedir (Makefile.am): Likewise.
6801         * modules/setenv (Makefile.am): Likewise.
6802         * modules/settime (Makefile.am): Likewise.
6803         * modules/sha1 (Makefile.am): Likewise.
6804         * modules/sig2str (Makefile.am): Likewise.
6805         * modules/snprintf (Makefile.am): Likewise.
6806         * modules/stat-macros (Makefile.am): Likewise.
6807         * modules/stat-time (Makefile.am): Likewise.
6808         * modules/stdbool (Makefile.am): Likewise.
6809         * modules/stdint (Makefile.am): Likewise.
6810         * modules/stdlib-safer (Makefile.am): Likewise.
6811         * modules/stpcpy (Makefile.am): Likewise.
6812         * modules/stpncpy (Makefile.am): Likewise.
6813         * modules/strcase (Makefile.am): Likewise.
6814         * modules/strcasestr (Makefile.am): Likewise.
6815         * modules/strchrnul (Makefile.am): Likewise.
6816         * modules/strcspn (Makefile.am): Likewise.
6817         * modules/strdup (Makefile.am): Likewise.
6818         * modules/strerror (Makefile.am): Likewise.
6819         * modules/strftime (Makefile.am): Likewise.
6820         * modules/strndup (Makefile.am): Likewise.
6821         * modules/strnlen (Makefile.am): Likewise.
6822         * modules/strpbrk (Makefile.am): Likewise.
6823         * modules/strsep (Makefile.am): Likewise.
6824         * modules/strstr (Makefile.am): Likewise.
6825         * modules/strtod (Makefile.am): Likewise.
6826         * modules/strtoimax (Makefile.am): Likewise.
6827         * modules/strtok_r (Makefile.am): Likewise.
6828         * modules/strtol (Makefile.am): Likewise.
6829         * modules/strtoll (Makefile.am): Likewise.
6830         * modules/strtoul (Makefile.am): Likewise.
6831         * modules/strtoull (Makefile.am): Likewise.
6832         * modules/strtoumax (Makefile.am): Likewise.
6833         * modules/strverscmp (Makefile.am): Likewise.
6834         * modules/sys_socket (Makefile.am): Likewise.
6835         * modules/sys_stat (Makefile.am): Likewise.
6836         * modules/sysexits (Makefile.am): Likewise.
6837         * modules/time_r (Makefile.am): Likewise.
6838         * modules/timegm (Makefile.am): Likewise.
6839         * modules/timespec (Makefile.am): Likewise.
6840         * modules/tmpfile-safer (Makefile.am): Likewise.
6841         * modules/trim (Makefile.am): Likewise.
6842         * modules/unistd-safer (Makefile.am): Likewise.
6843         * modules/unlinkdir (Makefile.am): Likewise.
6844         * modules/unlocked-io (Makefile.am): Likewise.
6845         * modules/userspec (Makefile.am): Likewise.
6846         * modules/utime (Makefile.am): Likewise.
6847         * modules/utimecmp (Makefile.am): Likewise.
6848         * modules/utimens (Makefile.am): Likewise.
6849         * modules/vasnprintf (Makefile.am): Likewise.
6850         * modules/vasprintf (Makefile.am): Likewise.
6851         * modules/vsnprintf (Makefile.am): Likewise.
6852         * modules/xalloc (Makefile.am): Likewise.
6853         * modules/xgetcwd (Makefile.am): Likewise.
6854         * modules/xnanosleep (Makefile.am): Likewise.
6855         * modules/xreadlink (Makefile.am): Likewise.
6856         * modules/xstrtod (Makefile.am): Likewise.
6857         * modules/xstrtol (Makefile.am): Likewise.
6858         * modules/xstrtold (Makefile.am): Likewise.
6859         * modules/yesno (Makefile.am): Likewise.
6860         * modules/getdate (Makefile.am): Don't add getdate.h to EXTRA_DIST.
6861
6862 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
6863
6864         * modules/error (Makefile.am): Distribute files through
6865         EXTRA_DIST, not lib_SOURCES.
6866
6867 2006-10-12  Eric Blake  <ebb9@byu.net>
6868
6869         * modules/error (Makefile.am): Distribute files in /lib.
6870         * modules/obstack (Makefile.am): Likewise.
6871
6872 2006-10-12  Bruno Haible  <bruno@clisp.org>
6873
6874         * modules/acl (Makefile.am): Distribute all files in lib/ through
6875         EXTRA_DIST.
6876         * modules/arcfour (Makefile.am): Likewise.
6877         * modules/arctwo (Makefile.am): Likewise.
6878         * modules/argmatch (Makefile.am): Likewise.
6879         * modules/argz (Makefile.am): Likewise.
6880         * modules/atexit (Makefile.am): Likewise.
6881         * modules/backupfile (Makefile.am): Likewise.
6882         * modules/c-strtod (Makefile.am): Likewise.
6883         * modules/c-strtold (Makefile.am): Likewise.
6884         * modules/calloc (Makefile.am): Likewise.
6885         * modules/canon-host (Makefile.am): Likewise.
6886         * modules/canonicalize (Makefile.am): Likewise.
6887         * modules/chdir-long (Makefile.am): Likewise.
6888         * modules/chdir-safer (Makefile.am): Likewise.
6889         * modules/check-version (Makefile.am): Likewise.
6890         * modules/chown (Makefile.am): Likewise.
6891         * modules/cloexec (Makefile.am): Likewise.
6892         * modules/close-stream (Makefile.am): Likewise.
6893         * modules/closeout (Makefile.am): Likewise.
6894         * modules/crc (Makefile.am): Likewise.
6895         * modules/cycle-check (Makefile.am): Likewise.
6896         * modules/des (Makefile.am): Likewise.
6897         * modules/dirfd (Makefile.am): Likewise.
6898         * modules/dirname (Makefile.am): Likewise.
6899         * modules/dup2 (Makefile.am): Likewise.
6900         * modules/euidaccess (Makefile.am): Likewise.
6901         * modules/exclude (Makefile.am): Likewise.
6902         * modules/exitfail (Makefile.am): Likewise.
6903         * modules/fcntl-safer (Makefile.am): Likewise.
6904         * modules/file-type (Makefile.am): Likewise.
6905         * modules/fileblocks (Makefile.am): Likewise.
6906         * modules/filemode (Makefile.am): Likewise.
6907         * modules/filenamecat (Makefile.am): Likewise.
6908         * modules/fnmatch (Makefile.am): Likewise.
6909         * modules/fopen-safer (Makefile.am): Likewise.
6910         * modules/fpending (Makefile.am): Likewise.
6911         * modules/fprintftime (Makefile.am): Likewise.
6912         * modules/free (Makefile.am): Likewise.
6913         * modules/fsusage (Makefile.am): Likewise.
6914         * modules/ftruncate (Makefile.am): Likewise.
6915         * modules/fts (Makefile.am): Likewise.
6916         * modules/gc (Makefile.am): Likewise.
6917         * modules/gc-pbkdf2-sha1 (Makefile.am): Likewise.
6918         * modules/getaddrinfo (Makefile.am): Likewise.
6919         * modules/getcwd (Makefile.am): Likewise.
6920         * modules/getdelim (Makefile.am): Likewise.
6921         * modules/getdomainname (Makefile.am): Likewise.
6922         * modules/getgroups (Makefile.am): Likewise.
6923         * modules/gethostname (Makefile.am): Likewise.
6924         * modules/gethrxtime (Makefile.am): Likewise.
6925         * modules/getline (Makefile.am): Likewise.
6926         * modules/getloadavg (Makefile.am): Likewise.
6927         * modules/getlogin_r (Makefile.am): Likewise.
6928         * modules/getopt (Makefile.am): Likewise.
6929         * modules/getpass (Makefile.am): Likewise.
6930         * modules/getpass-gnu (Makefile.am): Likewise.
6931         * modules/getsubopt (Makefile.am): Likewise.
6932         * modules/gettime (Makefile.am): Likewise.
6933         * modules/gettimeofday (Makefile.am): Likewise.
6934         * modules/getugroups (Makefile.am): Likewise.
6935         * modules/getusershell (Makefile.am): Likewise.
6936         * modules/glob (Makefile.am): Likewise.
6937         * modules/group-member (Makefile.am): Likewise.
6938         * modules/hard-locale (Makefile.am): Likewise.
6939         * modules/hash (Makefile.am): Likewise.
6940         * modules/hmac-md5 (Makefile.am): Likewise.
6941         * modules/hmac-sha1 (Makefile.am): Likewise.
6942         * modules/human (Makefile.am): Likewise.
6943         * modules/idcache (Makefile.am): Likewise.
6944         * modules/imaxabs (Makefile.am): Likewise.
6945         * modules/imaxdiv (Makefile.am): Likewise.
6946         * modules/inet_ntop (Makefile.am): Likewise.
6947         * modules/inet_pton (Makefile.am): Likewise.
6948         * modules/inttostr (Makefile.am): Likewise.
6949         * modules/isapipe (Makefile.am): Likewise.
6950         * modules/lchown (Makefile.am): Likewise.
6951         * modules/long-options (Makefile.am): Likewise.
6952         * modules/lstat (Makefile.am): Likewise.
6953         * modules/malloc (Makefile.am): Likewise.
6954         * modules/mathl (Makefile.am): Likewise.
6955         * modules/mbchar (Makefile.am): Likewise.
6956         * modules/md2 (Makefile.am): Likewise.
6957         * modules/md4 (Makefile.am): Likewise.
6958         * modules/md5 (Makefile.am): Likewise.
6959         * modules/memcasecmp (Makefile.am): Likewise.
6960         * modules/memchr (Makefile.am): Likewise.
6961         * modules/memcmp (Makefile.am): Likewise.
6962         * modules/memcoll (Makefile.am): Likewise.
6963         * modules/memcpy (Makefile.am): Likewise.
6964         * modules/memmem (Makefile.am): Likewise.
6965         * modules/memmove (Makefile.am): Likewise.
6966         * modules/mempcpy (Makefile.am): Likewise.
6967         * modules/memrchr (Makefile.am): Likewise.
6968         * modules/memset (Makefile.am): Likewise.
6969         * modules/memxor (Makefile.am): Likewise.
6970         * modules/mkancesdirs (Makefile.am): Likewise.
6971         * modules/mkdir (Makefile.am): Likewise.
6972         * modules/mkdir-p (Makefile.am): Likewise.
6973         * modules/mkdtemp (Makefile.am): Likewise.
6974         * modules/mkstemp (Makefile.am): Likewise.
6975         * modules/mktime (Makefile.am): Likewise.
6976         * modules/modechange (Makefile.am): Likewise.
6977         * modules/mountlist (Makefile.am): Likewise.
6978         * modules/nanosleep (Makefile.am): Likewise.
6979         * modules/openat (Makefile.am): Likewise.
6980         * modules/pagealign_alloc (Makefile.am): Likewise.
6981         * modules/physmem (Makefile.am): Likewise.
6982         * modules/poll (Makefile.am): Likewise.
6983         * modules/posixtm (Makefile.am): Likewise.
6984         * modules/posixver (Makefile.am): Likewise.
6985         * modules/putenv (Makefile.am): Likewise.
6986         * modules/quote (Makefile.am): Likewise.
6987         * modules/quotearg (Makefile.am): Likewise.
6988         * modules/raise (Makefile.am): Likewise.
6989         * modules/read-file (Makefile.am): Likewise.
6990         * modules/readline (Makefile.am): Likewise.
6991         * modules/readlink (Makefile.am): Likewise.
6992         * modules/readtokens (Makefile.am): Likewise.
6993         * modules/readutmp (Makefile.am): Likewise.
6994         * modules/realloc (Makefile.am): Likewise.
6995         * modules/regex (Makefile.am): Likewise.
6996         * modules/rename (Makefile.am): Likewise.
6997         * modules/rename-dest-slash (Makefile.am): Likewise.
6998         * modules/rijndael (Makefile.am): Likewise.
6999         * modules/rmdir (Makefile.am): Likewise.
7000         * modules/rpmatch (Makefile.am): Likewise.
7001         * modules/safe-read (Makefile.am): Likewise.
7002         * modules/safe-write (Makefile.am): Likewise.
7003         * modules/same (Makefile.am): Likewise.
7004         * modules/save-cwd (Makefile.am): Likewise.
7005         * modules/savedir (Makefile.am): Likewise.
7006         * modules/setenv (Makefile.am): Likewise.
7007         * modules/settime (Makefile.am): Likewise.
7008         * modules/sha1 (Makefile.am): Likewise.
7009         * modules/sig2str (Makefile.am): Likewise.
7010         * modules/snprintf (Makefile.am): Likewise.
7011         * modules/stdlib-safer (Makefile.am): Likewise.
7012         * modules/stpcpy (Makefile.am): Likewise.
7013         * modules/stpncpy (Makefile.am): Likewise.
7014         * modules/strcase (Makefile.am): Likewise.
7015         * modules/strcasestr (Makefile.am): Likewise.
7016         * modules/strchrnul (Makefile.am): Likewise.
7017         * modules/strcspn (Makefile.am): Likewise.
7018         * modules/strdup (Makefile.am): Likewise.
7019         * modules/strerror (Makefile.am): Likewise.
7020         * modules/strftime (Makefile.am): Likewise.
7021         * modules/strndup (Makefile.am): Likewise.
7022         * modules/strnlen (Makefile.am): Likewise.
7023         * modules/strpbrk (Makefile.am): Likewise.
7024         * modules/strsep (Makefile.am): Likewise.
7025         * modules/strstr (Makefile.am): Likewise.
7026         * modules/strtod (Makefile.am): Likewise.
7027         * modules/strtoimax (Makefile.am): Likewise.
7028         * modules/strtok_r (Makefile.am): Likewise.
7029         * modules/strtol (Makefile.am): Likewise.
7030         * modules/strtoll (Makefile.am): Likewise.
7031         * modules/strtoul (Makefile.am): Likewise.
7032         * modules/strtoull (Makefile.am): Likewise.
7033         * modules/strtoumax (Makefile.am): Likewise.
7034         * modules/strverscmp (Makefile.am): Likewise.
7035         * modules/time_r (Makefile.am): Likewise.
7036         * modules/timegm (Makefile.am): Likewise.
7037         * modules/tmpfile-safer (Makefile.am): Likewise.
7038         * modules/unistd-safer (Makefile.am): Likewise.
7039         * modules/unlinkdir (Makefile.am): Likewise.
7040         * modules/userspec (Makefile.am): Likewise.
7041         * modules/utime (Makefile.am): Likewise.
7042         * modules/utimecmp (Makefile.am): Likewise.
7043         * modules/utimens (Makefile.am): Likewise.
7044         * modules/vasnprintf (Makefile.am): Likewise.
7045         * modules/vasprintf (Makefile.am): Likewise.
7046         * modules/vsnprintf (Makefile.am): Likewise.
7047         * modules/xalloc (Makefile.am): Likewise.
7048         * modules/xgetcwd (Makefile.am): Likewise.
7049         * modules/xnanosleep (Makefile.am): Likewise.
7050         * modules/xreadlink (Makefile.am): Likewise.
7051         * modules/xstrtod (Makefile.am): Likewise.
7052         * modules/xstrtol (Makefile.am): Likewise.
7053         * modules/xstrtold (Makefile.am): Likewise.
7054         * modules/yesno (Makefile.am): Likewise.
7055
7056 2006-10-12  Jim Meyering  <jim@meyering.net>
7057
7058         * m4/getloadavg.m4: Revert the change below.
7059
7060         * m4/getloadavg.m4 (gl_GETLOADAVG): Test for the existence of
7061         lib/getloadavg.c using "ls -L", not "test -f".  The latter would
7062         fail with a symlink, which is what coreutils' ./bootstrap now
7063         creates by default.
7064
7065 2006-10-12  Bruno Haible  <bruno@clisp.org>
7066
7067         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): Don't define for MSVC or
7068         mingw.
7069         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX): Handle
7070         MSVC and mingw explicitly.
7071
7072 2006-10-11  Simon Josefsson  <jas@extundo.com>
7073             Bruno Haible  <bruno@clisp.org>
7074
7075         Add support for multiple gnulib-tool invocations in the scope of a
7076         single configure.ac file.
7077         * gnulib-tool (func_emit_lib_Makefile_am): In the _LIBADD variable,
7078         use a private [LT]LIBOBJS variant. Define a _DEPENDENCIES variable
7079         with the same contents as the _LIBADD variable.
7080         (func_emit_initmacro_start, func_emit_initmacro_end,
7081         func_emit_initmacro_done): New functions.
7082         (func_import, func_create_testdir): Invoke them. Allow the identifiers
7083         gl_LIBOBJS and gl_LTLIBOBJS.
7084
7085 2006-10-11  Bruno Haible  <bruno@clisp.org>
7086
7087         * gnulib-tool (GETTEXTPATH, AUTOHEADER, AUTOPOINT): New variables.
7088         (func_create_testdir): Don't create po/Makefile.am, don't invoke
7089         autoreconf. Instead, invoke autopoint explicitly but move back the
7090         *.m4 files from gnulib.
7091
7092 2006-10-11  Bruno Haible  <bruno@clisp.org>
7093
7094         * gnulib-tool (func_usage): Make module names after --create-testdir
7095         optional.
7096         (func_create_testdir): If no module was specified, use nearly all
7097         modules.
7098
7099 2006-10-12  Jim Meyering  <jim@meyering.net>
7100
7101         Big performance improvement for fts-based tools that use FTS_NOSTAT.
7102         Avoid spurious inode-mismatch problems on non-POSIX file systems.
7103         Details: http://article.gmane.org/gmane.comp.lib.gnulib.bugs/7416
7104         * lib/fts_.h (FTS_DEFER_STAT): Define new flag.
7105         (FTS_OPTIONMASK): Extend the mask to reflect this addition.
7106         * lib/fts.c (DT_IS_KNOWN, DT_MUST_BE): Define.
7107         (FTS_NO_STAT_REQUIRED, FTS_STAT_REQUIRED): Define.
7108         (fts_set_stat_required): New function.
7109         (fts_open): Defer the calls to fts_stat, if possible or requested.
7110         Move the code that maps a command-line fts_info value FTS_DOT to FTS_D
7111         into fts_stat itself.
7112         (fts_read): Perform any required (deferred) fts_stat call.
7113         (fts_build): Likewise, for the directory we're about to open and read.
7114         In the readdir loop, carefully decide whether each entry will require
7115         an eventual call to fts_stat, using dirent.d_type info if available.
7116         (fts_stat): Move the test for whether to honor FTS_COMFOLLOW on
7117         a command line argument into this function.  Update all callers.
7118         Map a return value of FTS_DOT to FTS_D for a command line argument.
7119         * modules/fts (Depends-on): Add d-type.  Alphabetize.
7120         Thanks to Miklos Szeredi for his tenacity and for the initial
7121         bug report about "find" failing on a FUSE-based file system.
7122
7123         * lib/fts.c (fts_open): Use consistent indentation.
7124
7125 2006-10-12  Paul Eggert  <eggert@cs.ucla.edu>
7126
7127         * m4/extensions.m4 (AC_USE_SYSTEM_EXTENSIONS): Renamed from
7128         gl_USE_SYSTEM_EXTENSIONS, to fix a coreutils bootstrap failure
7129         reported by Jim Meyering.  All uses of cache variables renamed
7130         to match Autoconf's.
7131         (gl_USE_SYSTEM_EXTENSIONS): New macro, which simply requires
7132         the other one.
7133
7134         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH):
7135         Fix misspelling in diagnostic.
7136
7137 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
7138
7139         * lib/mkdir-p.c (HAVE_FCHMOD): Define to false if not already
7140         defined.  Problem reported by Matthew Woehlke.
7141
7142         * lib/inttypes_.h (_LONG_LONG_FORMAT_PREFIX): New macro.
7143         Add support for Tandem NonStop R series.
7144         (_PRI64_PREFIX, _PRIu64_PREFIX, _SCN64_PREFIX, _SCNu64_PREFIX):
7145         Use new macro.
7146
7147         * lib/rename-dest-slash.c: Include stdbool.h but not string.h.
7148         (has_trailing_slash): Omit size arg; all callers changed.
7149         Omit 'inline', since it doesn't help performance and we'd
7150         need to configure it.
7151         Don't count //, ///, etc. as having a trailing slash.
7152         As a side effect, this removes a C99ism reported by Matthew Woehlke.
7153         (rpl_rename_dest_slash): On failure, use rename's errno rather
7154         than (in some cases) an incorrect or junk errno.
7155         Simplify code by removing need to compute length; this does
7156         cause it to make two passes instead of one over the file name,
7157         but it's worth it.
7158
7159         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Undo previous
7160         change, since Autoconf's version may no longer be appropriate now
7161         that we are using CVS Autoconf's version.  Add support for Tandem.
7162
7163 2006-10-11  Paul Eggert  <eggert@cs.ucla.edu>
7164             Bruno Haible  <bruno@clisp.org>
7165
7166         * lib/allocsa.h (sa_alignment_longlong, sa_alignment_max): Test
7167         HAVE_LONG_LONG_INT instead of HAVE_LONG_LONG.
7168         * m4/allocsa.m4 (gl_ALLOCSA): Invoke AC_TYPE_LONG_LONG_INT instead of
7169         gl_AC_TYPE_LONG_LONG.
7170
7171         * lib/printf-args.h (arg_type, argument): Test HAVE_LONG_LONG_INT
7172         instead of HAVE_LONG_LONG.
7173         * lib/printf-args.c (printf_fetchargs): Likewise.
7174         * lib/printf-parse.c (PRINTF_PARSE): Likewise.
7175         * lib/vasnprintf.c (VASNPRINTF): Likewise.
7176         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_ARGS, gl_PREREQ_PRINTF_PARSE,
7177         gl_PREREQ_VASNPRINTF): Invoke AC_TYPE_LONG_LONG_INT instead of
7178         gl_AC_TYPE_LONG_LONG.
7179
7180 2006-10-11  Bruno Haible  <bruno@clisp.org>
7181
7182         * m4/longlong.m4: Add comments.
7183         * m4/ulonglong.m4: Likewise.
7184
7185 2006-10-10  Bruno Haible  <bruno@clisp.org>
7186
7187         Make it possible to #define stpcpy, strdup to aliases.
7188         * lib/stpcpy.c (stpcpy) [!_LIBC]: Don't undefine.
7189         * lib/strdup.c (strdup) [!_LIBC]: Don't undefine.
7190
7191 2006-10-10  Bruno Haible  <bruno@clisp.org>
7192
7193         Make it possible to #define gcd to an alias.
7194         * lib/gcd.c: Include config.h.
7195
7196 2006-10-10  Bruno Haible  <bruno@clisp.org>
7197
7198         Make it possible to #define c_isascii to an alias.
7199         * lib/c-ctype.h: Don't define the macros if NO_C_CTYPE_MACROS is
7200         defined. Undefine the macros before defining them, to avoid gcc
7201         warnings.
7202         * lib/c-ctype.c: Include config.h. Don't undefine the macros; instead,
7203         define NO_C_CTYPE_MACROS early.
7204
7205 2006-10-10  Bruno Haible  <bruno@clisp.org>
7206
7207         Make it possible to #define set_program_name to an alias.
7208         * lib/progname.c: Don't undefine set_program_name; instead, undefine
7209         ENABLE_RELOCATABLE early.
7210
7211 2006-10-10  Paul Eggert  <eggert@cs.ucla.edu>
7212
7213         Port to Tandem NSK OSS, which has 64-bit signed int but at most
7214         32-bit unsigned int.  Problem reported by Matthew Woehlke in:
7215         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00062.html
7216         More generally, don't assume that 64-bit signed int is available
7217         if unsigned int is, and vice versa.
7218         * lib/inttypes_.h (_PRIu64_PREFIX, _SCNu64_PREFIX): Depend on
7219         unsigned symbols, not on their signed counterparts.
7220         * lib/stdint_.h (uint64_t, uint_least64_t, uint_fast64_t, uintmax_t):
7221         (UINT64_MAX, UINT_LEAST64_MAX, UINT_FAST64_MAX, UINTMAX_MAX):
7222         (UINT64_C, UINTMAX_C):
7223         Likewise.
7224         * lib/strtoimax.c (strtoll): Depend on signed symbols, not their
7225         unsigned counterparts.
7226         (Have_long_long, Unsigned): New macros.
7227         (Int): Renamed from INT.
7228         (strtoimax): Use the new macros.
7229         * m4/stdint.m4 (gl_STDINT_H): Require AC_TYPE_UNSIGNED_LONG_LONG_INT
7230         and substitute HAVE_UNSIGNED_LONG_LONG_INT.
7231         * modules/inttypes (inttypes.h): Substitute
7232         HAVE_UNSIGNED_LONG_LONG_INT.
7233         * modules/stdint (stdint.h): Likewise.
7234         (Files): Add m4/ulonglong.m4.
7235
7236 2006-10-10  Bruno Haible  <bruno@clisp.org>
7237
7238         Fix a gcc -Wshadow warning.
7239         * lib/gl_anyhash_list2.h (hash_resize): Rename local variable 'index'
7240         to 'bucket'.
7241         * lib/gl_anylinked_list2.h (gl_linked_search_from_to,
7242         gl_linked_indexof_from_to): Likewise.
7243         * lib/gl_linkedhash_list.c (add_to_bucket, remove_from_bucket):
7244         Likewise.
7245         * lib/gl_anytreehash_list1.h (add_to_bucket, remove_from_bucket):
7246         Likewise.
7247         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Likewise.
7248         Reported by Eric Blake.
7249
7250 2006-10-09  Paul Eggert  <eggert@cs.ucla.edu>
7251
7252         * lib/filemode.h [HAVE_DECL_STRMODE]: Include unistd.h too,
7253         for NetBSD.  Problem reported by Bruno Haible.
7254
7255 2006-10-09  Jim Meyering  <jim@meyering.net>
7256
7257         * lib/lchown.c: Include <sys/stat.h> before "stat-macros.h".
7258         Patch from Bruno Haible.
7259
7260 2006-10-09  Jim Meyering  <jim@meyering.net>
7261
7262         * lib/fts-cycle.c (leave_dir): When "leaving" a top level directory due
7263         to FTS_SKIP, don't copy the parent's uninitialized dev/ino values.
7264         Trigger with e.g., mkdir d && valgrind ./chmod u+rwx d d
7265
7266 2006-10-08  Paul Eggert  <eggert@cs.ucla.edu>
7267
7268         Don't include <config.h> twice; this doesn't work in some cases,
7269         e.g., when config.h has "#define intmax_t long long int" and
7270         we include <config.h>, <inttypes.h>, <config.h> in that order.
7271         Problem reported by Matthew Woehlke in:
7272         http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00073.html
7273         * lib/fprintftime.c: Don't include config.h or fprintftime.h.
7274         * lib/fts-cycle.c: Don't include config.h.
7275         * lib/strftime.c: Include fprintftime.h if FPRINTFTIME is defined.
7276         * lib/xstrtoimax.c: Remove copyright notice since it's short tnow.
7277         Don't include config.h or xstrtol.h.  Define STRTOL_T_MINIMUM
7278         and STRTOL_T_MAXIMUM unconditionally, since we now assume gnulib
7279         inttypes.h.
7280         * lib/xstrtoumax.c: Likewise.
7281         * lib/xstrtol.c: Include config.h and xstrtol.h after defining
7282         __strtol and the like, so that this module is more like its siblings.
7283         (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [! defined STRTOL_T_MINIMUM]:
7284         Remove; no longer needed now that we assume gnulib inttypes.h.
7285
7286 2006-10-08  Bruno Haible  <bruno@clisp.org>
7287
7288         * doc/gnulib-tool.texi: Emphasize the drawbacks of the --symlink
7289         option.
7290
7291 2006-10-07  Jim Meyering  <jim@meyering.net>
7292
7293         * modules/inttypes (inttypes.h): Revert what seems to have been
7294         an inadvertent part of today's change: use "|", not "/" in the
7295         substitution for the "/"-containing string, $(ABSOLUTE_INTTYPES_H).
7296
7297 2006-10-07  Bruno Haible  <bruno@clisp.org>
7298
7299         * modules/sublist: New file.
7300
7301 2006-10-07  Bruno Haible  <bruno@clisp.org>
7302
7303         * modules/alloca-opt (alloca.h): Add a "DO NOT EDIT" comment.
7304         * modules/argz (argz.h): Likewise.
7305         * modules/arpa_inet (arpa/inet.h): Likewise.
7306         * modules/byteswap (byteswap.h): Likewise.
7307         * modules/configmake (configmake.h): Likewise.
7308         * modules/fcntl (fcntl.h): Likewise.
7309         * modules/fnmatch (fnmatch.h): Likewise.
7310         * modules/getopt (getopt.h): Likewise.
7311         * modules/glob (glob.h): Likewise.
7312         * modules/inttypes (inttypes.h): Likewise.
7313         * modules/netinet_in (netinet/in.h): Likewise.
7314         * modules/poll (poll.h): Likewise.
7315         * modules/stdbool (stdbool.h): Likewise.
7316         * modules/stdint (stdint.h): Likewise.
7317         * modules/sys_select (sys/select.h): Likewise.
7318         * modules/sys_socket (sys/socket.h): Likewise.
7319         * modules/sys_stat (sys/stat.h): Likewise.
7320         * modules/sysexits (sysexits.h): Likewise.
7321         * modules/unistd (unistd.h): Likewise.
7322         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
7323         Add a "DO NOT EDIT" comment to the generated file.
7324         (func_import): Likewise for gnulib-comp.m4.
7325
7326 2006-10-07  Bruno Haible  <bruno@clisp.org>
7327
7328         * lib/gl_sublist.h: New file.
7329         * lib/gl_sublist.c: New file.
7330
7331 2006-10-06  Paul Eggert  <eggert@cs.ucla.edu>
7332
7333         * lib/mkancesdirs.c (mkancesdirs): Pass to MAKE_DIR both the full file
7334         name (relative to the original working directory) and the file
7335         name component (relative to the temporary working directory).  All
7336         callers changed.
7337         * lib/mkancesdirs.h (mkancesdirs): Adjust prototype to match.
7338         * lib/mkdir-p.c (make_dir_parents): Likewise.
7339         * lib/mkdir-p.h (make_dir_parents): Likewise.
7340
7341 2006-10-06  Eric Blake  <ebb9@byu.net>
7342
7343         Define several macros for use by the clean-temp module.
7344         * m4/close-stream.m4 (gl_CLOSE_STREAM): Define GNULIB_CLOSE_STREAM.
7345         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Define GNULIB_FCNTL_SAFER.
7346         * m4/stdio-safer.m4 (gl_FOPEN_SAFER): Define GNULIB_FOPEN_SAFER.
7347
7348         * lib/clean-temp.h (close_stream_temp): New declaration.
7349         * lib/clean-temp.c (includes): Pull in headers according to what
7350         other modules are in use.
7351         (close_stream_temp) [GNULIB_CLOSE_STREAM]: New function.
7352
7353 2006-10-06  Bruno Haible  <bruno@clisp.org>
7354
7355         * lib/javacomp.c (write_temp_file): Use fopen_temp, fwriteerror_temp
7356         instead of fopen, fwriteerror.
7357
7358 2006-10-06  Bruno Haible  <bruno@clisp.org>
7359
7360         * lib/clean-temp.h (cleanup_temp_file, cleanup_temp_subdir,
7361         cleanup_temp_dir_contents, cleanup_temp_dir): Change return type to
7362         int.
7363         * lib/clean-temp.c (do_unlink, do_rmdir, cleanup_temp_file,
7364         cleanup_temp_subdir, cleanup_temp_dir_contents, cleanup_temp_dir):
7365         Return an error indicator.
7366         Suggested by Eric Blake.
7367
7368 2006-10-06  Bruno Haible  <bruno@clisp.org>
7369
7370         * lib/clean-temp.c (PATH_MAX): Provide a fallback for GNU Hurd.
7371         Reported by Eric Blake.
7372
7373 2006-10-06  Bruno Haible  <bruno@clisp.org>
7374
7375         * modules/closeout (Description): Mention stderr too.
7376
7377 2006-10-06  Bruno Haible  <bruno@clisp.org>
7378         and Paul Eggert  <eggert@cs.ucla.edu>
7379
7380         * lib/closeout.c (close_stdout): Also close stderr.
7381         * lib/closeout.h: Update comment.
7382
7383 2006-10-05  Paul Eggert  <eggert@cs.ucla.edu>
7384
7385         Fix some Darwin-7.9.0 porting problems reported by Bruno Haible in
7386         <http://lists.gnu.org/archive/html/bug-coreutils/2006-10/msg00063.html>.
7387         * lib/dirchownmod.c: Include lchown.h.
7388         * lib/lchown.c: Don't include files that lchown.h now includes.
7389         Don't declare chown, since lchown.h now does that.
7390         * lib/lchown.h: Include errno.h, sys/types.h, unistd.h.
7391         (lchown): Define to rpl_chown if lchown is declared but
7392         does not exist.  Declare using a prototype if lchown is not
7393         declared.  Add a copyright notice.
7394         * lib/mkstemp.h: Include <unistd.h>.
7395         * lib/openat.c: Include lchown.h.
7396
7397         * lib/fcntl_.h (O_NOFOLLOW): Don't depend on O_NOFOLLOW_IS_INEFFECTIVE;
7398         we now test for that separately.
7399         * lib/fts.c (fts_safe_changedir): Inspect HAVE_WORKING_O_NOFOLLOW
7400         rather than O_NOFOLLOW, when testing whether it's possible to
7401         avoid a race condition reliably.
7402         * lib/savewd.c (savewd_chdir): Likewise.
7403
7404         Remove macros that are no longer needed now that stdint.h is
7405         reliable.
7406         * lib/fsusage.c (UINTMAX_MAX): Remove.
7407         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Remove.
7408         * lib/utimecmp.c (SIZE_MAX): Remove.
7409
7410         * m4/lchown.m4 (gl_FUNC_LCHOWN): Check whether lchown is declared.
7411
7412         * m4/fcntl_h.m4 (gl_FCNTL_H): Define HAVE_WORKING_O_NOFOLLOW instead
7413         of O_NOFOLLOW_IS_INEFFECTIVE.  Define HAVE_WORKING_O_NOATIME if
7414         O_NOATIME works.
7415
7416 2006-10-05  Bruno Haible  <bruno@clisp.org>
7417
7418         * lib/gl_list.h (gl_sortedlist_search_from_to,
7419         gl_sortedlist_indexof_from_to): New declarations.
7420         (gl_list_implementation): New fields sortedlist_search_from_to,
7421         sortedlist_indexof_from_to.
7422         (gl_sortedlist_search_from_to, gl_sortedlist_indexof_from_to): New
7423         inline functions.
7424         * lib/gl_list.c (gl_sortedlist_search_from_to,
7425         gl_sortedlist_indexof_from_to): New functions.
7426         * lib/gl_array_list.c (gl_array_sortedlist_indexof_from_to): New
7427         function.
7428         (gl_array_sortedlist_indexof, gl_array_sortedlist_search): Use it.
7429         (gl_array_sortedlist_search_from_to): New function.
7430         (gl_array_list_implementation): Update.
7431         * lib/gl_carray_list.c (gl_carray_sortedlist_indexof_from_to): New
7432         function.
7433         (gl_carray_sortedlist_indexof, gl_carray_sortedlist_search): Use it.
7434         (gl_carray_sortedlist_search_from_to): New function.
7435         (gl_carray_list_implementation): Update.
7436         * lib/gl_anylinked_list2.h (gl_linked_sortedlist_search_from_to,
7437         gl_linked_sortedlist_indexof_from_to): New functions.
7438         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
7439         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
7440         * lib/gl_anytree_list2.h (gl_tree_sortedlist_search_from_to,
7441         gl_tree_sortedlist_indexof_from_to): New functions.
7442         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
7443         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
7444         Update.
7445         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
7446         * lib/gl_rbtreehash_list.c (gl_avltreehash_list_implementation):
7447         Update.
7448
7449 2006-10-05  Bruno Haible  <bruno@clisp.org>
7450
7451         * lib/gl_list.h (gl_list_search_from, gl_list_search_from_to,
7452         gl_list_indexof_from, gl_list_indexof_from_to): New declarations.
7453         (struct gl_list_implementation): Add fields search_from_to,
7454         indexof_from_to. Remove fields search, indexof.
7455         (gl_list_search): Use the search_from_to method.
7456         (gl_list_search_from, gl_list_search_from_to): New functions.
7457         (gl_list_indexof): Use the indexof_from_to method.
7458         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
7459         * lib/gl_list.c (gl_list_search): Use the search_from_to method.
7460         (gl_list_search_from, gl_list_search_from_to): New functions.
7461         (gl_list_indexof): Use the indexof_from_to method.
7462         (gl_list_indexof_from, gl_list_indexof_from_to): New functions.
7463         * lib/gl_array_list.c (gl_array_indexof_from_to): Renamed from
7464         gl_array_indexof. Add start_index, end_index arguments.
7465         (gl_array_search_from_to): Renamed from gl_array_search. Add
7466         start_index, end_index arguments.
7467         (gl_array_remove, gl_array_list_implementation): Update.
7468         * lib/gl_carray_list.c (gl_carray_indexof_from_to): Renamed from
7469         gl_carray_indexof. Add start_index, end_index arguments.
7470         (gl_carray_search_from_to): Renamed from gl_carray_search. Add
7471         start_index, end_index arguments.
7472         (gl_carray_remove, gl_carray_list_implementation): Update.
7473         * lib/gl_anylinked_list2.h (gl_linked_search_from_to): Renamed from
7474         gl_linked_search. Add start_index, end_index arguments.
7475         (gl_linked_indexof_from_to): Renamed from gl_linked_indexof. Add
7476         start_index, end_index arguments.
7477         (gl_linked_remove): Update.
7478         * lib/gl_linked_list.c (gl_linked_list_implementation): Update.
7479         * lib/gl_linkedhash_list.c (gl_linkedhash_list_implementation): Update.
7480         * lib/gl_anytree_list1.h (iterstack_item_t): Change type of 'rightp'
7481         field to 'size_t'.
7482         * lib/gl_anytree_list2.h (gl_tree_search_from_to): Renamed from
7483         gl_tree_search. Add start_index, end_index arguments.
7484         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
7485         start_index, end_index arguments.
7486         (gl_tree_remove): Update.
7487         * lib/gl_avltree_list.c (gl_avltree_list_implementation): Update.
7488         * lib/gl_rbtree_list.c (gl_rbtree_list_implementation): Update.
7489         * lib/gl_anytreehash_list1.h (compare_position_threshold): New
7490         function.
7491         * lib/gl_anytreehash_list2.h (gl_tree_search_from_to): Renamed from
7492         gl_tree_search. Add start_index, end_index arguments.
7493         (gl_tree_indexof_from_to): Renamed from gl_tree_indexof. Add
7494         start_index, end_index arguments.
7495         * lib/gl_avltreehash_list.c (gl_avltreehash_list_implementation):
7496         Update.
7497         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Update.
7498
7499 2006-10-05  Bruno Haible  <bruno@clisp.org>
7500
7501         * modules/fwriteerror (configure.ac): Define GNULIB_FWRITEERROR.
7502
7503         * lib/clean-temp.h (open_temp, fopen_temp, close_temp, fclose_temp,
7504         fwriteerror_temp): New declarations.
7505         * lib/clean-temp.c (uintptr_t): Provide fallback definition.
7506         (descriptors): New variable.
7507         (cleanup): First, close the descriptors.
7508         (register_fd, unregister_fd, open_temp, fopen_temp, close_temp,
7509         fclose_temp, fwriteerror_temp): New functions.
7510
7511 2006-10-04  Jim Meyering  <jim@meyering.net>
7512
7513         * lib/fts.c (fts_open): Tiny comment change.
7514
7515 2006-10-04  Bruno Haible  <bruno@clisp.org>
7516
7517         Make it possible to invoke AC_GNU_SOURCE after gl_LOCK_EARLY.
7518         * m4/lock.m4 (gl_LOCK_EARLY_BODY): New macro, extracted code from
7519         gl_LOCK_BODY.
7520         (gl_LOCK_EARLY): Require gl_LOCK_EARLY_BODY, not gl_LOCK_BODY.
7521         (gl_LOCK_BODY): Remove settings of CPPFLAGS, now done in
7522         gl_LOCK_EARLY_BODY.
7523         (gl_LOCK): Require gl_LOCK_BODY.
7524
7525 2006-10-04  Bruno Haible  <bruno@clisp.org>
7526
7527         * lib/gl_oset.h (gl_setelement_threshold_fn): New type.
7528         (gl_oset_search_atleast): New declaration.
7529         (struct gl_oset_implementation): Add field 'search_atleast'.
7530         (gl_oset_search_atleast): New inline function.
7531         * lib/gl_oset.c (gl_oset_search_atleast): New function.
7532         * lib/gl_array_oset.c (gl_array_search_atleast): New function.
7533         (gl_array_oset_implementation): Update.
7534         * lib/gl_anytree_oset.h (gl_tree_search_atleast): New function.
7535         * lib/gl_avltree_oset.c (gl_avltree_oset_implementation): Update.
7536         * lib/gl_rbtree_oset.c (gl_rbtree_oset_implementation): Update.
7537
7538 2006-10-04  Bruno Haible  <bruno@clisp.org>
7539
7540         * lib/fatal-signal.c (fatal_signals) [WOE32]: Add the SIGBREAK signal.
7541
7542 2006-10-03  Bruno Haible  <bruno@clisp.org>
7543
7544         * lib/gl_rbtreehash_list.c (gl_rbtreehash_list_implementation): Renamed
7545         from gl_avltreehash_list_implementation.
7546
7547 2006-10-03  Bruno Haible  <bruno@clisp.org>
7548
7549         * lib/gl_oset.c (gl_oset_add): Fix return type.
7550
7551 2006-10-02  Paolo Bonzini  <bonzini@gnu.org>  (tiny change)
7552
7553         * lib/quotearg.c (mbstate_t) [!HAVE_MBRTOWC]: #define to int.
7554
7555 2006-10-02  Eric Blake  <ebb9@byu.net>
7556
7557         * modules/strnlen (Depends-on): Add extensions.
7558
7559 2006-10-02  Eric Blake  <ebb9@byu.net>
7560
7561         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use autoconf's
7562         definition in 2.60+.
7563
7564 2006-10-02  Dmitry V. Levin  <ldv@altlinux.org>
7565
7566         * lib/fts.c (fts_close, fts_build, fts_palloc): Remove redundant
7567         checks.
7568
7569 2006-10-02  Bruno Haible  <bruno@clisp.org>
7570
7571         * gnulib-tool (func_emit_lib_Makefile_am): Don't add no-dependencies
7572         to the AUTOMAKE_OPTIONS.
7573         Reported by Jim Meyering.
7574
7575 2006-09-29  Paul Eggert  <eggert@cs.ucla.edu>
7576
7577         Work around bug in Solaris 10 /proc file system:
7578         /proc/self/fd/NNN/.. isn't the parent directory of
7579         the directory whose file descriptor is NNN.  This needs to
7580         be worked around at run time, not compile time, since a
7581         program might be built on Solaris 8, where things work, and
7582         run on Solaris 10.
7583         * lib/openat-priv.h (BUILD_PROC_NAME): Remove.  All callers changed
7584         to use the following interface instead:
7585         (OPENAT_BUFFER_SIZE): New macro.
7586         (openat_proc_name): New function.
7587         * lib/at-func.c (AT_FUNC_NAME): Adjust to above changes.
7588         * lib/openat.c (openat_permissive, openat_needs_fchdir, fdopendir):
7589         Likewise.
7590         * lib/openat-proc.c: New file.
7591         * modules/openat (Files): Add lib/openat-proc.c.
7592         (Depends-on): Add same-inode, stdbool.
7593         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBOBJ(openat-proc).
7594
7595 2006-09-29  Bruno Haible  <bruno@clisp.org>
7596
7597         * lib/fwriteerror.h (fwriteerror_no_ebadf): New declaration.
7598         * lib/(do_fwriteerror): Renamed from fwriteerror. Add ignore_ebadf
7599         argument. Set stdout_closed before testing for ferror, not after.
7600         (fwriteerror, fwriteerror_no_ebadf): New functions.
7601
7602 2006-09-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7603
7604         * m4/intmax.m4 (gt_TYPE_INTMAX_T): Avoid unused variables warning.
7605
7606 2006-09-28  Paolo Bonzini  <bonzini@gnu.org>
7607
7608         * lib/poll.c (rpl_poll) [__APPLE__]: Use FIONREAD instead of MSG_PEEK.
7609         * m4/poll.m4: Look for sys/ioctl.h and sys/filio.h.
7610
7611 2006-09-28  Jim Meyering  <jim@meyering.net>
7612
7613         * lib/mkdir-p.c: Include "dirchownmod.h", not "dirchownmod.c".
7614         Include <unistd.h>.
7615
7616 2006-09-28  Bruno Haible  <bruno@clisp.org>
7617
7618         * modules/avltreehash-list (Depends-on): Add stdint, remove size_max.
7619         * modules/linkedhash-list (Depends-on): Likewise.
7620         * modules/rbtreehash-list (Depends-on): Likewise.
7621
7622 2006-09-28  Bruno Haible  <bruno@clisp.org>
7623
7624         * lib/strndup.h: Simplify the redefinition of strndup.
7625         (_GL_CONCAT, _GL_XCONCAT, __STRNDUP_ID): Remove macros.
7626         * m4/strndup.m4 (gl_FUNC_STRNDUP): Don't define __STRNDUP_PREFIX.
7627
7628 2006-09-28  Bruno Haible  <bruno@clisp.org>
7629
7630         * lib/gl_avltreehash_list.c: Include <stdint.h> instead of size_max.h.
7631         * lib/gl_linkedhash_list.c: Likewise.
7632         * lib/gl_rbtreehash_list.c: Likewise.
7633
7634 2006-09-27  Paul Eggert  <eggert@cs.ucla.edu>
7635
7636         * lib/canon-host.c (canon_host_r): Work around bug in Darwin 7.9.0
7637         getaddrinfo.
7638
7639         * lib/__fpending.h: Don't include <stdio_ext.h> unless
7640         HAVE_DECL___FPENDING.  This avoids a bug with lsbcc, where
7641         it causes <stdio_ext.h> to cause a compile-time error.
7642         Problem reported by Nelson H. F. Beebe.
7643         * lib/getpass.c: Likewise, except for HAVE_DECL___FSETLOCKING instead
7644         of HAVE_DECL___PENDING.
7645
7646         * m4/fpending.m4 (gl_FUNC_FPENDING): Check for stdio_ext at most once.
7647         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for __fsetlocking's
7648         declaration.
7649
7650 2006-09-27  Jim Meyering  <jim@meyering.net>
7651
7652         This file could end up with a definition for a function
7653         named __strndup, rather than rpl_strndup on a system with
7654         incomplete weak_alias support.
7655         * lib/strndup.c (strndup): Rename from __strndup.
7656         Remove #defines that used to map __strndup to strndup.
7657         Don't use K&R prototypes.
7658         Remove LIBC-related code, since this file is not sync'd with glibc.
7659         * lib/strndup.h: Revamp, accordingly.
7660         * m4/strndup.m4: Modernize.
7661
7662 2006-09-26  Paul Eggert  <eggert@cs.ucla.edu>
7663
7664         * modules/savewd (Depends-on): Add 'raise'.
7665         * lib/savewd.c: Include <signal.h>, for 'raise'.
7666
7667 2006-09-26  Jim Meyering  <jim@meyering.net>
7668
7669         * m4/acl.m4 (AC_FUNC_ACL): Disable ACL support altogether
7670         when we detect Darwin 8.7.0's acl_get_file bug.
7671         Rearrange to perform the new (below) run-test while $LIBS
7672         contains any acl-related library.  Set USE_ACL at the end.
7673         (gl_ACL_GET_FILE): New function.
7674
7675 2006-09-26  Eric Blake  <ebb9@byu.net>
7676
7677         * lib/verror.c: Include <config.h> unconditionally.
7678
7679 2006-09-25  Paul Eggert  <eggert@cs.ucla.edu>
7680
7681         * modules/clock-time (Maintainer): Add self.
7682         * modules/getlogin_r (Depends-on): Add extensions.
7683
7684 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7685
7686         * modules/clock-time: New module.
7687         * modules/nanosleep (Depends-on): Add clock-time.
7688         * modules/gethrxtime (Depends-on): Likewise.
7689         * modules/gettime (Depends-on): Likewise.
7690         * modules/settime (Depends-on): Likewise.
7691
7692         * modules/fts-lgpl: Depend on openat.
7693         * modules/mkancesdirs: Depend on savewd.
7694         * modules/mkdir-p: Likewise.
7695
7696 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7697
7698         * m4/host-os.m4 (gl_HOST_OS): Require AC_CANONICAL_HOST.
7699
7700         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Rename cache variable from
7701         `gl_have_arbitrary_file_name_length_limit' to
7702         `gl_cv_have_arbitrary_file_name_length_limit', so that caching
7703         actually works between configure runs.
7704
7705 2006-09-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7706             Bruno Haible  <bruno@clisp.org>
7707
7708         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Include <string.h>.
7709
7710 2006-09-25  Jim Meyering  <jim@meyering.net>
7711
7712         * m4/fcntl_h.m4 (gl_FCNTL_H): Fix typo in test for failed open.
7713         This typo caused coreutils/tests/dd/misc to fail on Darwin 8.7.0.
7714
7715 2006-09-25  Eric Blake  <ebb9@byu.net>
7716
7717         * gnulib-tool (func_import, func_create_testdir): Fix typos in
7718         exec's in 2006-09-18 patch when shuffling fds.
7719
7720 2006-09-25  Bruno Haible  <bruno@clisp.org>
7721
7722         * m4/getloadavg.m4 (gl_GETLOADAVG): Fix directory in error message.
7723         Reported by Jim Meyering.
7724
7725 2006-09-24  Jim Meyering  <jim@meyering.net>
7726
7727         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Don't use '>' to
7728         compare a pointer against a literal "0".  That caused failures with
7729         at least HP-UX's hpcc.
7730
7731 2006-09-22  Simon Josefsson  <jas@extundo.com>
7732
7733         * modules/gc-sha1:
7734         * modules/gc-md4:
7735         * modules/gc-hmac-sha1:
7736         * modules/gc-hmac-md5:
7737         * modules/gc-des:
7738         * modules/gc-arcfour: Distribute more files.
7739
7740 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7741
7742         * lib/gl_anylinked_list2.h [lint] (gl_linked_iterator)
7743         (gl_linked_iterator_from_to): Initialize struct completely.
7744         * lib/gl_anytree_list2.h [lint] (gl_tree_iterator): Likewise.
7745         (gl_tree_iterator_from_to): Likewise
7746         * lib/gl_anytree_oset.h [lint] (gl_tree_iterator): Likewise.
7747         * lib/gl_array_list.c [lint] (gl_array_iterator)
7748         (gl_array_iterator_from_to): Likewise.
7749         * lib/gl_array_oset.c [lint] (gl_array_iterator): Likewise.
7750         * lib/gl_carray_list.c [lint] (gl_carray_iterator)
7751         (gl_carray_iterator_from_to): Likewise.
7752
7753         * lib/gc-gnulib.c [GC_USE_HMAC_SHA1]: include hmac.h for hmac_sha1.
7754         * lib/md4.c (md4_process_block): Remove unused variable.
7755         * lib/rijndael-api-fst.c (rijndaelBlockDecrypt): GCC suggests
7756         parentheses for clarity.
7757
7758 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7759
7760         * modules/bison-i18n (Depends-on): Add gettext.
7761
7762 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7763
7764         * m4/fsusage.m4 (gl_STATFS_TRUNCATES): Avoid unused variable.
7765         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): Likewise.
7766         * m4/jm-winsz1.m4 (gl_HEADER_TIOCGWINSZ_IN_TERMIOS_H): Likewise;
7767         also add missing comma that caused broken test.
7768         * m4/link-follow.m4 (gl_AC_FUNC_LINK_FOLLOWS_SYMLINK): Include
7769         stdlib.h, for `abort'.
7770         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Avoid unused
7771         variables.
7772         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Check for and
7773         include unistd.h if present, for `rmdir'.
7774         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): Avoid unused
7775         variables.
7776         * m4/putenv.m4 (gl_FUNC_PUTENV): Rewrite using AC_RUN_IFELSE, and
7777         in the process include standard headers for prototypes.
7778         * m4/readutmp.m4 (gl_READUTMP): Require AC_GNU_SOURCE, so utmpxname
7779         gets declared on GNU/Linux.
7780         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Check for and include
7781         unistd.h, for `rmdir'.
7782         * m4/time_r.m4 (gl_TIME_R): Avoid unused variables.
7783
7784         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Avoid expression that is
7785         always true.
7786         * m4/strndup.m4 (gl_FUNC_STRNDUP): include stdlib.h, for `free'.
7787
7788         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Avoid gcc -Wall warnings.
7789
7790 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7791
7792         * gnulib-tool (func_version): Create output all at once.  This
7793         may help avoid triggering unnecessary SIGPIPEs, and at any
7794         rate it doesn't hurt.
7795
7796 2006-09-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7797             Bruno Haible  <bruno@clisp.org>
7798
7799         * m4/lock.m4 (gl_LOCK_BODY): Avoid unused variables warning.
7800         * m4/mbswidth.m4 (gl_MBSWIDTH): Likewise.
7801         * m4/signed.m4 (bh_C_SIGNED): Likewise.
7802
7803         * m4/vasprintf.m4 (gl_PREREQ_VASPRINTF_H): New macro.
7804         (gl_FUNC_VASPRINTF): Invoke it.
7805
7806 2006-09-22  Bruno Haible  <bruno@clisp.org>
7807
7808         * m4/getloadavg.m4 (gl_GETLOADAVG): Expect the directory of
7809         getloadavg.c as first argument.
7810
7811 2006-09-22  Bruno Haible  <bruno@clisp.org>
7812
7813         * gnulib-tool (func_import, func_create_testdir): Set gl_source_base
7814         at the beginning of the gl_INIT macro.
7815         * modules/getloadavg (configure.ac): Pass $gl_source_base to
7816         gl_GETLOADAVG.
7817
7818 2006-09-22  Bruno Haible  <bruno@clisp.org>
7819
7820         * gnulib-tool (func_create_megatestdir): Don't include the config-h
7821         module.
7822         Suggested by Ralf Wildenhues.
7823
7824 2006-09-20  Paul Eggert  <eggert@cs.ucla.edu>
7825
7826         Import this patch from libc:
7827
7828         2006-09-06  Jakub Jelinek  <jakub@redhat.com>
7829
7830         * lib/regex_internal.c (re_string_reconstruct): Handle
7831         offset < pstr->valid_raw_len && pstr->offsets_needed case.
7832         Ensure no bytes read before raw_mbs array.  Pass a saved copy of
7833         pstr->valid_len - 1 rather than pstr->valid_raw_len - 1 to
7834         re_string_context_at.
7835
7836         * m4/regex.m4 (gl_REGEX): Check for locale.h, since the test
7837         now requires it.
7838         (gl_PREREQ_REGEX): Don't check for locale.h any more, since
7839         gl_REGEX now does it for us.
7840         (gl_REGEX): Add test taken from
7841         http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html.
7842
7843         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Require AC_SYS_LARGEFILE.
7844         Check that large offsets work.  Modernize Autoconf usages.
7845         Prefer "yes" to mean a good thing rather than a bad.
7846         Don't put "#define mkstemp" in config.h, as this might interfere
7847         with standard system headers that "#define mkstemp mkstemp64".
7848
7849         * modules/mkstemp (Depends-on): Add extensions, so that
7850         mkstemp is visible on some platforms.
7851         (Makefile.am): Add mkstemp.h to EXTRA_DIST.
7852         (Include): Change to "mkstemp.h" from <stdlib.h>.
7853         (Files): Add mkstemp.h.
7854
7855         * lib/mkstemp.h: New file, since some standard headers
7856         #define mkstemp.
7857         * lib/mkstemp.c: Revamp to put the !_LIBC code together.
7858         Include "mkstemp.h".
7859         Make the _LIBC code resemble glibc original more,
7860         e.g., use K&R style.
7861         * lib/mkstemp-safer.c: Include "mkstemp.h" instead of <stdlib.h>.
7862         (mkstemp): Remove, since mkstemp.h does this for us.
7863         * lib/stdlib--.h: Include mkstemp.h.
7864
7865         Import this patch from libc:
7866
7867         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7868
7869         * lib/tempname.c (__gen_tempname): Change attempts_min
7870         into a macro.  Use preprocessor to decide how to initialize
7871         attempts [Coverity CID 67].
7872
7873 2006-09-20  Bruno Haible  <bruno@clisp.org>
7874
7875         * lib/mkdtemp.c: Import from libc.
7876         2006-04-07  Ulrich Drepper  <drepper@redhat.com>
7877                 * sysdeps/posix/tempname.c (__gen_tempname): Change
7878                 attempts_min into a macro.  Use preprocessor to decide how to
7879                 initialize attempts [Coverity CID 67].
7880         2001-11-27  Paul Eggert  <eggert@twinsun.com>
7881                 * sysdeps/posix/tempname.c (__gen_tempname): Try at least
7882                 ATTEMPTS_MIN or TMP_MAX times, whichever is greater.
7883
7884 2006-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7885
7886         * gnulib-tool (func_exit): New function, to allow to pass the
7887         exit status portably through the trap.  Use everywhere.
7888         (--help, --version): Signal a write error.
7889         (trap): catch SIGPIPE, for write errors.
7890         Exit at the end of the trap, with the correct exit status.
7891
7892 2006-09-19  Karl Berry  <karl@gnu.org>
7893
7894         * doc/gnulib.texi: note about the license texinfo files.
7895
7896 2006-09-19  Eric Blake  <ebb9@byu.net>
7897
7898         * gnulib-tool: Avoid space-tab.
7899
7900 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7901
7902         * lib/getaddrinfo.c (getaddrinfo) [defined HAVE_IPV6]: Fix typo
7903         that prevented coreutils 6.1 from building.  Problem reported
7904         by Petter Reinholdtsen.
7905
7906 2006-09-18  Paul Eggert  <eggert@cs.ucla.edu>
7907
7908         * gnulib-tool (avoidlist): Fix typo that broke options like
7909         --avoid=lock that are used by coreutils bootstrap.
7910
7911 2006-09-18  Mark D. Baushke  <mdb@gnu.org>
7912
7913         * m4/inttypes.m4 (gl_INTTYPES_H): Quote "test" args
7914         more systematically.
7915
7916 2006-09-18  Jim Meyering  <jim@meyering.net>
7917
7918         * lib/savewd.c (savewd_restore): Don't shadow: s/status/child_status/.
7919
7920 2006-09-18  Bruno Haible  <bruno@clisp.org>
7921
7922         * modules/inttypes (Files): Remove m4/inttypes-h.m4.
7923
7924 2006-09-18  Bruno Haible  <bruno@clisp.org>
7925
7926         * m4/inttypes-h.m4 (gl_HEADER_INTTYPES_H): Remove macro.
7927         * m4/inttypes-pri.m4: Require autoconf >= 2.52.
7928         (gt_INTTYPES_PRI): Invoke AC_CHECK_HEADERS on inttypes.h. Test
7929         ac_cv_header_inttypes_h instead of gl_cv_header_inttypes_h.
7930         * m4/gettext.m4: Require autoconf >= 2.52.
7931         (gt_INTL_SUBDIR_CORE): Invoke AC_CHECK_HEADERS on inttypes.h.
7932         * m4/inttypes.m4 (gl_INTTYPES_H): Test ac_cv_header_inttypes_h instead
7933         of gl_cv_header_inttypes_h.
7934
7935 2006-09-18  Bruno Haible  <bruno@clisp.org>
7936
7937         * lib/javaversion.c: Include configmake.h.
7938
7939 2006-09-18  Bruno Haible  <bruno@clisp.org>
7940
7941         * gnulib-tool (func_import, func_create_testdir): Use exec tricks to
7942         avoid that the while loops be executed in a subshell.
7943
7944 2006-09-18  Bruno Haible  <bruno@clisp.org>
7945
7946         * MODULES.html.sh (func_module): Break long lines.
7947         Suggested by Bruce Korb <bkorb@gnu.org>.
7948
7949 2006-09-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7950
7951         Speed up by a factor of 1.12.
7952         * gnulib-tool (nl): New variable.
7953         (func_import): Rewrite include directive extraction to only read each
7954         directive once.
7955
7956 2006-09-17  Bruno Haible  <bruno@clisp.org>
7957
7958         * modules/javaversion (Makefile.am): Remove DEFS setting.
7959         (Depends-on): Add configmake, for PKGDATADIR definition.
7960
7961 2006-09-17  Bruno Haible  <bruno@clisp.org>
7962
7963         * gnulib-tool (func_create_testdir): Rewrite all files at once.
7964
7965 2006-09-17  Bruno Haible  <bruno@clisp.org>
7966
7967         * gnulib-tool (func_append): New function, stolen from libtool.m4.
7968         (func_modules_transitive_closure, func_modules_add_dummy,
7969         func_modules_to_filelist, func_import, func_create_testdir,
7970         func_create_megatestdir, ...): Use it wherever possible.
7971         Suggested by Ralf Wildenhues.
7972
7973 2006-09-16  Karl Berry  <karl@gnu.org>
7974
7975         * doc/fdl.texi (ADDENDUM): switch to @heading from @appendixsubsec,
7976         to avoid sectioning errors.
7977         * doc/lgpl.texi, gpl.texi (Copying): downcase @unnumbered title.
7978         [ifinfo]: blank line after @center-ed titles.
7979         * doc/lgpl.texi (Library Copying): Rename main node to GNU LGPL.
7980         Spell FSF address consistently with others.
7981         (These changes approved by rms.)
7982
7983 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7984
7985         Speed up by a factor of 1.61.
7986         * gnulib-tool (func_modules_transitive_closure): Rewrite to not check
7987         already checked module names again.
7988
7989 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7990
7991         Speed up by a factor of 1.13.
7992         * gnulib-tool (func_import): Rewrite all old_files at once; likewise
7993         for new_files, and the input to func_add_or_update.
7994
7995 2006-09-15  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
7996
7997         * gnulib-tool (func_all_modules, func_modules_to_filelist, func_import,
7998         func_create_testdir, ...): Change 'sort | uniq' to 'sort -u'.
7999
8000 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8001
8002         * modules/mkancesdirs (Depends-on): Add fcntl.
8003         * modules/savewd: New file.
8004         * MODULES.html.sh (File system functions): Add savewd.
8005
8006         * modules/configmake (Makefile.am): Add support for the
8007         Automake-supplied PKGLIBDIR, PKGINCLUDEDIR, PKGDATADIR.
8008
8009 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8010
8011         * m4/savewd.m4: New file.
8012
8013 2006-09-15  Paul Eggert  <eggert@cs.ucla.edu>
8014
8015         * lib/dirchownmod.c: Don't include fcntl.h; no longer needed.
8016         (dirchownmod): New arg FD.  All callers changed.
8017         Use FD rather than opening the directory ourself, as opening is
8018         now the caller's responsibility.
8019         * lib/dirchownmod.h: Likewise.
8020         * lib/mkancesdirs.c: Include <sys/types.h>, for portability to older
8021         hosts that require <sys/types.h> before <sys/stat.h>.  Include
8022         fcntl.h, savewd.h, and unistd.h, not dirname.h and stat-macros.h.
8023         (test_dir): Remove.
8024         (mkancesdirs): Return length of prefix of FILE that has already
8025         been made, or -2 if there is a child doing the work.  Redo
8026         algorithm so that it is O(N) rather than O(N**2).  Optimize away
8027         ".", and treat ".." specially since it might stray back into
8028         already-created areas.  Use a subprocess if necessary.  New arg
8029         WD; all users changed.  MAKE_DIR function should now return 1
8030         if it creates a directory that is not readable.  Return -2 if
8031         a child process is spun off.
8032         * lib/mkancesdirs.h: Include <stddef.h>, for ptrdiff_t.
8033         Adjust signature to match code.
8034         * lib/mkdir-p.c: Include dirname.h, for IS_ABSOLUTE_FILE_NAME.
8035         (make_dir_parents): Use a subprocess if necessary.  New arg WD;
8036         all users changed.
8037         * lib/savewd.c, lib/savewd.h: New files.
8038
8039 2006-09-15  Jim Meyering  <jim@meyering.net>
8040
8041         * modules/rename-dest-slash: New module.
8042         * MODULES.html.sh (posix_compat): Add it here.
8043
8044         * modules/rename: Reflect vb_FUNC_RENAME -> gl_FUNC_RENAME change.
8045
8046 2006-09-15  Jim Meyering  <jim@meyering.net>
8047
8048         * m4/rename-dest-slash.m4 (gl_FUNC_RENAME_TRAILING_DEST_SLASH): New
8049         file.
8050
8051         * m4/rename.m4 (gl_FUNC_RENAME): Rename from vb_FUNC_RENAME.
8052
8053 2006-09-15  Jim Meyering  <jim@meyering.net>
8054
8055         * lib/rename-dest-slash.c (has_trailing_slash): Use
8056         FILE_SYSTEM_PREFIX_LEN, for non-POSIX systems.
8057         (rpl_rename_dest_slash): Perform the cheaper trailing slash
8058         test before testing whether SRC is a directory.
8059         Suggestions from Bruno Haible.
8060
8061         Avoid a warning about an unused variable.
8062         * lib/regex_internal.c (re_dfa_add_node): Move declaration of "type"
8063         into the #ifdef block where it's used.
8064
8065         * lib/rename-dest-slash.c: New file.
8066
8067 2006-09-14  Bruno Haible  <bruno@clisp.org>
8068
8069         * lib/allocsa.c: Include <config.h> unconditionally.
8070         * lib/asnprintf.c: Likewise.
8071         * lib/asprintf.c: Likewise.
8072         * lib/c-strcasecmp.c: Likewise.
8073         * lib/c-strcasestr.c: Likewise.
8074         * lib/c-strncasecmp.c: Likewise.
8075         * lib/c-strstr.c: Likewise.
8076         * lib/classpath.c: Likewise.
8077         * lib/clean-temp.c: Likewise.
8078         * lib/concatpath.c: Likewise.
8079         * lib/copy-file.c: Likewise.
8080         * lib/csharpcomp.c: Likewise.
8081         * lib/csharpexec.c: Likewise.
8082         * lib/execute.c: Likewise.
8083         * lib/fatal-signal.c: Likewise.
8084         * lib/findprog.c: Likewise.
8085         * lib/fwriteerror.c: Likewise.
8086         * lib/gl_array_list.c: Likewise.
8087         * lib/gl_array_oset.c: Likewise.
8088         * lib/gl_avltree_list.c: Likewise.
8089         * lib/gl_avltree_oset.c: Likewise.
8090         * lib/gl_avltreehash_list.c: Likewise.
8091         * lib/gl_carray_list.c: Likewise.
8092         * lib/gl_linked_list.c: Likewise.
8093         * lib/gl_linkedhash_list.c: Likewise.
8094         * lib/gl_list.c: Likewise.
8095         * lib/gl_oset.c: Likewise.
8096         * lib/gl_rbtree_list.c: Likewise.
8097         * lib/gl_rbtree_oset.c: Likewise.
8098         * lib/gl_rbtreehash_list.c: Likewise.
8099         * lib/imaxabs.c: Likewise.
8100         * lib/imaxdiv.c: Likewise.
8101         * lib/javacomp.c: Likewise.
8102         * lib/javaexec.c: Likewise.
8103         * lib/javaversion.c: Likewise.
8104         * lib/linebreak.c: Likewise.
8105         * lib/localcharset.c: Likewise.
8106         * lib/lock.c: Likewise.
8107         * lib/mbchar.c: Likewise.
8108         * lib/mbswidth.c: Likewise.
8109         * lib/mkdtemp.c: Likewise.
8110         * lib/pipe.c: Likewise.
8111         * lib/printf-args.c: Likewise.
8112         * lib/printf-parse.c: Likewise.
8113         * lib/progname.c: Likewise.
8114         * lib/progreloc.c: Likewise.
8115         * lib/readlink.c: Likewise.
8116         * lib/sh-quote.c: Likewise.
8117         * lib/stpcpy.c: Likewise.
8118         * lib/stpncpy.c: Likewise.
8119         * lib/strcasecmp.c: Likewise.
8120         * lib/strcasestr.c: Likewise.
8121         * lib/strcspn.c: Likewise.
8122         * lib/striconv.c: Likewise.
8123         * lib/strncasecmp.c: Likewise.
8124         * lib/strnlen1.c: Likewise.
8125         * lib/strstr.c: Likewise.
8126         * lib/strtok_r.c: Likewise.
8127         * lib/tls.c: Likewise.
8128         * lib/tmpdir.c: Likewise.
8129         * lib/unicodeio.c: Likewise.
8130         * lib/unsetenv.c: Likewise.
8131         * lib/vasnprintf.c: Likewise.
8132         * lib/vasprintf.c: Likewise.
8133         * lib/wait-process.c: Likewise.
8134         * lib/xallocsa.c: Likewise.
8135         * lib/xsetenv.c: Likewise.
8136         * lib/xstriconv.c: Likewise.
8137
8138 2006-09-13  Simon Josefsson  <jas@extundo.com>
8139
8140         * m4/getdate.m4: Don't AC_LIBOBJ([getdate]), automake takes care of
8141         that internally, suggested by Ralf Wildenhues
8142         <Ralf.Wildenhues@gmx.de>.
8143
8144 2006-09-13  Simon Josefsson  <jas@extundo.com>
8145
8146         * gnulib-tool (func_emit_lib_Makefile_am): Use $(LIBOBJS), not
8147         @LIBOBJS@.
8148         Suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
8149
8150 2006-09-13  Paul Eggert  <eggert@cs.ucla.edu>
8151
8152         * lib/_fpending.c: Include <config.h> unconditionally, since we no
8153         longer worry about uses that don't define HAVE_CONFIG_H.
8154         * lib/acl.c, lib/alloca.c, lib/argmatch.c, lib/atexit.c:
8155         * lib/backupfile.c, lib/basename.c, lib/c-stack.c, lib/c-strtod.c:
8156         * lib/calloc.c,lib/ canon-host.c, lib/canonicalize.c, lib/chdir-long.c:
8157         * lib/chdir-safer.c, lib/chown.c, lib/cloexec.c, lib/close-stream.c:
8158         * lib/closeout.c, lib/creat-safer.c, lib/cycle-check.c, lib/diacrit.c:
8159         * lib/dirchownmod.c, lib/dirfd.c, lib/dirname.c, lib/dup-safer.c:
8160         * lib/dup2.c, lib/error.c, lib/euidaccess.c, lib/exclude.c:
8161         * lib/exitfail.c, lib/fchmodat.c, lib/fchown-stub.c, lib/fd-safer.c:
8162         * lib/file-type.c, lib/fileblocks.c, lib/filemode.c, lib/filenamecat.c:
8163         * lib/fnmatch.c, lib/fopen-safer.c, lib/fprintftime.c, lib/free.c:
8164         * lib/fsusage.c, lib/ftruncate.c, lib/fts-cycle.c, lib/fts.c:
8165         * lib/full-write.c, lib/gai_strerror.c, lib/getcwd.c, lib/getdate.y:
8166         * lib/getdomainname.c, lib/getgroups.c, lib/gethostname.c:
8167         * lib/gethrxtime.c, lib/getloadavg.c, lib/getlogin_r.c:
8168         * lib/getndelim2.c, lib/getnline.c, lib/getopt.c, lib/getopt1.c:
8169         * lib/getpass.c, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c:
8170         * lib/getusershell.c, lib/glob.c, lib/group-member.c:
8171         * lib/hard-locale.c, lib/hash-pjw.c, lib/hash.c, lib/human.c:
8172         * lib/idcache.c, lib/inet_ntop.c, lib/inet_pton.c, lib/inttostr.c:
8173         * lib/isdir.c, lib/lchown.c, lib/linebuffer.c, lib/long-options.c:
8174         * lib/lstat.c, lib/malloc.c, lib/md5.c, lib/memcasecmp.c, lib/memchr.c:
8175         * lib/memcmp.c, lib/memcoll.c, lib/memcpy.c, lib/memmove.c:
8176         * lib/memrchr.c, lib/mkancesdirs.c, lib/mkdir-p.c, lib/mkdir.c:
8177         * lib/mkdirat.c, lib/mkstemp-safer.c, lib/mkstemp.c, lib/modechange.c:
8178         * lib/mountlist.c, lib/nanosleep.c, lib/obstack.c, lib/open-safer.c:
8179         * lib/openat-die.c, lib/openat.c, lib/pagealign_alloc.c, lib/physmem.c:
8180         * lib/pipe-safer.c, lib/posixtm.c, lib/posixver.c, lib/putenv.c:
8181         * lib/quote.c, lib/quotearg.c, lib/raise.c, lib/readtokens.c:
8182         * lib/readtokens0.c, lib/readutmp.c, lib/realloc.c, lib/regex.c:
8183         * lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c:
8184         * lib/same.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c:
8185         * lib/settime.c, lib/sha1.c, lib/sig2str.c, lib/snprintf.c:
8186         * lib/strdup.c, lib/strerror.c, lib/strftime.c, lib/stripslash.c:
8187         * lib/strndup.c, lib/strnlen.c, lib/strpbrk.c, lib/strtod.c:
8188         * lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c:
8189         * lib/time_r.c, lib/timegm.c, lib/tmpfile-safer.c, lib/unlinkdir.c:
8190         * lib/userspec.c, lib/utime.c, lib/utimecmp.c, lib/utimens.c:
8191         * lib/version-etc-fsf.c, lib/version-etc.c, lib/xalloc-die.c:
8192         * lib/xgetcwd.c, lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c:
8193         * lib/xnanosleep.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtoimax.c:
8194         * lib/xstrtol.c, lib/xstrtoumax.c, lib/yesno.c:
8195         Likewise.
8196
8197 2006-09-13  Eric Blake  <ebb9@byu.net>
8198
8199         * lib/getopt.c: Fix typo in last commit.
8200
8201 2006-09-12  Sergey Poznyakoff  <gray@gnu.org.ua>
8202
8203         * lib/argp-help.c (argp_doc): Make sure NULL is not passed to
8204         dgettext.
8205
8206 2006-09-12  Jim Meyering  <jim@meyering.net>
8207
8208         * lib/nanosleep.c: Include <sys/types.h> before sys/select.h, to avoid
8209         compilation failure (due to use of pid_t in latter) on NetBSD 1.6.
8210         Reported by Nelson H. F. Beebe.
8211
8212 2006-09-10  Sergey Poznyakoff  <gray@gnu.org.ua>
8213
8214         * lib/argp-parse.c (__argp_parse) [!_LIBC]: Make sure
8215         program_invocation_name and program_invocation_short_name are
8216         initialized.
8217         * lib/argp-namefrob.h: Move declarations of program_invocation_name
8218         and program_invocation_short_name to argp.h, so they are visible
8219         to user programs.
8220         * lib/argp.h: Likewise
8221
8222 2006-09-10  Bruno Haible  <bruno@clisp.org>
8223
8224         * modules/mkdtemp (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
8225         m4/inttypes_h.m4, m4/uintmax_t.m4.
8226
8227 2006-09-10  Bruno Haible  <bruno@clisp.org>
8228
8229         * m4/mkdtemp.m4 (gl_PREREQ_MKDTEMP): Don't require
8230         gl_AC_TYPE_UINTMAX_T.
8231
8232 2006-09-10  Bruno Haible  <bruno@clisp.org>
8233
8234         * lib/mkdtemp.c: Include <stdint.h> always. Don't include <inttypes.h>.
8235
8236 2006-09-09  Sergey Poznyakoff  <gray@gnu.org.ua>
8237
8238         * lib/argp.h (struct argp): Document the N_("..") "\v" N_("..")
8239         convention.  Text proposed by Bruno Haible.
8240         (struct argp_option): Document the use of N_() wrappers.
8241
8242         * lib/argp-help.c (argp_doc): Split the untranslated doc string on
8243         '\v', and translate the two parts separately, instead of feeding
8244         the whole string to gettext.  This allows to exclude
8245         '\v' from the strings visible to the translator by writing doc
8246         strings as N_("..") "\v" N_("..").
8247
8248 2006-09-09  Paul Eggert  <eggert@cs.ucla.edu>
8249
8250         * config/srclist.txt: Undo latest change; the bug was fixed.
8251
8252 2006-09-09  Bruno Haible  <bruno@clisp.org>
8253
8254         * gnulib-tool (func_emit_lib_Makefile_am): Eliminate lib_LDFLAGS
8255         assignments if building a library without libtool.
8256         (func_emit_tests_Makefile_am): Likewise. Handle lib_* variables as
8257         in func_emit_lib_Makefile_am.
8258         (func_import): When building a static library libfoo.a, arrange to
8259         define variables LIBFOO_LIBDEPS and LIBFOO_LTLIBDEPS.
8260         (func_create_testdir): Likewise.
8261         * modules/gc (configure.ac, Makefile.am): If building statically,
8262         augment gl_libdeps and gl_ltlibdeps instead of lib_LDFLAGS.
8263         * modules/iconvme (configure.ac, Makefile.am): Likewise.
8264         * modules/striconv (configure.ac, Makefile.am): Likewise.
8265         Based on a suggestion by Ralf Wildenhues.
8266
8267 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8268
8269         * m4/mktime.m4 (AC_FUNC_MKTIME): Sync from Autoconf.
8270         Check for unistd.h too, since Autoconf doesn't assume POSIX.
8271         Also:
8272
8273         2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8274         Add year_2050_test to catch glibc bug 2821
8275         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8276
8277         2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
8278         Prefer #ifdef to #if.
8279
8280         2006-04-02  Paul Eggert  <eggert@cs.ucla.edu>
8281         Return from 'main' instead of calling 'exit'.
8282
8283 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8284
8285         * lib/mktime.c (guess_time_tm): Fix bug where mktime
8286         returned the maximum time_t value rather than (time_t) -1.
8287         Problem originally reported by William Bardwell
8288         <http://sourceware.org/bugzilla/show_bug.cgi?id=2821>.
8289
8290         * lib/isapipe.h (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8291         Moved to here ...
8292         * lib/isapipe.c (HAVE_FIFO_PIPES) [!defined HAVE_FIFO_PIPES]:
8293         ... from here.
8294
8295 2006-09-08  Paul Eggert  <eggert@cs.ucla.edu>
8296
8297         * config/srclist.txt: Temporarily comment out mktime.c until glibc bug
8298         2821 is fixed.
8299
8300 2006-09-08  Jim Meyering  <jim@meyering.net>
8301
8302         Don't make generated files read-only.  That would bother too many
8303         people.  However, do retain the ability to work when targets are
8304         read-only: remove the destination and temporary files before writing
8305         them (when generated via sed or echo), or by using the -f option for
8306         both cp and mv commands.  Suggestion to use -f from Paul Eggert.
8307         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8308         * modules/byteswap, modules/configmake, modules/fcntl:
8309         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8310         * modules/localcharset, modules/netinet_in, modules/poll:
8311         * modules/stdbool, modules/stdint, modules/sys_select:
8312         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8313
8314 2006-09-08  Jim Meyering  <jim@meyering.net>
8315
8316         Avoid new build failure on FreeBSD 6.0.
8317         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Include
8318         <sys/param.h> when testing whether getmntinfo uses statvfs.  Patch by
8319         Pavel Tsekov, in <http://savannah.gnu.org/bugs/?17643>.
8320
8321 2006-09-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8322
8323         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't use plain echo.
8324
8325 2006-09-07  Jim Meyering  <jim@meyering.net>
8326
8327         Fix global typo in last change: use chmod u-w, not chmod u-x.
8328         Spotted by Paul Eggert and Bruce Korb.
8329         * modules/alloca-opt, modules/argz, modules/arpa_inet:
8330         * modules/byteswap, modules/configmake, modules/fcntl:
8331         * modules/fnmatch, modules/getopt, modules/glob, modules/inttypes:
8332         * modules/localcharset, modules/netinet_in, modules/poll:
8333         * modules/stdbool, modules/stdint, modules/sys_select:
8334         * modules/sys_socket, modules/sys_stat, modules/sysexits:
8335
8336 2006-09-06  Jim Meyering  <jim@meyering.net>
8337
8338         Make generated files be read-only.
8339         * modules/alloca-opt (Makefile.am): Work also when $@ is read-only.
8340         Ensure that each generated file is now read-only.
8341         * modules/argz: Likewise.
8342         * modules/arpa_inet: Likewise.
8343         * modules/byteswap: Likewise.
8344         * modules/configmake: Likewise.
8345         * modules/fcntl: Likewise.
8346         * modules/fnmatch: Likewise.
8347         * modules/getopt: Likewise.
8348         * modules/glob: Likewise.
8349         * modules/inttypes: Likewise.
8350         * modules/netinet_in: Likewise.
8351         * modules/poll: Likewise.
8352         * modules/stdbool: Likewise.
8353         * modules/stdint: Likewise.
8354         * modules/sys_select: Likewise.
8355         * modules/sys_socket: Likewise.
8356         * modules/sys_stat: Likewise.
8357         * modules/sysexits: Likewise.
8358         * modules/localcharset: Same as above, but continue using temporary
8359         file named "t-$@" (why different?) rather than the "$@-t" used
8360         everywhere else.
8361
8362         * modules/sysexits (Makefile.am): Replace literal occurrences
8363         of "sysexit.h" more readable, and more consistent, "$@".
8364
8365 2006-09-06  Bruno Haible  <bruno@clisp.org>
8366
8367         * modules/striconv: New file.
8368         * modules/xstriconv: New file.
8369         * MODULES.html.sh (Internationalization functions): Add striconv,
8370         xstriconv.
8371
8372 2006-09-06  Bruno Haible  <bruno@clisp.org>
8373
8374         * modules/gc (Makefile.am): Augment lib_LDFLAGS, not lib_LIBADD.
8375         * modules/iconvme (Makefile.am): Likewise. Also handle the case of
8376         not using libtool correctly.
8377
8378 2006-09-06  Bruno Haible  <bruno@clisp.org>
8379
8380         * lib/striconv.h: New file.
8381         * lib/striconv.c: New file, merging iconvme.c with GNU gettext's
8382         iconvstring.c.
8383         * lib/xstriconv.h: New file.
8384         * lib/xstriconv.c: New file.
8385
8386 2006-09-06  Bruno Haible  <bruno@clisp.org>
8387
8388         * gnulib-tool (func_emit_lib_Makefile_am): Initialize also
8389         lib_..._LDFLAGS.
8390
8391 2006-09-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8392
8393         * lib/argz_.h: Sync from Libtool.
8394
8395         2006-09-04  George Bosilca <bosilca@cs.utk.edu>
8396                 and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
8397
8398         * lib/libltdl/argz_.h: It's __cplusplus, not _cplusplus.
8399
8400 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
8401
8402         * modules/trim: New file.
8403
8404 2006-09-05  Davide Angelocola  <davide.angelocola@tiscali.it>
8405
8406         * lib/trim.h: New file.
8407         * lib/trim.c: New file.
8408
8409 2006-09-05  Bruno Haible  <bruno@clisp.org>
8410
8411         * MODULES.html.sh (String handling): Add trim.
8412
8413 2006-09-04  Karl Berry  <karl@gnu.org>
8414
8415         * config/srclist.txt (signed.m4, gettext.m4): changes not propagated
8416         until next release.
8417
8418 2006-09-03  Bruno Haible  <bruno@clisp.org>
8419
8420         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Locate mingw shared libraries
8421         correctly.
8422
8423 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8424
8425         * m4/getloadavg.m4 (gl_GETLOADAVG): Use CONFIGURING_GETLOADAVG,
8426         not gl_GETLOADAVG.  Omit unneeded semicolons.
8427         Problems reported by Ralf Wildenhues in
8428         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
8429         (gl_PREREQ_GETLOADAVG): Use AC_DEFUN, not m4_define.  Put
8430         at the end, which is the usual gnulib style.
8431
8432         * m4/fstypename.m4 (gl_FSTYPENAME): Use AC_CHECK_MEMBERS instead
8433         of doing all the work ourselves.
8434         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Don't check for
8435         sys/statvfs.h since the code doesn't use HAVE_SYS_STATVFS_H.
8436
8437 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8438
8439         * lib/getloadavg.c: Use CONFIGURING_GETLOADAVG, not gl_GETLOADAVG.
8440         Problem reported by Ralf Wildenhues in
8441         <http://lists.gnu.org/archive/html/bug-gnulib/2006-09/msg00000.html>.
8442
8443         * lib/mountlist.c: All uses of HAVE_F_FSTYPENAME_IN_STATFS replaced by
8444         HAVE_STRUCT_STATFS_F_FSTYPENAME.
8445
8446 2006-09-01  Paul Eggert  <eggert@cs.ucla.edu>
8447
8448         * gnulib-tool (func_emit_lib_Makefile_am): Fix typos in
8449         yesterday's patch by changing test -n to test -z.
8450
8451 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8452
8453         * modules/getloadavg (Files): Add m4/getloadavg.m4.
8454         (configure.ac): AC_FUNC_GETLOADAVG -> gl_GETLOADAVG, as
8455         the former is now obsolescent.
8456
8457         * modules/chdir-long (Depends-on): Add fcntl.
8458
8459 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8460
8461         * m4/fnmatch.m4: Add comment that Autoconf AC_FUNC_FNMATCH is
8462         obsolescent, and programs should use gnulib instead.
8463         * m4/getloadavg.m4: New file, with contents taken from Autoconf
8464         but with prefixes changed.
8465
8466 2006-08-31  Paul Eggert  <eggert@cs.ucla.edu>
8467
8468         * lib/getloadavg.c [defined gl_GETLOADAVG]: Don't include config.h
8469         or stdbool.h, because they might not exist while configuring.
8470
8471         * lib/chdir-long.c: Include <fcntl.h>, for O_DIRECTORY.
8472         Don't include unistd.h or limits.h; not needed, since chdir-long.h
8473         does that for us.
8474         (O_DIRECTORY): Remove.
8475
8476 2006-08-31  Eric Blake  <ebb9@byu.net>
8477
8478         * gnulib-tool: Don't let emacs change spaces to TAB.
8479
8480 2006-08-31  Bruno Haible  <bruno@clisp.org>
8481
8482         * gnulib-tool: When calling func_import more than once, do it in a
8483         subshell.
8484         Reported by Eric Blake <ebb9@byu.net>.
8485
8486 2006-08-31  Bruno Haible  <bruno@clisp.org>
8487
8488         * gnulib-tool (nl): Remove variable.
8489         (sed_transform_lib_file): Use more robust test for config-h module.
8490         (func_import): Fix typo in 2006-08-25 patch.
8491
8492 2006-08-31  Bruno Haible  <bruno@clisp.org>
8493
8494         * gnulib-tool (func_emit_lib_Makefile_am): When --makefile-name was
8495         specified, augment Makefile.am variables instead of assigning them.
8496
8497 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8498
8499         Work around a bug in both the Linux and SunOS 64-bit kernels:
8500         nanosleep mishandles sleeps for longer than 2**31 seconds.
8501         Problem reported by Frank v Waveren in
8502         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
8503         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Require gl_CLOCK_TIME.
8504         Check for nanosleep bug.
8505         (LIB_NANOSLEEP): Append clock_gettime library if needed.
8506
8507 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8508
8509         Work around a bug in both the Linux and SunOS 64-bit kernels:
8510         nanosleep mishandles sleeps for longer than 2**31 seconds.
8511         Problem reported by Frank v Waveren in
8512         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00298.html>.
8513         * lib/nanosleep.c (BILLION): New constant.
8514         (getnow) [HAVE_BUG_BIG_NANOSLEEP]: New functions.
8515         (rpl_nanosleep) [HAVE_BUG_BIG_NANOSLEEP]: Completely new
8516         implementation.
8517
8518 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8519
8520         * modules/nanosleep (Depends-on): Add gettime.
8521
8522 2006-08-30  Paul Eggert  <eggert@cs.ucla.edu>
8523         and Simon Josefsson  <jas@extundo.com>
8524         and Oskar Liljeblad  <oskar@osk.mine.nu>
8525
8526         * MODULES.html.sh (Support for building documentation): Add gpl, lgpl.
8527         * gnulib-tool (func_import): New license type 'unmodifiable license
8528         text'.
8529         * modules/fdl: Use it.  Longer description.
8530         * module/gpl, module/lgpl: New files.
8531
8532 2006-08-30  Jim Meyering  <jim@meyering.net>
8533
8534         * lib/isapipe.c (isapipe): Rename local s/fd/fd_pair/ to avoid
8535         shadowing the parameter.
8536
8537 2006-08-29  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8538
8539         Sync from Libtool:
8540
8541         2006-08-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
8542
8543         * lib/libltdl/argz.c: Use `#ifdef HAVE_CONFIG_H', to facilitate code
8544         sharing with gnulib.  Report by Eric Blake.
8545
8546 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8547
8548         * modules/isapipe: New file.
8549         * MODULES.html.sh (File descriptor based Input/Output): Add isapipe.
8550
8551 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8552
8553         * modules/configmake (Makefile.am): Add a comment, and omit
8554         the CONFIGMAKE_ prefix from generated macro names.  Suggested
8555         by Bruno Haible.
8556
8557 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8558
8559         * m4/isapipe.m4: New file.
8560
8561 2006-08-29  Paul Eggert  <eggert@cs.ucla.edu>
8562
8563         * lib/isapipe.c, lib/isapipe.h: New files.
8564
8565 2006-08-29  Jim Meyering  <jim@meyering.net>
8566
8567         * modules/configmake (Makefile.am): Make configmake.h depend on
8568         Makefile.  Otherwise, a stale configmake.h could hang around.
8569
8570 2006-08-29  Eric Blake  <ebb9@byu.net>
8571
8572         * lib/error.c (error_at_line, print_errno_message): Match libc, after
8573         resolution of upstream bug 3044.
8574
8575 2006-08-29  Bruno Haible  <bruno@clisp.org>
8576
8577         * modules/localcharset (Depends-on): Add configmake.
8578         (Makefile.am): Remove setting of LIBDIR through DEFS.
8579
8580 2006-08-29  Bruno Haible  <bruno@clisp.org>
8581
8582         * lib/localcharset.c: Include configmake.h in order to get LIBDIR
8583         defined.
8584
8585 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8586
8587         * modules/fcntl: New file.
8588         * modules/chdir-safer (Depends-on): Add fcntl.
8589         * modules/fts: Likewise.
8590         * modules/mkdir-p: Likewise.
8591
8592         * modules/stdint (Makefile.am): Do not substitute ABSOLUTE_INTTYPES_H.
8593         This undoes the most recent change, since we're now addressing the
8594         problem in a different way.
8595
8596         * gnulib-tool (emit_lib_Makefile_am): Don't put $makefile_name
8597         into output, since the output might be called Makefile.am even
8598         if $makefile_name is something different.
8599         (func_import): Use $makefile_am rather than
8600         ${makefile_name-Makefile.am}, to fix a bug where makefile_name was
8601         empty.
8602
8603         * modules/inttypes (Files): Add m4/inttypes-h.m4.
8604
8605 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8606
8607         * m4/inttypes.m4 (gl_INTTYPES_H): Move ABSOLUTE_INTTYPES_H code here...
8608         * m4/stdint.m4 (gl_STDINT_H): ... from here.  This undoes the most
8609         recent change to stdint.m4, since we're now addressing the problem in a
8610         different way.
8611
8612 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8613
8614         * m4/fcntl_h.m4: New file.
8615
8616 2006-08-28  Paul Eggert  <eggert@cs.ucla.edu>
8617
8618         * lib/fcntl_.h: New file.
8619         * lib/chdir-safer.c (O_DIRECTORY, O_NOFOLLOW): Remove, now that we have
8620         the fcntl module.
8621         * lib/dirchownmod.c: Likewise.
8622         * lib/fts.c: Likewise.
8623
8624         * lib/inttypes_.h [defined _GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H]:
8625         Include @ABSOLUTE_INTTYPES_H@ if available, but do nothing else.
8626         * lib/stdint_.h (_GL_JUST_INCLUDE_ABSOLUTE_INTTYPES_H): Define
8627         just before including <inttypes.h>, to avoid circular inclusion.
8628
8629 2006-08-28  Jim Meyering  <jim@meyering.net>
8630
8631         * doc/visibility.texi: Actually read and correct the grammar of the
8632         sentence affected by yesterday's change.
8633
8634 2006-08-28  Eric Blake  <ebb9@byu.net>
8635
8636         * modules/inttypes (Makefile.am): Fix sed error when inttypes.h
8637         needs wrapper.
8638
8639 2006-08-28  Eric Blake  <ebb9@byu.net>
8640
8641         * m4/inttypes.m4 (gl_INTTYPES_H): Fix missing #endif.
8642
8643 2006-08-28  Eric Blake  <ebb9@byu.net>
8644
8645         * m4/codeset.m4 (AM_LANGINFO_CODESET): Avoid compiler warning.
8646
8647 2006-08-28  Bruno Haible  <bruno@clisp.org>
8648
8649         * modules/c-strstr: New file, from GNU gettext.
8650         * MODULES.html.sh (String handling): Add c-strstr.
8651
8652 2006-08-28  Bruno Haible  <bruno@clisp.org>
8653
8654         * m4/inttypes.m4 (gl_INTTYPES_H): Don't test for the existence of SCNX*
8655         macros.
8656         Reported by Eric Blake.
8657
8658 2006-08-28  Bruno Haible  <bruno@clisp.org>
8659
8660         * lib/vasnprintf.c (EOVERFLOW): Remove definition.
8661         (VASNPRINTF): Return a string of length > INT_MAX without failing.
8662         * lib/vasprintf.c: Include errno.h, limits.h.
8663         (EOVERFLOW): New fallback definition.
8664         (vasprintf): Test here whether the string length is > INT_MAX.
8665         * lib/vsnprintf.c: Include errno.h, limits.h.
8666         (EOVERFLOW): New fallback definition.
8667         (vsnprintf): Fix bug when generated string was too long for the buffer.
8668         Test here whether the string length is > INT_MAX.
8669
8670 2006-08-28  Bruno Haible  <bruno@clisp.org>
8671
8672         * lib/inttypes_.h (SCNX*): Remove definitions.
8673         Reported by Eric Blake.
8674
8675 2006-08-28  Bruno Haible  <bruno@clisp.org>
8676
8677         * lib/c-strstr.h: New file, from GNU gettext.
8678         * lib/c-strstr.c: New file, from GNU gettext.
8679
8680 2006-08-28  Bruno Haible  <bruno@clisp.org>
8681
8682         * gnulib-tool: Reorder some statements.
8683
8684 2006-08-28  Bruno Haible  <bruno@clisp.org>
8685
8686         * gnulib-tool: New option --makefile-name.
8687         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use
8688         $makefile_name.
8689         (func_import): Write $makefile_name to the cache file, and read it from
8690         there unless explicitly specified. Use $makefile_name as file name
8691         instead of Makefile.am. Adjust the recommendations accordingly.
8692
8693 2006-08-28  Bruno Haible  <bruno@clisp.org>
8694
8695         * gnulib-tool (func_verify_module): Check against misapplying patch.
8696
8697 2006-08-28  Bruno Haible  <bruno@clisp.org>
8698
8699         * gnulib-tool (func_relativize, func_relconcat): New functions.
8700         Give an error if --local-dir is given with --update.
8701         Remove trailing slashes from $local_gnulib_dir.
8702         (func_import): Store the relativized $local_gnulib_dir in
8703         gnulib-cache.m4, and read it from there if not specified explicitly.
8704
8705 2006-08-28  Bruno Haible  <bruno@clisp.org>
8706
8707         * gnulib-tool (func_get_tests_module): Don't assume that $gnulib_dir
8708         is the current directory. Respect also $local_gnulib_dir.
8709
8710 2006-08-28  Bruno Haible  <bruno@clisp.org>
8711             Simon Josefsson  <jas@extundo.com>
8712
8713         BeOS portability.
8714         * lib/getaddrinfo.c (PF_INET, PF_UNSPEC): New macros.
8715
8716 2006-08-27  Jim Meyering  <jim@meyering.net>
8717
8718         * doc/visibility.texi: Remove duplicate word: "pointer".
8719
8720 2006-08-26  Bruno Haible  <bruno@clisp.org>
8721
8722         * modules/inttypes (Files): Add lib/inttypes_.h, remove lib/inttypes.h.
8723         Add m4/inttypes.m4, remove m4/_inttypes_h.m4 and m4/include_next.m4.
8724         (Makefile.am): Create inttypes.h from inttypes_.h.
8725         * modules/stdint (Makefile.am): Substitute also ABSOLUTE_INTTYPES_H.
8726
8727         * modules/imaxabs: New file.
8728
8729         * modules/imaxdiv: New file.
8730
8731 2006-08-26  Bruno Haible  <bruno@clisp.org>
8732
8733         * m4/inttypes.m4: New file.
8734         * m4/_inttypes_h.m4: Remove file.
8735         * m4/inttypes-pri.m4 (gt_INTTYPES_PRI): Also AC_SUBST
8736         PRI_MACROS_BROKEN.
8737         * m4/stdint.m4 (gl_STDINT_H): Define also ABSOLUTE_INTTYPES_H.
8738
8739         * m4/imaxabs.m4: New file.
8740
8741         * m4/imaxdiv.m4: New file.
8742
8743 2006-08-26  Bruno Haible  <bruno@clisp.org>
8744
8745         * lib/inttypes_.h: New file.
8746         * lib/inttypes.h: Remove file.
8747         * lib/stdint_.h: Include <inttypes.h> through its absolute filename.
8748
8749         * lib/imaxabs.c: New file.
8750
8751         * lib/imaxdiv.c: New file.
8752
8753 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8754
8755         New config-h module, so that "make" output needn't be cluttered
8756         by -DHAVE_CONFIG_H.
8757         * MODULES.html.sh (Support for building libraries and executables):
8758         Add config-h.
8759         * modules/config-h: New file.
8760         * gnulib-tool (nl, sed_transform_lib_file): New vars.
8761         (func_import): Turn "#ifdef HAVE_CONFIG_H" to "#if 1" if
8762         the config-h module is used.
8763
8764         New configmake module, so that "make" output needn't be cluttered
8765         by fluff like '-DLIBDIR=\"/usr/local/lib\"'.
8766         * MODULES.html.sh (Support for building libraries and executables):
8767         Add configmake.
8768         * modules/configmake: New file.
8769
8770 2006-08-25  Paul Eggert  <eggert@cs.ucla.edu>
8771
8772         * m4/config-h.m4: New file.
8773
8774 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8775
8776         * config/srclist.txt: Add elisp-comp.
8777
8778 2006-08-24  Paul Eggert  <eggert@cs.ucla.edu>
8779
8780         * MODULES.html.sh (Support for building libraries and executables):
8781         Add elisp-comp.
8782         * build-aux/elisp-comp: New file.
8783         * modules/elisp-comp: New file.
8784
8785 2006-08-24  Bruno Haible  <bruno@clisp.org>
8786
8787         * gnulib-tool (func_create_testdir): Use non-default values of
8788         sourcebase and m4base.
8789
8790 2006-08-24  Bruno Haible  <bruno@clisp.org>
8791
8792         * MODULES.html.sh (Compatibility checks for POSIX:2001 functions: Fix
8793         HTML structure.
8794
8795 2006-08-23  Paul Eggert  <eggert@cs.ucla.edu>
8796
8797         * modules/openat (Depends-on): Add lchown.
8798
8799 2006-08-23  Bruno Haible  <bruno@clisp.org>
8800
8801         * gnulib-tool (func_import, func_create_testdir): Emit an invocation
8802         of gl_LOCK_EARLY instead of gl_LOCK.
8803
8804 2006-08-23  Bruno Haible  <bruno@clisp.org>
8805
8806         * m4/lock.m4 (gl_LOCK_BODY): Change the default value of gl_use_threads
8807         on OSF/1 to no.
8808         Reported by Stephen Cartwright <sgcartwr@ucalgary.ca>.
8809
8810 2006-08-23  Bruno Haible  <bruno@clisp.org>
8811
8812         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Don't consider BeOS statvfs
8813         as unusable.
8814
8815         * m4/lock.m4 (gl_LOCK_EARLY): Renamed from gl_LOCK.
8816         (gl_LOCK_BODY): Remove gl_PREREQ_LOCK invocation.
8817         (gl_LOCK): New macro.
8818
8819 2006-08-22  Simon Josefsson  <jas@extundo.com>
8820
8821         * modules/gc-md5 (Makefile.am): Need to add md5.h, after changes
8822         to md5 module.
8823
8824 2006-08-22  Simon Josefsson  <jas@extundo.com>
8825
8826         * MODULES.html.sh: Add "Support for maintaining and release
8827         projects".
8828
8829         * build-aux/gnupload: New file, from coreutils.
8830
8831 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8832
8833         Avoid the need for AC_LIBSOURCES in m4 macros.
8834         * modules/arcfour (EXTRA_DIST): Add arcfour.h.
8835         * modules/arctwo (EXTRA_DIST): Add arctwo.h.
8836         * modules/check-version (EXTRA_DIST): Add check-version.h.
8837         * modules/crc (EXTRA_DIST): Add crc.h.
8838         * modules/des (EXTRA_DIST): Add des.h.
8839         * modules/gc (EXTRA_DIST): Add gc.h.
8840         * modules/getdelim (EXTRA_DIST): Add getdelim.h.
8841         * modules/getline (EXTRA_DIST): Add getline.h.
8842         * modules/getlogin_r (EXTRA_DIST): Add getlogin_r.h.
8843         * modules/hmac-md5 (EXTRA_DIST): Add hmac.h.
8844         * modules/hmac-sha1 (EXTRA_DIST): Add hmac.h.
8845         * modules/md2 (EXTRA_DIST): Add md2.h.
8846         * modules/md4 (EXTRA_DIST): Add md4.h.
8847         * modules/pagealign_alloc (EXTRA_DIST): Add pagealign_alloc.h.
8848         * modules/read-file (EXTRA_DIST): Add read-file.h.
8849         * modules/readline (EXTRA_DIST): Add readline.h.
8850         * modules/rijndael (EXTRA_DIST): Add rijndael-alg-fst.h,
8851         rijndael-api-fst.h.
8852
8853 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8854
8855         * m4/rijndael.m4 (gl_ARCFOUR):
8856         * m4/arctwo.m4 (gl_ARCTWO):
8857         * m4/check-version.m4 (gl_CHECK_VERSION):
8858         * m4/crc.m4 (gl_CRC):
8859         * m4/des.m4 (gl_DES):
8860         * m4/gc-pbkdf2-sha1.m4 (gl_GC_PBKDF2_SHA1):
8861         * m4/gc.m4 (gl_GC):
8862         * m4/getdelim.m4 (gl_FUNC_GETDELIM):
8863         * m4/getline.m4 (gl_FUNC_GETLINE):
8864         * m4/getlogin_r.m4 (gl_GETLOGIN_R_SUBSTITUTE):
8865         * m4/hmac-md5.m4 (gl_HMAC_MD5):
8866         * m4/hmac-sha1.m4 (gl_HMAC_SHA1):
8867         * m4/md2.m4 (gl_MD2):
8868         * m4/md4.m4 (gl_MD4):
8869         * m4/pagealign_alloc.m4 (gl_PAGEALIGN_ALLOC):
8870         * m4/read-file.m4 (gl_FUNC_READ_FILE):
8871         * m4/readline.m4 (gl_FUNC_READLINE):
8872         * m4/rijndael.m4 (gl_RIJNDAEL):
8873         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
8874         to get the necessary .h files and whatnot.
8875
8876 2006-08-22  Paul Eggert  <eggert@cs.ucla.edu>
8877
8878         * config/srclist.txt: Remove gnupload, since coreutils now syncs from
8879         gnulib rather than the other way around.
8880         * config/srclistvars.sh (COREUTILS): Remove.
8881
8882 2006-08-22  Jim Meyering  <jim@meyering.net>
8883
8884         * modules/mkdir-p (Makefile.am): Fix typo: s/lib+SOURCES/lib_SOURCES/.
8885
8886         * modules/getpass-gnu (Makefile.am): Add getpass.h to EXTRA_DIST.
8887
8888 2006-08-22  Eric Blake  <ebb9@byu.net>
8889
8890         * modules/regexprops-generic: New file.
8891         * MODULES.html.sh (Support for building documentation): List it.
8892
8893 2006-08-22  Eric Blake  <ebb9@byu.net>
8894
8895         * m4/stdint_h.m4 (gl_AC_HEADER_STDINT_H): Avoid compiler warning.
8896         * m4/inttypes_h.m4 (gl_AC_HEADER_INTTYPES_H): Likewise.
8897         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Likewise.
8898         * m4/intmax_t.m4 (gt_AC_TYPE_INTMAX_T): Likewise.
8899
8900 2006-08-22  Bruno Haible  <bruno@clisp.org>
8901
8902         * gnulib-tool (func_emit_lib_Makefile_am): Don't treat lib_LIBRARIES
8903         and lib_LTLIBRARIES like the other lib_* variables.
8904
8905 2006-08-22  Bruno Haible  <bruno@clisp.org>
8906
8907         * build-aux/x-to-1.in: New file, from GNU gettext.
8908
8909 2006-08-22  Bruno Haible  <bruno@clisp.org>
8910
8911         * m4/readutmp.m4 (gl_READUTMP): Compile readutmp.c only if <utmp.h> or
8912         <utmpx.h> exists.
8913
8914 2006-08-22  Bruno Haible  <bruno@clisp.org>
8915
8916         * lib/readutmp.h: Skip most definitions if neither <utmp.h> nor
8917         <utmpx.h> exists.
8918
8919 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8920
8921         BeOS portability.
8922         * lib/dirchownmod.c (dirchownmod): Don't use fchmod if it doesn't
8923         exist.
8924         Problem reported by Bruno Haible.
8925
8926 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
8927
8928         Avoid the need for AC_LIBSOURCES in m4 macros.
8929         * modules/acl (EXTRA_DIST): Add acl.h.
8930         * modules/argmatch (Files): Add m4/argmatch.m4.
8931         (configure.ac): Add gl_ARGMATCH.
8932         (EXTRA_DIST): Renamed from lib_SOURCES, for
8933         consistency with the other modules.  Remove argmatch.c.
8934         * modules/backupfile (EXTRA_DIST): Add backupfile.h.
8935         * modules/c-strtod (EXTRA_DIST): Add c-strtod.h.
8936         * modules/c-strtold (EXTRA_DIST): Add c-strtod.c, c-strtod.h.
8937         * modules/canonhost (EXTRA_DIST): Add c-canonhost.h.
8938         * modules/canonicalize (EXTRA_DIST): Add canonicalize.h.
8939         * modules/chdir-long (EXTRA_DIST): Add chdir-long.h.
8940         * modules/chdir-safer (EXTRA_DIST): Add chdir-safer.h.
8941         * modules/cloexec (EXTRA_DIST): Add cloexec.h.
8942         * modules/close-stream (EXTRA_DIST): Add close-stream.h.
8943         * modules/closeout (EXTRA_DIST): Add closeout.h.
8944         * modules/cycle-check (EXTRA_DIST): Add cycle-check.h.
8945         * modules/dev-ino (EXTRA_DIST): Add dev-ino.h.
8946         * modules/dirfd (EXTRA_DIST): Add dirfd.h.
8947         * modules/dirname (EXTRA_DIST): Renamed from lib_SOURCES.  Add
8948         dirname.h; remove basename.c and stripslash.c.
8949         * modules/exclude (EXTRA_DIST): Add exclude.h.
8950         * modules/exitfail (EXTRA_DIST): Add exitfail.h.
8951         * modules/fcntl-safer (EXTRA_DIST): Add fcntl-safer.h fcntl--.h.
8952         * modules/file-type (EXTRA_DIST): Add file-type.h.
8953         * modules/filemode (EXTRA_DIST): Add filemode.h.
8954         * modules/filenamecat (EXTRA_DIST): Add filenamecat.h.
8955         * modules/fopen-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
8956         * modules/fpending (EXTRA_DIST): Add __fpending.h.
8957         * modules/fprintftime (EXTRA_DIST): Add fprintftime.h.
8958         * modules/fsusage (EXTRA_DIST): Add fsusage.h.
8959         * modules/fts (EXTRA_DIST): Add fts_.h fts-cycle.c.
8960         * modules/getcwd (EXTRA_DIST): Add getcwd.h.
8961         * modules/getdate (EXTRA_DIST): Add getdate.c.
8962         * modules/gethrxtime (EXTRA_DIST): Add gethrxtime.h xtime.h.
8963         * modules/getpagesize (EXTRA_DIST): Add getpagesize.h.
8964         * modules/getpass (EXTRA_DIST): Add getpass.h.
8965         * modules/glob (EXTRA_DIST): Add glob_.h glob-libc.h.
8966         * modules/group-member (EXTRA_DIST): Add group-member.h.
8967         * modules/hard-locale (EXTRA_DIST): Add hard-locale.h.
8968         * modules/hash (EXTRA_DIST): Add hash.h.
8969         * modules/human (EXTRA_DIST): Add human.h.
8970         * modules/inttypes (EXTRA_DIST): Add inttypes.h.
8971         * modules/lchmod (EXTRA_DIST): Add lchmod.h.
8972         * modules/lchown (EXTRA_DIST): Add lchown.h.
8973         * modules/long-options (EXTRA_DIST): Add long-options.h.
8974         * modules/lstat (EXTRA_DIST): Add lstat.h.
8975         * modules/md5 (EXTRA_DIST): Add memcasecmp.h.
8976         * modules/memcoll (EXTRA_DIST): Add memcoll.h.
8977         * modules/mempcpy (EXTRA_DIST): Add mempcpy.h.
8978         * modules/memrchr (EXTRA_DIST): Add memrchr.h.
8979         * modules/memxor (EXTRA_DIST): Add memxor.h.
8980         * modules/mkancesdirs (EXTRA_DIST): Add mkancesdirs.h.
8981         * modules/mkdir-p (EXTRA_DIST): Add modechange.h.
8982         * modules/mountlist (EXTRA_DIST): Add mountlist.h.
8983         * modules/openat (EXTRA_DIST): Add at-func.c openat.h openat-priv.h.
8984         * modules/pathmax (EXTRA_DIST): Add pathmax.h.
8985         * modules/physmem (EXTRA_DIST): Add physmem.h.
8986         * modules/posixtm (EXTRA_DIST): Add posixtm.h.
8987         * modules/posixver (EXTRA_DIST): Add posixver.h.
8988         * modules/quote (EXTRA_DIST): Add quote.h.
8989         * modules/quotearg (EXTRA_DIST): Add quotearg.h.
8990         * modules/readtokens (EXTRA_DIST): Add readtokens.h.
8991         * modules/readutmp (EXTRA_DIST): Add readutmp.h.
8992         * modules/regex (EXTRA_DIST): Add regcomp.c regex.h regex_internal.c
8993         regex_internal.h regexec.c.
8994         * modules/safe-read (EXTRA_DIST): Add safe-read.h.
8995         * modules/safe-write (EXTRA_DIST): Add safe-write.h.
8996         * modules/same (EXTRA_DIST): Add same.h.
8997         * modules/same-inode (EXTRA_DIST): Add same-inode.h.
8998         * modules/save-cwd (EXTRA_DIST): Add save-cwd.h.
8999         * modules/savedir (EXTRA_DIST): Add savedir.h.
9000         * modules/sha1 (EXTRA_DIST): Add sha1.h.
9001         * modules/sig2str (EXTRA_DIST): Add sig2str.h.
9002         * modules/stat-macros (EXTRA_DIST): Add stat-macros.h.
9003         * modules/stat-time (EXTRA_DIST): Add stat-time.h.
9004         * modules/stdlib-safer (EXTRA_DIST): Add stdlib-safer.h stdlib--.h.
9005         * modules/strdup (EXTRA_DIST): Add strdup.h.
9006         * modules/strftime (EXTRA_DIST): Add strftime.h.
9007         * modules/strndup (EXTRA_DIST): Add strndup.h.
9008         * modules/strnlen (EXTRA_DIST): Add strnlen.h.
9009         * modules/strverscmp (EXTRA_DIST): Add strverscmp.h.
9010         * modules/time_r (EXTRA_DIST): Add time_r.h.
9011         * modules/timespec (EXTRA_DIST): Add timespec.h.
9012         * modules/tmpfile-safer (EXTRA_DIST): Add stdio-safer.h stdio--.h.
9013         * modules/unistd-safer (EXTRA_DIST): Add unistd-safer.h unistd--.h.
9014         * modules/unlinkdir (EXTRA_DIST): Add unlinkdir.h.
9015         * modules/unlocked-io (EXTRA_DIST): Add unlocked-io.h.
9016         * modules/userspec (EXTRA_DIST): Add userspec.h.
9017         * modules/utimecmp (EXTRA_DIST): Add utimecmp.h.
9018         * modules/utimens (EXTRA_DIST): Add utimens.h.
9019         * modules/xalloc (EXTRA_DIST): Add xalloc.h.
9020         * modules/xgetcwd (EXTRA_DIST): Add xgetcwd.h.
9021         * modules/xnanosleep (EXTRA_DIST): Add xnanosleep.h.
9022         * modules/xreadlink (EXTRA_DIST): Add xreadlink.h.
9023         * modules/xstrtod (EXTRA_DIST): Add xstrtod.h.
9024         * modules/xstrtol (EXTRA_DIST): Add xstrtol.h.
9025         * modules/xstrtold (EXTRA_DIST): Add xstrtod.c xstrtod.h.
9026         * modules/yesno (EXTRA_DIST): Add yesno.h.
9027
9028 2006-08-21  Paul Eggert  <eggert@cs.ucla.edu>
9029
9030         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Check for fchmod.
9031
9032         * m4/argmatch.m4: New file, from coreutils with AC_LIBSOURCES removed.
9033         * m4/dev-ino.m4, same-inode.m4: Remove.
9034
9035         * m4/_inttypes_h.m4 (gl_INTTYPES_H):
9036         * m4/acl.m4 (AC_FUNC_ACL):
9037         * m4/backupfile.m4 (gl_BACKUPFILE):
9038         * m4/c-strtod.m4 (gl_C99_STRTOLD):
9039         * m4/canon-host.m4 (gl_CANON_HOST):
9040         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME):
9041         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG):
9042         * m4/chdir-safer.m4 (gl_CHDIR_SAFER):
9043         * m4/cloexec.m4 (gl_CLOEXEC):
9044         * m4/close-stream.m4 (gl_CLOSE_STREAM):
9045         * m4/closeout.m4 (gl_CLOSEOUT):
9046         * m4/dirfd.m4 (gl_FUNC_DIRFD):
9047         * m4/dirname.m4 (gl_DIRNAME):
9048         * m4/exclude.m4 (gl_EXCLUDE):
9049         * m4/exitfail.m4 (gl_EXITFAIL):
9050         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER):
9051         * m4/file-type.m4 (gl_FILE_TYPE):
9052         * m4/filemode.m4 (gl_FILEMODE):
9053         * m4/filenamecat.m4 (gl_FILE_NAME_CONCAT):
9054         * m4/fpending.m4 (gl_FUNC_FPENDING):
9055         * m4/fprintftime.m4 (gl_FPRINTFTIME):
9056         * m4/fts.m4 (gl_FUNC_FTS):
9057         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL):
9058         * m4/getdate.m4 (gl_GETDATE):
9059         * m4/gethrxtime.m4 (gl_GETHRXTIME):
9060         * m4/getpagesize.m4 (gl_GETPAGESIZE):
9061         * m4/getpass.m4 (gl_FUNC_GETPASS):
9062         * m4/gettime.m4 (gl_GETTIME):
9063         * m4/getugroups.m4 (gl_GETUGROUPS):
9064         * m4/glob.m4 (gl_GLOB_SUBSTITUTE):
9065         * m4/group-member.m4 (gl_FUNC_GROUP_MEMBER):
9066         * m4/hard-locale.m4 (gl_HARD_LOCALE):
9067         * m4/hash.m4 (gl_HASH):
9068         * m4/idcache.m4 (gl_IDCACHE):
9069         * m4/lchmod.m4 (gl_FUNC_LCHMOD):
9070         * m4/lchown.m4 (gl_FUNC_LCHOWN):
9071         * m4/long-options.m4 (gl_LONG_OPTIONS):
9072         * m4/lstat.m4 (gl_FUNC_LSTAT):
9073         * m4/md5.m4 (gl_MD5):
9074         * m4/memcasecmp.m4 (gl_MEMCASECMP):
9075         * m4/memcoll.m4 (gl_MEMCOLL):
9076         * m4/mempcpy.m4 (gl_FUNC_MEMPCPY):
9077         * m4/memrchr.m4 (gl_FUNC_MEMRCHR):
9078         * m4/memxor.m4 (gl_MEMXOR):
9079         * m4/mkancesdirs.m4 (gl_MKANCESDIRS):
9080         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS):
9081         * m4/modechange.m4 (gl_MODECHANGE):
9082         * m4/mountlist.m4 (gl_MOUNTLIST):
9083         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP):
9084         * m4/openat.m4 (gl_FUNC_OPENAT):
9085         * m4/pathmax.m4 (gl_PATHMAX):
9086         * m4/physmem.m4 (gl_PHYSMEM):
9087         * m4/posixtm.m4 (gl_POSIXTM):
9088         * m4/posixver.m4 (gl_POSIXVER):
9089         * m4/quote.m4 (gl_QUOTE):
9090         * m4/quotearg.m4 (gl_QUOTEARG):
9091         * m4/readtokens.m4 (gl_READTOKENS):
9092         * m4/readutmp.m4 (gl_READUTMP):
9093         * m4/regex.m4 (gl_REGEX):
9094         * m4/safe-read.m4 (gl_SAFE_READ):
9095         * m4/safe-write.m4 (gl_SAFE_WRITE):
9096         * m4/same.m4 (gl_SAME):
9097         * m4/save-cwd.m4 (gl_SAVE_CWD):
9098         * m4/savedir.m4 (gl_SAVEDIR):
9099         * m4/settime.m4 (gl_SETTIME):
9100         * m4/sha1.m4 (gl_SHA1):
9101         * m4/sig2str.m4 (gl_FUNC_SIG2STR):
9102         * m4/stat-macros.m4 (gl_STAT_MACROS):
9103         * m4/stat-time.m4 (gl_STAT_TIME):
9104         * m4/stdio-safer.m4 (gl_FOPEN_SAFER):
9105         * m4/stdlib-safer.m4 (gl_STDLIB_SAFER):
9106         * m4/strdup.m4 (gl_FUNC_STRDUP):
9107         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME):
9108         * m4/strndup.m4 (gl_FUNC_STRNDUP):
9109         * m4/strnlen.m4 (gl_FUNC_STRNLEN):
9110         * m4/strverscmp.m4 (gl_FUNC_STRVERSCMP):
9111         * m4/time_r.m4 (gl_TIME_R):
9112         * m4/timespec.m4 (gl_TIMESPEC):
9113         * m4/unistd-safer.m4 (gl_UNISTD_SAFER):
9114         * m4/unlinkdir.m4 (gl_UNLINKDIR):
9115         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO):
9116         * m4/userspec.m4 (gl_USERSPEC):
9117         * m4/utimecmp.m4 (gl_UTIMECMP):
9118         * m4/utimens.m4 (gl_UTIMENS):
9119         * m4/xalloc.m4 (gl_XALLOC):
9120         * m4/xgetcwd.m4 (gl_XGETCWD):
9121         * m4/xnanosleep.m4 (gl_XNANOSLEEP):
9122         * m4/xreadlink.m4 (gl_XREADLINK):
9123         * m4/xstrtod.m4 (gl_XSTRTOD):
9124         * m4/yesno.m4 (gl_YESNO):
9125         Don't use AC_LIBSOURCES; instead, rely on the files in ../modules/
9126         to get the necessary .h files and whatnot.
9127
9128 2006-08-21  Mark D. Baushke  <mdb@gnu.org>
9129             Bruno Haible  <bruno@clisp.org>
9130
9131         * gnulib-tool (func_verify_module): Work around Sun's non-POSIX 1003.2
9132         /bin/sh understanding of '!' conditional negation.
9133
9134 2006-08-21  Jim Meyering  <jim@meyering.net>
9135
9136         * modules/openat (Depends-on): Really alphabetize.
9137
9138         * modules/acl (Depends-on): Add error and quote.
9139
9140         * check-module (find_included_lib_files): Add at-func.c to the
9141         ok-to-include-more-than-once white list.
9142
9143         * modules/openat (Depends-on): Add lstat.  Alphabetize.
9144
9145 2006-08-21  Bruno Haible  <bruno@clisp.org>
9146
9147         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9148         Emit a pkgdata_DATA variable only if some snippets add contents to it.
9149         Reported by Martin Lambers <marlam@marlam.de>.
9150
9151 2006-08-21  Bruno Haible  <bruno@clisp.org>
9152
9153         * gnulib-tool (func_emit_lib_Makefile_am): If the snippets already
9154         specify an installation location, don't emit a noinst_LIBRARIES or
9155         noinst_LTLIBRARIES assignment.
9156
9157 2006-08-21  Bruno Haible  <bruno@clisp.org>
9158
9159         BeOS portability.
9160         * modules/mbchar (Include): Don't test HAVE_WCTYPE_H any more, since
9161         BeOS has mbrtowc() but no <wctype.h>.
9162
9163 2006-08-21  Bruno Haible  <bruno@clisp.org>
9164
9165         BeOS portability.
9166         * m4/mbchar.m4 (gl_MBCHAR): Compile mbchar.c also if <wctype.h> doesn't
9167         exist.
9168
9169 2006-08-21  Bruno Haible  <bruno@clisp.org>
9170
9171         BeOS portability.
9172         * lib/mbchar.h: Include <wctype.h> only if it exists.
9173
9174 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9175
9176         Remove files that are no longer needed by their respective modules.
9177         * m4/obstack.m4: Remove.
9178         * m4/strerror_r.m4: Remove.
9179         * m4/uint32_t.m4: Remove.
9180         * m4/uintptr_t.m4: Remove.
9181         * m4/ullong_max.m4: Remove.
9182         * m4/xstrtoimax.m4: Remove.
9183         * m4/xstrtoumax.m4: Remove.
9184
9185         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Do not require
9186         gl_AC_TYPE_UINTMAX_T, gl_STRUCT_DEV_INO, or gl_SAME_INODE, since gnulib
9187         dependencies now capture this.
9188
9189         * m4/cycle-check.m4 (gl_CYCLE_CHECK):
9190         Do not use AC_LIBSOURCES, since gnulib modules now do this.
9191         * m4/fsusage.m4 (gl_FSUSAGE): Likewise.
9192         * m4/human.m4 (gl_HUMAN): Likewise.
9193         * m4/inttostr.m4 (gl_INTTOSTR): Likewise.
9194         * m4/xstrtol.m4 (gl_XSTRTOL): Likewise.
9195
9196         * m4/filemode.m4 (gl_FILEMODE): Require AC_STRUCT_ST_DM_MODE.
9197
9198         * m4/filemode.m4 (gl_PREREQ_FSUSAGE_EXTRA): Do not require
9199         gl_AC_TYPE_INTMAX_T or gl_AC_TYPE_UINTMAX_T, since we now require
9200         stdint.
9201         * m4/human.m4 (gl_HUMAN): Likewise.
9202         * m4/inttostr.m4 (gl_PREREQ_INTTOSTR): Likewise.
9203         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Likewise.
9204         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9205         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9206         * m4/xstrtol (gl_XSTRTOL): Likewise.
9207
9208         * m4/gethrxtime.m4 (gl_XTIME): gl_AC_TYPE_LONG_LONG ->
9209         AC_TYPE_LONG_LONG_INT.
9210         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Likewise.
9211         * m4/strtoll.m4 (gl_FUNC_STRTOLL): Likewise.
9212         * m4/strtoull.m4 (gl_FUNC_STRTOULL): Likewise, for unsigned long.
9213         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Likewise.
9214
9215         * m4/human.m4 (gl_HUMAN): Do not require AM_STDBOOL_H since we depend
9216         on stdbool.
9217
9218         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL_H, gl_PREREQ_XSTRTOL): Remove.
9219         (gl_PREREQ_XSTRTOUL): Remove.
9220
9221         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Check for hasmntopt.
9222
9223         * m4/posixver.m4: Fix comment since head -1 now works even in POSIX
9224         mode.
9225
9226 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9227
9228         Add and change modules to make it easier for coreutils to use
9229         gnulib-tool.
9230         * modules/backupfile (Files): Remove m4/d-ino.m4.
9231         (Depends-on): Add d-ino.
9232         * modules/cycle-check (Depends-on): Add stdint.
9233         (lib_SOURCES): Add cycle-check.h.
9234         * modules/d-ino: New module.
9235         * modules/d-type: New module.
9236         * modules/error (Files): Remove m4/strerror_r.m4.
9237         * modules/filemode (Files): Add m4/st_dm_mode.m4.
9238         * modules/fsuage (Files): Remove m4/ulonglong.m4, m4/stdint_h.m4,
9239         m4/inttypes_h.m4, m4/uintmax_t.m4.
9240         (Depends-on): Add stdint.
9241         (lib_SOURCES): Add fsusage.h.
9242         * modules/getcwd (Files): Remove d-ino.m4.
9243         (Depends-on): Add d-ino.
9244         * modules/getndelim2 (Depends-on): Add stdint.
9245         * modules/glob (Files): Remove m4/d-type.m4.
9246         (Depends-on): Add d-type.
9247         * modules/host-os: New module.
9248         * modules/human (Files):  Remove m4/ulonglong.m4, m4/stdint_h.m4,
9249         m4/inttypes_h.m4, m4/uintmax_t.m4.
9250         * Depends-on: Add stdint.
9251         (lib_SOURCES): Add human.h.
9252         * modules/inttostr (Files): Remove m4/intmax_t.m4,
9253         m4/inttostr.m4, m4/inttypes_h.m4, m4/longlong.m4, m4/stdint_h.m4,
9254         m4/uintmax_t.m4, m4/ulonglong.m4.
9255         (Depends-on): Add stdint.
9256         (EXTRA_DIST): Add inttostr.h.
9257         * modules/lchmod: New module.
9258         * modules/link-follow: New module.
9259         * modules/mkdir-p (Files): Remove lib/lchmod.h, m4/lchmod.m4.
9260         (Depends-on): Add lchmod.
9261         * modules/mkstemp (Files): Remove m4/ulonglong.m4,
9262         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4.
9263         (Depends-on): Add stdint.
9264         * modules/obstack (Files): Remove m4/inttypes_h.m4, m4/obstack.m4,
9265         m4/stdint_h.m4, m4/uintmax_t.m4, m4/ulonglong.m4.
9266         (Depends-on): Add stdint.
9267         (configure.ac): Change gl_OBSTACK to AC_FUNC_OBSTACK.
9268         * modules/perl: New module.
9269         * modules/regex (Depends-on): Add stdint.
9270         * modules/rmdir-errno: New module.
9271         * modules/strtoimax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9272         m4/intmax_t.m4.
9273         (Depends-on): Add stdint.
9274         * modules/strtoumax (Files): Remove m4/stdint_h.m4, m4/inttypes_h.m4,
9275         m4/uintmax_t.m4.
9276         (Depends-on): Add stdint.
9277         * modules/unlink-busy: New module.
9278         * modules/utimecmp (Depends-on): Add stdint.
9279         * modules/uptime: New module.
9280         * modules/winsz-ioctl: New module.
9281         * modules/winsz-termios: New module.
9282         * modules/xnanosleep (Depends-on): Add nanosleep.
9283         * modules/ullong_max: Remove.
9284         * modules/xstrtoimax (Files): Remove m4/xstrtoimax.m4.
9285         (configure.ac): Remove gl_XSTRTOIMAX; no action needed now.
9286         * modules/xstrtol (Files): Remove m4/ulonglong.m4, m4/longlong.m4,
9287         m4/stdint_h.m4, m4/inttypes_h.m4, m4/uintmax_t.m4, m4/intmax_t.m4.
9288         (Depends-on): Add inttypes.
9289         (lib_SOURCES): Add xstrtol.h.
9290         * modules/xstrtoumax (Files): Remove m4/xstrtoumax.m4.
9291         (configure.ac): Remove gl_XSTRTOUMAX; no action needed now.
9292         * MODULES.html.sh: Move 'assert' into the assert section.
9293         Move 'dummy' into the linking section.
9294         Remove ullong_max.
9295         Add section for compatibility checks for POSIX:2001 functions,
9296         and put d-ino, d-type, link-follow, rmdir-errno, unlink-busy,
9297         winsz-ioctl, and winsz-termios into it.
9298         Add lchmod.
9299         Add top-level Misc section and put host-os, perl, and uptime
9300         into it.
9301
9302 2006-08-20  Paul Eggert  <eggert@cs.ucla.edu>
9303
9304         * lib/cycle-check.h: Include <stdint.h> unconditionally, since we
9305         now assume the stdint module.  Do not include inttypes.h.
9306         * lib/fsusage.h: Likewise.
9307         * lib/getndelim2.c: Likewise.
9308         * lib/human.h: Likewise.
9309         * lib/inttostr.h: Likewise.
9310         * lib/obstack.c: Likewise.
9311         * lib/regex_internal.h: Likewise.
9312         * lib/tempname.c: Likewise.
9313         * lib/utimecmp.c: Likewise.
9314         * lib/xstrtol.h: Likewise.
9315
9316         * lib/stat_.h: Fix typo: HAVE_FUNC_LSTAT -> HAVE_LSTAT.
9317
9318         * lib/strtoimax.c: Adjust to macro name changes in Autoconf,
9319         e.g., HAVE_LONG_LONG -> HAVE_LONG_LONG_INT.
9320         * lib/xtime.h: Likewise.
9321
9322 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9323
9324         * modules/openat (Files): Add lib/fchmodat.c.
9325         Fixes problem reported by Jay Youngman.
9326
9327 2006-08-19  Paul Eggert  <eggert@cs.ucla.edu>
9328
9329         * lib/fchmodat.c: New file, from coreutils.  This was inadvertently
9330         omitted in the 2006-08-17 update.  Problem reported by Jay Youngman.
9331
9332 2006-08-18  Paul Eggert  <eggert@cs.ucla.edu>
9333             Bruno Haible  <bruno@clisp.org>
9334
9335         * m4/bison-i18n.m4 (BISON_I18N): Also handle the case where yacc exists
9336         and is a script that invokes bison. Tighten the code. Add comments.
9337
9338 2006-08-18  Jim Meyering  <jim@meyering.net>
9339
9340         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Also check for
9341         CLOCK_REALTIME, since gethrxtime may revert to using clock_gettime via
9342         gettime.c.  Gabor Z. Papp reported that gethrxtime-using programs
9343         failed to link due to unresolved clock_gettime on a linux-2.4.x system.
9344
9345 2006-08-18  Bruno Haible  <bruno@clisp.org>
9346
9347         * modules/bison-i18n: New file.
9348         * MODULES.html.sh (Internationalization functions): Add it.
9349
9350 2006-08-18  Bruno Haible  <bruno@clisp.org>
9351
9352         * m4/ls-mntd-fs.m4 (gl_LIST_MOUNTED_FILE_SYSTEMS): Also check for
9353         sys/statvfs.h. When getmntinfo was found, check its declaration and
9354         set either MOUNTED_GETMNTINFO or MOUNTED_GETMNTINFO2 depending on it.
9355
9356 2006-08-18  Bruno Haible  <bruno@clisp.org>
9357
9358         * m4/bison-i18n.m4: New file, from bison.
9359
9360 2006-08-18  Bruno Haible  <bruno@clisp.org>
9361
9362         * lib/mountlist.c [MOUNTED_GETMNTINFO2]: Include sys/statvfs.h.
9363         (ME_DUMMY): Treat "kernfs" as a dummy.
9364         (read_file_system_list) [MOUNTED_GETMNTINFO2]: Implement.
9365
9366 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9367
9368         Update from coreutils.
9369
9370         2006-08-15  Jim Meyering  <jim@meyering.net>
9371
9372         * m4/openat.m4 (gl_FUNC_OPENAT): Add at-func.c via AC_LIBSOURCES.
9373
9374         2006-01-17  Jim Meyering  <jim@meyering.net>
9375
9376         * m4/fts.m4 (gl_FUNC_FTS_CORE): Depend on gl_FUNC_OPENAT.
9377
9378         2006-01-11  Jim Meyering  <jim@meyering.net>
9379
9380         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile fchmodat.c.
9381         Check for the lchmod function.
9382
9383 2006-08-17  Paul Eggert  <eggert@cs.ucla.edu>
9384
9385         Update from coreutils.
9386
9387         * lib/__fpending.h: Add copyright notice.
9388         * lib/fprintftime.h: Likewise.
9389         * lib/savedir.c: Use (C) in copyright notice.
9390         * lib/savedir.h: Likewise.
9391
9392         2006-08-15  Jim Meyering  <jim@meyering.net>
9393
9394         * lib/at-func.c: New file, with the logic of all emulated at-functions.
9395         * lib/openat-priv.h: Include <errno.h> and define ENOSYS,
9396         in support of the EXPECTED_ERRNO macro.
9397         * lib/openat.c (fstatat, unlinkat, fchownat): Remove function
9398         definitions.  Instead, define the appropriate symbols and include
9399         "at-func.c".
9400         * lib/mkdirat.c (mkdirat): Likewise.
9401         * lib/fchmodat.c (fchmodat): Likewise.
9402         (ENOSYS): Remove definition.
9403         * lib/openat.c: Don't include <errno.h>, now that "openat-priv.h" does
9404         it.  Don't include "unistd--.h" -- it wasn't ever used.
9405
9406         2006-01-17  Jim Meyering  <jim@meyering.net>
9407
9408         Rewrite fts.c not to change the current working directory,
9409         by using openat, fstatat, fdopendir, etc..
9410
9411         * lib/fts.c [! _LIBC]: Include "openat.h" and "unistd--.h".
9412         (HAVE_OPENAT_SUPPORT): Define.
9413         [_LIBC] (fchdir): Don't undef or define; no longer used.
9414         (FCHDIR): Define in terms of cwd_advance_fd rather than fchdir.
9415         Now, this `function' always succeeds, and consumes its file descriptor
9416         parameter -- so callers must not close such FDs.  Update callers.
9417         (diropen_fd, opendirat, cwd_advance_fd): New functions.
9418         (diropen): Add parameter, SP.  Adjust all callers.
9419         Implement using diropen_fd, rather than open.
9420         (fts_open): Initialize new member, fts_cwd_fd.
9421         Remove fts_rft-setting code.
9422         (fts_close): Close fts_cwd_fd, if necessary.
9423         (__opendir2): Define in terms of opendir or opendirat,
9424         depending on whether the FST_NOCHDIR flag is set.
9425         (fts_build): Since fts_safe_changedir consumes its FD, and since
9426         this code must do `closedir(dirp)', dup the dirfd(dirp) argument,
9427         and close the dup'd file descriptor upon failure.
9428         (fts_stat): Use fstatat(...AT_SYMLINK_NOFOLLOW) in place of lstat.
9429         (fts_safe_changedir): Tweak semantics to reflect that this function
9430         now calls cwd_advance_fd and hence consumes its FD argument.
9431         * lib/fts_.h [struct FTS] (fts_cwd_fd): New member.
9432         [struct FTS] (fts_rft): Remove now-unused member.
9433         [struct FTS] (fts_cycle.state): Improve comment.
9434
9435         * lib/openat.c (openat_needs_fchdir): New function.
9436         * lib/openat.h (openat_needs_fchdir): Declare it.
9437
9438 2006-08-16  Paul Eggert  <eggert@cs.ucla.edu>
9439
9440         * lib/memcoll.c (memcoll): Set errno = 0 in the shortcut case, too.
9441         Problem and fix reported by Pádraig Brady in
9442         <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00099.html>.
9443
9444 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9445
9446         * modules/cycle-check (configure.ac): Add gl_CYCLE_CHECK.
9447
9448 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9449
9450         * lib/memcoll.c (memcoll): Optimize for the common case where the
9451         arguments are bytewise equal.
9452
9453 2006-08-15  Paul Eggert  <eggert@cs.ucla.edu>
9454
9455         * doc/regexprops-generic.texi: Add a copyright notice.
9456
9457 2006-08-15  Bruno Haible  <bruno@clisp.org>
9458
9459         * modules/tmpdir (License): Change to LGPL.
9460
9461 2006-08-15  Bruno Haible  <bruno@clisp.org>
9462
9463         * gnulib-tool (func_all_modules, func_verify_module): COPYING is not a
9464         module.
9465
9466 2006-08-14  Simon Josefsson  <jas@extundo.com>
9467
9468         * config/srclist.txt: Add gnupload.
9469
9470 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9471
9472         Change copyright notice from LGPL 2 to GPL 2, since that's the
9473         standard form used in the gnulib repository.
9474         * tests/test-lock.c: Likewise.
9475         * tests/test-stdint.c: Likewise.
9476         * tests/test-tls.c: Likewise.
9477
9478         * users.txt: Add bison, diffutils, libprelude, prelude-lml,
9479         prelude-manager.  User shorter URLs for GNU projects, without '?'.
9480         Add copyright notice.
9481
9482         * check-module: Add copyright notice.  Output a copyright
9483         notice if "--version" is specified.
9484         * modules/COPYING: New file.
9485         * tests/test-getaddrinfo.c: Add copyright notice.
9486         * tests/test-verify.c: Likewise.
9487
9488 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9489
9490         Change copyright notice from LGPL 2 to GPL 2, since that's the
9491         standard form used in the gnulib repository.
9492         * lib/lock.c: LGPL -> GPL.
9493         * lib/lock.h: Likewise.
9494         * lib/strnlen1.c: Likewise.
9495         * lib/strnlen1.h: Likewise.
9496         * lib/tls.c: Likewise.
9497         * lib/tls.h: Likewise.
9498         * lib/tmpdir.c: Likewise.
9499
9500         * lib/TODO: Remove; this belongs only in coreutils.
9501
9502 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9503
9504         Add copyright notices to long-enough files that lack them, since
9505         otherwise the files aren't clearly free.  Use the same notice that
9506         getdate.texi already uses.
9507         * doc/alloca-opt.texi: Add copyright notice.
9508         * doc/alloca.texi: Likewise.
9509         * doc/ctime.texi: Likewise.
9510         * doc/functions.texi: Likewise.
9511         * doc/gcd.texi: Likewise.
9512         * doc/gnulib-tool.texi: Likewise.
9513         * doc/inet_ntoa.texi: Likewise.
9514         * doc/visibility.texi: Likewise.
9515
9516         * doc/getdate.texi: Update FDL version from 1.1 to 1.2.
9517         * doc/quote.texi: Add copyright notice.
9518
9519         * doc/solaris-versions: Add SunOS 5.10, SunOS 1.x, SunOS 4.0, SunOS
9520         4.0.x, SunOS 4.1.1.1, SunOS 4.1.1_U1, SunOS 4.1.3B.  SunOS 4.1.3
9521         was Solaris 1.1A.  Remove space before B in Solaris 1.1.1B.
9522         Mention SunOS 5.11.  Mention that everything before SunOS 5.7
9523         is now obsolete, and give a pointer to the Sun list.
9524         Add copyright notice.
9525
9526 2006-08-14  Paul Eggert  <eggert@cs.ucla.edu>
9527
9528         * config/srclistvars.sh: Add copyright notice.
9529
9530 2006-08-14  Eric Blake  <ebb9@byu.net>
9531
9532         Import the following change from libc:
9533
9534         2006-08-12  Ulrich Drepper  <drepper@redhat.com>
9535
9536         Upstream bug 2997.
9537         * lib/misc/error.c: Add space between program name and message if file
9538         name is missing.
9539
9540 2006-08-12  Karl Berry  <karl@gnu.org>
9541
9542         * config/srclist.txt (ssize_t.m4, sig_atomic_t.m4, signalblocking.m4):
9543         remove, these originate in gnulib now.
9544
9545 2006-08-11  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9546
9547         * doc/Makefile (standards.info standards.html standards.dvi):
9548         Also depend on make-stds.texi.
9549
9550 2006-08-11  Paul Eggert  <eggert@cs.ucla.edu>
9551
9552         * lib/pipe-safer.c (pipe_safer): Fix misspelling: HAVE_FUNC_PIPE ->
9553         HAVE_PIPE.  Fix a file descriptor leak when fd_safer fails.
9554
9555         * lib/regex_internal.c (re_string_skip_chars): Don't assume WEOF fits
9556         in wchar_t.  Problem reported by Eric Blake.
9557
9558         * lib/snprintf.c (snprintf): memcpy LEN bytes, not SIZE - 1, when
9559         LEN is smaller than SIZE.  Suggested by Bruno Haible.
9560         Also, help the compiler to keep LEN in a register.
9561
9562 2006-08-11  Eric Blake  <ebb9@byu.net>
9563
9564         * users.txt: Sort.  Add tar.
9565
9566 2006-08-11  Bruno Haible  <bruno@clisp.org>
9567
9568         * users.txt: New file.
9569
9570 2006-08-11  Bruno Haible  <bruno@clisp.org>
9571
9572         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Include <stdio.h> and <time.h>
9573         before <wchar.h>. Needed for OSF/1 and BSD/OS.
9574
9575 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
9576
9577         * modules/snprintf (Depends-on): Remove minmax.
9578         (Maintainer): Add self and Bruno.
9579
9580 2006-08-10  Paul Eggert  <eggert@cs.ucla.edu>
9581
9582         * lib/.cppi-disable: Add snprintf.h, socket_.h.
9583         * lib/snprintf.c: Include <errno.h> and <limits.h>.
9584         (EOVERFLOW): Define if the system does not.
9585         Do not include "minmax.h"; it wasn't used.
9586         (snprintf): Don't assume size_t promotes to an unsigned type.
9587         Fix bug when generated string was too long for the buffer: the
9588         buffer's contents are supposed to be the initial prefix of the
9589         output.  Don't assume vasnprintf returns EOVERFLOW if the size
9590         exceeds INT_MAX; do the check ourselves.
9591
9592         Import the following changes from libc:
9593
9594         2006-06-02  Jakub Jelinek  <jakub@redhat.com>
9595
9596         * lib/posix/regex_internal.c (re_string_skip_chars): If no character
9597         has been converted at all, set *last_wc to WEOF.  If mbrtowc failed,
9598         set wc to the byte which couldn't be converted.
9599         (re_string_reconstruct): Don't clear valid_raw_len before calling
9600         re_string_skip_chars.  If wc is WEOF after re_string_skip_chars, set
9601         tip_context using re_string_context_at.
9602
9603         2006-05-02  Ulrich Drepper  <drepper@redhat.com>
9604
9605         * lib/posix/regex.h: g++ still cannot handled [restrict].
9606
9607         2006-04-21  Ulrich Drepper  <drepper@redhat.com>
9608
9609         * lib/posix/regex.h: Remove special handling for VMS.
9610
9611 2006-08-10  Jim Meyering  <jim@meyering.net>
9612
9613         * modules/same-inode: New module.
9614         * modules/dev-ino: New module.
9615         * modules/cycle-check: Depend on these modules, rather than simply
9616         including their .h files.
9617         (Makefile.am): Don't list cycle-check.[ch] here, now that they're
9618         required via m4/cycle-check.m4.
9619         * modules/same: Depend on new same-inode module, rather than
9620         including same-inode.h.
9621         * modules/chdir-safer: New file.
9622
9623         * modules/chown (Depends-on): Add stat-macros.
9624
9625 2006-08-10  Jim Meyering  <jim@meyering.net>
9626
9627         * m4/cycle-check.m4: New file.
9628         Require gl_STRUCT_DEV_INO and gl_SAME_INODE.
9629         * m4/dev-ino.m4, m4/same-inode.m4: New files.
9630
9631 2006-08-10  Eric Blake  <ebb9@byu.net>
9632
9633         * modules/verror (Depends-on): Remove bogus gl_VERROR that snuck
9634         in from original proposal.
9635
9636 2006-08-10  Eric Blake  <ebb9@byu.net>
9637         and Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
9638
9639         * gnulib-tool (func_import): Detect unexpanded macros in gnulib
9640         namespace.
9641
9642 2006-08-10  Bruno Haible  <bruno@clisp.org>
9643
9644         * gnulib-tool (func_create_testdir): Detect unexpanded macros here
9645         as well.
9646
9647 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9648
9649         Sync from coreutils.
9650
9651         2006-07-19  Mike Frysinger  <vapier@gentoo.org>
9652
9653         * lib/mountlist.c [ME_REMOTE]: Filter out cifs.
9654         Reported by Toralf Förster in <http://bugs.gentoo.org/141012>.
9655
9656 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9657
9658         * modules/restrict: Remove; no longer needed now that we assume
9659         Autoconf 2.59 or later.
9660         * MODULES.html.sh: Remove 'restrict'.
9661         * modules/argp (Depends-on): Remove 'restrict'.
9662         * modules/base64 (Depends-on): Likewise.
9663         * modules/gc (Depends-on): Likewise.
9664         * modules/getaddrinfo (Depends-on): Likewise.
9665         * modules/glob (Depends-on): Likewise.
9666         * modules/inet_ntop (Depends-on): Likewise.
9667         * modules/inet_pton (Depends-on): Likewise.
9668         * modules/memxor (Depends-on): Likewise.
9669         * modules/regex (Depends-on): Likewise.
9670         * modules/strtok_r (Depends-on): Likewise.
9671         * modules/time_r (Depends-on): Likewise.
9672
9673 2006-08-09  Paul Eggert  <eggert@cs.ucla.edu>
9674
9675         * m4/argp.m4 (gl_ARGP): Require AC_C_RESTRICT.
9676         * m4/gc.m4 (gl_PREREQ_GC): Likewise.
9677         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
9678         * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Likewise.
9679         * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise.
9680         * m4/memxor.m4 (gl_MEMXOR): Likewise.
9681         * m4/restrict.m4: Remove; no longer needed.  All remaining uses of
9682         gl_C_RESTRICT replaced by AC_C_RESTRICT.
9683
9684         Merge from coreutils.
9685         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_C_RESTRICT, not
9686         gl_C_RESTRICT, now that we assume Autoconf 2.59 or later.
9687         * m4/strtok_r.m4 (gl_FUNC_STRTOK_R): Likewise.
9688         * m4/time_r.m4 (gl_TIME_R): Likewise.
9689
9690 2006-08-09  Karl Berry  <karl@gnu.org>
9691
9692         * config/srclist.txt: no more gettext-tools, per Bruno.
9693
9694 2006-08-08  Eric Blake  <ebb9@byu.net>
9695
9696         * modules/verror: New module.
9697         * MODULES.html.sh: Document it.
9698
9699 2006-08-08  Eric Blake  <ebb9@byu.net>
9700
9701         * lib/verror.h, lib/verror.c: New files.
9702
9703 2006-08-08  Eric Blake  <ebb9@byu.net>
9704
9705         * lib/verror.c (verror_at_line): Work around glibc bug 2997, so that
9706         verror_at_line output complies with GNU Coding Standards even when
9707         file is NULL.
9708
9709 2006-08-07  Bruno Haible  <bruno@clisp.org>
9710
9711         * lib/allocsa.h (sa_alignof) [_AIX]: Also consider 'long long' in newer
9712         versions of AIX.
9713         Reported by Ralf Wildenhues.
9714
9715 2006-08-07  Bruno Haible  <bruno@clisp.org>
9716
9717         * gnulib-tool (func_create_testdir): Wrap the set of autoconf snippets
9718         in an AC_DEFUN. Needed so that the autoconf snippets can use
9719         AC_REQUIRE.
9720
9721 2006-08-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
9722
9723         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9724         Initialize pkgdata_DATA.
9725         * modules/javaversion (Makefile.am): Add to pkgdata_DATA, rather than
9726         overriding it.
9727
9728 2006-08-06  Eric Blake  <ebb9@byu.net>
9729
9730         * lib/error.h: Fold in some upstream changes from glibc.
9731         * lib/error.c: Likewise.
9732
9733 2006-08-04  Bruno Haible  <bruno@clisp.org>
9734
9735         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9736         Make the mostlyclean-local rule depend on mostlyclean-generic.
9737         Reported by Jim Meyering. Solution suggested by Ralf Wildenhues.
9738
9739 2006-07-31  Bruno Haible  <bruno@clisp.org>
9740
9741         * m4/localcharset.m4 (gl_LOCALCHARSET): Remove tests for <stddef.h>,
9742         <stdlib.h>, <string.h>.
9743
9744 2006-07-30  Bruno Haible  <bruno@clisp.org>
9745
9746         * modules/readlink (License): Change to LGPL.
9747
9748 2006-07-30  Bruno Haible  <bruno@clisp.org>
9749
9750         * modules/javaversion (Makefile.am): Distribute javaversion.java and
9751         javaversion.class. Also install javaversion.class in $(pkgdatadir) and
9752         set PKGDATADIR to point to it.
9753
9754 2006-07-30  Bruno Haible  <bruno@clisp.org>
9755
9756         * modules/csharpexec (configure.ac): Comment out macro invocation.
9757         * modules/javaexec (configure.ac): Likewise.
9758         * modules/javacomp-script (configure.ac): Likewise.
9759
9760         * modules/csharpcomp-script (configure.ac): Use AC_REQUIRE.
9761
9762 2006-07-30  Bruno Haible  <bruno@clisp.org>
9763
9764         * modules/clean-temp (Depends-on): Add linkedhash-list, remove
9765         linked-list.
9766
9767 2006-07-30  Bruno Haible  <bruno@clisp.org>
9768
9769         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Assume <string.h> exists.
9770
9771 2006-07-30  Bruno Haible  <bruno@clisp.org>
9772
9773         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
9774         Initialize MOSTLYCLEANFILES to core and *.stackdump, so that core dumps
9775         get removed.
9776
9777 2006-07-29  Bruno Haible  <bruno@clisp.org>
9778
9779         Make it possible for gnulib-tool to work with locally modified or
9780         augmented gnulib repositories.
9781         * gnulib-tool (func_usage): Document --local-dir option.
9782         (local_gnulib_dir): New variable.
9783         Handle --local-dir option.
9784         (func_lookup_file): New function.
9785         (func_all_modules, func_verify_module): Look also in $local_gnulib_dir.
9786         (func_get_description, func_get_filelist, func_get_description,
9787         func_get_filelist, func_get_dependencies, func_get_autoconf_snippet,
9788         func_get_automake_snippet, func_get_include_directive,
9789         func_get_license, func_get_maintainer): Use func_lookup_file.
9790         (func_import, func_create_testdir): Use func_lookup_file.
9791
9792 2006-07-29  Bruno Haible  <bruno@clisp.org>
9793
9794         * modules/setenv (Depends-on): Add unistd.
9795
9796 2006-07-29  Bruno Haible  <bruno@clisp.org>
9797
9798         * lib/setenv.c: Undo unintended modification done on 2006-02-27.
9799
9800 2006-07-29  Bruno Haible  <bruno@clisp.org>
9801
9802         * lib/localcharset.c: Assume <stddef.h>, <stdlib.h>, <string.h> exist.
9803
9804 2006-07-29  Bruno Haible  <bruno@clisp.org>
9805
9806         * gnulib-tool (import, update): If there is no Makefile.am, look at
9807         aclocal.m4, instead of bailing out.
9808
9809 2006-07-29  Bruno Haible  <bruno@clisp.org>
9810
9811         * gnulib-tool (func_usage): Revert most of the 2006-07-15 change.
9812         Categorize the options by when they are useful.
9813
9814 2006-07-29  Bruno Haible  <bruno@clisp.org>
9815
9816         * gnulib-tool (func_usage): Document option --no-libtool.
9817         Handle option --no-libtool.
9818         (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Update
9819         for changed semantics of $libtool variable.
9820         (func_import): Likewise. If libtool is not used, show this through
9821         an option --no-libtool.
9822         (func_create_testdir): Update.
9823
9824 2006-07-29  Bruno Haible  <bruno@clisp.org>
9825
9826         * gnulib-tool (func_import): Extend error message about missing
9827         --doc-base.
9828
9829 2006-07-29  Bruno Haible  <bruno@clisp.org>
9830
9831         * gnulib-tool (func_import): Don't create the $docbase directory if
9832         there is no file to store there.
9833
9834 2006-07-29  Bruno Haible  <bruno@clisp.org>
9835
9836         * gnulib-tool (autoconf_minversion): If a --dir option is given and
9837         relevant, look for configure.ac there, not in the current directory.
9838         Also use a simple search for AC_PREREQ, not "autoconf --trace".
9839
9840 2006-07-29  Bruno Haible  <bruno@clisp.org>
9841
9842         * gnulib-tool (SORT): New variable.
9843         (func_usage): Undocument --assume-autoconf option.
9844         Remove --assume-autoconf option handling.
9845         (autoconf_minversion): Determine from the contents of configure.ac.
9846         (func_import): Remove autoconf_minversion handling.
9847         Suggested by Eric Blake.
9848
9849 2006-07-29  Bruno Haible  <bruno@clisp.org>
9850
9851         * doc/gnulib-tool.texi (gl_LIBTOOL): Mention --no-libtool option.
9852
9853 2006-07-29  Bruno Haible  <bruno@clisp.org>
9854
9855         * config/srclist.txt (*setenv.[ch]): Remove rules.
9856
9857 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9858
9859         * m4/inet_pton.m4, inet_ntop.m4: Check for netinet/in.h too.
9860
9861 2006-07-28  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
9862
9863         * lib/inet_ntop.h, inet_pton.h: Need to include netinet/in.h before
9864         arpa/inet.h.
9865
9866 2006-07-28  Simon Josefsson  <jas@extundo.com>
9867
9868         * modules/inet_ntop (Depends-on): Depend on arpa_inet.
9869         * modules/inet_pton (Depends-on): Likewise.
9870
9871 2006-07-28  Simon Josefsson  <jas@extundo.com>
9872
9873         * m4/netinet_in_h.m4: New file.
9874
9875 2006-07-28  Simon Josefsson  <jas@extundo.com>
9876
9877         * lib/inet_ntop.h, inet_pton.h: No need to guard netinet/in.h
9878         #include's.
9879
9880 2006-07-28  Simon Josefsson  <jas@extundo.com>
9881
9882         * lib/inet_ntop.h, inet_pton.h: No need to guard arpa/inet.h
9883         #include's.
9884
9885 2006-07-28  Paul Eggert  <eggert@cs.ucla.edu>
9886
9887         * lib/modechange.c (mode_compile): Numeric modes now affect setuid and
9888         setgid on directories only if they set these bits.
9889         * lib/modechange.h: Remove obsolete comment about masks.
9890
9891 2006-07-28  Eric Blake  <ebb9@byu.net>
9892
9893         * lib/regex_internal.h (struct re_dfa_t) [!_LIBC]: Avoid invalid C89
9894         macro expansion.
9895
9896 2006-07-28  Bruno Haible  <bruno@clisp.org>
9897
9898         * lib/inet_ntop.h, inet_pton.h: Use #if HAVE* instead of #ifdef HAVE*.
9899
9900 2006-07-28  Bruno Haible  <bruno@clisp.org>
9901
9902         * m4/mbchar.m4 (gl_MBCHAR): Also test for iswcntrl.
9903
9904 2006-07-28  Bruno Haible  <bruno@clisp.org>
9905
9906         * lib/mbchar.h (iswalnum, iswalpha, iswblank, iswcntrl, iswdigit,
9907         iswgraph, iswlower, iswprint, iswpunct, iswspace, iswupper, iswxdigit):
9908         Define fallbacks.
9909         Avoids link error on FreeBSD 4.x.
9910         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
9911
9912         * lib/wcwidth.h (iswprint): Assume an ASCII compatible wide character
9913         encoding.
9914         * lib/mbswidth.c (iswcntrl): Likewise.
9915
9916 2006-07-27  Bruno Haible  <bruno@clisp.org>
9917
9918         * m4/stdint.m4 (gl_STDINT_H): Define __STDC_CONSTANT_MACROS during the
9919         test.
9920
9921 2006-07-27  Bruno Haible  <bruno@clisp.org>
9922
9923         * lib/stdint_.h (INT*_C, UINT*_C) [C++]: Define these if
9924         __STDC_CONSTANT_MACROS is defined, not if __STDC_LIMIT_MACROS is
9925         defined.
9926
9927 2006-07-26  Eric Blake  <ebb9@byu.net>
9928
9929         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Check for missing pipe.
9930
9931 2006-07-26  Eric Blake  <ebb9@byu.net>
9932
9933         * lib/mkstemp-safer.c [! HAVE_MKSTEMP]: Add prototype for platforms
9934         like mingw that lack mkstemp.
9935         * lib/pipe-safer.c (pipe_safer) [!HAVE_FUNC_PIPE]: Provide fallback to
9936         avoid compilation warning on mingw.
9937
9938 2006-07-26  Bruno Haible  <bruno@clisp.org>
9939
9940         * m4/stdint.m4 (gl_STDINT_H): Also verify the existence of the macros
9941         INT*_MIN, INT_LEAST*_MAX, INT_LEAST*_MIN, UINT_LEAST*_MAX,
9942         INT_FAST*_MIN, INTPTR_MIN.
9943
9944 2006-07-25  Bruno Haible  <bruno@clisp.org>
9945
9946         * modules/version-etc (Depends-on): Add stdarg.
9947
9948 2006-07-25  Bruno Haible  <bruno@clisp.org>
9949
9950         * m4/stdint.m4 (gl_INTEGER_TYPE_SUFFIX): Avoid 'eval' in front of
9951         complex commands.
9952
9953 2006-07-25  Bruno Haible  <bruno@clisp.org>
9954
9955         * lib/version-etc.c (version_etc_va): Use va_copy, assumed to be
9956         defined in <stdarg.h> or config.h.
9957
9958 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9959
9960         * m4/stdio-safer.m4 (gl_FOPEN_SAFER, gl_TMPFILE_SAFER): New macros.
9961         (gl_STDIO_SAFER): Remove.
9962
9963 2006-07-24  Paul Eggert  <eggert@cs.ucla.edu>
9964
9965         * MODULES.html.sh (File stream based Input/Output):
9966         Add fopen-safer, tmpfile-safer; remove stdio-safer.
9967         * modules/getusershell (Depends-on): Change stdio-safer to fopen-safer.
9968         * modules/fopen-safer, modules/tmpfile-safer: New files.
9969         * modules/stdio-safer: Remove.
9970
9971 2006-07-24  Bruno Haible  <bruno@clisp.org>
9972
9973         * modules/tmpdir: New file.
9974         * MODULES.html.sh (File system functions): Add it.
9975
9976 2006-07-24  Bruno Haible  <bruno@clisp.org>
9977
9978         * modules/javacomp (Depends-on): Add unistd, javaversion, binary-io,
9979         getline, pathname, fwriteerror, clean-temp, xvasprintf, strstr.
9980
9981 2006-07-24  Bruno Haible  <bruno@clisp.org>
9982
9983         * modules/clean-temp: New file.
9984
9985 2006-07-24  Bruno Haible  <bruno@clisp.org>
9986
9987         * m4/tmpdir.m4: New file, from GNU gettext.
9988
9989 2006-07-24  Bruno Haible  <bruno@clisp.org>
9990
9991         * lib/tmpdir.h: New file, from GNU gettext.
9992         * lib/tmpdir.c: New file, from GNU gettext.
9993
9994 2006-07-24  Bruno Haible  <bruno@clisp.org>
9995
9996         * lib/clean-temp.h: New file, from GNU gettext.
9997         * lib/clean-temp.c: New file, from GNU gettext.
9998
9999 2006-07-23  Eric Blake  <ebb9@byu.net>
10000
10001         * modules/stdio-safer (Files): Add tmpfile-safer.c.
10002         (Depends-on): Add binary-io.
10003
10004 2006-07-23  Eric Blake  <ebb9@byu.net>
10005
10006         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add tmpfile-safer.c.
10007
10008 2006-07-23  Eric Blake  <ebb9@byu.net>
10009
10010         * lib/tmpfile-safer.c: New file.
10011         * lib/stdio-safer.h (fopen_safer): Add prototype.
10012         * lib/stdio--.h (tmpfile): Make safer.
10013
10014 2006-07-23  Bruno Haible  <bruno@clisp.org>
10015
10016         * lib/gl_anylinked_list2.h (ASYNCSAFE): New macro.
10017         (gl_linked_add_first, gl_linked_add_last, gl_linked_add_before,
10018         gl_linked_add_after, gl_linked_add_at, gl_linked_remove_node,
10019         gl_linked_remove_at): Use it.
10020
10021 2006-07-22  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
10022         and Simon Josefsson <jas@extundo.com>
10023
10024         * lib/getaddrinfo.h (AI_PASSIVE): Make sure it is defined.
10025
10026         * lib/getaddrinfo.c (getaddrinfo): Support AI_PASSIVE.
10027
10028 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10029
10030         * modules/close-stream: New file.
10031         * modules/closeout (Description): Make it clear that it exits
10032         with a diagnostic on error.
10033         (Depends-on): Add close-stream.  Remove fpending, stdbool.
10034         * MODULES.html.sh (File stream based Input/Output): Add close-stream.
10035
10036 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10037
10038         * m4/close-stream.m4: New file.
10039
10040 2006-07-22  Paul Eggert  <eggert@cs.ucla.edu>
10041
10042         * lib/close-stream.c, lib/close-stream.h: New files.
10043
10044 2006-07-22  Bruno Haible  <bruno@clisp.org>
10045
10046         Merge from GNU gettext 0.15.
10047
10048         2006-05-01  Bruno Haible  <bruno@clisp.org>
10049
10050                 * build-aux/javacomp.sh.in: Update for changed javacomp.m4.
10051
10052         2006-07-22  Bruno Haible  <bruno@clisp.org>
10053
10054                 * modules/javaversion: New file.
10055                 * MODULES.html.sh (Java): Add javaversion.
10056
10057         2006-03-12  Bruno Haible  <bruno@clisp.org>
10058
10059                 * build-aux/javaexec.sh.in: Update for changed javaexec.m4.
10060
10061         2005-12-04  Bruno Haible  <bruno@clisp.org>
10062
10063                 * build-aux/csharpexec.sh.in: Add support for 'clix' launcher
10064                 (untested).
10065
10066         2006-06-21  Bruno Haible  <bruno@clisp.org>
10067
10068                 Avoid warnings from recent versions of mcs.
10069                 * build-aux/csharpcomp.sh.in (options_mcs): Don't use options
10070                 -o, -L, -r any more. Use options documented since mcs-1.0
10071                 instead. Similarly for -g.
10072
10073         2005-12-04  Bruno Haible  <bruno@clisp.org>
10074
10075                 * build-aux/csharpcomp.sh.in: Suffix for resources is
10076                 .resources, not .resource.
10077
10078         2005-07-09  Bruno Haible  <bruno@clisp.org>
10079
10080                 * build-aux/csharpcomp.sh.in (options_csc): For -l option,
10081                 add a .dll suffix.
10082                 Reported by Mark Junker <mjscod@gmx.de>.
10083
10084         2006-07-22  Bruno Haible  <bruno@clisp.org>
10085
10086                 * modules/gettext: Upgrade to gettext-0.15.
10087                 (Files): Remove m4/isc-posix.m4. Add m4/lock.m4,
10088                 m4/visibility.m4.
10089                 Replace m4/inttypes.m4 with m4/inttypes-h.m4.
10090
10091 2006-07-22  Bruno Haible  <bruno@clisp.org>
10092
10093         Merge from GNU gettext 0.15.
10094
10095         2006-03-25  Bruno Haible  <bruno@clisp.org>
10096
10097                 * lib-link.m4 (AC_LIB_LINKFLAGS_FROM_LIBS): New macro.
10098
10099         2006-07-21  Bruno Haible  <bruno@clisp.org>
10100
10101                 * javacomp.m4 (gt_JAVACOMP): Convert target_version "null" to
10102                 "1.1".
10103
10104         2006-05-09  Bruno Haible  <bruno@clisp.org>
10105
10106                 * javacomp.m4 (gt_JAVACOMP): On Cygwin, set
10107                 CLASSPATH_SEPARATOR to a semicolon. Use CLASSPATH_SEPARATOR
10108                 for the conftestver execution.
10109
10110         2006-05-01  Bruno Haible  <bruno@clisp.org>
10111
10112                 * javacomp.m4 (gt_JAVACOMP): Accept a source-version and an
10113                 optional target-version argument. Verify that the compiler
10114                 groks source of the specified source-version, or add -source
10115                 option as necessary. Verify that the compiler produces
10116                 bytecode in the specified target-version, or add -target and
10117                 -source options as necessary. Make the result of the test
10118                 available as variable CONF_JAVAC. Also log error output in
10119                 config.log.
10120
10121         2006-03-11  Bruno Haible  <bruno@clisp.org>
10122
10123                 * javacomp.m4 (gt_JAVACOMP): Treat gcj-4.x like gcj-3.x.
10124
10125         2006-05-09  Bruno Haible  <bruno@clisp.org>
10126
10127                 * javaexec.m4 (gt_JAVAEXEC): On Cygwin, set
10128                 CLASSPATH_SEPARATOR to a semicolon.
10129
10130         2006-03-12  Bruno Haible  <bruno@clisp.org>
10131
10132                 * javaexec.m4 (gt_JAVAEXEC): Make the result of the test
10133                 available as variable CONF_JAVA, for subsequent autoconf
10134                 tests. Also log error output in config.log.
10135
10136         2006-07-19  Bruno Haible  <bruno@clisp.org>
10137
10138                 * getline.m4 (AM_FUNC_GETLINE): When cross-compiling, assume
10139                 that getline works on glibc2 systems. Needed to avoid trouble
10140                 in relocatable.c.
10141                 Reported by Nils Magnus Larsgard <nmlarsgaard@atmel.no>.
10142
10143         2005-12-04  Bruno Haible  <bruno@clisp.org>
10144
10145                 * csharpexec.m4 (gt_CSHARPEXEC): Add support for 'clix'
10146                 launcher (untested).
10147
10148         2005-12-04  Bruno Haible  <bruno@clisp.org>
10149
10150                 * csharpcomp.m4 (gt_CSHARPCOMP): Also set CSHARPCOMPFLAGS.
10151
10152         2006-07-22  Bruno Haible  <bruno@clisp.org>
10153
10154                 * gettext.m4: Update from GNU gettext-0.15.
10155                 * nls.m4: Likewise.
10156                 * po.m4: Likewise.
10157                 * inttypes-pri.m4: Likewise.
10158                 * inttypes-h.m4: Renamed from inttypes.m4.
10159                 (gl_HEADER_INTTYPES_H): Renamed from gt_HEADER_INTTYPES_H.
10160
10161 2006-07-22  Bruno Haible  <bruno@clisp.org>
10162
10163         Merge from GNU gettext 0.15.
10164
10165         2005-07-05  Bruno Haible  <bruno@clisp.org>
10166
10167                 * printf-args.c (printf_fetchargs): Work around broken
10168                 definition of wint_t on mingw.
10169
10170         2005-02-12  Bruno Haible  <bruno@clisp.org>
10171
10172                 * xallocsa.h: Add extern "C" for C++.
10173
10174         2006-05-17  Bruno Haible  <bruno@clisp.org>
10175
10176                 Cygwin portability.
10177                 * progreloc.c (WIN32_NATIVE): Renamed from WIN32.
10178
10179         2006-04-30  Bruno Haible  <bruno@clisp.org>
10180
10181                 * progreloc.c: Include <mach-o/dyld.h> if available.
10182                 (find_executable): Use _NSGetExecutablePath when possible.
10183
10184         2006-05-06  Charles Wilson  <cygwin@cwilson.fastmail.fm>
10185
10186                 * progreloc.c (maybe_executable) [CYGWIN]: Use the access()
10187                 function.
10188
10189         2005-12-29  Bruno Haible  <bruno@clisp.org>
10190
10191                 * progreloc.c (set_program_name_and_installdir): Fix
10192                 compilation error.
10193
10194         2005-12-04  Bruno Haible  <bruno@clisp.org>
10195
10196                 Cygwin portability.
10197                 * progreloc.c: Include <windows.h> also on Cygwin.
10198                 (find_executable): Add support for Cygwin.
10199                 (set_program_name_and_installdir): Handle also platforms with
10200                 nonempty EXEEXT.
10201
10202         2006-07-11  Bruno Haible  <bruno@clisp.org>
10203
10204                 * javacomp.c: Fix a comment.
10205                 Reported by Jim Meyering.
10206
10207         2006-04-30  Bruno Haible  <bruno@clisp.org>
10208
10209                 * javacomp.h (compile_java_class): Add source_version,
10210                 target_version arguments.
10211                 * javacomp.c: Rewritten to choose only a compiler that
10212                 respects the specified source_version and target_version.
10213
10214         2006-06-27  Bruno Haible  <bruno@clisp.org>
10215
10216                 Assume correct S_ISDIR macro.
10217                 * mkdtemp.c: Remove test of STAT_MACROS_BROKEN.
10218
10219         2006-07-22  Bruno Haible  <bruno@clisp.org>
10220
10221                 * javaversion.h: New file, from GNU gettext.
10222                 * javaversion.c: New file, from GNU gettext.
10223                 * javaversion.java: New file, from GNU gettext.
10224                 * javaversion.class: New file, from GNU gettext.
10225
10226         2006-05-17  Bruno Haible  <bruno@clisp.org>
10227
10228                 Cygwin portability.
10229                 * javaexec.c (execute_java_class): Test for jview program
10230                 also on Cygwin.
10231
10232         2006-04-09  Bruno Haible  <bruno@clisp.org>
10233
10234                 * fatal-signal.c: Don't include string.h.
10235                 (at_fatal_signal): Use a copying loop instead of memcpy.
10236
10237         2005-12-04  Bruno Haible  <bruno@clisp.org>
10238
10239                 * csharpexec.c: Add support for 'clix' launcher (untested).
10240                 (execute_csharp_using_sscli): New function.
10241                 (execute_csharp_program): Call it.
10242
10243         2006-06-21  Bruno Haible  <bruno@clisp.org>
10244
10245                 Avoid warnings from recent versions of mcs.
10246                 * csharpcomp.c (compile_csharp_using_mono): Don't use options
10247                 -o, -L, -r any more. Use options documented since mcs-1.0
10248                 instead. Similarly for -g.
10249
10250         2005-07-09  Bruno Haible  <bruno@clisp.org>
10251
10252                 * csharpcomp.c (compile_csharp_using_sscli): For -l option,
10253                 add a .dll suffix.
10254                 Reported by Mark Junker <mjscod@gmx.de>.
10255
10256         2006-06-17  Bruno Haible  <bruno@clisp.org>
10257
10258                 * config.charset: Update for NetBSD 3.0.
10259
10260         2006-05-17  Bruno Haible  <bruno@clisp.org>
10261
10262                 Cygwin portability.
10263                 * localcharset.c (WIN32_NATIVE): Renamed from WIN32.
10264
10265         2006-05-16  Bruno Haible  <bruno@clisp.org>
10266
10267                 * localcharset.c [CYGWIN]: Include <windows.h>.
10268                 (get_charset_aliases): For Cygwin, return the same CPxxx
10269                 aliases list as under WIN32.
10270                 (locale_charset) [CYGWIN]: Try to retrieve the encoding from
10271                 the environment variables. Fall back to GetACP().
10272
10273         2006-04-05  Bruno Haible  <bruno@clisp.org>
10274
10275                 * config.charset: Update Juan Manuel Guerrero's address.
10276
10277         2005-02-12  Bruno Haible  <bruno@clisp.org>
10278
10279                 * allocsa.h: Add extern "C" for C++.
10280
10281         2005-02-10  Bruno Haible  <bruno@clisp.org>
10282
10283                 * allocsa.h (sa_alignof): Define differently with AIX xlc, to
10284                 avoid a bug of this compiler on AIX 3.2.5 dealing with enums.
10285
10286         2006-07-22  Bruno Haible  <bruno@clisp.org>
10287
10288                 * gettext.h: Update to GNU gettext-0.15.
10289
10290 2006-07-22  Bruno Haible  <bruno@clisp.org>
10291
10292         * config/srclist.txt: Resync printf-args.c, vasnprintf.c,
10293         localcharset.c, mkdtemp.c, config.rpath, lib-ld.m4, lib-link.m4,
10294         lib-prefix.m4, longdouble.m4, ssize_t.m4.
10295
10296 2006-07-21  Eric Blake  <ebb9@byu.net>
10297
10298         * modules/stdlib-safer: New file.
10299         * MODULES.html.sh (File stream based Input/Output): Add
10300         stdlib-safer.
10301
10302 2006-07-21  Eric Blake  <ebb9@byu.net>
10303
10304         * lib/stdlib-safer.h: New file from coreutils, required by
10305         stdlib--.h.
10306
10307 2006-07-20  Paul Eggert  <eggert@cs.ucla.edu>
10308
10309         * gnulib-tool (func_usage): Document --assume-autoconf='latest-stable'.
10310
10311 2006-07-20  Bruno Haible  <bruno@clisp.org>
10312
10313         * gnulib-tool: Recognize new option --assume-autoconf.
10314         (autoconf_minversion): New variable.
10315         (func_get_filelist): Use it to decide whether to add onceonly_2_57.m4.
10316
10317 2006-07-20  Bruno Haible  <bruno@clisp.org>
10318
10319         * MODULES.html.sh (func_all_modules): Add a missing func_begin_table.
10320
10321 2006-07-19  Derek R. Price  <derek@ximbiot.com>
10322
10323         * lib/getaddrinfo.h: Don't define unimplemented AI_* flags.
10324         Reindent and repaginate.
10325
10326 2006-07-19  Derek Price  <derek@ximbiot.com>
10327
10328         * doc/gnulib.texi (Libtool and Windows):  Eliminate passive voice.
10329         Correct grammar.
10330
10331 2006-07-17  Bruno Haible  <bruno@clisp.org>
10332
10333         * modules/list: New file.
10334         * modules/array-list: New file.
10335         * modules/carray-list, modules/carray-list-tests: New files.
10336         * modules/linked-list, modules/linked-list-tests: New files.
10337         * modules/avltree-list, modules/avltree-list-tests: New files.
10338         * modules/rbtree-list, modules/rbtree-list-tests: New files.
10339         * modules/linkedhash-list, modules/linkedhash-list-tests: New files.
10340         * modules/avltreehash-list, modules/avltreehash-list-tests: New files.
10341         * modules/rbtreehash-list, modules/rbtreehash-list-tests: New files.
10342         * modules/oset: New file.
10343         * modules/array-oset: New file.
10344         * modules/avltree-oset, modules/avltree-oset-tests: New files.
10345         * modules/rbtree-oset, modules/rbtree-oset-tests: New files.
10346         * tests/test-carray_list.c: New file.
10347         * tests/test-linked_list.c: New file.
10348         * tests/test-avltree_list.c: New file.
10349         * tests/test-rbtree_list.c: New file.
10350         * tests/test-linkedhash_list.c: New file.
10351         * tests/test-avltreehash_list.c: New file.
10352         * tests/test-rbtreehash_list.c: New file.
10353         * tests/test-avltree_oset.c: New file.
10354         * tests/test-rbtree_oset.c: New file.
10355         * MODULES.html.sh (Container data structures): New section.
10356
10357 2006-07-17  Bruno Haible  <bruno@clisp.org>
10358
10359         * m4/gl_list.m4: New file.
10360
10361 2006-07-17  Bruno Haible  <bruno@clisp.org>
10362
10363         * lib/gl_list.h: New file.
10364         * lib/gl_list.c: New file.
10365         * lib/gl_array_list.h: New file.
10366         * lib/gl_array_list.c: New file.
10367         * lib/gl_carray_list.h: New file.
10368         * lib/gl_carray_list.c: New file.
10369         * lib/gl_linked_list.h: New file.
10370         * lib/gl_linked_list.c: New file.
10371         * lib/gl_anylinked_list1.h: New file.
10372         * lib/gl_anylinked_list2.h: New file.
10373         * lib/gl_avltree_list.h: New file.
10374         * lib/gl_avltree_list.c: New file.
10375         * lib/gl_anyavltree_list1.h: New file.
10376         * lib/gl_anyavltree_list2.h: New file.
10377         * lib/gl_rbtree_list.h: New file.
10378         * lib/gl_rbtree_list.c: New file.
10379         * lib/gl_anyrbtree_list1.h: New file.
10380         * lib/gl_anyrbtree_list2.h: New file.
10381         * lib/gl_anytree_list1.h: New file.
10382         * lib/gl_anytree_list2.h: New file.
10383         * lib/gl_linkedhash_list.h: New file.
10384         * lib/gl_linkedhash_list.c: New file.
10385         * lib/gl_anyhash_list1.h: New file.
10386         * lib/gl_anyhash_list2.h: New file.
10387         * lib/gl_avltreehash_list.h: New file.
10388         * lib/gl_avltreehash_list.c: New file.
10389         * lib/gl_rbtreehash_list.h: New file.
10390         * lib/gl_rbtreehash_list.c: New file.
10391         * lib/gl_anytreehash_list1.h: New file.
10392         * lib/gl_anytreehash_list2.h: New file.
10393
10394         * lib/gl_oset.h: New file.
10395         * lib/gl_oset.c: New file.
10396         * lib/gl_array_oset.h: New file.
10397         * lib/gl_array_oset.c: New file.
10398         * lib/gl_avltree_oset.h: New file.
10399         * lib/gl_avltree_oset.c: New file.
10400         * lib/gl_rbtree_oset.h: New file.
10401         * lib/gl_rbtree_oset.c: New file.
10402         * lib/gl_anytree_oset.h: New file.
10403
10404 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10405
10406         * m4/mkancesdirs.m4: New file.
10407         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Mention dirchownmod.c,
10408         dirchownmod.h.  Don't require AC_FUNC_ALLOCA, gl_AFS, gl_CHDIR_SAFER;
10409         no longer needed.  Require gl_FUNC_LCHOWN, since dirchownmod.c needs
10410         it.
10411
10412 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10413
10414         * lib/dirchownmod.c, lib/dirchownmod.h, lib/mkancesdirs.c:
10415         * lib/mkancesdirs.h: New files.
10416         * lib/mkdir-p.c: Don't include alloca.h, stdio.h, sys/types.h,
10417         unistd.h, string.h, chdir-safer.h, dirname.h, lchmod.h, lchown.h,
10418         save-cwd.h.  Instead, include dirchownmod.h and mkancesdirs.h.
10419         (make_dir_parents): New args MAKE_ANCESTOR, OPTIONS, ANNOUNCE,
10420         MODE_BITS.  Remove options VERBOSE_FMT_STRING, CWD_ERRNO.  All
10421         callers changed.  Revamp internals significantly, by not
10422         attempting to create directories that are temporarily more
10423         permissive than the final results.  Do not attempt to use
10424         save_cwd/restore_cwd; it isn't worth it for mkdir and install.
10425         This removes some race conditions, fixes some bugs, and simplifies
10426         things.  Use new dirchownmod function to do owner and mode changes.
10427         * lib/mkdir-p.h: Likewise.
10428         * lib/modechange.c (octal_to_mode): New function.
10429         (struct mode_change): New member mentioned.
10430         (make_node_op_equals): New arg mentioned.  All callers changed.
10431         (mode_compile): Keep track of which mode bits the user has explicitly
10432         mentioned.
10433         (mode_adjust): New arg DIR, so that we implement the X op correctly.
10434         New arg PMODE_BITS, to keep track of which mode bits the user
10435         mentioned; it treats S_ISUID and S_ISGID speciall.
10436         All callers changed.
10437         * lib/modechange.h: Likewise.
10438
10439 2006-07-16  Paul Eggert  <eggert@cs.ucla.edu>
10440
10441         * MODULES.html.sh: Add mkancestors.
10442         * modules/mkancesdirs: New module.
10443         * modules/mkdir-p (Files): Remove lib/chdir-safer.c, lib/chdir-safer.h,
10444         lib/same-inode.h, m4/afs.m4, m4/chdir-safer.m4.
10445         The chdir-safer and afs files are now orphans; I'll remove them
10446         unless someone speaks up.
10447         Add lib/dirchownmod.c, lib/dirchownmod.h.
10448         (Depends-on): Remove alloca, chown, save-cwd, dirname.
10449         Add lchown, mkancesdirs.
10450         (Maintainer): Add self.
10451
10452 2006-07-15  Karl Berry  <karl@gnu.org>
10453
10454         * gnulib-tool: help message wording/arrangement.
10455
10456 2006-07-14  Simon Josefsson  <jas@extundo.com>
10457
10458         * doc/gnulib.texi (Libtool and Windows): New section.
10459
10460 2006-07-12  Simon Josefsson  <jas@extundo.com>
10461
10462         * modules/gendocs (License): Fix license, approved by Karl.
10463
10464 2006-07-12  Eric Blake  <ebb9@byu.net>
10465
10466         * MODULES.html.sh: Add gendocs.
10467
10468 2006-07-11  Eric Blake  <ebb9@byu.net>
10469
10470         * modules/fdl: New module, to install doc/fdl.texi.
10471         * MODULES.html.sh: Add new section for documentation modules.
10472         * gnulib-tool: Avoid space-tab.
10473         (--doc-base): New option, to manage files from doc.
10474
10475 2006-07-11  Eric Blake  <ebb9@byu.net>
10476
10477         * m4/absolute-header.m4: Fix comments to match recent change.
10478
10479 2006-07-11  Eric Blake  <ebb9@byu.net>
10480
10481         * gnulib-tool: List --doc-base before --tests-base.
10482
10483 2006-07-11  Derek R. Price  <derek@ximbiot.com>
10484
10485         * lib/glob.c: s/NAMLEN/_D_EXACT_NAMLEN/.
10486
10487 2006-07-11  Bruno Haible  <bruno@clisp.org>
10488
10489         * README: Mention where to put documentation.
10490
10491 2006-07-10  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10492
10493         * doc/functions.texi, gnulib-tool.texi, gnulib.texi: Fix some typos.
10494
10495 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
10496
10497         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Like today's change
10498         to stdint.m4.
10499
10500 2006-07-10  Paul Eggert  <eggert@cs.ucla.edu>
10501
10502         * m4/stdint.m4 (gl_STDINT_H): Like yesterday's change to
10503         absolute-header.m4.  Also, set ABSOLUTE_STDINT_H to a string
10504         "no/such/file/stdint.h" when there is no such file, so that
10505         the resulting C code can be parsed by dodgy compilers.
10506         Problems reported by Bob Proulx.
10507
10508 2006-07-10  Derek R. Price  <derek@ximbiot.com>
10509
10510         * lib/backupfile.c, dirfd.h, fts.c, getcwd.c, glob.c, glob_.h:
10511         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
10512         macros into the GNU _D_EXACT_NAMLEN.
10513         * lib/savedir.c:  Likewise.
10514         (savedirstream): Use _D_EXACT_NAMLEN in preference to strlen.
10515
10516 2006-07-10  Derek R. Price  <derek@ximbiot.com>
10517         and Paul Eggert  <eggert@cs.ucla.edu>
10518
10519         * m4/backupfile.m4, d-ino.m4, d-type.m4, dirfd.m4, fts.m4, getcwd.m4:
10520         * m4/savedir.m4:
10521         Ignore the obsolescent !HAVE_DIRENT_H case.  Consolidate NAMLEN
10522         macros into the GNU _D_EXACT_NAMLEN.
10523
10524 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10525
10526         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Use "" rather than <>
10527         around the absolute name, to work around a problem with the HP-UX
10528         11.23 native C compiler, reported by Bob Proulx.
10529
10530 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10531
10532         * doc/maintain.texi, make-stds.texi: Sync from
10533         <http://savannah.gnu.org/projects/gnustandards>.
10534
10535 2006-07-09  Paul Eggert  <eggert@cs.ucla.edu>
10536
10537         * build-aux/depcomp, build-aux/install-sh: Sync from Automake.
10538
10539 2006-07-09  Jim Meyering  <jim@meyering.net>
10540
10541         * m4/glob.m4: Remove a doubled word in a comment.
10542
10543 2006-07-09  Jim Meyering  <jim@meyering.net>
10544
10545         * lib/argp-pv.c: Remove a doubled word in a comment.
10546         * lib/check-version.c (check_version): Likewise.
10547         * lib/javacomp.c (compile_java_class): Likewise.
10548
10549 2006-07-08  Paul Eggert  <eggert@cs.ucla.edu>
10550
10551         * gnulib-tool (func_get_filelist): Don't echo m4/onceonly_2_57.m4,
10552         for the benefit of people using Autoconf 2.60.  If you want to
10553         support older Autoconf versions you can copy m4/onceonly_2_57.m4
10554         (or m4/onceonly.m4, if pre-2.57) manually.
10555
10556 2006-07-08  Jim Meyering  <jim@meyering.net>
10557
10558         * m4/link-follow.m4: Remove one of two adjacent "whether"s in a
10559         comment.
10560         * m4/getopt.m4: Remove one of two adjacent "your"s in a comment.
10561         * m4/regex.m4 (gl_REGEX): Remove one of two adjacent "the"s in a
10562         comment.
10563
10564 2006-07-08  Jim Meyering  <jim@meyering.net>
10565
10566         * lib/getndelim2.h (getndelim2): Remove doubled "after" in comment.
10567
10568 2006-07-07  Simon Josefsson  <jas@extundo.com>
10569
10570         * tests/test-crc.c: Change expected crc value, the test vector
10571         were probably computed using the old broken crc.c?
10572
10573 2006-07-06  Simon Josefsson  <jas@extundo.com>
10574
10575         * modules/sys_socket (Files): Add m4/sockpfaf.m4 (this module is
10576         now the canonical place for the M4 file).
10577
10578         * modules/getaddrinfo (Files): Remove m4/sockpfaf.m4, we get it
10579         from the sys_socket dependency now.
10580
10581         * modules/inet_pton (Files): Ditto.
10582
10583         * modules/inet_ntop (Files): Ditto.
10584
10585 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
10586
10587         * modules/getusershell (configure.ac): Use gl_FUNC_GETUSERSHELL,
10588         not gl_PREREQ_GETUSERSHELL.
10589
10590 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10591
10592         * m4/_inttypes_h.m4 (gl_INTTYPES_H): Use AC_CHECK_DECLS_ONCE
10593         with only one argument, for Autoconf 2.60.
10594         * m4/fileblocks.m4 (gl_PREREQ_FILEBLOCKS): AC_CHECK_DECLS_ONCE may
10595         expand to nothing, so add a shell command to avoid syntax error.
10596         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
10597
10598 2006-07-06  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10599
10600         * lib/strtod.c (strtod): cast the argument of tolower to unsigned char.
10601
10602 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10603
10604         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't check for getenv decl;
10605         no longer needed.  Check for isblank decl.
10606         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Don't check for getenv decl.
10607         * m4/regex.m4 (gl_PREREQ_REGEX): Dheck for isblank decl instead
10608         of existence.
10609
10610 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10611
10612         * lib/getloadavg.c: Use __VMS, not VMS.
10613         * lib/getopt.c: Likewise.
10614         * lib/getpagesize.h: Likewise.
10615         * lib/glob.c: Remove most VMS cruft; it hasn't been tested for a while
10616         and probably does not work.
10617
10618 2006-07-06  Paul Eggert  <eggert@cs.ucla.edu>
10619
10620         * lib/.cppi-disable: Add wcwidth.
10621         * lib/fnmatch.c (ISBLANK): Remove.  All uses changed to isblank.
10622         (isblank) [! (defined isblank || HAVE_DECL_ISBLANK)]: New macro.
10623         (ISGRAPH): Remove.  All uses changed to isgraph.
10624         (FOLD) [!defined _LIBC]: Remove special case.
10625         * lib/getdate.y (lookup_word): Remove no-longer-needed call to islower.
10626         * lib/regex_internal.h (isblank): Depend on HAVE_DECL_ISBLANK, not
10627         HAVE_ISBLANK.
10628         * lib/strftime.c (TOLOWER, TOUPPER) [!defined _LIBC]: Remove special
10629         case.
10630
10631 2006-07-06  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
10632
10633         * lib/getaddrinfo.c: Changes to compile under MSVC6: changed
10634         '#if WIN32_NATIVE' to '#ifdef' & moved WSAAPI macro inside
10635         brackets.  Other minor changes to suppress some compiler
10636         warnings.
10637
10638 2006-07-06  Derek R. Price  <derek@ximbiot.com>
10639         and Paul Eggert  <eggert@cs.ucla.edu>
10640
10641         * m4/backupfile.m4 (gl_BACKUPFILE): Check for dirent.h, instead
10642         of invoking obsolescent AC_HEADER_DIRENT macro.
10643         * m4/d-ino.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_INO): Likewise.
10644         * m4/d-type.m4 (gl_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Likewise.
10645         * m4/dirfd.m4 (gl_FUNC_DIRFD): Likewise.
10646         * m4/fts.m4 (gl_FUNC_FTS_CORE): Likewise.
10647         * m4/getcwd.m4 (gl_PREREQ_GETCWD): Likewise.
10648         * m4/glob.m4 (gl_PREREQ_GLOB): Likewise.
10649         * m4/savedir.m4 (gl_SAVEDIR): Likewise.
10650         * m4/readdir.m4: Remove; no longer needed.
10651
10652 2006-07-06  Derek R. Price  <derek@ximbiot.com>
10653         and Paul Eggert  <eggert@cs.ucla.edu>
10654
10655         * lib/backupfile.c [HAVE_DIRENT_H && ! HAVE_NDIR_H]:
10656         Don't worry about this obsolete case any more.
10657         (HAVE_DIR): Remove.  All uses removed; we now assume you can read
10658         directories.
10659         * lib/dirfd.h [HAVE_DIRENT_H && ! HAVE_NDIR_H]: Don't
10660         worry about this obsolete case any more.
10661         * lib/fts.c: Likewise.
10662         * lib/getcwd.c: Likewise.
10663         * lib/glob.h: Likewise.
10664         * lib/savedir.c: Likewise.
10665
10666 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
10667
10668         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Use AC_CHECK_DECLS_ONCE
10669         rather than AC_CHECK_DECLS for strtoimax and strtoumax.
10670         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Remove; no longer
10671         needed.
10672         All uses removed.
10673         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10674         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
10675         * m4/exclude.m4 (gl_EXCLUDE): Don't check for isascii; no longer
10676         needed.
10677         * m4/getdate.m4 (gl_GETDATE): Likewise.
10678         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
10679         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
10680         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
10681         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10682         * m4/strtoul.m4 (gl_PREREQ_STRTOUL): Likewise.
10683         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
10684         * m4/exclude.m4 (gl_EXCLUDE): Don't require AC_C_INLINE; no longer
10685         needed.
10686
10687 2006-07-05  Paul Eggert  <eggert@cs.ucla.edu>
10688
10689         * lib/memcasecmp.c: Include <limits.h>.
10690         (memcasecmp): Don't assume UCHAR_MAX <= INT_MAX.
10691         * lib/strtod.c (strtod): Don't assume isspace works on negative chars.
10692         Don't assume isdigit succeeds only on '0' through '9'.
10693
10694 2006-07-05  Eric Blake  <ebb9@byu.net>
10695
10696         * modules/getaddrinfo (Depends-on): Add snprintf.
10697
10698 2006-07-05  Eric Blake  <ebb9@byu.net>
10699
10700         * m4/sockpfaf.m4 (gl_SOCKET_FAMILIES): Use gl_HEADER_SYS_SOCKET
10701         to avoid 'header present but could not be compiled' on cygwin.
10702
10703 2006-07-05  Eric Blake  <ebb9@byu.net>
10704
10705         * lib/getaddrinfo.h (NI_NUMERICHOST, NI_NUMERICSERV): Define if
10706         missing from netdb.h.
10707         * lib/getaddrinfo.c (includes): Include inet_ntop and snprintf.
10708
10709 2006-07-05  Derek R. Price  <derek@ximbiot.com>
10710
10711         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Don't require AC_HEADER_STDC;
10712         no longer needed.
10713         * m4/exclude.m4 (gl_EXCLUDE): Likewise.
10714         * m4/getdate.m4 (gl_GETDATE): Likewise.
10715         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Likewise.
10716         * m4/memcasecmp.m4 (gl_MEMCASECMP): Likewise.
10717         * m4/strtod.m4 (gl_FUNC_STRTOD): Likewise.
10718         * m4/strtol.m4 (gl_PREREQ_STRTOL): Likewise.
10719         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
10720
10721 2006-07-05  Derek R. Price  <derek@ximbiot.com>
10722
10723         * lib/exclude.c (IN_CTYPE_DOMAIN, is_space): Remove; no longer needed.
10724         All uses of is_space replaced by isspace.
10725         * lib/exit.h: Don't talk about STDC_HEADERS.
10726         * lib/fnmatch.c (ISASCII): Remove; no longer needed.  All uses removed.
10727         (ISPRINT, ISDIGIT, ISALNUM, ISALPHA, ISCNTRL, ISLOWER, ISPUNCT):
10728         (ISSPACE, ISUPPER, ISXDIGIT): Remove; no longer needed.  All uses
10729         replaced by isprint etc.
10730         * lib/getdate.y (IN_CTYPE_DOMAIN, ISSPACE, ISALPHA, ISLOWER): Likewise.
10731         * lib/getusershell.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
10732         * lib/memcasecmp.c (IN_CTYPE_DOMAIN, ISLOWER, TOUPPER): Likewise.
10733         * lib/strtod.c (IN_CTYPE_DOMAIN, ISSPACE, ISDIGIT, TOLOWER): Likewise.
10734         * lib/strtol.c (IN_CTYPE_DOMAIN): Likewise.
10735         * lib/xstrtol.c (IN_CTYPE_DOMAIN, ISSPACE): Likewise.
10736
10737 2006-07-05  Bruno Haible  <bruno@clisp.org>
10738
10739         * m4/strndup.m4 (gl_FUNC_STRNDUP): When cross-compiling, check whether
10740         the function exists, before testing against AIX.
10741         Reported by Martin Lambers <marlam@marlam.de>.
10742
10743 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10744
10745         * modules/cycle-check (lib_SOURCES): Add same-inode.h.
10746         From Mark D. Baushke.
10747
10748 2006-07-04  Paul Eggert  <eggert@cs.ucla.edu>
10749
10750         * m4/absolute-header.m4 (gl_ABSOLUTE_HEADER): Prepend three slashes
10751         to the absolute name, not just one, to bypass Sun C 5.8's
10752         "warning: #include of /usr/include/... may be non-portable".
10753
10754 2006-07-04  Eric Blake  <ebb9@byu.net>
10755
10756         * modules/dirname-tests: New test module.
10757         * tests/test-dirname.c: New file, replacing dirname.c
10758         TEST_DIRNAME section that was recently deleted.
10759
10760 2006-07-04  Bruno Haible  <bruno@clisp.org>
10761
10762         Assume ANSI C header files and <ctype.h> functions.
10763         * lib/mbswidth.c (IN_CTYPE_DOMAIN, ISPRINT, ISCNTRL): Remove macros.
10764         (mbsnwidth): Use isprint, iscntrl instead.
10765
10766 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10767
10768         Merge from coreutils.
10769         * MODULES.html.sh: Add xstrtold.
10770         * modules/xstrtold: New file.
10771         * modules/cycle-check (Files): Add lib/same-inode.h.
10772         * modules/dirname (Files): Add m4/double-slash-root.m4.
10773         * modules/getcwd (Files): Add m4/getcwd-abort-bug.m4.
10774         * modules/mkdir-p (Files): Add lib/same-inode.h.
10775         * modules/same (Files): Add lib/same-inode.h.
10776
10777 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10778
10779         * m4/absolute-header.m4: Renamed from full-header-path.m4.
10780         This is to keep the terminology clean; POSIX talks about
10781         "absolute pathnames", not "full pathnames", but the GNU
10782         Coding Standards say to use "path" for something else;
10783         so use "absolute" to keep both sides happy.
10784         (gl_ABSOLUTE_HEADER): Renamed from gl_FULL_HEADER_PATH.
10785         Set gl_absolute_header, not gl_full_header_path.
10786         Set gl_cv_absolute_<header>, not gl_full_path_<header>.
10787         Define ABSOLUTE_<HEADER>, not FULL_PATH_<HEADER>.
10788         All uses changed.
10789
10790         Merge from coreutils.
10791
10792         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10793
10794         * m4/c-strtod.m4 (gl_C_STRTOLD): Add c-strtod.c to LIBSOURCES.
10795         Require gl_USE_SYSTEM_EXTENSIONS, not gl_C_STRTOD, since we don't
10796         want to require the building of c-strtod.o.
10797         * m4/lib-check.m4 (cu_LIB_CHECK): Remove SEQ_LIBM, since seq no longer
10798         needs -lm directly.
10799         * m4/xstrtod.m4 (gl_XSTRTOLD): New macro.
10800
10801         2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
10802
10803         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Prefer binutils's
10804         --as-needed option if available.  Problem reported by Albert Chin in
10805         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00114.html>.
10806         However, use -Wl,--as-needed, not bare --as-needed, since HP-UX 11.11
10807         cc merely issues a bunch of annoying warnings for --as-needed
10808         (this problem was reported by Bob Proulx).  Also, try linking with
10809         -lm to detect a bug in binutils 2.16 (this problem was reported
10810         by Ralf Wildenhues).
10811
10812         2006-06-18  Jim Meyering  <jim@meyering.net>
10813
10814         Test for a bug that causes glibc's getcwd to suffer a failed assertion.
10815         * m4/getcwd-abort-bug.m4 (gl_FUNC_GETCWD_ABORT_BUG): New file and
10816         macro.
10817         * m4/getcwd.m4 (gl_FUNC_GETCWD): If we detect support for getcwd_null,
10818         also check for glibc-2.4's abort-inducing bug.
10819
10820         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Fix typo.
10821         Low-probability clean-up should be to use rmdir to get rid of
10822         the just-created directory, not unlink.
10823
10824         * m4/ftruncate.m4 (gl_FUNC_FTRUNCATE): If ftruncate is missing, make
10825         configure fail, and request a bug report to inform us about it.
10826         Add a comment that, barring reports to the contrary, in 2007 we'll
10827         assume ftruncate is universally available.
10828
10829         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10830
10831         * m4/filemode.m4 (gl_FILEMODE): Check for strmode declaration.
10832
10833         2006-03-12  Jim Meyering  <jim@meyering.net>
10834
10835         * m4/chdir-safer.m4 (gl_CHDIR_SAFER): Add same-inode.h to the list.
10836         * m4/cycle-check.m4 (gl_CYCLE_CHECK): Likewise.
10837         * m4/same.m4 (gl_SAME): Likewise.
10838         * m4/root-dev-ino.m4 (gl_ROOT_DEV_INO): Likewise.
10839
10840         2006-03-11  Eric Blake  <ebb9@byu.net>
10841
10842         * m4/double-slash-root.m4: New file, provides gl_DOUBLE_SLASH_ROOT.
10843         * m4/dirname.m4 (gl_DIRNAME): Use gl_DOUBLE_SLASH_ROOT.
10844         * m4/dos.m4 (FILE_SYSTEM_PREFIX_LEN): Move from here to dirname.h.
10845         (FILE_SYSTEM_DRIVE_PREFIX_CAN_BE_RELATIVE): New define.
10846
10847 2006-07-03  Paul Eggert  <eggert@cs.ucla.edu>
10848
10849         * lib/stdint_.h: Include <sys/types.h> after @FULL_PATH_STDINT_H@, for
10850         MacOS X 10.4.6.  Don't mention <sys/int_types.h>.  Problems
10851         reported by Mark D. Baushke, one in
10852         <http://lists.gnu.org/archive/html/bug-gnulib/2006-07/msg00015.html>.
10853
10854         Merge from coreutils.
10855
10856         * lib/.cppi-disable: Add stdint_.h.
10857         * lib/.cvsignore: Add stdint.h.
10858
10859         2006-06-30  Paul Eggert  <eggert@cs.ucla.edu>
10860
10861         * lib/xstrtod.c (XSTRTOD, DOUBLE): New macros, so that we can support
10862         both double and long double versions.
10863         (XSTRTOD): Renamed from xstrtod.  Use DOUBLE internally.
10864         * lib/xstrtold.c: New file.
10865         * lib/xstrtod.h (xstrtold): New decl.
10866
10867         2006-05-22  Paul Eggert  <eggert@cs.ucla.edu>
10868
10869         * lib/filemode.c (setst): Remove.
10870         (strmode): Rewrite to avoid setst.  This makes the code shorter,
10871         (arguably) clearer, and the generated code is a bit smaller on my
10872         Debian GNU/Linux stable x86 host.
10873
10874         2006-04-17  Paul Eggert  <eggert@cs.ucla.edu>
10875
10876         * lib/filemode.c: Include "filemode.h" first, to test the interface.
10877         Assume that filemode.h includes sys/types.h and sys/stat.h.
10878         (HAVE_ST_DM_MODE): New macro, moved here from ls.c.
10879         (ftypelet): Reorder to put common cases first, for efficiency.
10880         Add 'P', 'w'.  Remove 'M', since it's now the caller's responsibility
10881         to do 'M'.
10882         (strmode): Renamed from mode_string, and now stores 12 bytes instead
10883         of 10, for compatibility with FreeBSD.  All callers changed.
10884         (filemodestring): Now stores 12 bytes instead of 10, and sets file
10885         types that can't be deduced solely from st_mode.  First arg is now a
10886         const pointer.
10887         * lib/filemode.h (HAVE_DECL_STRMODE): Include <string.h> for strmode.
10888         (strmode): Renamed from mode_string.
10889         (filemodestring): New decl.
10890         * lib/stat-macros.h: Don't undef S_ISDOOR, since it's never buggy.
10891         (S_ISDOOR): Don't bother with S_IFDOOR, since that code is never
10892         needed.
10893         (S_ISPORT, S_ISWHT): New macros, if not already defined.
10894
10895         2006-04-12  Paul Eggert  <eggert@cs.ucla.edu>
10896
10897         * lib/fsusage.c: Don't include <inttypes.h> or <stdint.h>, since
10898         fsusage.h now does that.  Include fsusage.h first, to test interface.
10899         Prefer statvfs if it works, since it's blessed by POSIX.  Attempt
10900         at most one method (the old code could have generated decls that
10901         didn't conform to C89, not that this was ever exercised).
10902         * lib/fsusage.h: Include <inttypes.h> and <stdint.h> if they exist.
10903
10904         2006-03-19  Jim Meyering  <jim@meyering.net>
10905
10906         Work even in a chroot where d_ino values for entries in "/"
10907         don't match the stat.st_ino values for the same names.
10908         * lib/getcwd.c (__getcwd): When no d_ino value matches the target inode
10909         number, iterate through all entries again, using lstat instead.
10910         Reported by Kenshi Muto in http://bugs.debian.org/355810, and by
10911         Zouhir Hafidi in https://bugzilla.redhat.com/bugzilla/190656.
10912
10913         * lib/getcwd.c (__getcwd): Clarify a comment.
10914         Use memcpy in place of a call to strcpy.
10915
10916         2006-03-12  Jim Meyering  <jim@meyering.net>
10917
10918         * lib/fts-cycle.c (leave_dir): If cycle-check's saved dev-ino pair
10919         matches that of the current directory (which we're about to chdir ".."
10920         out of), then save the dev-ino of the parent, instead.
10921
10922         * lib/same-inode.h (SAME_INODE): New file/macro.
10923         * lib/chdir-safer.c (SAME_INODE): Remove definition.
10924         Include "same-inode.h", instead.
10925         * lib/same.c: Likewise.
10926         * lib/cycle-check.h: Include "same-inode.h".
10927         (CYCLE_CHECK_REFLECT_CHDIR_UP): Define.
10928         * lib/cycle-check.c (SAME_INODE): Remove definition.
10929         * lib/root-dev-ino.h: Include "same-inode.h".
10930
10931         2006-03-11  Eric Blake  <ebb9@byu.net>
10932
10933         * lib/same.c (same_name): s/base_name/last_component/
10934         * lib/backupfile.c (check_extension, numbered_backup): Likewise.
10935         * lib/filenamecat.c (file_name_concat): Likewise.
10936
10937         2006-03-11  Eric Blake  <ebb9@byu.net>,
10938                     Paul Eggert  <eggert@cs.ucla.edu>
10939
10940         * lib/dirname.h (FILE_SYSTEM_PREFIX_LEN): Move here from dos.m4.
10941         [FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't treat 1: as a
10942         drive prefix.
10943         (IS_ABSOLUTE_FILE_NAME): Treat all drive letters as absolute on
10944         platforms like cygwin with FILE_SYSTEM_DRIVE_PREFIX_IS_ABSOLUTE.
10945         (last_component): New method.
10946         * lib/dirname.c (dir_len): Determine when drive letters need a
10947         subsequent slash.  Preserve // when it is special.
10948         (dir_name): Don't append dot when drive letter is absolute.
10949         [TEST_DIRNAME]: Move into a full-blown gnulib test.
10950         * lib/basename.c (base_name): New semantics - malloc the result.
10951         Preserve // when it is special.  Preserve relative files that look
10952         like drive letters.
10953         (base_len): Preserve // when it is special.
10954         (last_component): New method, similar to old base_name semantics.
10955         * lib/stripslash.c (strip_trailing_slashes): Use last_component, not
10956         base_name.  Strip redundant slashes from ///.
10957
10958 2006-07-03  Jim Meyering  <jim@meyering.net>
10959
10960         * lib/cycle-check.h (CYCLE_CHECK_REFLECT_CHDIR_UP): Abort if this
10961         macro is used before the first cycle_check call.
10962
10963 2006-07-03  Eric Blake  <ebb9@byu.net>
10964
10965         * modules/dirname (Depends-on): Add xstrndup.
10966
10967 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10968
10969         * m4/stdint.m4 (gl_STDINT_H): Use more-mnemonic identifiers for
10970         test cases, so that config.log is a bit easier to follow.
10971
10972 2006-07-02  Paul Eggert  <eggert@cs.ucla.edu>
10973
10974         * lib/stdint_.h (intmax_t, uintmax_t): Prefer long to long long if
10975         both are 64 bits, since this seems to be the tradition, and this
10976         prevents gcc -Wformat from warning about usages with PRIuMAX.  If
10977         we ever run into a host that prefers long long to long in this
10978         case, we'll need another configure-time test.  Problem reported by
10979         Jim Meyering.
10980
10981 2006-07-02  Eric Blake  <ebb9@byu.net>
10982
10983         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Simplify by using AC_CHECK_DECLS.
10984
10985 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
10986
10987         * modules/inttypes (Depends-on): No longer depends on stdint.
10988         * modules/stdint (Description): Say more about assumptions.
10989         Say that the fast types might differ.  Say macros are used.
10990         (Files): Remove m4/size_max.m4, m4/wchar_t.m4.  Add m4/longlong.m4.
10991         (Makefile.am): Revise list of substituted symbols to match
10992         new stdint.m4.
10993         * modules/stdint-tests (Files): Add m4/wchar_t.m4, m4/wint_t.m4.
10994         (configure.ac): Add gt_TYPE_WCHAR_T, gt_TYPE_WINT_T.
10995         * tests/test-stdint.c (verify_same_types)
10996         [! (__GNUC__ >= 2 && DO_PEDANTIC)]: Put in a decl, so that
10997         the code conforms to C99/C89.
10998         Test for WCHAR_MIN and WCHAR_MAX only if HAVE_WCHAR_T.
10999         Test for WINT_MIN and WINT_MAX only if HAVE_WINT_T.
11000
11001 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11002
11003         * m4/longlong.m4 (AC_TYPE_LONG_LONG_INT): Backport from Autoconf 2.60,
11004         but fix a bug, by requiring at least 64 bits.
11005         * m4/ulonglong.m4 (AC_TYPE_UNSIGNED_LONG_LONG_INT): Likewise.
11006         * m4/longlong.m4 (gl_AC_TYPE_LONG_LONG): Now just call
11007         AC_TYPE_LONG_LONG_INT.  This macro is obsolete and will go soon.
11008         * m4/ulonglong.m4 (gl_AC_TYPE_UNSIGNED_LONG_LONG) Likewise.
11009
11010         * m4/stdint.m4 (gl_STDINT_H): Rewrite to accommodate stdint_.h
11011         changes.  Make 2.59 a prerequisite.  Check and substitute for
11012         HAVE_LONG_LONG_INT.  Rely on Autoconf to check for stdint.h and
11013         inttypes.h.  Do not use special include files; just use the
11014         defaults.  Check for sys/inttypes.h and sys/bitypes.h in the usual
11015         way now.  Remove no-longer-needed tests for HAVE_LONG_64BIT,
11016         HAVE_LONG_LONG_64BIT, int8_t, int16_t, int32_t, int64_t, uint8_t,
11017         uint16_t, uint32_t uint64_t, int_least8_t, int_least16_t,
11018         int_least32_t, int_least64_t, uint_least8_t, uint_least16_t,
11019         uint_least32_t, uint_least64_t, int_fast8_t, int_fast16_t,
11020         int_fast32_t, int_fast64_t, uint_fast8_t uint_fast16_t,
11021         uint_fast32_t, uint_fast64_t, intptr_t, uintptr_t, intmax_t,
11022         uintmax_t, INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX,
11023         UINT16_MAX, INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN,
11024         INT64_MAX, UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX,
11025         UINT_LEAST8_MAX, INT_LEAST16_MIN, INT_LEAST16_MAX,
11026         UINT_LEAST16_MAX, INT_LEAST32_MIN, INT_LEAST32_MAX,
11027         UINT_LEAST32_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX,
11028         UINT_LEAST64_MAX, INT_FAST8_MIN, INT_FAST8_MAX, UINT_FAST8_MAX,
11029         INT_FAST16_MIN, INT_FAST16_MAX, UINT_FAST16_MAX, INT_FAST32_MIN,
11030         INT_FAST32_MAX, UINT_FAST32_MAX, INT_FAST64_MIN, INT_FAST64_MAX,
11031         UINT_FAST64_MAX, INTPTR_MIN, INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN,
11032         INTMAX_MAX, UINTMAX_MAX, PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN,
11033         SIG_ATOMIC_MAX, SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN,
11034         WINT_MAX.  Check for C99 conformance more strictly, by detecting
11035         bugs in glibc 2.4, Solaris 10, and OpenBSD 3.9.  On the other hand do
11036         not check for things that C99 does not require, e.g., int8_t.  If
11037         a test isn't needed unless <stdint.h> isn't working, and is
11038         unlikely to be needed for any other reason, then don't do it
11039         unless <stdint.h> isn't working.  Do not check for ptrdiff_t or
11040         size_t, since we assume C89 freestanding at least.  Do not check
11041         for sig_atomic_t, wchar_t, or wint_t, since the code now does
11042         the right thing even if the types are not defined.  Instead use:
11043         (gl_STDINT_TYPE_PROPERTIES): New macro.
11044         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H): Remove.  Don't bother
11045         testing whether <sys/types.h> clashes, as Autoconf does this for
11046         us now.  All uses removed.
11047         (gl_STDINT_CHECK_TYPES, gl_STDINT_MISSING_BOUND):
11048         (gl_STDINT_MISSING_BOUNDS, gl_STDINT_MISSING_BOUNDS2):
11049         (gl_CHECK_TYPE_SAME):
11050         Remove; no longer needed.
11051         (gl_STDINT_BITSIZEOF): Don't bother to check whether the type
11052         exists, since we'll return 0 anyway in that case.
11053         (gl_INTEGER_TYPE_SUFFIX, gl_STDINT_INCLUDES): New macros.
11054
11055 2006-07-01  Paul Eggert  <eggert@cs.ucla.edu>
11056
11057         * lib/stdint_.h (_GL_STDINT_H): Renamed from _STDINT_H, to avoid
11058         possible collision with system files.
11059         (<stdio.h>, <time.h>, <wchar.h>) [defined __cplusplus && ! defined
11060         __STDC_CONSTANT_MACROS)]: Do not include, since we don't need
11061         WCHAR_MIN and WCHAR_MAX in this case.
11062         (<stddef.h>): Do not include; no longer needed.
11063         (<sys/types.h>): Include if @HAVE_SYS_TYPES_H@, not if
11064         (defined(__OpenBSD__) || defined(__bsdi__) || defined(__sgi)).
11065         (<sys/inttypes.h>): Include if @HAVE_SYS_INTTYPES_H@ &&
11066         !@HAVE_INTTYPES_H@, not if (defined(__FreeBSD__)
11067         && (__FreeBSD__ >= 3) && (__FreeBSD__ <= 4)).
11068         (__STDINT_H__) [@HAVE_STDINT_H@ && defined __sgi && ! defined
11069         __c99]: Define, to work around IRIX <stdint.h> incompatibility.
11070         (@FULL_PATH_STDINT_H@) [!(defined(__sgi) && @HAVE_INTTYPES_H@ &&
11071         !defined(__c99))]: Include in this case too, since it's harmless
11072         now.
11073         (<inttypes.h>) [@HAVE_INTTYPES_H@]: Include, since it's no longer
11074         dangerous to do so.
11075         (@FULL_PATH_INTTYPES_H@) [(defined(__hpux) || defined(_AIX)) &&
11076         @HAVE_INTTYPES_H@]: Do not include, since we now include <inttypes.h>.
11077         (_STDINT_MIN, _STDINT_MAX): New macros.
11078         (int8_t, uint8_t, int16_t, uint16_t, int32_t, uint32_t, int64_t):
11079         (uint64_t, int_least8_t, uint_least8_t, int_least16_t):
11080         (uint_least16_t, int_least32_t, uint_least32_t, int_least64_t):
11081         (uint_least64_t, int_fast8_t, uint_fast8_t, int_fast16_t):
11082         (uint_fast16_t, int_fast32_t, uint_fast32_t, int_fast64_t):
11083         (uint_fast64_t, intptr_t, uintptr_t, intmax_t, uintmax_t): Now
11084         macros, not typedefs; this simplifies things quite a bit.
11085         Use long int for all types narrower than int64_t.
11086         (intmax_t, uintmax_t, INTMAX_C, UINTMAX_C):
11087         Define in terms of long long int or int64_t or long int,
11088         not int64_t or int32_t.  This saves some compile-time testing.
11089         (INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX):
11090         (INT32_MIN, INT32_MAX, UINT32_MAX, INT64_MIN, INT64_MAX):
11091         (UINT64_MAX, INT_LEAST8_MIN, INT_LEAST8_MAX, UINT_LEAST8_MAX):
11092         (INT_LEAST16_MIN, INT_LEAST16_MAX, UINT_LEAST16_MAX):
11093         (INT_LEAST32_MIN, INT_LEAST32_MAX, UINT_LEAST32_MAX):
11094         (INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX, INT_FAST8_MIN):
11095         (INT_FAST8_MAX, UINT_FAST8_MAX, INT_FAST16_MIN, INT_FAST16_MAX):
11096         (UINT_FAST16_MAX, INT_FAST32_MIN, INT_FAST32_MAX, UINT_FAST32_MAX):
11097         (INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTPTR_MIN):
11098         (INTPTR_MAX, UINTPTR_MAX, INTMAX_MIN, INTMAX_MAX, UINTMAX_MAX):
11099         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
11100         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
11101         undef any previous version and define our own version, for
11102         simplicity and consistency with the new macros for types.
11103         (PTRDIFF_MIN, PTRDIFF_MAX, SIG_ATOMIC_MIN, SIG_ATOMIC_MAX):
11104         (SIZE_MAX, WCHAR_MIN, WCHAR_MAX, WINT_MIN, WINT_MAX):
11105         Simplify definitions by using _STDINT_MIN and _STDINT_MAX
11106         where appropriate.  Rely on new symbols @PTRDIFF_T_SUFFIX@,
11107         @SIG_ATOMIC_T_SUFFIX@, @SIZE_T_SUFFIX@, @WCHAR_T_SUFFIX@,
11108         @WINT_T_SUFFIX@ to keep things simple here.
11109         (UINT8_C, UINT16_C, UINT32_C, INT64_C, UINT64_C):
11110         Simplify by assuming typical 8/16/32/64 host, since we're
11111         already doing that elsewhere anyway.
11112         Use (LONG_MAX >> 31 >> 31 == 1) rather than @HAVE_LONG_64BIT@,
11113         and assume long long int is 64 bits if available.  This
11114         speeds up 'configure'.
11115
11116 2006-07-01  Eric Blake  <ebb9@byu.net>
11117
11118         * m4/stdarg.m4 (gl_STDARG_H): Use proper AH_VERBATIM.
11119         Reported by Andreas Buening.
11120
11121 2006-07-01  Eric Blake  <ebb9@byu.net>
11122
11123         * m4/stdarg.m4 (gl_STDARG_H): Properly parenthesize gl_va_copy.
11124
11125 2006-06-30  Jim Hyslop  <jhyslop@dreampossible.ca>  (tiny change)
11126
11127         * lib/getaddrinfo.c: fixed typo
11128
11129 2006-06-29  Jim Meyering  <jim@meyering.net>
11130
11131         * modules/strftime (Maintainer): Add my name, since with the
11132         FPRINTFTIME changes strftime.c has forked from glibc.
11133
11134 2006-06-29  Eric Blake  <ebb9@byu.net>
11135
11136         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Use AC_C_INLINE.
11137
11138 2006-06-29  Eric Blake  <ebb9@byu.net>
11139
11140         * m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): New file.
11141
11142 2006-06-29  Eric Blake  <ebb9@byu.net>
11143
11144         * lib/stat_.h: New file.
11145
11146 2006-06-29  Eric Blake  <ebb9@byu.net>
11147
11148         * lib/stat_.h (rpl_mkdir): Declare inline, to avoid warnings about
11149         unused static function.
11150
11151 2006-06-29  Eric Blake  <ebb9@byu.net>
11152
11153         * doc/functions.texi (Function Portability): Document missing lstat
11154         on mingw.
11155
11156 2006-06-29  Eric Blake  <ebb9@byu.net>
11157
11158         * MODULES.html.sh: Add sys_stat.
11159         * modules/sys_stat: New module.
11160         * modules/mkstemp (Depends-on): Add sys_stat.
11161
11162 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11163
11164         * m4/strftime.m4: Don't call AC_FUNC_STRFTIME.
11165
11166 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11167
11168         * m4/c-bs-a.m4: Removed.
11169
11170 2006-06-29  Derek R. Price  <derek@ximbiot.com>
11171
11172         * lib/strftime.c: Assume strftime() exists.
11173
11174 2006-06-29  Derek Price  <derek@ximbiot.com>
11175
11176         * modules/c-bs-a: Removed - \a is C89.
11177         * MODULES.html.sh: Remove c-bs-a.
11178
11179 2006-06-29  Bruno Haible  <bruno@clisp.org>
11180
11181         * modules/wcwidth (License): Change to LGPL.
11182
11183 2006-06-28  Simon Josefsson  <jas@extundo.com>
11184
11185         * tests/test-getaddrinfo.c: Test getnameinfo too.  Call WSAStartup
11186         on _WIN32.
11187
11188         * modules/getaddrinfo (Depends-on): Add inet_ntop, needed by
11189         getnameinfo.
11190
11191 2006-06-28  Simon Josefsson  <jas@extundo.com>
11192
11193         * m4/getaddrinfo.m4: Look for getnameinfo prototypes too.
11194
11195 2006-06-28  Simon Josefsson  <jas@extundo.com>
11196
11197         * lib/getaddrinfo.c: Try to load ws2_32.dll on Windows, to find the
11198         functions there.  It will succeed on Windows XP, but on Windows
11199         2000 and (presumably) earlier, it will fail, and use the internal
11200         re-implementation.
11201         (use_win32_p): New function.
11202         (getaddrinfo): Use strtoul on servname, to support numeric ports.
11203         Support AI_NUMERICSERV to disable getservbyname.
11204         (getnameinfo): New function, only supports
11205         NI_NUMERICHOST|NI_NUMERICSERV for now.
11206
11207         * lib/getaddrinfo.h: Test and check for AI_* flags separately, MinGW
11208         only have some of them.  Add AI_NUMERICSERV.  Add prototype for
11209         getnameinfo.
11210
11211 2006-06-28  Eric Blake  <ebb9@byu.net>
11212
11213         * modules/wcwidth: New file.
11214         * modules/mbchar (Depends-on): Add wcwidth.
11215         * modules/mbswidth (Depends-on): Add wcwidth.
11216         * MODULES.html.sh: Add wcwidth.
11217
11218 2006-06-28  Eric Blake  <ebb9@byu.net>
11219
11220         * m4/mbswidth.m4 (gl_MBSDWIDTH): Move wcwidth from here...
11221         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): ...to this new file.
11222
11223 2006-06-28  Eric Blake  <ebb9@byu.net>
11224
11225         * lib/xvasprintf.h: Fix comments.
11226
11227 2006-06-28  Eric Blake  <ebb9@byu.net>
11228
11229         * lib/mbchar.h (wcwidth): Include wcwidth.h.
11230         * lib/mbswidth.c (wcwidth): Move from here...
11231         * lib/wcwidth.h: ...to this new file.
11232
11233 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11234
11235         * m4/savedir.m4: Remove AC_FUNC_CLOSEDIR_VOID requirement.
11236
11237         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Don't require AC_C_CONST, since
11238         it's obsolete.
11239         * m4/strftime.m4 (gl_FUNC_GNU_STRFTIME): Likewise.
11240
11241 2006-06-28  Derek R. Price  <derek@ximbiot.com>
11242
11243         * lib/savedir.c (CLOSEDIR): Remove.  All uses changed to closedir.
11244         Autoconf 2.60 says this stuff was obsolete.
11245
11246 2006-06-28  Bruno Haible  <bruno@clisp.org>
11247
11248         * modules/wcwidth (Files): Add m4/wchar_t.m4.
11249
11250 2006-06-28  Bruno Haible  <bruno@clisp.org>
11251
11252         * m4/wcwidth.m4 (gl_FUNC_WCWIDTH): Also require AC_C_INLINE and
11253         gt_TYPE_WCHAR_T.
11254
11255 2006-06-28  Bruno Haible  <bruno@clisp.org>
11256
11257         * lib/wcwidth.h: Declare nothing if !HAVE_WCHAR_T. Provide a fallback
11258         declaration for wcwidth.
11259         * lib/mbswidth.c: Restore the includes of <wchar.h> and <wctypes.h>.
11260
11261 2006-06-28  Bruno Haible  <bruno@clisp.org>
11262
11263         * lib/mkdtemp.c [MINGW]: Include <io.h>.
11264         (mkdir): Define using _mkdir.
11265
11266 2006-06-28  Bruno Haible  <bruno@clisp.org>
11267
11268         * lib/getaddrinfo.h: Fix POSIX URL.
11269         * lib/getaddrinfo.c (WIN32_NATIVE): New macro. Use it instead of
11270         _WIN32.
11271         (use_win32_p): Make static.
11272         (getaddrinfo): Reject service name if it is empty or does not consist
11273         solely of decimal digits, or if its value is > 65535.
11274         (getnameinfo): Remove useless casts.
11275
11276 2006-06-27  Simon Josefsson  <jas@extundo.com>
11277
11278         * modules/sys_select: New file, suggested by Bruno Haible, Paul
11279         Eggert and Martin Lambers.
11280
11281 2006-06-27  Simon Josefsson  <jas@extundo.com>
11282
11283         * m4/sys_select_h.m4: New file, suggested by Bruno Haible, Paul
11284         Eggert and Martin Lambers.
11285
11286 2006-06-27  Bruno Haible  <bruno@clisp.org>
11287
11288         * m4/stdint.m4 (gl_STDINT_BITSIZEOF): For nonexistent types, set the
11289         result to 0, not to empty.
11290         Reported by Martin Neitzel <neitzel@sco.gaertner.de>.
11291
11292 2006-06-27  Bruno Haible  <bruno@clisp.org>
11293
11294         * lib/stdint_.h (intmax_t, uintmax_t): Undefine before typedef.
11295
11296 2006-06-26  Simon Josefsson  <jas@extundo.com>
11297
11298         * m4/inet_ntop.m4: Don't check for sys/types.h, we assume it is
11299         present.
11300
11301 2006-06-26  Paul Eggert  <eggert@cs.ucla.edu>
11302
11303         * lib/base64.c (B64): Use _ as the formal parameter, not x, to avoid
11304         bug in IBM C V6 for AIX.  Problem reported by Larry Jones in
11305         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00181.html>.
11306
11307 2006-06-26  Mark D. Baushke  <mdb@gnu.org>
11308
11309         * m4/stdint.m4 (gl_STDINT_H): Treat BSD/OS like OpenBSD.
11310
11311 2006-06-26  Bruno Haible  <bruno@clisp.org>
11312
11313         * modules/stdint (Makefile.am): Also substitute HAVE_WCHAR_H.
11314
11315 2006-06-26  Bruno Haible  <bruno@clisp.org>
11316
11317         * m4/stdint.m4 (gl_STDINT_H): Test also for <wchar.h>.
11318
11319 2006-06-26  Bruno Haible  <bruno@clisp.org>
11320
11321         * m4/stdint.m4 (gl_STDINT_H): Don't include <stdint.h> when using the
11322         SGI C compiler in pre-C99 mode.
11323         Suggested by Mark D. Baushke and Larry Jones.
11324
11325 2006-06-26  Bruno Haible  <bruno@clisp.org>
11326
11327         * lib/stdint_.h: Include <wchar.h> if necessary for WCHAR_MIN or
11328         WCHAR_MAX.
11329         Reported by Mark D. Baushke and Larry Jones.
11330
11331 2006-06-26  Bruno Haible  <bruno@clisp.org>
11332
11333         * lib/stdint_.h: Don't include <stdint.h> when using the SGI C compiler
11334         in pre-C99 mode.
11335         Suggested by Mark D. Baushke and Larry Jones.
11336
11337 2006-06-23  Simon Josefsson  <jas@extundo.com>
11338             Bruno Haible  <bruno@clisp.org>
11339
11340         * gnulib-tool (func_emit_lib_Makefile_am): Define MOSTLYCLEANDIRS.
11341         Emit mostlyclean-local rule.
11342         (func_emit_tests_Makefile_am): Likewise.
11343         * modules/sys_socket (Makefile.am): Use MOSTLYCLEANDIRS.
11344
11345 2006-06-23  Mark D. Baushke  <mdb@gnu.org>
11346
11347         * lib/stdint_.h: Treat BSD/OS like OpenBSD.
11348
11349 2006-06-23  Bruno Haible  <bruno@clisp.org>
11350
11351         * tests/test-stdint.c: Update to match ISO C 99 Technical
11352         Corrigendum 1.
11353
11354 2006-06-23  Bruno Haible  <bruno@clisp.org>
11355
11356         * m4/stdint.m4 (gl_STDINT_H): Treat IRIX like OpenBSD.
11357
11358 2006-06-23  Bruno Haible  <bruno@clisp.org>
11359
11360         * lib/stdint_.h: Treat IRIX like OpenBSD.
11361
11362 2006-06-23  Bruno Haible  <bruno@clisp.org>
11363
11364         * lib/stdint_.h (UINT8_C, UINT16_C, UINT32_C): Define according to
11365         ISO C 99 Technical Corrigendum 1.
11366
11367 2006-06-22  Simon Josefsson  <jas@extundo.com>
11368
11369         * m4/sockpfaf.m4: Include winsock2.h too, to make it work under
11370         MinGW.
11371
11372 2006-06-22  Paul Eggert  <eggert@cs.ucla.edu>
11373
11374         * lib/glob.c (collated_compare): Remove 'const' uses that weren't
11375         needed.  Some compiler complained about some of them.  Problem reported
11376         by Larry Jones in
11377         <http://lists.gnu.org/archive/html/bug-gnulib/2006-06/msg00172.html>.
11378
11379 2006-06-21  Simon Josefsson  <jas@extundo.com>
11380
11381         * tests/test-getaddrinfo.c: New file.
11382
11383         * modules/getaddrinfo-tests: New file.
11384
11385         * MODULES.html.sh: Add inet_pton.
11386
11387         * modules/inet_pton: New file.
11388
11389 2006-06-21  Simon Josefsson  <jas@extundo.com>
11390
11391         * m4/getaddrinfo.m4: Don't define WINVER.  Look for gethostbyname in
11392         -lws2_32 too.  Fixes getaddrinfo on Windows 2000, with the price
11393         of using the (limited) gnulib implementation on Windows XP.
11394
11395         * m4/inet_pton.m4: New file.
11396
11397 2006-06-21  Simon Josefsson  <jas@extundo.com>
11398
11399         * lib/getaddrinfo.c (getaddrinfo): Set ai_family in the return
11400         variable.
11401
11402         * lib/socket_.h: Don't define WINVER.
11403
11404         * lib/inet_pton.h, inet_pton.c: New file, taken from glibc but
11405         slightly modified to work in gnulib.
11406
11407 2006-06-21  Simon Josefsson  <jas@extundo.com>
11408
11409         * doc/gnulib.texi (Windows sockets): Add.
11410
11411 2006-06-21  Paul Eggert  <eggert@cs.ucla.edu>
11412
11413         * lib/read-file.c (fread_file): Start with buffer allocation of
11414         0 bytes rather than 1 byte; this simplifies the code.
11415         Don't invoke feof; it's not needed.  Refactor to avoid duplicate
11416         code to free buffer and save/restore errno.
11417         (internal_read_file): Remove unused local.
11418
11419 2006-06-20  Paul Eggert  <eggert@cs.ucla.edu>
11420
11421         * lib/openat.c (openat): Use ?:, not if, to work around GCC bug 4210
11422         <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=4210>.
11423         Problem reported by Denis Excoffier in
11424         <http://lists.gnu.org/archive/html/bug-tar/2006-06/msg00023.html>.
11425
11426 2006-06-19  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
11427
11428         * modules/sys_socket, modules/socklen: Include sys/types since
11429         FreeBSD 4.x's sys/socket.h needs it.
11430
11431 2006-06-19  Simon Josefsson  <jas@extundo.com>
11432
11433         * lib/inet_ntop.c: Always build inet_ntop4, since inet_ntop6 calls it.
11434
11435 2006-06-19  Paul Eggert  <eggert@cs.ucla.edu>
11436
11437         * lib/alloca_.h (alloca) [defined alloca]: Don't define or declare.
11438
11439 2006-06-19  Bruno Haible  <bruno@clisp.org>
11440
11441         * m4/stdint.m4 (gl_STDINT_H): Enclose the values of FULL_PATH_STDINT_H
11442         and FULL_PATH_INTTYPES_H in angle brackets.
11443         Reported by Mark D. Baushke <mdb@gnu.org>.
11444
11445 2006-06-17  Eric Blake  <ebb9@byu.net>
11446
11447         * m4/rmdir-errno.m4 (gl_FUNC_FMDIR_NOTEMPTY): Assume errno.h declares
11448         errno.
11449
11450 2006-06-17  Bruno Haible  <bruno@clisp.org>
11451
11452         * m4/stdint.m4 (gl_STDINT_H) [FreeBSD >= 5]: Don't include
11453         <sys/inttypes.h>.
11454
11455 2006-06-17  Bruno Haible  <bruno@clisp.org>
11456
11457         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove test
11458         whether errno is declared. Assume <errno.h> declares errno.
11459
11460 2006-06-17  Bruno Haible  <bruno@clisp.org>
11461
11462         * lib/stdint_.h [FreeBSD >= 5]: Don't include <sys/inttypes.h>.
11463
11464 2006-06-17  Bruno Haible  <bruno@clisp.org>
11465
11466         * lib/stdint_.h (_UINT8_T, _UINT32_T, _UINT64_T): New macros. Fixes a
11467         problem on Solaris 2.5.1.
11468
11469 2006-06-16  Eric Blake  <ebb9@byu.net>
11470
11471         * lib/unsetenv.c [!defined errno]: Assume errno.h declares errno.
11472         * lib/unicodeio.c [!defined errno]: Likewise.
11473         * lib/strtol.c [!defined errno]: Likewise.
11474         * lib/strtod.c [!defined errno]: Likewise.
11475
11476 2006-06-15  Eric Blake  <ebb9@byu.net>
11477
11478         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Work in spite of -Werror.
11479
11480 2006-06-15  Eric Blake  <ebb9@byu.net>
11481
11482         * config/srclist.txt (ssize_t.m4): Lose sync.
11483
11484 2006-06-15  Bruno Haible  <bruno@clisp.org>
11485
11486         * modules/stdint (Files): Include m4/full-header-path.m4,
11487         m4/size_max.m4, m4/wchar_t.m4.
11488         (Makefile.am): Many more substitutions.
11489         * modules/stdint-tests: New file.
11490         * tests/test-stdint.c: New file.
11491
11492 2006-06-15  Bruno Haible  <bruno@clisp.org>
11493
11494         * m4/stdint.m4 (gl_STDINT_H): Rewritten to produce a complete stdint.h.
11495         (gl_HEADER_STDINT_H, gl_HEADER_INTTYPES_H, gl_STDINT_CHECK_TYPES,
11496         gl_STDINT_MISSING_BOUND, gl_STDINT_MISSING_BOUNDS,
11497         gl_STDINT_MISSING_BOUNDS2, gl_STDINT_BITSIZEOF, gl_CHECK_TYPES_SIGNED,
11498         gl_CHECK_TYPE_SAME): New macros.
11499
11500 2006-06-15  Bruno Haible  <bruno@clisp.org>
11501
11502         * m4/size_max.m4 (gl_SIZE_MAX): Make it work also when cross-compiling.
11503
11504 2006-06-15  Bruno Haible  <bruno@clisp.org>
11505
11506         * lib/stdint_.h: Rewritten to be fully auto-configured.
11507         Fixes bug on HP-UX/IA64.
11508
11509 2006-06-11  Paul Eggert  <eggert@cs.ucla.edu>
11510
11511         * lib/getdate.y (__attribute__): Don't define if already defined.
11512         Problem reported by Larry Jones.
11513         * lib/utimens.c (__attribute__): Likewise.
11514
11515 2006-06-04  Paul Eggert  <eggert@cs.ucla.edu>
11516
11517         * lib/regexec.c (group_nodes_into_DFAstates): Fix a buffer overrun
11518         reported by Andreas Schwab.
11519
11520 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11521             Bruno Haible  <bruno@clisp.org>
11522
11523         * m4/strndup.m4 (gl_FUNC_STRNDUP): Replace the AC_REPLACE_FUNCS with a
11524         check for the declaration of strnlen and a run test that exposes the
11525         AIX 5.1 strnlen bug.  In the failure case, #define strndup to
11526         rpl_strndup.
11527
11528 2006-05-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11529             Bruno Haible  <bruno@clisp.org>
11530
11531         * lib/strndup.c (strndup) [!_LIBC]: Don't undefine macro definition.
11532
11533 2006-05-28  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
11534
11535         * m4/c-strtod.m4 (gl_C99_STRTOLD): Use a link test rather than a
11536         compile test, for Tru64 4.0D.
11537
11538 2006-05-28  Karl Berry  <karl@gnu.org>
11539
11540         * config/srclist.txt (printf-args.c): lose sync.
11541
11542 2006-05-26  Martin Lambers  <marlam@marlam.de>
11543
11544         * lib/getpass.c: Updates the test for the native W32 API, and adds
11545         missing includes, thus fixing compilation warnings.
11546
11547 2006-05-25  Sergey Poznyakoff  <gray@gnu.org.ua>
11548
11549         * lib/exclude.c (exclude_fnmatch): New function.
11550         (excluded_file_name): Call exclude_fnmatch.
11551         * lib/exclude.h (excluded_file_name): New prototype
11552
11553 2006-05-25  Paul Eggert  <eggert@cs.ucla.edu>
11554
11555         * lib/tempname.c (small_open, large_open): New macros.
11556         (__open, __open64) [!_LIBC]: Remove.
11557         (__gen_tempname): Use small_open and large_open instead of __open
11558         and __open64.  This fixes a portability bug on HP-UX 11.11i
11559         reported by Simon Wing-Tang in
11560         <http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00114.html>.
11561
11562 2006-05-24  Bruno Haible  <bruno@clisp.org>
11563
11564         * lib/printf-args.c (printf_fetchargs): Turn NULL pointers for
11565         TYPE_STRING and TYPE_WIDE_STRING into a non-NULL replacement.
11566         Reported by Thorsten Maerz <torte@netztorte.de> via
11567         Aaron Stone <aaron@serendipity.cx>.
11568
11569 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
11570
11571         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Rename cache variables to use
11572         gl_ rather than jm_.  Link, don't run, so that cross-compiles are
11573         allowed.  Check that resulting type is arithmetic.  Move AC_REQUIRE
11574         and AC_CHECK_HEADERS_ONCE outside of AC_CACHE_CHECK, since they're
11575         not really conditional on the cache.
11576         (gl_PREREQ_NANOSLEEP): Check for sys/select.h.
11577
11578 2006-05-19  Paul Eggert  <eggert@cs.ucla.edu>
11579
11580         * lib/nanosleep.c [HAVE_SYS_SELECT_H]: Include <sys/select.h>.
11581         Use the usual Autoconf way to include <time.h> and/or sys/time.h.
11582         (my_usleep): Don't mishandle maximum value.
11583
11584 2006-05-19  Jim Meyering  <jim@meyering.net>
11585
11586         * lib/getugroups.c: Correct an outdated comment.  From Bruno Haible.
11587
11588 2006-05-17  Bruno Haible  <bruno@clisp.org>
11589
11590         Cygwin portability.
11591         * lib/classpath.c (PATH_SEPARATOR) [CYGWIN]: Define as ':'.
11592
11593 2006-05-17  Bruno Haible  <bruno@clisp.org>
11594
11595         * lib/stdint_.h: Fix recognition of Cygwin.
11596
11597 2006-05-15  Bruno Haible  <bruno@clisp.org>
11598
11599         * build-aux/config.rpath: Improve support for Sun C 5.9 on Linux, based
11600         on libtool patch by Ralf Wildenhues.
11601
11602 2006-05-14  Paul Eggert  <eggert@cs.ucla.edu>
11603
11604         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Fix overly-picky
11605         test for C99 conformance; (bool) 0.5 is an integer constant
11606         expression, but (bool) -0.5 is not.  Problem reported by Fedor
11607         Sergeev in <http://forum.sun.com/jive/thread.jspa?threadID=96202>.
11608
11609 2006-05-11  Simon Josefsson  <jas@extundo.com>
11610
11611         * m4/xvasprintf.m4: Fix obvious typo.
11612
11613 2006-05-11  Jim Meyering  <jim@meyering.net>
11614
11615         * lib/sha1.c (sha1_buffer): Correct comment: s/MD5/SHA1/.  From
11616         James Lemley.
11617
11618 2006-05-10  Simon Josefsson  <jas@extundo.com>
11619
11620         * lib/md4.c: Typo fix, update copyright years.
11621         (K1, K2): Don't use L because it turn computations into 64-bit on
11622         64-bit platforms.
11623
11624 2006-05-10  Paul Eggert  <eggert@cs.ucla.edu>
11625
11626         * lib/crc.c (crc32_update): Remove unnecessary L suffix.
11627         * lib/md4.c (rol): Cast right-shift arg to uint32_t to prevent
11628         unwanted sign propagation, e.g., on hosts with 64-bit int.
11629         There still are some problems with reeelly weird theoretical hosts
11630         (e.g., 33-bit int) but it's not worth worrying about now.
11631         * lib/sha1.c (rol): Likewise.
11632         (K1, K2, K3, K4): Remove unnecessary L suffix.
11633
11634 2006-05-10  Bruno Haible  <bruno@clisp.org>
11635
11636         * lib/des.c: Cast to avoid warnings.
11637
11638 2006-05-09  Bruno Haible  <bruno@clisp.org>
11639
11640         * modules/xvasprintf (Files): Add m4/xvasprintf.m4.
11641         (Depends-on): Depend also on xsize, stdarg.
11642         (configure.ac): Add gl_XVASPRINTF.
11643
11644 2006-05-09  Bruno Haible  <bruno@clisp.org>
11645
11646         * m4/xvasprintf.m4: New file.
11647
11648 2006-05-09  Bruno Haible  <bruno@clisp.org>
11649
11650         * lib/xvasprintf.c: Include limits.h, string.h, xsize.h.
11651         (EOVERFLOW): Define fallback value.
11652         (xstrcat): New function.
11653         (xvasprintf): Recognize the special case of a string concatenation.
11654
11655 2006-05-08  Eric Blake  <ebb9@byu.net>
11656
11657         * gnulib-tool (func_version): Base copyright year on CVS date.
11658         (func_emit_copyright_notice): New function.
11659         (func_emit_lib_Makefile_am): Use it.
11660         (func_emit_tests_Makefile_am): Likewise.
11661         (func_import): Likewise.
11662
11663 2006-05-08  Bruno Haible  <bruno@clisp.org>
11664
11665         * modules/stdarg: New file.
11666         * MODULES.html.sh (func_all_modules): Add section for <stdarg.h>.
11667
11668 2006-05-08  Bruno Haible  <bruno@clisp.org>
11669
11670         * m4/stdarg.m4: New file, from GNU gettext.
11671
11672 2006-05-08  Bruno Haible  <bruno@clisp.org>
11673
11674         * config/srclist.txt (build-aux/config.rpath): different from latest
11675         release.
11676
11677 2006-05-08  Bruno Haible  <bruno@clisp.org>
11678
11679         * build-aux/config.rpath: Add support for Sun C 5.9 on Linux.
11680
11681 2006-05-05  Jim Meyering  <jim@meyering.net>
11682
11683         * m4/warning.m4: New file, derived from bison's file by the same name.
11684
11685 2006-05-03  Bruno Haible  <bruno@clisp.org>
11686
11687         * lib/stdint_.h: Shorter URL.
11688         * lib/inttypes.h: Likewise.
11689
11690 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11691
11692         * modules/inttypes (Maintainer): Change from Derek Price to 'all'.
11693
11694 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11695
11696         * lib/verify.h: Document the internals better.  Most of this change
11697         was written by Bruno Haible.
11698
11699 2006-05-02  Paul Eggert  <eggert@cs.ucla.edu>
11700
11701         * doc/verify.texi: New file, partly based on a proposal by
11702         Bruno Haible.
11703
11704 2006-05-02  Bruno Haible  <bruno@clisp.org>
11705
11706         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Move the include_next
11707         test from here...
11708         * m4/_inttypes_h.m4 (gl_INTTYPES_H): ... to here.
11709
11710 2006-04-29  Bruno Haible  <bruno@clisp.org>
11711
11712         * lib/gcd.c: Use WORD_T and GCD instead of unsigned long and gcd.
11713         Suggested by Oskar Liljeblad <oskar@osk.mine.nu>.
11714
11715 2006-04-29  Bruno Haible  <bruno@clisp.org>
11716
11717         * gnulib-tool: Make --update option actually work.
11718
11719 2006-04-29  Bruno Haible  <bruno@clisp.org>
11720
11721         * doc/gcd.texi: New file.
11722         * doc/gnulib.texi: Include it.
11723
11724 2006-04-25  Paul Eggert  <eggert@cs.ucla.edu>
11725
11726         * lib/getdate.y (get_date): When adding relative date, start with the
11727         initial time, not with the result of the first mktime call.
11728
11729 2006-04-25  Bruno Haible  <bruno@clisp.org>
11730
11731         * gnulib-tool (func_import): Output the include directives in three
11732         blocks, sorted separately.
11733         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11734
11735 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11736
11737         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use prototype
11738         to define main with arguments, for C++.  Reported by Eric Blake.
11739         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC):
11740         Prefer 'int main ()' to 'int main (void)', for C++.
11741         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Likewise.
11742         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Specify a return type
11743         for 'main', for C99 and C++.
11744
11745 2006-04-24  Paul Eggert  <eggert@cs.ucla.edu>
11746
11747         * m4/fsusage.m4 (gl_FILE_SYSTEM_USAGE): Use return, not exit.
11748         Don't assume that exit status -1 is valid.
11749         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
11750         * m4/putenv.m4 (gl_FUNC_PUTENV): Likewise.
11751         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Likewise.
11752         * m4/readdir.m4 (GL_FUNC_READDIR): Include <stdlib.h>.
11753         * m4/rename.m4 (vb_FUNC_RENAME): Likewise.
11754         * m4/unlink-busy.m4 (gl_FUNC_UNLINK_BUSY_TEXT): Use AC_RUN_IFELSE,
11755         not AC_TRY_RUN.  Use return, not exit.  Don't assume that
11756         functions can be used without declaring them, or that you can
11757         exit with status -1.
11758         * m4/utimes-null.m4 (gl_FUNC_UTIMES_NULL): Likewise.
11759
11760 2006-04-24  Karl Berry  <karl@gnu.org>
11761
11762         * config/srclist.txt (longdouble.m4): sync lost.
11763
11764 2006-04-24  Eric Blake  <ebb9@byu.net>
11765
11766         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Avoid unused variable warning.
11767
11768 2006-04-24  Bruno Haible  <bruno@clisp.org>
11769
11770         * m4/poll.m4 (gl_FUNC_POLL): When cross-compiling, reject also the
11771         poll() implementation in AIX.
11772         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
11773
11774 2006-04-24  Bruno Haible  <bruno@clisp.org>
11775
11776         * m4/poll.m4 (gl_FUNC_POLL): Rearrange code, so that POLL_H gets
11777         assigned exactly once.
11778
11779 2006-04-23  Claudio Fontana  <claudio@gnu.org>
11780             Bruno Haible  <bruno@clisp.org>
11781
11782         * modules/gettext (Makefile.am): Add a -I flag for <libintl.h>.
11783         * gnulib-tool (func_emit_lib_Makefile_am): Emit empty default value
11784         for AM_CPPFLAGS.
11785
11786 2006-04-23  Bruno Haible  <bruno@clisp.org>
11787
11788         * modules/copy-file: Depend on unistd.
11789         * modules/execute: Likewise.
11790         * modules/fatal-signal: Likewise.
11791         * modules/findprog: Likewise.
11792         * modules/mkdtemp : Likewise.
11793         * modules/pipe: Likewise.
11794         * modules/wait-process: Likewise.
11795
11796 2006-04-23  Bruno Haible  <bruno@clisp.org>
11797
11798         * lib/fwriteerror.c (fwriteerror): Call fclose also when an error
11799         condition was already detected.
11800         Reported by Ben Pfaff <blp@cs.stanford.edu>.
11801
11802 2006-04-23  Bruno Haible  <bruno@clisp.org>
11803
11804         * lib/copy-file.c: Include <unistd.h> unconditionally.
11805         * lib/execute.c: Likewise.
11806         * lib/fatal-signal.c: Likewise.
11807         * lib/findprog.c: Likewise.
11808         * lib/mkdtemp.c: Likewise.
11809         * lib/pipe.h: Likewise.
11810         * lib/pipe.c: Likewise.
11811         * lib/wait-process.h: Likewise.
11812
11813 2006-04-23  Bruno Haible  <bruno@clisp.org>
11814
11815         * gnulib-tool (func_usage): Fix --import description. Document
11816         --update.
11817         (func_import): Create temporary file in a temporary directory, if
11818         --dry-run is specified. Silence errors from 'grep' when there are no
11819         m4 files in $m4dir.
11820         (func_create_testdir): Silence errors from 'grep' when there are no
11821         m4 files in $m4dir.
11822         Reported by Karl Berry <karl@freefriends.org>.
11823
11824 2006-04-20  Bruno Haible  <bruno@clisp.org>
11825
11826         * m4/argp.m4 (gl_ARGP): Don't call AC_CHECK_DECLS_ONCE with more than
11827         one argument, so that the code will be portable to Autoconf 2.60.
11828         * m4/getlogin_r.m4 (gl_PREREQ_GETLOGIN_R): Likewise.
11829         * m4/getpass.m4 (gl_PREREQ_GETPASS): Likewise.
11830         * m4/unlocked-io.m4 (gl_FUNC_GLIBC_UNLOCKED_IO): Likewise.
11831
11832 2006-04-19  Derek Price  <derek@ximbiot.com>
11833             Eric Blake  <ebb9@byu.net>
11834
11835         * m4/full-header-path.m4 (gl_FULL_HEADER_PATH): Use </full/path.h>
11836         rather than "/full/path.h".  Update comment to match.  Shorten &
11837         generalize m4_translit call via AS_TR_CPP.
11838
11839 2006-04-19  Derek Price  <derek@ximbiot.com>
11840             Eric Blake  <ebb9@byu.net>
11841
11842         * lib/inttypes.h: Correct grammar in comment.
11843
11844 2006-04-18  Derek Price  <derek@ximbiot.com>
11845             Paul Eggert  <eggert@cs.ucla.edu>
11846
11847         * modules/inttypes: New file.
11848         * modules/strtoimax, modules/strtoumax: Depend on inttypes.
11849
11850 2006-04-18  Derek Price  <derek@ximbiot.com>
11851             Paul Eggert  <eggert@cs.ucla.edu>
11852
11853         * m4/_inttypes_h.m4, m4/full-header-path.m4, m4/include_next.m4:
11854         New files.
11855
11856 2006-04-18  Derek Price  <derek@ximbiot.com>
11857             Paul Eggert  <eggert@cs.ucla.edu>
11858
11859         * lib/inttypes.h: New file.
11860         * lib/strtoimax.c: Assume <inttypes.h>.
11861
11862 2006-04-15  Paul Eggert  <eggert@cs.ucla.edu>
11863
11864         * lib/utimens.c (futimens): glibc futimesat messes up if /proc
11865         isn't mounted.  Problem reported by Kir Kolyshkin.
11866
11867 2006-04-13  Paul Eggert  <eggert@cs.ucla.edu>
11868
11869         * lib/regcomp.c (init_dfa): Don't use wchar_t or wctype_t if
11870         RE_ENABLE_I18N is not defined.  Problem reported by Mark D. Baushke via
11871         Derek R. Price.
11872         * lib/regex.h (RE_DUP_MAX): Update comment to match current
11873         implementation.
11874
11875 2006-04-12  Eric Blake  <ebb9@byu.net>
11876
11877         * modules/time_r (Makefile.am): Remove lib_SOURCES line, as this
11878         is now done automatically by the corresponding Autoconf macro.
11879
11880 2006-04-11  Paul Eggert  <eggert@cs.ucla.edu>
11881
11882         * m4/time_r.m4 (gl_TIME_R): Add AC_LIBSOURCES for time_r.c and
11883         time_r.h.
11884
11885 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
11886
11887         Merge regex changes from libc, removing some of our
11888         POSIX-conformance changes that were rejected and redoing them in a
11889         less-intrusive way.
11890
11891         * lib/regcomp.c (re_compile_internal, init_dfa):
11892         Length arg is now size_t, not Idx.  All uses changed.
11893         (peek_token): Forward decl now says internal_function.
11894         (__re_error_msgid, __re_error_msgid_idx):
11895         Now static rather than extern with attribute_hidden.
11896         (re_compile_pattern) [!defined _LIBC]: Use K&R-style defn.
11897         For some reason libc prefers K&R style defns for external functions.
11898         (regerror) [!defined _LIBC]: Likewise.
11899         (re_set_syntax, re_compile_fastmap, regcomp, regfree, re_comp):
11900         (seek_collating_symbol_entry, lookup_collation_sequence_value):
11901         (build_range_exp, build_collating_symbol):
11902         Use K&R-style defn.
11903         (re_compile_fastmap): Use '\0' to memset, not 0.
11904         (utf8_sb_map): Make the calculations more obvious.
11905         (init_dfa, parse_bracket_exp, build_charclass_op):
11906         Call calloc and cast result, as glibc does.
11907         (init_word_char, fetch_token, peek_token, peek_token_bracket):
11908         (build_range_exp, build_collating_symbol):
11909         Now internal functions.
11910
11911         * lib/regex.c [!defined _LIBC]: Allow compiling with C++ compilers.
11912
11913         * lib/regex.h (__USE_GNU_REGEX): New macro.  Don't depend on
11914         _REGEX_SOURCE any more; depend on _GNU_SOURCE instead.
11915         Don't depend on VMS; depend on __VMS instead, for POSIX
11916         namespace cleanness.
11917         (regoff_t): Define to ssize_t, not long int.
11918
11919         Remove the REG_ macros named below.  Instead, make the old names
11920         (e.g., RE_BACKSLASH_ESCAPE_IN_LISTS) visible only if
11921         __USE_GNU_REGEX.
11922         (REG_BACKSLASH_ESCAPE_IN_LISTS):
11923         (REG_BK_PLUS_QM, REG_CHAR_CLASSES, REG_CONTEXT_INDEP_ANCHORS):
11924         (REG_CONTEXT_INDEP_OPS, REG_CONTEXT_INVALID_OPS):
11925         (REG_DOT_NEWLINE, REG_DOT_NOT_NULL, REG_HAT_LISTS_NOT_NEWLINE):
11926         (REG_INTERVALS, REG_LIMITED_OPS, REG_NEWLINE_ALT):
11927         (REG_NO_BK_BRACES, REG_NO_BK_PARENS, REG_NO_BK_REFS):
11928         (REG_NO_BK_VBAR, REG_NO_EMPTY_RANGES):
11929         (REG_UNMATCHED_RIGHT_PAREN_ORD, REG_NO_POSIX_BACKTRACKING):
11930         (REG_NO_GNU_OPS, REG_DEBUG, REG_INVALID_INTERVAL_ORD):
11931         (REG_IGNORE_CASE, REG_CARET_ANCHORS_HERE):
11932         (REG_CONTEXT_INVALID_DUP, REG_NO_SUB, REG_SYNTAX_EMACS):
11933         (REG_SYNTAX_AWK, REG_SYNTAX_GNU_AWK, REG_SYNTAX_POSIX_AWK):
11934         (REG_SYNTAX_GREP, REG_SYNTAX_EGREP, REG_SYNTAX_POSIX_EGREP):
11935         (REG_SYNTAX_ED, REG_SYNTAX_SED, _REG_SYNTAX_POSIX_COMMON):
11936         (REG_SYNTAX_POSIX_BASIC, REG_SYNTAX_POSIX_MINIMAL_BASIC):
11937         (REG_SYNTAX_POSIX_EXTENDED, REG_SYNTAX_POSIX_MINIMAL_EXTENDED):
11938         (REG_DUP_MAX, REG_UNALLOCATED, REG_REALLOCATE, REG_FIXED):
11939         (REG_NREGS):
11940         Remove.  All uses replaced by the old RE_* names.
11941         (RE_BACKSLASH_ESCAPE_IN_LISTS):
11942         (RE_BK_PLUS_QM, RE_CHAR_CLASSES, RE_CONTEXT_INDEP_ANCHORS):
11943         (RE_CONTEXT_INDEP_OPS, RE_CONTEXT_INVALID_OPS):
11944         (RE_DOT_NEWLINE, RE_DOT_NOT_NULL, RE_HAT_LISTS_NOT_NEWLINE):
11945         (RE_INTERVALS, RE_LIMITED_OPS, RE_NEWLINE_ALT):
11946         (RE_NO_BK_BRACES, RE_NO_BK_PARENS, RE_NO_BK_REFS):
11947         (RE_NO_BK_VBAR, RE_NO_EMPTY_RANGES):
11948         (RE_UNMATCHED_RIGHT_PAREN_ORD, RE_NO_POSIX_BACKTRACKING):
11949         (RE_NO_GNU_OPS, RE_DEBUG, RE_INVALID_INTERVAL_ORD):
11950         (RE_IGNORE_CASE, RE_CARET_ANCHORS_HERE):
11951         (RE_CONTEXT_INVALID_DUP, RE_NO_SUB):
11952         Don't bother having these macros be independent of each others'
11953         values, since they no longer exist in the POSIX name space.
11954
11955         Rename the following member names back to their old names,
11956         unless !__USE_GNU_REGEX.  All uses changed back.
11957         (buffer): Renamed from re_buffer.
11958         (allocated): Renamed from re_allocated.
11959         (used): Renamed from re_used.
11960         (syntax): Renamed from re_syntax.
11961         (fastmap): Renamed from re_fastmap.
11962         (translate): Renamed from re_translate.
11963         (can_be_null): Renamed from re_can_be_null.
11964         (regs_allocated): Renamed from re_regs_allocated.
11965         (fastmap_accurate): Renamed from re_fastmap_accurate.
11966         (no_sub): Renamed from re_no_sub.
11967         (not_bol): Renamed from re_not_bol.
11968         (not_eol): Renamed from re_not_eol.
11969         (newline_anchor): Renamed from re_newline_anchor.
11970         (num_regs): Renamed from rm_num_regs.
11971         (start): Renamed from rm_start.
11972         (end): Renamed from rm_end.
11973
11974         (free_state): Move up a bit.
11975
11976         * lib/regex_internal.h (inline) [__GNUC__ < 3 && defined _LIBC]:
11977         #define to be empty.
11978         (ASCII_CHARS): New macro, replacing all uses of 0x80 and/or SBC_MAX / 2
11979         when that is what is intended.
11980         (SBC_MAX): Define to UCHAR_MAX + 1, not 256.
11981         (__re_error_msgid, __re_error_msgid_idx): Remove decls; not needed.
11982         (MAX): New macro.
11983         (re_xmalloc, re_calloc, re_xrealloc, re_x2realloc): Remove.
11984         All uses changed back to re_malloc, etc.  It's now the caller's
11985         responsibility to check for overflow; all callers changed.
11986         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc, re_xnrealloc):
11987         (re_x2nrealloc): Remove.
11988         (free_state): Remove decl.
11989
11990         * lib/regexc.c (regexec, re_match, re_search, re_match_2, re_search_2):
11991         (re_set_registers, re_exec):
11992         Use K&R-style defn.
11993
11994         2006-01-31  Roland McGrath  <roland@redhat.com>
11995
11996         * lib/regcomp.c (calc_eclosure_iter): Remove dead variables.
11997         Reported by Mike Frysinger <vapier@gentoo.org>.
11998
11999         2006-01-15  Andreas Jaeger  <aj@suse.de>
12000
12001         [BZ #1950]
12002         * lib/regex_internal.c (re_string_reconstruct): Adjust for
12003         build_wcs_upper_buffer change.
12004         (build_wcs_upper_buffer): Change return type.
12005
12006         2005-12-10  Ulrich Drepper  <drepper@redhat.com>
12007
12008         * lib/regex_internal.h: Include <stdint.h> if available.
12009
12010         2005-12-06  Paolo Bonzini  <bonzini@gnu.org>
12011
12012         * lib/regex_internal.h (SIZE_MAX): Provide a default definition.
12013
12014         2005-10-14  Ulrich Drepper  <drepper@redhat.com>
12015
12016         * lib/regcomp.c: Adjust for changed secondary hash function.
12017
12018         2005-09-30  Ulrich Drepper  <drepper@redhat.com>
12019
12020         * lib/regex.h: Pretty printing.
12021         Clean up namespace a bit.
12022
12023         2005-09-30  Jakub Jelinek  <jakub@redhat.com>
12024
12025         * lib/regexec.c (update_cur_sifted_state, check_arrival,
12026         check_arrival_add_next_nodes): Avoid using uninitialized variable.
12027
12028         2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
12029                     Ulrich Drepper  <drepper@redhat.com>
12030
12031         [BZ #1302]
12032         * lib/regex_internal.h (bitset_t): Renamed from bitset.  All uses
12033         changed.
12034         (bitset_word_t): Renamed from bitset_word.  All uses changed.
12035
12036         2005-09-22  Ulrich Drepper  <drepper@redhat.com>
12037
12038         [BZ #281]
12039         * lib/regex.h: Define RE_TRANSLATE_TYPE as unsigned char *.
12040         * lib/regcomp.c: Remove unnecessary uses of
12041         unsigned RE_TRANSLATE_TYPE.
12042         * lib/regex_internal.h: Likewise.
12043         * lib/regex_internal.c: Likewise.
12044         * lib/regexec.c: Likewise.
12045         Based on a patch by Stepan Kasal <kasal@ucw.cz>.
12046
12047         2005-09-07  Ulrich Drepper  <drepper@redhat.com>
12048
12049         * lib/regexec.c (find_recover_state): Remove unnecessary
12050         initialization.
12051         (transit_state_bkref): Make DFA a const pointer.
12052         (get_subexp): Likewise.
12053         (check_arrival): Likewise.
12054         (update_cur_sifted_state): Likewise.
12055         (re_search_internal): Likewise.
12056         (prune_impossible_nodes): Likewise.
12057         (acquire_init_state_context): Likewise.
12058         (proceed_next_node): Likewise.
12059         (set_regs): Likewise.
12060         (free_fail_stack_return): Likewise.
12061         (check_arrival_expand_ecl): Mark DFA parameter as const.
12062         (check_arrival_expand_ecl_sub): Likewise.
12063         (check_subexp_limits): Likewise.
12064         (sub_epsilon_src_nodes):  Likewise.
12065         (add_epsilon_src_nodes):  Likewise.
12066         (merge_state_array): Likewise.
12067         (update_regs): Likewise.
12068         (build_trtable): Likewise.
12069         (sift_states_backward): Mark MCTX parameter as const.
12070         (build_sifted_states): Likewise.
12071         (update_cur_sifted_state): Likewise.
12072         (sift_states_mkref): Likewise.
12073         (check_arrival_expand_ecl): Mark eclosure as const.
12074         (check_dst_limits_calc_pos_1): Likewise.
12075         * lib/regex_internal.h (re_match_context_t): Make dfa a const
12076         pointer.
12077
12078         2005-09-06  Ulrich Drepper  <drepper@redhat.com>
12079
12080         * lib/regexec.c (merge_state_with_log): Define dfa as const pointer.
12081         (transit_state_sb): Likewise.
12082         (transit_state_mb): Likewise.
12083         (sift_states_iter_mb): Likewise.
12084         (check_arrival_add_next_nodes): Likewise.
12085         (check_node_accept_bytes): Change first parameter to pointer-to-const.
12086         [_LIBC] (re_search_2_stub): Use mempcpy.
12087
12088         * lib/regex_internal.c (re_string_reconstruct): Avoid calling
12089         mbrtowc for very simple UTF-8 case.
12090
12091         * lib/regex_internal.c (re_acquire_state): Make DFA pointer arg
12092         a pointer-to-const.
12093         (re_acquire_state_context): Likewise.
12094         * lib/regex_internal.h: Adjust prototypes.
12095
12096         * lib/regex.c: Prevent using C++ compilers.
12097
12098         * lib/regex_internal.c (re_acquire_state): Minor code rearrangement.
12099         (re_acquire_state_context): Likewise.
12100
12101 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12102
12103         * modules/regex (Depends-on): Add ssize_t.
12104
12105 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12106
12107         * m4/regex.m4 (gl_REGEX): Check for new glibc interface to
12108         translation table.
12109
12110 2006-04-09  Paul Eggert  <eggert@cs.ucla.edu>
12111
12112         * doc/gnulib-tool.texi (Modified imports): pathname -> file name.
12113
12114 2006-03-29  Mark D. Baushke  <mdb@gnu.org>
12115             Bruno Haible  <bruno@clisp.org>
12116
12117         * lib/stdint_.h: On OpenBSD, don't redefine types already included in
12118         <sys/types.h> and <inttypes.h>.
12119
12120 2006-03-25  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12121
12122         * m4/argz.m4 (gl_FUNC_ARGZ): If we define `error_t', also define
12123         `__error_t_defined', so argp.h will not typedef the former.
12124
12125 2006-03-25  Paul Eggert  <eggert@cs.ucla.edu>
12126
12127         * m4/regex.m4 (gl_REGEX): Don't insist on REG_SYNTAX_POSIX_EGREP,
12128         REG_SYNTAX_EMACS, and REG_IGNORE_CASE.  Settle for the traditional
12129         glibc names.  Even if glibc is changed to conform to POSIX, the
12130         traditional names will be available anyway, since regex depends on
12131         the extensions module.  Also, fix a longstanding typo in the
12132         implementation of Spencer ERE test #75 from grep 2.3.  Problems
12133         reported by Emanuele Giaquinta.  Also, change sense of cached
12134         variable, so that the message makes sense.
12135
12136 2006-03-24  Simon Josefsson  <jas@extundo.com>
12137
12138         * lib/base64.c: Fix problems reported by Eric Blake <ebb9@byu.net>,
12139         including some doc fixes.
12140         (base64_encode_alloc): Fix +1 bug on allocation failures.
12141
12142 2006-03-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12143
12144         * lib/base64.c (base64_encode): Do not read past end of array with
12145         unsanitized input on systems with CHAR_BIT > 8.
12146
12147 2006-03-24  Eric Blake  <ebb9@byu.net>
12148
12149         * lib/time_r.c (copy_string_result): Remove, as it is no longer used.
12150
12151 2006-03-22  Karl Berry  <karl@gnu.org>
12152
12153         * config/srclist.txt (*setenv.[ch]): get from coreutils.
12154         * config/srclistvars.sh (COREUTILS): new var.
12155
12156 2006-03-17  Jim Meyering  <jim@meyering.net>
12157
12158         * m4/regex.m4 (gl_REGEX): Fix typo in last change:
12159         s/_REGEX_WIDE_OFFSETS/_REGEX_LARGE_OFFSETS/.
12160
12161 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
12162
12163         * m4/regex.m4 (gl_REGEX): Don't check for off_t, since the code
12164         no longer needs it.  Instead, check that regoff_t is as least
12165         as wide as ptrdiff_t.
12166
12167         Don't define _REGEX_WIDE_OFFSETS unless using the included regex,
12168         so that our regex.h stays compatible with the installed regex.
12169         This is helpful for installers who configure --without-included-regex.
12170         Problem reported by Emanuele Giaquinta.
12171
12172 2006-03-16  Paul Eggert  <eggert@cs.ucla.edu>
12173
12174         * lib/regex.h (regoff_t) [defined _REGEX_LARGE_OFFSETS]:
12175         Typedef to long int, not to off_, as POSIX will likely change
12176         in that direction.
12177
12178 2006-03-15  Eric Blake  <ebb9@byu.net>
12179
12180         * m4/dirfd.m4 (gl_FUNC_DIRFD): Use AC_REQUIRE for AC_HEADER_DIRENT.
12181
12182 2006-03-13  Sergey Poznyakoff  <gray@gnu.org.ua>
12183
12184         * lib/argp-help.c (validate_uparams): Fix typo
12185         * lib/argp-parse.c (argp_default_options): Consistently begin help
12186         messages with a lowercase letter.
12187
12188 2006-03-11  Paul Eggert  <eggert@cs.ucla.edu>
12189
12190         * lib/time_r.h (asctime_r, ctime_r): Remove.  These functions can
12191         overrun buffers and shouldn't be used (much as gets shouldn't be
12192         used).
12193         * lib/time_r.c (asctime_r, ctime_r): Likewise.
12194
12195 2006-03-08  Simon Josefsson  <jas@extundo.com>
12196
12197         * m4/gc-random.m4: Permit 'no' as variable values and fix warnings,
12198         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12199
12200 2006-03-08  Simon Josefsson  <jas@extundo.com>
12201
12202         * m4/gc-random.m4: Call AC_CANONICAL_HOST and use $host_os instead of
12203         $target, suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12204
12205 2006-03-08  Simon Josefsson  <jas@extundo.com>
12206
12207         * lib/gc-gnulib.c (randomize): Don't open files called 'no', they
12208         signal that configure disabled the device.
12209
12210 2006-03-08  Simon Josefsson  <jas@extundo.com>
12211
12212         * build-aux/maint.mk: Fix refresh-po, to handle no translated
12213         languages.
12214
12215 2006-03-07  Simon Josefsson  <jas@extundo.com>
12216
12217         * modules/getopt (Depends-on): Add unistd.
12218
12219         * modules/unistd: New file.
12220
12221 2006-03-07  Simon Josefsson  <jas@extundo.com>
12222
12223         * modules/gc-random: New file.
12224
12225 2006-03-07  Simon Josefsson  <jas@extundo.com>
12226
12227         * m4/unistd_h.m4: New file.
12228
12229 2006-03-07  Simon Josefsson  <jas@extundo.com>
12230
12231         * m4/readline.m4 (gl_FUNC_READLINE): Rewrite the cached part of the
12232         test to be side-effect free by storing the result in the cache
12233         variable gl_cv_lib_readline, and moving the assignment of
12234         LIBREADLINE and LTLIBREADLINE outside the COMMANDS-TO-SET-IT.
12235         From Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12236
12237 2006-03-07  Simon Josefsson  <jas@extundo.com>
12238
12239         * m4/gc-random.m4: New file, mostly from gc.m4.  Warn instead of
12240         error on missing devices (the functions will return an error).
12241
12242         * m4/gc.m4: Move random stuff to gc-random.m4
12243
12244 2006-03-07  Simon Josefsson  <jas@extundo.com>
12245
12246         * lib/unistd_.h: New file.
12247
12248 2006-03-07  Simon Josefsson  <jas@extundo.com>
12249
12250         * lib/gc-libgcrypt.c, gc-gnulib.c: Use GC_USE_RANDOM.
12251
12252 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12253
12254         * m4/unistd_h.m4 (gl_HEADER_UNISTD): Rename, to match modules file.
12255         Problem reported by Juan Manuel Guerrero.
12256
12257 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12258
12259         * lib/c-stack.c: Include unistd.h unconditionally, since we now assume
12260         the unistd module.
12261         * lib/getlogin_r.c: Likewise.
12262         * lib/getlogin_r.h: Likewise.
12263         * lib/glob.c: Likewise.
12264         * lib/pagealign_alloc.c: Likewise.
12265         * lib/unistd_.h: Remove; no longer needed.
12266
12267 2006-03-07  Paul Eggert  <eggert@cs.ucla.edu>
12268
12269         * MODULES.html.sh (Support for systems lacking POSIX:2001):
12270         Add unistd.
12271         * modules/c-stack (Depends-on): Add unistd.
12272         * modules/getlogin_r: Likewise.
12273         * modules/glob: Likewise.
12274         * modules/pagealign_alloc: Likewise.
12275         * modules/unistd (Files): Remove lib/unistd_.h.
12276         (EXTRA_DIST): Remove.
12277         (unistd.h): Create using 'echo' rather than 'cp', so that we don't
12278         need unistd_.h.
12279         (MOSTLYCLEANFILES): Remove unistd.h-t.
12280
12281 2006-03-03  Simon Josefsson  <jas@extundo.com>
12282
12283         * build-aux/maint.mk: Add several syntax checks from CoreUtils.
12284
12285 2006-03-03  Simon Josefsson  <jas@extundo.com>
12286
12287         * build-aux/maint.mk: Add refresh-po rule, based on ideas from
12288         libidn and bison.
12289
12290 2006-03-03  Simon Josefsson  <jas@extundo.com>
12291
12292         * build-aux/maint.mk: Add indent target.
12293
12294 2006-03-03  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de> (tiny change)
12295
12296         * m4/poll.m4 (gl_FUNC_POLL): If we deem poll(2) unacceptable, use
12297         our replacement poll.h in any case, to avoid a differing
12298         declaration from a system header.  Seen on AIX.
12299
12300 2006-03-01  Simon Josefsson  <jas@extundo.com>
12301
12302         * lib/readline.c: Fix typo, tiny patch from Stepan Kasal
12303         <kasal@ucw.cz>.
12304
12305 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12306
12307         * modules/gettime (Depends-on): Add extensions module.
12308         * modules/nanosleep (Depends-on): Likewise.
12309         * modules/settime (Depends-on): Likewise.
12310
12311 2006-03-01  Paul Eggert  <eggert@cs.ucla.edu>
12312
12313         * m4/clock_time.m4 (gl_CLOCK_TIME): Require gl_USE_SYSTEM_EXTENSIONS,
12314         not merely AC_GNU_SOURCE, for the benefit of Solaris 10 when compiled
12315         pedantically.
12316         * m4/nanosleep.m4 (gl_FUNC_NANOSLEEP): Likewise.
12317         * m4/timespec.m4 (gl_TIMESPEC): Likewise.
12318
12319         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Use "=" with "test",
12320         not "==".  Reported by Ralf Wildenhues.
12321
12322 2006-03-01  Karl Berry  <karl@gnu.org>
12323
12324         * doc/Copyright/request-*: new files, synced from gnuorg.
12325
12326 2006-03-01  Karl Berry  <karl@gnu.org>
12327
12328         * config/srclist.txt (Copyright/*): new entries.
12329
12330 2006-02-28  Simon Josefsson  <jas@extundo.com>
12331
12332         * lib/getopt.c: Protect #include of unistd.h, for MSVS.
12333
12334 2006-02-27  Simon Josefsson  <jas@extundo.com>
12335
12336         * lib/base64.h: Indent #define's.  From Jim Meyering
12337         <jim@meyering.net>.
12338
12339 2006-02-27  Jim Meyering  <jim@meyering.net>
12340
12341         Revert the change of 2006-02-24, so these files can continue
12342         to be sync'd from gettext.
12343         * lib/mkdtemp.c, setenv.c, unsetenv.c: *Un*-normalize inclusion
12344         of `config.h'.
12345
12346 2006-02-26  Paul Eggert  <eggert@cs.ucla.edu>
12347
12348         * modules/intprops: New file.
12349         * MODULES.html.sh (Numeric conversion functions <stdlib.h>):
12350         Add intprops.
12351         * modules/getloadavg (Files): Remove lib/intprops.h.
12352         (Depends-on): Add intprops.
12353         * modules/human: Likewise.
12354         * modules/inttostr: Likewise.
12355         * modules/openat: Likewise.
12356         * modules/sig2str: Likewise.
12357         * modules/userspec: Likewise.
12358         * modules/utimecmp: Likewise.
12359         * modules/xnanosleep: Likewise.
12360         * modules/xstrtol: Likewise.
12361
12362 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny changes)
12363
12364         * modules/xstrtod: Omit xstrtod.h, xstrtod.c; they're in LIB_SOURCES.
12365         * modules/lock-tests (TESTS): Use $(EXEEXT).
12366         * modules/tls-tests: Likewise.
12367         * modules/argp-tests: Likewise.
12368         (check_PROGRAMS): New var, replacing...
12369         (noinst_PROGRAMS, test_argp_SOURCES): Remove.
12370
12371 2006-02-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12372
12373         * lib/mkdtemp.c, lib/setenv.c, lib/unsetenv.c: Normalize inclusion of
12374         `config.h'.
12375
12376 2006-02-24  Paul Eggert  <eggert@cs.ucla.edu>
12377
12378         * lib/glob.c: Say "invalid" rather than "illegal" in comments.
12379
12380 2006-02-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
12381
12382         Sync from coreutils.
12383         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Require gl_FUNC_LCHMOD and
12384         gl_CHDIR_SAFER.
12385
12386 2006-02-22  Jim Meyering  <jim@meyering.net>
12387
12388         Sync from coreutils.
12389         * m4/chdir-safer.m4: New file.
12390
12391 2006-02-20  Paul Eggert  <eggert@cs.ucla.edu>
12392
12393         * lib/getcwd.c (AT_FDCWD): Work around a bug in Solaris 9 and 10, where
12394         AT_FDCWD exceeds INT_MAX.
12395         * lib/openat.h (AT_FDCWD): Likewise.
12396
12397 2006-02-17  Eric Blake  <address@hidden>
12398
12399         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Fix caching error.
12400
12401 2006-02-16  Simon Josefsson  <jas@extundo.com>
12402
12403         * modules/getaddrinfo (Depends-on): Add sys_socket.
12404
12405 2006-02-15  Simon Josefsson  <jas@extundo.com>
12406
12407         * build-aux/maint.mk: Add dsyntax-check rule.
12408
12409 2006-02-15  Eric Blake  <ebb9@byu.net>
12410
12411         * m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Don't attempt using
12412         winsock2.h or ws2tcpip.h when sys/socket.h is present. Fixes
12413         'present but cannot compile' warnings on cygwin.
12414         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Use gl_HEADER_SYS_SOCKET.  Don't
12415         use ws2tcpip.h if sys/socket.h works.
12416         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Use gl_HEADER_SYS_SOCKET.
12417         (gl_GETADDRINFO): Don't use ws2tcpip.h when sys/socket.h is present.
12418
12419 2006-02-14  Simon Josefsson  <jas@extundo.com>
12420
12421         * modules/maintainer-makefile (Files): Rename.
12422
12423         * build-aux/GNUmakefile: Rename Makefile.maint to maint.mk
12424         and (the local) Makefile.cfg to maint-cfg.mk.
12425
12426         * build-aux/Makefile.maint, build-aux/maint.mk: Renamed the former
12427         to the latter.
12428
12429         * modules/maintainer-makefile: New module.
12430
12431         * build-aux/Makefile.maint: New file, from GNU CoreUtils, although
12432         severaly stripped to make it possible to build it up from scratch
12433         with reliable tests.
12434
12435         * build-aux/GNUmakefile: New file, from GNU CoreUtils with some
12436         fixes to permit overriding the default actions when configure and
12437         makefile are not available.
12438
12439 2006-02-14  Paul Eggert  <eggert@cs.ucla.edu>
12440
12441         Sync from coreutils.
12442         * modules/lstat (Depends-on): Don't depend on xalloc.
12443         (License): Change from GPL to LGPL, since this is now simply a
12444         replacement for a libc function.
12445
12446 2006-02-14  Jim Meyering  <jim@meyering.net>
12447
12448         Sync from coreutils.
12449
12450         Eliminate the unwelcome (albeit unlikely) possibility of xmalloc
12451         failure on deficient systems, and simplify gnulib lgpl dependencies.
12452         * lib/lstat.c (rpl_lstat): Rewrite to use stat() in place of the
12453         xmalloc/lstat combination.  Based on a patch from Bruno Haible.
12454
12455         * lib/xalloc-die.c: Remove unused definition of N_.
12456
12457 2006-02-14  Jim Meyering  <jim@meyering.net>
12458
12459         Sync from coreutils.
12460         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Invoke
12461         AC_CHECK_FUNCS(getmntent) unconditionally so that tests of
12462         $ac_cv_func_getmntent (e.g., in gl_LIST_MOUNTED_FILE_SYSTEMS) need not
12463         double-quote uses of that variable, to accommodate the rare case in
12464         which getmntent is available in none of the libraries checked.  This
12465         happens at least on FreeBSD 5.0.
12466
12467 2006-02-13  Simon Josefsson  <jas@extundo.com>
12468
12469         * gnulib-tool (Usage): Fix --import, from
12470         karl@freefriends.org (Karl Berry).
12471
12472 2006-02-13  Sergey Poznyakoff  <gray@gnu.org.ua>
12473
12474         * lib/argp-fmtstream.c: Restore another bugfix lost on 2005-12-12
12475
12476 2006-02-07  Sergey Poznyakoff  <gray@gnu.org.ua>
12477
12478         * lib/argp-namefrob.h: Restore changes accidentally lost during the
12479         "autoupdate" on 2005-12-12.
12480
12481 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
12482
12483         * modules/closeout (Depends-on): Remove atexit.
12484
12485 2006-02-07  Paul Eggert  <eggert@cs.ucla.edu>
12486
12487         * lib/closeout.c (close_stdout): Don't assume 'bool' converts nonzero
12488         ints to 0 or 1, as this isn't true for the stdbool.h substitute.
12489
12490 2006-02-05  Paul Eggert  <eggert@cs.ucla.edu>
12491
12492         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Don't #define
12493         __EXTENSIONS__ if this causes compilation to fail.  Problem
12494         reported by Nelson H. F. Beebe with Solaris 10 and Sun C 5.7
12495         c89 -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED.
12496
12497 2006-01-27  Paul Eggert  <eggert@cs.ucla.edu>
12498
12499         * lib/fnmatch.c (L_): Renamed from L, to work around a bug in
12500         Mac OS X 10.3.9 with GCC 3 reported by Claudio Fontana in
12501         <http://lists.gnu.org/archive/html/bug-gnulib/2006-01/msg00074.html>.
12502         All uses changed.
12503
12504 2006-01-26  Simon Josefsson  <jas@extundo.com>
12505
12506         * lib/socket_.h: Set WINVER to 0x0501, to make sure getaddrinfo
12507         prototype is visible on mingw32.
12508
12509         * lib/getaddrinfo.h: Define EAI_ADDRFAMILY and EAI_SYSTEM if not set,
12510         for mingw32.
12511
12512         * lib/gai_strerror.c, getaddrinfo.h: Protect netdb.h #include (for
12513         mingw32).
12514
12515 2006-01-26  Paul Eggert  <eggert@cs.ucla.edu>
12516
12517         * lib/fts.c (diropen): Open with O_NOCTTY | O_NONBLOCK too.  Don't
12518         attempt to open for write; this always fails, at least on POSIX
12519         hosts.  This reinstates the 2006-01-09 change, which was
12520         inadvertently removed.
12521
12522 2006-01-26  Bruno Haible  <bruno@clisp.org>
12523
12524         * gnulib-tool (func_import): Use "trap 'exit $?' instead of "trap :".
12525         Reported by Paul Eggert.
12526
12527 2006-01-26  Bruno Haible  <bruno@clisp.org>
12528             Paul Eggert  <eggert@cs.ucla.edu>
12529
12530         * lib/stdbool_.h (_Bool)
12531         [(! (defined __cplusplus || defined __BEOS__)
12532           && !defined __GNUC__
12533           && !(defined __HP_cc || defined __xlc__
12534                || (defined __SUNPRO_C && (__SUNPRO_C < 0x550 || __STDC__ == 1))
12535                || defined __sgi))]:
12536         #define to signed char in these cases too; this simplifies
12537         the code (so that we don't have to worry about HP-UX, AIX, SunPRO,
12538         etc., separately) and makes it more conservative.
12539
12540 2006-01-25  Simon Josefsson  <jas@extundo.com>
12541
12542         * m4/getaddrinfo.m4: Look for getaddrinfo inside ws2tcip.h and
12543         -lws2_32.  Protect sys/socket.h and netdb.h #include's.  Include
12544         ws2tcpip.h with WINVER=0x0501.  All for mingw32.
12545
12546 2006-01-25  Sergey Poznyakoff  <gray@gnu.org.ua>
12547
12548         * lib/argp-namefrob.h: Bugfix. Remove stray #
12549
12550 2006-01-25  Paul Eggert  <eggert@cs.ucla.edu>
12551
12552         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for xlc bug if __GCC__ too,
12553         so that we test the test.
12554         Check for yet another HP-UX cc bug involving *bool |= bool.
12555
12556 2006-01-25  Karl Berry  <karl@gnu.org>
12557
12558         * config/srclist.txt (vasnprintf.c): sync lost.
12559
12560 2006-01-25  Jim Meyering  <jim@meyering.net>
12561
12562         Sync from the stable (b5) branch of coreutils:
12563
12564         * lib/fts.c (fts_children): Don't let close() clobber errno from
12565         failed fchdir().
12566
12567         * lib/fts.c (fts_stat): When following a symlink-to-directory,
12568         don't necessarily interpret stat-fails+lstat-succeeds as indicating
12569         a dangling symlink.  That can also happen at least for ELOOP.
12570         The fix: return FTS_SLNONE only when the stat errno is ENOENT.
12571         FYI, this bug predates the inclusion of fts.c in coreutils.
12572
12573         * lib/fts.c (fts_open): Put new maxarglen declaration and uses
12574         in their own block, so pre-c99 compilers don't object.
12575
12576         Avoid the double-free (first in fts_read, second in fts_close) that
12577         would occur when an `active' directory is made inaccessible (e.g.,
12578         via chmod a-x) during a traversal.
12579         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12580         before returning.  Reproduce this failure by
12581         mkdir -p a/b; cd a; chmod a-x . b
12582         Reported by Stavros Passas.
12583
12584 2006-01-25  Jim Meyering  <jim@meyering.net>
12585
12586         * lib/fileblocks.c: Remove more useless parentheses.
12587         * lib/readutmp.h: Likewise.
12588
12589 2006-01-25  Bruno Haible  <bruno@clisp.org>
12590
12591         * lib/stdbool_.h (_Bool) [IRIX cc]: Define as 'signed char', to avoid
12592         warnings.
12593         Reported by Paul Eggert.
12594
12595 2006-01-25  Bruno Haible  <bruno@clisp.org>
12596
12597         * gnulib-tool (func_import): Use "trap :" instead of "trap -" to get
12598         rid of a trap command. For Solaris sh.
12599         Reported by Mark D. Baushke <mdb@gnu.org>.
12600
12601 2006-01-24  Simon Josefsson  <jas@extundo.com>
12602
12603         * lib/socket_.h (SHUT_WR, SHUT_RDWR): Don't hardcode, suggested by
12604         Bruno.
12605
12606 2006-01-24  Karl Berry  <karl@gnu.org>
12607
12608         * config/srclist.txt (argp-namefrob.h): sync lost.
12609
12610 2006-01-24  Jim Meyering  <jim@meyering.net>
12611
12612         * modules/openat (Files): Add lib/intprops.h.
12613         From Mark D. Baushke.
12614
12615 2006-01-24  Jim Meyering  <jim@meyering.net>
12616
12617         * m4/openat.m4 (gl_FUNC_OPENAT): Add AC_LIBSOURCES([intprops.h]).
12618         Reported by Mark D. Baushke.
12619
12620 2006-01-24  Jim Meyering  <jim@meyering.net>
12621
12622         * lib/socket_.h: Remove useless parentheses in uses of cpp `defined'.
12623
12624 2006-01-24  Bruno Haible  <bruno@clisp.org>
12625
12626         * modules/strnlen (Maintainer): Change from glibc to all.
12627
12628 2006-01-24  Bruno Haible  <bruno@clisp.org>
12629
12630         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check for IBM and HP-UX bugs.
12631         Patch by Paul Eggert.
12632
12633 2006-01-24  Bruno Haible  <bruno@clisp.org>
12634
12635         * lib/stdbool_.h (_Bool) [__cplusplus]: Don't define if the compiler
12636         already has it.
12637         Report and patch by Albert Chin-A-Young  <china@thewrittenword.com> on
12638         2005-11-26.
12639
12640         * lib/stdbool_.h (_Bool) [HP-UX cc, AIX cc,xlc]: Define as
12641         'signed char' to avoid problems with the built-in _Bool type.
12642         Reported by Paul Eggert on 2005-11-26.
12643
12644 2006-01-24  Bruno Haible  <bruno@clisp.org>
12645
12646         * gnulib-tool (func_import): Avoid constructing complicated sed
12647         expressions inside backquote.
12648         Report and solution by Mark D. Baushke <mdb@gnu.org>.
12649
12650 2006-01-23  Ulrich Drepper  <drepper@redhat.com>
12651
12652         These changes imported from libc.
12653         * lib/getopt.c: Use __fxprintf instead of inline stream orientation
12654         test and two separate function calls.
12655         * lib/strndup.c (__strndup): Add libc_hidden_def.
12656
12657 2006-01-23  Simon Josefsson  <jas@extundo.com>
12658
12659         * modules/lock-tests: Use check_PROGRAMS instead of noinst_PROGRAMS.
12660         Remove the test_*_SOURCES variable: automake infers it by default.
12661         * modules/tls-tests: Likewise.
12662
12663 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12664
12665         Work around porting bugs reported by Dieter in
12666         <http://lists.gnu.org/archive/html/bug-bison/2006-01/msg00049.html>.
12667         * lib/getopt.c (_NOPROTO): Remove; no longer needed.
12668         Include <stdlib.h> and <unistd.h> in all environments; it's safe now.
12669         Include "getopt.h" first, to check interface.
12670         (getenv): Declare only if defined HAVE_DECL_GETENV &&
12671         !HAVE_DECL_GETENV.
12672         * lib/strndup.c [!_LIBC]: Include "strndup.h" to get prototype.
12673         (__strndup): Revert to K&R-style function dfns, the glibc style.
12674         * lib/strnlen.c: Don't claim it's taken from glibc; it's not.
12675         (strnlen, __strnlen): Remove #defines and #undefs; not needed.
12676         Include strnlen.h first, to get prototype properly.
12677         (strnlen): Renamed from __strnlen.
12678         Remove weak alias.
12679
12680 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12681
12682         * m4/getopt.m4 (gl_PREREQ_GETOPT): Check for getenv decl.
12683
12684 2006-01-23  Paul Eggert  <eggert@cs.ucla.edu>
12685
12686         * config/srclist.txt: Adjust to reflect glibc reorganization.
12687         This affects only comments.
12688
12689 2006-01-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
12690
12691          * gnulib-tool, build-aux/csharpcomp.sh.in: Do not pass `-q' to mktemp.
12692          Reported by Bruce Korb <bkorb@gnu.org>.
12693
12694 2006-01-22  Paul Eggert  <eggert@cs.ucla.edu>
12695
12696         * lib/quotearg.c (quotearg_buffer_restyled): Add "default: break;"
12697         to pacify gcc -Wswitch-default.
12698
12699 2006-01-22  Bruno Haible  <bruno@clisp.org>
12700
12701         * lib/vasnprintf.c (VASNPRINTF): In the computation of the size of the
12702         temporary buffer for sprintf, take into account the precision also
12703         for 'd', 'i', 'u', 'o', 'x', 'X'.
12704
12705 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
12706
12707         * modules/argp-tests: New module
12708         * tests/test-argp.c: New file
12709         * tests/test-argp-2.sh: New file
12710
12711 2006-01-21  Sergey Poznyakoff  <gray@gnu.org.ua>
12712
12713         * lib/argp-help.c (usage_long_opt): Do not print DOC options.
12714         (__argp_base_name): Removed
12715         * lib/argp-namefrob.h (__argp_basename): Removed definition. Was a
12716         typo.
12717         (__argp_base_name): Provide macro definition or extern declaration
12718         depending on the configuration
12719
12720 2006-01-20  Simon Josefsson  <jas@extundo.com>
12721
12722         * modules/inet_ntop (Depends-on): Depend on sys_socket.
12723
12724 2006-01-20  Simon Josefsson  <jas@extundo.com>
12725
12726         * lib/inet_ntop.h: Unconditionally include sys/socket.h.
12727
12728 2006-01-20  Paul Eggert  <eggert@cs.ucla.edu>
12729
12730         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Use -Wl,-z,ignore
12731         rather than -Xlinker -z -Xlinker ignore, as it's more portable.
12732         Suggested by Bruno Haible.
12733
12734 2006-01-20  Karl Berry  <karl@gnu.org>
12735
12736         * config/srclist.txt (argp-fmtstream.h, localcharset.c): comment out
12737         until changes propagate, I guess.
12738
12739 2006-01-19  Simon Josefsson  <jas@extundo.com>
12740
12741         * m4/socklen.m4: Look in ws2tcpip.h too, for mingw32.
12742
12743 2006-01-19  Simon Josefsson  <jas@extundo.com>
12744
12745         * lib/socket_.h: Map SHUT_RD, SHUT_WR, SHUT_RDWR correctly.
12746
12747 2006-01-19  Simon Josefsson  <jas@extundo.com>
12748
12749         * gnulib-tool: Set check_PROGRAMS.
12750
12751         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12752         modules/des-tests, modules/gc-arcfour-tests,
12753         modules/gc-arctwo-tests, modules/gc-des-tests,
12754         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12755         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12756         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12757         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12758         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12759         modules/md5-tests, modules/readline, modules/rijndael-tests: Use
12760         check_PROGRAMS instead of noinst_PROGRAMS to be able to remove
12761         test_*_SOURCES.
12762
12763 2006-01-18  Simon Josefsson  <jas@extundo.com>
12764
12765         * modules/socklen (Depends-on): Depend on sys_socket.
12766
12767 2006-01-18  Simon Josefsson  <jas@extundo.com>
12768
12769         * modules/arcfour-tests, modules/arctwo-tests, modules/crc-tests,
12770         modules/des-tests, modules/gc-arcfour-tests,
12771         modules/gc-arctwo-tests, modules/gc-des-tests,
12772         modules/gc-hmac-md5-tests, modules/gc-hmac-sha1-tests,
12773         modules/gc-md2-tests, modules/gc-md4-tests, modules/gc-md5-tests,
12774         modules/gc-pbkdf2-sha1-tests, modules/gc-rijndael-tests,
12775         modules/gc-sha1-tests, modules/gc-tests, modules/hmac-md5-tests,
12776         modules/hmac-sha1-tests, modules/md2-tests, modules/md4-tests,
12777         modules/md5-tests, modules/readline, modules/rijndael-tests: Add
12778         $(EXEEXT) to automake TESTS variable, for mingw32.
12779
12780 2006-01-17  Simon Josefsson  <jas@extundo.com>
12781
12782         * modules/socklen (Include): Need sys/socket.h.
12783
12784 2006-01-17  Bruno Haible  <bruno@clisp.org>
12785
12786         * modules/ssize_t (Include): Add <sys/types.h>.
12787
12788 2006-01-16  Paul Eggert  <eggert@cs.ucla.edu>
12789
12790         * m4/lib-ignore.m4 (gl_IGNORE_UNUSED_LIBRARIES): Don't use ldd, as
12791         it's not portable and it doesn't work with cross-compiles.
12792         Problem reported by Bruno Haible.  Fix missing-$ typo in
12793         'test "gl_cv_ignore_unused_libraries" ...' that prevented
12794         -zignore from being used with Sun's C compiler.
12795
12796 2006-01-12  Simon Josefsson  <jas@extundo.com>
12797
12798         * lib/base64.c: Fix warning, reported by Bruno Haible
12799         <bruno@clisp.org> and patch by Paul Eggert <eggert@CS.UCLA.EDU>.
12800
12801 2006-01-12  Bruno Haible  <bruno@clisp.org>
12802
12803         * modules/ldd: New file.
12804         * build-aux/ldd.sh.in: New file.
12805         * MODULES.html.sh (Support for building libraries and executables): Add
12806         ldd.
12807
12808 2006-01-12  Bruno Haible  <bruno@clisp.org>
12809
12810         * m4/ldd.m4: New file.
12811
12812 2006-01-12  Bruno Haible  <bruno@clisp.org>
12813
12814         * gnulib-tool (func_import, func_create_testdir): Don't go into an
12815         endless loop while replacing $auxdir with build-aux.
12816
12817 2006-01-11  Simon Josefsson  <jas@extundo.com>
12818
12819         * lib/stdint_.h (SIZE_MAX): Add missing (.
12820
12821 2006-01-11  Paul Eggert  <eggert@cs.ucla.edu>
12822
12823         Sync from coreutils.
12824         * lib/md5.c: Fix commentary typos.
12825         (alignof, UNALIGNED_P): No need for a GCC-specific version.
12826         * lib/md5.h (__attribute__): Remove; unused.
12827         * lib/sha1.c: Fix commentary to match md5 better.
12828         * lib/sha1.h (struct sha1_ctx): Use a word buffer, not a byte buffer,
12829         so that we don't need to worry about alignment.  All uses changed.
12830         This merges the 2005-10-28 md5 change into sha1.
12831
12832 2006-01-11  Jim Meyering  <jim@meyering.net>
12833
12834         Sync from coreutils.
12835         * lib/md5.c (OP): Fix spacing.
12836
12837 2006-01-11  Bruno Haible  <bruno@clisp.org>
12838
12839         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12840         * m4/lock.m4 (gl_LOCK_BODY): Renamed from gl_LOCK.
12841         (gl_LOCK): New macro, requiring gl_LOCK_BODY.
12842
12843 2006-01-11  Bruno Haible  <bruno@clisp.org>
12844
12845         Ensure automatic ordering between gl_LOCK and gl_ARGP.
12846         * gnulib-tool (func_import, func_create_testdir): Put gl_LOCK into
12847         the "early" section as well.
12848
12849 2006-01-11  Bruno Haible  <bruno@clisp.org>
12850
12851         Avoid "ar: no archive members specified" error on MacOS X.
12852         * gnulib-tool (func_modules_add_dummy): New function.
12853         (func_import, func_create_testdir): Invoke it.
12854
12855 2006-01-11  Bruno Haible  <bruno@clisp.org>
12856
12857         * gnulib-tool (func_import, func_create_testdir): Replace build-aux
12858         with $auxdir in AC_CONFIG_FILES statements.
12859
12860 2006-01-11  Bruno Haible  <bruno@clisp.org>
12861
12862         * gnulib-tool (func_emit_lib_Makefile_am, func_emit_tests_Makefile_am):
12863         Initialize also noinst_HEADERS to empty.
12864
12865 2006-01-11  Bruno Haible  <bruno@clisp.org>
12866
12867         * gnulib-tool (AUTOMAKEPATH, AUTOCONF, ACLOCAL, AUTOMAKE): New
12868         variables.
12869         (func_create_megatestdir): Call aclocal, autoconf, automake here, not
12870         autoreconf.
12871
12872 2006-01-11  Bruno Haible  <bruno@clisp.org>
12873
12874         * gnulib-tool (AUTOCONF, ACLOCAL, AUTOMAKE, AUTORECONF): Make
12875         overridable by the user.
12876         Reported by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
12877
12878 2006-01-10  Simon Josefsson  <jas@extundo.com>
12879
12880         * modules/sys_socket: New file.
12881
12882 2006-01-10  Simon Josefsson  <jas@extundo.com>
12883
12884         * m4/sys_socket_h.m4: New file.
12885
12886 2006-01-10  Simon Josefsson  <jas@extundo.com>
12887
12888         * lib/socket_.h: New file.
12889
12890 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12891
12892         * modules/readutmp (Maintainer): Add myself.
12893
12894 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12895
12896         * m4/memcoll.m4 (gl_MEMCOLL): Don't require AC_FUNC_MEMCMP, undoing
12897         the 2002-12-31 change.  Problem and fix reported by Bruno Haible.
12898         People who are still concerned with buggy memcmp implementations
12899         can invoke gl_FUNC_MEMCMP themselves.
12900
12901 2006-01-10  Paul Eggert  <eggert@cs.ucla.edu>
12902
12903         * lib/regex_internal.h (BITSET_WORD_BITS):
12904         Work around a bug in 64-bit PGC (before version 6.1-2), where the
12905         preprocessor mishandles large unsigned values as if they were signed.
12906         Problem reported by Claudio Fontana in
12907         <http://lists.gnu.org/archive/html/bug-gnulib/2005-12/msg00061.html>.
12908
12909 2006-01-10  Jim Meyering  <jim@meyering.net>
12910
12911         Avoid the double-free (first in fts_read, second in fts_close) that
12912         would occur when an `active' directory is made inaccessible (e.g.,
12913         via chmod a-x) during a traversal.
12914         * lib/fts.c (fts_read): After a failed fchdir, update sp->fts_cur
12915         before returning.  Reproduce this failure by
12916         mkdir -p a/b; cd a; chmod a-x . b
12917         Reported by Stavros Passas.
12918
12919         Sync from coreutils.
12920         * lib/sha1.c: Tweak grammar in a comment.
12921
12922 2006-01-10  Jim Meyering  <jim@meyering.net>
12923
12924         * m4/fpending.m4: Also include <stdio.h>, for Dragonfly.
12925         Patch by Joerg Sonnenberger.
12926
12927 2006-01-10  Bruno Haible  <bruno@clisp.org>
12928
12929         * modules/readutmp: Depend on module free.
12930         * modules/strtok_r: Depend on module restrict.
12931
12932 2006-01-10  Bruno Haible  <bruno@clisp.org>
12933
12934         * modules/gettext (configure.ac): Add an invocation of
12935         AM_GNU_GETTEXT_VERSION. Needed since autoreconf is used by gnulib-tool.
12936
12937 2006-01-10  Bruno Haible  <bruno@clisp.org>
12938
12939         * m4/localcharset.m4 (gl_LOCALCHARSET): Also test for getc_unlocked.
12940         Reported by Werner Lemberg <wl@gnu.org>.
12941
12942 2006-01-10  Bruno Haible  <bruno@clisp.org>
12943
12944         * lib/localcharset.c: Update from GNU gettext.
12945
12946 2006-01-10  Bruno Haible  <bruno@clisp.org>
12947
12948         * lib/argp.h (__const): Remove macro. Use const instead.
12949         * lib/argp-fmtstream.h (__const): Likewise.
12950         * lib/glob_.h (__const): Remove macro.
12951         * lib/glob-libc.h: Use const instead of __const.
12952
12953 2006-01-10  Bruno Haible  <bruno@clisp.org>
12954
12955         * gnulib-tool (func_emit_tests_Makefile_am): Emit an empty SUBDIR
12956         variable.
12957         Needed to avoid an automake error regarding the 'gettext' module.
12958
12959 2006-01-09  Simon Josefsson  <jas@extundo.com>
12960
12961         * modules/inet_ntop (Depends-on): Add restrict.
12962
12963 2006-01-09  Simon Josefsson  <jas@extundo.com>
12964
12965         * modules/gc-rijndael-tests (License): Put under LGPL.
12966
12967         * modules/gc-des-tests (License): Likewise.
12968
12969         * modules/gc-arcfour-tests (License): Likewise.
12970
12971         * modules/gc-arctwo-tests (License): Likewise.
12972
12973         * modules/gc-pbkdf2-sha1-tests (License): Likewise.
12974
12975         * modules/gc-hmac-sha1-tests (Files): Likewise.
12976
12977         * modules/gc-hmac-md5-tests (License): Likewise.
12978
12979         * modules/gc-sha1-tests (License): Likewise.
12980
12981         * modules/gc-md5-tests (License): Likewise.
12982
12983         * modules/gc-md4-tests (License): Likewise.
12984
12985         * modules/gc-md2-tests (License): Likewise.
12986
12987         * modules/gc-tests (License): Likewise.
12988
12989         * modules/des-tests (License): Likewise.
12990
12991         * modules/md4-tests (License): Likewise.
12992
12993         * modules/md2-tests (License): Likewise.
12994
12995 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
12996
12997         Sync from coreutils:
12998
12999         * MODULES.html.sh (build_lib): New section, with new lib-ignore module.
13000         * modules/lib-ignore: New file.
13001         * modules/mkdir-p (Files): Add chdir-safer.c, chdir-safer.h, lchmod.h,
13002         chdir-safer.m4, lchmod.m4.
13003         * modules/openat: Add mkdirat.c, openat-priv.h.
13004
13005 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13006
13007         Sync from coreutils.
13008         * m4/lib-ignore.m4: New file.
13009         * m4/lchmod.m4: New file.
13010
13011 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13012
13013         Sync from coreutils.
13014         * lib/chdir-long.c (cdb_free): Don't bother trying to open directory
13015         for write access: POSIX says that must fail.
13016         * lib/fts.c (diropen): Likewise.
13017         * lib/save-cwd.c (save_cwd): Likewise.
13018         * lib/chdir-long.c (cdb_free): Open with O_NOCTTY | O_NONBLOCK as
13019         well, for minor improvements on hosts that lack O_DIRECTORY.
13020         * lib/chown.c (rpl_chown) [CHOWN_MODIFIES_SYMLINK]:
13021         Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
13022         Fall back on chown if open failed with EACCES.
13023
13024         * lib/gettime.c (gettime) [!defined OK_TO_USE_1S_CLOCK]:
13025         Report an error at compile-time if only a 1-second nominal clock
13026         resolution is found.
13027
13028         * lib/lchmod.h: New file.
13029         * lib/mkdir-p.c: Include lchmod.h, lchown.h.
13030         (make_dir_parents): Use lchown rather than chown, and
13031         lchmod rather than chmod.
13032
13033         * lib/mountlist.c (ME_DUMMY): "none" and "proc" file systems are
13034         dummies too.  Problem with "none" reported by Bob Proulx.  Problem with
13035         "proc" reported by n0dalus.
13036
13037         * lib/mountlist.c: Include <limits.h>.
13038         (dev_from_mount_options)
13039         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]:
13040         New function.  It no longer assumes "dev=" has the System V meaning
13041         on Linux (since it doesn't).  It also parses "dev=" more carefully.
13042         (read_file_system_list)
13043         [defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2]: Use it.
13044         MOUNTED_GETMNTENT2 is new here; the code didn't used to look for
13045         dev= in that case.
13046
13047         * lib/posixtm.h (PDS_PRE_2000): New macro.
13048         * lib/posixtm.c (year): Arg is now syntax_bits rather than
13049         allow_century.  All usages changed.  Reject dates outside the range
13050         1969-1999 if PDS_PRE_2000 is used.
13051
13052 2006-01-09  Paul Eggert  <eggert@cs.ucla.edu>
13053
13054         Sync from coreutils.
13055         * doc/getdate.texi (General date syntax): Invalid dates are rejected.
13056         (Time of day items): Mention the possibility of leap seconds.
13057         Problem reported by Dr. David Alan Gilbert.
13058
13059 2006-01-09  Jim Meyering  <jim@meyering.net>
13060
13061         Sync from coreutils.
13062
13063         * lib/version-etc.c (COPYRIGHT_YEAR): Update to 2006.
13064
13065         * lib/chdir-safer.h, lib/chdir-safer.c: New files.
13066
13067         * lib/modechange.c (mode_compile): Reject an invalid mode string
13068         that starts with an octal digit.  From Andreas Gruenbacher.
13069
13070         * lib/openat.c: Include "fcntl--.h" and "unistd--.h", to map open
13071         and dup to open_safer and dup_safer, respectively.
13072         (openat_permissive): Fix typo in comment.
13073
13074         * lib/openat.c: Don't include <stdlib.h>, <unistd.h>, <fcntl.h>,
13075         "gettext.h"; either no longer needed or are guaranteed by openat.h.
13076         (_): Remove; no longer needed.
13077         (openat): Renamed from rpl_openat; no need for rpl_openat
13078         since openat.h renames openat for us.
13079         Replace most of the body with a call to openat_permissive,
13080         to avoid duplicate code.
13081         Port to (probably hypothetical) environments were mode_t is
13082         wider than int.
13083         (openat_permissive): Require mode arg, so that we can check
13084         types better.  Put it just after flags.  Change cwd failure
13085         indicator from pointer-to-bool to pointer-to-errno-value.
13086         All callers changed.
13087         Invoke openat_save_fail and/or openat_restore_fail if
13088         cwd_errno is null, so that openat can call us.
13089         (openat_permissive, fdopendir, fstatat, unlinkat):
13090         Simplify errno handling to avoid some duplicate code,
13091         as it's OK to set errno on success.
13092         * lib/openat.h: Revamp code so that function macros depend on
13093         __OPENAT_PREFIX only, not also on AT_FDCWD.
13094         (openat_ro): Remove.  Caller changed to use openat_permissive.
13095         (openat_permissive): Now a macro, if not a function.
13096         (openat_restore_fail, openat_save_fail): Now always functions,
13097         since mkdirat needs them even if __OPENAT_PREFIX is defined.
13098
13099         * lib/openat-priv.h: New file, defining macros used by mkdirat.c
13100         and openat.c.
13101         * lib/mkdirat.c: Include openat-priv.h.
13102         Remove definitions of macros defined therein.
13103         * lib/openat.c: Likewise.
13104
13105         * lib/mkdirat.c (mkdirat): New file and function.
13106         * lib/openat.h (mkdirat): Declare.
13107
13108         * lib/openat.c (fdopendir): Don't change errno when returning non-NULL.
13109
13110         * lib/openat.h (openat_permissive): Declare.
13111         (openat_ro): Define.
13112
13113         * lib/openat.c (EXPECTED_ERRNO): New macro.
13114         (openat_permissive): New function -- used in remove.c rewrite.
13115         (all functions): Set errno just before returning, only if there
13116         was an actual failure.
13117         Use EXPECTED_ERRNO rather than comparing against only ENOTDIR.
13118
13119         Emulate openat-family functions using Linux's procfs, if possible.
13120         Idea and some code based on Ulrich Drepper's glibc changes.
13121
13122         * lib/openat.c: (BUILD_PROC_NAME): New macro.
13123         Include <stdio.h>, <string.h>, "alloca.h" and "intprops.h".
13124         (rpl_openat): Emulate by trying to open /proc/self/fd/%d/%s,
13125         before falling back on save_cwd and restore_cwd.
13126         (fdopendir, fstatat, unlinkat): Likewise.
13127
13128         * lib/openat.c (fstatat, unlinkat): Perform the syscall directly,
13129         skipping the save_cwd...restore_cwd overhead, if FILE is absolute.
13130
13131         * lib/openat.c (rpl_openat): Use the promoted type (int), not mode_t,
13132         as second argument to va_arg.  Otherwise, some versions of gcc
13133         warn that `if this code is reached, the program will abort'.
13134
13135 2006-01-09  Jim Meyering  <jim@meyering.net>
13136
13137         Sync from coreutils.
13138         * m4/openat.m4 (gl_FUNC_OPENAT): Require and compile mkdirat.c.
13139         Require openat-priv.h.
13140
13141 2006-01-09  Bruno Haible  <bruno@clisp.org>
13142
13143         * modules/strnlen (Include): Use strnlen.h.
13144
13145 2006-01-09  Bruno Haible  <bruno@clisp.org>
13146
13147         * m4/stdint.m4 (gl_STDINT_H): Also test for <sys/bitypes.h>.
13148
13149 2006-01-09  Bruno Haible  <bruno@clisp.org>
13150
13151         * lib/sysexit_.h (EX_OK): New macro.
13152         Suggested by Martin Lambers <marlam@marlam.de>.
13153
13154 2006-01-09  Bruno Haible  <bruno@clisp.org>
13155
13156         * lib/stdint_.h: On Linux libc4 and libc5, include <sys/bitypes.h> and
13157         don't define _STDINT_H_NEED_SIGNED_INT_TYPES.
13158
13159 2006-01-09  Bruno Haible  <bruno@clisp.org>
13160
13161         * lib/stdint_.h (SIZE_MAX): Write the value without involving negative
13162         numbers.
13163
13164 2006-01-09  Bruno Haible  <bruno@clisp.org>
13165
13166         * lib/javacomp.sh.in: Move to ../build-aux/javacomp.sh.in.
13167         * lib/javaexec.sh.in: Move to ../build-aux/javaexec.sh.in.
13168         * lib/csharpcomp.sh.in: Move to ../build-aux/csharpcomp.sh.in.
13169         * lib/csharpexec.sh.in: Move to ../build-aux/csharpexec.sh.in.
13170
13171 2006-01-09  Bruno Haible  <bruno@clisp.org>
13172
13173         * build-aux/javacomp.sh.in: New file, moved from lib/.
13174         * modules/javacomp-script (Files): Update.
13175         (configure.ac): Add AC_CONFIG_FILES invocation.
13176         (EXTRA_DIST): Remove variable.
13177
13178         * build-aux/javaexec.sh.in: New file, moved from lib/.
13179         * modules/javaexec (Files): Update.
13180         (configure.ac): Add AC_CONFIG_FILES invocation.
13181         (EXTRA_DIST): Remove javaexec.sh.in.
13182
13183         * build-aux/csharpcomp.sh.in: New file, moved from lib/.
13184         * modules/csharpcomp-script (Files): Update.
13185         (configure.ac): Add AC_CONFIG_FILES invocation.
13186         (EXTRA_DIST): Remove variable.
13187
13188         * build-aux/csharpexec.sh.in: New file, moved from lib/.
13189         * modules/csharpexec (Files): Update.
13190         (configure.ac): Add AC_CONFIG_FILES invocation.
13191         (EXTRA_DIST): Remove csharpexec.sh.in.
13192
13193 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13194
13195         Sync from coreutils.
13196
13197         Add POSIX ACL support
13198         * lib/acl.h (copy_acl, set_acl): Add declarations.
13199         * lib/acl.c (acl_entries): Add fallback implementation for POSIX ACL
13200         systems other than Linux.
13201         (chmod_or_fchmod): New function: use fchmod when possible,
13202         and chmod otherwise.
13203         (file_has_acl): Add a POSIX ACL implementation, with a
13204         Linux-specific subcase.
13205         (copy_acl): Add: copy an acl and S_ISUID, S_ISGID, and
13206         S_ISVTX from one file to another.  Fall back to fchmod/chmod when
13207         acls are unsupported.
13208         (set_acl): Add: set a file's acl and S_ISUID, S_ISGID, and
13209         S_ISVTX to a defined value.  Fall back to fchmod/chmod when acls
13210         are unsupported.
13211
13212 2006-01-09  Andreas Gruenbacher  <agruen@suse.de>
13213
13214         Sync from coreutils.
13215         * m4/acl.m4 (AC_FUNC_ACL): Add POSIX ACL and Linux-specific acl tests.
13216
13217 2006-01-07  Bruno Haible  <bruno@clisp.org>
13218
13219         * gnulib-tool (func_import): Add an AC_PROG_RANLIB dependency to
13220         gl_EARLY.
13221
13222 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13223
13224         * lib/strftime.c (tzname): Don't declare if it is already #defined.
13225         Problem reported for Mingw by Mark Junker.
13226
13227 2006-01-04  Paul Eggert  <eggert@cs.ucla.edu>
13228
13229         * README: Gnulib normally doesn't generate a tarball.
13230
13231 2006-01-03  Paul Eggert  <eggert@cs.ucla.edu>
13232
13233         * lib/xtime.h (xtime_make, xtime_nonnegative_nsec, xtime_nsec): Use
13234         long int, not int, for nanosecond counts, so that people who are
13235         used to POSIX struct timespec won't be surprised.  Reported by Jim
13236         Meyering.
13237
13238 2005-12-28  Bruno Haible  <bruno@clisp.org>
13239
13240         * build-aux/config.rpath: Update from GNU gettext.
13241
13242 2005-12-16  Jim Meyering  <jim@meyering.net>
13243
13244         * modules/fprintftime: New module.
13245         * MODULES.html.sh (Date and time <time.h>): Add fprintftime.
13246
13247 2005-12-16  Jim Meyering  <jim@meyering.net>
13248
13249         * m4/fprintftime.m4: New file.
13250
13251 2005-12-16  Jim Meyering  <jim@meyering.net>
13252
13253         * lib/fprintftime.c, lib/fprintftime.h: New files.
13254
13255 2005-12-15  Simon Josefsson  <jas@extundo.com>
13256
13257         * modules/socklen (configure.ac): Fix M4 macro name, to align with
13258         new m4/socklen.m4.
13259
13260 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13261
13262         * m4/argp.m4: Define HAVE_DECL_PROGRAM_INVOCATION_NAME and
13263         HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME
13264
13265 2005-12-10  Sergey Poznyakoff  <gray@gnu.org.ua>
13266
13267         * lib/argp-fmtstream.c (__argp_fmtstream_update): Fix coredump
13268         * lib/argp-help.c (fill_in_uparams): Check if the constructed
13269         struct uparams is valid. Fall back to the default values if it is
13270         not.
13271
13272 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13273
13274         * modules/argp (Files): Add argp-pin.c
13275         (Depends-on): dirname
13276         (lib_SOURCES): Add argp-pin.c
13277
13278 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13279
13280         * m4/argp.m4:  Check if program_invocation_name and
13281         program_invocation_short_name are declared and define appropriate
13282         macros if they are not.
13283
13284 2005-12-09  Sergey Poznyakoff  <gray@gnu.org.ua>
13285
13286         * lib/argp-help.c (__argp_base_name): New function
13287         (__argp_short_program_name): Rewrite using __argp_base_name
13288         * lib/argp-namefrob.h: Define program_invocation_name and
13289         program_invocation_short_name if requested
13290         (__argp_base_name): Add prototype
13291         * lib/argp-parse.c (argp_def): Use gettext wrappers
13292         (argp_default_parser): Use __argp_base_name
13293         * lib/argp-pin.c: New file. Defines program_invocation_name and
13294         program_invocation_short_name on systems that lack them.
13295
13296 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13297
13298         * m4/stat-time.m4 (gl_STAT_TIME): Add check for
13299         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13300         porting problem reported by Georg Schwarz in
13301         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13302
13303 2005-12-07  Paul Eggert  <eggert@cs.ucla.edu>
13304
13305         * lib/stat-time.h (STATE_TIMESPEC, STAT_TIMESPEC_NS): Add check for
13306         TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC, to fix IRIX 5.3
13307         porting problem reported by Georg Schwarz in
13308         <http://lists.gnu.org/archive/html/bug-coreutils/2005-12/msg00083.html>.
13309
13310 2005-12-05  Bruno Haible  <bruno@clisp.org>
13311
13312         * lib/csharpcomp.sh.in (options_csc): For -l option, add a .dll suffix.
13313         * lib/csharpcomp.c (compile_csharp_using_sscli): Likewise.
13314         Reported by Mark Junker <mjscod@gmx.de>.
13315
13316 2005-12-02  Paul Eggert  <eggert@cs.ucla.edu>
13317
13318         * m4/socklen.m4 (gl_TYPE_SOCKLEN_T): Renamed from gl_SOCKLEN_T.
13319         Use implementation from Albert Chin, with some
13320         comments/corrections by Stepan Kasal and myself.
13321
13322 2005-12-02  Bruno Haible  <bruno@clisp.org>
13323
13324         * gnulib-tool (func_import): Accept GPLed build tool modules when
13325         --lgpl is given.
13326         * modules/csharpcomp-script: New file.
13327         * modules/csharpcomp: Depend on it.
13328         * modules/javacomp-script: New file.
13329         * modules/javacomp: Depend on it.
13330         Suggested by Simon Josefsson.
13331
13332 2005-12-01  Paul Eggert  <eggert@cs.ucla.edu>
13333
13334         * m4/regex.m4 (gl_REGEX): Check whether off_t can be used in a switch
13335         statement, to work around an HP-UX 10.20 compiler bug reported by
13336         Peter O'Gorman.
13337
13338 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13339
13340         * modules/savedir (Depends-on): Add openat.
13341
13342 2005-11-29  Paul Eggert  <eggert@cs.ucla.edu>
13343
13344         * lib/stdint_.h (intmax_t) [defined intmax_t]: Do not declare.
13345         (uintmax_t) [defined uintmax_t]: Do not declare.
13346         (SIZE_MAX) [defined SIZE_MAX]: Do not define.
13347         This works around a problem if intmax_t.m4 and/or uintmax_t.m4
13348         and/or size_max.m4 are also used.  Problem reported by Mark D. Baushke.
13349         (SIZE_MAX): Define to ((size_t) -1), not (~(size_t)0), for the
13350         sake of portability to weird hosts that C allows (though we don't
13351         know of any practical examples).
13352
13353         * lib/savedir.h (fdsavedir): New decl.
13354         * lib/savedir.c (fdsavedir, savedirstream): New functions; the latter
13355         contains most of the former guts of savedir.
13356         (savedir): Use savedirstream.
13357         Include "openat.h".
13358
13359 2005-11-25  Paul Eggert  <eggert@cs.ucla.edu>
13360
13361         * modules/obstack (Files): Add m4/ulonglong.m4.
13362         Problem reported by Davide Angelocola.
13363
13364 2005-11-15  Paul Eggert  <eggert@cs.ucla.edu>
13365
13366         * lib/xstrtod.c: Don't bother with #pragma STDC FENV_ACCESS ON, as
13367         coreutils no longer futzes with rounding modes.
13368
13369 2005-11-14  Jim Meyering  <jim@meyering.net>
13370
13371         * lib/mkstemp-safer.c: Include <config.h>, required for possible
13372         replacement of mkstemp.
13373
13374 2005-11-10  Simon Josefsson  <jas@extundo.com>
13375
13376         * lib/readline.c: Remove EOL.
13377
13378 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13379
13380         * modules/gethrxtime (Depends-on): Add gettime.
13381
13382 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13383
13384         * m4/gethrxtime.m4 (gl_PREREQ_GETHRXTIME): Don't require AC_HEADER_TIME
13385         or gettimeofday; no longer needed.
13386
13387 2005-11-10  Paul Eggert  <eggert@cs.ucla.edu>
13388
13389         * lib/gethrxtime.c: Include "timespec.h" rather than the sys/time /
13390         time business.
13391         (gethrxtime) [! (HAVE_NANOUPTIME
13392         || (defined CLOCK_MONOTONIC && HAVE_CLOCK_GETTIME)
13393         || HAVE_MICROUPTIME)]: Fall back on gettime rather than rolling
13394         our own approximation.
13395
13396 2005-11-08  Eric Blake  <ebb9@byu.net>
13397
13398         * lib/inet_ntop.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13399
13400 2005-11-08  Eric Blake  <ebb9@byu.net>
13401
13402         * lib/getaddrinfo.h: Use #if !, not #ifndef, for AC_CHECK_DECLS.
13403
13404 2005-11-04  Bruno Haible  <bruno@clisp.org>
13405
13406         * gnulib-tool: Implement --update mode.
13407
13408 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
13409
13410         Fix porting problem reported by Theodoros V. Kalamatianos.
13411         * lib/utimens.c (futimens) [HAVE_WORKING_UTIMES && HAVE_FUTIMES]:
13412         Don't assume that futimes failing means we must fail.
13413
13414 2005-10-30  Paul Eggert  <eggert@cs.ucla.edu>
13415
13416         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Revamp wording and local
13417         variables to suggest the intended function of the PATH_MAX check.
13418
13419 2005-10-30  Kean Johnston  <jkj@sco.com>
13420
13421         Trivial changes to support SCO systems.
13422         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Check for MAXPATHLEN as well
13423         as PATH_MAX.
13424         * m4/fpending.m4 (gl_FUNC_FPENDING): Correct check for SCO systems,
13425         where __ptr is null when no I/O is pending.
13426
13427 2005-10-29  Paul Eggert  <eggert@cs.ucla.edu>
13428
13429         * lib/getcwd.c (__getcwd): Don't assume that system calls after readdir
13430         leave errno alone.  Problem reported by Dmitry V. Levin.
13431
13432 2005-10-28  Simon Josefsson  <jas@extundo.com>
13433
13434         * tests/test-gc-md4.c, tests/test-gc-md5.c, tests/test-gc-sha1.c:
13435         Test more.
13436
13437         * tests/test-gc-md2.c, tests/test-md2.c: New files.
13438
13439         * modules/md2, modules/md2-tests: New files.
13440
13441 2005-10-28  Simon Josefsson  <jas@extundo.com>
13442
13443         * m4/inet_ntop.m4: More tests.
13444
13445         * m4/gc-md2.m4, md2.m4: New file.
13446
13447 2005-10-28  Simon Josefsson  <jas@extundo.com>
13448
13449         * lib/inet_ntop.h, inet_ntop.c: Make it work under mingw32: Add
13450         "restrict" keywords, as per POSIX.  Protect the function
13451         declaration around HAVE_DECL_INET_NTOP rather than HAVE_INET_NTOP.
13452         Don't use K&R prototypes.  Check the sprintf return values.
13453         Re-define EAFNOSUPPORT if not present.  Indent.
13454
13455         * lib/md5.h, md5.c: Simplify buffer handling visavi alignment,
13456         suggested by Bruno Haible <bruno@clisp.org>.
13457
13458         * lib/gc-gnulib.c, gc-libgcrypt.c: Check calloc return value.
13459
13460         * lib/gc.h: Add MD2 and RMD160 length defines.  Add prototypes.
13461
13462         * lib/gc-libgcrypt.c: Add MD2 (which is not available through
13463         libgcrypt).
13464
13465         * lib/gc-gnulib.c: Add MD2.  Implement gc_hash_* API.
13466
13467         * lib/md2.h, lib/md2.c: New files.
13468
13469 2005-10-28  Paul Eggert  <eggert@cs.ucla.edu>
13470
13471         * lib/savedir.c (savedir): Don't assume that xrealloc etc. leave
13472         errno alone.  Problem reported by Frederic Jolliton.
13473
13474 2005-10-27  Paul Eggert  <eggert@cs.ucla.edu>
13475
13476         * modules/verify (License): Change from GPL to LGPL.  This is a
13477         tiny module and there are apparently near-equivalents that are
13478         under the BSD license.
13479
13480 2005-10-24  Simon Josefsson  <jas@extundo.com>
13481
13482         * modules/sha1: Relicense to LGPL.
13483
13484 2005-10-24  Simon Josefsson  <jas@extundo.com>
13485
13486         * lib/md4.h: Shrink buffer size, now that we changed the type.
13487
13488 2005-10-23  Simon Josefsson  <jas@extundo.com>
13489
13490         * gnulib-tool (func_import): Fix --tests-base.
13491
13492 2005-10-22  Simon Josefsson  <jas@extundo.com>
13493
13494         * modules/arcfour (Depends-on): Need stdint.
13495
13496 2005-10-22  Simon Josefsson  <jas@extundo.com>
13497
13498         * m4/gc.m4: Don't be fooled by --disable-*random-device parameters,
13499         suggested by Bruno Haible <bruno@clisp.org>.  Fix error messages.
13500
13501 2005-10-22  Simon Josefsson  <jas@extundo.com>
13502
13503         * lib/md4.h, md4.c: Simplify buffer handling visavi alignment,
13504         suggested by Bruno Haible <bruno@clisp.org>.
13505
13506 2005-10-22  Simon Josefsson  <jas@extundo.com>
13507
13508         * lib/crc.h: Include stddef.h, for size_t.
13509
13510 2005-10-22  Simon Josefsson  <jas@extundo.com>
13511
13512         * lib/arcfour.h, arcfour.c: Use fixed size indices in the
13513         arcfour_context struct (simplify test vector testing in GNU
13514         Shishi).
13515
13516 2005-10-21  Simon Josefsson  <jas@extundo.com>
13517
13518         * modules/des, modules/des-tests: New files.
13519
13520         * modules/gc-des, modules/gc-des-tests: New files.
13521
13522         * tests/test-des.c, tests/test-gc-des.c: New file.
13523
13524 2005-10-21  Simon Josefsson  <jas@extundo.com>
13525
13526         * modules/arctwo, modules/arctwo-tests: New files.
13527
13528         * tests/test-arctwo.c: New file.
13529
13530         * modules/gc-arctwo, modules/gc-arctwo-tests: New files.
13531
13532         * tests/test-gc-arctwo.c: New file.
13533
13534 2005-10-21  Simon Josefsson  <jas@extundo.com>
13535
13536         * m4/gc.m4: Don't use libgcrypt if gcrypt.h isn't found, suggested by
13537         Bruno Haible <bruno@clisp.org>.
13538
13539         * m4/gc-des.m4: New file.
13540
13541 2005-10-21  Simon Josefsson  <jas@extundo.com>
13542
13543         * m4/arctwo.m4: New file.
13544
13545         * m4/gc-arctwo.m4: New file.
13546
13547 2005-10-21  Simon Josefsson  <jas@extundo.com>
13548
13549         * lib/rijndael-api-fst.c: Fix bugs in CBC mode for more than one
13550         block.
13551
13552 2005-10-21  Simon Josefsson  <jas@extundo.com>
13553
13554         * lib/hmac-md5.c (hmac_md5): Add comments, suggested by Bruno Haible
13555         <bruno@clisp.org>.
13556
13557         * lib/hmac-sha1.c (hmac_sha1): Likewise.
13558
13559         * lib/crc.c (crc32_update): Actually use crc parameter, suggested by
13560         Bruno Haible <bruno@clisp.org>.
13561
13562         * lib/crc.h: Include stdint.h directly, suggested by Bruno Haible
13563         <bruno@clisp.org>.
13564
13565 2005-10-21  Simon Josefsson  <jas@extundo.com>
13566
13567         * lib/gc-libgcrypt.c (gc_cipher_open): Handle ECB.
13568
13569 2005-10-21  Simon Josefsson  <jas@extundo.com>
13570
13571         * lib/gc-gnulib.c: Support ARCTWO in CBC mode.
13572
13573 2005-10-21  Simon Josefsson  <jas@extundo.com>
13574
13575         * lib/des.h, lib/des.c: New files.
13576
13577         * lib/gc-gnulib.c: Support DES.c
13578
13579 2005-10-21  Simon Josefsson  <jas@extundo.com>
13580
13581         * lib/arctwo.h, lib/arctwo.c: New files.
13582
13583         * lib/gc-gnulib.c: Support ARCTWO.
13584
13585 2005-10-21  Simon Josefsson  <jas@extundo.com>
13586
13587         * lib/arctwo.h (arctwo_setkey): Protect variable in CPP macro,
13588         suggested by Ralf Wildenhues <Ralf.Wildenhues@gmx.de>.
13589
13590 2005-10-21  Simon Josefsson  <jas@extundo.com>
13591
13592         * gnulib-tool (func_import, func_create_testdir): Define automake
13593         conditional GL_COND_LIBTOOL if libtool is used (to be used by modules
13594         Makefile.am snippet),
13595         suggested by Bruno Haible <bruno@clisp.org>.
13596
13597         * modules/gc (Makefile.am): Use it.
13598
13599 2005-10-21  Bruno Haible  <bruno@clisp.org>
13600
13601         * gnulib-tool (func_import, func_create_testdir): Add quoting to last
13602         patch.
13603
13604 2005-10-19  Simon Josefsson  <jas@extundo.com>
13605
13606         * tests/test-gc-rijndael.c: New file.
13607
13608         * modules/gc-rijndael, modules/gc-rijndael-test: New files.
13609
13610 2005-10-19  Simon Josefsson  <jas@extundo.com>
13611
13612         * tests/test-gc-md4.c, tests/test-gc-md5.c: Test gc_hash_buffer
13613         interface too.
13614
13615 2005-10-19  Simon Josefsson  <jas@extundo.com>
13616
13617         * tests/test-gc-arcfour.c: New file.
13618
13619         * modules/gc-arcfour, modules/gc-arcfour-tests: New files.
13620
13621 2005-10-19  Simon Josefsson  <jas@extundo.com>
13622
13623         * modules/gc-md4, modules/gc-md4-tests: New file.
13624
13625         * tests/test-gc-md4.c: New file.
13626
13627 2005-10-19  Simon Josefsson  <jas@extundo.com>
13628
13629         * m4/gc-md4.m4: New file.
13630
13631 2005-10-19  Simon Josefsson  <jas@extundo.com>
13632
13633         * m4/gc-hmac-md5.m4, gc-hmac-sha1.m4, gc-md4.m4,
13634         gc-md5.m4, gc-sha1.m4: Fix typo, suggested by Stepan Kasal
13635         <kasal@ucw.cz>.
13636
13637 2005-10-19  Simon Josefsson  <jas@extundo.com>
13638
13639         * m4/gc-arcfour.m4: New file.
13640
13641         * m4/gc-rijndael.m4: New file.
13642
13643 2005-10-19  Simon Josefsson  <jas@extundo.com>
13644
13645         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support MD4.
13646
13647 2005-10-19  Simon Josefsson  <jas@extundo.com>
13648
13649         * lib/gc-gnulib.c: Support ARCFOUR.
13650
13651 2005-10-19  Simon Josefsson  <jas@extundo.com>
13652
13653         * lib/gc-gnulib.c: Implement gc_cipher_* API, currently only with AES
13654         support.
13655
13656         * lib/gc.h: Add ECB enum type.
13657
13658         * lib/hmac-md5.c, hmac-sha1.c: Include memxor.h.
13659
13660 2005-10-18  Simon Josefsson  <jas@extundo.com>
13661
13662         * tests/test-md5.c: New file.
13663
13664         * modules/md5-tests: New file.
13665
13666 2005-10-18  Simon Josefsson  <jas@extundo.com>
13667
13668         * tests/test-md4.c: New file.
13669
13670         * modules/md4, modules/md4-tests: New files.
13671
13672 2005-10-18  Simon Josefsson  <jas@extundo.com>
13673
13674         * m4/md4.m4: New file.
13675
13676 2005-10-18  Simon Josefsson  <jas@extundo.com>
13677
13678         * lib/md4.h, lib/md4.c: New files, based on md5.?.
13679
13680 2005-10-17  Stepan Kasal  <kasal@ucw.cz>
13681
13682         * gnulib-tool (func_create_testdir): Omit the second check whether
13683         BUILT_SOURCES in nonempty.
13684
13685 2005-10-17  Simon Josefsson  <jas@extundo.com>
13686
13687         * tests/test-rijndael.c: New file.
13688
13689 2005-10-17  Simon Josefsson  <jas@extundo.com>
13690
13691         * modules/sha1: Depend on stdint instead of md5.
13692
13693         * modules/md5: Depend on stdint, remove uint32_t.
13694
13695 2005-10-17  Simon Josefsson  <jas@extundo.com>
13696
13697         * modules/gc-sha1-tests: New file.
13698
13699         * tests/test-gc-sha1.c: New file.
13700
13701 2005-10-17  Simon Josefsson  <jas@extundo.com>
13702
13703         * m4/md5.m4: Remove call to uint32_t.m4.
13704
13705 2005-10-17  Simon Josefsson  <jas@extundo.com>
13706
13707         * lib/sha1.c: Use uint32_t instead of md5_uint32.t
13708
13709         * lib/sha1.h: Use stdint.h and uint32_t instead of md5_uint32 from
13710         md5.h.
13711
13712         * lib/md5.c: Use uin32_t.  Fix non-gcc UNALIGNED_P macro.
13713
13714         * lib/md5.h: Use stdint.h and uint32_t.  Doc fix.
13715
13716 2005-10-17  Simon Josefsson  <jas@extundo.com>
13717
13718         * lib/gc.h, gc-libgcrypt.c: Add more hash types/functions.
13719
13720 2005-10-17  Simon Josefsson  <jas@extundo.com>
13721
13722         * lib/gc.h, gc-libgcrypt.c: Add ciphers.
13723
13724 2005-10-17  Simon Josefsson  <jas@extundo.com>
13725
13726         * lib/gc-libgcrypt.c (gc_hmac_sha1): Fix assert.
13727
13728         * lib/gc.h (gc_nonce, gc_pseudo_random, gc_random): Add prototypes.
13729
13730 2005-10-17  Bruno Haible  <bruno@clisp.org>
13731
13732         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Change the return statement so
13733         that it can also be used in a test.
13734
13735 2005-10-16  Bruno Haible  <bruno@clisp.org>
13736
13737         * gnulib-tool (func_emit_tests_Makefile_am): Also define
13738         TESTS_ENVIRONMENT, so that individual tests can augment it.
13739
13740         * gnulib-tool (func_create_testdir): Use an intermediate target for
13741         building $(BUILT_SOURCES). Needed because BUILT_SOURCES can contain
13742         macros, like $(ALLOCA_H), which cannot be passed through the command
13743         line.
13744
13745 2005-10-15  Simon Josefsson  <jas@extundo.com>
13746
13747         * modules/rijndael-tests: New file.
13748
13749         * modules/rijndael: New file.
13750
13751 2005-10-15  Simon Josefsson  <jas@extundo.com>
13752
13753         * m4/rijndael.m4: New file.
13754
13755 2005-10-15  Simon Josefsson  <jas@extundo.com>
13756
13757         * lib/rijndael-api-fst.h, lib/rijndael-api-fst.c: New files.
13758
13759         * lib/rijndael-alg-fst.h, lib/rijndael-alg-fst.c: New files.
13760
13761 2005-10-14  Simon Josefsson  <jas@extundo.com>
13762
13763         * tests/test-arcfour.c: New file.
13764
13765         * modules/arcfour, modules/arcfour-tests: New files.
13766
13767 2005-10-14  Simon Josefsson  <jas@extundo.com>
13768
13769         * m4/arcfour.m4: New file.
13770
13771 2005-10-14  Simon Josefsson  <jas@extundo.com>
13772
13773         * lib/arcfour.h, lib/arcfour.c: New files.
13774
13775 2005-10-14  Roland McGrath  <roland@redhat.com>
13776
13777         Import from libc.  [BZ #1331]
13778         * lib/obstack.h [!__STDC__] (obstack_int_grow_fast): Fix misnamed
13779         macro argument.
13780         Reported by Matej Vela <vela@debian.org>.
13781
13782 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13783
13784         * lib/obstack.c [defined _LIBC && defined USE_IN_LIBIO]: Don't
13785         include <wchar.h>; no longer needed.
13786
13787 2005-10-14  Paul Eggert  <eggert@cs.ucla.edu>
13788
13789         * config/srclist.txt: Add glibc bug 321 for obstack.c, obstack.h.
13790
13791 2005-10-14  Jakub Jelinek  <jakub@redhat.com>
13792         and  Ulrich Drepper  <drepper@redhat.com>
13793
13794         Import from libc.
13795         * lib/obstack.c (print_and_abort) [defined _LIBC]: Use __fxprintf
13796         instead of inline stream orientation test and two separate
13797         function calls.  Pay no attention to USE_IN_LIBIO.
13798
13799 2005-10-13  Simon Josefsson  <jas@extundo.com>
13800
13801         * modules/gc-hmac-md5-tests: New file.
13802
13803         * tests/test-gc-hmac-sha1.c: New file.
13804
13805         * tests/test-gc.c (main): Remove MD5 and HMAC-MD5 tests.
13806
13807         * modules/gc-hmac-md5-tests: New file.
13808
13809         * tests/test-gc-md5.c: New file.
13810
13811         * modules/gc-md5-tests: New file.
13812
13813 2005-10-13  Simon Josefsson  <jas@extundo.com>
13814
13815         * lib/gc-pbkdf2-sha1.c (gc_pbkdf2_sha1): Optimize CEIL computation.
13816         Move memory allocation outside of loop.
13817
13818 2005-10-13  Paul Eggert  <eggert@cs.ucla.edu>
13819
13820         * lib/mkdir-p.c (make_dir_parents): Don't report an error if an
13821         intermediate directory is in a read-only file system.  Problem
13822         reported by Eric Blake.
13823
13824 2005-10-13  Oskar Liljeblad  <oskar@osk.mine.nu>
13825
13826         * modules/human (Depends-on): Depend on xstrtoumax, not xstrtol.
13827
13828 2005-10-12  Simon Josefsson  <jas@extundo.com>
13829
13830         * tests/test-hmac-sha1.c: New file.
13831
13832         * modules/hmac-sha1-tests: New file.
13833
13834         * modules/hmac-sha1: New file.
13835
13836 2005-10-12  Simon Josefsson  <jas@extundo.com>
13837
13838         * modules/gc-sha1: New file.
13839
13840 2005-10-12  Simon Josefsson  <jas@extundo.com>
13841
13842         * modules/gc-pbkdf2-sha1, modules/gc-pbkdf2-sha1-tests: New files.
13843
13844         * tests/test-gc-pbkdf2-sha1.c: New file.
13845
13846 2005-10-12  Simon Josefsson  <jas@extundo.com>
13847
13848         * modules/gc-md5, modules/gc-hmac-md5: New files.
13849
13850         * modules/gc (Files): Remove md5, memxor and hmac files.
13851
13852 2005-10-12  Simon Josefsson  <jas@extundo.com>
13853
13854         * m4/gc-pbkdf2-sha1.m4: New file.
13855
13856         * m4/gc-hmac-sha1.m4: New file.
13857
13858         * m4/gc-sha1: New file.
13859
13860         * m4/hmac-sha1.m4: New file.
13861
13862 2005-10-12  Simon Josefsson  <jas@extundo.com>
13863
13864         * m4/gc-md5.m4, m4/gc-hmac-md5.m4: New files.
13865
13866         * m4/gc.m4: Don't call gl_MD5, gl_MEMXOR or gl_HMAC_MD5.
13867
13868 2005-10-12  Simon Josefsson  <jas@extundo.com>
13869
13870         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Use Gc_rc for return types,
13871         suggested by Bruno Haible <bruno@clisp.org>.
13872
13873 2005-10-12  Simon Josefsson  <jas@extundo.com>
13874
13875         * lib/gc.h, gc-gnulib.c, gc-libgcrypt.c: Support SHA-1.
13876
13877 2005-10-12  Simon Josefsson  <jas@extundo.com>
13878
13879         * lib/gc-pbkdf2-sha1.c: New file.
13880
13881         * lib/gc.h: Add gc_pbkdf2_sha1 prototype.
13882
13883 2005-10-12  Simon Josefsson  <jas@extundo.com>
13884
13885         * lib/gc-libgcrypt.c (gc_hmac_sha1): New function.
13886
13887         * lib/gc-gnulib.c (gc_hmac_sha1): New function.
13888
13889 2005-10-12  Simon Josefsson  <jas@extundo.com>
13890
13891         * lib/gc-gnulib.c: Condition MD5 and HMAC-MD5 use on GC_USE_MD5 and
13892         GC_USE_HMAC_MD5, respectively.
13893
13894         * lib/gc-libgcrypt.c (gc_md5): Fix assert call.
13895         (gc_md5): Fix typo.
13896
13897         * lib/gc.h (gc_hash_buffer): Use gc_hash in prototype.
13898
13899         * lib/gc-libgcrypt.c (gc_hash_buffer): Ditto.
13900
13901         * lib/gc-gnulib.c (gc_hash_buffer): Ditto.
13902
13903 2005-10-12  Bruno Haible  <bruno@clisp.org>
13904
13905         * m4/stdbool.m4 (gl_STDBOOL_H): Define as an alias of AM_STDBOOL_H.
13906         Reported by Stepan Kasal <kasal@ucw.cz>.
13907
13908 2005-10-11  Simon Josefsson  <jas@extundo.com>
13909
13910         * tests/test-crc.c: New file.
13911
13912         * modules/crc, modules/crc-tests: New files.
13913
13914 2005-10-11  Simon Josefsson  <jas@extundo.com>
13915
13916         * m4/crc.m4: New file.
13917
13918 2005-10-11  Simon Josefsson  <jas@extundo.com>
13919
13920         * lib/gc.h: Add gc_hash and gc_hash_buffer.
13921
13922         * lib/gc-gnulib.c (gc_hash_buffer): Add.  Reorder #include's.
13923
13924         * lib/gc-libgcrypt.c (gc_hash_buffer): Add.
13925
13926 2005-10-11  Simon Josefsson  <jas@extundo.com>
13927
13928         * lib/crc.h, lib/crc.c: New files.
13929
13930         * lib/gc.h (gc_hash_buffer): Add doc.
13931
13932 2005-10-11  Bruno Haible  <bruno@clisp.org>
13933
13934         * modules/c-strcasestr: New file.
13935         * MODULES.html.sh (String handling <string.h>): Add c-strcasestr.
13936
13937 2005-10-11  Bruno Haible  <bruno@clisp.org>
13938
13939         * modules/c-strcase: New file.
13940         * MODULES.html.sh (String handling <string.h>): Add c-strcase.
13941
13942 2005-10-11  Bruno Haible  <bruno@clisp.org>
13943
13944         * lib/strcasecmp.c: Include limits.h.
13945         (strcasecmp): Avoid integer overflow on exotic platforms.
13946         * lib/strncasecmp.c: Include limits.h.
13947         (strncasecmp): Avoid integer overflow on exotic platforms.
13948         Reported by Paul Eggert.
13949
13950 2005-10-11  Bruno Haible  <bruno@clisp.org>
13951
13952         * lib/c-strcasestr.h: New file, from GNU gettext.
13953         * lib/c-strcasestr.c: New file, from GNU gettext.
13954
13955 2005-10-11  Bruno Haible  <bruno@clisp.org>
13956
13957         * lib/c-strcase.h: New file, from GNU gettext.
13958         * lib/c-strcasecmp.c: New file, from GNU gettext.
13959         * lib/c-strncasecmp.c: New file, from GNU gettext.
13960
13961 2005-10-10  Paul Eggert  <eggert@cs.ucla.edu>
13962
13963         * modules/mempcpy (License): GPL -> LGPL.
13964         * modules/strchrnul (License): Likewise.
13965         * modules/sysexits (License): Likewise.
13966
13967 2005-10-08  Simon Josefsson  <jas@extundo.com>
13968
13969         * config/srclist.txt: Bug 1423 is closed, but 1439 remains.
13970
13971 2005-10-07  Simon Josefsson  <jas@extundo.com>
13972
13973         * m4/memxor.m4: Remove gl_C_RESTRICT call.
13974
13975 2005-10-06  Simon Josefsson  <jas@extundo.com>
13976
13977         * tests/test-hmac-md5.c: New file.
13978
13979         * modules/hmac-md5-tests: New file.
13980
13981         * modules/hmac-md5: New file.
13982
13983 2005-10-06  Simon Josefsson  <jas@extundo.com>
13984
13985         * m4/hmac-md5.m4: New file.
13986
13987         * m4/memxor.m4: Require gl_C_RESTRICT.
13988
13989 2005-10-06  Simon Josefsson  <jas@extundo.com>
13990
13991         * lib/memxor.c (memxor): Avoid casts and warnings.
13992
13993 2005-10-06  Simon Josefsson  <jas@extundo.com>
13994
13995         * lib/hmac-md5.c: New file.
13996
13997         * lib/hmac.h: New file.
13998
13999 2005-10-06  Paul Eggert  <eggert@cs.ucla.edu>
14000
14001         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Check that bool
14002         promotes to int, not unsigned int, to catch the AIX 5.3
14003         compiler bug.
14004
14005 2005-10-05  Simon Josefsson  <jas@extundo.com>
14006
14007         * modules/memxor: New file.
14008
14009         * modules/iconv (Files): Move config.rpath to havelib, it is used
14010         there.
14011
14012         * modules/havelib (Files): Add config.rpath.
14013
14014 2005-10-05  Simon Josefsson  <jas@extundo.com>
14015
14016         * m4/memxor.m4: New file.
14017
14018 2005-10-05  Simon Josefsson  <jas@extundo.com>
14019
14020         * lib/memxor.c (memxor): Fix compiler error.
14021
14022         * lib/md5.h (MD5_DIGEST_SIZE, MD5_BLOCK_SIZE): Add, see also
14023         <http://sourceware.org/bugzilla/show_bug.cgi?id=1423>.
14024
14025         * lib/memxor.h, lib/memxor.c: New files.
14026
14027         * lib/getaddrinfo.h: Don't protect sys/types.h with HAVE_SYS_TYPES_H,
14028         we assume all systems have it, suggested by Jim Meyering
14029         <jim@meyering.net>.  Remove HAVE_SYS_SOCKET_H test too, to see if
14030         any systems lack sys/socket.h; mingw32 is known to lack it, but we
14031         don't support it yet anyway.  Also remove HAVE_NETDB_H test, for
14032         same reasons.
14033
14034 2005-10-05  Simon Josefsson  <jas@extundo.com>
14035
14036         * config/srclist.txt: Add glibc bug 1423 for md5.h.
14037
14038 2005-10-05  Paul Eggert  <eggert@cs.ucla.edu>
14039
14040         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Don't check for
14041         sys/socket.h, netdb.h, sys/types.h; the checks areno longer
14042         needed, since the source code now assumes these .h files.
14043
14044 2005-10-05  Derek Price  <derek@ximbiot.com>
14045
14046         * lib/getdelim.c (SIZE_MAX): New macro, if not already defined.
14047
14048 2005-10-05  Bruno Haible  <bruno@clisp.org>
14049
14050         * modules/stdint (License): Change to LGPL.
14051
14052 2005-10-04  Simon Josefsson  <jas@extundo.com>
14053
14054         * lib/getaddrinfo.h: Move sys/types.h include first, reported by "Mark
14055         D. Baushke" <mdb@gnu.org>.
14056
14057 2005-10-04  Bruno Haible  <bruno@clisp.org>
14058
14059         * lib/verify.h (verify_true): Provide alternative definition for C++.
14060
14061 2005-10-03  Paul Eggert  <eggert@cs.ucla.edu>
14062
14063         * lib/getdelim.c: Include getdelim.h first.  Include <limits.h>.
14064         (SSIZE_MAX): New macro, if not already defined.
14065         (getdelim): Fix buffer overrun on 64-bit hosts with lines longer
14066         than 2 GiB.
14067
14068 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14069
14070         Sync from coreutils.
14071         * m4/openat.m4 (gl_FUNC_OPENAT): Check for fdopendir.
14072         * m4/ullong_max.m4 (gl_ULLONG_MAX): Simplify so that it merely
14073         defines ULONG_MAX_LT_ULLONG_MAX.  Thomas M.Ott reports that
14074         ULLONG_MAX doesn't work with 2.7.2.1.
14075
14076 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14077
14078         * modules/xreadlink (Makefile.am): Remove lib_SOURCES.
14079         From Ben Pfaff.
14080
14081         * modules/exclude (Depends-on): Depend on verify.
14082         * modules/strtoimax (Depends-on): Likewise.
14083         * modules/utimecmp (Depends-on): Likewise.
14084
14085 2005-10-02  Paul Eggert  <eggert@cs.ucla.edu>
14086
14087         * lib/exclude.c: Include verify.h.
14088         (verify): Remove.  All callers changed to use verify.h's version.
14089         * lib/strtoimax.c: Likewise.
14090         * lib/utimecmp.c: Likewis.e
14091
14092         Sync from coreutils.
14093         * lib/.cppi-disable: Add getaddrinfo.h, getdelim.h, getline.h,
14094         getpass.c, mbchar.h, mbuiter.h, strcase.h, strnlen.h, strnlen1.h.
14095         * lib/.cvsignore: Add fts.h, search.h, t-fpending.
14096         * lib/settime.c (settime): Fix { typo in previous patch.  Also, don't
14097         bother returning ENOSYS if settimeofday or stime fails; just let
14098         them return whatever errno they want to return.
14099         * lib/utimens.c: Include unistd.h, for dup2.
14100         (futimens): Fix typo: HAVE_FUTIMESAT was misspelled in an #if.
14101         (futimens) [! HAVE_FUTIMESAT]: If !file, set errno before returning -1.
14102
14103 2005-10-02  Jim Meyering  <jim@meyering.net>
14104
14105         Sync from coreutils.
14106         * m4/utimes.m4 (gl_FUNC_UTIMES): Detect the version of utimes
14107         from glibc-2.2.5 that fails for read-only files.
14108
14109 2005-10-02  Jim Meyering  <jim@meyering.net>
14110
14111         Sync from coreutils.
14112         * lib/fts-cycle.c [HAVE_CONFIG_H]: Include <config.h>.
14113         * lib/openat-die.c: Use `#ifdef HAVE_CONFIG_H', not
14114         `#if HAVE_CONFIG_H'.
14115         * lib/openat.c (fdopendir): Do not define if HAVE_FDOPENDIR.
14116         Remove AT_FDCWD test.
14117         Do not consume the fd unless successful.
14118         * lib/openat.h (fdopendir): Do not define if HAVE_FDOPENDIR.
14119         * lib/settime.c (settime): Move the HAVE_STIME block `up' into an #elif
14120         block, so that we don't even try to compile it if settimeofday is
14121         available.  This works around a compilation failure on OSF1 V5.1,
14122         due to stime requiring a `long int*' while tv_sec is `int'.
14123
14124 2005-10-02  Alfred M. Szmidt  <ams@gnu.org>
14125
14126         Sync from coreutils.
14127         * m4/chdir-long.m4 (gl_FUNC_CHDIR_LONG): Compare $gl_have_path...
14128         against `yes', rather than just testing for nonempty.
14129
14130 2005-10-01  Simon Josefsson  <jas@extundo.com>
14131
14132         * m4/getaddrinfo.m4: Include sys/types.h for sys/socket.h, on FreeBSD
14133         and Darwin.
14134
14135         * m4/getaddrinfo.m4: Use AC_GNU_SOURCE, GNU only declare getaddrinfo
14136         as an (POSIX) extension.  Check for sys/types.h, sys/socket.h, and
14137         netdb.h too, needed by getaddrinfo.h.  Check if getaddrinfo,
14138         freeaddrinfo and gai_strerror are declared by the POSIX headers.
14139         Check if struct addrinfo is declared.
14140
14141 2005-10-01  Simon Josefsson  <jas@extundo.com>
14142
14143         * lib/getaddrinfo.h: Protect #include's of sys/socket.h and netdb.h.
14144         Only define struct addrinfo if !HAVE_STRUCT_ADDRINFO.  Protect
14145         AI_* and EAI_* definitions.  Protect function declarations.
14146
14147 2005-10-01  Jim Meyering  <jim@meyering.net>
14148
14149         Sync from coreutils.
14150
14151         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Look for getservbyname in these
14152         libraries [inet nsl socket xnet].  Nelson Beebe reported that with
14153         native cc on Solaris 7, getaddrinfo.c requires -lsocket.
14154         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
14155         in the inet and nsl libraries.  Required on Solaris 5.7.
14156
14157 2005-10-01  Jim Meyering  <jim@meyering.net>
14158
14159         Sync from coreutils.
14160         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Check for gethostbyname
14161         in the inet and nsl libraries.  Required on Solaris 5.7.
14162
14163 2005-10-01  Eric Blake  <ebb9@byu.net>  (tiny change)
14164
14165         * lib/getdelim.c (getdelim): Remove unused variables.
14166
14167 2005-09-29  Paul Eggert  <eggert@cs.ucla.edu>
14168
14169         * lib/xtime.h (XTIME_PRECISION): Now of type int, not long long int,
14170         so that the code works even with ancient cpp.  Portability problem
14171         with GCC 2.7.2.1 reported by Thomas M.Ott.
14172
14173 2005-09-27  Paul Eggert  <eggert@cs.ucla.edu>
14174
14175         * modules/regex (Depends-on): Add strcase.
14176
14177         * modules/gethostname (Licence): Change from GPL to LGPL, since
14178         gethostname.c is a trivial implementation of a standard library
14179         function.
14180         * modules/poll (License): Change from GPL to LGPL, since it's
14181         derived from LGPL code.
14182
14183 2005-09-27  Jim Meyering  <jim@meyering.net>
14184
14185         * lib/getcwd.c: Change #ifdef<TAB>HAVE_CONFIG_H to #ifdef
14186         HAVE_CONFIG_H.
14187
14188         * lib/intprops.h (signed_type_or_expr__): Define.
14189         (INT_STRLEN_BOUND) [__GNUC__]: Use a slightly tighter bound
14190         for unsigned types.
14191
14192 2005-09-26  Paul Eggert  <eggert@cs.ucla.edu>
14193
14194         * lib/verify.h (verify_expr): Remove, replacing with:
14195         (verify_true): New macro that returns true instead of void.
14196         (verify_type__): Remove.
14197         (verify): Use verify_true rather than verify_type__.
14198
14199 2005-09-26  Bruno Haible  <bruno@clisp.org>
14200
14201         * modules/mbchar (Include): Mention that HAVE_WCHAR_H && HAVE_WCTYPE_H
14202         is necessary.
14203         (lib_SOURCES): Remove mbchar.c.
14204         * modules/mbfile (Include): Mention that HAVE_MBRTOWC is necessary.
14205         (Files): Add m4/mbrtowc.m4.
14206         * modules/mbiter: Likewise.
14207         * modules/mbuiter: Likewise.
14208
14209 2005-09-26  Bruno Haible  <bruno@clisp.org>
14210
14211         * m4/mbchar.m4 (gl_MBCHAR): Check for wchar.h and wctype.h. Don't
14212         compile mbchar.c if they are not both present.
14213         * m4/mbfile.m4 (gl_MBFILE): Require gl_FUNC_MBRTOWC.
14214         * m4/mbiter.m4 (gl_MBITER): Likewise.
14215         * m4/strstr.m4 (gl_PREREQ_STRSTR): Use AC_REQUIRE.
14216         * m4/strcasestr.m4 (gl_PREREQ_STRCASESTR): Likewise.
14217         * m4/strcase.m4 (gl_PREREQ_STRCASECMP): Likewise.
14218
14219 2005-09-25  Jim Meyering  <jim@meyering.net>
14220
14221         * modules/inet_ntop (Depends-on): Add socklen, since inet_ntop.c
14222         also uses socklen_t.
14223
14224 2005-09-24  Paul Eggert  <eggert@cs.ucla.edu>
14225
14226         * lib/utimens.c (ENOSYS): Define if not already defined.
14227         (futimens): Support having a null PATH if the file descriptor
14228         is nonnegative.
14229
14230         * lib/regex_internal.h (__GNUC_PREREQ, always_inline, inline, pure):
14231         Remove.
14232         (__attribute): Define to empty unless GCC 3.1 or later.
14233         This works around a core dump on OpenBSD 3.4, which has GCC
14234         2.95.3, which dumps core when given __attribute__(()).  It also
14235         simplifies other tests, since we really don't want to bother with
14236         worrying about which ancient version of GCC supported what.
14237         Original problem reported by Yoann Vandoorselaere, with part of
14238         the fix suggested by Derek Price.
14239
14240 2005-09-24  Jim Meyering  <jim@meyering.net>
14241
14242         * lib/verify.h (verify_type__): Use `unsigned int' as the bitfield type
14243         so we can once again use a positive bitfield width of 1 -- now we
14244         don't have to explain why we were using a bitfield width of 2.
14245
14246 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14247
14248         * m4/regex.m4 (gl_REGEX): If replacing, define regcomp to rpl_regcomp,
14249         and similarly for the other external symbols.  Problem reported
14250         by James Gallager.
14251
14252         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Catch Sun Studio 10u1 on Linux
14253         bug reported by Jim Meyering.
14254
14255         * m4/utimens.m4 (gl_UTIMENS): Check for futimesat.
14256         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Undo previous change;
14257         not needed, since socklen is a prerequisite module.
14258
14259 2005-09-23  Paul Eggert  <eggert@cs.ucla.edu>
14260
14261         * lib/getaddrinfo.c [HAVE_NETINET_IN_H]: Include <netinet/in.h>.
14262         Problem reported by Eric Blake.
14263         (getaddrinfo): Initialize se so that it's not garbage.
14264         Redo internal storage allocation so that it doesn't make unportable
14265         assumptions about alignment.
14266         Fix a memory leak.
14267
14268         * lib/utimens.c (futimens): Use futimesat if available.
14269         Prefer it to futimes since it doesn't have the futimes bug.
14270
14271         * lib/verify.h (GL_CONCAT0, GL_CONCAT): Remove.
14272         (verify): Don't use the __LINE__ trick, as it doesn't work in general.
14273         Instead, declare a function that returns a pointer to an array,
14274         and use verify_type__ to declare the size of the array.
14275         Problem and germ of a solution reported by Bruno Haible.
14276         (verify_type__): Use 2, not 1, for bitfield size, to avoid
14277         a warning with Irix 6.5 cc.  Problem reported by Bruno Haible.
14278
14279 2005-09-23  Jim Meyering  <jim@meyering.net>
14280
14281         Sync from coreutils.
14282         Correct build failure (socklen_t not defined) on at least
14283         mips-sgi-irix6.5 and alphaev67-dec-osf5.1.
14284         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Require gl_SOCKLEN_T.
14285
14286 2005-09-23  Jim Meyering  <jim@meyering.net>
14287
14288         * modules/getaddrinfo (Depends-on): Add socklen.
14289
14290 2005-09-23  Bruno Haible  <bruno@clisp.org>
14291
14292         * tests/test-verify.c: New file.
14293
14294 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14295
14296         Sync from coreutils.
14297
14298         * modules/argmatch (Depends-on): Add verify.
14299         * modules/getloadavg (Depends-on): Depend on fcntl-safer, not
14300         unistd-safer.
14301         * modules/save-cwd (Depends-on): Likewise.
14302
14303         * modules/openat (Files): Add lib/openat-die.c.
14304         (Depends-on): Remove error, exitfail.
14305         Add dirname.
14306
14307         * modules/verify: New file.
14308         * MODULES.html.sh (Diagnostics <assert.h>): New section,
14309         with "verify" module.
14310
14311 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14312
14313         Sync from coreutils.
14314
14315         * m4/backupfile.m4, calloc.m4, chown.m4, cloexec.m4, dup2.m4:
14316         * m4/fileblocks.m4, free.m4, ftruncate.m4, getcwd.m4, getpagesize.m4:
14317         * m4/getugroups.m4, group-member.m4, idcache.m4, link-follow.m4:
14318         * m4/mkstemp.m4, mktime.m4, mountlist.m4, nanosleep.m4, pathmax.m4:
14319         * m4/physmem.m4, posixver.m4, putenv.m4, safe-read.m4, same.m4:
14320         * m4/save-cwd.m4, stdio-safer.m4, unistd-safer.m4, unlinkdir.m4:
14321         * m4/userspec.m4, xgetcwd.m4, xreadlink.m4:
14322         Don't bother checking for string.h, stdlib.h, unistd.h.
14323         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't require
14324         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK; that's now the lstat
14325         module's job.
14326         * m4/jm-macros.m4 (gl_MACROS): Likewise.
14327         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_LSTAT.
14328
14329         * m4/getdate.m4 (gl_C_COMPOUND_LITERALS): New macro.
14330         (gl_GETDATE): Use it.
14331
14332         * m4/mkdir-p.m4 (gl_MKDIR_PARENTS): Don't bother checking for unistd.h.
14333
14334 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14335
14336         Sync from coreutils.
14337
14338         * lib/.cppi-disable: Add regcomp.c, regex_internal.c, regex_internal.h,
14339         stat-time.h.
14340         * lib/argmatch.h: Include verify.h
14341         (ARGMATCH_VERIFY): Use verify rather than rolling our own.
14342         (ARGMATCH_ASSERT): Remove; unused.
14343         * lib/canonicalize.c: Assume STDC_HEADERS.
14344         * lib/exclude.c: Include "strcase.h".
14345         * lib/regex_internal.h [!defined _LIBC]: Likewise.
14346         * lib/getusershell.c: Include stdio--.h rather than stdio.h
14347         and stdio-safer.h.
14348         (getusershell): Call fopen, not fopen_safer.
14349         * lib/save-cwd.c: Include fcntl--.h rather than fcntl.h.
14350         Do not include unistd-safer.h.
14351         (save_cwd): Don't call fd_safer; no longer needed
14352         now that we include fcntl--.h.
14353
14354         * lib/getdate.y (relative_time): New type.
14355         (RELATIVE_TIME_0): New constant.
14356         (parser_control): Use relative_time instead of doing it ourselves.
14357         (%union): Add new relative_time rel member.
14358         (tYEAR_UNIT, tMONTH_UNIT, tHOUR_UNIT, tMINUTE_UNIT, tSEC_UNIT):
14359         Now typeless.
14360         (relunit, relunit_snumber): Now of type rel.
14361         (zone, rel, relunit, get_date): Adjust to above changes.
14362
14363         * lib/getloadavg.c: Include fcntl--.h rather than fcntl.h.
14364         Do not include unistd-safer.h.
14365         (getloadavg): Don't call fd_safer; no longer needed
14366         now that we include fcntl--.h.
14367
14368         * lib/mkdir-p.c (ENOSYS): Define to EEXIST if not defined.
14369         (make_dir_parents): Treat ENOSYS like EEXIST.
14370
14371         Improve quality of diagnostics on restore_cwd failure.
14372         * lib/mkdir-p.h (make_dir): Remove.  All uses replaced by mkdir.
14373         (make_dir_parents): Last arg is now int * (for errno), not bool *.
14374         * lib/mkdir-p.c (make_dir, make_dir_parents): Likewise.
14375         Rewrite "mkdir -p" algorithm to avoid the need for "stat"
14376         each time through the loop.  Do not diagnose restore_cwd failure;
14377         that is the caller's job (and perhaps the caller does not care).
14378
14379         * lib/mkdir-p.c (CLEANUP_CWD, CLEANUP): Remove.
14380         (make_dir_parents): Revamp to avoid need for CLEANUP_CWD, CLEANUP.
14381         If the file already exists but is not a directory, don't bother
14382         to try to make its parents.
14383         Close potential file descriptor leak if we can't chdir("/") (!).
14384         Don't always return true if chdir($PWD) fails; return true only
14385         if the requested action was done successfully (except for the
14386         chdir($PWD)).
14387         Don't log final directory unless we actually made it.
14388         Refactor to avoid duplicate code to fix up permissions.
14389         Don't attempt to fix up parent permissions if chdir($PWD) fails.
14390
14391         * lib/strftime.c (my_strftime): Rewrite the previous change slightly,
14392         to make it a bit faster and (I hope) clearer.
14393         * lib/strftime.c (my_strftime): Add support for %:z, %::z, %:::z.
14394         Fix bug in formats like %2N.
14395
14396         * lib/verify.h: New file.
14397
14398 2005-09-22  Paul Eggert  <eggert@cs.ucla.edu>
14399
14400         Sync from coreutils.
14401         * m4/getaddrinfo.m4 (gl_PREREQ_GETADDRINFO): Check for netinet/in.h.
14402
14403 2005-09-22  Jim Meyering  <jim@meyering.net>
14404
14405         Sync from coreutils.
14406
14407         * m4/lstat.m4 (gl_FUNC_LSTAT):
14408         Use AC_LIBSOURCES to require lstat.c and lstat.h.
14409         Remove obsolete comment.
14410         * m4/xreadlink.m4: Use AC_LIBSOURCES and AC_LIBOBJ.
14411         * m4/xstrtod.m4: Likewise.
14412
14413         * m4/openat.m4 (gl_FUNC_OPENAT): Add openat-die.c.
14414
14415 2005-09-22  Jim Meyering  <jim@meyering.net>
14416
14417         Sync from coreutils.
14418
14419         * lib/backupfile.c: Use ARGMATCH_VERIFY, just in case.
14420
14421         * lib/posixtm.c (posixtime) [lint]: Initialize *all* of tm0, not just
14422         the .tm_year member, since otherwise gcc-4.0 would now warn about
14423         tm_zone, tm_gmtoff, tm_isdst, tm_yday, tm_wday.
14424
14425         * lib/quotearg.c (quotearg_n_options): Change code to be suboptimal, in
14426         order to avoid an unsuppressible warning from gcc on 64-bit systems.
14427
14428         * lib/getdate.y (get_date): Undo part of the 2005-04-04 change, so that
14429         the command "date -d'2005-03-27 +1 day'" succeeds once again, even
14430         when run in a time zone for which daylight savings time is in effect
14431         for the starting date.
14432
14433         * lib/mkdir-p.c (make_dir_parents): Don't let a failed chdir($PWD)
14434         stop us from restricting permissions of just-created absolute-named
14435         directories.
14436         * lib/mkdir-p.c (CLEANUP_CWD): Return *true*, not false when failing
14437         to restore initial working directory.
14438         * lib/mkdir-p.c (make_dir_parents): New parameter:
14439         different_working_dir, to tell caller if/when we change the working
14440         directory and are unable to return to the initial one.
14441         * lib/mkdir-p.h (make_dir_parents): Update prototype.
14442         * lib/mkdir-p.c (CLEANUP_CWD): Change one more `return 1' to
14443         `return false'.  This fixes a bug introduced on 2004-07-30.
14444
14445         * lib/openat.c (fdopendir): Be sure to close the supplied
14446         file descriptor before returning.  This makes our replacement
14447         implementation a little closer to Solaris's, where fdopendir
14448         ties the file descriptor to the returned DIR* pointer.
14449         * lib/openat.c (unlinkat): New function.
14450         * lib/openat.h (unlinkat): Add prototype.
14451         * lib/openat-die.c (openat_save_fail): Rename from openat_save_die.
14452         (openat_restore_fail): Rename from openat_restore_die.
14453         * lib/openat.c, openat.h: Reflect s/_die/_fail/ renaming.
14454
14455         Provide an alternative to exiting immediately upon save_cwd or
14456         restore_cwd failure.  Now, an application can arrange e.g.,
14457         to perform a longjump in that case.
14458         * lib/openat.c: Include dirname.h.
14459         Use IS_ABSOLUTE_FILE_NAME rather than testing for leading slash.
14460         (rpl_openat, fdopendir, fstatat): Call openat_save_die
14461         and openat_restore_die rather than calling error directly.
14462         Don't include "error.h" or "exitfail.h"; they're no longer needed.
14463
14464         * lib/openat-die.c (openat_save_die, openat_restore_die): New file.
14465         * lib/openat.h (openat_save_die, openat_restore_die): Declare and
14466         define.
14467
14468         * lib/strftime.c [FPRINTFTIME] (fprintftime): Provide a new interface:
14469         size_t fprintftime (FILE *fp, char const *fmt, struct tm const *tm,
14470                             int utc, int nanoseconds);
14471         Background:
14472         date should not have to allocate a megabyte of virtual memory to
14473         handle a format argument like +%1048575T.  When implemented with
14474         strftime, it must allocate such a buffer, use strftime to fill it
14475         in, print it, then free it.
14476         With fprintftime, it simply prints everything and exits.
14477         With no need for memory allocation, that's one fewer way to fail.
14478         * lib/strftime.c (my_strftime): Parse the colons of %:::z *after* the
14479         optional field width, not before, so we accept %9:z, not %:9z.
14480         (my_strftime): Be sure to use L_('x') for literals.
14481
14482         * lib/backupfile.c, lib/canon-host.c, lib/canonicalize.c, lib/chown.c:
14483         * lib/cloexec.c, lib/dup-safer.c, lib/dup2.c, lib/euidaccess.c:
14484         * lib/fd-safer.c, lib/fileblocks.c, lib/fopen-safer.c, lib/fsusage.c:
14485         * lib/ftruncate.c, lib/getcwd.c, lib/getcwd.h, lib/getloadavg.c:
14486         * lib/getopt_.h, lib/getpagesize.h, lib/getugroups.c:
14487         * lib/group-member.c, lib/human.h, lib/idcache.c, lib/mkdir-p.c:
14488         * lib/mountlist.c, lib/nanosleep.c, lib/pathmax.h, lib/physmem.c:
14489         * lib/posixver.c, lib/putenv.c, lib/raise.c, lib/safe-read.c:
14490         * lib/same.c, lib/save-cwd.c, lib/setenv.c, lib/settime.c:
14491         * lib/tempname.c, lib/unlinkdir.c, lib/unsetenv.c, lib/userspec.c:
14492         * lib/xgethostname.c, lib/xreadlink.c:
14493         Assume HAVE_UNISTD_H, i.e., include <unistd.h> unconditionally.
14494
14495         * lib/chown.c, lib/cloexec.c, lib/dup-safer.c, lib/dup2.c:
14496         * lib/fsusage.c, lib/getcwd.c, lib/getloadavg.c, lib/mountlist.c:
14497         * lib/openat.h, lib/save-cwd.c, lib/tempname.c:
14498         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
14499         and don't include <sys/file.h>).
14500
14501 2005-09-22  Eric Blake  <ebb9@byu.net>  (tiny change)
14502
14503         Sync from coreutils.
14504
14505         * lib/getloadavg.c (getloadavg) [__CYGWIN__]: Port to cygwin.
14506         [__linux__]: Allocate a big enough buffer for /proc/loadavg.
14507         [!LDAV_DONE]: Avoid unused variable warning.
14508
14509 2005-09-21  Bruno Haible  <bruno@clisp.org>
14510
14511         * lib/unicodeio.h (unicode_to_mb): New declaration.
14512
14513 2005-09-20  Derek Price  <derek@ximbiot.com>
14514
14515         * lib/getaddrinfo.c: Don't include <netdb.h> included from
14516         getaddrinfo.h.
14517
14518 2005-09-20  Bruno Haible  <bruno@clisp.org>
14519
14520         * gnulib-tool: Remove trailing slashes from the values specified for
14521         --source-base, --m4-base, --tests-base, --aux-dir.
14522         Suggested by Simon Josefsson <jas@extundo.com>.
14523
14524 2005-09-20  Bruno Haible  <bruno@clisp.org>
14525
14526         * gnulib-tool (func_all_modules, func_modules_transitive_closure,
14527         func_modules_to_filelist, func_import, func_create_testdir): Make all
14528         sorting results locale-independent, so that gnulib-cache.m4 doesn't
14529         change when gnulib-tool is invoked in a different locale.
14530
14531 2005-09-19  Simon Josefsson  <jas@extundo.com>
14532
14533         * m4/socklen.m4: Fix typo.
14534
14535 2005-09-19  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
14536
14537         Use a consistent style for including <config.h>.
14538         * lib/__fpending.c, lib/acl.c, lib/argmatch.c, lib/argp-help.c,
14539         lib/argp-parse.c, lib/argp-pvh.c, lib/backupfile.c, lib/basename.c,
14540         lib/c-stack.c, lib/calloc.c, lib/check-version.c, lib/cloexec.c,
14541         lib/closeout.c, lib/copy-file.c, lib/creat-safer.c, lib/cycle-check.c,
14542         lib/dirfd.c, lib/dirname.c, lib/dup-safer.c, lib/dup2.c,
14543         lib/euidaccess.c, lib/exclude.c, lib/exitfail.c, lib/fatal-signal.c,
14544         lib/fd-safer.c, lib/file-type.c, lib/fileblocks.c, lib/filemode.c,
14545         lib/filenamecat.c, lib/findprog.c, lib/fnmatch.c, lib/fopen-safer.c,
14546         lib/free.c, lib/fsusage.c, lib/ftruncate.c, lib/full-write.c,
14547         lib/fwriteerror.c, lib/getaddrinfo.c, lib/getcwd.c, lib/getdelim.c,
14548         lib/getline.c, lib/getlogin_r.c, lib/getndelim2.c, lib/getnline.c,
14549         lib/getopt1.c, lib/getpass.c, lib/group-member.c, lib/hard-locale.c,
14550         lib/hash-pjw.c, lib/hash.c, lib/human.c, lib/idcache.c,
14551         lib/inet_ntop.c, lib/isdir.c, lib/long-options.c, lib/malloc.c,
14552         lib/memcasecmp.c, lib/memcmp.c, lib/memcoll.c, lib/memcpy.c,
14553         lib/memmove.c, lib/mkdir-p.c, lib/modechange.c, lib/mountlist.c,
14554         lib/open-safer.c, lib/physmem.c, lib/pipe-safer.c, lib/pipe.c,
14555         lib/poll.c, lib/posixver.c, lib/progname.c, lib/progreloc.c,
14556         lib/putenv.c, lib/quote.c, lib/quotearg.c, lib/readline.c,
14557         lib/readlink.c, lib/realloc.c, lib/regex.c, lib/rename.c, lib/rmdir.c,
14558         lib/rpmatch.c, lib/safe-read.c, lib/same.c, lib/save-cwd.c,
14559         lib/savedir.c, lib/sig2str.c, lib/strcspn.c, lib/strerror.c,
14560         lib/stripslash.c, lib/strncasecmp.c, lib/strndup.c, lib/strnlen.c,
14561         lib/strnlen1.c, lib/strsep.c, lib/strstr.c, lib/strtod.c,
14562         lib/strtoimax.c, lib/strtol.c, lib/strverscmp.c, lib/tempname.c,
14563         lib/time_r.c, lib/userspec.c, lib/utimecmp.c, lib/version-etc-fsf.c,
14564         lib/version-etc.c, lib/wait-process.c, lib/xalloc-die.c, lib/xgetcwd.c,
14565         lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c, lib/xreadlink.c,
14566         lib/xsetenv.c, lib/xstrndup.c, lib/xstrtoimax.c, lib/xstrtol.c,
14567         lib/xstrtoumax.c, lib/yesno.c:
14568         Standardize inclusion of config.h.
14569         * lib/__fpending.h, lib/dirfd.h, lib/getdate.h, lib/human.h,
14570         lib/inttostr.h:  Removed inclusion of config.h from header files.
14571         * lib/inttostr.c:  Adjusted in-tree users.
14572         * lib/timespec.h: Remove superfluous warning to include config.h.
14573         * lib/atexit.c, lib/chdir-long.c, lib/chown.c, lib/fchown-stub.c,
14574         lib/getgroups.c, lib/gettimeofday.c, lib/lchown.c, lib/lstat.c,
14575         lib/mkdir.c, lib/mkstemp.c, lib/nanosleep.c, lib/openat.c, lib/raise.c,
14576         lib/readtokens0.c, lib/readutmp.c, lib/unlinkdir.c: Guard inclusion of
14577         config.h with HAVE_CONFIG_H.
14578
14579 2005-09-19  Jim Meyering  <jim@meyering.net>
14580
14581         * modules/pathmax (License): Change to LGPL.
14582
14583 2005-09-19  Derek Price  <derek@ximbiot.com>
14584
14585         * config/srclist.txt: glibc's glob.h is now in lib/glob-libc.h.
14586
14587 2005-09-19  Bruno Haible  <bruno@clisp.org>
14588
14589         * gnulib-tool (import): Provide default for --tests-base.
14590
14591 2005-09-19  Bruno Haible  <bruno@clisp.org>
14592
14593         * doc/quote.texi: New file, extracted from gnulib.texi.
14594         * doc/ctime.texi: New file, extracted from gnulib.texi.
14595         * doc/inet_ntoa.texi: New file, extracted from gnulib.texi.
14596         * doc/gnulib-tool.texi: New file, extracted from gnulib.texi.
14597         * doc/gnulib.texi: Include them.
14598
14599 2005-09-18  Bruno Haible  <bruno@clisp.org>
14600
14601         Portability fix.
14602         * gnulib-tool (func_readlink): New function.
14603         (func_ln_if_changed): Use it.
14604
14605 2005-09-18  Bruno Haible  <bruno@clisp.org>
14606
14607         * gnulib-tool: Support --with-tests also with --import.
14608         (func_emit_tests_Makefile_am): Use variables $m4base and $testsbase.
14609         (func_import): Use variables $testsbase and $inctests. Emit a
14610         gl_TESTS_BASE form into gnulib-cache.m4. Create $testsbase/Makefile.am.
14611         Remind the user to add AC_CONFIG_FILES($testsdir/Makefile) and
14612         SUBDIRS += $testsdir.
14613         (func_create_testdir): Update.
14614
14615 2005-09-18  Bruno Haible  <bruno@clisp.org>
14616
14617         * gnulib-tool: Revise --dry-run implementation. Use variable $doit
14618         instead of $dry_run.
14619         (func_cp_if_changed, func_mv_if_changed): Remove functions.
14620         (func_ln_if_changed): Don't handle dry-run here.
14621         (func_import): In dry-run mode, detect more precisely which actions
14622         would be performed, and don't use "...ing" verbs.
14623
14624 2005-09-18  Bruno Haible  <bruno@clisp.org>
14625
14626         * gnulib-tool (func_tmpdir): New function, taken from GNU gettextize.
14627         (func_import): Use join on two temporary files instead of three nested
14628         loops, in order to determine which files are new or old.
14629
14630 2005-09-18  Bruno Haible  <bruno@clisp.org>
14631
14632         * gnulib-tool (func_import): Comment out code that spits out the
14633         new files with --dry-run.
14634
14635 2005-09-18  Bruno Haible  <bruno@clisp.org>
14636
14637         * doc/gnulib.texi (Invoking gnulib-tool): 50% rewritten.
14638
14639 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14640
14641         * lib/stat-time.h: New file.
14642         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP, ATIME_CMP, CTIME_CMP):
14643         (MTIME_CMP, TIMESPEC_NS): Remove.  Now done by stat-time.h,
14644         in a different way.
14645         (timespec_cmp): New function.
14646         * lib/utimecmp.c: Include stat-time.h.
14647         (SYSCALL_RESOLUTION): Depend on whether various struct stat
14648         members exist, not on the obsolescent ST_MTIM_NSEC.
14649         (utimecmp): Use the new stat-time functions rater than TIMESPEC_NS.
14650
14651 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14652
14653         * config/srclist.txt: Remove glibc bug 1033 and uncomment mktime.c.
14654
14655 2005-09-16  Paul Eggert  <eggert@cs.ucla.edu>
14656
14657         * MODULES.html.sh (File system functions): Add stat-time.
14658         * modules/stat-time: New file.
14659         * modules/timespec (Files): Remove m4/st_mtim.m4; this
14660         is now done in a different way, by the stat-time module.
14661         * modules/utimecmp (Depends-on): Add stat-time.
14662
14663 2005-09-15  Paul Eggert  <eggert@cs.ucla.edu>
14664
14665         * m4/st_mtim.m4: Remove.  Superseded by...
14666         * m4/stat-time.m4: New file.
14667         * m4/timespec.m4 (gl_TIMESPEC): Require AC_C_INLINE.
14668         Do not invoke AC_STRUCT_ST_MTIM_NSEC; no longer needed.
14669
14670 2005-09-15  Derek Price  <derek@ximbiot.com>
14671
14672         * m4/strstr.m4 (gl_FUNC_STRSTR): Don't define strstr here.
14673
14674 2005-09-15  Derek Price  <derek@ximbiot.com>
14675
14676         * lib/regex_internal.h: Blank `pure' for GNUC < 3.
14677         * lib/regex_internal.c: Ditto, using this...
14678         (__GNUC_PREREQ): ...new macro.
14679         * lib/regcomp.c, regexec.c: Blank `always_inline' for GNUC < 3.1
14680         using...
14681         (__GNUC_PREREQ): ...this new macro.
14682
14683         * lib/strstr.h: Include string.h. Define strstr as a macro here.
14684
14685 2005-09-15  Derek Price  <derek@ximbiot.com>
14686             Paul Eggert  <eggert@cs.ucla.edu>
14687
14688         * lib/regcomp.c, regexec.c, regex_internal.c: Back out previous
14689         changes, consolidating in...
14690         * lib/regex_internal.h: ...this file.
14691
14692 2005-09-13  Jim Meyering  <jim@meyering.net>
14693
14694         * lib/canon-host.c: Filter through gnu indent and reword comments
14695         slightly.
14696         * lib/canon-host.h (ch_strerror_r): Tweak cpp indentation and spacing.
14697
14698 2005-09-13  Derek Price  <derek@ximbiot.com>
14699
14700         * lib/canon-host.c (canon_host_r): Set *cherror on memory allocation
14701         failure.
14702         Reported by Jim Meyering  <jim@meyering.net>.
14703
14704 2005-09-12  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
14705
14706         * lib/base64.c: Typo.
14707         (base64_encode): Put b64str in initialized data section.
14708
14709 2005-09-12  Paul Eggert  <eggert@cs.ucla.edu>
14710
14711         Merge glibc and coreutils changes into gnulib, plus a few
14712         extra fixes.
14713         * lib/md5.c: Use #error rather than a string.
14714         (CYCLIC): New macro, from glibc source.  Use it instead of rol.
14715         * lib/md5.h (__GNUC_PREREQ, __THROW): Define if not defined already.
14716         (__attribute__): Define to empty for non recent-GCC.
14717         (__md5_buffer, __md5_finish_ctx, __md5_init_ctx, __md5_process_block):
14718         (__md5_process_bytes, __md5_read_ctx, __md5_stream):
14719         Renamed from their non-__ counterparts, with new macros replacing
14720         them if not _LIBC.  Add __THROW attribute.
14721         (rol): Remove.
14722         (struct md5_ctx): Align buffer if using GCC.
14723         * lib/sha1.h (struct sha1_ctx): Likewise.
14724         * lib/sha1.c (SWAP): Renamed from the NOTSWAP.  All uses changed.
14725         The old name was backwards.
14726         (NOTSWAP): Remove; not used.
14727         (rol): New macro, moved here from md5.h.
14728         (sha1_process_block): Remove a FIXME that doesn't make sense.
14729
14730 2005-09-12  Derek Price  <derek@ximbiot.com>
14731
14732         Return usable errors from canon-host.
14733         * lib/canon-host.h: New file.
14734         * lib/canon-host.c (canon_host): Wrap...
14735         (canon_host_r): ...this new function, which now relies exclusively on
14736         getaddrinfo.
14737         (ch_strerror): New function.
14738         (last_cherror): New global.
14739         * lib/getaddrinfo.c: Move include of getaddrinfo.h first to test
14740         interface.
14741         (getaddrinfo): Add AI_CANONNAME functionality.  Don't do arithmetic on
14742         void *.
14743         (freeaddrinfo): Free ai->ai_canonname when set.
14744
14745 2005-09-12  Derek Price  <derek@ximbiot.com>
14746
14747         Make canon-host require getaddrinfo.
14748         * m4/canon-host.m4 (gl_CANON_HOST): Remove most dependencies.
14749         AC_LIBSOURCE canon-host.h.  Call...
14750         (gl_PREREQ_CANON_HOST): ...this new function, which requires
14751         gl_GETADDRINFO.
14752         * m4/getaddrinfo.m4 (gl_GETADDRINFO): Compile gai_strerror when needed.
14753
14754 2005-09-12  Derek Price  <derek@ximbiot.com>
14755
14756         * modules/canon-host: Add canon-host.h.  Depend on getaddrinfo.  Make
14757         LGPL.
14758         * modules/getaddrinfo: Add link to opengroup spec.  Depend on strdup.
14759
14760 2005-09-12  Derek Price  <derek@ximbiot.com>
14761
14762         * lib/gai_strerror.c: Include config.h when available.  Include
14763         getaddrinfo.h before other headers to test interface.
14764         Reported by Larry Jones <lawrence.jones@ugs.com>.
14765
14766 2005-09-12  Derek Price  <derek@ximbiot.com>
14767             Paul Eggert  <eggert@cs.ucla.edu>
14768
14769         * modules/glob (Files): Add glob-libc.h.
14770
14771 2005-09-12  Derek Price  <derek@ximbiot.com>
14772             Paul Eggert  <eggert@cs.ucla.edu>
14773
14774         * m4/glob.m4 (gl_GLOB_SUBSTITUTE): AC_LIBSOURCES for glob.c,
14775         glob_.h, glob-libc.h.
14776         (gl_PREREQ_GLOB): Remove _SYS_CDEFS_H hack; no longer needed.
14777
14778 2005-09-12  Derek Price  <derek@ximbiot.com>
14779             Paul Eggert  <eggert@cs.ucla.edu>
14780
14781         * lib/glob-libc.h: Renamed from glob_.h.  The new version is
14782         taken from libc's glob.h, except with '#ifdef __GLOB_GNULIB'
14783         protecting things that should be done only in gnulib contexts.
14784         * lib/glob_.h: New file, containing only the glob things needed for
14785         gnulib.
14786         (GLOB_PREFIX): Remove.  All uses changed to look for __GLOB_GNULIB.
14787         (__GLOB_CONCAT, __GLOB_XCONCAT, __GLOB_ID): Remove; no longer needed.
14788         (glob, globfree, glob_pattern_p): Now defined simply in terms of
14789         rpl_glob, rpl_globfree, rpl_glob_pattern_p.
14790         (__GLOB_GNULIB): New macro, to keep the glob.h changes clearer
14791         and to respect the namespace rules better.
14792
14793 2005-09-08  Simon Josefsson  <jas@extundo.com>
14794
14795         * modules/socklen: New file.
14796
14797 2005-09-08  Simon Josefsson  <jas@extundo.com>
14798
14799         * m4/socklen.m4: New file.
14800
14801 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14802
14803         * modules/utimens (Files): Add m4/utimbuf.m4, since
14804         m4/utimens.m4 requires gl_CHECK_TYPE_STRUCT_UTIMBUF.
14805         Reported by Sergey Poznyakoff.
14806
14807 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14808
14809         * lib/glob.c (glob, globfree, __glob_pattern_p): Use old-style function
14810         definitions, since that's the preferred style in glibc.
14811         Fix a minor spacing issue, and update copyright notice to match
14812         glibc's.
14813
14814 2005-09-08  Paul Eggert  <eggert@cs.ucla.edu>
14815
14816         * config/srclist.txt: Remove glibc bug 1061; it's been fixed.
14817
14818 2005-09-06  Simon Josefsson  <jas@extundo.com>
14819
14820         * lib/getpass.c (getpass): Fix typo, test for HAVE_TCSETATTR and not
14821         TCSETATTR.  Reported by Derek Price <derek@ximbiot.com>.
14822
14823 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14824
14825         * lib/regex_internal.h (bitset_not): Add parens to avoid gcc -Wall
14826         warning.
14827
14828 2005-09-06  Paul Eggert  <eggert@cs.ucla.edu>
14829
14830         * config/srclist.txt: Add glibc bug 1302.
14831
14832 2005-09-05  Paul Eggert  <eggert@cs.ucla.edu>
14833
14834         Change bitset word type from unsigned int to unsigned long int,
14835         as this has better performance on typical 64-bit hosts.
14836         Port bitset code to hosts with unusual word sizes.
14837         * lib/regcomp.c (build_equiv_class, build_charclass, build_range_exp):
14838         (build_collating_symbol):
14839         Prefer bitset to re_bitset_ptr_t in prototypes, when the actual
14840         argument is a bitset.  This is merely a style issue, but it makes
14841         it clearer that an entire array is expected.
14842         (re_compile_fastmap_iter, init_dfa, init_word_char, optimize_subexps):
14843         * lib/regcomp.c (lower_subexp, parse_bracket_exp, built_charclass_op):
14844         Port to the case where bitset_word is not the same as unsigned int.
14845         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
14846         (bitset_not, bitset_merge, bitset_set_all, bitset_mask):
14847         Likewise.
14848         * lib/regexec.c (check_dst_limits_calc_pos_1,
14849         check_subexp_matching_top):
14850         (build_trtable, group_nodes_into_DFAstates):
14851         Likewise.
14852         * lib/regcomp.c (re_compile_fastmap_iter, utf8_sb_map, optimize_utf8):
14853         Don't assume that SBC_MAX is a multiple of BITSET_WORD_BITS.
14854         * lib/regex_internal.h (bitset_set_all, bitset_not): Likewise.
14855         * lib/regexec.c (group_nodes_into_DFAstates): Likewise.
14856         * lib/regcomp.c (utf8_sb_map): Don't assume UINT_MAX == 0xffffffff.
14857         * lib/regcomp.c (optimize_subexps, lower_subexp):
14858         Work even if bitset_word has holes in its bitwise representation.
14859         * lib/regex_internal.h (BITSET_WORD_BITS): Likewise.
14860         * lib/regexec.c (check_dst_limits_calc_pos_1,
14861         check_subexp_matching_top):
14862         Likewise.
14863         * lib/regex_internal.c (re_string_reconstruct):
14864         Don't assume UCHAR_MAX == 255.
14865         * lib/regex_internal.h (bitset_set_all): Likewise.
14866         * lib/regex_internal.h (BITSET_WORD_BITS): Renamed from UINT_BITS.
14867         All uses changed.
14868         (BITSET_WORDS): Renamed from BITSET_UINTS.  All uses changed.
14869         (bitset_word): New type, replacing 'unsigned int' for bitset uses.
14870         All uses changed.
14871         (BITSET_WORD_MAX): New macro.
14872         (bitset_set, bitset_clear, bitset_contain, bitset_empty):
14873         (bitset_set_all, bitset_copy):  Now inline functions, not macros.
14874         (bitset_empty, bitset_copy):
14875         Prefer sizeof (bitset) to multiplying it out ourselves.
14876         (bitset_not_merge): Remove; unused.
14877         (bitset_contain): Return bool, not unsigned int with one bit on.
14878         All callers changed.
14879         * lib/regexec.c (build_trtable): Don't assume bitset has no stricter
14880         alignment than re_node_set; do this by defining a new internal
14881         type struct dests_alloc and using it to allocate memory.
14882
14883 2005-09-05  Bruno Haible  <bruno@clisp.org>
14884
14885         * gnulib-tool (func_import): Fix comparison in handling of symbolic
14886         links.
14887
14888 2005-09-04  Martin Lambers  <marlam@marlam.de>  (tiny change)
14889
14890         * modules/size_max (Makefile.am): Add size_max.h
14891
14892 2005-09-04  Derek Price  <derek@ximbiot.com>
14893
14894         * gnulib-tool (func_import): Fix reversed $symbolic logic.
14895
14896 2005-09-03  Simon Josefsson  <jas@extundo.com>
14897
14898         * gnulib-tool: Fix typo.
14899
14900 2005-09-03  Simon Josefsson  <jas@extundo.com>
14901
14902         * config/srclist.txt: Add glibc bug 1293.
14903
14904 2005-09-03  Derek Price  <derek@ximbiot.com>
14905
14906         * m4/getlogin_r (gl_GETLOGIN_R): Fix cut & paste error.
14907         From Larry Jones <lawrence.jones@ugs.com>.
14908
14909 2005-09-02  Simon Josefsson  <jas@extundo.com>
14910
14911         * modules/socklen: New file.
14912
14913 2005-09-02  Simon Josefsson  <jas@extundo.com>
14914
14915         * modules/havelib: New module.
14916
14917         * modules/gettext, modules/iconv, modules/lock, modules/readline:
14918         Use havelib.
14919
14920 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14921
14922         Check for arithmetic overflow when calculating sizes, to prevent
14923         some buffer-overflow issues.  These patches are conservative, in the
14924         sense that when I couldn't determine whether an overflow was possible,
14925         I inserted a run-time check.
14926         * lib/regex_internal.h (re_xmalloc, re_xrealloc, re_x2realloc): New
14927         macros.
14928         (SIZE_MAX) [!defined SIZE_MAX]: New macro.
14929         (re_alloc_oversized, re_x2alloc_oversized, re_xnmalloc):
14930         (re_xnrealloc, re_x2nrealloc): New inline functions.
14931         * lib/regcomp.c (init_dfa, analyze, build_range_exp,
14932         parse_bracket_exp):
14933         (build_equiv_class, build_charclass): Check for arithmetic overflow
14934         in size expression calculations.
14935         * lib/regex_internal.c (re_string_realloc_buffers):
14936         (build_wcs_upper_buffer, re_node_set_add_intersect):
14937         (re_node_set_init_union, re_node_set_insert, re_node_set_insert_last):
14938         (re_dfa_add_node, register_state): Likewise.
14939         * lib/regexec.c (re_search_stub, re_copy_regs, re_search_internal):
14940         (prune_impossible_nodes, push_fail_stack, set_regs, check_arrival):
14941         (build_trtable, extend_buffers, match_ctx_init, match_ctx_add_entry):
14942         (match_ctx_add_subtop, match_ctx_add_sublast): Likewise.
14943
14944 2005-09-02  Paul Eggert  <eggert@cs.ucla.edu>
14945
14946         * modules/inttostr (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
14947         m4/ulonglong.m4.  Problem reported by Martin Lambers.
14948
14949 2005-09-02  Bruno Haible  <bruno@clisp.org>
14950
14951         Support for lib vs. lib64 distinction on biarch platforms.
14952         * m4/lib-prefix.m4 (AC_LIB_PREPARE_MULTILIB): New macro.
14953         (AC_LIB_PREFIX): Require it. Use $acl_libdirstem instead of 'lib'.
14954         * m4/lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Likewise.
14955
14956 2005-09-02  Bruno Haible  <bruno@clisp.org>
14957
14958         * gnulib-tool (import): In the other first-use case, provide defaults
14959         as well.
14960
14961 2005-09-02  Bruno Haible  <bruno@clisp.org>
14962
14963         * config/srclist.txt: lib-link.m4 and lib-prefix.m4 currently have
14964         patches not yet found in the latest gettext release.
14965
14966 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
14967
14968         * lib/glob.c (GET_LOGIN_NAME_MAX): Renamed from LOGIN_NAME_MAX,
14969         to avoid a collision with bits/local_lim.h in glibc.
14970         All uses changed.  Problem reported by Dmitry V. Levin in
14971         <http://sources.redhat.com/bugzilla/show_bug.cgi?id=1060>.
14972
14973         * lib/regex_internal.c (build_wcs_upper_buffer): Fix portability
14974         bugs in int versus size_t comparisons.
14975         (re_string_context_at): Fix bug where the code assumed that
14976         Idx is signed.
14977
14978         Use bool where appropriate.
14979         * lib/regcomp.c (re_set_fastmap): ICASE arg is bool, not int.
14980         All callers changed.
14981         (calc_eclosure_iter): Likewise, for ROOT arg.
14982         (parse_bracket_element): Likewise, for ACCEPT_HYPHEN arg.
14983         (build_charclass_op): Likewise, for NON_MATCH arg.
14984         * lib/regex_internal.c (re_string_allocate, re_string_construct):
14985         (re_string_construct_common): Likewise, for ICASE arg.
14986         * lib/regexec.c (re_search_2_stub, re_search_stub):
14987         Likewise, for RET_LEN arg.
14988         (check_matching): Likewise, for FL_LONGEST_MATCH arg.
14989         (set_regs): Likewise, for FL_BACKTRACK arg.
14990         * lib/regcomp.c (re_compile_fastmap_iter, optimize_utf8):
14991         (duplicate_node_closure, calc_inveclosure, calc_eclosure):
14992         (calc_eclosure_iter, parse_bracket_exp):
14993         Use bool for internal variables that are booleans.
14994         * lib/regexec.c (re_search_internal, check_matching,
14995         proceed_next_node):
14996         (set_regs, build_sifted_states, sift_states_bkref):
14997         (check_arrival_add_next_nodes, check_arrival_expand_ecl_sub):
14998         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
14999         (find_collation_sequence_value):
15000         Likewise.
15001         * lib/regex_internal.c (re_node_set_insert, re_node_set_insert_last):
15002         (re_node_set_compare):
15003         Return bool, not int. All callers changed.
15004         * lib/regexec.c (check_halt_node_context, check_dst_limits):
15005         (build_trtable, check_node_accept): Likewise.
15006         * lib/regex_internal.h: Include stdbool.h.
15007
15008         Fix bugs uncovered when converting to bool.
15009         * lib/regcomp.c (calc_eclosure_iter): Check for storage allocation
15010         failure instead of charging ahead blindly.
15011         * lib/regex_internal.c (register_state): Likewise.
15012         * lib/regexec.c (re_search_2_stub): Use simpler method than boolean
15013         for freeing internal storage.
15014         (group_nodes_into_DFA_states): Use unsigned int, not int, for
15015         bitset pieces used as boolean, to avoid undefined behavior
15016         on hosts that do int overflow checking.
15017
15018 2005-09-01  Paul Eggert  <eggert@cs.ucla.edu>
15019
15020         * config/srclist.txt: Add glibc bugs 1285-1287.
15021
15022 2005-09-01  Jim Meyering  <jim@meyering.net>
15023
15024         * m4/lchown.m4: Require gl_FUNC_CHOWN, for the definition of
15025         CHOWN_MODIFIES_SYMLINK, which is used by lchown.c.
15026         Require gl_STAT_MACROS, too.
15027
15028 2005-09-01  Bruno Haible  <bruno@clisp.org>
15029
15030         * gnulib-tool (import): In the first-use case, provide defaults.
15031
15032 2005-09-01  Bruno Haible  <bruno@clisp.org>
15033
15034         * gnulib-tool (func_import): Remove the .tmp files.
15035
15036 2005-09-01  Bruno Haible  <bruno@clisp.org>
15037
15038         * gnulib-tool (func_import): Fix handling of symbolic links.
15039
15040 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15041
15042         On 64-bit hosts (where size_t is 64 bits and int is 32 bits), the
15043         old glibc regex code mishandles strings longer than 2**31 bytes.
15044         This patch fixes this when the regex code is used in gnulib
15045         (i.e., outside glibc).
15046
15047         This patch should not affect the use of the regex code inside
15048         glibc.  No doubt this problem also needs to be handled for glibc
15049         as well, but the result will be an incompatible change to the
15050         glibc ABI, and the old ABI will have to be supported too.  That
15051         can be the the subject for another patch.
15052
15053         * lib/regex.h (_REGEX_LARGE_OFFSETS): New feature-test macro,
15054         governing whether the rest of this patch is active.  By default,
15055         the macro is disabled and the patch has no effect.
15056         (regoff_t) [defined _REGEX_LARGE_OFFSETS]: Define to off_t, not int.
15057         (__re_idx_t, __re_size_t, __re_long_size_t): New types.
15058         (struct re_pattern_buffer, re_search, re_search_2, re_match):
15059         (re_match_2, re_set_registers): Use the new types.
15060         * lib/regex_internal.h (Idx, re_hashval_t): New types.
15061         (REG_MISSING, REG_ERROR, REG_VALID_INDEX, REG_VALID_NONZERO_INDEX):
15062         New macros.
15063         (re_node_set, re_charset_t, re_token_t, re_string_realloc_buffers):
15064         (re_string_context_at, bin_tree_t, re_dfastate_t):
15065         (struct re_state_table_entry, state_array_t, re_sub_match_last_t):
15066         (re_sub_match_top_t, re_match_context_t, re_sift_context_t):
15067         (struct re_fail_stack_ent_t, struct re_fail_stack_t, struct re_dfa_t):
15068         (re_string_char_size_at, re_string_wchar_at):
15069         (re_string_elem_size_at):
15070         Use the new types and macros to port to 64-bit hosts.
15071         Use unsigned types for internal values, so that the code
15072         mostly works even for arrays larger than SSIZE_MAX.
15073         * lib/regcomp.c (re_compile_internal, init_dfa, duplicate_node):
15074         (search_duplicated_node, calc_eclosure_iter, fetch_number):
15075         (parse_reg_exp, parse_branch, parse_expression, parse_sub_exp):
15076         (build_equiv_class, build_charclass, re_compile_fastmap_iter):
15077         (free_dfa_content, create_initial_state, optimize_utf8, analyze):
15078         (optimize_subexps, calc_first, link_nfa_nodes, duplicate_node_closure):
15079         (calc_inveclosure, parse_dup_op, build_range_exp):
15080         (build_collating_symbol, parse_bracket_exp, build_charclass_op):
15081         (fetch_number, create_token_tree, mark_opt_subexp):
15082         Likewise.
15083         * lib/regex_internal.c (re_string_construct_common,
15084         create_ci_newstate):
15085         (create_cd_newstate, re_string_allocate, re_string_construct):
15086         (re_string_realloc_buffers, build_wcs_upper_buffer):
15087         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
15088         (re_string_reconstruct, re_string_peek_byte_case):
15089         (re_string_fetch_byte_case, re_string_context_at):
15090         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
15091         (re_node_set_init_copy, re_node_set_add_intersect):
15092         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15093         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15094         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
15095         (re_acquire_state, re_acquire_state_context, register_state):
15096         Likewise.
15097         * lib/regex.c (match_ctx_init, match_ctx_add_entry,
15098         search_cur_bkref_entry):
15099         (match_ctx_add_subtop, match_ctx_add_sublast, sift_ctx_init):
15100         (re_search_internal, re_search_2_stub, re_search_stub)
15101         (re_copy_regs, check_matching, check_halt_state_context, update_regs):
15102         (push_fail_stack, sift_states_iter_mb, build_sifted_states):
15103         (update_cur_sifted_state, check_dst_limits):
15104         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
15105         (check_subexp_limits, sift_states_bkref, merge_state_array):
15106         (check_subexp_matching_top, get_subexp, get_subexp_sub):
15107         (find_subexp_node, check_arrival, check_arrival_add_next_nodes):
15108         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
15109         (expand_bkref_cache, check_node_accept_bytes):
15110         (group_nodes_into_DFAstates, check_node_accept, regexec, re_match):
15111         (re_search, re_match_2, re_search_2, prune_impossible_nodes):
15112         (acquire_init_state_context, check_halt_node_context):
15113         (proceed_next_node, pop_fail_stack, set_regs, free_fail_stack_return):
15114         (sift_states_backward, clean_state_log_if_needed):
15115         (sub_epsilon_src_nodes, add_epsilone_src_nodes, merge_state_with_log):
15116         (find_recover_state, transit_state_sb, transit_state_mb):
15117         (transit_state_bkref, build_trtable, match_ctx_clean):
15118         Likewise.
15119         * lib/regcomp.c (parse_dup_op): Add an extra test if Idx is unsigned,
15120         to work around an assumption that REG_MISSING is negative.
15121
15122         * lib/regcomp.c (re_comp) [defined _REGEX_RE_COMP || defined _LIBC]:
15123         (seek_collating_symbol_entry) [defined _LIBC]:
15124         (lookup_collation_sequence_value) [defined _LIBC]:
15125         (build_range_exp, build_collating_symbol) [defined _LIBC]:
15126         Use prototypes rather than old-style function definitions.
15127         * lib/regexec.c (re_exec) [defined _REGEX_RE_COMP || defined _LIBC]:
15128         (transit_state_sb) [0]:
15129         (find_collation_sequence_value) [defined _LIBC]: Likewise.
15130
15131         * lib/regexec.c (re_search_internal): Simplify update of rm_so and
15132         rm_eo.
15133
15134         * lib/regcomp.c (re_compile_fastmap_iter, init_dfa, init_word_char):
15135         (optimize_subexps, lower_subexp):
15136         Don't assume 1<<31 has defined behavior on hosts with 32-bit int,
15137         since the signed shift might overflow.  Use 1u<<31 instead.
15138         * lib/regex_internal.h (bitset_set, bitset_clear, bitset_contain):
15139         Likewise.
15140         * lib/regexec.c (check_dst_limits_calc_pos_1,
15141         check_subexp_matching_top): Likewise.
15142
15143         * lib/regcomp.c (optimize_subexps, lower_subexp):
15144         Use CHAR_BIT rather than 8, for clarity.
15145         * lib/regexec.c (check_dst_limits_calc_pos_1):
15146         (check_subexp_matching_top): Likewise.
15147         * lib/regcomp.c (init_dfa): Make table_size unsigned, so that we don't
15148         have to worry about portability issues when shifting it left.
15149         Remove no-longer-needed test for table_size > 0.
15150         * lib/regcomp.c (parse_sub_exp): Do not shift more bits than there are
15151         in a word, as the resulting behavior is undefined.
15152         * lib/regexec.c (check_dst_limits_calc_pos_1): Likewise;
15153         in one case, a <= should have been an <, and in another case the
15154         whole test was missing.
15155         * lib/regex_internal.h (BYTE_BITS): Remove.  All uses changed to
15156         the standard name CHAR_BIT.
15157         * lib/regexec.c (match_ctx_add_entry): Don't assume that ~0 == -1;
15158         this is not true on one's complement and signed-magnitude hosts.
15159
15160         * lib/regex_internal.h (re_sub_match_top_t): Remove unused member
15161         next_last_offset.
15162         (struct re_dfa_t): Remove unused member states_alloc.
15163         * lib/regcomp.c (init_dfa): Don't initialize unused members.
15164
15165 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15166
15167         * m4/regex.m4 (gl_REGEX): Require AC_SYS_LARGEFILE, Define
15168         _REGEX_LARGE_OFFSETS).  Test for regoff_t/off_t bug in 64-bit
15169         and large-file glibc and in 32-bit large-file Solaris.
15170
15171 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15172
15173         * lib/regex_internal.c (re_string_reconstruct): Don't assume buffer
15174         lengths fit in regoff_t; this isn't true if regoff_t is the same
15175         width as size_t.
15176         * lib/regex.c (re_search_internal): 5th arg is LAST_START
15177         (= START + RANGE) instead of RANGE.  This avoids overflow
15178         problems when regoff_t is the same width as size_t.
15179         All callers changed.
15180         (re_search_2_stub): Check for overflow when adding the
15181         sizes of the two strings.
15182         (re_search_stub): Check for overflow when adding START
15183         to RANGE; if it occurs, substitute the extreme value.
15184
15185 2005-08-31  Paul Eggert  <eggert@cs.ucla.edu>
15186
15187         * config/srclist.txt: Add glibc bugs 1273, 1278-1282, 1284.
15188
15189 2005-08-31  Jim Meyering  <jim@meyering.net>
15190
15191         * lib/regcomp.c (search_duplicated_node): Make first pointer arg
15192         a pointer-to-const.
15193         * lib/regex_internal.c (create_ci_newstate, create_cd_newstate):
15194         (register_state): Likewise.
15195         * lib/regexec.c (search_cur_bkref_entry, check_dst_limits):
15196         (check_dst_limits_calc_pos_1, check_dst_limits_calc_pos):
15197         (group_nodes_into_DFAstates): Likewise.
15198
15199 2005-08-31  Jim Meyering  <jim@meyering.net>
15200
15201         * check-module: Add a FIXME comment.
15202
15203 2005-08-31  Eric Blake  <ebb9@byu.net>
15204
15205         * modules/unistd-safer (Files): Add unistd--.h.
15206         * modules/stdio-safer (Files): Add stdio--.h.
15207
15208 2005-08-31  Derek Price  <derek@ximbiot.com>
15209
15210         * lib/getdelim.c (getdelim): Return EOF on EOF.
15211         Reported by Larry Jones <lawrence.jones@ugs.com>.
15212
15213 2005-08-31  Bruno Haible  <bruno@clisp.org>
15214
15215         Avoid unnecessary diffs in the generated lib/Makefile.am.
15216         * gnulib-tool (func_emit_lib_Makefile_am): Don't write the cmd into
15217         the generated files.
15218         (func_import): Don't set cmd.
15219
15220 2005-08-31  Bruno Haible  <bruno@clisp.org>
15221
15222         * lib/strstr.c: Include <stddef.h>, for NULL.
15223         * lib/strcasestr.c: Likewise.
15224         Reported by Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
15225
15226 2005-08-31  Bruno Haible  <bruno@clisp.org>
15227
15228         * gnulib-tool: New option --macro-prefix.
15229         (func_import): Use macro_prefix.
15230         (import): Handle option --macro-prefix.
15231
15232 2005-08-31  Bruno Haible  <bruno@clisp.org>
15233
15234         * gnulib-tool (import): Rename most ac_* variables to cached_*.
15235         Also use new variables cached_lgpl, cached_libtool.
15236
15237 2005-08-31  Bruno Haible  <bruno@clisp.org>
15238
15239         * gnulib-tool (func_import): Require AC_GNU_SOURCE etc. instead of
15240         always instantiating them.
15241
15242 2005-08-31  Bruno Haible  <bruno@clisp.org>
15243
15244         * gnulib-tool (func_import): Read the previous cached settings
15245         from gnulib-cache.m4 and gnulib-comp.m4. Remove files that were
15246         earlier added by gnulib but are now dropped. Warn when a gnulib file
15247         overwrites a non-gnulib file.
15248
15249 2005-08-31  Bruno Haible  <bruno@clisp.org>
15250
15251         * gnulib-tool (func_import): Generate two files gnulib-cache.m4 and
15252         gnulib-comp.m4 instead of a single gnulib.m4, to make it easy for
15253         projects that don't keep autogenerated files in CVS. Put into
15254         actioncmd only the specified modules, not the transitive closure.
15255
15256 2005-08-31  Bruno Haible  <bruno@clisp.org>
15257
15258         * gnulib-tool (func_import): Fix defaulting of $libname and $libtool.
15259         Create directories that shall be filled.
15260         (import): Don't look for gl_* macros in configure.ac. Recurse across
15261         all directories containing a gnulib-cache.m4 files, if meaningful.
15262
15263 2005-08-31  Bruno Haible  <bruno@clisp.org>
15264
15265         * gnulib-tool (func_import): Emit also a stub for gl_LIBTOOL.
15266         (import): Set seen_libtool when we see gl_LIBTOOL.
15267
15268 2005-08-31  Bruno Haible  <bruno@clisp.org>
15269
15270         * gnulib-tool (func_import): Also copy m4/gnulib-tool.m4. Omit
15271         declaration macro definitions from generated gnulib.m4.
15272
15273 2005-08-30  Oskar Liljeblad  <oskar@osk.mine.nu>
15274
15275         * lib/iconvme.h: Add prototype for iconv_alloc.
15276
15277 2005-08-29  Simon Josefsson  <jas@extundo.com>
15278
15279         * lib/iconvme.c: Fix errno.
15280
15281 2005-08-29  Bruno Haible  <bruno@clisp.org>
15282
15283         * gnulib-tool: Enclose all occurrences of $destdir in "...", so
15284         that it works when the directory contains spaces.
15285
15286 2005-08-29  Bruno Haible  <bruno@clisp.org>
15287
15288         * gnulib-tool (import): Avoid unnecessary spaces in $avoidlist.
15289
15290 2005-08-29  Bruno Haible  <bruno@clisp.org>
15291
15292         * gnulib-tool (func_import): Emit more comments into gnulib.m4.
15293         Emit more advice.
15294
15295 2005-08-29  Bruno Haible  <bruno@clisp.org>
15296         and Stepan Kasal  <kasal@ucw.cz>
15297
15298         * check-module: If more parameters are given, check each of them
15299         separately; add more exceptions, as noted by Jim Meyering.
15300         (check_module): New procedure.
15301         (%exempt_header): Now contains all exceptions.
15302
15303 2005-08-29  Ben Pfaff  <blp@cs.stanford.edu>
15304
15305         * modules/byteswap (Makefile.am): Fix rule to not assume GNU make.
15306
15307 2005-08-29  Oskar Liljeblad  <oskar@osk.mine.nu>
15308
15309         * lib/iconvme.c: Split iconv_string into iconv_alloc.
15310
15311 2005-08-28  Bruno Haible  <bruno@clisp.org>
15312
15313         * m4/gnulib-tool.m4: New file.
15314
15315 2005-08-27  Jim Meyering  <jim@meyering.net>
15316
15317         * modules/unistd-safer (Files): Add pipe-safer.c.
15318         * modules/fcntl-safer (Files): Add creat-safer.c.
15319
15320 2005-08-27  Jim Meyering  <jim@meyering.net>
15321
15322         * m4/stdlib-safer.m4: New file.  From coreutils.
15323         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Add stdio--.h.
15324         * m4/fcntl-safer.m4 (gl_FCNTL_SAFER): Add creat-safer.c to the
15325         AC_LIBSOURCES list and arrange to compile it via AC_LIBOBJ.
15326         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise, add pipe-safer.c.
15327         Add pipe-safer.c and unistd--.h to the AC_LIBSOURCES list.
15328
15329 2005-08-27  Jim Meyering  <jim@meyering.net>
15330
15331         * lib/fopen-safer.c: Merge minor changes from coreutils.
15332         * lib/dup-safer.c: Likewise.
15333         * lib/fd-safer.c: Likewise.
15334
15335         Merge from coreutils.
15336         * lib/stdio--.h: New file.
15337         * lib/stdlib--.h: New file.
15338         * lib/mkstemp-safer.c: New file.
15339
15340         GNU tar needs these.
15341         * lib/pipe-safer.c: New file.
15342         * lib/creat-safer.c: New file.
15343         * lib/fcntl--.h (creat): Define to creat_safer.
15344         * lib/fcntl-safer.h: Include <sys/types.h> and declare creat_safer.
15345         * lib/unistd--.h (pipe): Define to pipe_safer.
15346         * lib/unistd-safer.h: Declare pipe_safer.
15347
15348 2005-08-26  Simon Josefsson  <jas@extundo.com>
15349
15350         * lib/getpass.c: Use _WIN32 instead of WIN32, suggested by Bruno
15351         Haible <bruno@clisp.org>.
15352
15353 2005-08-26  Paul Eggert  <eggert@cs.ucla.edu>
15354
15355         * lib/regex_internal.h: Remove all references to
15356         RE_NO_INTERNAL_PROTOTYPES; no longer neeeded now that we assume C89
15357         or better.
15358         (bitset_not, bitset_merge, bitset_not_merge):
15359         (bitset_mask, re_string_allocate, re_string_construct):
15360         (re_string_reconstruct, re_string_destruct, re_string_elem_size_at):
15361         (re_string_char_size_at, re_string_wchar_at, re_string_peek_byte_case):
15362         (re_string_fetch_byte_case, re_node_set_alloc, re_node_set_init_1):
15363         (re_node_set_init_2, re_node_set_init_copy, re_node_set_add_intersect):
15364         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15365         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15366         (re_node_set_remove_at, re_dfa_add_node, re_acquire_state):
15367         (re_acquire_state_context):
15368         Remove unnecessary forward decls.
15369         (re_string_char_size_at, re_string_wchar_at, re_string_elem_size_at):
15370         Put __attribute at function definition,
15371         now that the function decl has been removed.
15372         * lib/regex_internal.c (re_string_peek_byte_case):
15373         (re_string_fetch_byte_case, re_node_set_compare, re_node_set_contains):
15374         Likewise.
15375
15376 2005-08-25  Stepan Kasal  <kasal@ucw.cz>
15377
15378         * m4/regex.m4: Add AC_PREREQ(2.50).
15379         (gl_REGEX): If --with-included-regex was given, skip the autodetection.
15380
15381 2005-08-25  Simon Josefsson  <jas@extundo.com>
15382
15383         * m4/getpass.m4: Check for termios.h, tcgetattr, tcsetattr, and
15384         __fsetlocking.
15385
15386 2005-08-25  Simon Josefsson  <jas@extundo.com>
15387
15388         * lib/getpass.c: Add WIN32 implementation.  Conditionalize use of
15389         termios.h, tcgetattr, tcsetattr and __fsetlocking.  Remove some
15390         GLIBC specific code.
15391
15392 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15393
15394         Make regex safe for g++.  This fixes one real bug (an "err"
15395         that should have been "*err").  g++ problem reported by
15396         Sam Steingold.
15397         * lib/regex_internal.h (re_calloc): New macro, consistent with
15398         re_malloc etc.  All callers of calloc changed to use re_calloc.
15399         * lib/regex_internal.c (build_wcs_upper_buffer): Return reg_errcode_t,
15400         not int.  All callers changed.
15401         * lib/regcomp.c (re_compile_fastmap_iter): Don't use
15402         alloca (mb_cur_max); just use an array of size MB_LEN_MAX.
15403         * lib/regexec.c (push_fail_stack): Use re_realloc, not realloc.
15404         (find_recover_state): Change "err" to "*err"; this fixes what
15405         appears to be a real bug.
15406         (check_arrival_expand_ecl_sub): Be consistent about reg_errcode_t
15407         versus int.
15408
15409 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15410
15411         * modules/regex (Depends-on): Add malloc, since the code
15412         assumes that !malloc(0) means failure.
15413
15414 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15415
15416         * lib/regexec.c (set_regs): Don't alloca with an unbounded size.
15417
15418         alloca modernization/simplification for regex.
15419         * lib/regex.c: Remove portability cruft for alloca.  This no longer
15420         needs to be at the start of the file, and can be moved into
15421         regex_internal.h and simplified.
15422         * lib/regex_internal.h: Include <alloca.h>.
15423         (__libc_use_alloca) [!defined _LIBC]: New macro.
15424         * lib/regexec.c (build_trtable): Remove "#ifdef _LIBC", since the code
15425         now works outside glibc.
15426
15427 2005-08-25  Paul Eggert  <eggert@cs.ucla.edu>
15428
15429         * config/srclist.txt: Add glibc bugs 1241, 1245.
15430
15431 2005-08-25  Jim Meyering  <jim@meyering.net>
15432
15433         * lib/open-safer.c: Include <config.h>.
15434         Otherwise, we'd lose LARGEFILE support in any file using
15435         e.g. "fcntl--.h"
15436
15437 2005-08-25  Bruno Haible  <bruno@clisp.org>
15438
15439         * m4/minmax.m4: Require autoconf 2.52.
15440         (gl_MINMAX_IN_HEADER): Add comments. Use m4_pushdef/m4_popdef instead
15441         of define/undefine. Use AS_TR_SH and AS_TR_CPP as more robust
15442         alternatives of translit over the alphabet.
15443         Based on a patch from Stepan Kasal <kasal@ucw.cz>.
15444
15445 2005-08-24  Simon Josefsson  <jas@extundo.com>
15446
15447         * tests/test-getpass.c: New file.
15448
15449 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15450
15451         * m4/regex.m4 (gl_REGEX): Use POSIX-compliant spellings when testing
15452         for GNU regex features.
15453
15454 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15455
15456         * lib/regcomp.c (regerror): 2nd arg is 'restrict', as per POSIX.
15457         * lib/regex.h (regerror): Likewise.
15458
15459         * lib/regex.c: Do not include <sys/types.h>, as POSIX no longer
15460         requires this.  (The code never needed it.)
15461
15462         * lib/regcomp.c, regex_internal.c, regex_internal.h, regexec.c:
15463         All uses of recently-renamed identifiers changed to use the new,
15464         POSIX-compliant names.  The code will build and run just fine
15465         without these changes, but it's better to eat our own dog food
15466         and use the standard-conforming names.
15467
15468         * lib/regex.h: Fix a multitude of POSIX name space violations.
15469         These changes have an effect only for programs that define
15470         _POSIX_C_SOURCE, _POSIX_SOURCE, or _XOPEN_SOURCE; they
15471         do not change anything for programs compiled in the normal way.
15472         Also, there is no effect on the ABI.
15473
15474         (_REGEX_SOURCE): New macro.
15475         Do not include <stddef.h> if _XOPEN_SOURCE and VMS are both
15476         defined and _GNU_SOURCE is not; this fixes a name space violation.
15477
15478         Rename the following macros to obey POSIX requirements.
15479         The old names are still visible as macros if _REGEX_SOURCE is defined.
15480         (REG_BACKSLASH_ESCAPE_IN_LISTS): renamed from
15481         RE_BACKSLASH_ESCAPE_IN_LISTS.
15482         (REG_BK_PLUS_QM): renamed from RE_BK_PLUS_QM.
15483         (REG_CHAR_CLASSES): renamed from RE_CHAR_CLASSES.
15484         (REG_CONTEXT_INDEP_ANCHORS): renamed from RE_CONTEXT_INDEP_ANCHORS.
15485         (REG_CONTEXT_INDEP_OPS): renamed from RE_CONTEXT_INDEP_OPS.
15486         (REG_CONTEXT_INVALID_OPS): renamed from RE_CONTEXT_INVALID_OPS.
15487         (REG_DOT_NEWLINE): renamed from RE_DOT_NEWLINE.
15488         (REG_DOT_NOT_NULL): renamed from RE_DOT_NOT_NULL.
15489         (REG_HAT_LISTS_NOT_NEWLINE): renamed from RE_HAT_LISTS_NOT_NEWLINE.
15490         (REG_INTERVALS): renamed from RE_INTERVALS.
15491         (REG_LIMITED_OPS): renamed from RE_LIMITED_OPS.
15492         (REG_NEWLINE_ALT): renamed from RE_NEWLINE_ALT.
15493         (REG_NO_BK_BRACES): renamed from RE_NO_BK_BRACES.
15494         (REG_NO_BK_PARENS): renamed from RE_NO_BK_PARENS.
15495         (REG_NO_BK_REFS): renamed from RE_NO_BK_REFS.
15496         (REG_NO_BK_VBAR): renamed from RE_NO_BK_VBAR.
15497         (REG_NO_EMPTY_RANGES): renamed from RE_NO_EMPTY_RANGES.
15498         (REG_UNMATCHED_RIGHT_PAREN_ORD): renamed from
15499         RE_UNMATCHED_RIGHT_PAREN_ORD.
15500         (REG_NO_POSIX_BACKTRACKING): renamed from RE_NO_POSIX_BACKTRACKING.
15501         (REG_NO_GNU_OPS): renamed from RE_NO_GNU_OPS.
15502         (REG_DEBUG): renamed from RE_DEBUG.
15503         (REG_INVALID_INTERVAL_ORD): renamed from RE_INVALID_INTERVAL_ORD.
15504         (REG_IGNORE_CASE): renamed from RE_ICASE.  This renaming is a bit
15505         unusual, since we can't clash with the POSIX REG_ICASE.
15506         (REG_CARET_ANCHORS_HERE): renamed from RE_CARET_ANCHORS_HERE.
15507         (REG_CONTEXT_INVALID_DUP): renamed from RE_CONTEXT_INVALID_DUP.
15508         (REG_NO_SUB): renamed from RE_NO_SUB.
15509         (REG_SYNTAX_EMACS): renamed from RE_SYNTAX_EMACS.
15510         (REG_SYNTAX_AWK): renamed from RE_SYNTAX_AWK.
15511         (REG_SYNTAX_GNU_AWK): renamed from RE_SYNTAX_GNU_AWK.
15512         (REG_SYNTAX_POSIX_AWK): renamed from RE_SYNTAX_POSIX_AWK.
15513         (REG_SYNTAX_GREP): renamed from RE_SYNTAX_GREP.
15514         (REG_SYNTAX_EGREP): renamed from RE_SYNTAX_EGREP.
15515         (REG_SYNTAX_POSIX_EGREP): renamed from RE_SYNTAX_POSIX_EGREP.
15516         (REG_SYNTAX_ED): renamed from RE_SYNTAX_ED.
15517         (REG_SYNTAX_SED): renamed from RE_SYNTAX_SED.
15518         (_REG_SYNTAX_POSIX_COMMON): renamed from _RE_SYNTAX_POSIX_COMMON.
15519         (REG_SYNTAX_POSIX_BASIC): renamed from RE_SYNTAX_POSIX_BASIC.
15520         (REG_SYNTAX_POSIX_MINIMAL_BASIC): renamed from
15521         RE_SYNTAX_POSIX_MINIMAL_BASIC.
15522         (REG_SYNTAX_POSIX_EXTENDED): renamed from RE_SYNTAX_POSIX_EXTENDED.
15523         (REG_SYNTAX_POSIX_MINIMAL_EXTENDED): renamed from
15524         RE_SYNTAX_POSIX_MINIMAL_EXTENDED.
15525         (REG_DUP_MAX): renamed from RE_DUP_MAX.  No need to undef it.
15526         (REG_UNALLOCATED): Renamed from REGS_UNALLOCATED.
15527         (REG_REALLOCATE): Renamed from REGS_REALLOCATE.
15528         (REG_FIXED): Renamed from REGS_FIXED.
15529         (REG_NREGS): Renamed from RE_NREGS.
15530
15531         (REG_ICASE, REG_NEWLINE, REG_NOSUB): Do not depend on the values
15532         of other REG_* macros, since POSIX says the user is allowed to
15533         #undef these macros selectively.
15534
15535         (reg_errcode_t): Update comment stating what other tables need
15536         to be consistent.
15537
15538         Rename the following enum values to obey POSIX requirements.
15539         The old names are still visible as macros.
15540         (_REG_ENOSYS): Renamed from REG_ENOSYS.  Define even if _XOPEN_SOURCE
15541         is not defined, since GNU is supposed to be a superset of POSIX as
15542         much as possible, and since we want reg_errcode_t to be a signed
15543         type for implementation consistency.
15544         (_REG_NOERROR): Renamed from REG_NOERROR.
15545         (_REG_NOMATCH): Renamed from REG_NOMATCH.
15546         (_REG_BADPAT): Renamed from REG_BADPAT.
15547         (_REG_ECOLLATE): Renamed from REG_ECOLLATE.
15548         (_REG_ECTYPE): Renamed from REG_ECTYPE.
15549         (_REG_EESCAPE): Renamed from REG_EESCAPE.
15550         (_REG_ESUBREG): Renamed from REG_ESUBREG.
15551         (_REG_EBRACK): Renamed from REG_EBRACK.
15552         (_REG_EPAREN): Renamed from REG_EPAREN.
15553         (_REG_EBRACE): Renamed from REG_EBRACE.
15554         (_REG_BADBR): Renamed from REG_BADBR.
15555         (_REG_ERANGE): Renamed from REG_ERANGE.
15556         (_REG_ESPACE): Renamed from REG_ESPACE.
15557         (_REG_BADRPT): Renamed from REG_BADRPT.
15558         (_REG_EEND): Renamed from REG_EEND.
15559         (_REG_ESIZE): Renamed from REG_ESIZE.
15560         (_REG_ERPAREN): Renamed from REG_ERPAREN.
15561         (REG_ENOSYS, REG_NOERROR, REG_NOMATCH, REG_BADPAT, REG_ECOLLATE):
15562         (REG_ECTYPE, REG_EESCAPE, REG_ESUBREG, REG_EBRACK, REG_EPAREN):
15563         (REG_EBRACE, REG_BADBR, REG_ERANGE, REG_ESPACE, REG_BADRPT, REG_EEND):
15564         (REG_ESIZE, REG_ERPAREN): Now macros, not enum constants.
15565
15566         (_REG_RE_NAME, _REG_RM_NAME): New macros.
15567         (REG_TRANSLATE_TYPE): Renamed from RE_TRANSLATE_TYPE.  All uses
15568         changed.  But support the old name if the new one is not defined
15569         and if _REGEX_SOURCE.
15570
15571         Change the following member names in struct re_pattern_buffer.
15572         The old names are still supported if !_REGEX_SOURCE.
15573         The new names are always supported, regardless of _REGEX_SOURCE.
15574         (re_buffer): Renamed from buffer.
15575         (re_allocated): Renamed from allocated.
15576         (re_used): Renamed from used.
15577         (re_syntax): Renamed from syntax.
15578         (re_fastmap): Renamed from fastmap.
15579         (re_translate): Renamed from translate.
15580         (re_can_be_null): Renamed from can_be_null.
15581         (re_regs_allocated): Renamed from regs_allocated.
15582         (re_fastmap_accurate): Renamed from fastmap_accurate.
15583         (re_no_sub): Renamed from no_sub.
15584         (re_not_bol): Renamed from not_bol.
15585         (re_not_eol): Renamed from not_eol.
15586         (re_newline_anchor): Renamed from newline_anchor.
15587
15588         Change the following member names in struct re_registers.
15589         The old names are still supported if !_REGEX_SOURCE.
15590         The new names are always supported, regardless of _REGEX_SOURCE.
15591         (rm_num_regs): Renamed from num_regs.
15592         (rm_start): Renamed from start.
15593         (rm_end): Renamed from end.
15594
15595         (re_set_syntax, re_compile_pattern, re_compile_fastmap):
15596         (re_search, re_search_2, re_match, re_match_2, re_set_registers):
15597         Prepend __ to parameter names.
15598
15599         Undo yesterday's changes.
15600
15601 2005-08-24  Paul Eggert  <eggert@cs.ucla.edu>
15602
15603         * config/srclist.txt: Remove glibc bug 1233 and add 1236, which
15604         supersedes it. Add glibc bugs 1237, 1238, 1240.  Comment out
15605         lib/regex.c.
15606
15607 2005-08-24  Jim Meyering  <jim@meyering.net>
15608
15609         Sync from coreutils.
15610         * m4/fcntl-safer.m4: New file.
15611
15612         * m4/xgetcwd.m4: Use AC_LIBSOURCES and AC_LIBOBJ to indicate source
15613         and object files for this module.
15614
15615 2005-08-24  Jim Meyering  <jim@meyering.net>
15616
15617         Sync from coreutils.
15618         * lib/fcntl--.h, lib/fcntl-safer.h, lib/open-safer.c: New files.
15619
15620 2005-08-24  Jim Meyering  <jim@meyering.net>
15621
15622         * modules/xgetcwd (Makefile.am): Remove `lib_SOURCES += ...' line,
15623         now that xgetcwd.m4 requires xgetcwd.c and xgetcwd.h.
15624
15625 2005-08-24  Jim Meyering  <jim@meyering.net>
15626
15627         * modules/fcntl-safer: New module.
15628         * modules/fts (Depends-on): Add fcntl-safer.
15629         * MODULES.html.sh (File descriptor based Input/Output):
15630         Add fcntl-safer.
15631
15632 2005-08-24  Bruno Haible  <bruno@clisp.org>
15633
15634         Support for unit test modules.
15635         * modules/README: Mention tests modules.
15636         * modules/TEMPLATE-TESTS: New file.
15637         * gnulib-tool: New options --extract-tests-module, --with-tests and
15638         --tests-base (unused for the moment).
15639         (testsbase, inctests): New variables.
15640         (func_all_modules): Exclude TEMPLATE-TESTS and *-tests.
15641         (func_verify_module): Exclude TEMPLATE-TESTS.
15642         (func_verify_nontests_module, func_verify_tests_module): New functions.
15643         (func_get_dependencies): Add implicit dependency for tests modules.
15644         (func_get_tests_module): New function.
15645         (func_modules_transitive_closure): When --with-tests was specified,
15646         include the unit tests as well, unless explicitly avoided.
15647         (func_emit_lib_Makefile_am): Ignore the tests modules here.
15648         (func_emit_tests_Makefile_am): New function.
15649         (func_create_testdir): When --with-tests was specified, emit a
15650         tests/ directory.
15651         * MODULES.html.sh (Future developments): Update.
15652
15653 2005-08-24  Bruno Haible  <bruno@clisp.org>
15654
15655         * modules/tls-tests: New file.
15656         * tests/test-tls.c: New file, from GNU gettext.
15657
15658 2005-08-24  Bruno Haible  <bruno@clisp.org>
15659
15660         * modules/lock-tests: New file.
15661         * tests/test-lock.c: New file, from GNU gettext.
15662
15663 2005-08-24  Bruno Haible  <bruno@clisp.org>
15664
15665         * lib/lock.h: Add multiple inclusion guard.
15666         * lib/tls.h: Add multiple inclusion guard.
15667
15668 2005-08-24  Bruno Haible  <bruno@clisp.org>
15669
15670         * gnulib-tool: Add support for the --aux-dir option to
15671         --create-testdir, --create-megatestdir, --test, --megatest.
15672         (func_create_testdir, func_create_megatestdir): Optionally emit a
15673         AC_CONFIG_AUX_DIR directive.
15674         (create-testdir, create-megatestdir, test, megatest): Provide a
15675         default value for $auxdir.
15676
15677 2005-08-24  Bruno Haible  <bruno@clisp.org>
15678
15679         * gnulib-tool (import): Use compound statement instead of subshell
15680         where possible.
15681
15682 2005-08-24  Bruno Haible  <bruno@clisp.org>
15683
15684         * gnulib-tool (import): Change --aux-dir default to "build-aux".
15685
15686 2005-08-24  Bruno Haible  <bruno@clisp.org>
15687
15688         * gnulib-tool (func_version): Update.
15689
15690 2005-08-24  Bruno Haible  <bruno@clisp.org>
15691
15692         * gnulib-tool (func_import, func_create_testdir,
15693         func_create_megatestdir): Quote all autoconf macro arguments.
15694
15695 2005-08-24  Bruno Haible  <bruno@clisp.org>
15696
15697         * gnulib-tool (func_create_megatestdir): Call autoreconf without the
15698         option --force, because --force causes the aclocal.m4 of each
15699         subdirectory to be newer than the corresponding config.h.in.
15700
15701 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15702
15703         * m4/regex.m4 (gl_INCLUDED_REGEX): Remove; no longer used.
15704         All contents moved to gl_REGEX.
15705         (gl_REGEX): Don't bother checking whether lib/regex.c exists;
15706         assume that it does.
15707
15708 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15709
15710         * lib/regex.h (REG_NOSYS)
15711         [!defined _XOPEN_SOURCE && 200112L <= _POSIX_C_SOURCE]:
15712         Define, since POSIX requires it as of 2001.
15713         (_REG_ENOSYS)
15714         [! (defined _XOPEN_SOURCE || 200112L <= _POSIX_C_SOURCE)]:
15715         New private symbol, used to keep the enum signed in all cases.
15716         * lib/regex.h (RE_NO_EMPTY_RANGES): Fix doc bug reported by James
15717         Youngman in
15718         <http://lists.gnu.org/archive/html/bug-gnulib/2005-07/msg00132.html>.
15719
15720         * lib/regex_internal.c (re_string_skip_chars, register_state):
15721         (calc_state_hash):
15722         Remove forward decls; no longer needed now that we use prototypes.
15723         * lib/regexec.c (acquire_init_state_context, check_halt_node_context):
15724         (proceed_next_node, pop_fail_stack, sub_epsilon_src_nodes):
15725         (clean_state_log_if_needed): Likewise.
15726
15727 2005-08-23  Paul Eggert  <eggert@cs.ucla.edu>
15728
15729         * config/srclist.txt: Add glibc bugs 1231-1233.
15730
15731 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15732
15733         Fix problems reported by Sam Steingold in
15734         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00007.html>.
15735         * lib/regexec.c (sift_states_bkref): Fix portability bug: the code
15736         assumed that reg_errcode_t is a signed type, which is not
15737         necessarily true if _XOPEN_SOURCE is not defined.
15738         * lib/regex_internal.c (calc_state_hash): Put 'inline' before type,
15739         since some compilers warn about it otherwise.
15740
15741 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15742
15743         * lib/regcomp.c (create_initial_state): Remove duplicate decl.
15744         (init_word_char, create_initial_state, duplicate_node_closure):
15745         (fetch_token, peek_token_bracket, build_range_exp):
15746         (build_collating_symbol): Remove forward decls; no longer needed
15747         now that we use prototypes.
15748
15749         * lib/regcomp.c:
15750         (re_compile_pattern, re_set_syntax, re_compile_fastmap):
15751         (re_compile_fastmap_iter, regcomp, regerror, regfree):
15752         (re_compile_internal, init_dfa, init_word_char, free_workarea_compile):
15753         (create_initial_state, optimize_utf8, analyze, postorder, preorder):
15754         (optimize_subexps, lower_subexps, lower_subexp, calc_first, calc_next):
15755         (link_nfa_nodes, duplicate_node_closure, search_duplicated_node):
15756         (duplicate_node, calc_inveclosure, calc_eclosure, calc_eclosure_iter):
15757         (fetch_token, peek_token, peek_token_bracket, parse, parse_reg_exp):
15758         (parse_branch, parse_expression, parse_sub_exp, parse_dup_op):
15759         (build_range_exp, build_collating_symbol, parse_bracket_exp):
15760         (parse_bracket_element, parse_bracket_symbol, build_equiv_class):
15761         (build_charclass, build_charclass_op, fetch_number, create_tree):
15762         (create_token_tree, mark_opt_subexp, duplicate_tree):
15763         Use prototypes rather than old-style definitions.
15764
15765         * lib/regex_internal.c:
15766         (re_string_allocate, re_string_construct, re_string_realloc_buffers):
15767         (re_string_construct_common, build_wcs_buffer, build_wcs_upper_buffer):
15768         (re_string_skip_chars, build_upper_buffer, re_string_translate_buffer):
15769         (re_string_reconstruct, re_string_peek_byte_case):
15770         (re_string_fetch_byte_case, re_string_destruct, re_string_context_at):
15771         (re_node_set_alloc, re_node_set_init_1, re_node_set_init_2):
15772         (re_node_set_init_copy, re_node_set_add_intersect):
15773         (re_node_set_init_union, re_node_set_merge, re_node_set_insert):
15774         (re_node_set_insert_last, re_node_set_compare, re_node_set_contains):
15775         (re_node_set_remove_at, re_dfa_add_node, calc_state_hash):
15776         (re_acquire_state, re_acquire_state_context, register_state):
15777         (create_ci_newstate, create_cd_newstate, free_state):
15778         Likewise.
15779         * lib/regexec.c (regexec, re_match, re_search, re_match_2,
15780         re_search_2):
15781         (re_search_2_stub, re_search_stub, re_copy_regs, re_set_registers):
15782         (re_search_internal, prune_impossible_nodes):
15783         (acquire_init_state_context, check_matching, static):
15784         (check_halt_node_context, check_halt_state_context, proceed_next_node):
15785         (push_fail_stack, pop_fail_stack, set_regs, free_fail_stack_return):
15786         (update_regs, sift_states_backward, build_sifted_states):
15787         (clean_state_log_if_needed, merge_state_array):
15788         (update_cur_sifted_state, add_epsilon_src_nodes):
15789         (sub_epsilon_src_nodes, check_dst_limits, check_dst_limits_calc_pos_1):
15790         (check_dst_limits_calc_pos, check_subexp_limits, sift_states_bkref):
15791         (sift_states_iter_mb, transit_state, merge_state_with_log, static):
15792         (find_recover_state, check_subexp_matching_top, transit_state_mb):
15793         (transit_state_bkref, get_subexp, get_subexp_sub, find_subexp_node):
15794         (check_arrival, check_arrival_add_next_nodes):
15795         (check_arrival_expand_ecl, check_arrival_expand_ecl_sub):
15796         (expand_bkref_cache, build_trtable, group_nodes_into_DFAstates):
15797         (check_node_accept_bytes, check_node_accept, extend_buffers):
15798         (match_ctx_init, match_ctx_clean, match_ctx_free, match_ctx_add_entry):
15799         (search_cur_bkref_entry, match_ctx_add_subtop, match_ctx_add_sublast):
15800         (sift_ctx_init):
15801         Likewise.
15802
15803         * lib/regex_internal.h:
15804         (re_string_allocate, re_string_construct, re_string_reconstruct):
15805         (re_string_realloc_buffers, build_wcs_buffer, build_wcs_upper_buffer):
15806         (build_upper_buffer, re_string_translate_buffer, re_string_destruct):
15807         (re_string_elem_size_at, re_string_char_size_at, re_string_wchar_at):
15808         (re_string_context_at, re_string_peek_byte_case):
15809         (re_string_fetch_byte_case): Declare even if RE_NO_INTERNAL_PROTOTYPES
15810         is defined, since we now use prototypes always.
15811
15812         * lib/regex.h (_RE_ARGS): Remove.  No longer needed, since we assume
15813         C89 or better.  All uses removed.
15814
15815 2005-08-20  Paul Eggert  <eggert@cs.ucla.edu>
15816
15817         * config/srclist.txt: Add glibc bugs 1220-1227.
15818
15819 2005-08-20  Jim Meyering  <jim@meyering.net>
15820
15821         * lib/regexec.c (regexec, re_search_stub) [!_LIBC]: Omit declaration
15822         of unused local, dfa.
15823
15824 2005-08-20  Bruno Haible  <bruno@clisp.org>
15825
15826         * m4/regex.m4 (gl_PREREQ_REGEX): Require AC_GNU_SOURCE.
15827
15828 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15829
15830         * lib/regex_internal.c (re_string_realloc_buffers, re_node_set_insert):
15831         (re_node_set_insert_last, re_dfa_add_node):
15832         Rename local variables to avoid GCC shadowing warnings.
15833
15834 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15835
15836         * lib/regex_internal.c (re_acquire_state, re_acquire_state_context)
15837         [defined lint]: Suppress bogus uninitialized-variable warnings.
15838
15839         * lib/regcomp.c (duplicate_node): Return new index, not an error code,
15840         and let the caller return REG_ESPACE if out of space.  This
15841         removes an uninitialied-variable warning with GCC 4.0.1, and also
15842         avoids taking the address of a local variable.  All callers
15843         changed.
15844
15845 2005-08-19  Paul Eggert  <eggert@cs.ucla.edu>
15846
15847         * config/srclist.txt: Comment out $LIBCSRC/posix/regex_internal.c,
15848         $LIBCSRC/posix/regexec.c.
15849         Add glibc bug 1217 for regcomp.c.
15850
15851 2005-08-19  Jim Meyering  <jim@meyering.net>
15852
15853         * lib/regexec.c (proceed_next_node): Redo local variables to
15854         avoid GCC shadowing warnings.
15855
15856 2005-08-18  Bruno Haible  <bruno@clisp.org>
15857
15858         * lib/strstr.c (strstr): Fix return value in multibyte case.
15859         * lib/strcasestr.c (strcasestr): Likewise.
15860
15861 2005-08-17  Paul Eggert  <eggert@cs.ucla.edu>
15862
15863         * lib/regex.h: Remove useless space-before-tab.  From coreutils.
15864
15865 2005-08-17  Jim Meyering  <jim@meyering.net>
15866
15867         Make the %s format (seconds since the epoch) work for a negative
15868         number and when used with a zero-padded field width, e.g. %015s.
15869
15870         * lib/strftime.c (my_strftime): Move the `do_number_sign_and_padding'
15871         label so that it precedes the code to set `digits'.  Otherwise,
15872         %0Ns wouldn't work.  Before this change, `date -d @-22 +%05s' would
15873         print `00-22'.  Now, it prints `-0022', as it should.
15874
15875 2005-08-17  Bruno Haible  <bruno@clisp.org>
15876
15877         * modules/strstr (Files): Add m4/mbrtowc.m4.
15878         (Depends-on): Add mbuiter.
15879
15880 2005-08-17  Bruno Haible  <bruno@clisp.org>
15881
15882         * modules/strcasestr: New file.
15883         * MODULES.html.sh (String handling, based on ANSI C 89): Add
15884         strcasestr.
15885
15886 2005-08-17  Bruno Haible  <bruno@clisp.org>
15887
15888         * modules/strcase (Depends-on): Add mbuiter. Remove strnlen1, mbchar.
15889
15890 2005-08-17  Bruno Haible  <bruno@clisp.org>
15891
15892         * modules/mbuiter: New file.
15893         * MODULES.html.sh (Extended multibyte and wide character utilities):
15894         Add mbuiter.
15895
15896 2005-08-17  Bruno Haible  <bruno@clisp.org>
15897
15898         * m4/strstr.m4 (gl_FUNC_STRSTR): Use the replacement function always.
15899         (gl_PREREQ_STRSTR): Use gl_FUNC_MBRTOWC.
15900
15901 2005-08-17  Bruno Haible  <bruno@clisp.org>
15902
15903         * m4/strcasestr.m4: New file.
15904
15905 2005-08-17  Bruno Haible  <bruno@clisp.org>
15906
15907         * lib/strstr.h: Ignore HAVE_STRSTR, always declare the gnulib function.
15908         * lib/strstr.c: Completely rewritten, with multibyte locale support.
15909
15910 2005-08-17  Bruno Haible  <bruno@clisp.org>
15911
15912         * lib/strcasestr.h: New file.
15913         * lib/strcasestr.c: New file.
15914
15915 2005-08-17  Bruno Haible  <bruno@clisp.org>
15916
15917         * lib/strcasecmp.c: Use mbuiter.h.
15918
15919 2005-08-17  Bruno Haible  <bruno@clisp.org>
15920
15921         * lib/mbuiter.h: New file.
15922
15923 2005-08-16  Paul Eggert  <eggert@cs.ucla.edu>
15924
15925         * m4/getopt.m4 (gl_GETOPT_CHECK_HEADERS): Do not override the results
15926         of gl_GETOPT_SUBSTITUTE.  That way, if both gl_GETOPT_SUBSTITUTE
15927         and gl_GETOPT are both invoked via different paths (as happens
15928         with GNU tar CVS because it uses both argp and getopt), the former
15929         wins.
15930
15931 2005-08-16  Bruno Haible  <bruno@clisp.org>
15932
15933         * modules/tls: New file.
15934         * MODULES.html.sh (Multithreading): Add tls.
15935
15936 2005-08-16  Bruno Haible  <bruno@clisp.org>
15937
15938         * modules/strnlen1: New file.
15939         * MODULES.html.sh (String handling): Add strnlen1.
15940
15941 2005-08-16  Bruno Haible  <bruno@clisp.org>
15942
15943         * modules/strcase (Files): Add m4/mbrtowc.m4.
15944         (Depends-on): Add strnlen1, mbchar.
15945
15946 2005-08-16  Bruno Haible  <bruno@clisp.org>
15947
15948         * modules/mbiter: New file.
15949         * MODULES.html.sh (Extended multibyte and wide character utilities):
15950         Add mbiter.
15951
15952 2005-08-16  Bruno Haible  <bruno@clisp.org>
15953
15954         * modules/mbfile: New file.
15955         * MODULES.html.sh (Extended multibyte and wide character utilities):
15956         Add mbfile.
15957
15958 2005-08-16  Bruno Haible  <bruno@clisp.org>
15959
15960         * modules/mbchar: New file.
15961         * MODULES.html.sh (Extended multibyte and wide character utilities):
15962         New section.
15963
15964 2005-08-16  Bruno Haible  <bruno@clisp.org>
15965
15966         * m4/tls.m4: New file, from GNU gettext.
15967
15968 2005-08-16  Bruno Haible  <bruno@clisp.org>
15969
15970         * m4/strcase.m4 (gl_FUNC_STRCASECMP): Use the replacement function
15971         always.
15972         (gl_PREREQ_STRCASECMP): Use gl_FUNC_MBRTOWC.
15973
15974 2005-08-16  Bruno Haible  <bruno@clisp.org>
15975
15976         * m4/mbiter.m4: New file.
15977
15978 2005-08-16  Bruno Haible  <bruno@clisp.org>
15979
15980         * m4/mbfile.m4: New file.
15981
15982 2005-08-16  Bruno Haible  <bruno@clisp.org>
15983
15984         * m4/mbchar.m4: New file.
15985
15986 2005-08-16  Bruno Haible  <bruno@clisp.org>
15987
15988         * lib/tls.h: New file, from GNU gettext.
15989         * lib/tls.c: New file, from GNU gettext.
15990
15991 2005-08-16  Bruno Haible  <bruno@clisp.org>
15992
15993         * lib/strnlen1.h: New file.
15994         * lib/strnlen1.c: New file.
15995
15996 2005-08-16  Bruno Haible  <bruno@clisp.org>
15997
15998         * lib/strcasecmp.c (struct mbiter_multi): Remove at_end field.
15999         (mbi_init): Update.
16000         (mbi_avail, mbi_advance): Let the iteration end before the terminating
16001         NUL byte, not after it.
16002
16003 2005-08-16  Bruno Haible  <bruno@clisp.org>
16004
16005         * lib/strcase.h (strcasecmp): Add note in comments.
16006         * lib/strncasecmp.c: Use code from strcasecmp.c.
16007         * lib/strcasecmp.c: Use mbchar module. Define private mbiter variant.
16008         (strcasecmp): Work correctly in multibyte locales.
16009
16010 2005-08-16  Bruno Haible  <bruno@clisp.org>
16011
16012         * lib/mbiter.h: New file.
16013
16014 2005-08-16  Bruno Haible  <bruno@clisp.org>
16015
16016         * lib/mbfile.h: New file.
16017
16018 2005-08-16  Bruno Haible  <bruno@clisp.org>
16019
16020         * lib/mbchar.h: New file.
16021         * lib/mbchar.c: New file.
16022
16023 2005-08-16  Bruno Haible  <bruno@clisp.org>
16024
16025         * lib/mbchar.h (mb_cmp, mb_casecmp): Order the invalid characters after
16026         the valid ones. Makes the comparison operations transitive:
16027         cmp (a, b) < 0 && cmp (b, c) < 0 ==> cmp (a, c) < 0.
16028         * lib/strcasecmp.c (strcasecmp): Use mb_casecmp.
16029
16030 2005-08-15  Simon Josefsson  <jas@extundo.com>
16031
16032         * modules/ssize_t (License): Change to 'unlimited'.
16033
16034         * gnulib-tool (sed_extract_prog): Recognize 'unlimited' license.
16035
16036 2005-08-15  Paul Eggert  <eggert@cs.ucla.edu>
16037
16038         * config/srclist.txt: Comment out $LIBCSRC/posix/regex.h.
16039         Add comments for each pending glibc patch.
16040
16041 2005-08-15  Bruno Haible  <bruno@clisp.org>
16042
16043         * lib/regex.h (__restrict_arr): Don't define to __restrict if
16044         __cplusplus is defined.
16045
16046 2005-08-14  Jim Meyering  <jim@meyering.net>
16047
16048         Sync from coreutils.
16049
16050         * lib/fts-cycle.c (setup_dir, enter_dir, leave_dir, free_dir):
16051         Use the hash-table-based cycle-detection code not just when
16052         FTS_TIGHT_CYCLE_CHECK if specified, but also with FTS_LOGICAL.
16053         Reported by James Youngman in
16054         <http://lists.gnu.org/archive/html/bug-gnulib/2005-08/msg00011.html>.
16055         * lib/fts_.h: Mention that with FTS_LOGICAL, we use
16056         FTS_TIGHT_CYCLE_CHECK.
16057         * lib/fts.c (fts_cross_check) [FTS_DEBUG]:
16058         s/active_dir_ht/fts_cycle.ht/. This lets us compile with -DFTS_DEBUG,
16059         once again.
16060         * lib/fts.c [! _LIBC]: Include "lstat.h" rather than rolling our own.
16061         * lib/fts.c (fd_safer): Remove decl.
16062         Include fcntl--.h rather than unistd-safer.h
16063         (fts_safe_changedir): Don't call fd_safer; no longer needed
16064         now that we include fcntl--.h.
16065
16066 2005-08-12  Simon Josefsson  <jas@extundo.com>
16067
16068         * modules/getndelim2: Use ssize_t module.
16069         * modules/getnline: Likewise.
16070         * modules/safe-read: Likewise.
16071         * modules/xreadlink: Likewise.
16072
16073         * modules/ssize_t: New file.
16074
16075 2005-08-12  Simon Josefsson  <jas@extundo.com>
16076
16077         * m4/readline.m4: Look for termcap, curses or ncurses if required.
16078
16079 2005-08-12  Simon Josefsson  <jas@extundo.com>
16080
16081         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
16082         ssize_t.
16083
16084 2005-08-12  Simon Josefsson  <jas@extundo.com>
16085
16086         * MODULES.html.sh (Extra functions based on ANSI C 89: Misc): Add
16087         readline, getdelim and check_version.
16088         (Support for systems lacking ISO C 99: Sizes of integer types):
16089         Add size_max.
16090
16091 2005-08-12  Bruno Haible  <bruno@clisp.org>
16092
16093         * m4/readline.m4 (gl_FUNC_READLINE): Look for ncurses first.
16094
16095 2005-08-11  Simon Josefsson  <jas@extundo.com>
16096
16097         * modules/readline: New file.
16098
16099         * modules/strnlen (Files): Add strnlen.h.
16100
16101 2005-08-11  Simon Josefsson  <jas@extundo.com>
16102
16103         * m4/readline.m4: New file.
16104
16105 2005-08-11  Simon Josefsson  <jas@extundo.com>
16106
16107         * lib/readline.h, readline.c: New file.
16108
16109 2005-08-11  Simon Josefsson  <jas@extundo.com>
16110
16111         * doc/gnulib.texi (Initial import, Finishing touches): Mention
16112         gl_AVOID.
16113
16114 2005-08-11  Bruno Haible  <bruno@clisp.org>
16115
16116         * lib/strnlen.h (strnlen): Change parameter name to match comment.
16117
16118 2005-08-10  Stepan Kasal  <kasal@ucw.cz>
16119
16120         * m4/onceonly_2_57.m4: Really require Autoconf 2.57.
16121
16122 2005-08-10  Simon Josefsson  <jas@extundo.com>
16123
16124         * tests/test-iconvme.c: New file.
16125
16126 2005-08-10  Simon Josefsson  <jas@extundo.com>
16127
16128         * m4/strnlen.m4: New file.
16129
16130         * m4/strndup.m4: Don't check for strnlen declaration, done in
16131         strnlen.m4.
16132
16133 2005-08-10  Simon Josefsson  <jas@extundo.com>
16134
16135         * lib/strndup.c: Use strnlen.h.
16136
16137         * lib/strnlen.h: New file.
16138
16139 2005-08-08  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>  (tiny change)
16140
16141         * README: Typos.
16142
16143 2005-08-02  Simon Josefsson  <jas@extundo.com>
16144
16145         * modules/readline: New file.
16146
16147 2005-08-02  Simon Josefsson  <jas@extundo.com>
16148
16149         * modules/getdelim: New file.
16150
16151         * modules/getline: Rewrite, don't use getndelim2.
16152
16153 2005-08-02  Simon Josefsson  <jas@extundo.com>
16154
16155         * m4/getline.m4: Separate out getdelim stuff into separate module.
16156
16157         * m4/getdelim.m4: New file.
16158
16159 2005-08-02  Simon Josefsson  <jas@extundo.com>
16160
16161         * lib/getline.h, getline.c: Rewrite.
16162
16163         * lib/getdelim.h, lib/getdelim.c: New files, ported from glibc.
16164
16165 2005-07-31  Bruno Haible  <bruno@clisp.org>
16166
16167         * lib/lock.h (gl_lock_initializer): New macro.
16168         (gl_lock_define_initialized): Use it.
16169         (gl_rwlock_initializer): New macro.
16170         (gl_rwlock_define_initialized): Use it.
16171         (gl_recursive_lock_initializer): New macro.
16172         (gl_recursive_lock_define_initialized): Use it.
16173
16174 2005-07-30  Karl Berry  <karl@gnu.org>
16175
16176         * doc/gnulib.texi (Initial import): mention -I$(top_builddir)/lib.
16177         Report from Ben Pfaff, regarding getopt.
16178
16179 2005-07-26  Paul Eggert  <eggert@cs.ucla.edu>
16180
16181         Add support to getopt for Emacs, which doesn't use LIBOBJS in the
16182         normal way.
16183         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE_HEADER): New macro.
16184         (gl_GETOPT_SUBSTITUTE): Use it.  Invoke gl_PREREQ_GETOPT.
16185         (gl_GETOPT_IFELSE, gl_GETOPT_CHECK_HEADERS): New macros.
16186         (gl_GETOPT): Use the new macros.  Most of the implementation
16187         is moved to the new macros.  This is for programs like Emacs
16188         that don't want all the functionality of gl_GETOPT.
16189
16190 2005-07-26  Bruno Haible  <bruno@clisp.org>
16191
16192         * m4/lock.m4: Update from GNU gettext.
16193
16194 2005-07-26  Bruno Haible  <bruno@clisp.org>
16195
16196         * lib/lock.h: Update from GNU gettext.
16197         * lib/lock.c: Update from GNU gettext.
16198
16199 2005-07-25  Paul Eggert  <eggert@cs.ucla.edu>
16200
16201         * m4/regex.m4 (gl_INCLUDED_REGEX): Use AC_RUN_IFELSE instead of the
16202         obsolescent AC_TRY_RUN.  Include the default includes files, for
16203         'exit'.
16204
16205 2005-07-24  Bruno Haible  <bruno@clisp.org>
16206
16207         * modules/visibility: New file.
16208         * MODULES.html.sh (Misc): Add visibility.
16209
16210 2005-07-24  Bruno Haible  <bruno@clisp.org>
16211
16212         * m4/visibility.m4: New file.
16213
16214 2005-07-24  Bruno Haible  <bruno@clisp.org>
16215
16216         * doc/visibility.texi: New file.
16217
16218 2005-07-22  Bruno Haible  <bruno@clisp.org>
16219
16220         * modules/alloca-opt (Makefile.am): Remove explicit dependency on
16221         $(ALLOCA_H), redundant through BUILT_SOURCES.
16222         * modules/argz (Makefile.am): Remove explicit dependency on $(ARGZ_H),
16223         redundant through BUILT_SOURCES.
16224         * modules/byteswap (Makefile.am): Remove explicit dependency on
16225         $(BYTESWAP_H), redundant through BUILT_SOURCES.
16226         * modules/fnmatch (Makefile.am): Remove explicit dependency on
16227         $(FNMATCH_H), redundant through BUILT_SOURCES.
16228         * modules/getopt (Makefile.am): Remove explicit dependency on
16229         $(GETOPT_H), redundant through BUILT_SOURCES.
16230         * modules/glob (Makefile.am): Remove explicit dependency on $(GLOB_H),
16231         redundant through BUILT_SOURCES.
16232         * modules/poll (Makefile.am): Remove explicit dependency on $(POLL_H),
16233         redundant through BUILT_SOURCES.
16234         * modules/stdbool (Makefile.am): Remove explicit dependency on
16235         $(STDBOOL_H), redundant through BUILT_SOURCES.
16236         * modules/stdint (Makefile.am): Remove explicit dependency on
16237         $(STDINT_H), redundant through BUILT_SOURCES.
16238         * modules/sysexits (Makefile.am): Add $(SYSEXITS_H) to BUILT_SOURCES.
16239         Remove explicit dependency on $(SYSEXITS_H).
16240         Reported by Alexandre Duret-Lutz <adl@src.lip6.fr>.
16241
16242 2005-07-18  Simon Josefsson  <jas@extundo.com>
16243
16244         * lib/check-version.c (check_version): Accept identical versions too.
16245
16246 2005-07-18  Bruno Haible  <bruno@clisp.org>
16247
16248         * modules/lock: New file.
16249         * MODULES.html.sh (Multithreading): New section.
16250
16251 2005-07-18  Bruno Haible  <bruno@clisp.org>
16252
16253         * m4/lock.m4: New file, from GNU gettext.
16254
16255 2005-07-18  Bruno Haible  <bruno@clisp.org>
16256
16257         * lib/lock.h: New file, from GNU gettext.
16258         * lib/lock.c: New file, from GNU gettext.
16259
16260 2005-07-18  Bruno Haible  <bruno@clisp.org>
16261
16262         * lib/lock.h (gl_once_t): New type.
16263         (gl_once_define, gl_once): New macros.
16264         * lib/lock.c (fresh_once): New variable.
16265         (glthread_once, glthread_once_call, glthread_once_singlethreaded): New
16266         functions.
16267
16268 2005-07-16  Simon Josefsson  <jas@extundo.com>
16269
16270         * doc/gnulib.texi (Library version handling): Add ELF symbol collision
16271         workaround, suggested by Bruno.
16272
16273 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16274
16275         * modules/xalloc (Depends-on): Add xalloc-die.
16276         * modules/xvasprintf (Depends-on): Add xalloc-die.
16277
16278 2005-07-15  Paul Eggert  <eggert@cs.ucla.edu>
16279
16280         * lib/quotearg.c: Add translator comment suggested by Bruno Haible,
16281         with a minor change.
16282
16283 2005-07-15  Bruno Haible  <bruno@clisp.org>
16284
16285         * m4/poll.m4 (gl_FUNC_POLL): Check against MacOS X 10.4 poll() bug.
16286         When using lib/poll.c, define poll as rpl_poll.
16287
16288 2005-07-14  Paul Eggert  <eggert@cs.ucla.edu>
16289
16290         * modules/argp (Depends-on): Remove unlocked-io.
16291
16292 2005-07-14  Derek Price  <derek@ximbiot.com>
16293
16294         * m4/glob.m4 (gl_GLOB): Cache glob interface check result.  Add check
16295         for glob symlink bug.
16296
16297 2005-07-14  Bruno Haible  <bruno@clisp.org>
16298
16299         * m4/argp.m4 (gl_ARGP): Remove invocation of gl_FUNC_GLIBC_UNLOCKED_IO.
16300         Instead, test for *_unlocked function declarations directly.
16301
16302 2005-07-11  Simon Josefsson  <jas@extundo.com>
16303
16304         * modules/size_max: New file.
16305
16306         * modules/xsize: Depend on size_max module for size_max.m4.
16307
16308 2005-07-11  Simon Josefsson  <jas@extundo.com>
16309
16310         * lib/size_max.h: New file.
16311
16312 2005-07-11  Paul Eggert  <eggert@cs.ucla.edu>
16313
16314         * lib/version-etc-fsf.c (version_etc_copyright): Parameterize the
16315         copyright symbol and the year.
16316         * lib/version-etc.c (COPYRIGHT_YEAR): New constant.
16317         (version_etc_va): Use parameterized copyright notice.
16318         Reword to conform to the current GNU coding standards.
16319
16320 2005-07-11  Karl Berry  <karl@gnu.org>
16321
16322         * doc/gnulib.texi (Quoting): new node.
16323         (Initial import): more info, from Patrice.
16324
16325 2005-07-11  Bruno Haible  <bruno@clisp.org>
16326
16327         * gnulib-tool (func_usage): Document option --avoid.
16328         (Command line options): Handle --avoid.
16329         (func_acceptable): New function.
16330         (func_modules_transitive_closure): Use it.
16331
16332 2005-07-11  Bruno Haible  <bruno@clisp.org>
16333
16334         * MODULES.html.sh: Use shortcut URLs to the www.opengroup.org site.
16335         Reported by Jim Meyering.
16336
16337 2005-07-10  Bruno Haible  <bruno@clisp.org>
16338
16339         * m4/size_max.m4 (gl_SIZE_MAX): Cast ~(size_t)0 back to size_t.
16340         Needed when size_t is smaller than 'unsigned int'.
16341         Reported by Paul Eggert.
16342
16343 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16344
16345         * modules/argp (Depends-on): Add unlocked-io
16346
16347 2005-07-09  Sergey Poznyakoff  <gray@gnu.org.ua>
16348
16349         * lib/argp-namefrob.h: Include unlocked-io.h. Removed unnecessary
16350         block of defines.
16351
16352 2005-07-08  Paul Eggert  <eggert@cs.ucla.edu>
16353
16354         * config/srclist.txt: Comment out regcomp.c, since we have a porting
16355         fix now.
16356
16357 2005-07-08  Eric Blake  <ebb9@byu.net>  (tiny change)
16358         and Paul Eggert  <eggert@cs.ucla.edu>
16359
16360         * lib/regcomp.c (init_dfa, build_range_exp): Store __btowc value
16361         in wint_t, not wchar_t.  Remove now-unnecessary cast.
16362
16363 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16364
16365         * modules/regex (Files): Add lib/regex_internal.c,
16366         lib/regex_internal.h, lib/regexec.c, lib/regcomp.c, m4/codeset.m4.
16367         (Depends-on): Add extensions.
16368         (Makefile.am): Remove lib_SOURCES; now done by m4 code.
16369
16370 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16371
16372         * m4/backupfile.m4 (gl_BACKUPFILE): Use AC_CHECK_FUNCS_ONCE on
16373         pathconf.
16374         * m4/same.m4 (gl_SAME): Likewise.
16375         Require AC_SYS_LONG_FILE_NAMES; bug reported by Gerrit P. Haase.
16376
16377         * m4/regex.m4: Adjust to new libc regex implementation.
16378         (gl_INCLUDED_REGEX): Add AC_LIBSOURCES for
16379         all the .c and .h parts of (the new) regex.
16380         Quote the m4 stuff better.
16381         Check for RE_ICASE bug of old gnulib.
16382         Check for REG_STARTEND of recent libc.
16383         Rename local variables from jm_* to gl_*.
16384         Quote operand of "test -f".
16385         Say "recent enough" version of libc, not "version 2".
16386         (gl_PREREQ_REGEX): Remove AC_FUNC_ALLOCA, since alloca is a
16387         prerequisite module.  Remove AC_HEADER_STDC; no longer needed.
16388         Check for locale.h, isblank, mbrtowc, wcrtomb, wcscoll.
16389         Remove check for btowc, isascii.
16390         Require AM_LANGINFO_CODESET.
16391
16392 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16393
16394         * lib/regex.c, regex.h: Sync from libc.
16395         * lib/regcomp.c, lib/regexec_internal.c, lib/regex_internal.h:
16396         * lib/regexec.c:
16397         New files, synced from libc, except that regex_internal.h
16398         currently has a small porting fix.
16399
16400 2005-07-07  Paul Eggert  <eggert@cs.ucla.edu>
16401
16402         * config/srclist.txt: Add regcomp.c, regex.c, regex.h,
16403         regex_internal.c, regexec.c.
16404         Add regex_internal.h too, but as a comment, since the libc version
16405         is currently broken in gnulib mode.
16406
16407 2005-07-06  Paul Eggert  <eggert@cs.ucla.edu>
16408
16409         Support programs like Emacs that use gnulib but not gettext.
16410         * MODULES.html.sh (Internationalization functions): Add gettext-h.
16411         * modules/gettext-h: New file.
16412         * modules/gettext (Files): Remove lib/gettext.h.
16413         (Depends-on): Add gettext-h.
16414         (Makefile.am): Remove lib_SOURCES.
16415         * modules/argmatch, modules/c-stack, modules/closeout:
16416         * modules/copy-file, modules/csharpcomp, modules/csharpexec:
16417         * modules/execute, modules/file-type, modules/getaddrinfo:
16418         * modules/getopt, modules/human, modules/javacomp:
16419         * modules/javaexec, modules/mkdir-p, modules/obstack:
16420         * modules/openat, modules/pagealign_alloc, modules/pipe:
16421         * modules/quotearg, modules/regex, modules/rpmatch:
16422         * modules/unicodeio, modules/userspec, modules/version-etc:
16423         * modules/wait-process, modules/xalloc-die, modules/xmemcoll:
16424         * modules/xsetenv:
16425         Depend on gettext-h, not gettext.
16426
16427 2005-07-05  Paul Eggert  <eggert@cs.ucla.edu>
16428
16429         * gnulib-tool (func_import): Add support for 'public domain' license.
16430         * modules/alloca, modules/atexit, modules/memmove:
16431         Now public domain, not GPL.
16432         * modules/dup2, modules/getpagesize, modules/malloc, modules/memset:
16433         * modules/realloc, modules/strerror, modules/strtod:
16434         Now LGPL, not GPL.
16435
16436 2005-07-05  Bruno Haible  <bruno@clisp.org>
16437
16438         * m4/mbrtowc.m4 (gl_FUNC_MBRTOWC): Upgrade to version from current
16439         autoconf CVS. Needed for mingw.
16440
16441 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16442
16443         Remove the dependency of the strftime module on the tzset module.
16444         * modules/strftime (Depends-on): Remove dependency on tzset.
16445
16446 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16447
16448         Remove the dependency of the strftime module on the tzset module.
16449         * m4/strftime.m4 (gl_FUNC_STRFTIME): Don't require
16450         gl_FUNC_TZSET_CLOBBER.
16451
16452 2005-07-03  Paul Eggert  <eggert@cs.ucla.edu>
16453
16454         Remove the dependency of the strftime module on the tzset module.
16455         * lib/strftime.c (my_strftime)
16456         [! defined _LIBC && ! HAVE_RUN_TZSET_TEST]:
16457         Copy the input structure, to work around some of the bug with
16458         Solaris 2.5.1 and Solaris 2.6.  If you still care about these old
16459         Solaris releases, you should also use the tzset module, but we won't
16460         require it as a dependency any more since we don't want LGPLed code
16461         to depend on GPLed code.
16462
16463 2005-07-02  Jim Meyering  <jim@meyering.net>
16464
16465         * m4/chown.m4, cloexec.m4, dup2.m4, fsusage.m4:
16466         * m4/getcwd-path-max.m4, getcwd.m4, mkstemp.m4, mountlist.m4:
16467         * m4/pagealign_alloc.m4, save-cwd.m4, unistd-safer.m4:
16468         Don't check for fcntl.h, and don't test for HAVE_FCNTL_H.
16469
16470 2005-07-02  Jim Meyering  <jim@meyering.net>
16471
16472         * lib/backupfile.c (backup_args): Change a `0' to NULL.
16473
16474 2005-07-01  Paul Eggert  <eggert@cs.ucla.edu>
16475
16476         * lib/xnanosleep.c: Include timespec.h, since OpenBSD 3.4 <time.h>
16477         declares only 'struct timespec;' (!).
16478
16479 2005-07-01  Jim Meyering  <jim@meyering.net>
16480
16481         * lib/chown.c, cloexec.c, dup-safer.c, dup2.c, fsusage.c, getcwd.c:
16482         * lib/getloadavg.c, mountlist.c, openat.h, pagealign_alloc.c:
16483         * lib/save-cwd.c, tempname.c:
16484         Assume HAVE_FCNTL_H (i.e., include <fcntl.h> unconditionally,
16485         and don't include <sys/file.h>).
16486
16487 2005-06-29  Jim Meyering  <jim@meyering.net>
16488
16489         * lib/mkdir-p.c (make_dir_parents): Don't apply sizeof to a hard-coded
16490         type name.  Use the variable name instead.
16491         * lib/idcache.c (getuser, getuidbyname, getgroup, getgidbyname):
16492         Likewise.
16493
16494 2005-06-28  Simon Josefsson  <jas@extundo.com>
16495
16496         * modules/check-version (Files): Add check-version.m4.
16497
16498 2005-06-28  Simon Josefsson  <jas@extundo.com>
16499
16500         * m4/check-version.m4: New file, suggested by Jim Meyering
16501         <jim@meyering.net>.
16502
16503 2005-06-28  Simon Josefsson  <jas@extundo.com>
16504
16505         * lib/check-version.h, lib/check-version.c: New files.
16506
16507 2005-06-28  Simon Josefsson  <jas@extundo.com>
16508
16509         * lib/base64.c (base64_encode): Indent.  Rename 'b64' to avoid
16510         collision with global variable.  Better indentation.  Don't
16511         increment buffer pointer beyond buffer end.  Based on comments
16512         from Paul Eggert <eggert@cs.ucla.edu>.
16513
16514         * lib/base64.h: Indent.
16515
16516 2005-06-28  Simon Josefsson  <jas@extundo.com>
16517
16518         * doc/gnulib.texi (Library version handling): New section.
16519
16520 2005-06-28  Jim Meyering  <jim@meyering.net>
16521
16522         * check-module (find_included_lib_files): Hard-code another
16523         pair of exceptions: fts.c includes fts-cycle.c and unistd-safer.h
16524         but modules/fts-lgpl (correctly) does not list those files.
16525
16526         * modules/canonicalize (Files): Add lib/pathmax.h.
16527
16528 2005-06-25  Simon Josefsson  <jas@extundo.com>
16529
16530         * modules/check-version: New file.
16531
16532 2005-06-24  Paul Eggert  <eggert@cs.ucla.edu>
16533
16534         * lib/canon-host.c (canon-host): Append trailing "," to 0 in
16535         initializer of struct addrinfo, as an indication that we don't
16536         care how many members the structure has.
16537
16538 2005-06-24  Derek Price  <derek@ximbiot.com>
16539         and Bruno Haible  <bruno@clisp.org>
16540
16541         Remove stat module & update lstat.
16542         * m4/lstat.m4 (gl_FUNC_LSTAT): Drop AC_FUNC_LSTAT in favor of
16543         AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
16544         * m4/stat.m4: Remove this file.
16545
16546 2005-06-24  Derek Price  <derek@ximbiot.com>
16547         and Bruno Haible  <bruno@clisp.org>
16548
16549         Remove stat module & update lstat.
16550         * lib/stat.c: Remove this file...
16551         (slash_aware_lstat): ...moving this content and its support...
16552         * lib/lstat.c (rpl_lstat): ...into here.
16553         * lib/lstat.h: New file.
16554
16555 2005-06-24  Derek Price  <derek@ximbiot.com>
16556         and Bruno Haible  <bruno@clisp.org>
16557
16558         Remove stat module & update lstat.
16559         * config/srclist.txt (libc sources): Remove stat.
16560
16561 2005-06-24  Derek Price  <derek@ximbiot.com>
16562         and Bruno Haible  <bruno@clisp.org>
16563
16564         Remove stat module & update lstat.
16565         * MODULES.html.sh (stat): Remove.
16566         * MODULES.html: Regenerated.
16567         * modules/lstat (Description): Correct function name.
16568         (Files): Add "lstat.h".
16569         (Depends-on): Remove stat, add xalloc, stat-macros.
16570         * modules/stat: Remove this file.
16571         (Include): Add "lstat.h", remove <sys/stat.h>.
16572
16573 2005-06-23  Paul Eggert  <eggert@cs.ucla.edu>
16574
16575         * lib/mktime.c: Include <string.h> even if !DEBUG.  (From glibc.)
16576         (ranged_convert): Don't save conversion in a temporary struct.
16577         This causes a warning with GCC 4.0.0, and anyway in the typical
16578         case it's not worth the extra 100 bytes or so of code.
16579         (ranged_convert, __mktime_internal): When calling a function via a
16580         pointer P, use P () rather than (*P) (), as we now assume C89 or
16581         better.
16582
16583 2005-06-22  Paul Eggert  <eggert@cs.ucla.edu>
16584
16585         * lib/readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
16586         "who -r" failed to give output.  Problem reported by Tim Waugh.
16587
16588         * lib/xmalloc.c (HAVE_GNU_CALLOC): New constant.
16589         (xcalloc): Use it to avoid needless tests.
16590         Problem reported by Jim Meyering.
16591
16592 2005-06-20  Derek Price  <derek@ximbiot.com>
16593
16594         * m4/bison.m4: Note that precious decls of YACC & YFLAGS will be
16595         unnecessary for Autoconfs > 2.59c.
16596
16597 2005-06-16  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
16598
16599         * lib/argp.h (__option_is_short): Check upper limit of
16600         __key. Isprint() requires its argument to have the value
16601         of an unsigned char or EOF.
16602
16603 2005-06-16  Jim Meyering  <jim@meyering.net>
16604
16605         * lib/calloc.c (rpl_calloc): Allocate a 1-byte buffer (not 1xS or Nx1)
16606         when either N or S is zero.
16607
16608 2005-06-16  Derek Price  <derek@ximbiot.com>
16609
16610         * m4/bison.m4: Declare YACC & YFLAGS precious.
16611
16612 2005-06-10  Paul Eggert  <eggert@cs.ucla.edu>
16613
16614         * lib/fnmatch.c (fnmatch): If there is an encoding error in a
16615         multibyte string or pattern, fall back on unibyte matching.
16616         Problem reported by James Youngman.
16617
16618 2005-06-08  Bruno Haible  <bruno@clisp.org>
16619
16620         * modules/csharpcomp: New file.
16621         * MODULES.html.sh (C#): Add csharpcomp.
16622
16623 2005-06-08  Bruno Haible  <bruno@clisp.org>
16624
16625         * m4/csharpcomp.m4: New file, from GNU gettext.
16626
16627 2005-06-08  Bruno Haible  <bruno@clisp.org>
16628
16629         * lib/csharpcomp.h: New file, from GNU gettext.
16630         * lib/csharpcomp.c: New file, from GNU gettext.
16631         * lib/csharpcomp.sh.in: New file, from GNU gettext.
16632
16633 2005-06-08  Bruno Haible  <bruno@clisp.org>
16634
16635         * lib/binary-io.h (fileno): Undefine before defining it. Avoids a gcc
16636         warning on mingw.
16637
16638 2005-06-07  Derek Price  <derek@ximbiot.com>
16639
16640         Sync from CVS.
16641         * lib/glob_.h: Indent nested #ifdef.
16642
16643 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16644
16645         Sync from coreutils.
16646         Use "file name" when talking about file names, instead of "filename"
16647         or "path", as per the GNU coding standards.
16648         * lib/mkdir-p.c: Renamed from makepath.c.
16649         (make_dir_parents): Renamed from make_path.  All callers changed.
16650         * lib/mkdir-p.h: Likewise.  All includers changed.
16651         * lib/filenamecat.c: Renamed from path-concat.c.
16652         (file_name_concat): Renamed from path_concat.  All callers changed.
16653         [TEST_FILE_NAME_CONCAT]: Renamed from TEST_PATH_CONCAT.
16654         * lib/filenamecat.h: Likewise.  All includers changed.
16655         * lib/acl.c: Don't use "path" or "filename" to mean "file name"
16656         in comments or local variable names.
16657         * lib/basename.c: Likewise.
16658         * lib/canonicalize.c, canonicalize.h: Likewise.
16659         * lib/dirname.c, dirname.h: Likewise.
16660         * lib/euidaccess.c: Likewise.
16661         * lib/exclude.c: Likewise
16662         * lib/fnmatch_.h, fnmatch_loop.c: Likewise.
16663         * lib/fsusage.c, fsuage.h: Likewise.
16664         * lib/fts.c, fts_.h: Likewise.
16665         * lib/getcwd.c: Likewise.
16666         * lib/getloadavg.c: Likewise.
16667         * lib/mkstemp.c: Likewise.
16668         * lib/mountlist.c, mountlist.h: Likewise.
16669         * lib/openat.c, openat.h: Likewise.
16670         * lib/readlink-stub.c: Likewise.
16671         * lib/readutmp.c, readutmp.h: Likewise.
16672         * lib/rename.c: Likewise.
16673         * lib/rmdir.c: Likewise.
16674         * lib/same.c: Likewise.
16675         * lib/savedir.c: Likewise.
16676         * lib/stripslash.c: Likewise.
16677         * lib/tempname.c: Likewise.
16678         * lib/xreadlink.c: Likewise.
16679         * lib/exclude.c (excluded_file_name): Renamed from excluded_filename.
16680         All uses changed.
16681         * lib/exclude.h: Likewise.
16682
16683         * lib/euidaccess.c (getuid, getgid, getuid, getegid)
16684         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16685         * lib/idcache.c (getpwuid, getpwnam, getgrgid, getgrnam)
16686         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16687         * lib/pathmax.h: Include <limits.h> unconditionally, since other
16688         files have been getting away with it for years (MORE/BSD 4.3
16689         is extinct now).
16690         * lib/userspec.c (getpwnam, getgrnam, getgrgid)
16691         [!defined _POSIX_VERSION]: Remove decls; not needed these days.
16692
16693         * lib/pathmax.h (_POSIX_PATH_MAX) [!defined _POSIX_PATH_MAX]:
16694         Define to 256, not 255, as per modern POSIX.
16695
16696 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16697
16698         Sync from coreutils.
16699         Use "file name" when talking about file names, instead of "filename"
16700         or "path", as per the GNU coding standards.
16701         * MODULES.html.sh: mkdir-p renamed from makepath.
16702         filenamecat renamed from path-concat.
16703         * modules/filenamecat: Renamed from modules/path-concat.
16704         (Files): filenamecat.h and filenamecat.c renamed from
16705         path-concat.h and path-concat.c.
16706         (configure.ac): gl_FILE_NAME_CONCAT, not gl_PATH_CONCAT.
16707         (Include): filenamecat.h, not path-concat.h.
16708         * modules/mkdir-p: Renamed from modules/makepath.
16709         (Files): mkdir-p.h and mkdir-p.c renamed from makepath.h and
16710         makepath.c.
16711         (configure.ac): gl_MKDIR_PARENTS, not gl_MAKEPATH.
16712         (Include): mkdir-p.h, not makepath.h.
16713
16714 2005-06-02  Paul Eggert  <eggert@cs.ucla.edu>
16715
16716         Sync from coreutils.
16717         * m4/mkdir-p.m4: Renamed from makepath.m4.
16718         (gl_MKDIR_PARENTS): Renamed from gl_MAKEPATH.  All uses changed.
16719         Rename files from makepath.c to mkdir-p.c, and from
16720         makepath.h to mkdir-p.h.
16721         * m4/filenamecat.m4: Renamed from path-concat.m4.
16722         (gl_FILE_NAME_CONCAT): Renamed from gl_PATH_CONCAT.  All uses changed.
16723         Rename files from path-concat.c to filenamecat.c,
16724         and from path-concat.h to filenamecat.h.
16725         * m4/getcwd-path-max.m4: Don't use "path" or "filename" to mean
16726         "file name" in local variables or comments.
16727         * m4/rename.m4: Likewise.
16728
16729 2005-06-01  Bruno Haible  <bruno@clisp.org>
16730
16731         * modules/csharpexec: New file.
16732         * MODULES.html.sh (C#): New section.
16733
16734 2005-06-01  Bruno Haible  <bruno@clisp.org>
16735
16736         * m4/csharp.m4: New file, from GNU gettext.
16737         * m4/csharpexec.m4: New file, from GNU gettext.
16738
16739 2005-06-01  Bruno Haible  <bruno@clisp.org>
16740
16741         * lib/csharpexec.h: New file, from GNU gettext.
16742         * lib/csharpexec.c: New file, from GNU gettext.
16743         * lib/csharpexec.sh.in: New file, from GNU gettext.
16744
16745 2005-05-31  Derek Price  <derek@ximbiot.com>
16746             Paul Eggert  <eggert@cs.ucla.edu>
16747
16748         Sync from cvs.
16749         * m4/glob.m4: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16750
16751 2005-05-31  Derek Price  <derek@ximbiot.com>
16752             Paul Eggert  <eggert@cs.ucla.edu>
16753
16754         Sync from cvs.
16755         * lib/glob_.h: s/MISSING_SYS_CDEFS_H/_SYS_CDEFS_H/ and comment.
16756
16757 2005-05-29  Derek Price  <derek@ximbiot.com>
16758
16759         * config/srclist.txt (glob_.h, glob.c): Add these files.
16760
16761 2005-05-29  Derek Price  <derek@ximbiot.com>
16762
16763         * MODULES.html.sh: Add glob to Enhanced POSIX.2001 section.
16764         * modules/glob: New file.
16765         * modules/getlogin_r: Add link to POSIX spec in description.
16766
16767 2005-05-29  Derek Price  <derek@ximbiot.com>
16768             Paul Eggert  <eggert@cs.ucla.edu>
16769
16770         * m4/glob.m4: New file.
16771
16772 2005-05-29  Derek Price  <derek@ximbiot.com>
16773             Paul Eggert  <eggert@cs.ucla.edu>
16774
16775         * lib/glob_.h, lib/glob.c: New files.
16776
16777 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16778
16779         * modules/fts (Files): Remove m4/inttypes-pri.m4.
16780         * modules/fts-lgpl (Depends-on): Remove gettext.
16781
16782 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16783
16784         * m4/fts.m4 (gl_FUNC_FTS_CORE): Don't check for inttypes.h or stdint.h,
16785         and don't require gt_INTTYPES_PRI.
16786
16787 2005-05-27  Paul Eggert  <eggert@cs.ucla.edu>
16788
16789         * lib/getlogin_r.c (getlogin_r): Don't set errno to 0 on return.
16790
16791         * lib/fts.c: Don't worry about debugging on pre-C99-compatible hosts;
16792         the configuration hassle isn't worth it.
16793         Include inttypes.h and stdint.h unconditionally if FTS_DEBUG.
16794         (LONGEST_MODIFIER, PRIuMAX): Remove.
16795
16796 2005-05-27  Bruno Haible  <bruno@clisp.org>
16797
16798         * lib/getlogin_r.h: Remove second include of <stddef.h>.
16799
16800 2005-05-26  Paul Eggert  <eggert@cs.ucla.edu>
16801
16802         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Define
16803         _POSIX_PTHREAD_SEMANTICS for Solaris.
16804
16805 2005-05-25  Derek Price  <derek@ximbiot.com>
16806
16807         * MODULES.html.sh: Add getlogin_r to POSIX.2001 support section.
16808
16809 2005-05-25  Derek Price  <derek@ximbiot.com>
16810             Paul Eggert  <eggert@cs.ucla.edu>
16811
16812         * modules/getlogin_r, m4/getlogin_r.m4: New files.
16813         * lib/getlogin_r.c, getlogin_r.h: New files.
16814
16815 2005-05-25  Bruno Haible  <bruno@clisp.org>
16816             Derek Price  <derek@ximbiot.com>
16817
16818         * lib/getlogin_r.h: Simplify API documentation.
16819
16820 2005-05-23  Derek Price  <derek@ximbiot.com>
16821
16822         * modules/minmax (Files): Add m4/minmax.m4.
16823         (configure.ac): Add gl_MINMAX.
16824
16825 2005-05-22  Paul Eggert  <eggert@cs.ucla.edu>
16826
16827         * lib/fts.c (fd_safer) [_LGPL_PACKAGE]: New static function,
16828         so that unistd-safer.h (GPL'ed code) need not be included.
16829
16830 2005-05-22  Bruno Haible  <bruno@clisp.org>
16831
16832         * m4/minmax.m4: New file.
16833         Based on a patch by Derek Price <derek@ximbiot.com>.
16834
16835 2005-05-22  Bruno Haible  <bruno@clisp.org>
16836
16837         * lib/stdint_.h (_STDINT_H_HAVE_INT64): New macro. Use it in #ifdefs.
16838         (INT64_MIN): Fix definition.
16839         Suggested by Paul Eggert <eggert@cs.ucla.edu>.
16840
16841         * lib/stdint_.h (_STDINT_H_NEED_SIGNED_INT_TYPES): Renamed from
16842         NEED_SIGNED_INT_TYPES.
16843
16844         * lib/stdint_.h (_STDINT_H_HAVE_SYSTEM_INTTYPES): Renamed from
16845         HAVE_SYSTEM_INTTYPES.
16846
16847 2005-05-22  Bruno Haible  <bruno@clisp.org>
16848
16849         * lib/minmax.h: Include <limits.h> only when it defines MIN, MAX.
16850         Also include <sys/param.h> if it defines MIN, MAX.
16851         Based on a patch by Derek Price <derek@ximbiot.com>.
16852
16853 2005-05-21  Jim Meyering  <jim@meyering.net>
16854
16855         * modules/fts (Files): Add m4/inttypes-pri.m4.
16856         (Depends-on): Add lstat and remove gettext.  Alphabetize.
16857
16858 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16859
16860         New fts module.
16861         * lib/fts.c: Don't include "cycle-check.h" or "hash.h".
16862         (setup_dir, free_dir): New functions.
16863         (enter_dir, leave_dir): Define trivial
16864         alternatives of _LGPL_PACKAGE.  Move to fts-cycle.c if !_LGPL_PACKAGE.
16865         (HT_INITIAL_SIZE, ENTER_DIR): Remove.  All uses removed.
16866         (LEAVE_DIR): Fix typo: pass Fts and Ent to leave_dir.
16867         (struct Active_dir, AD_compare, AD_hash, enter_dir, leave_dir):
16868         Move to fts-cycle.c.
16869         (fts_open): Use setup_dir.
16870         (fts_close): Use free_dir.
16871         (fts_read): Have just one copy of the ENTER_DIR code rather than three.
16872         This adds a label and some gotos, but the alternatives were messier.
16873         Check for memory allocation failure when entering a dir.
16874         (fts_stat) [_LGPL_PACKAGE]: Bring back glibc cycle detection code.
16875         * lib/fts_.h (_LGPL_PACKAGE) [defined _LIBC]: New macro.
16876         (FTS): New member fts_cycle, that is a union that contains the
16877         old active_dir_ht and cycle_state.  All uses changed to mention
16878         fts_cycle.ht and fts_cycle.state.
16879         * lib/fts-cycle.c: New file, containing GPL'ed code migrated out of
16880         fts.c, with the following changes:
16881         (setup_dir, free_dir): New functions.
16882         (enter_dir): Now returns bool.  Return true if successful, false
16883         if memory exhausted.  All callers changed.
16884         Do not bother partly cleaning up on
16885         memory allocation failure; that is free_dir's job.
16886         However, free ad if hash_insert fails, to avoid memory leak.
16887         (enter_dir, leave_dir): Accommodate change to FTS by inspecting
16888         fts->fts_options to see which union member to use.
16889
16890 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16891
16892         * m4/fts.m4 (gl_FUNC_FTS_CORE): Renamed from gl_FUNC_FTS.
16893         (gl_FUNC_FTS, gl_FUNC_FTS_LGPL): New macros.
16894
16895 2005-05-20  Paul Eggert  <eggert@cs.ucla.edu>
16896
16897         * MODULES.html.sh (File system functions): Add fts, fts-lgpl.
16898
16899 2005-05-20  Jim Meyering  <jim@meyering.net>
16900
16901         * lib/unlinkdir.h (cannot_unlink_dir) [UNLINK_CANNOT_UNLINK_DIR]:
16902         Now a macro, to pacify GCC.
16903
16904 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16905
16906         * m4/chown.m4 (gl_FUNC_CHOWN): Correct sense of test for honoring IDs
16907         of -1.
16908
16909 2005-05-20  Eric Blake  <ebb9@byu.net>  (tiny change)
16910
16911         * lib/chown.c (rpl_chown): Return -1 on failure.
16912
16913 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16914
16915         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME]):
16916         Don't check for stddef.h.
16917         * m4/fts.m4 (gl_FUNC_FTS): Don't require AC_HEADER_STDC, as we
16918         don't use its results.
16919         Don't check for fcntl.h, stddef.h, stdlib.h, string.h, unistd.h,
16920         since we include them unconditionally.  Don't require
16921         AM_STDBOOL_H, since stdbool is a prerequisite.
16922         Don't require AC_C_CONST, AC_TYPE_SIZE_T or check for ptrdiff_t
16923         since we assume C89 or better.
16924         Don't require AC_FUNC_CLOSEDIR_VOID, AC_FUNC_LSTAT, or AC_FUNC_STAT,
16925         as we don't use their results.
16926         Don't check for fchdir, memmove, memset, strrchr, as we use
16927         them unconditionally.
16928         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Don't define
16929         GETTIMEOFDAY_CLOBBERS_LOCALTIME_BUFFER, since nobody uses it.
16930
16931 2005-05-18  Paul Eggert  <eggert@cs.ucla.edu>
16932
16933         * lib/canonicalize.c: Include canonicalize.h first, to test interface.
16934         Include <stddef.h> unconditionally, since we assume C89 now.
16935         All uses of PTR_INT_TYPE replaced by ptrdiff_t.
16936         * lib/fts.c: Include fts_.h first, to check interface.
16937         Do not include intprops.h; no longer needed.
16938         Include cycle-check.h and hash.h, since fts_.h no longer does.
16939         Remove unnecessary casts of closedir to void.
16940         (fts_build): Use a simpler method (not involving TYPE_SIGNED) to
16941         decide whether to decrement nlinks.
16942         * lib/fts_.h: Do not include hash.h or cycle-check.h; no longer needed.
16943         (FTS): Use struct hash_table * instead of Hash_table, so that
16944         we no longer need to include hash.h here.
16945
16946 2005-05-18  Jim Meyering  <jim@meyering.net>
16947
16948         * modules/dirfd (License): Change to LGPL.  Most of the code
16949         is already in the public domain.
16950
16951 2005-05-18  Jim Meyering  <jim@meyering.net>
16952
16953         * m4/fts.m4 (AC_LIBSOURCES): Add intprops.h to the list.
16954         Reported by Yoann Vandoorselaere.
16955
16956 2005-05-17  Jim Meyering  <jim@meyering.net>
16957
16958         * m4/fts.m4: New file, from coreutils.
16959
16960 2005-05-17  Jim Meyering  <jim@meyering.net>
16961
16962         * lib/fts.c, lib/fts_.h: New files, from coreutils.
16963
16964 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16965
16966         Sync from coreutils.
16967         * m4/unlinkdir.m4: New file.
16968
16969 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16970
16971         Sync from coreutils.
16972         * lib/unlinkdir.c, lib/unlinkdir.h: New files.
16973         * lib/gethrxtime.c, lib/gethrxtime.h, lib/getpass.h, lib/mountlist.h,
16974         lib/path-concat.c, lib/regex.h, lib/unlocked-io.h, lib/xtime.h:
16975         White space changes only.
16976         * lib/makepath.c (make_path): Port to hosts where leading "//" is
16977         special.
16978         * lib/yesno.c: Include getline.h, not ctype.h.
16979         (yesno): Don't remove leading white space; POSIX doesn't allow it.
16980         Use getline to remove arbitrary restriction on response length.
16981
16982 2005-05-14  Paul Eggert  <eggert@cs.ucla.edu>
16983
16984         * config/srclist-update: Spell out "Street" in FSF postal
16985         mail address; this is the style the FSF seems to prefer.
16986
16987         * build-aux/depcomp, build-aux/install-sh, build-aux/mdate-sh,
16988         build-aux/missing, build-aux/mkinstalldirs: Sync from Automake;
16989         this updates FSF postal mail address.
16990
16991         Sync from coreutils.
16992         * modules/unlinkdir: New file.
16993         * modules/yesno (Depends-on): Add getline.
16994         * MODULES.html.sh (File system functions): Add unlinkdir.
16995
16996 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
16997
16998         * lib/byteswap_.h, lib/getsubopt.h, lib/iconvme.h, lib/strsep.c,
16999         lib/strsep.h:
17000         Change the initial comment to refer to GPL, not LGPL.
17001         gnulib-tool will change it to LGPL as needed.
17002
17003         * lib/__fpending.c, lib/acl.c, lib/acl.h, lib/alloca_.h, lib/allocsa.c,
17004         lib/allocsa.h, lib/argmatch.c, lib/argmatch.h, lib/argp-ba.c,
17005         lib/argp-eexst.c, lib/argp-fmtstream.c, lib/argp-fmtstream.h,
17006         lib/argp-fs-xinl.c, lib/argp-help.c, lib/argp-namefrob.h,
17007         lib/argp-parse.c, lib/argp-pv.c, lib/argp-pvh.c, lib/argp-xinl.c,
17008         lib/argp.h, lib/argz.c, lib/argz_.h, lib/asnprintf.c, lib/asprintf.c,
17009         lib/atanl.c, lib/backupfile.c, lib/backupfile.h, lib/base64.c,
17010         lib/base64.h, lib/basename.c, lib/binary-io.h, lib/byteswap_.h,
17011         lib/c-ctype.c, lib/c-ctype.h, lib/c-stack.c, lib/c-stack.h,
17012         lib/c-strtod.c, lib/calloc.c, lib/canon-host.c, lib/canonicalize.c,
17013         lib/canonicalize.h, lib/ceill.c, lib/chdir-long.c, lib/chdir-long.h,
17014         lib/chown.c, lib/classpath.c, lib/classpath.h, lib/cloexec.c,
17015         lib/closeout.c, lib/closeout.h, lib/concatpath.c, lib/config.charset,
17016         lib/copy-file.c, lib/copy-file.h, lib/cycle-check.c, lib/cycle-check.h,
17017         lib/diacrit.c, lib/diacrit.h, lib/dirfd.c, lib/dirfd.h, lib/dirname.c,
17018         lib/dirname.h, lib/dummy.c, lib/dup-safer.c, lib/dup2.c, lib/eealloc.h,
17019         lib/error.c, lib/error.h, lib/euidaccess.c, lib/exclude.c,
17020         lib/exclude.h, lib/execute.c, lib/execute.h, lib/exit.h,
17021         lib/exitfail.c, lib/exitfail.h, lib/expl.c, lib/fatal-signal.c,
17022         lib/fatal-signal.h, lib/fd-safer.c, lib/file-type.c, lib/file-type.h,
17023         lib/fileblocks.c, lib/filemode.c, lib/filemode.h, lib/findprog.c,
17024         lib/findprog.h, lib/floorl.c, lib/fnmatch.c, lib/fnmatch_.h,
17025         lib/fnmatch_loop.c, lib/fopen-safer.c, lib/free.c, lib/frexpl.c,
17026         lib/fsusage.c, lib/fsusage.h, lib/full-read.c, lib/full-read.h,
17027         lib/full-write.c, lib/full-write.h, lib/fwriteerror.c,
17028         lib/fwriteerror.h, lib/gai_strerror.c, lib/gcd.c, lib/gcd.h,
17029         lib/getaddrinfo.c, lib/getaddrinfo.h, lib/getcwd.c, lib/getcwd.h,
17030         lib/getdate.h, lib/getdate.y, lib/getdomainname.c, lib/getdomainname.h,
17031         lib/getgroups.c, lib/gethostname.c, lib/gethrxtime.c, lib/gethrxtime.h,
17032         lib/getline.c, lib/getline.h, lib/getloadavg.c, lib/getndelim2.c,
17033         lib/getndelim2.h, lib/getnline.c, lib/getnline.h, lib/getopt.c,
17034         lib/getopt1.c, lib/getopt_.h, lib/getopt_int.h, lib/getpagesize.h,
17035         lib/getpass.c, lib/getpass.h, lib/getsubopt.c, lib/getsubopt.h,
17036         lib/gettext.h, lib/gettime.c, lib/gettimeofday.c, lib/getugroups.c,
17037         lib/getusershell.c, lib/group-member.c, lib/group-member.h,
17038         lib/hard-locale.c, lib/hard-locale.h, lib/hash-pjw.c, lib/hash-pjw.h,
17039         lib/hash.c, lib/hash.h, lib/human.c, lib/human.h, lib/iconvme.c,
17040         lib/iconvme.h, lib/idcache.c, lib/inet_ntop.h, lib/intprops.h,
17041         lib/inttostr.c, lib/inttostr.h, lib/isdir.c, lib/javacomp.c,
17042         lib/javacomp.h, lib/javacomp.sh.in, lib/javaexec.c, lib/javaexec.h,
17043         lib/javaexec.sh.in, lib/lbrkprop.h, lib/lchown.c, lib/ldexpl.c,
17044         lib/linebreak.c, lib/linebreak.h, lib/linebuffer.c, lib/linebuffer.h,
17045         lib/localcharset.c, lib/localcharset.h, lib/logl.c, lib/long-options.c,
17046         lib/long-options.h, lib/lstat.c, lib/makepath.c, lib/makepath.h,
17047         lib/malloc.c, lib/mathl.h, lib/mbswidth.c, lib/mbswidth.h, lib/md5.c,
17048         lib/md5.h, lib/memcasecmp.c, lib/memcasecmp.h, lib/memchr.c,
17049         lib/memcmp.c, lib/memcoll.c, lib/memcoll.h, lib/memcpy.c, lib/memmem.c,
17050         lib/memmem.h, lib/mempcpy.c, lib/mempcpy.h, lib/memrchr.c,
17051         lib/memrchr.h, lib/memset.c, lib/minmax.h, lib/mkdir.c, lib/mkdtemp.c,
17052         lib/mkdtemp.h, lib/mkstemp.c, lib/mktime.c, lib/modechange.c,
17053         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
17054         lib/obstack.c, lib/obstack.h, lib/openat.c, lib/openat.h,
17055         lib/pagealign_alloc.c, lib/pagealign_alloc.h, lib/path-concat.c,
17056         lib/path-concat.h, lib/pathmax.h, lib/pathname.h, lib/physmem.c,
17057         lib/physmem.h, lib/pipe.c, lib/pipe.h, lib/poll.c, lib/poll_.h,
17058         lib/posixtm.c, lib/posixtm.h, lib/posixver.c, lib/printf-args.c,
17059         lib/printf-args.h, lib/printf-parse.c, lib/printf-parse.h,
17060         lib/progname.c, lib/progname.h, lib/progreloc.c, lib/putenv.c,
17061         lib/quote.c, lib/quote.h, lib/quotearg.c, lib/quotearg.h, lib/raise.c,
17062         lib/readlink.c, lib/readtokens.c, lib/readtokens.h, lib/readtokens0.c,
17063         lib/readtokens0.h, lib/readutmp.c, lib/readutmp.h, lib/realloc.c,
17064         lib/ref-add.sin, lib/ref-del.sin, lib/regex.c, lib/regex.h,
17065         lib/rename.c, lib/rmdir.c, lib/rpmatch.c, lib/safe-read.c,
17066         lib/safe-read.h, lib/safe-write.c, lib/safe-write.h, lib/same.c,
17067         lib/same.h, lib/save-cwd.c, lib/save-cwd.h, lib/savedir.c,
17068         lib/savedir.h, lib/setenv.c, lib/setenv.h, lib/settime.c,
17069         lib/sh-quote.c, lib/sh-quote.h, lib/sha1.c, lib/sha1.h, lib/sig2str.c,
17070         lib/sig2str.h, lib/sincosl.c, lib/snprintf.c, lib/snprintf.h,
17071         lib/sqrtl.c, lib/stat-macros.h, lib/stat.c, lib/stdbool_.h,
17072         lib/stdint_.h, lib/stdio-safer.h, lib/stpcpy.c, lib/stpcpy.h,
17073         lib/stpncpy.c, lib/stpncpy.h, lib/strcase.h, lib/strcasecmp.c,
17074         lib/strchrnul.c, lib/strchrnul.h, lib/strcspn.c, lib/strdup.c,
17075         lib/strdup.h, lib/strerror.c, lib/strftime.c, lib/strftime.h,
17076         lib/stripslash.c, lib/strndup.c, lib/strndup.h, lib/strnlen.c,
17077         lib/strpbrk.c, lib/strpbrk.h, lib/strsep.c, lib/strsep.h, lib/strstr.c,
17078         lib/strstr.h, lib/strtod.c, lib/strtoimax.c, lib/strtok_r.c,
17079         lib/strtok_r.h, lib/strtol.c, lib/strtoll.c, lib/strtoul.c,
17080         lib/strtoull.c, lib/strverscmp.c, lib/strverscmp.h, lib/sysexit_.h,
17081         lib/tempname.c, lib/time_r.c, lib/time_r.h, lib/timegm.c, lib/timegm.h,
17082         lib/timespec.h, lib/trigl.c, lib/trigl.h, lib/ucs4-utf16.h,
17083         lib/ucs4-utf8.h, lib/unicodeio.c, lib/unicodeio.h, lib/unistd-safer.h,
17084         lib/unlocked-io.h, lib/unsetenv.c, lib/userspec.c, lib/utf16-ucs4.h,
17085         lib/utf8-ucs4.h, lib/utime.c, lib/utimecmp.c, lib/utimecmp.h,
17086         lib/utimens.c, lib/vasnprintf.c, lib/vasnprintf.h, lib/vasprintf.c,
17087         lib/vasprintf.h, lib/version-etc-fsf.c, lib/version-etc.c,
17088         lib/version-etc.h, lib/vsnprintf.c, lib/vsnprintf.h, lib/w32spawn.h,
17089         lib/wait-process.c, lib/wait-process.h, lib/xalloc-die.c, lib/xalloc.h,
17090         lib/xallocsa.c, lib/xallocsa.h, lib/xasprintf.c, lib/xgetcwd.c,
17091         lib/xgetcwd.h, lib/xgetdomainname.c, lib/xgetdomainname.h,
17092         lib/xgethostname.c, lib/xmalloc.c, lib/xmemcoll.c, lib/xnanosleep.c,
17093         lib/xreadlink.c, lib/xreadlink.h, lib/xsetenv.c, lib/xsetenv.h,
17094         lib/xsize.h, lib/xstrndup.c, lib/xstrndup.h, lib/xstrtod.c,
17095         lib/xstrtod.h, lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h,
17096         lib/xstrtoumax.c, lib/xtime.h, lib/xvasprintf.c, lib/xvasprintf.h,
17097         lib/yesno.c, lib/yesno.h:
17098         Update FSF postal mail address.
17099
17100 2005-05-13  Paul Eggert  <eggert@cs.ucla.edu>
17101
17102         * MODULES.html.sh, README, gnulib-tool, tests/test-base64.c,
17103         tests/test-memmem.c, tests/test-stpncpy.c:
17104         Update FSF postal mail address.
17105
17106 2005-05-13  Bruno Haible  <bruno@clisp.org>
17107
17108         * lib/stdint_.h (int64_t, uint64_t, int_least64_t, uint_least64_t,
17109         int_fast64_t, uint_fast64_t, intmax_t, uintmax_t, INT64_MIN, INT64_MAX,
17110         UINT64_MAX, INT_LEAST64_MIN, INT_LEAST64_MAX, UINT_LEAST64_MAX,
17111         INT_FAST64_MIN, INT_FAST64_MAX, UINT_FAST64_MAX, INTMAX_MIN,
17112         INTMAX_MAX, UINTMAX_MAX, INT64_C, UINT64_C, INTMAX_C, UINTMAX_C):
17113         Add support for 64-bit integers in the MSVC compiler.
17114
17115 2005-05-12  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17116
17117         * modules/getdate (Makefile.am): Add getdate.c to EXTRA_DIST
17118
17119 2005-05-12  Eric Blake  <ebb9@byu.net>  (tiny change)
17120
17121         * gnulib-tool (func_import): Sort and uniquify recommended includes.
17122
17123 2005-05-11  Paul Eggert  <eggert@cs.ucla.edu>
17124
17125         * doc/getdate.texi (General date syntax): Don't say that date
17126         date --iso-8601=ns generates acceptable dates; it doesn't yet.
17127         Problem reported by Nic Ferrier.
17128
17129 2005-05-10  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17130
17131         * lib/getaddrinfo.c: Don't fail when SOCK_STREAM or SOCK_DGRAM are
17132         specified in ai_socktype. Fix invalid ai_protocol
17133         check. ai_protocol is usually set to 0 or depending on
17134         ai_family/ai_socktype to IPPROTO_TCP / IPPROTO_UDP.  Checking for
17135         SOCK_STREAM / SOCK_DGRAM in ai_protocol was invalid.  Set
17136         ai_socktype / ai_protocol in the returned addrinfo structure.
17137
17138 2005-05-10  Simon Josefsson  <jas@extundo.com>
17139
17140         * m4/getaddrinfo.m4: Look in libnsl/libsocket for getaddrinfo, from
17141         Yoann Vandoorselaere <yoann.v@prelude-ids.com>.
17142
17143 2005-05-10  Karl Berry  <karl@gnu.org>
17144
17145         * doc/fdl.texi, gpl.texi, lgpl.texi, COPYING: update FSF address
17146         (from http://www.gnu.org/licenses).
17147         * doc/COPYING.LIB: also rename to COPYING.LESSER.
17148         * doc/COPYING.DOC: remove; per rms, only needed in doc files, so
17149         fdl.texi suffices.
17150
17151 2005-05-10  Karl Berry  <karl@gnu.org>
17152
17153         * config/srclist.txt (COPYING.LESSER): rename from COPYING.LIB.
17154         (COPYING.DOC): remove.
17155
17156         * config/srclist-update: new FSF address.
17157
17158 2005-05-10  Derek Price  <derek@ximbiot.com>
17159
17160         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 bug, not decl, when
17161         possible.
17162
17163 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17164             Bruno Haible  <bruno@clisp.org>
17165
17166         * modules/inet_ntop: New file.
17167         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
17168         inet_ntop.
17169
17170 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17171             Bruno Haible  <bruno@clisp.org>
17172
17173         * m4/inet_ntop.m4: New file.
17174
17175 2005-05-09  Yoann Vandoorselaere  <yoann.v@prelude-ids.com>
17176             Bruno Haible  <bruno@clisp.org>
17177
17178         * lib/inet_ntop.h: New file.
17179         * lib/inet_ntop.c: New file, from glibc with modifications.
17180
17181 2005-05-09  Paul Eggert  <eggert@cs.ucla.edu>
17182
17183         * modules/time_r (License): Change to LGPL.
17184         * modules/extensions (License): Change to LGPL.  Actually,
17185         the license is more permissive than that, but currently gnulib-tool
17186         doesn't know how to handle more-permissive licenses.
17187
17188         * modules/stat-macros (Depends-on): Don't depend on stat-macros (!).
17189         Problem reported by Dave Love.
17190
17191 2005-05-08  Jim Meyering  <jim@meyering.net>
17192
17193         * lib/classpath.c (PATH_SEPARATOR): Remove insignificant trailing
17194         blank.
17195
17196 2005-05-06  Paul Eggert  <eggert@cs.ucla.edu>
17197
17198         * modules/argmatch (Depends-on): Add stdbool.
17199         * modules/backupfile (Depends-on): Likewise.
17200         * modules/chdir-long (Depends-on): Likewise.
17201         * modules/closeout (Depends-on): Likewise.
17202         * modules/cycle-check (Depends-on): Likewise.
17203         * modules/dirname (Depends-on): Likewise.
17204         * modules/fnmatch (Depends-on): Likewise.
17205         * modules/fsusage (Depends-on): Likewise.
17206         * modules/fwriteerror (Depends-on): Likewise.
17207         * modules/getcwd (Depends-on): Likewise.
17208         * modules/getloadavg (Depends-on): Likewise.
17209         * modules/hard-locale (Depends-on): Likewise.
17210         * modules/makepath (Depends-on): Likewise.
17211         * modules/mountlist (Depends-on): Likewise.
17212         * modules/nanosleep (Depends-on): Likewise.
17213         * modules/posixtm (Depends-on): Likewise.
17214         * modules/quotearg (Depends-on): Likewise.
17215         * modules/readtokens (Depends-on): Likewise.
17216         * modules/readtokens0 (Depends-on): Likewise.
17217         * modules/readutmp (Depends-on): Likewise.
17218         * modules/save-cwd (Depends-on): Likewise.
17219         * modules/strftime (Depends-on): Likewise.
17220         * modules/userspec (Depends-on): Likewise.
17221         * modules/utimecmp (Depends-on): Likewise.
17222         * modules/xgetcwd (Depends-on): Likewise.
17223         * modules/xnanosleep (Depends-on): Likewise.
17224         * modules/xstrtod (Depends-on): Likewise.
17225         * modules/yesno (Depends-on): Likewise.
17226
17227 2005-05-05  Paul Eggert  <eggert@cs.ucla.edu>
17228
17229         * m4/getopt.m4 (gl_GETOPT): Check for Solaris 10 getopt, and avoid
17230         needless checks.
17231
17232 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17233
17234         Merge from coreutils.  Among other things,
17235         add bulletproofing for cases where stdin, stdout, or stderr are closed.
17236         * lib/fd-safer.c: New file.
17237         * lib/fcntl-safer.h, open-safer.c: Remove.
17238         * lib/chdir-long.c: Fix comment "fetish" -> "coreutils".
17239         * lib/dup-safer.c: Include unistd-safer.h first.
17240         Don't include errno.h.
17241         (dup_safer) [!defined F_DUPFD]: Let fd_safer do the real work.
17242         * lib/file-type.h: Don't assume invoker included sys/stat.h first.
17243         * lib/file-type.c: Rely on file-type.h change.
17244         * lib/getloadavg.c: Include unistd-safer.h.
17245         (getloadavg): Use safer open.
17246         * lib/getusershell.c: Include "stdio-safer.h".
17247         (getusershell): Use safer fopen.
17248         * lib/long-options.c (long_options): Use NULL rather than 0.
17249         * lib/modechange.h (mode_free): Remove; all callers changed to invoke
17250         'free'.
17251         * lib/modechange.c: Likewise.
17252         xstrtol.h, stdbool.h, stddef.h: Don't include; no longer needed.
17253         (MODE_DONE): New constant.
17254         (struct mode_change): Remove 'next' member.
17255         (make_node_op_equals): New function; like the old one of the
17256         same name, except it allocates an array.
17257         (mode_compile, mode_create_from_ref): Use it.
17258         (mode_compile): Allocate result as an array, not a linked list.
17259         Parse octal string ourself, so that we catch mistakes like "+0".
17260         (mode_adjust): Arg is an array, not a linked list.
17261         * lib/modechange.c: Include stat-macros.h, xalloc.h.
17262         (S_ISDIR, S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR):
17263         (S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH, S_IRXWU):
17264         (S_IRWXG, S_IRWXO, CHMOD_MODE_BITS):
17265         Remove.  This is now stat-macros.h's job.
17266         (talloc): Remove.  All callers replaced by xalloc, so that
17267         our invokers don't have to worry about reporting memory failures.
17268         (make_node_op_equals): Remove.
17269         (MODE_ORDINARY_CHAGE, MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17270         New constants.
17271         (struct mode_change): Moved here from modechange.h.
17272         (mode_append_entry): Remove.
17273         (mode_compile): Remove MASKED_OPS arg, since it encouraged
17274         apps to have incorrect behavior.  Use simpler algorithm for head
17275         and tail.  Don't futz with umask; that's now the job of mode_adjust.
17276         Detect more invalid usages rather than having somewhat-random behavior.
17277         Don't insert an "a=" action, as that leads to incorrect behavior.
17278         (mode_compile, mode_create_from_ref): Return NULL on error instead
17279         of an enum, since now there's only one way to have an error.  All
17280         callers changed.
17281         (mode_adjust): Accept new arg UMASK_VALUE, and interpret it
17282         at the correct time.  Simplify calculation of "+u" and its ilk.
17283         Don't mishandle "+X".
17284         (mode_free): Remove "register" and localize decls.
17285         * lib/modechange.h (MODE_X_IF_ANY_X, MODE_COPY_EXISTING):
17286         (struct mode_change): Move to modechange.c; callers don't
17287         need to see this stuff.
17288         (MODE_MASK_EQUALS, MODE_MASK_PLUS, MODE_MASK_MINUS, MODE_MASK_ALL):
17289         (MODE_INVALID, MODE_MEMORY_EXHAUSTED, MODE_BAD_REFERENCE): Remove.
17290         (mode_change, mode_adjust): Reflect the new signatures noted above.
17291         * lib/nanosleep.c (rpl_nanosleep): Include "timespec.h" before macros
17292         that might redefine system include files.
17293         (siginterrupt) [!HAVE_SIGINTERRUPT]: New macro.
17294         (my_usleep): Use NULL rather than (void *) 0.
17295         (rpl_nanosleep) [!defined SA_NOCLDSTOP]:
17296         Use siginterrupt to specify that system calls should be interrupted.
17297         (rpl_nanosleep): Move initialization of suspended closer to call of
17298         my_usleep.
17299         * lib/readutmp.h (read_utmp): New arg OPTIONS.  All uses changed.
17300         * lib/readutmp.c: Likewise.  Include signal.h, stdbool.h.
17301         (desirable_utmp_entry): New function.
17302         (read_utmp) [defined UTMP_NAME_FUNCTION]: Redo memory allocation
17303         using x2nrealloc, to simplify logic.
17304         (read_utmp) [!defined UTMP_NAME_FUNCTION]: Check for overflow in
17305         size calculation.  Do not assume utmp file is a regular file.
17306         * lib/readutmp.h (UT_PID): Moved here from ../src/who.c.
17307         (READ_UTMP_CHECK_PIDS): New constant.
17308         * lib/save-cwd.c: Include unistd-safer.h.
17309         (save_cwd): Use fd_safer.
17310         * lib/tempname.c (S_ISDIR, S_IRUSR, S_IRUSR, S_IWUSR, S_IXUSR): Remove.
17311         [!_LIBC] Include "stat-macros.h" instead.
17312         * lib/unistd-safer.h (fd_safer): New decl.
17313
17314 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17315
17316         * modules/getloadavg (Depends-on): Add unistd-safer.
17317         * modules/getusershell (Depends-on): Add stdio-safer.
17318         * modules/lstat (Depends-on): Remove xalloc.
17319         * modules/mkstemp (Depends-on): Add stat-macros.
17320         * modules/modechange (Depends-on): Remove xstrtol.
17321         Add stat-macros, xalloc.
17322         * modules/save-cwd (Depends-on): Add unistd-safer.
17323         * modules/stdio-safer (Makefile.am): Remove lib_SOURCES.
17324         * modules/unistd-safer (Files): Add lib/fd-safer.c
17325         (Makefile.am): Remove lib_SOURCES.
17326
17327         * MODULES.html.sh (Enhancements for POSIX:2001 functions):
17328         Remove fcntl-safer; unistd-safer supersedes it.
17329
17330 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17331
17332         * m4/euidaccess.m4 (gl_PREREQ_EUIDACCESS): Don't require
17333         AC_HEADER_STAT.
17334         * m4/lchown.m4 (gl_FUNC_CHOWN): Likewise.
17335         (gl_PREREQ_CHOWN): Remove.
17336         * m4/lstat.m4 (gl_FUNC_LSTAT): Require AC_FUNC_LSTAT instead of calling
17337         it.  Don't require AC_HEADER_STAT.
17338         (gl_PREREQ_LSTAT): Remove.
17339         * m4/mkstemp.m4 (gl_PREREQ_TEMPNAME): Check stdint.h only once.
17340         Don't require AC_HEADER_STAT.
17341         * m4/rmdir.m4 (gl_FUNC_RMDIR): Don't require AC_HEADER_STAT.
17342         (gl_PREREQ_RMDIR): Remove.
17343         * m4/canonicalize.m4 (AC_FUNC_CANONICALIZE_FILE_NAME): Don't
17344         mention stat-macros.h or AC_HEADER_STAT, since we'll make
17345         the stat-macros module a prerequisite.
17346         * m4/file-type.m4 (gl_FILE_TYPE): Likewise.
17347         * m4/filemode.m4 (gl_FILEMODE): Likewise.
17348         * m4/makepath.m4 (gl_MAKEPATH): Likewise.
17349         * m4/modechange.m4 (gl_MODECHANGE): Likewise.
17350         * m4/clock_time.m4 (gl_CLOCK_TIME): Use gl_ rather than fetish_ for
17351         variable names.
17352         * m4/rmdir-errno.m4 (gl_FUNC_RMDIR_NOTEMPTY): Renamed from
17353         fetish_FUNC_RMDIR_NOTEMPTY.  All uses changed.  Use gl_ for
17354         variable prefixes.
17355         * m4/fcntl-safer.m4: Remove.
17356         * m4/stdio-safer.m4 (gl_STDIO_SAFER): Use AC_LIBSOURCES and AC_LIBOBJ.
17357         * m4/unistd-safer.m4 (gl_UNISTD_SAFER): Likewise.
17358         Invoke gl_PREREQ_FD_SAFER.
17359         (gl_PREREQ_FD_SAFER): New macro.
17360         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): Check for siginterrupt.
17361         * m4/readutmp.m4 (gl_READUTMP): Require AC_C_INLINE.
17362         Use AC_CHECK_HEADERS_ONCE and AC_CHECK_FUNCS_ONCE when possible.
17363         Remove duplicate call to AC_LIBOBJ(readutmp).
17364         (gl_PREREQ_READUTMP): Remove.  All uses inlined.
17365
17366         * m4/mmap-anon.m4 (gl_FUNC_MMAP_ANON): Check for message, not for
17367         MAP_ANON.  Problem reported by Moriyoshi Koizumi to bug-cvs.
17368
17369 2005-05-01  Paul Eggert  <eggert@cs.ucla.edu>
17370
17371         * MODULES.html.sh (Misc): Add byteswap.
17372
17373 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17374
17375         * modules/getcwd (Depends-on): Add extensions.
17376         * modules/openat (Depends-on): Likewise.
17377
17378 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17379
17380         * modules/byteswap: New file.
17381
17382 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17383
17384         * m4/byteswap.m4: New file.
17385
17386 2005-05-01  Oskar Liljeblad  <oskar@osk.mine.nu>
17387
17388         * lib/byteswap_.h: New file.
17389
17390 2005-04-25  Karl Berry  <karl@gnu.org>
17391
17392         * m4/gettext.m4: Update from GNU gettext 0.14.4.
17393
17394 2005-04-25  Albert Chin  <china@thewrittenword.com>
17395
17396         * lib/regex.c: Include <stdio.h>, as a workaround to a Compaq Desktop
17397         Toolkit C bug.
17398
17399 2005-04-21  Oskar Liljeblad  <oskar@osk.mine.nu>
17400
17401         * gnulib-tool (Options): Add -s for --symlink/--symbolic.
17402         (func_ln_if_changed) Remove forcibly for no error message
17403         in case file does not exist.
17404
17405 2005-04-19  Simon Josefsson  <jas@extundo.com>
17406
17407         * gnulib-tool (Options): Make --symlink mean --symbolic.
17408
17409 2005-04-18  Oskar Liljeblad  <oskar@osk.mine.nu>
17410
17411         * doc/gnulib.texi (Initial import): Fix.  Mention --aux-dir.
17412
17413 2005-04-16  Simon Josefsson  <jas@extundo.com>
17414
17415         * modules/getpass-gnu (Makefile.am): Don't mention getpass.h.
17416
17417 2005-04-15  Simon Josefsson  <jas@extundo.com>
17418
17419         * m4/getpass.m4 (gl_FUNC_GETPASS): Use AC_LIBSOURCES.
17420
17421 2005-04-15  Simon Josefsson  <jas@extundo.com>
17422
17423         * gnulib-tool: Rename --symlink to --symbolic.
17424
17425 2005-04-15  Oskar Liljeblad  <oskar@osk.mine.nu>
17426
17427         * gnulib-tool: Add -s, --symlink option to gnulib-tool to make
17428         symbolic links to files instead of copying/moving.  Add --aux-dir,
17429         specifying directory relative --dir where auxiliary build tools
17430         are placed.
17431
17432 2005-04-14  Bruno Haible  <bruno@clisp.org>
17433
17434         * modules/allocsa (License): Change to LGPL.
17435         Requested by Yoann Vandoorselaere <yoann@prelude-ids.org>.
17436
17437 2005-04-13  Paul Eggert  <eggert@cs.ucla.edu>
17438
17439         * lib/getdate.y (zone): Allow relunit_snumber after tZONE, so
17440         that "UTC +1 second" continues to work.  Problem reported
17441         by Dmitry V. Levin.
17442         (relunit_snumber): New rule.
17443         (relunit): Use it.
17444
17445 2005-04-12  Paul Eggert  <eggert@cs.ucla.edu>
17446
17447         * lib/getdate.y (universal_time_zone_table): New constant.
17448         (time_zone_table): Remove GMT, UT, UTC entries; they're now in
17449         universal_time_zone_table.
17450         (lookup_zone): Prefer universal_time_zone_table to
17451         local_time_zone_table, so that "GMT" time stamps are allowed in
17452         London during the summer.  Problem reported by Ian Abbott.
17453
17454 2005-04-12  Jim Meyering  <jim@meyering.net>
17455
17456         * lib/human.c (humblock): Set *options even when returning due to
17457         xstrtoumax conversion failure.  Thanks to a used-uninitialized
17458         warning from gcc-4.
17459
17460 2005-04-09  Jim Meyering  <jim@meyering.net>
17461
17462         * lib/posixtm.c (posixtime) [lint]: Avoid spurious warning from gcc-4's
17463         -Wuninitialized: initialize tm0.tm_year.
17464
17465 2005-04-04  Paul Eggert  <eggert@cs.ucla.edu>
17466
17467         * lib/getdate.y (parser_control): rels_seen is now a boolean, not a
17468         count, since there's no maximum.  All uses changed.
17469         Add member dsts_seen.
17470         (local_zone): Accumulate dsts_seen rather than relying on tm_isdst
17471         not being INT_MAX.
17472         (get_date): Initialize dsts_seen, and check that it doesn't go over 1.
17473         Use pc_rels_seen to decide whther a date is absolute.
17474
17475         * lib/getdate.y (number): Don't overwrite year.
17476         (get_date): Initialize pc.year.digits to 0, not 4, to enable above
17477         check.
17478
17479 2005-04-02  Simon Josefsson  <jas@extundo.com>
17480
17481         * lib/getaddrinfo.h: Fix OpenBSD compilation failure, inspired by tiny
17482         patch from Yoann Vandoorselaere <yoann@prelude-ids.org>.
17483
17484 2005-03-28  Eric Blake  <ebb9@byu.net>  (tiny change)
17485
17486         * m4/getcwd-path-max.m4: Return success on systems such as Cygwin
17487         where no absolute path name can be longer than PATH_MAX.
17488
17489 2005-03-27  Jim Meyering  <jim@meyering.net>
17490
17491         * lib/argmatch.c: Clarify comment: null-terminated -> NULL-terminated.
17492
17493 2005-03-26  Paul Eggert  <eggert@cs.ucla.edu>
17494
17495         * lib/intprops.h (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND):
17496         "one's complement" -> "ones' complement" in comment, as per Knuth.
17497         "value of type" -> "type or expression" in comment.
17498         * lib/mktime.c, strftime.c: Propagate intprops.h comment nits.
17499
17500 2005-03-26  Jim Meyering  <jim@meyering.net>
17501
17502         Comment nits.
17503         * lib/intprops.h: Add the apostrophe in `(one|two)'s complement'.
17504         Correct typos: s/or/of/.
17505
17506 2005-03-26  Jim Meyering  <jim@meyering.net>
17507
17508         * modules/check-include-files: Move to ../ and rename to...
17509         * check-module: ...this.
17510
17511 2005-03-25  Jim Meyering  <jim@meyering.net>
17512
17513         * modules/xvasprintf (Files): Add xalloc.h.
17514
17515 2005-03-23  Paul Eggert  <eggert@cs.ucla.edu>
17516
17517         * modules/gettext (Files): config/config.rpath ->
17518         build-aux/config.rpath
17519         * modules/iconv (Files): Likewise.
17520         Problem reported by Oskar Liljeblad.
17521
17522 2005-03-23  Jim Meyering  <jim@meyering.net>
17523
17524         * modules/check-include-files: New script to check for
17525         missing dependencies, multiple includes, etc.
17526
17527         * modules/c-strtold (Depends-on): Add xalloc.
17528         * modules/c-strtod (Depends-on): Add xalloc.
17529         * modules/hash (Depends-on): Add xalloc.
17530         (Files): Remove lib/xalloc.h.
17531
17532         * modules/gethrxtime (Files): Add lib/gethrxtime.h.
17533         * modules/userspec (Files): Add lib/inttostr.h.
17534
17535 2005-03-23  Jim Meyering  <jim@meyering.net>
17536
17537         * lib/canonicalize.c: Remove duplicate `#include "stat-macros.h"'.
17538
17539 2005-03-22  Jim Meyering  <jim@meyering.net>
17540
17541         * modules/stat-macros: New module.
17542         * modules/canonicalize, modules/euidaccess, modules/file-type,
17543         * modules/filemode, modules/lchown, modules/makepath,
17544         * modules/rmdir, modules/stat: Depend on new stat-macros module
17545         rather than listing lib/stat-macros.h manually.
17546         Don't add stat-macros.h to lib_SOURCES or list it in Files: section.
17547
17548 2005-03-22  Jim Meyering  <jim@meyering.net>
17549
17550         * m4/stat-macros.m4 (gl_STAT_MACROS): New file/macro.
17551
17552 2005-03-22  Bruno Haible  <bruno@clisp.org>
17553
17554         * config/srclist.txt: Replace target directory 'config' with
17555         'build-aux'.
17556         * config/config.guess, config.sub, config.rpath, depcomp, install-sh:
17557         * config/mdate-sh, missing, mkinstalldirs, texinfo.tex: Move to
17558         ../build-aux/.
17559
17560 2005-03-21  Paul Eggert  <eggert@cs.ucla.edu>
17561
17562         * modules/chdir-long (Depends-on): Add mempcpy.
17563
17564         * modules/acl, modules/backupfile, modules/c-strtod,
17565         modules/c-strtold, modules/canon-host, modules/canonicalize,
17566         modules/cloexec, modules/closeout, modules/dirfd, modules/dirname,
17567         modules/exclude, modules/exitfail, modules/file-type,
17568         modules/filemode, modules/fpending, modules/fsusage, modules/getcwd,
17569         modules/getdate, modules/getline, modules/getpagesize,
17570         modules/getpass, modules/getugroups, modules/group-member,
17571         modules/hard-locale, modules/hash, modules/human, modules/idcache,
17572         modules/inttostr, modules/long-options, modules/makepath,
17573         modules/md5, modules/memcasecmp, modules/memcoll,
17574         modules/modechange, modules/mountlist, modules/path-concat,
17575         modules/pathmax, modules/physmem, modules/posixtm, modules/posixver,
17576         modules/quote, modules/quotearg, modules/readtokens, modules/readutmp,
17577         modules/safe-read, modules/safe-write, modules/same, modules/savedir,
17578         modules/settime, modules/sha1, modules/sig2str, modules/strdup,
17579         modules/strftime, modules/strndup, modules/strverscmp,
17580         modules/timespec, modules/unlocked-io, modules/userspec,
17581         modules/utimecmp, modules/utimens, modules/xalloc, modules/xstrtol,
17582         modules/yesno:
17583         Remove lib_SOURCES line from Makefile.am section, as this is now
17584         done automatically by the corresponding Autoconf macro.
17585
17586 2005-03-21  Jim Meyering  <jim@meyering.net>
17587
17588         Changes imported from coreutils.
17589
17590         * lib/cycle-check.c: Don't include xalloc.h.
17591
17592         * lib/path-concat.c: Don't include assert.h.
17593         (path_concat): Remove assertion that would have triggered
17594         for ABASE starting with more than one slash.
17595         Reported by Andreas Schwab.
17596
17597         * lib/path-concat.c (path_concat): Set *BASE_IN_RESULT
17598         properly when ABASE is an absolute file name.
17599         Correct the description of this function.
17600         Include <assert.h>.
17601         Add an assertion and a test driver.
17602         This fixes a bug introduced on 2004-07-02.
17603         Andreas Schwab reported the resulting failure of cp --parents:
17604         http://lists.gnu.org/archive/html/bug-coreutils/2005-01/msg00130.html
17605
17606 2005-03-21  Jim Meyering  <jim@meyering.net>
17607
17608         * m4/chdir-long.m4 (gl_PREREQ_CHDIR_LONG): Invoke gl_FUNC_MEMRCHR.
17609         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Check for memrchr decl.
17610
17611 2005-03-21  Jim Meyering  <jim@meyering.net>
17612         and  Paul Eggert  <eggert@cs.ucla.edu>
17613
17614         * m4/acl.m4, m4/backupfile.m4, m4/c-strtod.m4, m4/canon-host.m4,
17615         m4/canonicalize.m4, m4/cloexec.m4, m4/closeout.m4, m4/dirfd.m4,
17616         m4/dirname.m4, m4/exclude.m4, m4/exitfail.m4, m4/file-type.m4,
17617         m4/filemode.m4, m4/fpending.m4, m4/fsusage.m4, m4/getcwd.m4,
17618         m4/getdate.m4, m4/getline.m4, m4/getpagesize.m4, m4/getpass.m4,
17619         m4/getugroups.m4, m4/group-member.m4, m4/hard-locale.m4, m4/hash.m4,
17620         m4/human.m4, m4/idcache.m4, m4/inttostr.m4, m4/long-options.m4,
17621         m4/makepath.m4, m4/md5.m4, m4/memcasecmp.m4, m4/memcoll.m4,
17622         m4/modechange.m4, m4/mountlist.m4, m4/nanosleep.m4, m4/path-concat.m4,
17623         m4/pathmax.m4, m4/physmem.m4, m4/posixtm.m4, m4/posixver.m4,
17624         m4/quote.m4, m4/quotearg.m4, m4/readtokens.m4, m4/readutmp.m4,
17625         m4/safe-read.m4, m4/safe-write.m4, m4/same.m4, m4/savedir.m4,
17626         m4/settime.m4, m4/sha1.m4, m4/sig2str.m4, m4/strdup.m4, m4/strftime.m4,
17627         m4/strndup.m4, m4/strverscmp.m4, m4/timespec.m4, m4/unlocked-io.m4,
17628         m4/userspec.m4, m4/utimecmp.m4, m4/utimens.m4, m4/xalloc.m4,
17629         m4/xnanosleep.m4, m4/xstrtol.m4, m4/yesno.m4:
17630         Use AC_LIBSOURCES and AC_LIBOBJ to indicate source and object files
17631         for these modules.
17632
17633 2005-03-18  Paul Eggert  <eggert@cs.ucla.edu>
17634
17635         * lib/strftime.c (my_strftime): If the underlying strftime returns 0
17636         (which shouldn't happen), generate nothing instead of returning 0
17637         immediately, so that nstrftime (NULL, ...) doesn't return 0.
17638
17639 2005-03-16  Bruno Haible  <bruno@clisp.org>
17640
17641         * modules/stdint (Makefile.am): Use HAVE_LONG_LONG_64BIT instead of
17642         HAVE_LONGLONG_64BIT.
17643
17644 2005-03-16  Bruno Haible  <bruno@clisp.org>
17645
17646         * m4/stdint.m4 (gl_STDINT_H): Define HAVE_LONG_LONG_64BIT instead of
17647         HAVE_LONGLONG_64BIT.
17648
17649 2005-03-16  Bruno Haible  <bruno@clisp.org>
17650
17651         * lib/stdint_.h: Use HAVE_LONG_LONG_64BIT instead of
17652         HAVE_LONGLONG_64BIT.
17653
17654 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
17655
17656         * lib/strftime.c (my_strftime): Prepend space to format so that we can
17657         reliably distinguish strftime failure from empty output on POSIX
17658         hosts.
17659
17660 2005-03-15  Paul Eggert  <eggert@cs.ucla.edu>
17661
17662         * lib/iconvme.c (SIZE_MAX): New macro, if not already defined.
17663         (iconv_string): Don't guess a size-zero buffer, as that might cause
17664         buffer overrun.  Instead, avoid multiplying by MB_LEN_MAX if the
17665         result would be 'too large', where 'too large' is (heuristically)
17666         the square root of SIZE_MAX, divided by MB_LEN_MAX to allay
17667         overflow concerns.  This will prevent some unwanted malloc failures
17668         when the inputs are very large.
17669
17670 2005-03-15  Karl Berry  <karl@gnu.org>
17671
17672         * config/srclist.txt (config.rpath): from gettext.
17673         * config/config.rpath: update.
17674
17675 2005-03-15  Bruno Haible  <bruno@clisp.org>
17676
17677         * lib/regex.c (byte_re_match_2_internal): Rename local variable 'not'
17678         to 'negate'.
17679
17680         * lib/regex.c (byte_re_match_2_internal): Reduce scope of same_str_p
17681         variable.
17682
17683         * lib/regex.c (EXTEND_BUFFER, regcomp): Cast the realloc/malloc
17684         results.
17685
17686 2005-03-14  Simon Josefsson  <jas@extundo.com>
17687
17688         * lib/timegm.h: Use proper prototype CPP guards, reported by Dave Love
17689         <fx@gnu.org>.
17690
17691 2005-03-14  Paul Eggert  <eggert@cs.ucla.edu>
17692
17693         * lib/mktime.c (TYPE_TWOS_COMPLEMENT, TYPE_ONES_COMPLEMENT,
17694         TYPE_SIGNED_MAGNITUDE, TYPE_MINIMUM, TYPE_MAXIMUM): Sync from
17695         intprops.h.
17696         * lib/strtol.c: Likewise.
17697
17698 2005-03-14  Jim Meyering  <jim@meyering.net>
17699
17700         * lib/strftime.c (my_strftime) [HAVE_STRFTIME && ! (_NL_CURRENT
17701         && HAVE_STRUCT_ERA_ENTRY)]: Initialize the first byte of ubuf[]
17702         to be nonzero so that we (and caller) can detect the difference
17703         between a valid zero-length expansion and an error return, even
17704         when the underlying strftime fails before writing anything into
17705         that location.
17706
17707 2005-03-14  Bruno Haible  <bruno@clisp.org>
17708
17709         * m4/lib-link.m4, gettext.m4, nls.m4, po.m4:
17710         Update from GNU gettext 0.14.3.
17711
17712 2005-03-10  Jim Meyering  <jim@meyering.net>
17713
17714         * m4/save-cwd.m4 (gl_SAVE_CWD): Check for fchdir.
17715
17716 2005-03-10  Jim Meyering  <jim@meyering.net>
17717
17718         * lib/save-cwd.c [!HAVE_FCHDIR]: Define open, fchdir, and chdir_long
17719         so that this module works on systems without fchdir.
17720
17721 2005-03-09  Paul Eggert  <eggert@cs.ucla.edu>
17722
17723         Factor int-properties macros into a single file, except for
17724         glibc-related files.
17725         * lib/intprops.h: New file.
17726         * lib/getloadavg.c: Include it instead of limits.h.
17727         (INT_STRLEN_BOUND): Remove.
17728         * lib/human.c: Include intprops.h.
17729         (group_number): Use INT_STRLEN_BOUND instead of rolling it ourself.
17730         * lib/human.h (LONGEST_HUMAN_READABLE): Use 146/485 rather than
17731         302/1000.
17732         * lib/inttostr.h: Include intprops.h instead of limits.h.
17733         (INT_STRLEN_BOUND, INT_BUFSIZE_BOUND): Remove.
17734         * lib/mktime.c (TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT): New macros,
17735         for consistency with intprops.h.
17736         (time_t_is_integer, twos_complement_arithmetic): Use them.
17737         * lib/sig2str.h: Include <signal.h>, intprops.h.
17738         (INT_STRLEN_BOUND): Remove.
17739         * lib/strftime.c (TYPE_SIGNED): Remove.
17740         (INT_STRLEN_BOUND): Switch to same implementation as intprops.h.
17741         * lib/strtol.c: Adjust comments to match intprops.h.
17742         * lib/userspec.c: Include intprops.h.
17743         (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
17744         * lib/utimecmp.c, xnanosleep.c, xstrtol.c: Likewise.
17745         * lib/utimecmp.c (utimecmp): Use TYPE_IS_INTEGER, TYPE_TWOS_COMPLEMENT
17746         instead of rolling our own expressions.
17747         * lib/xstrtol.c: Include xstrtol.h first, to test interface.
17748
17749         * lib/strftime.c: Include <stdbool.h>.  Use bool where appropriate,
17750         instead of int.
17751         (my_strftime): Do not mishandle years close to INT_MAX, by doing
17752         the right thing even if adding 1900 would overflow.  Similarly
17753         for tm_mon + 1 and tm_yday + 1.
17754         Make %Y always equivalent to %C%y, and similarly for %G and %g.
17755         (DO_NUMBER, DO_NUMBER_SPACEPAD): Set digits to d, not a conditional.
17756         (DO_SIGNED_NUMBER): New macro.
17757         (my_strftime) [HAVE_TZNAME]: Don't dump core if tp->tm_dst > 1.
17758
17759 2005-03-07  Bruno Haible  <bruno@clisp.org>
17760
17761         * m4/mmap-anon.m4 (MAP_FILE, MAP_FAILED): Remove definitions.
17762
17763 2005-03-07  Bruno Haible  <bruno@clisp.org>
17764
17765         * lib/pagealign_alloc.c (MAP_FILE, MAP_FAILED): Define fallbacks.
17766
17767 2005-03-04  Derek R. Price  <derek@ximbiot.com>
17768
17769         * gnulib-tool (func_cp_if_changed, func_mv_if_changed): New functions.
17770         (func_import): Only replace files via --import when they have actually
17771         changed.
17772
17773 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17774
17775         * m4/mmap-anon.m4: New file.
17776         * m4/pagealign_alloc.m4: New file.
17777
17778 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17779             Bruno Haible  <bruno@clisp.org>
17780
17781         * modules/pagealign_alloc: New file.
17782         * MODULES.html.sh (Memory management functions): Add pagealign_alloc.
17783
17784 2005-03-03  Derek R. Price  <derek@ximbiot.com>
17785             Bruno Haible  <bruno@clisp.org>
17786
17787         * lib/pagealign_alloc.h: New file.
17788         * lib/pagealign_alloc.c: New file.
17789
17790 2005-03-03  Bruno Haible  <bruno@clisp.org>
17791
17792         * m4/inttypes.m4, isc-posix.m4, once-only.m4:
17793         Use an all-permissive copyright notice, recommended by RMS.
17794
17795 2005-03-02  Bruno Haible  <bruno@clisp.org>
17796
17797         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Undo the replacement here. Because
17798         of AIX, the replacement has to be done only after <string.h> is
17799         included, therefore not in config.h. stpncpy.h does the replacement,
17800         and stpncpy.c uses it.
17801
17802 2005-03-02  Bruno Haible  <bruno@clisp.org>
17803
17804         * lib/stpncpy.h (stpncpy): Define as a macro without arguments, so that
17805         stpncpy.c uses it.
17806
17807 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17808
17809         Remove workaround for bug in Linux kernel 2.6.8 or thereabouts.
17810         The workaround isn't strictly needed for POSIX conformance, and
17811         it's too much of a pain to configure and maintain.  We'll ask
17812         people to fix their kernels instead.
17813         * lib/xnanosleep.c: Don't include gethrxtime.h or xtime.h.
17814         (NANOSLEEP_BUG_WORKAROUND): Remove.
17815         (xnanosleep): Remove the workaround.
17816
17817 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17818
17819         * modules/gettime (Makefile.am): Remove lib_SOURCES line.
17820         Reported by Derek Price.
17821         (Include): Add "timespec.h".
17822
17823         * modules/xnanosleep (Depends-on): Remove gethrxtime.
17824
17825 2005-03-01  Paul Eggert  <eggert@cs.ucla.edu>
17826
17827         * m4/xnanosleep.m4 (gl_XNANOSLEEP): Remove configuration attempting
17828         to detect nanosleep bug.
17829
17830 2005-03-01  Bruno Haible  <bruno@clisp.org>
17831
17832         * lib/vasnprintf.c (EOVERFLOW): Define to a fallback if needed.
17833
17834 2005-02-26  Paul Eggert  <eggert@cs.ucla.edu>
17835
17836         * modules/gethrxtime: New file.
17837         * modules/xnanosleep (Files): Add m4/xnanosleep.m4.
17838         (Depends-on): Add gethrxtime.
17839         (configure.ac): Add gl_XNANOSLEEP.
17840         (Makefile.am): Remove lib_SOURCES line.
17841
17842 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17843
17844         * m4/gethrxtime.m4, m4/xnanosleep.m4: New files.
17845         * m4/gettime.m4 (gl_GETTIME): Check for nanotime.
17846
17847 2005-02-25  Paul Eggert  <eggert@cs.ucla.edu>
17848
17849         * lib/gethrxtime.h, lib/gethrxtime.c, lib/xtime.h: New files.
17850         * lib/timespec.h (gettime): Return void, since it always
17851         succeeds now.  All uses changed.
17852         * lib/gettime.c (gettime) Likewise.
17853         [HAVE_NANOTIME]: Prefer nanotime.
17854         Assume gettimeofday succeeds, as POSIX requires.
17855         Assime time () succeeds, since other code already does.
17856         * lib/xnanosleep.c: Include xtime.h and gethrxtime.h, not xalloc.h.
17857         (timespec_subtract): Remove.
17858         (NANOSLEEP_BUG_WORKAROUND): New constant.
17859         (xnanosleep): Use gethrxtime rather than gettime; this simplifies
17860         things considerably.  Use it only on GNU/Linux hosts, since the
17861         workaround shouldn't be needed elsewhere.
17862
17863 2005-02-24  Bruno Haible  <bruno@clisp.org>
17864
17865         * modules/gettext (Files): Add m4/glibc2.m4.
17866
17867 2005-02-24  Bruno Haible  <bruno@clisp.org>
17868
17869         * m4/gettext.m4, intdiv0.m4, intmax.m4, inttypes-pri.m4, lcmessage.m4:
17870         * m4/lib-link.m4, lib-prefix.m4, nls.m4, po.m4, printf-posix.m4:
17871         * m4/progtest.m4:
17872         Update from GNU gettext 0.14.2.
17873         * m4/glibc2.m4: New file, from GNU gettext 0.14.2.
17874
17875 2005-02-24  Bruno Haible  <bruno@clisp.org>
17876
17877         * lib/localcharset.c: Update from GNU gettext 0.14.2.
17878         * lib/config.charset: Update from GNU gettext 0.14.2.
17879
17880 2005-02-24  Bruno Haible  <bruno@clisp.org>
17881
17882         * lib/gettext.h: Update from GNU gettext 0.14.2.
17883
17884 2005-02-23  Simon Josefsson  <jas@extundo.com>
17885
17886         * m4/iconvme.m4: New file.
17887
17888 2005-02-23  Jim Meyering  <jim@meyering.net>
17889
17890         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Revert yesteday's
17891         change.
17892         Thanks to Bruno Haible for catching it.
17893
17894 2005-02-22  Simon Josefsson  <jas@extundo.com>
17895
17896         * modules/iconvme: New file.
17897
17898         * MODULES.html.sh: Add iconvme.
17899
17900 2005-02-22  Simon Josefsson  <jas@extundo.com>
17901
17902         * lib/iconvme.h, lib/iconvme.c: New files, from libc.
17903
17904 2005-02-22  Simon Josefsson  <jas@extundo.com>
17905
17906         * config/srclist.txt: Sync iconvme.h, iconvme.c from libc.
17907
17908 2005-02-22  Jim Meyering  <jim@meyering.net>
17909
17910         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Fix typo:
17911         s/ifndef/ifdef/.
17912
17913 2005-02-20  Neil Conway  <neilc@samurai.com>
17914
17915         * lib/xgethostname.c (xgethostname): Check for ENOMEM, which is
17916         returned by OSX/Darwin if the specified buffer is not large
17917         enough for the hostname.
17918
17919 2005-02-03  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
17920
17921         * lib/argp-help.c (__argp_help): Create a fake struct argp_state and
17922         pass it to _help, otherwise the latter coredumps trying to
17923         dereference state.root_argp.
17924
17925 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17926
17927         * modules/chdir-long (Depends-on): Add memrchr.
17928         * modules/memrchr (Files): Add lib/memrchr.h.
17929         (Include): "memrchr.h".
17930
17931 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17932
17933         * m4/memrchr.m4 (gl_FUNC_MEMRCHR): Add AC_LIBSOURCES, for memrchr.h.
17934
17935 2005-02-03  Paul Eggert  <eggert@cs.ucla.edu>
17936
17937         * lib/memrchr.h: New file.
17938         * lib/chdir-long.c: Include it.
17939         * lib/memrchr.c [!defined _LIBC]: Include it rather than <string.h>
17940         Don't bother including stddef.h.
17941
17942 2005-02-01  Paul Eggert  <eggert@cs.ucla.edu>
17943
17944         * lib/mountlist.h (MOUNTLIST_H_): New macro, to protect against double
17945         inclusion.
17946         Include <sys/types.h>, for dev_t.
17947         (ME_DUMMY, ME_REMOTE): Move from here....
17948         * lib/mountlist.c (ME_DUMMY, ME_REMOTE): To here.
17949         (ME_DUMMY): Count "subfs" as a dummy.  Problem reported by
17950         Dmitry V. Levin.
17951         Include mountlist.h first, to test the interface.
17952
17953 2005-01-29  Bruno Haible  <bruno@clisp.org>
17954
17955         * lib/progname.c (program_name): Initialize.
17956         Needed when linking statically on MacOS X.
17957
17958 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17959
17960         Sync from coreutils.
17961         * modules/getloadavg (Files): Remove m4/getloadavg.m4.
17962         (Depends-on): Add c-strtod.
17963         (configure.ac): Replace gl_FUNC_GETLOADAVG with AC_FUNC_GETLOADAVG.
17964
17965 2005-01-28  Paul Eggert  <eggert@cs.ucla.edu>
17966
17967         Sync from coreutils.
17968         * m4/getloadavg.m4, glibc.m4, search-libs.m4: Remove.
17969
17970         Remove files that are specific to coreutils.
17971         * m4/check-decl.m4, jm-macros.m4, lib-check.m4, prereq.m4: Remove.
17972
17973 2005-01-28  Bruno Haible  <bruno@clisp.org>
17974
17975         * modules/javacomp: New file.
17976         * MODULES.html.sh (Java): Add javacomp.
17977
17978 2005-01-28  Bruno Haible  <bruno@clisp.org>
17979
17980         * m4/javacomp.m4: New file, from GNU gettext.
17981
17982 2005-01-28  Bruno Haible  <bruno@clisp.org>
17983
17984         * lib/javacomp.sh.in: New file, from GNU gettext.
17985         * lib/javacomp.h: New file, from GNU gettext.
17986         * lib/javacomp.c: New file, from GNU gettext.
17987
17988 2005-01-26  Simon Josefsson  <jas@extundo.com>
17989
17990         * lib/gai_strerror.c: Use GPL in header.
17991
17992 2005-01-26  Bruno Haible  <bruno@clisp.org>
17993
17994         * modules/javaexec: New file.
17995         * MODULES.html.sh (Java): Add javaexec.
17996
17997 2005-01-26  Bruno Haible  <bruno@clisp.org>
17998
17999         * m4/javaexec.m4: New file, from GNU gettext.
18000
18001 2005-01-26  Bruno Haible  <bruno@clisp.org>
18002
18003         * lib/javaexec.sh.in: New file, from GNU gettext.
18004         * lib/javaexec.h: New file, from GNU gettext.
18005         * lib/javaexec.c: New file, from GNU gettext.
18006
18007 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18008
18009         * modules/lchown (Depends-on): Remove lchown.h
18010
18011 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18012
18013         * m4/sysexits.m4 (gl_SYSEXITS): Reverted logic. SYSEXITS_H
18014         must be defined if the header file was not found, in order
18015         to provide a replacement. Reported by Todd Vierling <tv@duh.org>
18016
18017 2005-01-24  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18018
18019         * lib/argp-help.c (hol_entry_help): Avoid using non-constant
18020         initializers for struct pentry_state.
18021         (__argp_error): Check return value of __asprintf
18022         (__argp_failure): Translate error message
18023
18024         * lib/argp-parse.c: Removed braces around the expansion of N_()
18025
18026 2005-01-23  Paul Eggert  <eggert@cs.ucla.edu>
18027
18028         * m4/acl.m4, afs.m4, alloca.m4, argp.m4, assert.m4, atexit.m4,
18029         backupfile.m4, base64.m4, bison.m4, c-bs-a.m4, c-stack.m4,
18030         c-strtod.m4, calloc.m4, canon-host.m4, canonicalize.m4,
18031         clock_time.m4, cloexec.m4, closeout.m4, d-ino.m4, d-type.m4,
18032         dirfd.m4, dirname.m4, dos.m4, dup2.m4, error.m4, euidaccess.m4,
18033         exclude.m4, exitfail.m4, extensions.m4, fcntl-safer.m4,
18034         file-type.m4, fileblocks.m4, filemode.m4, fnmatch.m4, fpending.m4,
18035         free.m4, fstypename.m4, fsusage.m4, ftruncate.m4, getaddrinfo.m4,
18036         getcwd-path-max.m4, getcwd.m4, getdate.m4, getdomainname.m4,
18037         getgroups.m4, gethostname.m4, getline.m4, getndelim2.m4,
18038         getnline.m4, getopt.m4, getpagesize.m4, getpass.m4, getsubopt.m4,
18039         gettime.m4, gettimeofday.m4, getugroups.m4, getusershell.m4,
18040         group-member.m4, hard-locale.m4, hash.m4, host-os.m4, human.m4,
18041         idcache.m4, inttostr.m4, isdir.m4, jm-winsz1.m4, jm-winsz2.m4,
18042         link-follow.m4, long-options.m4, ls-mntd-fs.m4, lstat.m4,
18043         makepath.m4, mathl.m4, md5.m4, memcasecmp.m4, memchr.m4,
18044         memcmp.m4, memcoll.m4, memcpy.m4, memmem.m4, memmove.m4,
18045         memrchr.m4, memset.m4, mkdir-slash.m4, mkstemp.m4, mktime.m4,
18046         modechange.m4, mountlist.m4, nanosleep.m4, obstack.m4,
18047         path-concat.m4, pathmax.m4, perl.m4, physmem.m4, poll.m4,
18048         posixtm.m4, posixver.m4, putenv.m4, quote.m4, quotearg.m4,
18049         readdir.m4, readtokens.m4, readutmp.m4, regex.m4, rename.m4,
18050         restrict.m4, rmdir-errno.m4, rmdir.m4, rpmatch.m4, same.m4,
18051         savedir.m4, settime.m4, sha1.m4, sig2str.m4, snprintf.m4,
18052         sockpfaf.m4, st_dm_mode.m4, st_mtim.m4, stat.m4, stdint.m4,
18053         stdio-safer.m4, strchrnul.m4, strdup.m4, strerror.m4,
18054         strerror_r.m4, strftime.m4, strndup.m4, strnlen.m4, strsep.m4,
18055         strtod.m4, strtoimax.m4, strtok_r.m4, strtol.m4, strtoll.m4,
18056         strtoul.m4, strtoull.m4, strtoumax.m4, strverscmp.m4, sysexits.m4,
18057         time_r.m4, timegm.m4, timespec.m4, tm_gmtoff.m4, tzset.m4,
18058         uint32_t.m4, uintptr_t.m4, unistd-safer.m4, unlink-busy.m4,
18059         unlocked-io.m4, uptime.m4, userspec.m4, utimbuf.m4, utime.m4,
18060         utimecmp.m4, utimens.m4, utimes-null.m4, vsnprintf.m4, xalloc.m4,
18061         xgetcwd.m4, xreadlink.m4, xstrndup.m4, xstrtod.m4, xstrtoimax.m4,
18062         xstrtol.m4, xstrtoumax.m4, yesno.m4:
18063         Use an all-permissive copyright notice, recommended by RMS.
18064
18065 2005-01-21  Paul Eggert  <eggert@cs.ucla.edu>
18066
18067         * modules/chdir-long (Depends-on): Remove mempcpy.
18068
18069 2005-01-21  Jim Meyering  <jim@meyering.net>
18070
18071         * lib/openat.h (AT_SYMLINK_NOFOLLOW): Define to 4096, so it's the
18072         same value as for Solaris 9.
18073
18074         * lib/chdir-long.c (chdir_long): Rewrite to remove limitation on
18075         component length.  This included changing the parameter to be
18076         of type `char *' rather than `char const *'.
18077         * lib/chdir-long.h (chdir_long): Update prototype.
18078
18079         * lib/openat.c (fdopendir, fstatat): New functions.
18080         * lib/openat.h: Include headers required for use of DIR and struct
18081         stat.
18082         [AT_SYMLINK_NOFOLLOW]: Define.
18083         (fdopendir, fstatat): Add prototypes.
18084
18085 2005-01-21  Bruno Haible  <bruno@clisp.org>
18086
18087         * modules/classpath: New file.
18088         * MODULES.html.sh (Java): Add classpath.
18089
18090 2005-01-21  Bruno Haible  <bruno@clisp.org>
18091
18092         * lib/classpath.h: New file, from GNU gettext.
18093         * lib/classpath.c: New file, from GNU gettext.
18094
18095 2005-01-20  Simon Josefsson  <jas@extundo.com>
18096
18097         * modules/version-etc-fsf: New file.
18098
18099 2005-01-20  Simon Josefsson  <jas@extundo.com>
18100
18101         * lib/version-etc-fsf.c: New file, with version_etc_copyright.
18102         * lib/version-etc.c: Remove version_etc_copyright.
18103         * lib/version-etc.h (version_etc_copyright): Use [] instead of * in
18104         prototype, suggested by Paul Eggert <eggert@CS.UCLA.EDU>.
18105
18106 2005-01-20  Simon Josefsson  <jas@extundo.com>
18107
18108         * lib/base64.h (isbase64): Add.
18109
18110         * lib/base64.c (isb64): Rename to isbase64, use to_uchar instead of
18111         using a unsigned prototype, don't inline.
18112         (base64_decode): Use it.
18113
18114 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18115
18116         * m4/save-cwd.m4 (gl_SAVE_CWD): Remove check for fcntl; we now assume
18117         it.
18118
18119 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18120
18121         * lib/save-cwd.c (save_cwd): Remove code to support the case
18122         where fchdir is missing or flaky.
18123
18124 2005-01-20  Paul Eggert  <eggert@cs.ucla.edu>
18125
18126         * MODULES.html.sh (Command-line arguments): Add version-etc-fsf.
18127
18128 2005-01-19  Paul Eggert  <eggert@cs.ucla.edu>
18129
18130         * modules/mempcpy (Makefile.am): Remove mention of mempcpy.h;
18131         AC_LIBSOURCES now does this.
18132         * MODULES.html.sh (Sizes of integer types <limits.h>): New element,
18133         with new ullong_max module.
18134
18135 2005-01-19  Bruno Haible  <bruno@clisp.org>
18136
18137         * modules/sh-quote: New file.
18138         * MODULES.html.sh (Executing programs): Add sh-quote.
18139
18140 2005-01-19  Bruno Haible  <bruno@clisp.org>
18141
18142         * lib/sh-quote.h: New file, from GNU gettext.
18143         * lib/sh-quote.c: New file, from GNU gettext.
18144
18145 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18146
18147         Merge from coreutils.
18148         * m4/ullong_max.m4: New file.
18149         * m4/jm-macros.m4 (gl_MACROS): Require gl_ULLONG_MAX.
18150         (gl_MACROS): Assume localeconv exists.
18151
18152 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18153
18154         Merge changes from coreutils, as described below in several
18155         changelogs dated today.
18156
18157         * lib/save-cwd.c: Include "save-cwd.h" before other include files.
18158         (O_DIRECTORY): Remove; not needed here, since "." must be
18159         a directory.  All uses removed.
18160         (save_cwd): Use __sgi || __sun, not sun || __sun.  __sun is
18161         universal on Suns, and we also need to test for IRIX.
18162         Revamp code to use 'if' rather than '#if'.
18163         Avoid unnecessary comparison of cwd->desc to 0.
18164
18165         * lib/utimens.c (futimens): Robustify the previous patch, by checking
18166         for known valid error numbers rather than observed invalid ones.
18167
18168 2005-01-18  Paul Eggert  <eggert@cs.ucla.edu>
18169
18170         * modules/ullong_max: New file.
18171
18172         * modules/chdir-long, modules/openat: New files.
18173         * modules/save-cwd (Depends-on): Depend on chdir-long.
18174         (Makefile.am): Remove lib_SOURCES; now handled by AC_LIBSOURCES.
18175
18176 2005-01-18  Jim Meyering  <jim@meyering.net>
18177
18178         Merge from coreutils.
18179         * m4/chdir-long.m4, m4/openat.m4: New files.
18180         * m4/save-cwd.m4 (gl_SAVE_CWD): Add AC_LIBSOURCES for save-cwd.c,
18181         save-cwd.h.  Add AC_LIBOBJ for save-cwd.
18182         * m4/chown.m4 (gl_FUNC_CHOWN): When cross-compiling, assume that chown
18183         is sane and DOES follow symlinks.  Besides, testing 20 different
18184         systems found no broken chown implementations.
18185         Prompted by a change in rsync's copy of this macro.
18186         * m4/jm-macros.m4 (gl_MACROS): Require gl_FUNC_CHDIR_LONG.
18187
18188         * m4/lchown.m4 (gl_FUNC_LCHOWN): Use AC_LIBSOURCES.
18189
18190         * m4/utimes.m4: Work around tests/touch/empty-file failure on a system
18191         (sparc64, Linux-2.4.28, glibc-2.3.3) that didn't honor utimes'
18192         NULL-means-set-to-current-time semantics.
18193         Remove temporary file immediately, rather than waiting
18194         for configure's at-exit trap code to do it.
18195
18196 2005-01-18  Jim Meyering  <jim@meyering.net>
18197
18198         * lib/version-etc.c (version_etc_copyright): Update copyright date.
18199
18200         * lib/utimens.c (futimens): Account for the fact that futimes
18201         can also fail with errno == ENOSYS or errno == ENOENT.
18202         Patch from Dmitry V. Levin.
18203
18204         Change the name of the robust chdir function from chdir to chdir_long.
18205         * lib/save-cwd.c: Include chdir-long.h rather than chdir.h.
18206         (restore_cwd): Use chdir_long, not chdir.
18207         * lib/chdir-long.c: Renamed from chdir.c.
18208         * lib/chdir-long.h: Renamed from chdir.h.
18209         [!defined PATH_MAX]: Define chdir_long to chdir on systems like the
18210         Hurd.
18211
18212 2005-01-18  Bruno Haible  <bruno@clisp.org>
18213
18214         * m4/allocsa.m4, m4/codeset.m4, m4/copy-file.m4, m4/eaccess.m4:
18215         * m4/eealloc.m4, m4/eoverflow.m4, m4/execute.m4, m4/fatal-signal.m4:
18216         * m4/findprog.m4, m4/glibc21.m4, m4/iconv.m4, m4/intmax_t.m4:
18217         * m4/inttypes_h.m4, m4/lib-ld.m4, m4/lib-link.m4, m4/lib-prefix.m4:
18218         * m4/linebreak.m4, m4/localcharset.m4, m4/longdouble.m4:
18219         * m4/longlong.m4, m4/mbrtowc.m4, m4/mbstate_t.m4, m4/mbswidth.m4:
18220         * m4/mkdtemp.m4, m4/pipe.m4, m4/readlink.m4, m4/safe-read.m4:
18221         * m4/safe-write.m4, m4/setenv.m4, m4/sig_atomic_t.m4:
18222         * m4/signalblocking.m4, m4/signed.m4, m4/size_max.m4, m4/ssize_t.m4:
18223         * m4/stdbool.m4, m4/stdint_h.m4, m4/stpcpy.m4, m4/stpncpy.m4:
18224         * m4/strcase.m4, m4/strcspn.m4, m4/strpbrk.m4, m4/strstr.m4:
18225         * m4/ucs4-utf.m4, m4/uintmax_t.m4, m4/ulonglong.m4, m4/unicodeio.m4:
18226         * m4/utf-ucs4.m4, m4/vasnprintf.m4, m4/vasprintf.m4:
18227         * m4/wait-process.m4, m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4:
18228         Use an all-permissive copyright notice, recommended by RMS.
18229
18230 2005-01-18  Bob Proulx  <bob@proulx.com>
18231
18232         * lib/obstack.c [DEFAULT_ALIGNMENT]: Use an intermediate type to
18233         simplify offsetof() macro construct to avoid compile failure with
18234         native HP-UX 11.0 ANSI C compiler.
18235
18236 2005-01-17  Bruno Haible  <bruno@clisp.org>
18237
18238         * lib/stpncpy.c: Remove HAVE_STPNCPY and gnu_stpncpy renaming,
18239         redundant because stpncpy.m4 takes care of it.
18240
18241 2005-01-17  Bruno Haible  <bruno@clisp.org>
18242
18243         * lib/progreloc.c: Include xalloc.h instead of xmalloc.h.
18244
18245 2005-01-17  Bruno Haible  <bruno@clisp.org>
18246
18247         * lib/progreloc.c (xstrdup): Define as strdup if no xmalloc should be
18248         used.
18249
18250 2005-01-17  Bruno Haible  <bruno@clisp.org>
18251
18252         * lib/fwriteerror.h (fwriteerror): Change specification to include
18253         fclose.
18254         * lib/fwriteerror.c: Include <stdbool.h>.
18255         (fwriteerror): At the end, close the file stream. Record whether
18256         stdout was already closed.
18257
18258 2005-01-17  Bruno Haible  <bruno@clisp.org>
18259
18260         * lib/execute.c (environ): Declare if needed.
18261         * lib/pipe.c (environ): Likewise.
18262         Reported by Michael Schloh von Bennewitz <michael.schloh@cw.com>.
18263
18264 2005-01-11  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18265
18266         * modules/argp: Depend on vsnprintf
18267
18268 2005-01-10  Jim Meyering  <jim@meyering.net>
18269
18270         * modules/closeout (Depends-on): Add atexit.
18271
18272 2005-01-06  Bruno Haible  <bruno@clisp.org>
18273
18274         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Rename stpncpy to gnu_stpncpy here.
18275
18276 2005-01-04  Paul Eggert  <eggert@cs.ucla.edu>
18277
18278         * lib/human.c (SIZE_MAX, UINTMAX_MAX): Move these conditional
18279         definitions to be after all include files, to avoid collisions.
18280         Problem reported by Bob Proulx.
18281
18282 2005-01-04  Jim Meyering  <jim@meyering.net>
18283
18284         Changes imported from coreutils.
18285         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Rather than using "conftestXXXXXX"
18286         as the mkstemp template, use a temporary directory and an
18287         8.3-friendly template to avoid trouble on systems like DJGPP.
18288         Reported by Juan M. Guerrero via Stepan Kasal.
18289         * m4/(gl_FUNC_MKSTEMP): Include <unistd.h> for the declaration of
18290         close. Remove the temporary directory right away, rather than waiting
18291         for configure's at-exit trap code to do it.
18292         Suggestion from Stepan Kasal.
18293
18294 2005-01-01  Simon Josefsson  <jas@extundo.com>
18295
18296         * gnulib-tool: Print #include directives when --import'ing.
18297
18298 2004-12-28  Simon Josefsson  <jas@extundo.com>
18299
18300         * tests/test-base64.c: Include required header files.  Remove
18301         unused variables.
18302
18303 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18304
18305         * modules/error (Depends-on): Remove gettext.
18306
18307 2004-12-28  Paul Eggert  <eggert@cs.ucla.edu>
18308
18309         * lib/error.c [!_LIBC && !ENABLE_NLS]: Do not include "gettext.h";
18310         not needed.  This removes a dependency on the gettext module.
18311         [defined _LIBC]: Do not include <libintl.h>; not needed.
18312
18313 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18314
18315         * m4/c-strtod.m4 (gl_C99_STRTOLD): New macro.
18316         (gl_C_STRTOD): Use it instead of AC_CHECK_DECLS_ONCE(strtold).
18317
18318 2004-12-24  Paul Eggert  <eggert@cs.ucla.edu>
18319
18320         * lib/c-strtod.c (STRTOD): Depend on HAVE_C99_STRTOLD, not
18321         HAVE_DECL_STRTOLD.
18322
18323 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18324
18325         * modules/getdate (Depends-on): Remove alloca-opt.
18326
18327 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18328
18329         * m4/getdate.m4 (gl_GETDATE): Remove AC_FUNC_ALLOCA.
18330
18331 2004-12-23  Paul Eggert  <eggert@cs.ucla.edu>
18332
18333         * lib/argp-parse.c: Include <stddef.h>.
18334         (alignof, alignto): New macros.
18335         (parser_init): Don't assume that void * is aligned sufficiently
18336         for struct option.
18337
18338         * lib/getdate.y (YYSTACK_USE_ALLOCA): Define to 0, since there's no
18339         need to extend the stack.
18340         (YYINITDEPTH): New macro, so that the initial stack isn't overly
18341         large.
18342
18343 2004-12-22  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18344
18345         * lib/argp-parse.c (parser_init): Avoid arithmetics on void pointers.
18346
18347 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18348
18349         * modules/regex (lib_SOURCES): Remove regex.c, undoing previous
18350         (2004-10-24) change.  Apparently this was a false alarm.
18351
18352         * modules/getdate: Depend on alloca-opt, not alloca.
18353
18354 2004-12-19  Paul Eggert  <eggert@cs.ucla.edu>
18355
18356         * lib/alloca_.h: Conditionalize on _GNULIB_ALLOCA_H, not _ALLOCA_H.
18357         Remove now-obsolete comment about AIX.
18358         * lib/getdate.y: Include <alloca.h> only if HAVE_ALLOCA.
18359         (YYSTACK_USE_ALLOCA): Define to 0 if !HAVE_ALLOCA.
18360         (YYMAXDEPTH): New macro.
18361
18362 2004-12-18  Simon Josefsson  <jas@extundo.com>
18363
18364         * modules/alloca: Depend on alloca-opt, instead of duplicating it.
18365
18366 2004-12-18  Bruno Haible  <bruno@clisp.org>
18367
18368         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Also test for sigaction.
18369
18370 2004-12-18  Bruno Haible  <bruno@clisp.org>
18371
18372         * lib/fatal-signal.c (fatal_signals): Make non-const.
18373         (init_fatal_signals): New function.
18374         (uninstall_handlers, install_handlers): Ignore signals that were set to
18375         SIG_IGN.
18376         (at_fatal_signal): Call init_fatal_signals.
18377         (init_fatal_signal_set): Likewise. Ignore signals that were set to
18378         SIG_IGN.
18379         Reported by Paul Eggert.
18380
18381 2004-12-18  Bruno Haible  <bruno@clisp.org>
18382
18383         * doc/alloca.texi: New file.
18384         * doc/alloca-opt.texi: New file.
18385
18386 2004-12-17  Jim Meyering  <jim@meyering.net>
18387
18388         * config/install-sh: Use `(exit N); exit N', not `(exit N); exit'.
18389         Otherwise, install-sh could exit with improper exit status when
18390         exiting via a trapped interrupt.  Thanks to a report from Bob Proulx.
18391
18392 2004-12-16  Simon Josefsson  <jas@extundo.com>
18393
18394         * tests/test-base64.c: Add license.
18395
18396 2004-12-15  Stepan Kasal  <address@hidden>
18397
18398         * gnulib-tool (func_emit_lib_Makefile_am): Shorten a long sed command.
18399
18400 2004-12-12  Paul Eggert  <eggert@cs.ucla.edu>
18401
18402         * modules/getcwd (Files): Add m4/d-ino.m4.
18403         Suggested by Mark D. Baushke.
18404
18405 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
18406
18407         * lib/getdate.y (textint): New member "negative".
18408         (time_zone_hhmm): New function.
18409         Expect 14 shift-reduce conflicts, not 13.
18410         (o_colon_minutes): New rule.
18411         (time, zone): Use it to add support for +HH:MM, UTC+HH:MM.
18412         (yylex): Set the "negative" member of signed numbers.
18413
18414 2004-12-08  Paul Eggert  <eggert@cs.ucla.edu>
18415
18416         * doc/getdate.texi (Time of day items, Time zone items):
18417         Describe new formats +00:00, UTC+00:00.
18418
18419 2004-12-07  Paul Eggert  <eggert@cs.ucla.edu>
18420
18421         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): Fix typo in previous change:
18422         spurious "-l"s.  Problem reported by Stepan Kasal.
18423
18424 2004-12-06  Paul Eggert  <eggert@cs.ucla.edu>
18425
18426         * m4/ls-mntd-fs.m4 (AC_FUNC_GETMNTENT): New macro, to work around bug
18427         in Autoconf 2.59.  Problem reported by Mark D. Baushke.
18428
18429 2004-12-04  Simon Josefsson  <jas@extundo.com>
18430
18431         * modules/getaddrinfo (License): Add LGPL, reported by Yoann
18432         Vandoorselaere <yoann@prelude-ids.org>.
18433
18434 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18435
18436         Changes imported from coreutils.
18437         * m4/hard-locale.m4 (gl_HARD_LOCALE): Assume locale.h and setlocale
18438         exist.
18439         * m4/human.m4 (gl_HUMAN): Assume locale.h and localeconv exist.
18440
18441 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18442
18443         Changes imported from coreutils.
18444         * lib/hard-locale.c: Assume <locale.h> exists.
18445         Include "strdup.h".
18446         (GLIBC_VERSION): New macro.
18447         (hard_locale): Assume setlocale exists.
18448         Rewrite to avoid #ifdef.
18449         Use strdup rather than malloc + strcpy.
18450         * lib/human.c: Assume <locale.h> exists.
18451         (human_readable): Assume localeconv exists.
18452
18453 2004-12-04  Paul Eggert  <eggert@cs.ucla.edu>
18454
18455         * modules/hard-locale (Depends-on): Add strdup.
18456
18457 2004-12-01  Jakub Jelinek  <jakub@redhat.com>
18458
18459         * lib/mktime.c (__mktime_internal): If SEC_REQUESTED != SEC,
18460         convert T2, not T.  (Imported from libc.)
18461
18462 2004-11-30  Simon Josefsson  <jas@extundo.com>
18463
18464         * modules/restrict (License): Change to LGPL.
18465
18466 2004-11-30  Simon Josefsson  <jas@extundo.com>
18467
18468         * m4/restrict.m4: Add copyright and copying conditions.
18469
18470 2004-11-30  Simon Josefsson  <jas@extundo.com>
18471
18472         * m4/base64.m4: New file.
18473
18474 2004-11-30  Simon Josefsson  <jas@extundo.com>
18475
18476         * MODULES.html.sh (Extra functions based on ANSI C 89): Add
18477         base64.
18478
18479         * tests/test-base64.c: New file.
18480
18481         * modules/base64: New file.
18482
18483 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
18484
18485         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX):
18486         Define HAVE_PARTLY_WORKING_GETCWD if getcwd is partly working.
18487
18488         * m4/readutmp.m4 (gl_READUTMP): Don't check for sys/param.h.
18489
18490 2004-11-30  Paul Eggert  <eggert@cs.ucla.edu>
18491
18492         * lib/getcwd.c (is_ENAMETOOLONG): New macro.
18493         (__getcwd.c): Don't restore errno; glibc doesn't.
18494         [HAVE_PARTLY_WORKING_GETCWD && !defined AT_FDCWD]: Try system getcwd
18495         first, falling back to our code only if its results look suspicious.
18496         Ensure that the resulting buffer is only as large as necessary.
18497
18498         * lib/readutmp.c: Include readutmp.h first.
18499         Include <errno.h>, since readutmp.h no longer does that.
18500         * lib/readutmp.h: Don't include <errno.h>,
18501         <sys/param.h>, <time.h>; not needed to establish interface.
18502         (errno): Remove decl.
18503         (HAVE_STRUCT_XTMP_UT_TYPE): Remove; no longer needed.
18504         (UT_TYPE_EQ, UT_TYPE_NOT_DEFINED, UT_TYPE_BOOT_TIME,
18505         UT_TYPE_USER_PROCESS, IS_USER_PROCESS): New macros.
18506
18507 2004-11-28  Simon Josefsson  <jas@extundo.com>
18508
18509         * lib/base64.h, base64.c: New file.
18510
18511 2004-11-27  Paul Eggert  <eggert@cs.ucla.edu>
18512
18513         * lib/getcwd.h: New file, which I forgot to check in on 2004-11-25.
18514
18515 2004-11-26  Paul Eggert  <eggert@cs.ucla.edu>
18516
18517         * modules/getcwd (Files): Add lib/getcwd.h, m4/getcwd.m4.
18518         (Depends-on): Remove pathmax, same.  Add mempcpy.
18519         (configure.ac): GL_FUNC_GETCWD_PATH_MAX -> gl_FUNC_GETCWD.
18520         (Makefile.am): Append getcwd.h to lib_SOURCES.
18521         (Include): Add getcwd.h.
18522         (Maintainer): Change from Jim Meyering to "all, glibc",
18523         since getdate now uses intended-for-glibc code.
18524         * modules/xgetcwd (Files): Remove m4/getcwd.m4.
18525         (Depends-on): Depend on getcwd.  Do not depend on pathmax.
18526
18527 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
18528
18529         Fix problems reported by Scott S. Tinsley for HP-UX 11.11 using
18530         HP's ANSI C compiler.
18531         * lib/fsusage.c (statvfs) [HAVE_SYS_STATVFS_H]: Remove decl.
18532         Declaring int functions causes warnings on some modern systems and
18533         shouldn't be needed to compile on ancient ones.
18534         * lib/same.c (MIN) [defined MIN]: Don't define, since it's already
18535         defined.
18536
18537         * lib/getcwd.c: Replace by a copy of glibc/sysdeps/posix/getcwd.c, but
18538         with the following changes.
18539         (__set_errno): Parenthesize properly.
18540         Include <stdbool.h>.
18541         (MIN, MAX, MATCHING_INO): New macros.
18542         (__getcwd): Define with prototype, not K&R form.
18543         Use heuristics to allocate default buffer on stack if possible.
18544         If AT_FDCWD is defined, use openat and fstatat to avoid O(N**2)
18545         behavior, and to avoid the PATH_MAX limit when computing
18546         ../../../../...
18547         Use MATCHING_INO to compare inode number to file.
18548         Check for arithmetic overflow in size calculations.
18549         Fix bug in reallocation of dot array that caused getcwd to fail
18550         on directories nested deeper than 75.
18551         Be more careful about saving errno on error.
18552         Do not use realloc; use only free+malloc, as this is a bit
18553         more flexible and avoids a needless copy operation.
18554         Do not inspect st_dev and st_ino for symbolic links; POSIX
18555         doesn't specify the latter.
18556         Check for closedir errors.
18557         Avoid needless casts.
18558         Use "#ifdef weak_alias" around weak_alias, to be like other
18559         glibc code.
18560         The following changes to getcwd.c have effect only when used in
18561         gnulib; they have no effect inside glibc proper.
18562         (#pragma alloca) [defined _AIX && !defined __GNUC__]: Remove,
18563         as alloca isn't used.
18564         (alloca, __alloca): Likewise.
18565         [!_LIBC]: Include "getcwd.h", "mempcpy.h".
18566         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
18567         unconditionally, as gnulib assumes C89 or better.
18568         Do not include <sys/param.h>.
18569         (errno) [!defined __GNU_LIBRARY__ && !defined STDC_HEADERS]: Remove
18570         no-longer-necessary 'extern int errno' decl; gnulib assumes C89 or
18571         better.
18572         (NULL) [!defined NULL]: Remove; we assume C89 or better.
18573         Include <dirent.h> in a way that is compatible with modern Autoconf.
18574         (_D_ALLOC_NAMELEN, _D_EXACT_NAMLEN):
18575         New macros, if not already defined.
18576         Include <unistd.h> if _LIBC, not if __GNU_LIBRARY__.
18577         Use "_LIBC", not "defined _LIBC", for consistency.
18578         (HAVE_MEMPCPY): Remove; no longer needed now that gnulib has
18579         a mempcpy module.
18580         (__lstat, __closedir, __opendir, __readdir) [!_LIBC]: New macros.
18581         (GETCWD_RETURN_TYPE): Remove.  All uses replaced by char *.
18582         * lib/xgetcwd.c: David MacKenzie's old code was removed, so give
18583         credit only to Jim Meyering and adjust the copyright dates.
18584         Do not include <limits.h>, <stdio.h>, <sys/types.h>,
18585         <stdlib.h>, <unistd.h>, "pathmax.h".
18586         Instead, include "xgetcwd.h" (first) and "getcwd.h".
18587         (INITIAL_BUFFER_SIZE): Remove.
18588         (xgetcwd): Rely on getcwd, since we now depend on a reliable one.
18589
18590 2004-11-25  Paul Eggert  <eggert@cs.ucla.edu>
18591
18592         * m4/getcwd-path-max.m4 (gl_FUNC_GETCWD_PATH_MAX): Renamed from
18593         GL_FUNC_GETCWD_PATH_MAX for consistency.  All uses changed.
18594         Use the _ONCE methods, for efficiency.
18595         Check for fcntl.h.  In test program, include <errno.h>
18596         and <fcntl.h> if available.  Remove old K&R cruft from
18597         test program.  Check for common errors in GNU/Linux,
18598         OpenBSD, and Solaris.  Just set gl_cv_func_getcwd_path_max;
18599         don't do AC_LIBOBJ, as that's getcwd.m4's job.
18600         * m4/getcwd.m4 (gl_FUNC_GETCWD_NULL): Renamed from
18601         AC_FUNC_GETCWD_NULL.  All used changed.  Change cache variable
18602         name accordingly.
18603         (gl_FUNC_GETCWD, gl_PREREQ_GETCWD): New macros.  Revamp to
18604         accommodate new getcwd.c.
18605         * m4/jm-macros.m4 (gl_MACROS): Don't require GL_FUNC_GETCWD_PATH_MAX.
18606         * m4/prereq.m4 (gl_PREREQ): Add gl_FUNC_MEMPCPY.
18607         * m4/xgetcwd.m4 (gl_XGETCWD): Replace with gl_FUNC_GETCWD, since
18608         that's all we need now.
18609
18610 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18611
18612         * m4/argp.m4 (gl_ARGP): Require gl_GETOPT_SUBSTITUTE unconditionally:
18613         argp-parse.c depends on getopt internals, that means we should
18614         always use our getopt, to be on the safe side.
18615         * m4/getopt.m4 (gl_GETOPT): Check if GETOPT_H is already set, in
18616         order not to spoil the result of an eventual previous invocation
18617         of gl_GETOPT_SUBSTITUTE.
18618
18619 2004-11-23  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
18620
18621         * lib/getopt_.h: Re-addition of __getopt_argv_const caused
18622         redefinition warnings. To avoid them, include the defines
18623         in `#if !defined __need_getopt ... #endif'. The only place
18624         where __getopt_argv_const is used is in definitions
18625         of getopt_long and getopt_long_only below, which are as well
18626         protected by `#ifndef __need_getopt'.
18627         [defined __GETOPT_PREFIX && !defined __need_getopt]: Undef
18628         __need_getopt after including <stdio.h> and <unistd.h> These
18629         headers might have defined it.
18630
18631 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
18632
18633         * m4/utimens.m4 (gl_UTIMENS): Check for futimes function.
18634
18635 2004-11-23  Paul Eggert  <eggert@cs.ucla.edu>
18636
18637         * lib/utimens.c (__attribute__, ATTRIBUTE_UNUSED): New macros.
18638         (futimens): New function, which uses futimes if available.
18639         (futimens, utimens): Support timespec==NULL, with same semantics
18640         as utime and utimens.
18641         * lib/utimens.h (futimens): New decl.
18642
18643 2004-11-23  Jim Meyering  <jim@meyering.net>
18644
18645         * lib/getopt_.h: Remove trailing blanks.
18646
18647 2004-11-23  Jim Meyering  <jim@meyering.net>
18648
18649         * lib/__fpending.c: Add comment.
18650
18651 2004-11-22  Paul Eggert  <eggert@cs.ucla.edu>
18652
18653         * modules/canonicalize (Depends-on): Add xreadlink.
18654         Problem reported by James Youngman.
18655
18656 2004-11-20  Paul Eggert  <eggert@cs.ucla.edu>
18657
18658         * lib/getopt_.h (__GETOPT_CONCAT, __GETOPT_XCONCAT, __GETOPT_ID):
18659         New macros.
18660         (getopt, getopt_long, getopt_long_only, optarg, opterr, optind,
18661         optopt): Use them instead of invoking ## directly; otherwise, the
18662         symbols will be __GETOPT_PREFIXgetopt rather than rpl_getopt.
18663
18664 2004-11-19  Bruno Haible  <bruno@clisp.org>
18665
18666         * lib/strtok_r.c: Move comments from here...
18667         * lib/strtok_r.h: ... to here.
18668
18669 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
18670
18671         * m4/calloc.m4 (_AC_FUNC_CALLOC_IF): Check for buggy calloc
18672         implementations that mishandle size_t overflow.
18673
18674 2004-11-17  Paul Eggert  <eggert@cs.ucla.edu>
18675
18676         * lib/realloc.c (rpl_realloc): Call 'free' if n==0, since realloc
18677         might fail.  Problem reported by Yoann Vandoorselaere.
18678         * lib/calloc.c (rpl_calloc): Defend against buggy calloc
18679         implementations that mishandle size_t overflow.
18680
18681 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18682
18683         * modules/canon-host (Depends-on): Add strdup.
18684
18685 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18686
18687         * m4/canon-host.m4 (gl_CANON_HOST): Check for getaddrinfo.
18688
18689 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18690
18691         * lib/canon-host.c: Include "strdup.h".
18692         (canon_host): Use getaddrinfo if available, so that IPv6 works.
18693         Use strdup instead of malloc/strcpy to duplicate strings.
18694
18695         * lib/human.h (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
18696         (human_space_before_unit): New constant.
18697         * lib/human.c (human_readable): Support it.
18698
18699         * lib/xgetcwd.c: Include <limits.h>, for PATH_MAX.
18700         (xgetcwd): Set errno correctly when failing.
18701         Work around Solaris 9 bug: getcwd sets errno==ERANGE even though
18702         the failure is actually due to a PATH_MAX problem.
18703
18704         Further getopt changes to make it more likely that glibc will
18705         buy the changes back.
18706         * lib/getopt.c (POSIXLY_CORRECT): New constant.
18707         (getopt): Use it, so to preserve glibc semantic
18708         * lib/getopt1.c (getopt_long, getopt_long_only): Arg is char * const *
18709         when compiling for libc.
18710         * lib/getopt_.h (__getopt_argv_const): Bring it back.
18711         (getopt_long, getopt_long_only): Use it.
18712
18713         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
18714         _getopt_internal): New arg POSIXLY_CORRECT.  All callers changed.
18715         (getopt): Argv is now char * const *, as per standard.
18716         (_getopt_internal_r, _getopt_internal): Argv is now char **,
18717         not char *__getopt_argv_const *.
18718         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
18719         _getopt_long_only_r): Likewise.
18720         * lib/getopt_.h (getopt, getopt_long, geopt_long_only): Likewise.
18721         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
18722         _getopt_long_r, _getopt_long_only_r): Likewise.
18723         * lib/getopt_.h (__getopt_argv_const): Remove.
18724         (getopt): Argv is now char * const *, as per standard.
18725
18726         * lib/getdate.y (tORDINAL): New token.
18727         (day, relunit): Allow it for relative times.
18728         (relative_time_table): Use tORDINAL for ordinals.
18729
18730 2004-11-16  Paul Eggert  <eggert@cs.ucla.edu>
18731
18732         * doc/getdate.texi (General date syntax): "next" is 1, not 2.
18733         Document that "second" isn't allowed as an ordinal number.
18734
18735 2004-11-16  Jim Meyering  <jim@meyering.net>
18736
18737         * modules/closeout (Depends-on): Add fpending.
18738
18739 2004-11-15  Jim Meyering  <jim@meyering.net>
18740
18741         * lib/closeout.c: Include "__fpending.h" once again.
18742         Include <stdbool.h>.
18743         (close_stdout): Don't fail just because stdout was closed initially,
18744         since some programs don't write to stdout in the normal course of
18745         operation (other than --version and --help), and we don't want this
18746         function to make e.g. `touch file >&-' fail.
18747         But do fail if it was closed and someone has tried to write to it.
18748         E.g., `printf foo >&-' must fail.
18749
18750 2004-11-13  Jim Meyering  <jim@meyering.net>
18751
18752         * m4/jm-macros.m4: Do require gl_FUNC_FPENDING.
18753
18754 2004-11-12  Simon Josefsson  <jas@extundo.com>
18755
18756         * config/srclist.txt: Add strtok_r.c, glibc bought our changes, but a
18757         small doc fix is still pending.
18758
18759 2004-11-11  Simon Josefsson  <jas@extundo.com>
18760
18761         * modules/strtok_r: New file.
18762
18763         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18764         strtok_r.
18765
18766 2004-11-11  Simon Josefsson  <jas@extundo.com>
18767
18768         * m4/strtok_r.m4: New file.
18769
18770         * m4/getopt.m4: Replace opterr.
18771
18772 2004-11-11  Simon Josefsson  <jas@extundo.com>
18773
18774         * lib/strtok_r.h, strtok_r.c: New file.
18775
18776 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18777
18778         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): Define __GETOPT_PREFIX instead
18779         of replacing opterr, getopt, etc.  This should handle the
18780         powerpc-apple-darwin5.5 problem recently noted by Simon Josefsson.
18781
18782 2004-11-11  Paul Eggert  <eggert@cs.ucla.edu>
18783
18784         * lib/getopt_.h (__getopt_argv_const): New macro, to be used so that
18785         we can stop lying to compilers about the constness of argv when we
18786         are compiled outside glibc.
18787         (getopt, getopt_long, getopt_long_only): Use it.
18788         * lib/getopt.c (_getopt_initialize, _getopt_internal_r,
18789         _getopt_internal, getopt): Likewise.
18790         * lib/getopt1.c (getopt_long, _getopt_long_r, getopt_long_only,
18791         _getopt_long_only_r): Likewise.
18792         * lib/getopt_int.h (_getopt_internal, _getopt_internal_r,
18793         _getopt_long_r, _getopt_long_only_r): Likewise.
18794
18795         * lib/getopt_.h [defined __GETOPT_PREFIX && !defined __need_getopt]:
18796         Include <stdlib.h> and <stdio.h>, and <unistd.h> if available.
18797         Then rename getopt to __GETOPT_PREFIX##getopt, and so forth for
18798         the other external symbols.
18799         (getopt) [!defined __GNU_LIBRARY]: Use prototype, not old-style
18800         declaration, since the above renaming now works around collisions.
18801
18802 2004-11-11  Jim Meyering  <jim@meyering.net>
18803
18804         * lib/linebreak.c: Remove trailing blanks.
18805         * lib/alloca_.h: Likewise.
18806         * lib/acosl.c: Likewise.
18807         * lib/euidaccess.c: Likewise.
18808         * lib/allocsa.h: Likewise.
18809
18810 2004-11-10  Simon Josefsson  <jas@extundo.com>
18811
18812         * m4/getaddrinfo.m4: New file.
18813
18814 2004-11-10  Simon Josefsson  <jas@extundo.com>
18815
18816         * lib/getaddrinfo.h, lib/getaddrinfo.c: New files.
18817
18818 2004-11-10  Simon Josefsson  <jas@extundo.com>
18819
18820         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
18821         getaddrinfo.
18822
18823         * modules/getaddrinfo: New file.
18824
18825 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18826
18827         * m4/prereq.m4 (gl_PREREQ): Require gt_FUNC_SETENV.
18828
18829 2004-11-10  Paul Eggert  <eggert@cs.ucla.edu>
18830
18831         * lib/mktime.c (SHR): New macro, which is a portable
18832         substitute for >> that should work even on Crays.
18833         (TIME_T_MIDPOINT, ydhms_diff, __mktime_internal): Use it.
18834         Problem reported by Mark D. Baushke in
18835         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00071.html>.
18836         * lib/getdate.y (SHR): Likewise.
18837         (tm_diff): Use it.
18838         * lib/strftime.c (SHR): Likewise.
18839         (tm_diff): Use it.
18840         * lib/quotearg.c (struct quoting_options): Use unsigned int for
18841         quote_these_too, so that right shifts are well defined.  All uses
18842         changed.
18843
18844 2004-11-10  Jim Meyering  <jim@meyering.net>
18845
18846         Ensure that no close failure goes unreported.
18847         * lib/closeout.c (close_stdout): Always close stdout.  I.e., don't
18848         return early when it seems there's nothing to flush.
18849         Don't include __fpending.h.
18850
18851 2004-11-10  Jim Meyering  <jim@meyering.net>
18852
18853         * modules/closeout (Depends-on): Remove fpending.
18854
18855 2004-11-10  Jim Meyering  <jim@meyering.net>
18856
18857         * m4/jm-macros.m4 (gl_MACROS): Don't require gl_FUNC_FPENDING.
18858
18859 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18860
18861         * m4/strftime.m4 (_gl_STRFTIME_PREREQS): Remove.  Move its body to
18862         gl_FUNC_STRFTIME.
18863         (gl_FUNC_STRFTIME): Use AC_CHECK_FUNCS_ONCE and AC_CHECK_HEADERS_ONCE
18864         and AC_REQUIRE when possible, to avoid duplicate checks.
18865         Check for <wchar.h>.
18866
18867 2004-11-09  Paul Eggert  <eggert@cs.ucla.edu>
18868
18869         * lib/strftime.c (DO_MULTIBYTE): Check for wchar.h, too.
18870
18871 2004-11-09  Bruno Haible  <bruno@clisp.org>
18872
18873         * m4/sockpfaf.m4: New file.
18874
18875 2004-11-05  Bruno Haible  <bruno@clisp.org>
18876
18877         * lib/readlink.c: Include stddef.h, needed for size_t on Woe32.
18878         Reported by Mark D. Baushke <mdb@cvshome.org>.
18879
18880 2004-11-04  Bruno Haible  <bruno@clisp.org>
18881
18882         2004-09-11  Bruno Haible  <bruno@clisp.org>
18883                 * allocsa.valgrind: New file.
18884         2004-02-06  Bruno Haible  <bruno@clisp.org>
18885                 * allocsa.h (sa_alignof): Define differently with HP-UX cc, to
18886                 avoid a bug of this cc on HP-UX 10.20 dealing with enums.
18887                 Reported by Christopher Seip <chris.seip@hp.com>.
18888
18889 2004-11-04  Bruno Haible  <bruno@clisp.org>
18890
18891         * modules/allocsa (Files): Add lib/allocsa.valgrind.
18892         (Makefile.am): Distribute it.
18893
18894 2004-11-03  Paul Eggert  <eggert@cs.ucla.edu>
18895
18896         * lib/xreadlink.c (xreadlink): AIX and HP-UX readlink return -1
18897         with errno == ERANGE if the buffer is too small.
18898         Problem reported by Mark D. Baushke.
18899
18900 2004-11-03  Albert Chin  <china@thewrittenword.com>
18901             Paul Eggert  <eggert@cs.ucla.edu>
18902
18903         * m4/uint32_t.m4 (gl_AC_TYPE_UINT32_T): When determining uint32_t
18904         equivalent, substitute $ac_type for equivalent type rather than
18905         blindly using uint32_t *always* which won't work if uint32_t is not
18906         available.  Define _UINT32_T to work around typedef of uint32_t if
18907         <sys/sched.h>, <pthread.h>, or <semaphore.h> used on Solaris
18908         2.5.1.
18909
18910 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18911
18912         * m4/jm-macros.m4: Sync from coreutils.
18913         (gl_MACROS): Check for mbrlen, for pathchk.
18914         (gl_CHECK_ALL_TYPES): Require AC_TYPE_MBSTATE_T, for pathchk.
18915
18916 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18917
18918         * lib/xreadlink.c (MAXSIZE): New macro.
18919         (xreadlink): Use it instead of SSIZE_MAX.  Ensure initial buffer
18920         size does not exceed MAXSIZE.  Avoid cast.
18921         As suggested by Mark D. Baushke in
18922         <http://lists.gnu.org/archive/html/bug-gnulib/2004-11/msg00009.html>,
18923         if readlink fails with buffer size just under MAXSIZE, try again
18924         with MAXSIZE.
18925
18926 2004-11-02  Paul Eggert  <eggert@cs.ucla.edu>
18927
18928         * config/srclist.txt: Add mktime.c; glibc bought all our changes.
18929
18930 2004-11-02  Derek R. Price  <derek@ximbiot.com>
18931         and  Paul Eggert  <eggert@cs.ucla.edu>
18932
18933         * lib/getdate.y [!TEST]: Include <stdio.h>, since we use sprintf now.
18934         (get_date): Overparenthesize to avoid GCC warning.
18935
18936 2004-11-02  Bruno Haible  <bruno@clisp.org>
18937
18938         * m4/setenv.m4 (gt_FUNC_SETENV): Define VOID_UNSETENV if unsetenv()
18939         returns void.
18940
18941 2004-11-02  Bruno Haible  <bruno@clisp.org>
18942
18943         * lib/setenv.h (unsetenv): Define as a macro if the system's unsetenv()
18944         function returns void.
18945
18946 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18947
18948         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for declarations of
18949         fflush_unlocked, flockfile, funlockfile, funlockfile,
18950         fputs_unlocked, putc_unlocked.
18951
18952 2004-11-01  Paul Eggert  <eggert@cs.ucla.edu>
18953
18954         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
18955         (funlockfile, fputs_unlocked, putc_unlocked): Don't define if
18956         already declared.
18957
18958 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18959
18960         * modules/getdate (Files): Add doc/getdate.texi.
18961         (Depends-on): Add setenv, xalloc.
18962
18963 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18964
18965         * lib/getdate.y: Add support for TZ="foo" within a date string.
18966         Fix some bugs near time_t boundaries.  Reject dates with
18967         out-of-range components, e.g., "Sept 31".
18968         Include <stdlib.h>, "setenv.h", "xalloc.h".
18969         (ISDIGIT_LOCALE): Remove; unused.
18970         Note that the TZ and time functions used here are not reentrant.
18971         (mktime_ok, get_tz): New functions.
18972         (TZBUFSIZE): New constant.
18973         (get_date): Parse leading TZ="foo".  Reject out-of-range components;.
18974         This requires that we sometimes generate our own TZ="XXX..." setting.
18975
18976 2004-10-29  Paul Eggert  <eggert@cs.ucla.edu>
18977
18978         * doc/getdate.texi: New file, from coreutils with modifications for
18979         the new TZ parsing.
18980
18981 2004-10-27  Derek R. Price  <derek@ximbiot.com>
18982
18983         * lib/mktime.c (not_equal_tm): Remove redundant check.
18984
18985 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18986
18987         * modules/regex (lib_SOURCES): Add regex.c.
18988         Reported by James Youngman in
18989         <http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00199.html>.
18990
18991 2004-10-24  Paul Eggert  <eggert@cs.ucla.edu>
18992
18993         * lib/getdate.y: Use Bison 1.875 features, and some minor
18994         code cleanups.  This change does not affect semantics.
18995         Don't include <stdlib.h>; no longer needed.
18996         Don't include unlocked-io.h; only the "#if TEST" code uses
18997         stdio, and performance isn't crucial there.
18998         (PC, YYLEX_PARAM, YYPARSE_PARAM): Remove; replaced by
18999         Bison 1.875 features as described below.
19000         All uses of "PC." replaced by "pc->".
19001         (YYSTYPE): Add a forward declaration.
19002         (yylex, yyerror): Use full prototypes in forward decls.
19003         Use "%pure-parser" rather than obsolescent "%pure_parser".
19004         Use %parse-param and %lex-param instead of obsolescent
19005         YYPARSE_PARAM and YYLEX_PARAM.
19006         (meridian_table, month_and_day_table, time_units_table,
19007         relative_time_table, time_zone_table, military_table,
19008         lookup_zone, lookup_word, get_date):
19009         Use NULL instead of 0 where appropriate.
19010         (to_hour): Avoid abort (), to avoid a dependency on
19011         stdlib.h.
19012         (yyerror, yylex): Now accepts parser_control * arg.
19013         (main) [TEST]: Use '\0' rather than 0 for char.
19014
19015 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
19016
19017         * m4/getpagesize.m4 (gl_GETPAGESIZE): Check for <sys/param.h>.
19018
19019 2004-10-22  Paul Eggert  <eggert@cs.ucla.edu>
19020
19021         * lib/getpagesize.c (getpagesize): Don't assume <sys/param.h> exists.
19022         It's now the caller's responsibility to handle the case where
19023         !HAVE_GETPAGESIZE && !defined getpagesize.
19024
19025         * lib/mktime.c (leapyear): Arg is long int, not int.
19026
19027 2004-10-18  Paul Eggert  <eggert@cs.ucla.edu>
19028
19029         * lib/argp-fs-xinl.c, argp-xinl.c: Update from glibc.
19030
19031 2004-10-17  Paul Eggert  <eggert@cs.ucla.edu>
19032
19033         * gnulib-tool (func_emit_lib_Makefile_am): Fix typo: a $ was
19034         missing.  Problem reported by James Youngman.
19035
19036 2004-10-16  Simon Josefsson  <jas@extundo.com>
19037
19038         * gnulib-tool: Fix comments.  Fix parse problem.
19039         (func_emit_lib_Makefile_am): Don't hard code a in libgl_a_SOURCES.
19040
19041 2004-10-15  Paul Eggert  <eggert@cs.ucla.edu>
19042
19043         * m4/getopt.m4 (gl_GETOPT): Detect and reject the incompatible BSD
19044         implementation of getopt_long.  Problem reported by Alexander Taler in:
19045         http://lists.gnu.org/archive/html/bug-gnulib/2004-10/msg00103.html
19046
19047 2004-10-15  Bruno Haible  <bruno@clisp.org>
19048
19049         * gnulib-tool: Untabify. Initialize supplied_libname.
19050         (func_usage): More homogenous output.
19051         (func_modules_transitive_closure, func_modules_to_filelist,
19052         func_emit_lib_Makefile_am): New functions.
19053         (func_import): New function, extracted from big case statement. Use
19054         func_get_license, func_modules_transitive_closure,
19055         func_modules_to_filelist, func_emit_lib_Makefile_am. Initialize
19056         opt_lgpl. Don't use test -a, as it's not portable.
19057         (func_create_testdir): Use func_modules_transitive_closure,
19058         func_modules_to_filelist, func_emit_lib_Makefile_am.
19059
19060 2004-10-15  Bruno Haible  <bruno@clisp.org>
19061
19062         * gnulib-tool (func_import): Let gl_INIT define LTALLOCA when needed.
19063
19064 2004-10-15  Bruno Haible  <bruno@clisp.org>
19065
19066         * gnulib-tool (func_emit_lib_Makefile_am): Add markers to separate
19067         the portions belonging to each module.
19068         Suggested by Derek Robert Price <derek@ximbiot.com>.
19069
19070 2004-10-12  Simon Josefsson  <jas@extundo.com>
19071
19072         * lib/getpass.c (fflush_unlocked, flockfile, funlockfile)
19073         (fputs_unlocked, putc_unlocked) [!_LIBCS && !USE_UNLOCKED_IO]: Map
19074         to real functions.
19075
19076 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19077
19078         * modules/vsnprintf: New file.
19079
19080 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19081
19082         * m4/vsnprintf.m4: New file.
19083
19084 2004-10-11  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19085
19086         * lib/vsnprintf.h: New file.
19087         * lib/vsnprintf.c: New file.
19088
19089 2004-10-11  Bruno Haible  <bruno@clisp.org>
19090
19091         * MODULES.html.sh (Support for systems lacking ISO C 99): Add
19092         vsnprintf.
19093
19094 2004-10-10  Paul Eggert  <eggert@cs.ucla.edu>
19095
19096         * config/srclistvars.sh: Add GNUSTANDARDS (for eggert only).
19097
19098 2004-10-07  Bruno Haible  <bruno@clisp.org>
19099
19100         * lib/snprintf.c (snprintf): Avoid a memory allocation if the result
19101         fits into the provided buffer.
19102
19103 2004-10-06  Paul Eggert  <eggert@cs.ucla.edu>
19104
19105         * lib/diacrit.c, diacrit.h: Add GPL notice.
19106
19107         * lib/atanl.c, logl.c: Add GPL notice, to match glibc's added LGPL
19108         notice.
19109         * lib/atanl.c (atanl): Keep the code as similar to glibc as possible.
19110         * lib/logl.c (logl): Keep the code as similar to glibc as possible.
19111         This avoids a potential constant-folding bug.
19112
19113 2004-10-05  Bruno Haible  <bruno@clisp.org>
19114
19115         * m4/strsep.m4 (gl_FUNC_STRSEP): Require AC_GNU_SOURCE. Don't check
19116         for the declaration of strsep.
19117
19118 2004-10-05  Bruno Haible  <bruno@clisp.org>
19119
19120         * lib/strsep.h: Don't declare strsep() if HAVE_STRSEP.
19121
19122 2004-10-04  Simon Josefsson  <jas@extundo.com>
19123
19124         * modules/memmem: New file.
19125         * tests/test-memmem.c: New file.
19126         * MODULES.html.sh (Extra functions based on ANSI C 89): Add memmem.
19127
19128 2004-10-04  Simon Josefsson  <jas@extundo.com>
19129
19130         * m4/memmem.m4: New file.
19131
19132 2004-10-04  Simon Josefsson  <jas@extundo.com>
19133
19134         * lib/memmem.h: New file.
19135         * lib/memmem.c: New file, taken from glibc.
19136
19137 2004-10-04  Simon Josefsson  <jas@extundo.com>
19138
19139         * lib/error.c, md5.c, regex.c: Use '#if USE_UNLOCKED_IO' instead of
19140         '#ifdef USE_UNLOCKED_IO'.
19141
19142 2004-10-04  Simon Josefsson  <jas@extundo.com>
19143
19144         * config/srclist.txt: Add memmem from glibc.
19145
19146 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19147
19148         * modules/xalloc (Files, Makefile.am): Remove xstrdup.c.
19149
19150         * modules/argmatch, modules/argp, modules/closeout, modules/error,
19151         modules/exclude, modules/getdate, modules/getline,
19152         modules/getndelim2, modules/getpass, modules/getpass-gnu,
19153         modules/getusershell, modules/linebuffer, modules/md5,
19154         modules/mountlist, modules/posixtm, modules/readtokens,
19155         modules/readutmp, modules/regex, modules/sha1,
19156         modules/version-etc, modules/yesno:
19157         Remove dependency on unlocked-io.
19158
19159 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19160
19161         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Remove.  All uses removed.
19162
19163         * m4/unlocked-io.m4: Add copyright notice.
19164         (gl_FUNC_GLIBC_UNLOCKED_IO): Define USE_UNLOCKED_IO.
19165
19166 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19167
19168         * lib/xalloc.h (xmemdup): Renamed from xclone.  All uses changed.
19169         * lib/xmalloc.c (xmemdup): Likewise.
19170         * lib/xalloc.h (CCLONE, CLONE, NEW, XCALLOC, XMALLOC, XREALLOC,
19171         XFREE): Remove these long-obsolescent macros.
19172         * lib/xmalloc.c (xstrdup): Implementation moved here from xstrdup.c
19173         * lib/xstrdup.c: Remove.
19174
19175         * lib/regex.c (re_comp): Cast gettext return value to char *,
19176         Problem reported by Martin Neitzel via Mark D. Baushke.
19177
19178 2004-10-04  Paul Eggert  <eggert@cs.ucla.edu>
19179
19180         * lib/argmatch.c, closeout.c, error.c, exclude.c, getdate.y,
19181         getndelim2.c, getpass.c, getusershell.c, linebuffer.c,
19182         md5.c, mountlist.c, posixtm.c, readtokens.c, readutmp.c,
19183         regex.c, sha1.c, version-etc.c, yesno.c:
19184         Include "unlocked-io.h" only if USE_UNLOCKED_IO.
19185         * lib/unlocked-io.h: Don't worry about USE_UNLOCKED_IO; that's now
19186         the includer's responsibility.
19187
19188         Sync from coreutils.
19189
19190         * lib/modechange.c (mode_compile): Don't decrement a pointer that
19191         points to the start of a string, as the C Standard says the
19192         resulting behavior is undefined.
19193
19194         * lib/backupfile.h (enum backuptype): Rename none -> no_backups,
19195         simple -> simple_backups, numbered_existing ->
19196         numbered_existing_backups, numbered -> numbered_backups
19197         to avoid shadowing problems.  All uses changed.
19198         * lib/argmatch.c (enum backuptype) [defined TEST]: Likewise.
19199         * lib/backupfile.c (check_extension, numbered_backup):
19200         Rename locals to avoid shadowing 'basename'.
19201         * lib/backupfile.h (VALID_BACKUP_TYPE): Don't evaluate arg more than
19202         once.
19203
19204         * lib/.cppi-disable: Add getopt_.h, getopt_int.h.
19205         * lib/.cvsignore: Add getopt.h.
19206
19207 2004-10-04  Bruno Haible  <bruno@clisp.org>
19208
19209         * modules/README: New file.
19210         * gnulib-tool (func_all_modules, func_verify_module): modules/README is
19211         not a module.
19212
19213 2004-10-02  Jim Meyering  <jim@meyering.net>
19214
19215         * lib/dirfd.h, getpagesize.h: Add copyright notice.
19216
19217 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19218
19219         * modules/strsep: New file.
19220
19221 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19222
19223         * m4/strsep.m4: New file.
19224
19225 2004-10-01  Yoann Vandoorselaere  <yoann@prelude-ids.org>
19226
19227         * lib/strsep.h: New file.
19228         * lib/strsep.c: New file.
19229
19230 2004-10-01  Simon Josefsson  <jas@extundo.com>
19231
19232         * lib/snprintf.c (snprintf): Handle size==0.
19233
19234 2004-10-01  Simon Josefsson  <jas@extundo.com>
19235             Bruno Haible  <bruno@clisp.org>
19236
19237         * lib/snprintf.c: Include <stdarg.h>, <stdlib.h>, <string.h>.
19238         (snprintf): Declare 'args'.
19239
19240 2004-10-01  Paul Eggert  <eggert@cs.ucla.edu>
19241
19242         * lib/snprintf.c: Remove comments as to why each header is needed.
19243
19244 2004-10-01  Bruno Haible  <bruno@clisp.org>
19245
19246         * MODULES.html.sh: Add strsep.
19247
19248 2004-09-30  Simon Josefsson  <jas@extundo.com>
19249
19250         * modules/snprintf: New file.
19251
19252 2004-09-30  Simon Josefsson  <jas@extundo.com>
19253
19254         * m4/snprintf.m4: New file.
19255
19256 2004-09-30  Simon Josefsson  <jas@extundo.com>
19257
19258         * lib/snprintf.h, lib/snprintf.c: New files.
19259
19260 2004-09-30  Sergey Poznyakoff  <gray@Mirddin.farlep.net>
19261
19262         * lib/argp-help.c (canon_doc_option): Fixed coredump if *name==NULL
19263         (hol_entry_help): Never translate an empty string.
19264         Do not translate option tag (opt->name) if OPTION_NO_TRANS is set
19265         * lib/argp.h (OPTION_NO_TRANS): New option.
19266
19267 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19268
19269         * modules/argp (Maintainer): Replace Simon Josefsson
19270         by Sergey Poznyakoff.
19271
19272 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19273
19274         * config/srclist.txt: Comment-out argp/argp.h, until we get the argp
19275         changes merged back into glibc.
19276
19277 2004-09-30  Paul Eggert  <eggert@cs.ucla.edu>
19278
19279         * MODULES.html.sh (Support for systems lacking ISO C 99): Add snprintf.
19280
19281 2004-09-29  Oskar Liljeblad  <oskar@osk.mine.nu>
19282
19283         * lib/xvasprintf.c: Include xalloc.h.
19284         (xvasprintf): Use xalloc_die, not xmalloc_die.
19285
19286 2004-09-29  Bruno Haible  <bruno@clisp.org>
19287
19288         * modules/alloca-opt: New file, derived from modules/alloca.
19289         * modules/allocsa: Depend on alloca-opt instead of alloca.
19290         * modules/setenv: Likewise.
19291         * modules/vasnprintf: Likewise.
19292         * MODULES.html.sh: Add alloca-opt.
19293
19294 2004-09-28  Simon Josefsson  <jas@extundo.com>
19295
19296         * gnulib-tool: New parameter --lgpl, to asseert that modules are
19297         LGPL, and to replace license template from GPL to LGPL.
19298
19299 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19300
19301         * modules/dummy: Change license to LGPL.
19302
19303 2004-09-28  Paul Eggert  <eggert@cs.ucla.edu>
19304
19305         * lib/dummy.c: Change copyright notice to FSF, and license to GPL.
19306
19307 2004-09-24  Simon Josefsson  <jas@extundo.com>
19308
19309         * modules/minmax (License): Change from GPL to LGPL.
19310
19311 2004-09-23  Simon Josefsson  <jas@extundo.com>
19312
19313         * gnulib-tool (--import): Typo.
19314
19315 2004-09-23  Simon Josefsson  <jas@extundo.com>
19316
19317         * gnulib-tool (--import): Make sure *.m4 end up in m4/ by default.
19318
19319 2004-09-22  Bruno Haible  <bruno@clisp.org>
19320
19321         * modules/*: Add 'License' field.
19322         * gnulib-tool: Accept --extract-license option.
19323         (func_get_license): New function.
19324
19325 2004-09-21  Bruno Haible  <bruno@clisp.org>
19326
19327         * modules/vasnprintf (Files): Add m4/stdint_h.m4, m4/inttypes_h.m4.
19328         Reported by Simon Josefsson.
19329
19330 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19331
19332         * modules/inttostr (Files): Add m4/longlong.m4, since it uses
19333         gl_AC_TYPE_LONG_LONG.
19334
19335 2004-09-20  Paul Eggert  <eggert@cs.ucla.edu>
19336
19337         * config/srclist.txt: Add getsubopt.c, since libc bought our changes.
19338
19339 2004-09-18  Simon Josefsson  <jas@extundo.com>
19340         and  Paul Eggert  <eggert@cs.ucla.edu>
19341
19342         * gnulib-tool: Replace various ad-hoc automake/autoconf/aclocal
19343         calls with autoreconf.  Define GL_LIB.
19344
19345 2004-09-14  Karl Berry  <karl@gnu.org>
19346
19347         * config/srclist.txt: unsync setenv.c, sigh.
19348
19349 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19350
19351         * lib/argp-pvh.c (argp_program_version_hook): Provide initial value.
19352         Problem reported by Bruno Haible in:
19353         http://lists.gnu.org/archive/html/bug-tar/2004-09/msg00023.html
19354
19355 2004-09-13  Paul Eggert  <eggert@cs.ucla.edu>
19356
19357         * config/srclist.txt: Comment out argp-pvh.c.
19358
19359 2004-09-11  Paul Eggert  <eggert@cs.ucla.edu>
19360
19361         * lib/mempcpy.h: Wrap the entire include file inside #ifndef mempcpy,
19362         in case some system header has #define'd it.  Problem reported by
19363         Soeren D. Schulze in
19364         <http://lists.gnu.org/archive/html/bug-gnulib/2004-09/msg00017.html>.
19365
19366 2004-09-09  Karl Berry  <karl@gnu.org>
19367
19368         * regex.[ch]: delete from the root.  These were supposed to be
19369                 synced with emacs cvs, but this has not happened for about
19370                 a year, and anyway nothing else uses emacs regex.[ch].
19371                 bug-gnulib mail from Jeff Bailey, 9 Sep 2004 15:49:24 -0700.
19372                 lib/regex[.ch] is untouched.
19373
19374 2004-09-09  Bruno Haible  <bruno@clisp.org>
19375
19376         * modules/vasnprintf (Files): Add m4/eoverflow.m4.
19377
19378 2004-09-09  Bruno Haible  <bruno@clisp.org>
19379
19380         * m4/eoverflow.m4: New file, taken from GNU libiconv eilseq.m4 with
19381         modifications.
19382         * m4/vasnprintf.m4 (gl_FUNC_VASNPRINTF): Require gl_EOVERFLOW.
19383
19384 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19385
19386         * modules/xvasprintf: New file.
19387         * MODULES.html.sh (Extra functions based on ANSI C 89): Add vasprintf.
19388
19389 2004-09-08  Oskar Liljeblad  <oskar@osk.mine.nu>
19390
19391         * lib/xvasprintf.h: New file.
19392         * lib/xvasprintf.c: New file.
19393         * lib/xasprintf.c: New file.
19394
19395 2004-09-08  Bruno Haible  <bruno@clisp.org>
19396
19397         * m4/stdint.m4: New file, taken from GNU clisp with modifications.
19398
19399 2004-09-08  Bruno Haible  <bruno@clisp.org>
19400
19401         * lib/vasnprintf.c (VASNPRINTF): Signal EOVERFLOW if the resulting
19402         length is > INT_MAX.
19403         * lib/vasprintf.c (vasprintf): Don't test for length > INT_MAX any
19404         more.
19405
19406 2004-09-08  Bruno Haible  <bruno@clisp.org>
19407
19408         * lib/stdint_.h: New file, taken from GNU clisp.
19409
19410 2004-09-08  Bruno Haible  <bruno@clisp.org>
19411             Oskar Liljeblad  <oskar@osk.mine.nu>
19412
19413         * modules/stdint: New file.
19414         * MODULES.html.sh (Support for systems lacking ISO C 99): Add stdint.
19415
19416 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19417
19418         Import from coreutils.
19419         * lib/userspec.c: Don't use <alloca.h>, so that we don't use alloca on
19420         strings on unbounded length.  alloca's performance benefits aren't
19421         that important here.
19422         (V_STRDUP): Remove.
19423         (parse_with_separator): New function, with most of the internals
19424         of the old parse_user_spec.  Allow user to omit both user and group,
19425         for compatibility with FreeBSD.
19426         Clone only the user name, not the entire spec.
19427         Do not set *uid, *gid unless entirely successful.
19428         Avoid memory leak in some failing cases.
19429         Fix regression for USER.GROUP reported by Dmitry V. Levin in
19430         <http://lists.gnu.org/archive/html/bug-coreutils/2004-08/msg00102.html>
19431         (parse_user_spec): Rewrite to use parse_with_separator.
19432
19433 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19434
19435         * modules/userspec: Don't depend on alloca.
19436
19437 2004-08-19  Paul Eggert  <eggert@cs.ucla.edu>
19438
19439         * m4/userspec.m4 (gl_USERSPEC): Don't require AC_FUNC_ALLOCA.
19440
19441 2004-08-17  Paul Eggert  <eggert@cs.ucla.edu>
19442
19443         * MODULES.html.sh: Add xalloc-die, c-strtod, c-strtold, raise,
19444         readtokens0, getcwd, fcntl-safer, canonicalize, cycle-check,
19445         utimecmp, utimens, xnanosleep.  Rename sha to sha1.
19446
19447 2004-08-16  Simon Josefsson  <jas@extundo.com>
19448
19449         * gnulib-tool: Use sed instead of autoconf --trace, inspired by
19450         libtoolize behaviour by "Gary V. Vaughan" <gary@gnu.org>.
19451         Add --dry-run for --import.
19452         Let user provided command line parameters override configure.ac
19453         settings.
19454
19455 2004-08-12  Simon Josefsson  <jas@extundo.com>
19456
19457         * m4/getopt.m4 (gl_GETOPT_SUBSTITUTE): New macro,
19458         as discussed with Paul Eggert in threads rooted at
19459         <http://lists.gnu.org/archive/html/bug-gnulib/2004-06/msg00039.html>
19460         and
19461         <http://lists.gnu.org/archive/html/bug-gnulib/2004-07/msg00001.html>.
19462         Before, the test was empty, and relied on ELIDE_CODE in source
19463         code.)
19464         (gl_PREREQ_GETOPT): New macro.
19465         (gl_GETOPT): Use them.
19466
19467 2004-08-12  Simon Josefsson  <jas@extundo.com>
19468
19469         * lib/getopt.c, getopt1.c: Remove ELIDE_CODE hack.
19470         * lib/getopt_.h: Renamed from getopt.h.
19471
19472 2004-08-12  Simon Josefsson  <jas@extundo.com>
19473
19474         * gnulib-tool: Add --source-base, --m4-base, --libtool options.
19475         Change default library name from libfoo to libgnu.
19476         Now, if you have a configure.ac that says:
19477                 gl_SOURCE_BASE(gl)
19478                 gl_M4_BASE(gl/m4)
19479                 gl_MODULES(error getopt etcetera)
19480                 gl_INIT
19481         you can import all you need by running:
19482                 ../gnulib/gnulib-tool --import
19483
19484         * modules/getopt (Files): Rename getopt.h to getopt_.h.
19485         (Makefile.am): Rewrite, use logic from argz.
19486         (Include): Use <getopt.h> instead of "getopt.h".
19487
19488 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19489
19490         * modules/argp (Files): Add m4/unlocked-io.m4.
19491         (Depends-on): Add extensions.
19492
19493 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19494
19495         * m4/argp.m4 (gl_ARGP): Do not check for argp.h or argp_parse; nobody
19496         uses HAVE_ARGP_H or HAVE_ARGP_PARSE.
19497         Require gl_FUNC_GLIBC_UNLOCKED_IO, gl_USE_SYSTEM_EXTENSIONS.
19498         Check for program_invocation_name, program_invocation_short_name,
19499         flockfile, funlockfile, features.h, _getopt_long_only_r.
19500
19501 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19502
19503         * lib/argp-help.c, argp-parse.c: Use "gettext.h" instead of
19504         its complicated substitute.
19505         * lib/argp-help.c: Include <errno.h>, for program_invocation_short_name
19506         and program_invocation_name.
19507         (__argp_basename) [!_LIBC]: Remove; the only use was
19508         replaced by its body.
19509         (__argp_short_program_name): Change condition from
19510         !defined __argp_short_program_name to
19511         ! (defined _LIBC || HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME),
19512         to match argp-namefrob.h.
19513         (__argp_failure): Don't assume strerror_r returns char *.
19514         * lib/argp-parse.c (N_): Define unconditionally.
19515         (argp_default_options): Fill out initializers with 0 to avoid
19516         gcc warnings.
19517
19518 2004-08-12  Paul Eggert  <eggert@cs.ucla.edu>
19519
19520         * config/srclist.txt: Remove getopt.c, getopt.h (renamed to getopt_.h),
19521         getopt1.c.
19522
19523 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19524
19525         Merge from coreutils.
19526
19527         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for wmemchr and wmemcpy.
19528
19529         * m4/obstack.m4 (gl_PREREQ_OBSTACK): Require
19530         gl_AC_HEADER_INTTYPES_H, gl_AC_HEADER_STDINT_H, gl_AC_TYPE_UINTMAX_T.
19531
19532 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19533
19534         Merge from coreutils.
19535
19536         * lib/fnmatch.c (WIDE_CHAR_SUPPORT): Don't set to 1 if missing
19537         wmemchr or wmemcpy.  Problem reported by Robert Dahlem
19538         for Reliant Unix 5.43.
19539
19540         * lib/obstack.c: Include <inttypes.h> and <stdint.h> if available.
19541         (union fooround): Use uintmax_t, not long int.
19542         The rest is a merge from libc:
19543         [defined _LIBC]: Include <shlib-compat.h>.
19544         (_obstack) [defined _LIBC]: Remove after 2.3.4.
19545
19546         * lib/settime.c (settime): Recode to avoid warning with
19547         Sun Forte C 6U2.
19548
19549         * lib/strverscmp.c: Convert to UTF-8.
19550
19551 2004-08-11  Paul Eggert  <eggert@cs.ucla.edu>
19552
19553         * modules/obstack (Files): Add m4/inttypes_h.m4, m4/stdint_h.m4,
19554         m4/uintmax_t.m4.
19555
19556 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19557
19558         * modules/xalloc-die: New file.
19559         * modules/xalloc: Remove dependencies on error, gettext, exitfail.
19560
19561         * modules/md5 (Files): Add m4/uint32_t.m4.
19562         * modules/sha1: Renamed from modules/sha.
19563         (Files):
19564         Rename lib/sha.h to lib/sha1.h.
19565         Rename lib/sha.c to lib/sha1.c.
19566         Rename m4/sha.m4 to m4/sha1.m4.
19567         (lib_SOURCES): Likewise.
19568         (configure.ac): Rename gl_SHA to gl_SHA1.
19569         (Include): sha.h -> sha1.h.
19570
19571 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19572
19573         * m4/uint32_t.m4, m4/uintptr_t.m4: New files.
19574         * m4/sha1.m4: Renamed from sha.m4.
19575         (gl_SHA1): Renamed from gl_SHA.  All uses changed.
19576
19577 2004-08-09  Paul Eggert  <eggert@cs.ucla.edu>
19578
19579         * lib/obstack.h (obstack_empty_p):
19580         Don't assume that chunk->contents is suitably aligned.
19581         * lib/obstack.c (_obstack_begin, _obstack_begin_1, _obstack_newchunk):
19582         Likewise. Problem reported by Benno in
19583         <http://sources.redhat.com/ml/libc-alpha/2004-08/msg00055.html>.
19584
19585         * lib/chown.c (rpl_chown): Work even if the file is writeable but not
19586         readable.  This could be improved further but it'd take some work.
19587
19588 2004-08-08  Simon Josefsson  <jas@extundo.com>
19589
19590         * modules/xgethostname (Depends-on): Remove exit and error (not
19591         used).
19592
19593         * modules/getpass-gnu: Add getpass.h.
19594         (Depends-on): Add stdbool.
19595         * modules/getpass: Add getpass.h.
19596
19597 2004-08-08  Simon Josefsson  <jas@extundo.com>
19598
19599         * m4/getpass.m4 (gl_FUNC_GETPASS, gl_FUNC_GETPASS_GNU):
19600         Check getpass declaration.
19601
19602 2004-08-08  Simon Josefsson  <jas@extundo.com>
19603
19604         * lib/xgethostname.c: Don't include error.h (not used).
19605
19606         * lib/getpass.h: Add.
19607         * lib/getpass.c: Include getpass.h first.
19608
19609 2004-08-08  Paul Eggert  <eggert@cs.ucla.edu>
19610
19611         * lib/xalloc-die.c: New file.
19612         * lib/xalloc.h (xalloc_fail_func, xalloc_msg_memory_exhausted): Remove.
19613         All uses removed.
19614         * lib/xmalloc.c (xalloc_fail_func, xalloc_msg_memory_exhausted):
19615         Likewise. Move inclusions of gettext.h, error.h, exitfail.h to
19616         xalloc-die.c.
19617         (_, N_, xalloc_die): Move to xalloc-die.c.
19618         * lib/userspec.c (parse_user_spaec): Use xstrdup rather than strdup,
19619         so that we needn't mess with xalloc_msg_memory_exhausted.
19620
19621         * lib/sha1.h: Renamed from sha.h.
19622         (SHA1_H): Renamed from _SHA_H.
19623         (sha1_ctx): Renamed from sha_ctx.
19624         (sha1_init_ctx): Renamed from sha_init_ctx.
19625         (sha1_process_block): Renamed from sha_process_block.
19626         (sha1_process_bytes): Renamed from sha_process_bytes.
19627         (sha1_finish_ctx): Renamed from sha_finish_ctx.
19628         (sha1_read_ctx): Renamed from sha_read_ctx.
19629         (sha1_stream): Renamed from sha_stream.
19630         (sha1_buffer): Renamed from sha_buffer.
19631         * lib/sha1.c: Likewise; renamed from sha.c.
19632         Do not include <sys/types.h>.
19633         Include <stddef.h> rather than <stdlib.h>.
19634
19635 2004-08-08  Bruno Haible  <bruno@clisp.org>
19636
19637         * lib/pathname.h (FILE_SYSTEM_PREFIX_LEN): Renamed from
19638         FILESYSTEM_PREFIX_LEN.
19639         * lib/progreloc.c: Likewise.
19640         * lib/concatpath.c (concatenated_pathname): Use FILE_SYSTEM_PREFIX_LEN.
19641
19642 2004-08-06  Simon Josefsson  <jas@extundo.com>
19643
19644         * modules/progname (Depends-on): Don't depend on stdbool.
19645
19646 2004-08-06  Simon Josefsson  <jas@extundo.com>
19647
19648         * modules/getsubopt: New file.
19649         * MODULES.html.sh (Support for systems lacking POSIX:2001): Add
19650         getsubopt.
19651
19652 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19653
19654         More merge from coreutils.
19655
19656         * m4/utimens.m4, m4/utimecmp.m4: New files.
19657         * m4/backupfile.m4, euidacces.m4, acl.m4, afs.m4, calloc.m4, dirfd.m4,
19658         fsusage.m4, jm-macros.m4, ls-mntd-fs.m4, md5.m4, mountlist.m4,
19659         prereq.m4, sha.m4: Import changes from coreutils.
19660
19661 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19662
19663         More merge from coreutils.
19664         * modules/raise, modules/readtokens0, modules/utimens:
19665         * modules/utimecmp, module/xnanosleep: New files.
19666         * modules/strftime: Add lib/strftime.h.
19667         Change include from <time.h> to "strftime.h".
19668         * modules/yesno: Add lib/yesno.h.
19669         * modules/backupfile: Remove lib/addext.c.
19670         * modules/euidaccess: Add stat-macros.h.
19671         * modules/canonicalize, modules/euidaccess,
19672         modules/filemode, modules/lchown, modules/makepath,
19673         modules/rmdir, modules/stat: Likewise.
19674
19675 2004-08-06  Paul Eggert  <eggert@cs.ucla.edu>
19676
19677         Merge from tar.
19678         * lib/argp-help.c (make_hol, hol_append): Don't assume that
19679         SIZE_MAX is a valid preprocessor constant.
19680         (__argp_basename): Change from "#ifndef _LIBC"
19681         to "#ifndef __argp_short_program_name", so that
19682         we don't compile these functions for tar.
19683
19684         More merges from coreutils.
19685         * lib/raise.c, lib/readtokens0.h, lib/readtokens0.c, lib/strftime.h:
19686         * lib/utimens.h, lib/utimens.c, lib/utimecmp.h, lib/utimecmp.c:
19687         * lib/xnanosleep.h, lib/xnanosleep.c, lib/yesno.h: New files.
19688         * lib/addext.c: Remove; no longer needed.
19689         * lib/yesno.c, lib/argmatch.h, lib/argmatch.c, lib/backupfile.h,
19690         lib/backupfile.c, lib/euidaccess.c, lib/filemode.c, lib/closeout.c,
19691         lib/dup2.c, lib/exclude.c, lib/fileblocks.c, lib/filemode.c,
19692         lib/fnmatch.c, lib/fnmtahc_loop.c, lib/fopen-safer.c, lib/fsusage.c,
19693         lib/fsusage.h, lib/ftruncate.c, lib/full-write.c, lib/getdate.y,
19694         lib/getloadavg.c, lib/getugroups.c, lib/hard-locale.c,
19695         lib/hard-locale.h, lib/hash.c, lib/human.c, lib/human.h, lib/lchown.c,
19696         lib/lchown.h, lib/makepath.c, lib/makepath.h, lib/md5.c, lib/md5.h,
19697         lib/memchr.c, lib/memcoll.c, lib/memrchr.c, lib/modechange.c,
19698         lib/modechange.h, lib/mountlist.c, lib/mountlist.h, lib/nanosleep.c,
19699         lib/posixtm.c, lib/putenv.c, quotearg.c, lib/quotearg.h,
19700         lib/readtokens.c, lib/readutmp.c, lib/readutmp.h, lib/rmdir.c,
19701         lib/safe-read.c, lib/save-cwd.c, lib/savedir.c, lib/setenv.c,
19702         lib/sig2str.c, lib/stat.c, lib/strtoimax.c, lib/strverscmp.c,
19703         lib/userspec.c, lib/utime.c, lib/version-etc.c., lib/xgethostname.c,
19704         lib/xmemcoll.c, lib/xreadlink.c, lib/xstrtod.c, lib/xstrtod.h,
19705         lib/xstrtoimax.c, lib/xstrtol.c, lib/xstrtol.h, lib/xstrtoumax.c:
19706         Import changes from coreutils.
19707
19708 2004-08-05  Simon Josefsson  <jas@extundo.com>
19709
19710         * m4/strdup.m4: Always run gl_PREREQ_STRDUP, since strdup.h need it.
19711
19712 2004-08-05  Simon Josefsson  <jas@extundo.com>
19713
19714         * m4/getsubopt.m4: New file.
19715
19716 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19717
19718         Merge from coreutils.
19719
19720         * m4/c-strtod.m4, m4/canonicalize.m4, m4/fcntl-safer.m4:
19721         * m4/getcwd-path-max.m4: New files.
19722
19723         * m4/dos.m4 (gl_AC_DOS): filesystem -> file system renaming.
19724         FILESYSTEM_PREFIX_LEN ->
19725         FILE_SYSTEM_PREFIX_LEN.
19726         FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX ->
19727         FILE_SYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX.
19728         FILESYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR ->
19729         FILE_SYSTEM_BACKSLASH_IS_FILE_NAME_SEPARATOR.
19730
19731         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't require gl_AC_DOS, the
19732         prerequisite modules now handle the DOS stuff.
19733         Don't check for unistd.h.
19734
19735 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19736
19737         Merge from coreutils.
19738
19739         * lib/.gdb-history: Remove; this doesn't belong here.
19740
19741         * lib/c-strtod.c, lib/c-strtod.h, lib/c-strtold.c, lib/cycle-check.c:
19742         * lib/cycle-check.h, lib/dev-ino.h, lib/canonicalize.h:
19743         * lib/canonicalize.c, lib/fcntl-safer.h, lib/fcntl-safer.c:
19744         * lib/getcwd.c: New files.
19745
19746         * lib/dirname.h: Include <stdbool.h>.
19747         (FILE_SYSTEM_PREFIX_LEN): Renamed from FILESYSTEM_PREFIX_LEN,
19748         for consistency with POSIX terminology.  All uses changed.
19749         (IS_ABSOLUTE_FILE_NAME, IS_RELATIVE_FILE_NAME): New macros.
19750         (strip_trailing_slashes): Use bool for booleans.
19751         * lib/stripslash.c (strip_trailing_slashes): Likewise.
19752
19753         * lib/error.c: Work around bug in OpenBSD 3.4 sterror_r: it
19754         sometimes returns a positive errno value even when it succeeds.
19755         (print_errno_message) [!LIBC]: Fall back on strerror if
19756         __strerror_r fails.
19757
19758         * lib/path-concat.c (mempcpy): Don't define if a system header defines
19759         it. Don't include stdio.h, stdlib.h, unistd.h, strdup.h.
19760         (longest_relative_suffix): New function.
19761         (path_concat): Use it.  Assume first argument is not NULL.
19762         Port to DOS.  Omit redundant separators.
19763         Report an error instead of returning NULL.
19764         Use mempcpy instead of memcpy.
19765         (xpath_concat): Remove: not declared or used.
19766
19767         * lib/same.h: Include <stdbool.h>
19768         (same_name): Return bool, not int.
19769         * lib/same.c (same_name): Likewise.
19770         (errno): Don't declare; we assume C89 or better now.
19771
19772         * lib/stat-macros (S_ISCTG, S_ISOFD, S_ISOFL): New macros,
19773         if not already defined.
19774
19775         * lib/xgetcwd.c (errno): Don't declare; we assume C89 or better now.
19776         * lib/dup-safer.c (errno): Likewise.
19777
19778 2004-08-05  Paul Eggert  <eggert@cs.ucla.edu>
19779
19780         Merge from coreutils.
19781         * modules/c-strtod, modules/c-strtold, modules/canonicalize:
19782         * modules/cycle-check, modules/fcntl-safer, modules/getcwd: New files.
19783         * modules/path-concat: Don't depend on strdup.
19784
19785 2004-08-03  Simon Josefsson  <jas@extundo.com>
19786
19787         * lib/strdup.h: Only use HAVE_DECL_STRDUP if defined.
19788         * lib/progname.h: Don't include stdbool.h.
19789
19790 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19791
19792         * modules/fatal: Remove, as the "fatal" module wasn't used or working.
19793         * MODULES.html.sh (func_all_modules): Remove fatal.
19794
19795 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19796
19797         * m4/fatal.m4: Remove, as the "fatal" module wasn't used or working.
19798
19799 2004-08-03  Paul Eggert  <eggert@cs.ucla.edu>
19800
19801         * lib/fatal.c, fatal.h: Remove as the "fatal" module wasn't used or
19802         working.
19803
19804 2004-08-02  Simon Josefsson  <jas@extundo.com>
19805
19806         * lib/getsubopt.h: New file, with comments from Bruno Haible.
19807         * lib/getsubopt.c: New file, from glibc, but slightly modified based on
19808         suggestions from Paul Eggert <eggert@cs.ucla.edu>.
19809
19810 2004-08-01  Simon Josefsson  <jas@extundo.com>
19811
19812         * lib/xgetdomainname.c: Include stdlib.h, for free().
19813
19814 2004-07-19  Bruno Haible  <bruno@clisp.org>
19815
19816         * MODULES.html.sh (func_all_modules): Add dummy.
19817
19818 2004-07-16  Simon Josefsson  <jas@extundo.com>
19819
19820         * modules/dummy: New file.
19821
19822 2004-07-16  Simon Josefsson  <jas@extundo.com>
19823
19824         * lib/dummy.c: New file.
19825
19826 2004-07-16  Bruno Haible  <bruno@clisp.org>
19827
19828         * lib/backupfile.h: Add extern "C" for C++.
19829         * lib/closeout.h: Likewise.
19830         * lib/copy-file.h: Likewise.
19831         * lib/findprog.h: Likewise.
19832         * lib/full-write.h: Likewise.
19833         * lib/pathname.h: Likewise.
19834         * lib/progname.h: Likewise.
19835         * lib/stpcpy.h: Likewise.
19836         * lib/stpncpy.h: Likewise.
19837         * lib/strcase.h: Likewise.
19838         * lib/strstr.h: Likewise.
19839         * lib/xalloc.h: Likewise.
19840
19841         * lib/mbswidth.h: Add extern "C" for C++.
19842         Reported by Albert Chin-A-Young <china@thewrittenword.com>.
19843
19844 2004-07-13  Robert Millan  <robertmh@gnu.org>
19845
19846         * m4/host-os.m4: s/KNetBSD/kNetBSD/g and s/KFreeBSD/kFreeBSD/g.
19847
19848 2004-07-09  Simon Josefsson  <jas@extundo.com>
19849
19850         * lib/getndelim2.c: Include stddef.h, for ptrdiff_t.  (FreeBSD 4.9
19851         failed without this.)
19852
19853 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19854
19855         * modules/chown (Files): Add lib/fchown-stub.c, since
19856         gl_PREREQ_CHOWN invokes AC_LIBOBJ(fchown-stub).
19857
19858 2004-07-09  Paul Eggert  <eggert@cs.ucla.edu>
19859
19860         * lib/fchown-stub.c: New file.
19861
19862 2004-06-24  Jim Meyering  <jim@meyering.net>
19863
19864         * lib/obstack.h (obstack_base): Cast to (void *), per documentation.
19865
19866 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19867
19868         * modules/argz: Omit "#include".
19869
19870         * MODULES.html.sh (func_all_modules): Add calloc, to match
19871         2004-06-01 addition of calloc module.
19872
19873 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19874
19875         * m4/argz.m4: New file, which is autoupdated from libtool.
19876
19877 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19878
19879         * lib/argz.c, lib/argz_.h: New files, which are autoupdated from
19880         libtool.
19881
19882 2004-06-22  Paul Eggert  <eggert@cs.ucla.edu>
19883
19884         * config/srclist-update: Don't insist on "USA." before the
19885         close-comment, as libtool omits the period and puts the */ on a
19886         separate line.
19887         * config/srclist.txt: Add argz.c, argz_.h, argz.m4.
19888         * config/srclistvars.sh: Add LIBTOOL (for eggert only).
19889
19890 2004-06-22  Gary V. Vaughan  <gary@gnu.org>
19891
19892         * modules/argz: New file.
19893         * MODULES.html.sh (func_all_modules): Add argz.
19894
19895 2004-06-12  Jim Meyering  <jim@meyering.net>
19896         and  Paul Eggert  <eggert@cs.ucla.edu>
19897
19898         * modules/hash (Files): Add lib/xalloc.h.
19899         * modules/pipe (Depends-on): Add wait-process.
19900         * modules/stat (Depends-on): Add xalloc.
19901         * modules/userspec (Files): Add lib/userspec.h.
19902         * modules/xstrto
19903
19904         Upgrade from gettext-0.13.
19905         * modules/gettext (Files): Add m4/intmax.m4, m4/longdouble.m4,
19906         m4/longlong.m4, m4/printf-posix.m4, m4/signed.m4, m4/size_max.m4,
19907         m4/wchar_t.m4, m4/wint_t.m4, m4/xsize.m4.
19908
19909 2004-06-10  Jim Meyering  <jim@meyering.net>
19910
19911         * lib/calloc.c: New file.
19912
19913 2004-06-06  Paul Eggert  <eggert@cs.ucla.edu>
19914
19915         * lib/getdate.y (yylex): Allow space between sign and number.
19916         Problem reported by Dan Jacobson.
19917
19918 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19919
19920         Merge from coreutils CVS.
19921
19922         * m4/backupfile.m4, dirname.m4, human.m4, inttypes.m4, longlong.m4,
19923         makepath.m4, memchr.m4, memcmp.m4, mountlist.m4, path-concat.m4,
19924         putenv.m4, quotearg.m4, readutmp.m4, strtoimax.m4, strtoll.m4,
19925         strtoull.m4, strtoumax.m4, ulonglong.m4, vasnprintf.m4,
19926         xstrtol.m4: Fix copyright date and/or serial number.
19927
19928         * m4/chown.m4 (gl_PREREQ_CHOWN): Check for fcntl.h.
19929         See if we need an fchown replacement.
19930         (gl_FUNC_CHOWN_FOLLOWS_SYMLINK): New macro.
19931         (gl_FUNC_CHOWN): Require gl_FUNC_CHOWN_FOLLOWS_SYMLINK,
19932         and use the replacement function if we detect either defect.
19933
19934         * m4/prereq.m4 (gl_PREREQ): Add gl_ALLOCSA, gl_CLOEXEC, gl_INTTOSTR,
19935         gl_UTIMECMP.
19936
19937 2004-06-01  Paul Eggert  <eggert@cs.ucla.edu>
19938         and  Jim Meyering  <jim@meyering.net>
19939
19940         Merge from coreutils CVS.
19941
19942         * lib/stat-macros.h: New file, with contents from file-type.h
19943         and coreutils' system.h.
19944         * lib/file-type.c: Include "stat-macros.h".
19945         * lib/file-type.h (file_type): Move all macro definitions to new file,
19946         stat-macros.h.
19947
19948         * lib/chown.c (rpl_chown) [CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE]:
19949         Wrap old code with this conditional.
19950         [CHOWN_MODIFIES_SYMLINK]: Try to work around a chown
19951         function that does not dereference symlinks.
19952         * lib/lchown.c (lchown) [CHOWN_MODIFIES_SYMLINK]: Just call chown.
19953
19954         * lib/xreadlink.c: Include xreadlink.h first, to catch .h file
19955         dependency problems.
19956         (xreadlink): Accept new arg SIZE, for efficiency.
19957         All decls and uses changed.
19958         * lib/xreadlink.h: Include <stddef.h>, for size_t.
19959
19960         * lib/.cppi-disable: Add alloca_.h, allocsa.h, exit.h, getndelim2.h,
19961         gettext.h, localcharset.h, strdup.h, strndup.h, strtoul.c, time_r.h.
19962
19963         * lib/.cvsignore: Add alloca.h, fnmatch.h, poll.h, stdbool.h,
19964         sysexits.h.
19965
19966 2004-06-01  Jim Meyering  <jim@meyering.net>
19967
19968         * m4/calloc.m4: New file.
19969
19970 2004-05-31  Paul Eggert  <eggert@cs.ucla.edu>
19971
19972         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Detect _Bool bug in HP aC++/ANSI
19973         C B3910B A.05.55 [Dec 04 2003].  Problem reported by Jim Meyering.
19974         Also, fix a typo in a diagnostic.
19975
19976 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19977
19978         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Do not require AC_FUNC_MALLOC
19979         or AC_FUNC_REALLOC.
19980
19981 2004-05-30  Paul Eggert  <eggert@cs.ucla.edu>
19982
19983         * lib/xmalloc.c (HAVE_MALLOC, HAVE_REALLOC): Do not require these
19984         macros to be defined.
19985         (xnmalloc_inline, xnrealloc_inline, xcalloc): Do not die if
19986         the allocator returns NULL because the requested size is zero.
19987
19988 2004-05-20  Paul Eggert  <eggert@cs.ucla.edu>
19989
19990         * lib/malloc/obstack.c (_obstack) [defined _LIBC]: Bring back this
19991         var.  Add comment explaining why libc still defines it.  This
19992         merges the following patch from glibc:
19993         http://sources.redhat.com/ml/libc-alpha/2004-05/msg00157.html
19994
19995 2004-05-20  Andreas Schwab  <schwab@suse.de>
19996
19997         * m4/free.m4: Replace free if it not known to work, not the other
19998         way round.
19999
20000 2004-05-19  Paul Eggert  <eggert@cs.ucla.edu>
20001
20002         * lib/obstack.c (_obstack): Remove unused variable.  It hasn't been
20003         present in glibc since revision 1.1 of this file.
20004         * lib/obstack.h (_obstack_free, obstack_1grow, obstack_1grow_fast,
20005         obstack_alignment_mask, obstack_alloc, obstack_base,
20006         obstack_blank, obstack_blank_fast, obstack_chunk_size,
20007         obstack_copy, obstack_copy0, obstack_finish, obstack_grow,
20008         obstack_grow0, obstack_init, obstack_int_grow,
20009         obstack_int_grow_fast, obstack_make_room, obstack_memory_used,
20010         obstack_next_free, obstack_object_size, obstack_ptr_grow,
20011         obstack_ptr_grow_fast, obstack_room): Remove declarations of
20012         nonexistent functions.
20013
20014 2004-05-18  Karl Berry  <karl@gnu.org>
20015
20016         * config/srclist.txt: break link for vasnprintf.c.
20017
20018 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
20019
20020         Port obstack to the AS/400, where pointers are 16 bytes wide and
20021         you cannot cast an integer to a valid pointer.  This patch is
20022         currently waiting to be integrated into glibc; see
20023         <http://sources.redhat.com/ml/libc-alpha/2004-05/msg00073.html>.
20024
20025         * lib/obstack.h (__PTR_TO_INT, __INT_TO_PTR): Remove.
20026         All uses of __INT_TO_PTR (PTR_TO_INT ...) replaced by __PTR_ALIGN.
20027         (__BPTR_ALIGN, __PTR_ALIGN): New macros.
20028         (struct obstack): temp member is now a union of a pointer and
20029         an integer, instead of an integer.  All integer uses changed.
20030         This does not affect the physical layout of struct obstack,
20031         except on hosts (like the AS/400) where the size or alignment of
20032         void * is greater than that of ptrdiff_t.
20033         (obstack_finish) [! (defined __GNUC__ && defined __STDC__ &&
20034         __STDC__)]: Store temporary in pointer member of union, not
20035         integer member.
20036         * lib/obstack.c: Include <stddef.h>, for offsetof.
20037         (struct fooalign): Remove; it doesn't need a name.
20038         (union fooround): Change double to long double, and add void *.
20039         (DEFAULT_ALIGNMENT): Use offsetof to compute.
20040         (DEFAULT_ALIGNMENT, DEFAULT_ROUNDING): Now an enum constant,
20041         not a macro.  Hence the values are always int; so remove all
20042         casts-to-int in uses.
20043
20044 2004-05-17  Paul Eggert  <eggert@cs.ucla.edu>
20045
20046         * config/srclist.txt: Break link for argp-help.c and argp-parse.c until
20047         we can get this patch merged into glibc.
20048
20049 2004-05-17  Derek R. Price  <derek@ximbiot.com>
20050             Paul Eggert  <eggert@cs.ucla.edu>
20051
20052         * m4/argp: Depend on alloca.
20053
20054 2004-05-17  Derek R. Price  <derek@ximbiot.com>
20055             Paul Eggert  <eggert@cs.ucla.edu>
20056
20057         * lib/argp-help.c, argp-parse.c: Assume <alloca.h> rather than
20058         freecoding.
20059
20060 2004-05-17  Bruno Haible  <bruno@clisp.org>
20061
20062         * lib/vasnprintf.c (VASNPRINTF): Correctly handle the case of a
20063         precision that consists of a '.' followed by an empty digit string.
20064         Patch by Tor Lillqvist <tml@iki.fi>.
20065
20066 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
20067
20068         * m4/alloca.m4 (gl_FUNC_ALLOCA): Define HAVE_ALLOCA_H always,
20069         for backward compatibility with older code.  We need our own
20070         alloca.h if _AIX is defined.  Define HAVE_ALLOCA if we discover
20071         it under some other name, and our alloca.h will define it.
20072
20073 2004-05-16  Paul Eggert  <eggert@cs.ucla.edu>
20074             Derek Price  <derek@ximbiot.com>
20075
20076         * lib/alloca.c: Include <alloca.h>, to get our interface.
20077         * lib/alloca_.h: Use __alloca on AIX, so that we don't have to
20078         include <alloca.h> first.  Use C89 prototype for alloca; this
20079         requires including <stddef.h> for size_t.  Use extern "C" if C++.
20080         Use #elif for simplicity, since we can assume C89 now.
20081         Don't try to source the system alloca.h since it will not be found
20082         and to prevent recursively including its replacement.
20083         * lib/fnmatch.c: Include <alloca.h> instead of opencoding.
20084         * lib/regex.c: Likewise.
20085
20086 2004-05-16  Derek Price  <derek@ximbiot.com>
20087             Paul Eggert  <eggert@cs.ucla.edu>
20088
20089         getline cleanup.  This changes the getndelim2 API: both order of
20090         arguments, and meaning of delim2 (now uses EOF, not 0, to indicate
20091         no delimiter).
20092
20093         * lib/getline.c: Don't include stddef.h or stdio.h, since our
20094         interface does that.
20095         (getline): Always use getdelim, so that we don't have two
20096         copies of this code.
20097         * lib/getndelim2.c: Include <limits.h>, <inttypes.h>, <stdint.h>
20098         if available.
20099         (PTRDIFF_MAX, SIZE_MAX, SSIZE_MAX): Define if not defined.
20100         (GETNDELIM2_MAXIMUM): New macro.
20101         (getndelim2): Reorder arguments.  delim==EOF now means no delimiter,
20102         instead of the old practice of delim2==0.  All callers changed.
20103         Return -1 on overflow, instead of returning junk.
20104         Do not set *linesize unless allocation succeeds.
20105         * lib/getndelim2.h: Do not include stddef.h; no longer needed, now
20106         that we include sys/types.h.
20107         * lib/getnline.h: Likewise.
20108         * lib/getndelim2.h (GETNLINE_NO_LIMIT): New macro.
20109         (getndelim2): Reorder arguments.
20110         * lib/getnline.c (getnline, getndelim):
20111         Don't discard the NMAX argument.
20112         (getnline): Invoke getndelim, to avoid code duplication.
20113         * lib/getnline.h (GETNLINE_NO_LIMIT): New macro, used instead
20114         of (size_t) -1 by callers of the getnline family.
20115
20116 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20117
20118         * m4/gettime.m4 (gl_GETTIME): Require gl_TIMESPEC.
20119         Check for gettimeofday.
20120         * m4/settime.m4 (gl_SETTIME): Require gl_TIMESPEC.
20121         Check for settimeofday, stime.
20122
20123 2004-05-13  Paul Eggert  <eggert@cs.ucla.edu>
20124
20125         * lib/nanosleep.c (suspended): Change its type from int to
20126         sig_atomic_t volatile.
20127         (first_call): Make it private to rpl_nanosleep, and have it
20128         be zero initially as that's a bit faster.
20129         (my_usleep): Round up fractional times instead of truncating them,
20130         as this is the usual meaning for 'sleep'.
20131
20132         * lib/gettime.c (gettime): Fall back on `time' if `gettimeofday'
20133         doesn't work.
20134         * lib/settime.c: Include <unistd.h>, for stime (on Solaris 8, anyway).
20135         (ENOSYS): Define if not defined.
20136         (settime): Fall back on stime if it exists and settimeofday fails.
20137         But don't bother with fallbacks if a method fails with errno == EPERM.
20138
20139 2004-05-11  Jim Meyering  <jim@meyering.net>
20140
20141         Prior to this change, the save_cwd caller required read access to the
20142         current directory on most systems (ones with the fchdir function).
20143
20144         * lib/save-cwd.c (save_cwd) [HAVE_FCHDIR]: If opening `.' read-only
20145         fails, try write-only, and finally, resort to using xgetcwd.
20146
20147 2004-05-06  Paul Eggert  <eggert@cs.ucla.edu>
20148
20149         * lib/obstack.c, obstack.h: Import changes from libc.
20150
20151 2004-04-28  Bruno Haible  <bruno@clisp.org>
20152
20153         * lib/findprog.c (find_in_path): Treat Cygwin like Windows, since it
20154         also implicitly appends .exe to executables.
20155         * lib/localcharset.c (ISSLASH): Treat Cygwin like Windows, since it now
20156         accepts Windows pathnames.
20157         * lib/pathname.h (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
20158         Treat Cygwin like Windows, since it now accepts Windows pathnames.
20159         * lib/progreloc.c (ISSLASH, IS_PATH_WITH_DIR, FILESYSTEM_PREFIX_LEN):
20160         Treat Cygwin like Windows, since it now accepts Windows pathnames.
20161         Reported by Derek Robert Price <derek@ximbiot.com>.
20162
20163 2004-04-21  Karl Berry  <karl@gnu.org>
20164
20165         * config/srclist.txt (localcharset.c): break sync.
20166
20167 2004-04-20  Paul Eggert  <eggert@twinsun.com>
20168
20169         * m4/host-os.m4: Add a copyright notice.
20170
20171 2004-04-20  Jim Meyering  <jim@meyering.net>
20172
20173         Change UTILS_ to gl_ in AC_DEFINE'd names.
20174         Change utils_- and jm_-prefixed variables, too.
20175         * m4/mkdir-slash.m4 (gl_FUNC_MKDIR_TRAILING_SLASH): Renamed from
20176         UTILS_FUNC_MKDIR_TRAILING_SLASH.
20177         * m4/mkstemp.m4 (gl_FUNC_MKSTEMP): Renamed from UTILS_FUNC_MKSTEP.
20178
20179         * m4/dirfd.m4 (gl_FUNC_DIRFD): Rename from UTILS_FUNC_DIRFD.
20180         Don't emit trailing blanks.
20181         Also rename jm_-prefixed variables to have gl_ prefix.
20182
20183         * m4/host-os.m4 (gl_HOST_OS): Rename from UTILS_HOST_OS.
20184         Also rename jm_-prefixed variables to have gl_ prefix.
20185
20186         * m4/jm-macros.m4: Reflect the renamings.
20187         * m4/prereq.m4: Likewise.
20188
20189 2004-04-20  Jim Meyering  <jim@meyering.net>
20190
20191         * lib/getndelim2.c (getndelim2): Upon realloc failure, don't leak
20192         memory.
20193
20194 2004-04-20  Jim Meyering  <jim@meyering.net>
20195             Bruno Haible  <bruno@clisp.org>
20196
20197         * lib/localcharset.c (get_charset_aliases) [!VMS && !WIN32]: Don't leak
20198         memory when realloc fails.
20199
20200 2004-04-19  Jim Meyering  <jim@meyering.net>
20201
20202         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Require gl_FUNC_FREE,
20203         now that readutmp.c may call `free (0)'.
20204
20205 2004-04-19  Bruno Haible  <bruno@clisp.org>
20206
20207         * m4/mbrtowc.m4: Change jm_ to gl_ in cache variables as well.
20208         * m4/inttypes_h.m4: Likewise.
20209         * m4/stdint_h.m4: Likewise.
20210         * m4/intmax_t.m4: Likewise.
20211         * m4/uintmax_t.m4: Likewise.
20212
20213 2004-04-18  Jim Meyering  <jim@meyering.net>
20214
20215         * m4/prereq.m4: Don't forbid jm_ prefix.
20216
20217         * m4/afs.m4, m4/allocsa.m4, m4/assert.m4, m4/backupfile.m4:
20218         * m4/bison.m4, m4/check-decl.m4, m4/chown.m4, m4/d-ino.m4:
20219         * m4/d-type.m4, m4/dirname.m4, m4/dos.m4, m4/error.m4, m4/fpending.m4:
20220         * m4/fstypename.m4, m4/fsusage.m4, m4/ftruncate.m4, m4/getdate.m4:
20221         * m4/getgroups.m4, m4/gettext.m4, m4/glibc21.m4, m4/group-member.m4:
20222         * m4/human.m4, m4/intmax.m4, m4/intmax_t.m4, m4/inttostr.m4:
20223         * m4/inttypes.m4, m4/inttypes_h.m4, m4/jm-macros.m4, m4/jm-winsz1.m4:
20224         * m4/jm-winsz2.m4, m4/lchown.m4, m4/lib-check.m4, m4/link-follow.m4:
20225         * m4/localcharset.m4, m4/longlong.m4, m4/ls-mntd-fs.m4, m4/lstat.m4:
20226         * m4/makepath.m4, m4/mbrtowc.m4, m4/mbswidth.m4, m4/memchr.m4:
20227         * m4/memcmp.m4, m4/mkdtemp.m4, m4/mkstemp.m4, m4/mountlist.m4:
20228         * m4/nanosleep.m4, m4/path-concat.m4, m4/perl.m4, m4/prereq.m4:
20229         * m4/putenv.m4, m4/quotearg.m4, m4/regex.m4, m4/stat.m4:
20230         * m4/stdint_h.m4, m4/strftime.m4, m4/strtoimax.m4, m4/strtoll.m4:
20231         * m4/strtoull.m4, m4/strtoumax.m4, m4/timespec.m4, m4/uintmax_t.m4:
20232         * m4/ulonglong.m4, m4/unlink-busy.m4, m4/unlocked-io.m4, m4/uptime.m4,
20233         * m4/utimbuf.m4, m4/utime.m4, m4/utimes-null.m4, m4/vasnprintf.m4:
20234         * m4/xstrtoimax.m4, m4/xstrtol.m4, m4/xstrtoumax.m4:
20235         Change jm_ to gl_ in AC_DEFINE'd names. Update all uses.
20236
20237 2004-04-18  Jim Meyering  <jim@meyering.net>
20238
20239         * lib/readutmp.c (read_utmp) [UTMP_NAME_FUNCTION]: Upon realloc
20240         failure, don't leak memory and do call END_UTMP_ENT.
20241
20242 2004-04-16  Jim Meyering  <jim@meyering.net>
20243
20244         * m4/prereq.m4 (jm_PREREQ_STAT): Remove macro.  It is specific to
20245         coreutils' stat program.
20246         (gl_PREREQ): Don't require jm_PREREQ_STAT.
20247
20248 2004-04-11  Paul Eggert  <eggert@twinsun.com>
20249
20250         * lib/inttostr.h: Include <limits.h> unconditionally, since we assume
20251         C89.
20252         (CHAR_BIT): Remove, since we assume C89.
20253         Include <stdint.h> if available, as per current Autoconf CVS advice.
20254
20255 2004-03-31  Jim Meyering  <jim@meyering.net>
20256
20257         * m4/prereq.m4: Require AC_FUNC_MALLOC, not jm_FUNC_MALLOC.
20258         Require AC_FUNC_REALLOC, not jm_FUNC_REALLOC.
20259         * m4/xalloc.m4: Likewise.
20260
20261 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20262
20263         Merge from coreutils.
20264
20265         * m4/inttostr.m4: New file.
20266         * m4/getdate.m4 (gl_GETDATE): Remove time-related stuff.
20267         Require AM_STDBOOL_H and gl_TIMESPEC instead.
20268         Require gl_CLOCK_TIME.
20269         * m4/clock_time.m4 (gl_CLOCK_TIME): Require AC_GNU_SOURCE.
20270
20271 2004-03-30  Paul Eggert  <eggert@twinsun.com>
20272
20273         * lib/cloexec.h, cloexec.c (set_cloexec_flag): Return int
20274         not bool, to be more consistent with Unix conventions.
20275         Suggested by Bruno Haible.
20276
20277         Merge from coreutils.
20278
20279         * lib/imaxtostr.c, lib/inttostr.c, lib/inttostr.h, lib/offtostr.c:
20280         * lib/umaxtostr.c: New files.
20281
20282         * lib/getdate.h: Include stdbool.h, and timespec.h instead of
20283         the usual <time.h> dance.
20284         (get_date): Change signature to support fractional time stamps.
20285         All callers changed.
20286         * lib/getdate.y: Include "getdate.h" first, as we can now
20287         assume C89 and don't need to worry about 'const'.
20288         Similarly, include "unlocked-io.h" near start, not in middle.
20289         Include <limits.h>.
20290         (textint.value): Use long int rather than int.
20291         (textint.digits): Use size_t rather than int.
20292         (BILLION, LOG10_BILLION): New constants.
20293         (parser_control): New member rel_ns.  Members day_ordinal,
20294         time_zone, month, day, hour, minutes, rel_year, rel_month,
20295         rel_day, rel_hour, rel_minutes, rel_seconds
20296         are now long int, not int.  Member seconds is now struct timespec,
20297         not int.  New member timespec_seen.  Members dates_seen, days_seen,
20298         local_zones_seen, rels_seen, times_seen, zones_seen are now size_t,
20299         not int.
20300         (%union.intval): Now long int, not int.
20301         New member timespec.
20302         (tSDECIMAL_NUMBER, tUDECIMAL_NUMBER): New tokens.
20303         (seconds, signed_seconds, unsigned_seconds): New nonterminals.
20304         (spec): Now is a timespec or an item list.
20305         (timespec, items): New nonterminals.
20306         (time, rel, relunit, number, get_date):
20307         Add support for fractional seconds.
20308         (time): Fix bug: seconds weren't cleared in "00:00 +0000" syntax.
20309         (gmtime, localtime, mktime): Remove decls; not needed with C89.
20310         (to_hour): First arg is now long int, not int.
20311         (to_year): Returns long int, not int.
20312         Don't treat year -70 like 70.
20313         (tm_diff): Returns long int, not int.
20314         (lookup_word): Use bool instead of int when appropriate.
20315         (yylex): Use size_t for count, not int.
20316         Detect overflow when parsing large integer constants.
20317         Add support for fractions.
20318         (get_date): Make pointers 'const' if possible.
20319         Use more-portable code to detect integer overflow.
20320         (main) [TEST]: Adjust to above changes.  Test for localtime failure.
20321         Don't use ctime; it's not reliable if the year has >4 digits.
20322
20323         * lib/human.c (humblock): Inspect BLOCKSIZE if BLOCK_SIZE isn't set.
20324         This is for compatibility with BSD.
20325
20326         * lib/timespec.h (ST_TIME_CMP_NS, ST_TIME_CMP): Define.
20327         (ATIME_CMP, CTIME_CMP, MTIME_CMP, TIMESPEC_NS): Likewise.
20328         From coreutils' system.h.
20329
20330         * lib/userspec.c: Don't include "posixver.h".
20331         (parse_user_spec): Fall back on USER.GROUP parsing, regardless
20332         of POSIX version, as POSIX 1003.1-2001 allows that behavior as a
20333         compatible extension.  Simplify code by removing a boolean int
20334         that was always nonzero if a string was nonnull.
20335
20336 2004-03-30  Jim Meyering  <jim@meyering.net>
20337
20338         Merge from coreutils.
20339
20340         Avoid a configure-time warning about sys/ucred.h on OSF V4.0.
20341         * m4/ls-mntd-fs.m4: Test for sys/ucred.h separately, since
20342         on some systems one must include <grp.h> before it.
20343         Reported by Christian Krackowizer.
20344
20345 2004-03-30  Jim Meyering  <jim@meyering.net>
20346
20347         Merge from coreutils.
20348
20349         * lib/mountlist.c [HAVE_SYS_UCRED_H]: Include grp.h before sys/ucred.h.
20350
20351         * lib/readtokens.c (readtoken): Don't leak 64 bytes when reading
20352         an empty input stream.
20353
20354         * lib/readtokens.c: Include <stdbool.h>.
20355         (readtoken): Use `size_t' rather than int/long.
20356         All callers adjusted.
20357         Use `bool' rather than `int' where appropriate.
20358         Use memset rather than an explicit loop.
20359         Use x2nrealloc rather than xrealloc.
20360         Allow the use of `\0' as a delimiter.
20361         (readtokens): Likewise.
20362         * lib/readtokens.h (readtoken, readtokens): Update prototypes.
20363
20364 2004-03-30  Jim Meyering  <jim@meyering.net>
20365
20366         * m4/realloc.m4: Remove file, since now it does no more than
20367         AC_REQUIRE([AC_FUNC_REALLOC]), and that can be done via
20368         the `configure.ac' section of module/realloc.
20369         * m4/malloc.m4: Likewise, but for AC_FUNC_MALLOC.
20370
20371 2004-03-30  Bruno Haible  <bruno@clisp.org>
20372
20373         * lib/getloadavg.c (getloadavg): Don't assume setlocale returns
20374         nonnull.
20375
20376 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20377
20378         Merge changes to getloadavg.c from coreutils and Emacs.
20379
20380         * lib/getloadavg.c [!defined HAVE_SETLOCALE] (setlocale):
20381         Define to an expression, not to the empty string.
20382         Include cloexec.h and xalloc.h.
20383         (getloadavg): Restore LC_NUMERIC locale after setting it temporarily.
20384         Use set_cloexec_flag rather than rolling our own.
20385         * lib/cloexec.c, lib/cloexec.h: New files.
20386
20387 2004-03-29  Paul Eggert  <eggert@twinsun.com>
20388
20389         * m4/cloexec.m4: New file.
20390
20391 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20392
20393         * lib/getopt.h: Sync with libc CVS.
20394
20395 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20396             Bruno Haible  <bruno@clisp.org>
20397
20398         * m4/mbswidth.m4 (gl_MBSWIDTH): Also test whether <wchar.h> declares
20399         mbswidth.
20400
20401 2004-03-18  Paul Eggert  <eggert@twinsun.com>
20402             Bruno Haible  <bruno@clisp.org>
20403
20404         * lib/mbswidth.h: Include <wchar.h> only if
20405         HAVE_DECL_MBSWIDTH_IN_WCHAR_H, not on all platforms that have
20406         <wchar.h>.
20407         * lib/mbswidth.c: Include <stdio.h> and <time.h> before <wchar.h>.
20408
20409 2004-03-09  Paul Eggert  <eggert@twinsun.com>
20410
20411         * lib/argp-parse.c, getopt.c, getopt.h, getopt1.c:
20412         Sync with libc CVS.
20413         * lib/getopt_int.h: New file, also synced from libc.
20414
20415 2004-03-09  Paul Eggert  <eggert@twinsun.com>
20416
20417         * config/srclistvars.sh: Add GNUWWWLICENSES for eggert.
20418         * config/srclist.txt: Sync getopt with libc.  Add getopt_int.h.
20419         Bring back getopt.c, getopt.h, getopt1.c.
20420
20421 2004-03-07  Paul Eggert  <eggert@twinsun.com>
20422
20423         * m4/c-stack.m4 (gl_PREREQ_C_STACK): Renamed from jm_PREREQ_C_STACK.
20424         All uses changed.  Check for sa_sigaction member; this fixes
20425         a bug first reported by Jason Andrade in
20426         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
20427
20428 2004-03-07  Paul Eggert  <eggert@twinsun.com>
20429
20430         * lib/c-stack.c (SIGACTION_WORKS): New macro.  Use it instead of long
20431         '#if' expressions.  Unlike the code it replaces, it does not
20432         depend on (defined _SC_PAGESIZE).  However, it does depend on
20433         HAVE_STRUCT_SIGACTION_SA_SIGACTION; this last change fixes a bug
20434         first reported by Jason Andrade in
20435         <http://mail.gnu.org/archive/html/bug-textutils/2003-03/msg00027.html>.
20436
20437 2004-02-25  Simon Josefsson  <jas@extundo.com>
20438
20439         * m4/strdup.m4 (gl_PREREQ_STRDUP): Check whether strdup is declared.
20440
20441 2004-02-25  Simon Josefsson  <jas@extundo.com>
20442
20443         * lib/strdup.h: New file.
20444         * lib/strdup.c: Include it.
20445         * lib/path-concat.c: Include strdup.h. Drop strdup declaration.
20446         * lib/userspec.c: Include strdup.h. Drop strdup declaration.
20447
20448 2004-02-23  Karl Berry  <karl@gnu.org>
20449
20450         * doc/maintain.texi, doc/standards.texi, doc/make-stds.texi: new files
20451         (from fencepost.gnu.org:/gd/gnuorg).
20452
20453 2004-02-23  Karl Berry  <karl@gnu.org>
20454
20455         * config/srclistvars.sh (GNUORG) [karl]: redefine.
20456         * config/srclist.txt: add maintain/standards documents.
20457
20458 2004-02-18  Bruno Haible  <bruno@clisp.org>
20459
20460         * m4/xsize.m4 (gl_XSIZE): Require AC_C_INLINE.
20461         Reported by Derek Robert Price <derek@ximbiot.com>.
20462
20463 2004-02-16  Karl Berry  <karl@gnu.org>
20464
20465         * config/mkinstalldirs, install-sh: update from automake.
20466
20467 2004-02-06  Karl Berry  <karl@gnu.org>
20468
20469         * m4/po.m4: update from gettext 0.14.1.
20470
20471 2004-02-06  Karl Berry  <karl@gnu.org>
20472
20473         * lib/config.charset: update from gettext 0.14.1.
20474
20475 2004-02-05  Paul Eggert  <eggert@twinsun.com>
20476
20477         Add comments and code, prompted by suggestions from Bruno Haible
20478         for sh-quote.
20479         * lib/quotearg.h (quotearg_alloc): New decl.  Improve the comments
20480         describing the enum quoting_style values.
20481         * lib/quotearg.c (quotearg_alloc): New function.
20482         (quotearg_buffer_restyled): Treat lone { and } as special.
20483         Treat = as special.  Work around bug with older shells
20484         that "see" a '\' that is really the 2nd byte of a multibyte char.
20485         Quote empty string with shell_quoting_style.
20486
20487 2004-02-03  Bruno Haible  <bruno@clisp.org>
20488
20489         * m4/pipe.m4: New file, from GNU gettext.
20490
20491 2004-02-03  Bruno Haible  <bruno@clisp.org>
20492
20493         * lib/pipe.h: New file, from GNU gettext.
20494         * lib/pipe.c: New file, from GNU gettext.
20495
20496 2004-01-27  Bruno Haible  <bruno@clisp.org>
20497
20498         * m4/execute.m4: New file, from GNU gettext.
20499
20500 2004-01-27  Bruno Haible  <bruno@clisp.org>
20501
20502         * lib/execute.h: New file, from GNU gettext.
20503         * lib/execute.c: New file, from GNU gettext.
20504         * lib/w32spawn.h: New file, from GNU gettext.
20505
20506 2004-01-24  Paul Eggert  <eggert@twinsun.com>
20507
20508         Merge from diffutils.
20509
20510         * lib/file-type.c (file_type): Add typed memory objects.
20511         * lib/file-type.h (S_TYPEISTMO): New macro.
20512
20513         * lib/c-stack.h (c_stack_action): Remove argv argument.
20514         * lib/c-stack.c (c_stack_action): Likewise.  All uses changed.
20515         (die): Don't calculate message unless segv_action returns.
20516         (get_stack_location, min_address_from_argv, max_address_from_argv,
20517         volatile stack_base, volatile_stack_size): Remove.
20518         (segv_handler): If ! HAVE_XSI_STACK_OVERFLOW_HEURISTIC, assume
20519         that every segmentation violation is a stack overflow.  (Ouch!)
20520         See Debian bug 136249 (still outstanding) for more info about why
20521         HAVE_XSI_STACK_OVERFLOW_HEURISTIC fails on Linux kernels.
20522
20523 2004-01-24  Paul Eggert  <eggert@twinsun.com>
20524
20525         Exit-status fix from coreutils.
20526
20527         Use exit_failure consistently in place of EXIT_FAILURE,
20528         so that program exit statuses are consistent on failure.
20529
20530         * lib/argmatch.c (ARGMATCH_DIE) [! defined ARGMATCH_DIE]:
20531         Include "exitfail.h", and use exit_failure rather than EXIT_FAILURE.
20532         * lib/argmatch.h: Comment fix to match the above.
20533         * lib/obstack.c (obstack_exit_failure) [!defined _LIBC]:
20534         Now a macro referring to exit_failure, instead of a separate
20535         variable.  Include "exitfail.h" to get it.
20536         * lib/xstrtol.h: Include "exitfail.h".
20537         (STRTOL_FATAL_ERROR): Exit with status exit_failure, not 2.
20538
20539         * lib/long-options.c (parse_long_options): Use prototype
20540         for usage function arg.  Pass it EXIT_SUCCESS rather than 0,
20541         for clarity.
20542
20543 2004-01-21  Jim Meyering  <jim@meyering.net>
20544
20545         * lib/mktime.c (__mktime_internal) [!_LIBC]: Define to mktime_internal
20546         so as not to conflict with a different-sized __mktime_internal
20547         function in GNU libc.
20548         * lib/timegm.c (__mktime_internal) [!_LIBC]: Likewise.
20549         Problem building statically-linked `ls' reported by Michael Brunnbauer.
20550
20551 2004-01-20  Karl Berry  <karl@gnu.org>
20552
20553         * config/config.guess: update from config.
20554
20555         * config/srclistvars.sh: GNUWWWLICENSES for karl.
20556
20557 2004-01-20  Bruno Haible  <bruno@clisp.org>
20558
20559         Safer stack allocation.
20560         * lib/setenv.c: Include allocsa.h.
20561         (alloca): Remove fallback definition.
20562         (freea): Remove macro.
20563         (__add_to_environ) [!_LIBC]: Use allocsa instead of alloca. Use freesa
20564         instead of freea.
20565
20566 2004-01-20  Bruno Haible  <bruno@clisp.org>
20567
20568         * m4/eealloc.m4: New file, from GNU gettext.
20569
20570 2004-01-20  Bruno Haible  <bruno@clisp.org>
20571
20572         * m4/allocsa.m4: New file, from GNU gettext.
20573
20574 2004-01-20  Bruno Haible  <bruno@clisp.org>
20575
20576         * lib/xallocsa.h: New file, from GNU gettext.
20577         * lib/xallocsa.c: New file, from GNU gettext.
20578
20579 2004-01-20  Bruno Haible  <bruno@clisp.org>
20580
20581         * lib/wait-process.c: On Windows, include windows.h. Needed on mingw.
20582
20583 2004-01-20  Bruno Haible  <bruno@clisp.org>
20584
20585         * lib/wait-process.c (wait_subprocess): Add ignore_sigpipe argument.
20586         * lib/wait-process.c (wait_subprocess): Likewise. Handle SIGPIPE
20587         specially.
20588
20589 2004-01-20  Bruno Haible  <bruno@clisp.org>
20590
20591         * lib/wait-process.c (wait_process): Disable the 2003-10-31 waitid()
20592         patch.
20593
20594 2004-01-20  Bruno Haible  <bruno@clisp.org>
20595
20596         * lib/wait-process.c (cleanup_slaves): Use ANSI C declaration.
20597
20598 2004-01-20  Bruno Haible  <bruno@clisp.org>
20599
20600         * lib/eealloc.h: New file.
20601
20602 2004-01-20  Bruno Haible  <bruno@clisp.org>
20603
20604         * lib/binary-io.h: Avoid warnings on Cygwin.
20605
20606 2004-01-20  Bruno Haible  <bruno@clisp.org>
20607
20608         * lib/allocsa.h: New file, from GNU gettext.
20609         * lib/allocsa.c: New file, from GNU gettext.
20610
20611 2004-01-18  Karl Berry  <karl@gnu.org>
20612
20613         * doc/gpl.texi, doc/lgpl.texi: new files.
20614
20615 2004-01-18  Karl Berry  <karl@gnu.org>
20616
20617         * config/srclistvars.sh (GNUWWWLICENSES): new variable.
20618         * config/srclist.txt ({fdl,gpl,lgpl}.text): get from there.
20619
20620 2004-01-15  Paul Eggert  <eggert@twinsun.com>
20621
20622         Merge from coreutils.
20623
20624         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for uintptr_t.
20625         * m4/posixver.m4 (gl_POSIXVER): Require gl_DEFAULT_POSIX2_VERSION.
20626         (gl_DEFAULT_POSIX2_VERSION): Move
20627         the documentation from 'configure' into 'config.hin',
20628         so that 'configure --help' isn't burdened by it and
20629         we don't have to worry about its formatting there.
20630         Reword the documentation so that it's more succinct
20631         and can be run together into a single paragraph.
20632         * m4/same.m4 (gl_SAME): Check for pathconf.
20633
20634 2004-01-15  Paul Eggert  <eggert@twinsun.com>
20635
20636         Merge from coreutils.
20637
20638         * lib/posixver.c: Include posixver.h.
20639
20640         * lib/same.c: Include <stdbool.h>, <limits.h>.
20641         (_POSIX_NAME_MAX): Define if not defined.
20642         (MIN): New macro.
20643         (same_name): If file names are silently truncated, report
20644         that the file names are the same if they are the same after
20645         the silent truncation.
20646
20647         * lib/xstrtod.h (xstrtod): Accept an extra arg, specifying the
20648         conversion function.
20649         * lib/xstrtod.c (xstrtod): Likewise.  All callers changed to
20650         include c-strtod.h and use c_strtod.  Don't include stdlib.h; no
20651         longer needed.
20652
20653 2004-01-15  Jim Meyering  <jim@meyering.net>
20654
20655         Merge from coreutils.
20656
20657         * m4/clock_time.m4 (gl_CLOCK_TIME): Don't set LIB_CLOCK_GETTIME
20658         if no library is required.
20659         * m4/jm-macros.m4: Don't require UTILS_SYS_OPEN_MAX.
20660         * m4/jm-macros.m4 (jm_MACROS): Require gl_FUNC_FREE.
20661         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.58.
20662         (AC_LANG_SOURCE): Remove definition, now that we require autoconf-2.58.
20663         * m4/jm-macros.m4 (jm_MACROS): Don't require AC_FUNC_FTW.
20664         * m4/lib-check.m4 (jm_LIB_CHECK): Do not set LIB_CRYPT to the
20665         value, $ac_cv_search_crypt, if it's "none required".
20666         * m4/posixver.m4 (gl_DEFAULT_POSIX2_VERSION): New macro.
20667         * m4/prereq.m4 (jm_PREREQ): Require AC_FUNC_GETLOADAVG,
20668         not gl_FUNC_GETLOADAVG.
20669         * m4/prereq.m4 (jm_PREREQ): Require gl_READTOKENS, gl_MD5, gl_MAKEPATH,
20670         gl_LONG_OPTIONS, and gl_IDCACHE, gl_GETUGROUPS.
20671
20672 2004-01-15  Jim Meyering  <jim@meyering.net>
20673
20674         Merge from coreutils.
20675
20676         * lib/md5.h (rol) [__GNUC__ && __i386__]: Don't use `asm' code.  These
20677         days, gcc-3.x does better all by itself.  Patch from Dean Gaudet:
20678         http://mail.gnu.org/archive/html/bug-coreutils/2003-11/msg00144.html
20679
20680         * lib/posixver.c (DEFAULT_POSIX2_VERSION): Use definition of new,
20681         optional configure-time default.
20682
20683         * lib/version-etc.c (version_etc_copyright): Update copyright date.
20684
20685         * lib/xreadlink.c (xreadlink): Correct outdated comment.
20686
20687 2004-01-15  Alexandre Duret-Lutz  <adl@gnu.org>
20688
20689         Merge from coreutils.
20690
20691         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Do not set LIB_NANOSLEEP to the
20692         value, $ac_cv_search_nanosleep, if it's "none required".
20693
20694 2004-01-14  Paul Eggert  <eggert@twinsun.com>
20695
20696         * lib/fnmatch_loop.c (ALLOCA_LIMIT): Remove macro, which collided
20697         with like-named macro in fnmatch.c.
20698         (EXT): Use an internal constant instead.
20699
20700         Merge fnmatch patches from glibc.
20701         * lib/fnmatch.c (mbsinit): Remove define.
20702         Add libc_hidden_ver (__fnmatch, fnmatch).
20703         * lib/fnmatch_loop.c (FCT): Cast to int32_t and UCHAR when appropriate.
20704         Adjust to renaming of collseq_table_lookup to __collseq_table_lookup.
20705
20706 2004-01-14  Karl Berry  <karl@gnu.org>
20707
20708         * config/install-sh: update from automake.
20709
20710 2004-01-13  Karl Berry  <karl@gnu.org>
20711
20712         * config/install-sh: update from automake.
20713
20714 2004-01-09  Karl Berry  <karl@gnu.org>
20715
20716         * config/install-sh: update from automake.
20717
20718 2004-01-05  Karl Berry  <karl@gnu.org>
20719
20720         * config/config.{sub,guess}: update from config.
20721
20722 2003-12-31  Karl Berry  <karl@gnu.org>
20723
20724         * config/depcomp: update from automake.
20725
20726 2003-12-14  Karl Berry  <karl@gnu.org>
20727
20728         * lib/config.charset: update from gettext-runtime.
20729
20730 2003-12-03  Paul Eggert  <eggert@twinsun.com>
20731
20732         * lib/getgroups.c (getgroups): xmalloc takes one argument, not two.
20733         Bug reported by Alfred M. Szmidt.
20734
20735 2003-12-03  Bruno Haible  <bruno@clisp.org>
20736
20737         * m4/gettext.m4: Upgrade from gettext-0.13.
20738         * m4/po.m4: Upgrade from gettext-0.13.
20739         * m4/size_max.m4 (gl_SIZE_MAX): Don't use the _ONCE macros here.
20740         * m4/intmax.m4: New file, from gettext-0.13.
20741         * m4/printf-posix.m4: New file, from gettext-0.13.
20742
20743 2003-11-29  Karl Berry  <karl@gnu.org>
20744
20745         * lib/argp-{help.c,parse.c,namefrob.h}, argp.h: update from libc.
20746
20747 2003-11-25  Paul Eggert  <eggert@twinsun.com>
20748             Bruno Haible  <bruno@clisp.org>
20749
20750         * lib/printf-parse.h: Don't include sys/types.h.
20751         (ARG_NONE): New macro.
20752         (char_directive): Change type of *arg_index fields to size_t.
20753         * lib/printf-parse.c: Don't include sys/types.h.
20754         (SSIZE_MAX): Remove macro.
20755         (PRINTF_PARSE): Change the type of the arg_index variables to size_t.
20756         Remove unnecessary overflow check.
20757         * lib/vasnprintf.c (VASNPRINTF): Update for type change of *arg_index
20758         fields.
20759
20760 2003-11-25  Bruno Haible  <bruno@clisp.org>
20761
20762         * modules/vasnprintf (Files): Remove m4/ssize_t.m4.
20763
20764 2003-11-25  Bruno Haible  <bruno@clisp.org>
20765
20766         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Don't require
20767         gt_TYPE_SSIZE_T.
20768
20769 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20770
20771         * modules/alloca: Remove dependency on xalloc.
20772
20773 2003-11-24  Paul Eggert  <eggert@twinsun.com>
20774
20775         * lib/alloca.c: Remove dependency on xalloc module.
20776         (xalloc_die): Remove.
20777         (memory_full) [!defined emacs]: New macro.
20778         [!defined emacs]: Don't include xalloc.h.
20779         (alloca): Invoke memory_full, not xalloc_die, if malloc fails or
20780         address arithmetic overflows.  Change datatypes a bit to avoid
20781         unnecessary casts.
20782
20783 2003-11-22  Jim Meyering  <jim@meyering.net>
20784
20785         * lib/xmalloc.c (x2nrealloc_inline): Fix typos in comments:
20786         s/size/size_t/.
20787
20788 2003-11-21  Karl Berry  <karl@gnu.org>
20789
20790         * config/config.{sub,guess}: update from config.
20791
20792 2003-11-18  Karl Berry  <karl@gnu.org>
20793
20794         * config/config.{sub,guess}: update from config.
20795
20796         * config/(printf-{parse,args}.[ch]): sync broken, sigh.
20797
20798 2003-11-17  Paul Eggert  <eggert@twinsun.com>
20799
20800         * README: Mention that S+T cannot overflow if S is the size of
20801         an existing object and T is sufficiently small.
20802
20803 2003-11-17  Jim Meyering  <jim@meyering.net>
20804
20805         On systems without utime and without a utimes function capable of
20806         dealing with a NULL struct utimbuf* argument, this utime replacement
20807         could -- in unusual circumstances -- leak a file descriptor.
20808         * lib/utime.c: Include <unistd.h> and <errno.h>.
20809         (utime_null): Be sure to close `fd' and to preserve errno.
20810         Reported by Geoff Collyer via Arnold Robbins.
20811
20812 2003-11-17  Bruno Haible  <bruno@clisp.org>
20813
20814         * modules/vasnprintf (Files): Add m4/ssize_t.m4.
20815         (Depends-on): Add xsize.
20816
20817 2003-11-17  Bruno Haible  <bruno@clisp.org>
20818
20819         * m4/vasnprintf.m4 (gl_PREREQ_PRINTF_PARSE): Require gt_TYPE_SSIZE_T.
20820
20821 2003-11-17  Bruno Haible  <bruno@clisp.org>
20822
20823         * lib/vasnprintf.c (alloca): Remove fallback definition.
20824         (freea): Remove definition.
20825         (VASNPRINTF): Use alloca only for small sizes, say <= 4000 bytes.
20826         Reported by Paul Eggert.
20827
20828 2003-11-16  Paul Eggert  <eggert@twinsun.com>
20829             Bruno Haible  <bruno@clisp.org>
20830
20831         Protect against address arithmetic overflow.
20832         * lib/printf-args.h: Include stddef.h.
20833         (arguments): Change type of field 'count' to size_t.
20834         * lib/printf-args.c (printf_fetchargs): Use size_t instead of
20835         'unsigned int' where appropriate.
20836         * lib/printf-parse.h: Include sys/types.h.
20837         (char_directive): Change type of *arg_index fields to ssize_t.
20838         (char_directives): Change type of fields 'count', max_*_length to
20839         size_t.
20840         * lib/printf-parse.c: Include sys/types.h and xsize.h.
20841         (SSIZE_MAX): Define fallback value.
20842         (PRINTF_PARSE): Use size_t instead of 'unsigned int' and ssize_t
20843         instead of 'int' where appropriate. Check a_allocated, d_allocated
20844         against overflow. Reject %m$ argument numbers > SSIZE_MAX + 1.
20845         * lib/vasnprintf.c: Include xsize.h.
20846         (VASNPRINTF): Use size_t instead of 'unsigned int' where appropriate.
20847         Check alloca, malloc, realloc, ENSURE_ALLOCATION arguments against
20848         overflow. Avoid wraparound when converting a width or precision from
20849         decimal to binary.
20850
20851 2003-11-16  Bruno Haible  <bruno@clisp.org>
20852
20853         Update from GNU gettext.
20854         * lib/printf-parse.c: Generalize to it can be compiled for wide
20855         strings.
20856         (PRINTF_PARSE, CHAR_T, DIRECTIVE, DIRECTIVES): New macros.
20857         * lib/vasnprintf.c: Generalize to it can be compiled for wide strings.
20858         (VASNPRINTF, CHAR_T, DIRECTIVE, DIRECTIVES, PRINTF_PARSE, USE_SNPRINTF,
20859         SNPRINTF): New macros.
20860         Don't include <alloca.h> if the file is used inside libintl.
20861         (local_wcslen): New function, for Solaris 2.5.1.
20862         (VASNPRINTF): Use it instead of wcslen.
20863
20864 2003-11-16  Bruno Haible  <bruno@clisp.org>
20865
20866         * lib/xsize.h (xmax): New function.
20867         (xsum, xsum3, xsum4): Declare as "pure" functions.
20868
20869 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20870
20871         * modules/xalloc (Files): Undo latest change, since xalloc.h
20872         no longer needs SIZE_MAX or PTRDIFF_MAX.
20873
20874 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20875
20876         * m4/xalloc.m4 (gl_PREREQ_XALLOC): Do not require gl_SIZE_MAX or
20877         gl_PTRDIFF_MAX.
20878
20879 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20880
20881         * lib/xstrtol.c (__xstrtol): Remove "break" immediately after
20882         "return", to pacify some unknown compiler.  Problem reported
20883         by Joerg Schilling.
20884
20885 2003-11-12  Paul Eggert  <eggert@twinsun.com>
20886
20887         * lib/xalloc.h: Do not include <limits.h> or <stdint.h>.
20888         (xalloc_oversized): Use sizeof (ptrdiff_t) and sizeof (size_t) for
20889         the heuristic, rather than PTRDIFF_MAX and SIZE_MAX.  This
20890         heuristic is just as accurate as far as we know, and it removes a
20891         dependency on size_max.m4 and ptrdiff_max.m4.
20892
20893 2003-11-11  Bruno Haible  <bruno@clisp.org>
20894
20895         * modules/xsize (Files): Add m4/size_max.m4.
20896         * modules/xalloc (Files): Add m4/size_max.m4, m4/ptrdiff_max.m4.
20897
20898 2003-11-11  Bruno Haible  <bruno@clisp.org>
20899
20900         * m4/size_max.m4: New file.
20901         * m4/ptrdiff_max.m4: New file.
20902         * m4/xsize,m4 (gl_XSIZE): Require gl_SIZE_MAX.
20903         * m4/xalloc.m4 (gl_PREREQ_XALLOC): New macro.
20904         (gl_XALLOC): Invoke it.
20905
20906 2003-11-11  Bruno Haible  <bruno@clisp.org>
20907
20908         * lib/xsize.h (SIZE_MAX): Remove fallback definition.
20909         * lib/xalloc.h: Include limits.h. Assume SIZE_MAX and PTRDIFF_MAX are
20910         defined.
20911
20912 2003-11-10  Paul Eggert  <eggert@twinsun.com>
20913
20914         * lib/xalloc.h (xalloc_oversized): [! (defined PTRDIFF_MAX &&
20915         PTRDIFF_MAX < SIZE_MAX)]: Fix off-by-one error that would have
20916         rejected some allocations of exactly SIZE_MAX - 2 bytes.
20917         From Bruno Haible.
20918         [defined PTRDIFF_MAX && PTRDIFF_MAX < SIZE_MAX]: Use SIZE_MAX,
20919         not (size_t) -1, since it's defined here.
20920
20921 2003-11-09  Karl Berry  <karl@gnu.org>
20922
20923         * config/mkinstalldirs, depcomp, mdate-sh: update from automake.
20924
20925 2003-11-06  Paul Eggert  <eggert@twinsun.com>
20926
20927         * lib/xalloc.h [HAVE_STDINT_H]: Include <stdint.h>.
20928         (xalloc_oversized) [! (PTRDIFF_MAX < SIZE_MAX)]:
20929         Reject sizes of exactly SIZE_MAX bytes.
20930         * lib/xreadlink.c: Include "xalloc.h" before checking whether SIZE_MAX
20931         is defined, since "xalloc.h" now defines SIZE_MAX on modern hosts.
20932
20933 2003-11-05  Bruno Haible  <bruno@clisp.org>
20934
20935         * lib/xsize.h: Include limits.h, to avoid a possible collision with
20936         SIZE_MAX defined in <limits.h> on Solaris.
20937
20938 2003-11-04  Jim Meyering  <jim@meyering.net>
20939
20940         * modules/sysexits: Use the `$(VAR)' notation for AC_SUBST'd
20941         variable names, rather than @VAR@.
20942         * modules/poll: Likewise.
20943
20944 2003-11-04  Bruno Haible  <bruno@clisp.org>
20945
20946         * modules/xsize: New file.
20947         * modules/linebreak: Depend on xsize.
20948         * MODULES.html.sh (func_all_modules): Add xsize.
20949
20950 2003-11-04  Bruno Haible  <bruno@clisp.org>
20951
20952         * m4/xsize.m4: New file.
20953
20954 2003-11-04  Bruno Haible  <bruno@clisp.org>
20955
20956         * lib/xsize.h: New file.
20957         * lib/linebreak.c: Include xsize.h.
20958         (mbs_possible_linebreaks, mbs_width_linebreaks): Check malloc()
20959         argument for overflow.
20960         Suggested by Paul Eggert.
20961
20962 2003-11-03  Karl Berry  <karl@gnu.org>
20963
20964         * config/config.{guess,sub}: update from config.
20965
20966 2003-11-03  Jim Meyering  <jim@meyering.net>
20967
20968         * modules/userspec (lib_SOURCES): Add userspec.h.
20969         (Include): Add "userspec.h".
20970         Improve description.
20971
20972 2003-11-03  Jim Meyering  <jim@meyering.net>
20973
20974         * lib/userspec.c: Include "userspec.h".
20975         * lib/userspec.h: New file.
20976
20977 2003-11-03  Bruno Haible  <bruno@clisp.org>
20978
20979         * m4/wait-process.m4 (gl_WAIT_PROCESS): Also check for waitid.
20980
20981 2003-11-03  Bruno Haible  <bruno@clisp.org>
20982
20983         * lib/wait-process.c (wait_process): Use waitid with WNOWAIT if
20984         available, to avoid (extremely rare) race condition.
20985         Suggested by Paul Eggert.
20986
20987 2003-11-02  Karl Berry  <karl@gnu.org>
20988
20989         * config/srclist.txt (vasprintf.c): sync broken, sigh.
20990
20991 2003-10-31  Paul Eggert  <eggert@twinsun.com>
20992
20993         * lib/mountlist.h (struct mount_entry.me_type_malloced): New member.
20994         * lib/mountlist.c (SIZE_MAX): Define if not defined already.
20995         (read_filesystem_list): Set and use me_type_malloced.
20996         Use "sizeof *me" rather than "sizeof (struct mount_entry)" (or
20997         whatever the type happens to be), for brevity and consistency.
20998         Check for size calculation overflow on Alphas running OSF/1.
20999
21000 2003-10-31  Jim Meyering  <jim@meyering.net>
21001
21002         * lib/hash.c: Include "xalloc.h" for use of xalloc_oversized.
21003
21004         * lib/linebuffer.c: Include <string.h> for declaration of memset.
21005
21006 2003-10-30  Paul Eggert  <eggert@twinsun.com>
21007             Bruno Haible  <bruno@clisp.org>
21008
21009         * lib/vasprintf.c: Include <limits.h>, <stdlib.h>.
21010         (vasprintf): Fail if the resulting length doesn't fit in an 'int'.
21011
21012 2003-10-30  Paul Eggert  <eggert@cs.ucla.edu>
21013
21014         * m4/host-os.m4 (UTILS_HOST_OS): Change netbsd*-gnu pattern back to
21015         netbsd*-gnu*.  Suggested by Robert Millan.
21016
21017 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21018
21019         * modules/group-member: Depend on stdbool.
21020
21021 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21022
21023         * m4/xalloc.m4 (gl_XALLOC): Undo previous change.
21024
21025 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21026
21027         * m4/host-os.m4 (UTILS_HOST_OS): Resurrect netbsd*-gnu.  Add comments
21028         to it, and to knetbsd*-gnu and kfreebsd*-gnu.  Remove the '*' from
21029         after the 'gnu' in these cases.  This fixes some bugs in the
21030         previous change, and is based on suggestions by Robert Millan.
21031
21032 2003-10-29  Paul Eggert  <eggert@twinsun.com>
21033
21034         * lib/xalloc.h (xalloc_oversized): Now a macro, not a function,
21035         so that it works even if SIZE_MAX < N.  Do not include <stdbool.h>;
21036         no longer needed.
21037         * lib/quotearg.c (quotearg_n_options): Use it.
21038         * lib/group-member.c: Include <stdbool.h>.
21039         (free_group_info): Arg is now const *; don't free arg.
21040         (get_group_info): Now returns bool and accepts struct group_info *,
21041         rather than returning a malloc'ed struct group_info *.
21042         All uses changed.  Check for overflow in internal size calculation.
21043
21044         * lib/getusershell.c (readname): Simplify the code by using x2nrealloc
21045         rather than xmalloc/xrealloc.
21046         * lib/linebuffer.c (initbuffer, readlinebuffer): Simplify the code by
21047         using x2realloc rather than xmalloc/xrealloc.  Also, fix a C
21048         conformance bug: the old code used a pointer after freeing the
21049         storage that it addressed.
21050         * lib/hash.c (hash_initialize): Simplify the code by using
21051         xalloc_oversized rather than doing it by hand.
21052         * lib/getgroups.c (getgroups): Don't use xrealloc, since we don't need
21053         the buffer preserved.  Use free and xmalloc instead.
21054         * lib/quotearg.c (quotearg_n_options): Likewise.
21055         Use a simpler test for size overflow.  Don't use xalloc_oversized
21056         because unsigned int might be wider than size_t (!); this suggests
21057         that we should switch from unsigned int to size_t for slot numbers.
21058
21059 2003-10-28  Paul Eggert  <eggert@twinsun.com>
21060
21061         * m4/host-os.m4 (UTILS_HOST_OS): Identify GNU/KFreeBSD and
21062         GNU/KNetBSD.  These implementations use glibc atop the FreeBSD and
21063         NetBSD kernels.  Requested by Richard Stallman.
21064
21065 2003-10-27  Paul Eggert  <eggert@twinsun.com>
21066
21067         * lib/exclude.c (new_exclude): Use xzalloc rather than xmalloc
21068         to allocate the returned structure.  Do not allocate a subarray,
21069         as x2nrealloc will do that.
21070         (add_exclude): Use x2nrealloc to reallocate ex->exclude,
21071         instead of xnrealloc.
21072         (add_exclude_file): Use x2realloc instead of malloc + xnrealloc.
21073
21074 2003-10-27  Bruno Haible  <bruno@clisp.org>
21075
21076         * lib/stdbool_.h: Better support for BeOS.
21077
21078 2003-10-26  Paul Eggert  <eggert@twinsun.com>
21079
21080         * m4/xalloc.m4 (gl_XALLOC): Requore AC_C_INLINE, since xalloc.h
21081         now uses inline.
21082
21083 2003-10-26  Paul Eggert  <eggert@twinsun.com>
21084
21085         * lib/xalloc.h (xalloc_oversized): New static inline function, for
21086         callers that want to do their own size-overflow checking.  Include
21087         <stdbool.h>, since xalloc_oversized returns bool.
21088         * lib/xalloc.c (array_size_overflow): Remove.  All callers changed
21089         to use xalloc_oversized.
21090
21091         Add two functions x2realloc, x2nrealloc, for programs that grow
21092         arrays dynamically by doubling their sizes.
21093         * lib/xalloc.h (x2realloc, x2nrealloc): New decls.
21094         * lib/xmalloc.c (x2nrealloc_inline, x2nrealloc, x2realloc):
21095         New functions.
21096
21097         Port to C99 semantics for 'inline' of external functions.
21098         Bug reported by Bruno Haible.
21099         * lib/xmalloc.c (xnmalloc_inline): New static inline function,
21100         with the old contents of xnmalloc.
21101         (xnmalloc, xmalloc): Use it.
21102         (xnrealloc_inline): New static inline function,
21103         with the old contents of xnrealloc.
21104         (xnrealloc, xrealloc): Use it.
21105
21106         * lib/alloc.c (alloca): xmalloc cannot return NULL, so don't test for
21107         that.
21108
21109 2003-10-26  Karl Berry  <karl@gnu.org>
21110
21111         * config/srclist.txt (COPYING.DOC): no longer available from
21112         /gd/gnuorg; don't know where the ultimate source is.
21113
21114 2003-10-25  Paul Eggert  <eggert@twinsun.com>
21115
21116         Fix several address-calculation bugs in the hash modules,
21117         plus some minor code cleanup.
21118
21119         * lib/hash.h: Include <stdbool.h>, for bool.
21120         * lib/hash.c: Don't include <stdbool.h>, since hash.h does it now.
21121         * lib/hash.h (Hash_hasher, hash_get_n_buckets, hash_get_n_buckets_used,
21122         hash_get_n_entries, hash_get_max_bucket_length,
21123         hash_get_entries, hash_do_for_each, hash_string, hash_initialize,
21124         hash_rehash): Use size_t rather than unsigned.
21125         * lib/hash.c (struct hash_table, hash_get_n_buckets,
21126         hash_get_n_buckets_used, hash_get_n_entries,
21127         hash_get_max_bucket_length, hash_table_ok, hash_print_statistics,
21128         hash_get_entries, hash_do_for_each, hash_string, is_prime,
21129         next_prime, hash_initialize, hash_rehash, hash_delete, hash_print):
21130         Likewise.
21131         (SIZE_MAX): Define if not defined.
21132         (hash_get_max_bucket_length, hash_table_ok, hash_lookup,
21133         hash_get_first, hash_get_next, hash_get_entries, hash_do_for_each,
21134         hash_print):
21135         Use const * when possible.
21136         (hash_string): Use (unsigned char) *P rather than *(unsigned char *) P.
21137         (check_tuning): Fix bug: if tuning parameters were very close to
21138         0 or 1, rounding errors could have caused subscript violations.
21139         (hash_initialize, allocate_entry, hash_print): Remove unnecessary cast.
21140         (hash_initialize): Add 'fail:' label
21141         to free table and return NULL, and use it to simplify code.
21142         Use calloc rather than clearing the storage ourself.
21143         (hash_initialize, hash_rehash): Check for arithmetic overflow in
21144         buffer size calculations.
21145         * lib/hash-pjw.h (hash_pjw): Use size_t, not unsigned.
21146         Include <stddef.h>, for size_t.
21147         * lib/hash-pjw.c (hash_pjw): Likewise.
21148         Switch to method described by Bruno Haible.
21149         Include <limits.h>, for CHAR_BIT.
21150         (SIZE_BITS): New macro.
21151
21152 2003-10-23  Paul Eggert  <eggert@twinsun.com>
21153
21154         * m4/getline.m4 (AM_FUNC_GETLINE):
21155         Don't include getndelim2.o twice into LIBOBJS; this breaks on some
21156         hosts.  Problem reported by Derek Robert Price in
21157         <http://mail.gnu.org/archive/html/bug-gnulib/2003-10/msg00092.html>.
21158         This patch can be withdrawn after Autoconf 2.58 is required for gnulib.
21159         * m4/getndelim2.m4 (gl_GETNDELIM2): Likewise.
21160
21161 2003-10-21  Paul Eggert  <eggert@twinsun.com>
21162
21163         * lib/getndelim2.c (getndelim2): When size calculation overflows,
21164         ceiling the allocation at NMAX bytes rather than silently
21165         discarding input bytes before NMAX is reached.  This makes
21166         a difference only if NMAX exceeds SIZE_MAX / 2.
21167
21168         * lib/obstack.c: Merge from glibc.
21169         [defined _LIBC]: Include <obstack.h>, not "obstack.h".
21170         Add libc_hidden_def (_obstack_newchunk).
21171         (_obstack_free) [! defined _LIBC]: Remove.
21172         [defined _LIBC]: Make a strong alias from obstack_free, rather than
21173         a clone of the function body.
21174         (fputs) [defined _LIBC && defined USE_IN_LIBIO]: Remove.
21175         [defined _LIBC && !defined USE_IN_LIBIO]: Include <libio/iolibio.h>.
21176
21177         * lib/obstack.h: Indenting cleanup, to make it easier to merge with
21178         glibc.
21179         (obstack_grow, obstack_grow0): Remove unnecessary parentheses around
21180         arg to memcpy.
21181
21182         * lib/obstack.h (obstack_1grow_fast): Properly parenthesize arg.
21183         (obstack_ptr_grow_fast, obstack_int_grow_fast):
21184         Don't use lvalue casts, as GCC plans to remove support for them
21185         in GCC 3.5.  Reported by Joseph S. Myers.  This bug
21186         was also present in the non-GCC version, indicating that this
21187         code had always been buggy and had never been widely used.
21188         (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
21189         Use the fast variant of each macro, rather than copying the
21190         definiens of the fast variant; that way, we'll be more likely to
21191         catch future bugs in the fast variants.
21192
21193 2003-10-20  Bruno Haible  <bruno@clisp.org>
21194
21195         * modules/wait-process: New file.
21196         * MODULES.html.sh (func_all_modules): Add wait-process.
21197
21198 2003-10-20  Bruno Haible  <bruno@clisp.org>
21199
21200         * m4/wait-process.m4: New file.
21201
21202 2003-10-20  Bruno Haible  <bruno@clisp.org>
21203
21204         * lib/wait-process.h: New file, from GNU gettext.
21205         * lib/wait-process.c: New file, from GNU gettext.
21206
21207 2003-10-19  Jim Meyering  <jim@meyering.net>
21208
21209         * lib/vasnprintf.c (vasnprintf): Work around losing snprintf on
21210         HPUX 10.20.
21211
21212 2003-10-18  Karl Berry  <karl@gnu.org>
21213
21214         * config/config.guess: update from config.
21215
21216 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21217
21218         * lib/getgroups.c: Include <errno.h>, <stdlib.h>.
21219         (getgroups): First arg is int, not size_t.
21220         Don't let 'free' mangle errno.
21221
21222 2003-10-16  Paul Eggert  <eggert@twinsun.com>
21223
21224         * README: Mention that gnulib assumes that (foo *) NULL + 0 == NULL.
21225
21226 2003-10-16  Karl Berry  <karl@gnu.org>
21227
21228         * config/config.{guess,sub}: update from config.
21229
21230 2003-10-16  Jim Meyering  <jim@meyering.net>
21231
21232         * lib/xmalloc.c: Include <string.h>, for declarations of memset and
21233         memcpy.
21234
21235 2003-10-15  Paul Eggert  <eggert@twinsun.com>
21236
21237         * lib/exclude.c: Do not include <inttypes.h> or <stdint.h>.
21238         (SIZE_MAX): Remove.
21239         (new_exclude, add_exclude_file): Initial size no longer needs to
21240         be a power of 2.
21241         (add_exclude, add_exclude_file): Use xnrealloc instead of rolling
21242         our own address arithmetic overflow checking.
21243
21244         * lib/fnmatch.c (SIZE_MAX): Define if standard headers don't.
21245         (fnmatch): Do not alloca more than 2000 wide characters;
21246         instead, use malloc for large buffers.
21247         Check for address arithmetic overflow, and return -1
21248         with errno set to ENOMEM in that case.
21249         * lib/fnmatch_loop.c (ALLOCA_LIMIT): New macro.
21250         (NEW_PATTERN): Do not alloca more than 8000 bytes;
21251         instead, return -1.  Check for address arithmetic overflow.
21252
21253 2003-10-14  Paul Eggert  <eggert@twinsun.com>
21254
21255         Handle invalid suffixes and overflow independently, so that
21256         callers can treat them independently as needed.  Fix some bugs in
21257         suffix handling, e.g., "100k@" was not diagnosed as an invalid
21258         suffix for a human-readable blocksize.  The major caller-visible
21259         change is the addition of a new
21260         LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW enum value, indicating
21261         that both overflow and suffix chars were found.
21262
21263         * lib/human.c (humblock): Don't check separately for invalid suffix
21264         char; that is xstrtoumax's job (now that its bug is fixed).
21265         * lib/xstrtoimax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM) [defined
21266         INTMAX_MAX]: New macros.
21267         * lib/xstrtol.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM, TYPE_MINIMUM,
21268         TYPE_MAXIMUM): New macros.
21269         (bkm_scale, bkm_scale_by_power): Return strtol_error, not int.
21270         (bkm_scale, bkm_scale_by_power, __xstrtol): Return maximal values
21271         if overflow occurs, as it's what __strtol does and it's more useful
21272         in practice.
21273         (__xstrtol): If __strtol reports some error other than ERANGE,
21274         reflect it to the caller as LONGINT_INVALID.  If it reports
21275         ERANGE, continue the rest of parsing, and report LONGINT_OVERFLOW
21276         | LONGINT_INVALID_SUFFIX_CHAR if both errors occur.
21277         * lib/xstrtol.h (LONGINT_INVALID_SUFFIX_CHAR_WITH_OVERFLOW): New enum
21278         value.
21279         (_STRTOL_ERROR): Handle it.  Abort when given unknown error codes.
21280         * lib/xstrtoul.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM): New macros.
21281         * lib/xstrtoumax.c (STRTOL_T_MINIMUM, STRTOL_T_MAXIMUM)
21282         [defined UINTMAX_MAX]: New macros.
21283
21284 2003-10-14  Bruno Haible  <bruno@clisp.org>
21285
21286         * modules/fatal-signal: Add m4/sig_atomic_t.m4 to file list.
21287
21288 2003-10-14  Bruno Haible  <bruno@clisp.org>
21289
21290         * m4/sig_atomic_t: New file, from GNU gettext.
21291         * m4/fatal-signal.m4 (gl_FATAL_SIGNAL): Require gt_TYPE_SIG_ATOMIC_T.
21292
21293 2003-10-14  Bruno Haible  <bruno@clisp.org>
21294
21295         * lib/fatal-signal.h: Improved comments. Suggested by Paul Eggert.
21296         * lib/fatal-signal.c: Use sig_atomic_t. Suggested by Paul Eggert.
21297         Also use volatile where needed.
21298
21299 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21300
21301         * modules/xalloc: Do not depend on 'exit'.  Depend on 'stdbool'.
21302         Change maintainer from Bruno Haible to 'all'.
21303
21304 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21305
21306         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Require AC_C_INLINE.
21307
21308 2003-10-12  Paul Eggert  <eggert@twinsun.com>
21309
21310         * lib/xalloc.h (xnmalloc, xzalloc, xnrealloc, xclone): New decls.
21311         (XMALLOC, XCALLOC, XREALLOC, XFREE, CCLONE, CLONE): Deprecate,
21312         and define in terms of the other primitives.
21313         * lib/xmalloc.c: Include stdbool.h; do not include exit.h.
21314         (SIZE_MAX): Define if not already defined.
21315         (array_size_overflow): New function.
21316         (xalloc_die): Abort instead of exiting if 'error' returns.
21317         (xnmalloc, xnrealloc, xzalloc, xclone): New functions.
21318         (xmalloc, xrealloc): Use them.
21319         (xcalloc): Check for address arithmetic overflow.
21320         * lib/xstrdup.c (xstrdup): Use xclone, since memcpy should be
21321         a bit faster than strcpy.
21322
21323 2003-10-10  Simon Josefsson  <jas@extundo.com>
21324
21325         * modules/argp (Depends-on): Add restrict and strcase.
21326
21327 2003-10-10  Simon Josefsson  <jas@extundo.com>
21328
21329         * m4/argp.m4: Add AC_C_INLINE.
21330
21331 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21332
21333         Merge getpass from libc, plus a few fixes.
21334
21335         * lib/getpass.c (HAVE_STDIO_EXT) [_LIBC]: Define to 1.
21336         Include <stdbool.h>.
21337         Include <stdio_ext.h> if HAVE_STDIO_H, otherwise define
21338         __fsetlocking to empty.
21339         [_LIBC]: Do not include "getline.h" or "unlocked-io.h", but
21340         do include <bits/libc-lock.h>.
21341         Do not include <fcntl.h>; not needed.
21342         [_LIBC]: Include <wchar.h>.
21343         (NOTCANCEL_MODE): New macro.
21344         (flockfile, funlockfile) [_LIBC]: New macros.
21345         (__libc_cleanup_push, __libc_cleanup_pop, __getline, __tcgetattr)
21346         [!_LIBC]: New macros.
21347         (call_fclose): New function.
21348         (getpass): Use it.  Save tty stream separately; this simplifies the
21349         code and makes it more reliable if stdin happens to equal stdout.
21350         Invoke __fsetlocking on tty.
21351         Handle thread cancellation if needed.
21352         Namespace cleanup (use __tcgetattr, __getline).
21353         Use bool for Booleans.
21354         [USE_IN_LIBIO]: Handle wide streams.
21355         [!_LIBC]: Unconditionally do the fseek, since we don't know what
21356         stream might go where.
21357
21358         * lib/unlocked-io.h: Include <stdio.h>, so that the caller
21359         doesn't have to include <stdio.h> before us.
21360         (clearerr_unlocked, feof_unlocked, ferror_unlocked,
21361         fflush_unlocked, fgets_unlocked, fputc_unlocked, fputs_unlocked,
21362         fread_unlocked, fwrite_unlocked, getc_unlocked, getchar_unlocked,
21363         putc_unlocked, putchar_unlocked): Define to the unlocked counterpart
21364         if not declared, so that we can use getpass.c code from libc without
21365         rewriting it.
21366         (flockfile, ftrylockfile, funlockfile): New macros.
21367
21368 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21369
21370         * modules/getpass: Depend on stdbool.
21371
21372 2003-10-08  Paul Eggert  <eggert@twinsun.com>
21373
21374         * m4/getpass.m4 (gl_PREREQ_GETPASS): Check for stdio_ext.h.
21375
21376 2003-10-07  Karl Berry  <karl@gnu.org>
21377
21378         * config/config.{guess,sub}: update from config.
21379
21380 2003-10-06  Jim Meyering  <jim@meyering.net>
21381             Bruno Haible  <bruno@clisp.org>
21382
21383         This lets translators provide better translations for the
21384         "Written by ..." part of --version output.
21385         * lib/version-etc.h: Include stdarg.h.
21386         (version_etc_copyright): Declare as readonly.
21387         (version_etc): Make this function variadic with a NULL-terminated list
21388         of author name strings.
21389         (version_etc_va): New declaration.
21390         * lib/version-etc.c: Include stdarg.h, stdlib.h.
21391         (version_etc_copyright): Declare as readonly.
21392         (version_etc_va): New function. Provide a different translatable string
21393         for each possible number of authors < 10. Abbreviate when there are 10
21394         authors or more.
21395         (version_etc): Make this function variadic. Call version_etc_va.
21396         Suggestion from Gary V. Vaughan.
21397
21398         * lib/long-options.h (parse_long_options): Change prototype: the
21399         authors string is moved to the end and becomes variadic.
21400         * lib/long-options.c: Include stdarg.h.
21401         (parse_long_options): Make this function variadic, too.
21402         Call version_etc_va, not version_etc.
21403
21404 2003-10-06  Bruno Haible  <bruno@clisp.org>
21405
21406         * modules/version-etc-2: Remove file.
21407         * MODULES.html.sh (func_all_modules): Remove version-etc-2.
21408
21409 2003-10-06  Bruno Haible  <bruno@clisp.org>
21410
21411         * modules/fatal-signal: New file.
21412         * MODULES.html.sh (func_all_modules): Add fatal-signal.
21413
21414 2003-10-06  Bruno Haible  <bruno@clisp.org>
21415
21416         * m4/fatal-signal.m4: New file.
21417         * m4/signalblocking.m4: New file, from GNU gettext.
21418
21419 2003-10-06  Bruno Haible  <bruno@clisp.org>
21420
21421         * lib/version-etc-2.h: Remove file.
21422         * lib/version-etc-2.c: Remove file.
21423
21424 2003-10-06  Bruno Haible  <bruno@clisp.org>
21425
21426         * lib/fatal-signal.h: New file, from GNU gettext.
21427         * lib/fatal-signal.c: New file, from GNU gettext.
21428
21429 2003-10-05  Paul Eggert  <eggert@twinsun.com>
21430
21431         * README: Rework advice for preventing empty .o files.
21432         Don't recommend ELIDE constructs.  Recommend <stddef.h>,
21433         not <sys/types.h>.
21434
21435 2003-10-04  Karl Berry  <karl@gnu.org>
21436
21437         * lib/argp*: update from libc.
21438
21439 2003-10-04  Karl Berry  <karl@gnu.org>
21440
21441         * config/config.{guess,sub}: update from config.
21442
21443 2003-10-02  Bruno Haible  <bruno@clisp.org>
21444
21445         * modules/lchown (Include): Add lchown.h.
21446         * modules/time_r (Include): Use "..." syntax.
21447         * modules/xgetdomainname (Include): Add xgetdomainname.h.
21448
21449 2003-10-01  Simon Josefsson  <jas@extundo.com>
21450
21451         * MODULES.html.sh (func_all_modules): Move gethostname from section
21452         'based on' to section 'lacking' POSIX:2001.
21453
21454 2003-10-01  Larry Jones  <lawrence.jones@eds.com>
21455
21456         * lib/getpass.c (getpass): Use a no-op fseek when switching from input
21457         to output mode on the same stream.
21458
21459 2003-09-29  Paul Eggert  <eggert@twinsun.com>
21460
21461         * lib/strftime.c (tm_diff) [! HAVE_TM_GMTOFF]:
21462         Fix arg typo in previous patch.
21463
21464 2003-09-28  Jim Meyering  <jim@meyering.net>
21465
21466         * lib/error.c: Correct cpp indentation.
21467
21468 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21469
21470         * modules/free: New file.
21471
21472 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21473
21474         * m4/free.m4: New file.
21475
21476 2003-09-27  Paul Eggert  <eggert@twinsun.com>
21477
21478         * lib/minmax.h (MIN, MAX)
21479         [__STDC__ && defined __GNUC__ && __GNUC__ >= 2]:
21480         Omit the special code that used __typeof__, since we worry that
21481         it could be more trouble than it's worth.  See:
21482         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00090.html
21483         http://mail.gnu.org/archive/html/bug-gnulib/2003-01/msg00095.html
21484
21485         * lib/free.c: New file.
21486
21487 2003-09-27  Oskar Liljeblad  <oskar@osk.mine.nu>
21488
21489         Trivial fixes to Makefile.am parts of module listings.
21490         * modules/strstr: Append strstr.h to lib_SOURCES.
21491         * modules/strcase: Likewise, for strcase.h.
21492
21493 2003-09-27  Karl Berry  <karl@gnu.org>
21494
21495         * config/mkinstalldirs: update from automake.
21496
21497 2003-09-26  Paul Eggert  <eggert@twinsun.com>
21498
21499         * lib/error.c (SIZE_MAX) [!defined SIZE_MAX]: Define.
21500         (error_tail): Do not loop, reallocating temporary buffer, since
21501         the output cannot contain more wide characters than the input
21502         contains bytes, the size must be big enough already.  This avoids
21503         one potential size overflow calculation.  Check for size overflow
21504         when calculating temporary buffer size.  Free temporary buffer
21505         when done, if it was allocated with malloc; this plugs a memory
21506         leak.  Remove casts from void * to pointers, that are no longer
21507         needed now that we're assuming C89 or better.
21508
21509         Merge error changes from glibc.
21510
21511         * lib/error.c, error.h: Update copyright notice header to match glibc.
21512         * lib/error.c [defined _LIBC]: Include <errno.h>, <bits/libc-lock.h>.
21513         (error, error_at_line) [defined _LIBC && defined __libc_ptf_call]:
21514         Disable cancellation while printing error.
21515         * lib/error.h: Prepend __ to parameter names.
21516
21517 2003-09-26  Jim Meyering  <jim@meyering.net>
21518
21519         * lib/error.c (error_tail): Move some declarations
21520         into inner scope where the local variables are used.
21521
21522 2003-09-26  Bruno Haible  <bruno@clisp.org>
21523
21524         * m4/stpncpy.m4 (gl_FUNC_STPNCPY): Add comments about the AIX
21525         stpncpy().
21526         Don't define stpncpy through config.h; it's now done through stpncpy.h.
21527
21528 2003-09-26  Bruno Haible  <bruno@clisp.org>
21529
21530         * lib/stpncpy.h (gnu_stpncpy): New declaration.
21531         (stpncpy): Define as alias for gnu_stpncpy.
21532         * lib/stpncpy.c [!_LIBC]: Define gnu_stpncpy, not stpncpy.
21533
21534 2003-09-25  Simon Josefsson  <jas@extundo.com>
21535
21536         * lib/xgetdomainname.h: New file.
21537         * lib/xgetdomainname.c: New file.
21538
21539 2003-09-25  Simon Josefsson  <jas@extundo.com>
21540             Bruno Haible  <bruno@clisp.org>
21541
21542         * modules/getdomainname: New file.
21543         * modules/xgetdomainname: New file.
21544         * MODULES.html.sh (func_all_modules): Add getdomainname,
21545         xgetdomainname.
21546
21547 2003-09-25  Simon Josefsson  <jas@extundo.com>
21548             Bruno Haible  <bruno@clisp.org>
21549
21550         * m4/getdomainname.m4: New file.
21551
21552 2003-09-25  Simon Josefsson  <jas@extundo.com>
21553             Bruno Haible  <bruno@clisp.org>
21554
21555         * lib/getdomainname.h: New file.
21556         * lib/getdomainname.c: New file.
21557
21558 2003-09-25  Karl Berry  <karl@gnu.org>
21559
21560         * lib/argp-fmtstream.c, argp-help.c: update from libc.
21561
21562 2003-09-25  Karl Berry  <karl@gnu.org>
21563
21564         * config/install-sh: update from automake.
21565
21566 2003-09-25  Bruno Haible  <bruno@clisp.org>
21567
21568         * modules/version-etc-2: New file, from modules/version-etc with
21569         modifications.
21570         * MODULES.html.sh (func_all_modules): Add version-etc-2.
21571
21572 2003-09-25  Bruno Haible  <bruno@clisp.org>
21573
21574         * lib/version-etc-2.h: New file, from version-etc.h with modifications.
21575         * lib/version-etc-2.c: New file, from version-etc.c with modifications.
21576
21577 2003-09-24  Simon Josefsson  <jas@extundo.com>
21578
21579         * modules/xgethostname: Add xgethostname.h.
21580
21581 2003-09-24  Paul Eggert  <eggert@twinsun.com>
21582
21583         * lib/linebuffer.c (freebuffer): Don't free the argument, just
21584         the buffer associated with the argument.  Bug reported by
21585         Simon Josefsson.
21586
21587 2003-09-24  Paul Eggert  <eggert@twinsun.com>
21588
21589         * README: Document assumptions that 'int' is at least 32 bits
21590         wide, that integer arithmetic is 2's complement without overflow,
21591         that there are no holes in integer values, that adding sizes of
21592         two nonoverlapping objects can't overflow, and that all-bits-zero
21593         yields scalar zero.  Fix spelling and capitalization typos.
21594
21595 2003-09-19  Karl Berry  <karl@gnu.org>
21596
21597         * lib/argp.h: update from libc.
21598
21599 2003-09-17  Paul Eggert  <eggert@twinsun.com>
21600
21601         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Call AC_BEFORE first,
21602         to avoid spurious warnings like "AC_RUN_IFELSE was called before
21603         gl_USE_SYSTEM_EXTENSIONS" from autoreconf.
21604
21605 2003-09-17  Paul Eggert  <eggert@twinsun.com>
21606
21607         * gnulib-tool: Use "test -h", not "test -L", for portability
21608         to Solaris 8 /bin/sh.  (This bug is fixed in Solaris 9.)
21609         (tags_regexp): Remove, since \| doesn't conform to POSIX.
21610         (sed_extract_prog): Issue s commands one-by-one, rather than
21611         using \| in one s command.
21612
21613 2003-09-16  Paul Eggert  <eggert@twinsun.com>
21614
21615         * lib/linebuffer.c (readlinebuffer): Return NULL immediately upon
21616         input error, instead of returning NULL the next time we are called
21617         (and therefore losing track of errno).
21618
21619 2003-09-16  Bruno Haible  <bruno@clisp.org>
21620
21621         * gnulib-tool (func_create_testdir): Warn about duplicated
21622         dependencies.
21623
21624 2003-09-15  Paul Eggert  <eggert@twinsun.com>
21625
21626         * modules/argmatch, modules/fatal, modules/obstack,
21627         modules/xalloc, modules/xgethostname: Sort dependencies by
21628         importance, not alphabetically.
21629
21630 2003-09-15  Paul Eggert  <eggert@twinsun.com>
21631
21632         * lib/getndelim2.c (getndelim2): Don't trash errno when a read
21633         fails, so that the caller gets the proper errno.
21634
21635         * lib/readutmp.c (read_utmp): Likewise.
21636         Check for fstat error.  Close stream and free storage
21637         when failing.
21638
21639 2003-09-14  Karl Berry  <karl@gnu.org>
21640
21641         * config/srclist.txt (strdup.c): disable for c89 changes.
21642
21643 2003-09-14  Jim Meyering  <jim@meyering.net>
21644
21645         * lib/getloadavg.c: Correct cpp indentation.
21646         * lib/strdup.c: Likewise.
21647         * lib/vasnprintf.c: Likewise.
21648
21649 2003-09-14  Bruno Haible  <bruno@clisp.org>
21650
21651         * modules/fwriteerror: New file.
21652         * MODULES.html.sh (func_all_modules): Add fwriteerror.
21653
21654 2003-09-14  Bruno Haible  <bruno@clisp.org>
21655
21656         * lib/fwriteerror.h: New file.
21657         * lib/fwriteerror.c: New file.
21658
21659 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21660
21661         * modules/argmatch, modules/exitfail, modules/fatal, modules/obstack,
21662         modules/xgethostname, modules/xalloc: Depend on exit.
21663
21664 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21665
21666         * m4/error.m4: Require AC_FUNC_STRERROR_R rather than invoking it.
21667
21668         * m4/extensions.m4 (gl_USE_SYSTEM_EXTENSIONS): Require AC_AIX
21669         and AC_MINIX, too, so that their extensions are available.
21670
21671         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Remove.  All uses removed.
21672         This macro has been superseded by gl_BACKUPFILE.
21673
21674         More patches to assume C89 or better.
21675
21676         * m4/error.m4 (gl_ERROR): Don't check for vprintf.
21677
21678         * m4/check-decl.m4 (jm_CHECK_DECLS): Include <string.h>, <stdlib.h>
21679         unconditionally.
21680         * m4/closeout.m4 (gl_CLOSEOUT): Don't check for stdlib.h.
21681         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER):
21682         Include <string.h>, <stdlib.h> unconditionally.
21683         * m4/lstat.m4 (gl_PREREQ_LSTAT): Don't check for stdlib.h, free.
21684         * m4/readdir.m4 (GL_FUNC_READDIR): Don't check for string.h.
21685         * m4/readutmp.m4 (gl_PREREQ_READUTMP): Don't check for standard C
21686         headers or for string.h.
21687         * m4/strtoumax.m4 (gl_PREREQ_STRTOUMAX): Don't check for stdlib.h
21688         or strtoul.
21689
21690         * m4/mkstemp.m4 (jm_PREREQ_TEMPNAME): Do not require standard C
21691         headers.
21692         * m4/strdup.m4 (gl_PREREQ_STRDUP): Likewise.
21693         * m4/userspec.m4 (gl_USERSPEC): Likewise.
21694         * m4/xalloc.m4 (gl_PREREQ_XMALLOC): Likewise.
21695         * m4/xstrtod.m4 (gl_XSTRTOD): Likewise.
21696         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
21697         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't check for limits.h,
21698         memcpy, memset.
21699         (jm_FUNC_GNU_STRFTIME): Don't require standard C headers.
21700         * m4/strtod.m4 (gl_FUNC_STRTOD): Do not check for float.h.
21701         * m4/strtoimax.m4 (gl_PREREQ_STRTOIMAX): Do not check for stdlib.h,
21702         strtol.
21703         * m4/strtol.m4 (gl_FUNC_STRTOL): Do not check for limits.h.
21704         * m4/userspec.m4 (gl_USERSPEC): Do not check for string.h.
21705         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Do not check for string.h, strtol,
21706         strtoul.
21707
21708 2003-09-12  Paul Eggert  <eggert@twinsun.com>
21709
21710         * lib/argmatch.c, fatal.c, xgethostname.c, xmalloc.c: Include exit.h.
21711         * lib/obstack.c [!defined _LIBC]: Likewise.
21712         * lib/argmatch.c (EXIT_FAILURE): Remove; now done by exit.h
21713         * lib/exitfail.c, fatal.c, xgethostname.c, xmalloc.c: Likewise.
21714         * lib/exitfail.c: Don't include stdlib.h; no longer needed.
21715
21716         More changes to assume C89 or better.
21717
21718         * lib/error.c (error_tail): Assume vprintf.
21719
21720         * lib/argmatch.c (getenv): Remove decl.
21721         * lib/progreloc.c (get_full_program_name): Define via prototype.
21722         * lib/setenv.c (clearenv): Likewise.
21723         * lib/stpncpy.c: Do not include <string.h> or <sys/types.h>; not
21724         needed.
21725         * lib/strdup.c: Include <stdlib.h>, <string.h> unconditionally.
21726         (malloc, memcpy): Remove decls.
21727         * lib/strftime.c (HAVE_LIMITS_H, STDC_HEADERS) [defined _LIBC]: Remove.
21728         (HAVE_MEMCPY) [defined emacs && !defined HAVE_BCOPY]: Remove.
21729         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
21730         (memcpy): Remove macro.
21731         (MEMCPY) [!defined COMPILE_WIDE]: Define to memcpy unconditionally.
21732         (__P): Remove.  All uses removed.
21733         (PTR): Remove.  All uses changed to void *.
21734         (CHAR_BIT, NULL): Remove.
21735         (spaces, zeros, memset_space, memset_zero)
21736         [!defined memset && !defined HAVE_MEMSET && !defined _LIBC]:
21737         Remove.
21738         (LOCALE_PARAM, LOCALE_PARAM_DECL): Remove.
21739         (memcpy_lowcase, memcpy_uppcase, tm_diff, iso_week_days):
21740         Define with prototype.
21741         Remove now-unnecessary prototype decl.
21742         (extra_args_spec): Assume ANSI C.  All uses changed.
21743         (extra_args_spec_iso): Remove.
21744         (my_strftime, emacs_strftimeu): Define via prototype.
21745         * lib/strtod.c: Include <float.h>, <stdlib.h>, <string.h>
21746         unconditionally.
21747         (DBL_MAX, DBL_MIN, HUGE_VAL, NULL): Remove decls.
21748         * lib/strtoimax.c: Include <stdlib.h> unconditionally.
21749         (strtoul, strtol): Remove decls.
21750         * lib/strtol.c (STDC_HEADERS, HAVE_LIMITS_H, NULL, ULONG_MAX,
21751         LONG_MAX): Remove.
21752         Include <limits.h>, <stddef.h>, <stdlib.h>, <string.h> unconditionally.
21753         (LOCALE_PARAM_DECL): Remove.  All uses changed to LOCALE_PARAM_PROTO.
21754         (LOCALE_PARAM_PROTO): New macro.
21755         (INTERNAL, INTERNAL1, WEAKNAME): Assume ANSI C, not K&R.
21756         (INTERNAL (strtol), strtol): Define with a prototype.
21757         (PARAMS): Remove.  All uses removed.
21758         * lib/tempname.c: Include <string.h> unconditionally.
21759         * lib/userspec.c: Include <stdlib.h>, <string.h> unconditionally.
21760         * lib/xgethostname.c (main): Define with a prototype.
21761         * lib/xmalloc.c: Include "xalloc.h" first, to check interface.
21762         Include <stdlib.h> unconditionally.
21763         (calloc, malloc, realloc, free): Remove decls.
21764         * lib/xstrtod.c: Include "xstrtod.h" first, to check interface.
21765         Include <stdlib.h> unconditionally.  Sort include file names.
21766         (strtod): Remove.
21767         (xstrtod): Define with a prototype.
21768         * lib/xstrtol.c: Include <stdlib.h>, <string.h> unconditionally.
21769         (strtol, strtoul): Remove decls.
21770
21771 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21772
21773         More patches to assume C89 or better.
21774         * m4/strndup.m4 (gl_PREREQ_STRNDUP): Remove STDC_HEADERS check.
21775         * m4/strnlen.m4 (gl_PREREQ_STRNLEN): Don't check for memory.h,
21776         string.h, memchr, STDC_HEADERS.
21777
21778 2003-09-11  Paul Eggert  <eggert@twinsun.com>
21779
21780         * lib/strndup.c: Don't include <stdio.h>, <sys/types.h>.
21781         Include <stdlib.h>, <string.h> unconditionally.
21782         Remove now-unnecessary cast to char *.
21783         * lib/strnlen.c: Include <string.h> unconditionally.
21784         * lib/yesno.c (yesno): Define with a prototype.
21785
21786 2003-09-11  Bruno Haible  <bruno@clisp.org>
21787
21788         * config/srclist.txt (setenv.c, unsetenv.c): Disable for the moment.
21789
21790 2003-09-10  Jim Meyering  <jim@meyering.net>
21791
21792         * lib/error.c: Correct indentation of cpp directives.
21793
21794 2003-09-10  Bruno Haible  <bruno@clisp.org>
21795
21796         * m4/strcspn.m4 (gl_PREREQ_STRCSPN): Remove <string.h> check.
21797         * m4/strpbrk.m4 (gl_PREREQ_STRPBRK): Remove <string.h> check.
21798         * m4/strstr.m4 (gl_PREREQ_STRSTR): Remove <string.h> check.
21799         * m4/unicodeio.m4 (gl_UNICODEIO): Remove <string.h> check.
21800         * m4/setenv.m4 (gl_PREREQ_SETENV, gl_PREREQ_UNSETENV): Remove
21801         <stdlib.h> and <string.h> checks.
21802         * m4/xreadlink.m4 (gl_XREADLINK): Remove <stdlib.h> check.
21803         * m4/yesno.m4 (gl_YESNO): Remove <stdlib.h> check.
21804
21805 2003-09-10  Bruno Haible  <bruno@clisp.org>
21806
21807         * lib/strcspn.c: Include <string.h> unconditionally.
21808         * lib/strpbrk.c: Include <string.h> unconditionally.
21809         * lib/strstr.c: Include <string.h> unconditionally.
21810         * lib/unicodeio.c: Include <string.h> unconditionally.
21811         * lib/setenv.c: Include <stdlib.h> and <string.h> unconditionally.
21812         * lib/unsetenv.c: Likewise.
21813         * lib/xreadlink.c: Include <stdlib.h> unconditionally.
21814         * lib/yesno.c: Include <stdlib.h> unconditionally.
21815         (rpmatch): Add prototype.
21816
21817 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21818
21819         More patches to assume C89 or better.
21820         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Don't check for stdlib.h.
21821         * m4/getopt.m4 (gl_GETOPT): Don't check for string.h.
21822         * m4/getugroups.m4 (gl_GETUGROUPS): Do not check for standard C headers
21823         or for string.h.
21824         * m4/getusershell.m4 (gl_PREREQ_GETUSERSHELL): Do not check for
21825         stdlib.h.
21826         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): Do not require standard
21827         C headers.
21828         * m4/hard-locale.m4 (gl_HARD_LOCALE): Do not check for stdlib.h,
21829         string.h.
21830         * m4/hash.m4 (gl_HASH): Do not check for stdlib.h, malloc, free.
21831         * m4/human.m4 (gl_HUMAN): Do not check for stdlib.h, string.h, getenv.
21832         * m4/idcache.m4 (gl_IDCACHE): Do not check for standard C headers,
21833         or for string.h.
21834         * m4/long-options.m4 (gl_LONG_OPTIONS): Do not check for stdlib.h.
21835         * m4/makepath.m4 (gl_MAKEPATH): Do not check for string.h or standard
21836         C headers.
21837         * m4/md5.m4 (gl_MD5): Don't check for limits.h, standard C headers,
21838         memcpy.
21839         * m4/sha.m4 (gl_SHA): Don't check for standard Cheaders, memcpy.
21840         * m4/memchr.m4 (jm_PREREQ_MEMCHR): Don't check for limits.h, stdlib.h.
21841         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): Don't check for string.h.
21842         * m4/memcoll.m4 (gl_MEMCOLL): Likewise.
21843         * m4/memrchr.c (gl_PREREQ_MEMRCHR): Don't check for limits.h.
21844         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): Don't check for stdlib.h,
21845         string.h, free.
21846         * m4/mktime.m4 (gl_PREREQ_MKTIME): Don't check for standard C headers.
21847         * m4/modechange.m4 (gl_MODECHANGE): Don't check for standard C headers.
21848         * m4/mountlist.m4 (gl_PREREQ_MOUNTLIST_EXTRA): Don't check for standard
21849         C headers, or for string.h.
21850         * m4/obstack.m4 (gl_OBSTACK): Don't check for stddefe.h, string.h.
21851         (gl_PREREQ_OBSTACK): Don't check for stdlib.h.
21852         * m4/path-concat.m4 (gl_PATH_CONCAT): Don't check for standard C
21853         headers, memory.h, stdlib.h, string.h, strings.h.
21854         * m4/posixtm.m4 (gl_POSIXTM): Don't check for stdlib.h, string.h.
21855         * m4/posixver.m4 (gl_POSIXVER): Don't check for getenv.
21856         * m4/putenv.m4 (gl_PREREQ_PUTENV): Don't check for string.h, memcpy,
21857         strchr.
21858         * m4/readtokens.m4 (gl_READTOKENS): Don't check for standard C
21859         headers, memory.h, string.h.
21860         * m4/regex.m4 (jm_PREREQ_REGEX): Do not check for limits.h, string.h.
21861         * m4/rename.m4 (gl_PREREQ_RENAME): Do not check for stdlib.h, string.h,
21862         free.
21863         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Don't check for standard C
21864         headers.
21865         * m4/same.m4 (gl_SAME): Don't check for stdlib.h, string.h, free.
21866         * m4/save-cwd.m4 (gl_SAVE_CWD): Don't check for standard C headers.
21867         * m4/savedir.m4 (gl_SAVEDIR): Don't check for standard C headers.
21868         * m4/strchrnul.m4 (gl_PREREQ_STRCHRNUL): Don't check for string.h.
21869         * m4/xgetcwd.m4 (gl_XGETCWD): Don't check for stdlib.h.
21870
21871 2003-09-09  Paul Eggert  <eggert@twinsun.com>
21872
21873         More K&R removal.
21874
21875         * lib/acosl.c (main): Use a prototype.
21876         * lib/asinl.c, cosl.c, expl.c, frexpl.c, ldexpl.c, sinl.c,
21877         tanl.c: Likewise.
21878
21879         * lib/getloadavg.c (getloadavg, main): Define via prototypes.
21880
21881         * lib/getopt.h (struct option.name): Assume C89, and use 'const'.
21882         (getopt, etopt_long, getopt_long_only, _getopt_internal)
21883         [defined __GNU_LIBRARY__]: Assume C89, so we can always declare
21884         with a prototype.
21885         * lib/getopt.c (const): Remove macro.
21886         Include <string.h> unconditionally.
21887         (my_index): Remove; all uses changed to strchr.
21888         (strlen): Remove decl.
21889         (exchange): Remove forward decl; no longer needed.
21890         (exchange, _getopt_initialize, _getopt_internal, getopt, main):
21891         Define with prototype.
21892         * lib/getopt1.c (const): Remove macro.
21893         (getopt_long, getopt_long_only, main): Define with prototype.
21894
21895         * lib/getugroups.c: Include <string.h> unconditionally.
21896
21897         * lib/getusershell.c: Include <stdlib.h> unconditionally.
21898         (getusershell, setusershell, endusershell, readname, main):
21899         Define with prototypes.
21900
21901         * lib/group-member.c: Include group-member.h first.
21902         Include <stdlib.h> unconditionally.
21903
21904         * lib/hard-locale.c: Include hard-locale.h first.
21905         Include <stdlib.h>, <string.h> unconditionally.
21906
21907         * lib/hash.c (free, malloc): Remove decls.
21908         Include <stdlib.h> unconditionally.
21909
21910         * lib/human.c: Include <stdlib.h>, <string.h> unconditionally.
21911         (getenv): Do not declare.
21912
21913         * lib/idcache.c: Include <string.h> unconditionally.
21914
21915         * lib/long-options.c: Include long-options.h first, to test interface.
21916         Include <stdlib.h> unconditionally.
21917
21918         * lib/makepath.c: Include makepath.h first, to test interface.
21919         Include <stdlib.h> and <string.h> unconditionally.
21920
21921         * lib/linebuffer.c: Include <stdlib.h>.
21922         (free): Remove decl.
21923
21924         * lib/malloc.c: Include <stdlib.h>, for malloc; don't bother with
21925         stddef.h. rpl_malloc returns void *, not char *.
21926         * lib/realloc.c (rpl_realloc): Likewise.  Also, define with a
21927         prototype.
21928
21929         * lib/md5.h: Include <limits.h> unconditionally.
21930         (UINT_MAX_32_BITS): Don't worry about non-__STDC__ case.
21931         (__P): Remove; all uses removed.
21932         * lib/md5.c: Include "md5.h" first.
21933         (md5_init_ctx, md5_read_ctx, md5_finish_ctx, md5_stream,
21934         md5_buffer, md5_process_bytes, md5_process_block):
21935         Define with prototypes.
21936         * lib/sha.h (__P): Remove all uses.  (It wasn't defined??)
21937         * lib/sha.c: Include "sha.h" first.
21938         Include <stdlib.h>, <string.h> unconditionally.
21939
21940         * lib/memchr.c (__ptr_t): Remove; all uses changed to void *.
21941         * lib/memcmp.c (__ptr_t): Likewise.
21942         * lib/memrchr.c (__ptr_t): Likewise.
21943         * lib/memchr.c, memcmp.c, memcoll.c, memrchr.c:
21944         Include <string.h> unconditionally.
21945         * lib/memchr.c, memrchr.c: Include <limits.h> unconditionally.
21946         * lib/memchr.c: Include <stdlib.h> unconditionally.
21947         * lib/memchr.c (LONG_MAX): Remove.
21948         * lib/memrchr.c (LONG_MAX): Likewise.
21949         * lib/memchr.c (__memchr): Define via a prototype.
21950         * lib/memrchr.c (__memrchr): Likewise.
21951         * lib/memcmp.c (__P): Remove, and remove all uses.
21952         (memcmp_bytes, memcmp_common_alignment, memcmp_not_common_alignment):
21953         Remove forward decls; no longer needed.
21954         * lib/memcpy.c, memmove.c, memset.c: Include <stddef.h>.
21955         Use types required by C89 in prototype.
21956
21957         * lib/mkdir.c: Include <stdlib.h>, <string.h> unconditionally.
21958         * lib/savedir.c: Likewise.
21959         * lib/mkdir.c (free): Remove decl.
21960         * lib/rmdir.c (rmdir): Define with a prototype.
21961         * lib/savedir.c: Include savedir.h first, to test interface.
21962
21963         * lib/mktime.c (STDC_HEADERS): Remove.
21964         Include <stdlib.h>, <string.h> unconditionally.
21965
21966         * lib/modechange.c: Include <stdlib.h> unconditionally.
21967         (malloc): Remove decl.
21968
21969         * lib/mountlist.c: Include <stdlib.h>, <string.h> unconditionally.
21970         (free): Remove decl.
21971
21972         * lib/obstack.h (PTR_INT_TYPE) [!defined __PTRDIFF_TYPE__]:
21973         Define to ptrdiff_t, without bothering to check HAVE_STDDEF_H.
21974         (This type really should be intptr_t, but that's a C99ism.)
21975         (_obstack_memcpy): Remove: all uses changed to memcpy.
21976         Include <string.h> unconditionally.
21977         (struct obstack): Assume __STDC__ for types of members
21978         chunkfun, freefun, extra_arg.
21979         (_obstack_newchunk, _obstack_free, _obstack_begin, _obstack_begin_1,
21980         _obstack_memory_used, obstack_alloc_failed_handler, obstack_init,
21981         obstack_begin, obstack_specify_allocation,
21982         obstack_specify_allocation_with_arg, obstack_chunkfun,
21983         obstack_freefun, obstack_free) [! (defined __STDC__ && __STDC__)]:
21984         Remove unprototyped decls and the macros that use them.
21985         * lib/obstack.c (POINTER): Remove.  All uses changed to void *.
21986         (obstack_alloc_failed_handler, CALL_CHUNKFUN, CALL_FREEFUN,
21987         _obstack_begin, _obstack_begin_1, _obstack_allocated_p)
21988         (defined __STDC__ && __STDC__)]:
21989         Remove nonprototyped code.
21990         Include <stdlib.h> unconditionally.
21991         (_obstack_begin, _obstack_begin_1, _obstack_newchunk,
21992         _obstack_allocated_p, _obstack_free, obstack_free,
21993         _obstack_memory_used, print_and_abort):
21994         Define using prototypes.
21995         (obstack_1grow, obstack_1grow_fast, obstack_alloc, obstack_base,
21996         obstack_blank, obstack_blank_fast, obstack_copy, obstack_copy0,
21997         obstack_finish, obstack_grow, obstack_grow0, obstack_make_room,
21998         obstack_next_free, obstack_object_size, obstack_room) [0]:
21999         Remove unused, unprototyped code.
22000
22001         * lib/path-concat.c: Include <stdlib.h>, <string.h> unconditionally.
22002
22003         * lib/physmem.c (physmem_total, physmem_available, main): Define
22004         with prototypes.
22005
22006         * lib/posixtm.c: Include <stdlib.h>, <string.h> unconditionally.
22007         (main): Define with a prototype.
22008
22009         * lib/posixver.c (getenv): Remove decl.
22010
22011         * lib/putenv.c (malloc): Returns void *, not char *.
22012         Include <string.h> unconditionally.
22013         (strchr, memcpy, NULL): Do not define.
22014
22015         * lib/readtokens.c: Include readtokens.h first, to test interface.
22016         Include <stdlib.h>, <string.h> unconditionally.
22017         (init_tokenbuffer): Define with a prototype.
22018
22019         * lib/regex.c (PARAMS): Remove.  All uses removed.
22020         All uses of _RE_ARGS removed, too.
22021         Include <stddef.h>, <stdlib.h>, <string.h>, <limits.h>
22022         unconditionally.
22023         (bzero): Assume memset exists.
22024         (memcmp, memcpy, NULL): Remove.
22025         (SIGN_EXTEND_CHAR): Remove; all uses replaced by casts to signed
22026         char, or assignments to local vars of type signed char.
22027         (init_syntax_once, PREFIX(extract_number_and_incr),
22028         PREFIX(print_partial_compiled_pattern),
22029         PREFIX(print_compiled_pattern), PREFIX(print_double_string),
22030         convert_mbs_to_wcs, print_fastmap, re_set_syntax,
22031         PREFIX(regex_grow_registers), PREFIX(regex_compile),
22032         PREFIX(store_op1), PREFIX(store_op2), PREFIX(insert_op1),
22033         PREFIX(insert_op2), PREFIX(at_begline_loc_p),
22034         PREFIX(at_endline_loc_p), group_in_compile_stack, insert_space,
22035         wcs_compile_range, byte_compile_range, truncate_wchar,
22036         PREFIX(re_compile_fastmap), re_compile_fastmap, re_set_registers,
22037         re_search, re_search_2, PREFIX(re_search_2), re_match, re_match_2,
22038         count_mbs_length, wcs_re_match_2_internal,
22039         byte_re_match_2_internal, PREFIX(group_match_null_string_p),
22040         PREFIX(alt_match_null_string_p),
22041         PREFIX(common_op_match_null_string_p), PREFIX(bcmp_translate),
22042         re_compile_pattern, re_comp, re_exec, regcomp, regexec, regerror,
22043         regfree, PREFIX(extract_number)): Define with prototype.  Remove
22044         now-unnecessary declaration, if any.
22045         (byte_compile_range, PREFIX(regex_compile), re_comp, re_exec,
22046         regcomp, regexec):
22047         Remove now-unnecessary casts among pointer types.
22048         * lib/regex.h (_RE_ARGS): Remove.  All uses removed.
22049
22050         * lib/rename.c: Include <stdlib.h>, <string.h> unconditionally.
22051         (free): Remove decl.
22052
22053         * lib/rpmatch.c: Include <stdlib.h> unconditionally.
22054
22055         * lib/same.c: Include <stdlib.h>, <string.h> unconditionally.
22056         (free): Remove decl.
22057
22058         * lib/save-cwd.c: Include <stdlib.h> unconditionally.
22059         * lib/xgetcwd.c: Likewise.
22060
22061         * lib/stat.c: Include <stdlib.h>, <string.h> unconditionally.
22062         (free): Remove decl.
22063
22064         * lib/strchrnul.c (strchrnul): Define with a prototype.
22065         Fix bug: c_in was not converted to char before searching.
22066
22067         The following changes are not K&R related:
22068
22069         * lib/group-member.h: Include <sys/types.h>, so that this file is
22070         self-contained.
22071         * lib/makepath.h: Likewise.
22072
22073         * lib/getusershell.c (readname, default_index, line_size, readname):
22074         Use size_t, not int, for sizes.
22075         (readname): If the size overflows, report an error instead of
22076         looping forever.
22077
22078 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22079
22080         * config/srclist.txt: Do not get getopt.h, getopt1.c, or regex.h from
22081         libc.
22082
22083 2003-09-09  Paul Eggert  <eggert@twinsun.com>
22084
22085         * README: New section: portability guidelines.
22086
22087 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
22088
22089         * m4/getndelim2.m4 (gl_PREREQ_GETNDELIM2): Assume stdlib.h per the
22090         C89 spec.
22091
22092 2003-09-09  Derek Robert Price  <derek@ximbiot.com>
22093
22094         * lib/getndelim2.c: Assume stdlib.h per the C89 spec.
22095
22096 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22097
22098         Assume C89 or better; remove K&R cruft.
22099         A few of these changes were first proposed by Derek Robert Price
22100         in <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00105.html>.
22101
22102         * lib/addext.c: Include <string.h> unconditionally.
22103         * lib/backupfile.c: Include <string.h>, <stdlib.h> unconditionally.
22104         Don't declare getenv or malloc.
22105
22106         * lib/alloca.c: Include <string.h>, <stdlib.h> unconditionally.
22107         (POINTER_TYPE, pointer): Remove; all uses changed to void *.
22108         (NULL): Remove.
22109         (find_stack_direction, alloca): Use prototypes.
22110
22111         * lib/atexit.c (atexit): Define using a prototype.
22112
22113         * lib/basename.c, dirname.c, stripslash.c:
22114         Include <string.h> unconditionally.
22115
22116         * lib/bcopy.c: Include <stddef.h>.
22117         (bcopy): Define with prototype, using 'const' and 'void' and 'size_t'.
22118
22119         * lib/canon-host.c: Include <stdlib.h>, <string.h> unconditionally.
22120
22121         * lib/error.h (error, error_at_line, error_print_progname)
22122         [! (defined (__STDC__) && __STDC__)]: Remove decls.
22123         * lib/error.c: Include error.h first, to check interface.
22124         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
22125         (VA_START): Remove; all uses changeed to va_start.
22126         (exit, strerror): Remove decls.
22127         (error_print_progname): Prototype uncondionally.
22128         Don't include <errno.h>; no longer needed.
22129         (private_strerror): Remove.
22130         (error_tail): Always define.
22131         (error, error_at_line): Assume C89 or better; always use prototypes.
22132         * lib/fatal.c: Include "fatal.h" first, to test interface.
22133         Include <stdarg.h>, <stdlib.h>, <string.h> unconditionally.
22134         (VA_START): Remove; all uses changed to va_start.
22135         [! (HAVE_VPRINTF || HAVE_DOPRNT || _LIBC)]: Remove support for
22136         this case.
22137         (exit): Remove decl.
22138         (fatal): Prototype unconditionally.  Assume va_start works.
22139         Abort at end, to pacify gcc.
22140
22141         * lib/euidaccess.c (main): Define with a prototype.
22142
22143         * lib/exclude.c: Include <stdlib.h>, <string.h> unconditionally.
22144
22145         * lib/exitfail.c: Include <stdlib.h> unconditionally.
22146
22147         * lib/fnmatch_.h (__P): Remove.  All uses changed to assume
22148         prototypes.
22149         * lib/fnmatch.c: Include fnmatch.h first, to test interface.
22150         Include <string.h>, <stddef.h>, <stdlib.h> unconditionally.
22151         (getenv): Remove decl.
22152         (fnmatch): Define using a prototype.
22153         * lib/fnmatch_loop.c (FCT): Remove forward decl; no longer needed.
22154         (FCT): Define using a prototype.
22155
22156         * lib/getdate.y: Include <stdlib.h>, <string.h> unconditionally.
22157
22158         * lib/gethostname.c: Include <stddef.h>.
22159         (gethostname): Define with prototype.  Length is size_t, not int.
22160
22161 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22162
22163         Assume C89 or better; remove K&R cruft.
22164         * m4/alloca.m4 (gl_PREREQ_ALLOCA): Don't check for stdlib.h, string.h.
22165         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for stdlib.h,
22166         string.h, getenv, malloc.
22167         * m4/dirname.m4 (gl_DIRNAME): Don't check for string.h or C standard
22168         headers.
22169         * m4/canon-host.m4 (gl_CANON_HOST): Don't check for string.h, stdlib.h.
22170         * m4/error.m4 (jm_PREREQ_ERROR): Do not require STDC headers, and
22171         do not check for strerror.
22172         * m4/exclude.m4: Do not check for stdlib.h, string.h, strings.h.
22173         * m4/exitfail.m4 (gl_EXITFAIL): Do not check for stdlib.h.
22174         * m4/fatal.m4 (gl_FATAL): Do not require STDC headers, and
22175         do not check for doprnt or vprintf.
22176         * m4/fnmatch.m4 (gl_PREREQ_FNMATCH_EXTRA): Remove.  All uses removed.
22177         * m4/getdate.m4 (gl_GETDATE): Don't check for stdlib.h or string.h.
22178
22179 2003-09-08  Paul Eggert  <eggert@twinsun.com>
22180
22181         * lib/getversion.c: Remove; was migrated to backupfile.c in 1997.
22182         getversion.c should have been removed then, but was accidentally
22183         preserved.
22184
22185         * lib/utime.c [!HAVE_UTIMES_NULL]: Include <sys/stat.h>, <fcntl.h>.
22186         (utime_null): Fix typo: 'st' was sometimes called 'sb'.
22187
22188 2003-09-08  Karl Berry  <karl@gnu.org>
22189
22190         * config/config.sub, config.guess, srclistvars.sh: update from savannah
22191                 config, forget about prep.
22192
22193         * config/depcomp, missing: update from automake.
22194
22195 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22196
22197         * modules/time_r: Depend on 'restrict'.  Fix from Simon Josefsson in
22198         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22199
22200 2003-09-07  Paul Eggert  <eggert@twinsun.com>
22201
22202         * lib/time_r.c (gmtime_r, localtime_r): Fix silly typo: missing arg to
22203         copy_tm_result.  Bug reported by Simon Josefsson in
22204         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00028.html>.
22205
22206 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22207
22208         * m4/time_r.m4: New file.
22209         * m4/mktime.m4 (gl_PREREQ_MKTIME): Remove check for limits.h.
22210         * m4/timegm.m4 (gl_FUNC_TIMEGM): Assume that timegm is buggy if mktime
22211         is. Check for timegm declaration.
22212         (gl_PREREQ_TIMEGM): Require gl_FUNC_MKTIME.
22213         Do not check for gmtime_r.
22214         Replace mktime if __mktime_internal does not exist and if mktime
22215         hasn't been replaced already.
22216
22217 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22218
22219         * lib/time_r.c, lib/time_r.h: New files.
22220
22221         * lib/mktime.c (my_mktime_localtime_r): Remove; all uses changed to
22222         __localtime_r.
22223         (__localtime_r) [!defined _LIBC]: New macro.  Include <time_r.h>.
22224         (__mktime_internal) [!defined _LIBC]: Now extern, not static.
22225
22226         * lib/strftime.c (my_strftime_gmtime_r): Remove; all uses changed to
22227         __gmtime_r.
22228         (my_strftime_localtime_r): Remove; all uses changed to __localtime_r.
22229         (__gtime_r, __localtime_r) [!HAVE_TM_GMTOFF]: New macros.
22230         Include <time_r.h>.
22231
22232         * lib/timegm.c: Switch to glibc implementation, with the following
22233         changes:
22234         [defined HAVE_CONFIG_H]: Include <config.h>.
22235         [!defined _LIBC]: Include "timegm.h" rather than <time.h>.
22236         (__mktime_internal) [!defined _LIBC]: New decl.
22237         (__gmtime_r) [!defined _LIBC]: New macro and function.
22238         (timegm): Use a prototype, since gnulib assumes C89.
22239         Do not bother declaring tmp to be const, as it's not really usefu.
22240         * lib/timegm.h: Hoist "#include <time.h>" out of #ifdef.
22241         (timegm): Declare only if HAVE_DECL_TIMEGM.
22242
22243 2003-09-06  Paul Eggert  <eggert@twinsun.com>
22244
22245         * MODULES.html.sh (func_all_modules): Add time_r.
22246         * modules/time_r: New file.
22247         * modules/mktime, modules/strftime, modules/timegm: Depend on time_r.
22248         * modules/timegm: Depend on mktime.  Change maintainer to "all, glibc".
22249
22250 2003-09-03  Paul Eggert  <eggert@twinsun.com>
22251
22252         * lib/human.c (human_readable): Fix bug that rounded 10501 to 10k.
22253         Bug reported by Lute Kamstra in
22254         <http://mail.gnu.org/archive/html/bug-gnulib/2003-09/msg00003.html>.
22255
22256         * lib/getdate.y (relative_time_table): Use tDAY_UNIT for "tomorrow",
22257         "yesterday", "today", and "now" rather than tMINUTE_UNIT.  Of
22258         course with correspondingly smaller numbers for tomorrow and
22259         yesterday.  From Tadayoshi Funaba.  Originally installed into
22260         sh-utils on 1999-08-07, but the patch got lost (I guess during the
22261         coreutils merge?).
22262
22263 2003-08-31  Simon Josefsson  <jas@extundo.com>
22264
22265         * modules/timegm: New file.
22266         * MODULES.html.sh (func_all_modules): Add timegm.
22267
22268 2003-08-31  Simon Josefsson  <jas@extundo.com>
22269
22270         * m4/timegm.m4: New file.
22271
22272 2003-08-31  Simon Josefsson  <jas@extundo.com>
22273
22274         * lib/timegm.h: New file.
22275         * lib/timegm.c: New file.  Based on
22276         wget-1.8.2/src/http.c:mktime_from_utc.
22277
22278 2003-08-31  Karl Berry  <karl@gnu.org>
22279
22280         * lib/argp.h: update from libc.
22281
22282 2003-08-28  Bruno Haible  <bruno@clisp.org>
22283
22284         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Remove AC_DEFINE of fnmatch here.
22285         This avoids havoc on compilers for which '#define fnmatch rpl_fnmatch'
22286         followed by '#define fnmatch fnmatch_posix' gives an error.
22287
22288 2003-08-28  Bruno Haible  <bruno@clisp.org>
22289
22290         * lib/binary-io.h: Undefine O_BINARY before defining it. This avoids a
22291         warning on QNX, which defines O_BINARY to 000000.
22292
22293 2003-08-27  Jim Meyering  <jim@meyering.net>
22294
22295         * m4/mkstemp.m4: Require that the system mkstemp be able to create
22296         70 temporary files, not just 30.  Tru64 V4.0F's mkstemp function
22297         would fail after 32.  Reported by Danny Levinson.  Details here:
22298         http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00124.html
22299
22300 2003-08-24  Bruno Haible  <bruno@clisp.org>
22301
22302         * lib/binary-io.h: Include <stdio.h>, to avoid a compilation error when
22303         MSVC7 <stdio.h> is included later.
22304
22305 2003-08-22  Simon Josefsson  <jas@extundo.com>
22306
22307         * modules/strndup (Makefile.am): Add strndup.h to lib_SOURCES.
22308
22309 2003-08-20  Karl Berry  <karl@gnu.org>
22310
22311         * m4/lib-ld.m4: serial 1003 from gettext, no changes besides serial.
22312
22313 2003-08-20  Bruno Haible  <bruno@clisp.org>
22314
22315         * modules/progname: New file.
22316         * MODULES.html.sh (func_all_modules): Add progname.
22317
22318 2003-08-20  Bruno Haible  <bruno@clisp.org>
22319
22320         * lib/progname.h: New file, from GNU gettext.
22321         * lib/progname.c: New file, from GNU gettext.
22322         * lib/progreloc.c: New file, from GNU gettext.
22323
22324 2003-08-19  Jim Meyering  <jim@meyering.net>
22325
22326         * m4/lib-ld.m4: Revert yesterday's change, per Bruno's request here:
22327         http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00155.html
22328
22329 2003-08-19  Bruno Haible  <bruno@clisp.org>
22330
22331         * m4/xalloc.m4 (gl_PREREQ_XSTRDUP): Don't check for <string.h> any
22332         more.
22333
22334 2003-08-19  Bruno Haible  <bruno@clisp.org>
22335
22336         * lib/xstrdup.c: Assume <string.h> exists.
22337
22338 2003-08-18  Paul Eggert  <eggert@twinsun.com>
22339
22340         * modules/stdbool: Add BUILT_SOURCES.  Prefer $@ to target name
22341         in makefile rules.
22342
22343 2003-08-18  Jim Meyering  <jim@meyering.net>
22344
22345         * m4/getloadavg.m4: Use [\t ], not [ \t] (where \t is a literal TAB).
22346         * m4/lib-ld.m4: Likewise.
22347
22348 2003-08-18  Jim Meyering  <jim@meyering.net>
22349
22350         * lib/setenv.h: Indent nested cpp directive.
22351         * lib/vasnprintf.c: Remove trailing blanks.
22352
22353 2003-08-17  Simon Josefsson  <jas@extundo.com>
22354
22355         * modules/xstrndup: New file.
22356         * MODULES.html.sh (func_all_modules): Add xstrndup.
22357
22358 2003-08-17  Simon Josefsson  <jas@extundo.com>
22359
22360         * modules/argp: Fix autoconf macro name. Add more dependencies.
22361
22362 2003-08-17  Simon Josefsson  <jas@extundo.com>
22363
22364         * m4/xstrndup.m4: New file.
22365
22366 2003-08-17  Simon Josefsson  <jas@extundo.com>
22367
22368         * m4/argp.m4: New file.
22369
22370 2003-08-17  Simon Josefsson  <jas@extundo.com>
22371             Bruno Haible  <bruno@clisp.org>
22372
22373         * lib/xstrndup.h: New file.
22374         * lib/xstrndup.c: New file.
22375
22376 2003-08-17  Bruno Haible  <bruno@clisp.org>
22377
22378         * modules/strndup (Files, Include): Add lib/strndup.h.
22379
22380 2003-08-17  Bruno Haible  <bruno@clisp.org>
22381
22382         * modules/euidaccess (Files): Add lib/euidaccess.h.
22383
22384 2003-08-17  Bruno Haible  <bruno@clisp.org>
22385
22386         * lib/strndup.h: New file.
22387
22388 2003-08-17  Bruno Haible  <bruno@clisp.org>
22389
22390         * gnulib-tool (func_create_testdir): Handle gl_USE_SYSTEM_EXTENSIONS
22391         like AC_GNU_SOURCE.
22392         * modules/extensions (configure.ac): Comment out the invocation of
22393         gl_USE_SYSTEM_EXTENSIONS.
22394
22395 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22396
22397         Merges from coreutils, etc.
22398         * m4/rpmatch.m4 (gl_PREREQ_RPMATCH): Insert ':' to prevent a syntax
22399         error in gl_FUNC_MATCH.  This fixes a bug I introduced on 2003-05-28.
22400         * m4/readlink.m4 (gl_PREREQ_READLINK): Renamed from gl_PREREQ_READLINE,
22401         fixing a typo.
22402         * m4/host-os.m4 (UTILS_HOST_OS): Add GNU/NetBSD, GNU/FreeBSD.
22403         * m4/hash.m4 (gl_HASH): Use AM_STDBOOL_H, not AC_HEADER_STDBOOL.
22404
22405 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22406
22407         Document merge from coreutils.
22408         * modules/alloca: Append $(ALLOCA_H) to BUILT_SOURCES.
22409         * modules/fnmatch: Append $(FNMATCH_H) to BUILT_SOURCES.
22410         * modules/utime: Add m4/utimes-null.m4.
22411
22412 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22413
22414         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Do not normalize white
22415         space, undoing this 2003-08-12 change:
22416         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
22417
22418 2003-08-16  Paul Eggert  <eggert@twinsun.com>
22419
22420         * config/srclist.txt: Get regex.h, strdup.c, strtoll.c,
22421         strtoul.c from libc, undoing this 2003-08-12 change:
22422         <http://mail.gnu.org/archive/html/bug-gnulib/2003-08/msg00080.html>
22423
22424 2003-08-16  Jim Meyering  <jim@meyering.net>
22425
22426         Merges from coreutils.
22427         * m4/readdir.m4 (GL_FUNC_READDIR): Change name to have GL_ (not jm_)
22428         prefix.  Adjust cache variables similarly.  Create 500 rather than
22429         just 300 files, to exercise bug on Darwin6.5, too.
22430         * m4/perl.m4 (jm_PERL): Use $am_missing_run, not undefined
22431         $missing_dir.
22432         * m4/jm-winsz1.m4: Require AC_SYS_POSIX_TERMIOS, not
22433         AM_SYS_POSIX_TERMIOS.
22434         Reported by mkc@mathdogs.com.
22435         Also change use of $am_cv_sys_posix_termios
22436         to $ac_cv_sys_posix_termios.  Reported by Andreas Schwab.
22437         * m4/getgroups.m4 (jm_FUNC_GETGROUPS): Rewrite to use AC_FUNC_GETGROUPS
22438         and (if needed) to call AC_LIBOBJ and to set GETGROUPS_LIB.
22439         * m4/fsusage.m4 [__GLIBC__]: GNU libc's statvfs stats each mount point
22440         in /proc/mounts until it finds one with matching device number.  This
22441         is unnecessary when the FILE argument *is* a mount point.  No stat call
22442         is necessary in that case.  So, disable the statvfs-testing code on
22443         systems with GNU libc.  Reported by Andrei Gaponenko via Tim Waugh
22444         as RedHat bug# 84846.
22445         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
22446         to 1MB, so as not to render systems with no stack size limit (e.g.,
22447         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
22448         Include <unistd.h>.  On some systems,
22449         it is required for the definition of _SC_PAGESIZE.
22450
22451 2003-08-16  Jim Meyering  <jim@meyering.net>
22452
22453         Merge from coreutils.
22454         * lib/xstrtoimax.c: #else #if -> #elif.
22455         * lib/xstrtoumax.c: Likewise.
22456
22457 2003-08-16  Jim Meyering  <jim@meyering.net>
22458
22459         * m4/utimes.m4 (gl_FUNC_UTIMES): New file.
22460         * m4/utimes.m4: Removed.
22461         * m4/utimes-null.m4: Renamed from utimes.m4.
22462
22463         * m4/c-stack.m4 (AC_SYS_XSI_STACK_OVERFLOW_HEURISTIC): Limit stack size
22464         to 1MB, so as not to render systems with no stack size limit (e.g.,
22465         linux-2.2.x) unusable.  Suggestion and code from Bruno Haible.
22466         Include <unistd.h>.  On some systems,
22467         it is required for the definition of _SC_PAGESIZE.
22468
22469 2003-08-16  Jim Meyering  <jim@meyering.net>
22470         and Paul Eggert  <eggert@cs.ucla.edu>
22471
22472         Merges from coreutils, etc.
22473
22474         * m4/jm-macros.m4 (AC_LANG_SOURCE(C)): New macro, undefine, then define
22475         using the latest version from cvs.  This avoids problems with #line
22476         directives using a vendor (Sun) compiler.
22477         (jm_MACROS): Bump prerequisite from 2.52g to 2.57.
22478         Don't set GETGROUPS_LIB here; now it's
22479         done via getgroups.m4's wrapper function.
22480         AC_SUBST OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, and MAN here,
22481         rather than just in sh-util/configure.in, so that the
22482         now-shared-by-fileutils-and-textutils lib/Makefile.am are all the
22483         same.
22484         Use AC_CONFIG_LIBOBJ_DIR(lib) to tell the new
22485         AC_FUNC_GETLOADAVG where to find getloadavg.c.
22486         Require AC_FUNC_FTW, gt_INTTYPES_PRI, gl_CLOCK_TIME,
22487         UTILS_SYS_OPEN_MAX, GL_FUNC_GETCWD_PATH_MAX, GL_FUNC_READDIR,
22488         gl_FSUSAGE, gl_MOUNTLIST, AC_FUNC_CANONICALIZE_FILE_NAME.
22489         Remove code that is now done by the newly-required macros.
22490         Append $(EXEEXT) to DF_PROG.
22491         AC_LIBOBJ fchdir-stub if fchdir doesn't exist; similarly for fchown.
22492         Do not invoke or require the following here,
22493         since prereq.m4 or some gnulib .m4 now does this for us:
22494         gl_REGEX, UTILS_FUNC_MKDIR_TRAILING_SLASH, jm_BISON, gl_FUNC_MKTIME,
22495         jm_FUNC_LSTAT, jm_FUNC_STAT, jm_FUNC_REALLOC, jm_FUNC_MALLOC,
22496         jm_FUNC_NANOSLEEP, jm_FUNC_READDIR, jm_FUNC_MEMCMP,
22497         jm_FUNC_GLIBC_UNLOCKED_IO, AC_FUNC_FNMATCH_GNU, jm_FUNC_PUTENV,
22498         jm_AC_PREREQ_XSTRTOUMAX, jm_AC_PREREQ_XSTRTOIMAX,
22499         AC_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, AC_FUNC_VPRINTF,
22500         vb_FUNC_RENAME, UTILS_FUNC_MKSTEP, jm_FUNC_UTIME, AM_FUNC_GETLINE,
22501         AC_FUNC_OBSTACK.
22502         Do not replace the following functions, as this is now the job
22503         of some gnulib .m4: strcasecmp, strncasecmp, dup2, gethostname,
22504         getusershell, sig2str, strcspn, stpcpy, strstr, strtol, strtoul
22505         strpbrk, euidaccess, memcmp, rmdir, rpmatch, strndup, strverscmp,
22506         atexit getpass, strdup, getpagesize.
22507         Replace 'raise'.
22508         Do not check for the following functions, as this is now the job
22509         of some gnulib .m4: bcopy, canonicalize_file_name, fchdir, ftime,
22510         getcwd, getmntinfo, resolvepath.  But check for sysctl, setreuid,
22511         setregid.
22512         (jm_CHECK_ALL_HEADERS): Do not check for fenv.h.
22513         Check for sys/sysctl.h.
22514         (jm_CHECK_ALL_TYPES): Do not require AC_STRUCT_TM, AC_STRUCT_TIMEZONE,
22515         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Invoke gt_TYPE_SSIZE_T instead
22516         of checking for ssize_t ourselves.
22517
22518         * m4/prereq.m4 (jm_PREREQ): Don't invoke macros; AC_REQUIRE them.
22519         Require every macro that gnulib/modules/* suggests for us.
22520         (jm_PREREQ_ADDEXT): New macro.
22521         (jm_PREREQ_STAT): Check for 'struct statfs' on Ultrix 4.4.
22522         Require jm_AC_TYPE_LONG_LONG instead of invoking it.
22523
22524         * m4/physmem.m4 (gl_SYS__SYSTEM_CONFIGURATION): New macro.
22525         (gl_PHYSMEM): Use it.
22526         Also check for `table' function.
22527         Check for new headers and functions.
22528         Add check for sys/sysmp.h.
22529         With suggestions from Kaveh Ghazi.
22530         Ignore headers that are present but cannot be compiled.  This
22531         avoids spurious warnings on Solaris 9 sparc with Forte Developer 7
22532         C 5.4.
22533
22534 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22535
22536         Document merge from coreutils.
22537         * modules/userspec: Depend on posixver.
22538         * modules/strftime: Depend on tzset.
22539
22540 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22541
22542         * lib/config.charset, ref-add.sin, ref-del.sin: Use three spaces,
22543         rather than tab, after '#' in shell-script copyright notices.
22544         Suggested by Bruno Haible.
22545
22546 2003-08-15  Paul Eggert  <eggert@twinsun.com>
22547
22548         * config/srclist-update: Use three spaces, rather than tab, after '#'
22549         in shell-script copyright notices.  Suggested by Bruno Haible.
22550         Remove unnecessary parenthesization in regular expression.
22551
22552 2003-08-15  Jim Meyering  <jim@meyering.net>
22553
22554         Merge from coreutils.
22555         * lib/xgethostname.c: Include <stdlib.h>.
22556         (xghostname): Don't exit for anything other than memory-related
22557         failure; just return NULL.
22558         * lib/userspec.c: Include "posixver.h".
22559         (parse_user_spec): Accept `.' as a separator only
22560         in pre-POSIX-200112 mode.
22561         * lib/strtoimax.c: Use #elif rather than #else #if.
22562         * lib/strftime.c (my_strftime) [!_LIBC && HAVE_TZNAME && HAVE_TZSET]:
22563         Remove function, now that we can rely on a working tzset function.
22564         [!_LIBC]: Ensure that the required autoconf test has been run.
22565         [!defined _NL_CURRENT && HAVE_STRFTIME]:
22566         Use underlying_strftime for %r.
22567         * lib/sha.c: Merge in some clean-up and optimization changes from
22568         glibc.
22569         * lib/sha.c (sha_stream) [BLOCKSIZE]: Move definition to top of file.
22570         Ensure that it is a multiple of 64.
22571         Rearrange loop exit tests so as to avoid performing an
22572         additional fread after encountering an error or EOF.
22573         * lib/realloc.c: Update copyright date.
22574
22575 2003-08-15  Jim Meyering  <jim@meyering.net>
22576         and Paul Eggert  <eggert@twinsun.com>
22577
22578         Merge from coreutils.
22579         * lib/readutmp.h (HAVE_UTMPX_H): Undef if struct utmp has the ut_exit
22580         member but strut utmpx does not.  Needed for AIX 4.3.3.
22581         (UT_EXIT_E_TERMINATION, UT_EXIT_E_EXIT): Define.
22582
22583 2003-08-15  Jim Meyering  <jim@meyering.net>
22584         and Paul Eggert  <eggert@cs.ucla.edu>
22585
22586         Merges from coreutils, etc.
22587         * m4/strftime.m4 (_jm_STRFTIME_PREREQS):
22588         Require gl_FUNC_TZSET_CLOBBER.
22589         * m4/readutmp.m4 (gl_READUTMP): Check for ut_exit.ut_exit,
22590         ut_exit.e_exit, ut_exit.ut_termination, and ut_exit.e_termination
22591         members.
22592
22593 2003-08-14  Paul Eggert  <eggert@twinsun.com>
22594
22595         Help the merge from coreutils.
22596         * m4/gettimeofday.m4 (gl_GETTIMEOFDAY_REPLACE_LOCALTIME): New macro.
22597         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use it.
22598         * m4/tzset.m4: Use it too.
22599
22600 2003-08-14  Paul Eggert  <eggert@twinsun.com>
22601
22602         * modules/tzset: New file.
22603
22604 2003-08-14  Jim Meyering  <jim@meyering.net>
22605
22606         Merges from coreutils.
22607         * modules/fnmatch: Use the `$(FNMATCH_H)' notation for AC_REPLACED
22608         variable names, rather than @FNMATCH_H@.
22609         * modules/alloca: Likewise for $(ALLOCA_H).
22610
22611         * modules/fnmatch (fnmatch.h): Use `$@' in the commands, in place of
22612         the three copies of the literal target, `fnmatch.h'.
22613         * modules/alloca (alloca.h): Likewise.
22614
22615 2003-08-14  Jim Meyering  <jim@meyering.net>
22616
22617         Merge from coreutils.
22618         * m4/tzset.m4: New file.
22619         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Move the
22620         MOUNTED_VMOUNT test to precede the MOUNTED_GETMNTENT1 tests, since
22621         otherwise, AIX 5.1 systems would end up using the latter.
22622         MOUNTED_GETMNTENT1 support is inadequate on such systems: 1) detecting
22623         whether a file system is remote doesn't work  2) the MOUNTED_VMOUNT
22624         code reports the HOSTNAME:/MOUNT_POINT, while the MOUNTED_GETMNTENT1
22625         code reports merely /MOUNT_POINT.  Reported by Mike Jetzer.
22626
22627 2003-08-14  Jim Meyering  <jim@meyering.net>
22628
22629         Merge from coreutils.
22630         * lib/obstack.h: Whitespace changes.
22631         * lib/mountlist.c: Remove anachronistic casts of xmalloc, xrealloc,
22632         and xcalloc return values.
22633         (read_filesystem_list) [MOUNTED_GETFSSTAT]:
22634         Use MNT_NOWAIT, rather than MNT_WAIT.  Otherwise, `df DIR' could
22635         hang on OSF/1 5.1 for DIR on both local and remote file systems.
22636         Reported by (and fix confirmed by) Nelson H. F. Beebe.
22637         (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
22638         error from mntctl.
22639         Use mntctl's return value to drive the entry-processing loop, since
22640         we can't rely on the value of the vmt_length member in the last
22641         entry.  On some systems doing so could result in exhausting
22642         virtual memory.  Based in part on a patch from Mike Jetzer.
22643
22644 2003-08-14  Jim Meyering  <jim@meyering.net>
22645         and Paul Eggert  <eggert@twinsun.com>
22646
22647         Merges from coreutils, plus other fixes.
22648         * lib/physmem.c: Merge in portability changes from gcc/libiberty
22649         to support AIX, IRIX, Tru64, and Windows.  See the ChangeLog there
22650         for credits and details.  Thanks to Kaveh Ghazi for helping
22651         to keep these files in sync.
22652         (ARRAY_SIZE): Define it.
22653         (physmem_total, physmem_available): Add comments. From Kaveh Ghazi.
22654         * lib/memcasecmp.c: Remove unnecessary parentheses after 'defined'.
22655         (memcasecmp): Don't assume size_t fits in unsigned int.
22656         Remove casts and duplicate code.
22657         * lib/md5.c: Include <string.h> and <stdlib.h> unconditionally.
22658         (memcpy): Remove definition.
22659         Merge in some clean-up and optimization changes from glibc.
22660         [BLOCKSIZE]: Move definition to top of file.
22661         Ensure that it is a multiple of 64.
22662         Rearrange loop exit tests so as to avoid performing an
22663         additional fread after encountering an error or EOF.
22664         * lib/md5.h (md5_uintptr): Define.
22665         * lib/makepath.c (CLEANUP_CWD): Report an error if we failed to
22666         return to the initial working directory.  Preserve errno
22667         for caller.
22668         * lib/idcache.c: Include "xalloc.h".
22669         (xmalloc, xrealloc): Remove decls.
22670         (getuser): Remove casts no longer required in C89.
22671         * lib/human.c: Include stdio.h, for sprintf.
22672         * lib/group-member.c: Include "xalloc.h".
22673         (xmalloc, xrealloc): Remove decls.
22674         (get_group_info): Remove casts no longer required in C89.
22675         * lib/getusershell.c (readname): Remove casts no longer required in
22676         C89.
22677         * lib/gettimeofday.c (rpl_gmtime, rpl_tzset): New functions.
22678         * lib/getline.c: Whitespace fix, from coreutils.
22679
22680 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22681
22682         * m4/exclude.m4 (gl_EXCLUDE): Require AC_C_INLINE, AC_HEADER_STDC.
22683         Check for isascii.
22684
22685         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
22686         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
22687         Undo previous (whitespace-only) change.
22688
22689 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22690
22691         * lib/exclude.c: Include <ctype.h>
22692         (IN_CTYPE_DOMAIN): New macro.
22693         (is_space): New fn.
22694         (add_exclude_file): If LINE_END is a space, ignore trailing spaces
22695         and empty lines.
22696
22697         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
22698         Undo previous (whitespace-only) change.
22699
22700 2003-08-13  Paul Eggert  <eggert@twinsun.com>
22701
22702         * config/srclist-update: Change update back to the old behavior,
22703         leaving whitespace alone.  Use one 'sed' command rather than a
22704         pipeline.
22705         (fixlicense): Now a variable, not a function.
22706         (remove_trailing_blanks): Remove.
22707         (fixfile): Don't invoke unexpand or cat, or remove trailing blanks.
22708         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
22709         Undo previous (whitespace-only) change.
22710
22711 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22712
22713         Merge from coreutils.
22714         * modules/euidaccess: Add lib_SOURCES, include for new
22715         file euidaccess.h
22716
22717 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22718
22719         * m4/gettext.m4, iconv.m4, intdiv0.m4, inttypes-pri.m4, lib-link.m4,
22720         lib-prefix.m4, longdouble.m4, po.m4, progtest.m4, signed.m4:
22721         Normalize leading white space and remove trailing white space.
22722
22723         Merge from coreutils
22724         * m4/euidaccess.m4 (gl_FUNC_EUIDACCESS): Check for euidaccess decl.
22725
22726         * m4/lib-ld.m4, lib-link.m4, lib-prefix.m4: Regenerate from gettext
22727         0.12.1.  These files are now being upgraded automatically by
22728         ../config/srclist-update.
22729
22730 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22731
22732         * lib/argp-help.c, argp-parse.c, config.charset, getopt.h:
22733         Normalize leading white space and remove trailing white space.
22734         * lib/ref-add.sin, ref-del.sin: Use '#' before empty line in copyright
22735         notice, as per ../config/srclist-update.
22736
22737         Merge from coreutils.
22738         * lib/euidaccess.h: New file.
22739         * lib/euidaccess.c: Include it.
22740         * lib/.cppi-disable: Add printf-args.h, printf-parse.h, stdbool_.h,
22741         vasnprintf.h, vasprintf.h.  Remove strdup.c, gettext.h.
22742         * lib/regex.h, strdup.c, strtoll.c, strtoul.c: Normalize white space.
22743
22744 2003-08-12  Paul Eggert  <eggert@twinsun.com>
22745
22746         * config/srclist-update: Add copyright notice.
22747         (remove_id_lines, remove_trailing_blanks): New constants.
22748         (fixfile): Use them to normalize spacing a bit in copied files.
22749         * config/config.guess, config.sub, install-sh, missing, texinfo.tex:
22750         Normalize leading white space and remove trailing white space.
22751
22752         * config/texinfo.tex: Sync with texinfo.
22753
22754         * config/srclist.txt: Don't get regex.h, strdup.c, strtoll.c,
22755         strtoul.c from libc, to merge coreutils whitespace changes.
22756
22757         * config/srclist.txt: Get the following m4 files from gettext:
22758         codeset.m4, gettext.m4, glibc21.m4, iconv.m4, intdiv0.m4,
22759         inttypes-pri.m4, lcmessage.m4, lib-ld.m4, lib-link.m4, lib-prefix.m4,
22760         longdouble.m4, nls.m4, po.m4, progtest.m4, signed.m4, wchar_t.m4,
22761         wint_t.m4.
22762
22763 2003-08-12  Karl Berry  <karl@gnu.org>
22764
22765         * config/srclist.txt: can't sync vasnprintf.c any more, changes have
22766         been made.
22767
22768 2003-08-11  Paul Eggert  <eggert@twinsun.com>
22769
22770         * modules/gnu-source, m4/gnu-source.m4:
22771         Remove; we're assuming Autoconf 2.54 or later now.
22772         Suggested by Bruno Haible.
22773         * MODULES.html.sh (func_all_modules): Remove gnu-source.
22774
22775 2003-08-11  Bruno Haible  <bruno@clisp.org>
22776
22777         * m4/vasnprintf.m4 (gl_PREREQ_VASNPRINTF): Also check for wcslen.
22778
22779 2003-08-11  Bruno Haible  <bruno@clisp.org>
22780
22781         * lib/vasnprintf.c (local_wcslen): New function, for Solaris 2.5.1.
22782         (vasnprintf): Use it instead of wcslen.
22783
22784 2003-08-11  Bruno Haible  <bruno@clisp.org>
22785
22786         * lib/stdbool_.h (_Bool): Undo last change; instead use a negative enum
22787         value to ensure that _Bool promotes to int. Use #define for _Bool when
22788         using the Solaris C compiler. Adds comments suggested by Paul Eggert.
22789
22790 2003-08-10  Karl Berry  <karl@gnu.org>
22791
22792         * lib/regex.h: update from libc (whitespace fix).
22793
22794 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22795
22796         Merge some files from coreutils.  These changes were
22797         originally made by Jim Meyering.
22798         * lib/acl.c: Include <sys/types.h> before <sys/stat.h>;
22799         many older Unixes require this.
22800         * lib/alloca.c (alloca): Remove cast to argument of free;
22801         no longer needed in C89.
22802         * lib/alloca_.h, regex.h: Fix white space to match
22803         what GNU indent does.
22804
22805 2003-08-09  Paul Eggert  <eggert@twinsun.com>
22806
22807         * m4/regex.m4 (jm_INCLUDED_REGEX): Change "\201" to "\371";
22808         apparently Emacs's Unicode mode got confused before my 2003-08-05
22809         checkin.
22810
22811 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22812
22813         * m4/extensions.m4: New file.
22814         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC):
22815         Require gl_USE_SYSTEM_EXTENSIONS.
22816         * m4/unlocked-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO):
22817         Require gl_USE_SYSTEM_EXTENSIONS rather than AC_GNU_SOURCE.
22818
22819 2003-08-08  Paul Eggert  <eggert@twinsun.com>
22820
22821         * MODULES.html.sh (func_all_modules): Add extensions, gnu-source.
22822         * modules/extensions, modules/gnu-source: New files.
22823         * modules/timespec, modules/unlocked-io: Depend on extensions.
22824
22825 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22826
22827         * modules/restrict: New file.
22828         * MODULES.html.sh (func_all_modules): Add restrict.
22829         * modules/regex: Depend on restrict.
22830
22831 2003-08-07  Paul Eggert  <eggert@twinsun.com>
22832
22833         * m4/restrict.m4: New file.
22834         * m4/regex.m4 (jm_PREREQ_REGEX): Add gl_C_RESTRICT.
22835
22836 2003-08-07  Bruno Haible  <bruno@clisp.org>
22837
22838         * modules/getndelim2 (Makefile.am): Add the files to EXTRA_DIST, not
22839         lib_SOURCES, because getndelim2.m4 now uses AC_LIBOBJ(getndelim2).
22840
22841 2003-08-07  Bruno Haible  <bruno@clisp.org>
22842
22843         * m4/getndelim2.m4 (gl_GETNDELIM2): Use AC_LIBOBJ(getndelim2). This
22844         makes the module 'getndelim2' compatible with the module 'getline'.
22845
22846 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22847
22848         * m4/regex.m4 (jm_INCLUDED_REGEX): Replace a single non-ASCII
22849         byte with "\201" to avoid glitches when editing that source file
22850         with multi-gnome-terminal.
22851
22852 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22853
22854         * lib/bumpalloc.h: Remove.
22855
22856 2003-08-05  Paul Eggert  <eggert@twinsun.com>
22857
22858         * MODULES.html.sh (func_all_modules): Remove bumpalloc.
22859         * modules/bumpalloc: Remove.
22860
22861 2003-08-04  Paul Eggert  <eggert@twinsun.com>
22862
22863         * lib/getloadavg.c: Change copyright notice and spacing to conform to
22864         GNU coding style.
22865
22866         Merge from coreutils.
22867         * lib/error.c [!USE_IN_LIBIO]: Omit this case; assume USE_IN_LIBIO is
22868         1. From glibc.
22869         * lib/getdate.y (date): Also accept dates like May-23-2003; suggestion
22870         from Karl Berry, implemented by Jim Meyering.
22871         * lib/getgroups.c: Include "xalloc.h" instead of declaring xalloc fns;
22872         from Dmitry V. Levin.
22873         Remove anachronistic cast of xrealloc.
22874         * lib/fnmatch_.h (__const): Remove.  Use 'const'.
22875         * lib/fnmatch_loop.c (NEW_PATTERN): Cast alloca return value to proper
22876         type. Otherwise, it wouldn't compile with at least /bin/cc on
22877         ymp-cray-unicos9.0.2.X.
22878         Combine two mostly-identical uses of alloca into one.
22879         Thanks to the Cray-Cyber project for access to a Cray Y-MP.
22880
22881 2003-08-04  Dave Love  <d.love@dl.ac.uk>
22882
22883         [From Emacs.]
22884
22885         * lib/getloadavg.c: Check `__unix' as well as `unix'.  Use #ifdef, not
22886         #if.  Check HAVE_LIBKSTAT as well as LOAD_AVE_TYPE.  Check
22887         F_SETFD, not FD_SETFD.  Use HAVE_STRUCT_NLIST_N_UN_N_NAME, not
22888         obsolete NLIST_NAME_UNION.
22889         [__GNU__]: Undef BSD and FSCALE.
22890         [!NLIST_STRUCT]: Remove conditional definition of NLIST_STRUCT.
22891
22892 2003-08-03  Paul Eggert  <eggert@twinsun.com>
22893
22894         * lib/stdbool_.h (_Bool): Make it signed char, instead of
22895         an enum type, so that it's guaranteed to promote to int.  See:
22896         <http://mail.gnu.org/archive/html/bug-gnulib/2003-07/msg00124.html>
22897
22898 2003-08-03  Karl Berry  <karl@gnu.org>
22899
22900         * config/depcomp: update from automake.
22901
22902 2003-07-31  Paul Eggert  <eggert@twinsun.com>
22903
22904         * lib/strerror.c: Include config.h, limits.h.  Declare sprintf.
22905         (strerror): Don't assume that a printable int fits in 14 bytes.
22906
22907 2003-07-31  Bruno Haible  <bruno@clisp.org>
22908
22909         * modules/getpass-gnu: New file.
22910         * MODULES.html.sh (func_all_modules): Add getpass-gnu.
22911
22912 2003-07-31  Bruno Haible  <bruno@clisp.org>
22913
22914         * m4/getpass.m4 (gl_FUNC_GETPASS_GNU): New macro.
22915
22916 2003-07-24  Karl Berry  <karl@gnu.org>
22917
22918         * config/missing: update from automake.
22919
22920 2003-07-24  Derek Robert Price  <derek@ximbiot.com>
22921             Bruno Haible  <bruno@clisp.org>
22922
22923         * lib/getline.h (getline, getdelim): Change return type to ssize_t.
22924         * lib/getline.c (getline, getdelim): Likewise.
22925         Remove _GNU_SOURCE define; now it's defined in config.h through
22926         m4/getline.m4.
22927
22928 2003-07-23  Karl Berry  <karl@gnu.org>
22929
22930         * config/config.sub: update from prep.
22931
22932 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22933
22934         * modules/xalloc (Depends-on): Add exitfail.
22935         * modules/xmemcoll: Likewise.
22936
22937 2003-07-22  Paul Eggert  <eggert@twinsun.com>
22938
22939         * lib/xalloc.h (XCALLOC, XREALLOC, CCLONE): Fix under- and
22940         over-parenthesization in macros.
22941
22942         Sync with coreutils.
22943
22944         * lib/xalloc.h (XMALLOC, XCALLOC, XREALLOC): Remove casts not
22945         required by C99.
22946
22947         Use `exit_failure' for xalloc and xmemcoll instead of their own
22948         private exit-failure variables.
22949         * lib/xalloc.h (xalloc_exit_failure): Remove.
22950         * lib/xmalloc.c: Likewise.  Include exitfail.h.
22951         (xalloc_die): Use exit_failure instead of xalloc_exit_failure.
22952         * lib/xmemcoll.h (xmemcoll_exit_failure): Remove.
22953         * lib/xmemcoll.c: Likewise.  Include exitfail.h.
22954         (xmemcoll): Use exit_failure instead of xalloc_exit_failure.
22955
22956 2003-07-20  Jim Meyering  <jim@meyering.net>
22957
22958         * modules/closeout (Depends-on): Add exitfail.
22959         Suggestion from Bruno Haible.
22960
22961 2003-07-19  Karl Berry  <karl@gnu.org>
22962
22963         * config/config.sub: update from prep.
22964
22965 2003-07-18  Paul Eggert  <eggert@twinsun.com>
22966
22967         * lib/closeout.h (close_stdout_set_status, close_stdout_status):
22968         Remove.
22969         * lib/closeout.c: Likewise.  Include "closeout.h" right after config.h,
22970         to test that it can stand by itself.  Include "exitfail.h".
22971         Clients should set exit_failure instead.
22972         (EXIT_FAILURE): Remove; no longer needed.  Do not include <stdlib.h>.
22973
22974 2003-07-18  Bruno Haible  <bruno@clisp.org>
22975
22976         * modules/getndelim2: New file.
22977         * modules/getline: Share files with module getndelim2.
22978         * modules/getnline: Depend on getndelim2 instead of sharing files with
22979         it. Add getnline.c to lib_SOURCES.
22980         * MODULES.html.sh (func_all_modules): Add getndelim2.
22981
22982 2003-07-18  Bruno Haible  <bruno@clisp.org>
22983
22984         * m4/getndelim2.m4: New file.
22985         * m4/getline.m4 (AM_FUNC_GETLINE): Add AC_LIBOBJ of getndelim2.c and
22986         invoke gl_PREREQ_GETNDELIM2.
22987         (gl_PREREQ_GETLINE): Drop AC_HEADER_STDC, now done by
22988         gl_PREREQ_GETNDELIM2.
22989         * m4/getnline.m4 (gl_GETNLINE): Drop AC_HEADER_STDC, now done by
22990         gl_GETNDELIM2.
22991
22992 2003-07-18  Bruno Haible  <bruno@clisp.org>
22993
22994         * lib/getndelim2.h: New file.
22995         * lib/getndelim2.c: Make into a module of its own. Include config.h,
22996         getndelim2.h.
22997         (getndelim2): Make non-static. Change return type to ssize_t.
22998         * lib/getline.h: Change argument names.
22999         * lib/getline.c: Include getndelim2.h instead of getndelim2.c.
23000         * lib/getnline.c: Include getndelim2.h.
23001
23002 2003-07-18  Andreas Schwab  <schwab@suse.de>
23003
23004         * lib/memcoll.c (memcoll) [!HAVE_STRCOLL]: Clear errno.
23005
23006 2003-07-17  Karl Berry  <karl@gnu.org>
23007
23008         * config/config.sub: update from prep.
23009
23010 2003-07-17  Bruno Haible  <bruno@clisp.org>
23011
23012         * modules/getnline: New file.
23013         * modules/getline: Add lib/getndelim2.c to source file list.
23014         * MODULES.html.sh (func_all_modules): Add getnline.
23015
23016 2003-07-17  Bruno Haible  <bruno@clisp.org>
23017
23018         * m4/getnline.m4: New file.
23019
23020 2003-07-17  Bruno Haible  <bruno@clisp.org>
23021
23022         * m4/Makefile.am.in: Remove file.
23023         * m4/Makefile.am: Remove file.
23024         * m4/Makefile.in: Remove file.
23025
23026 2003-07-17  Bruno Haible  <bruno@clisp.org>
23027
23028         * lib/getnline.h: New file.
23029         * lib/getnline.c: New file.
23030         * lib/getndelim2.c: New file, extracted from getline.c.
23031         (getndelim2): Renamed from getdelim2, with added nmax argument.
23032         * lib/getline.c: Include getndelim2.c.
23033         (getdelim2): Moved out to getndelim2.c.
23034         (getline, getdelim): Update.
23035
23036 2003-07-17  Bruno Haible  <bruno@clisp.org>
23037
23038         * lib/Makefile.am: Remove file.
23039         * lib/Makefile.in: Remove file.
23040
23041 2003-07-17  Bruno Haible  <bruno@clisp.org>
23042
23043         * configure.in: Remove file.
23044         * Makefile.in: Remove file.
23045
23046 2003-07-17  Bruno Haible  <bruno@clisp.org>
23047
23048         * MODULES.html.sh: Put the </BODY> right before </HTML>.
23049
23050 2003-07-16  Karl Berry  <karl@gnu.org>
23051
23052         * config/srclist-update: was running fixlicense twice, which caused
23053                 texinfo.tex to be nullified for some reason.  Simplify,
23054                 $gplsrc is no longer needed as far as I can see?
23055
23056 2003-07-16  Jim Meyering  <jim@meyering.net>
23057
23058         * modules/save-cwd: Depend on xgetcwd.  From Derek Price.
23059
23060 2003-07-15  Paul Eggert  <eggert@twinsun.com>
23061
23062         * config/srclist.txt: Get the following files from gettext-runtime/intl
23063         instead: config.charset, localcharset.c, localcharset.h, ref-add.sin,
23064         ref-del.sin.  From Bruno Haible.
23065         * config/srclist-update (fixfile): Change grep pattern again, since the
23066         previous fix didn't work (there was another trailing $).  Use
23067         '[$]' to escape the $s.
23068
23069 2003-07-15  Karl Berry  <karl@gnu.org>
23070
23071         * lib/vasnprintf.c: update from gettext.
23072
23073 2003-07-15  Karl Berry  <karl@gnu.org>
23074
23075         * config/srclist-update (fixfile): Change grep pattern, since 'Id'
23076         gets expanded when surrounded by '$'.
23077
23078 2003-07-15  Jim Meyering  <jim@meyering.net>
23079
23080         * modules/save-cwd: Don't depend on error.  From Derek Price.
23081
23082 2003-07-15  Jim Meyering  <jim@meyering.net>
23083
23084         * lib/makepath.c (make_path): Enclose diagnostic in _(...).
23085
23086 2003-07-14  Simon Josefsson  <jas@extundo.com>
23087
23088         * modules/mempcpy: New file.
23089         * MODULES.html.sh (func_all_modules): Add mempcpy.
23090
23091 2003-07-14  Simon Josefsson  <jas@extundo.com>
23092
23093         * m4/mempcpy.m4: New file.
23094
23095 2003-07-14  Simon Josefsson  <jas@extundo.com>
23096
23097         * lib/mempcpy.h: New file.
23098         * lib/mempcpy.c: New file.
23099
23100 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23101
23102         * modules/getdate, modules/posixtm: Depend on mktime.
23103
23104 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23105
23106         * lib/ceill.c, expl.c, floorl.c, frexpl.c, ldexpl.c, mathl.h,
23107         sincosl.c, sqrtl.c, trigl.c, trigl.h, poll.c, poll_.h, mkstemp.c,
23108         unicodeio.c, unicodeio.h, unlocked-io.h:
23109         Switch from LGPL to GPL.
23110
23111 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23112
23113         * lib/asnprintf.c, asprintf.c, config.charset, gettext.h,
23114         localcharset.c, localcharset.h, mkdtemp.c, printf-args.c,
23115         printf-args.h, printf-parse.c, printf-parse.h, ref-add.sin,
23116         ref-del.sin, setenv.c, unsetenv.c, vasnprintf.c, vasnprintf.h,
23117         vasprintf.c, vasprintf.h: Regenerate.  These files are now being
23118         updated automatically by ../config/srclist-update.  This changes
23119         their license from LPGL to GPL.
23120
23121 2003-07-14  Paul Eggert  <eggert@twinsun.com>
23122
23123         * config/srclist.txt: Add tons more gettext files.  $GETTEXT is now
23124         assumed to refer to the root of the most recent stable gettext version.
23125         * config/srclistvars.sh: Add defaults for eggert.
23126         * config/srclist-update: Convert LGPL to GPL in shell scripts, too.
23127         Match "This program" as well as "The program".  This is needed
23128         for gettext.
23129
23130 2003-07-14  Jim Meyering  <jim@meyering.net>
23131
23132         Don't emit diagnostics.  Let callers do that.
23133         * lib/save-cwd.c: Don't include "error.h".
23134         (save_cwd): Don't call error.  Ensure that errno is valid
23135         when returning nonzero.
23136
23137         * lib/save-cwd.h (restore_cwd): Update prototype.
23138         * lib/save-cwd.c (restore_cwd): Remove two parameters.
23139         Simplify.  Don't call error upon failure.  Let callers do that.
23140         (save_cwd): Mention that Irix 5.3 has the same problem as SunOS 4
23141         when auditing is enabled.  But don't bother updating the #if.
23142
23143 2003-07-11  Alexandre Duret-Lutz  <adl@gnu.org>
23144
23145         * lib/obstack.h (__INT_TO_PTR): Revert change of 2003-03-13;
23146         it breaks C++ compilation.
23147         [!__GNUC__ || !__STDC__] (obstack_finish): Cast result to void*.
23148
23149 2003-07-10  Simon Josefsson  <jas@extundo.com>
23150
23151         * modules/strchrnul (Makefile.am): Add strchrnul.h.
23152
23153 2003-07-10  Jim Meyering  <jim@meyering.net>
23154
23155         * m4/clock_time.m4: Remove trailing blank.
23156         * m4/intmax_t.m4: Likewise.
23157
23158 2003-07-10  Jim Meyering  <jim@meyering.net>
23159
23160         * lib/vasnprintf.c: Remove trailing blanks.
23161         Make cpp indentation consistent.
23162
23163 2003-07-09  Paul Eggert  <eggert@twinsun.com>
23164
23165         * lib/alloca_.h, euidaccess.c, getpass.c, memrchr.c, obstack.h,
23166         posixver.c, strftime.c, strnlen.c, strverscmp.c:
23167         Switch from LGPL to GPL.
23168
23169 2003-07-09  Paul Eggert  <eggert@twinsun.com>
23170
23171         * config/srclist.txt: Sort sublists.  Add
23172         $LIBCSRC/sysdeps/generic/strtoul.c. In comments, add more libc files
23173         that differ from gnulib for one reason or another; we'd like this list
23174         to be smaller but for now let's document what we have.
23175
23176 2003-07-08  Paul Eggert  <eggert@twinsun.com>
23177
23178         * config/srclist-update: Port to POSIX 1003.1-2001 hosts by avoiding
23179         the use of GNU extensions.  Change "x=`eval echo $x`" to the shorter
23180         and sweeter "eval x=$x".
23181         * config/srclist.txt: Get lib/argp* from glibc.
23182
23183 2003-07-07  Paul Eggert  <eggert@twinsun.com>
23184
23185         * lib/mktime.c: Fix some boundary cases and remove need for floating
23186         point.
23187
23188         Issue a compile-time diagnostic if time_t is floating point, or if
23189         two's complement arithmetic is not in effect, or if arithmetic
23190         right shift does not propagate the sign.  These assumptions were
23191         all in the original code but they weren't checked.
23192
23193         (TIME_T_MIDPOINT, verify): New macros.
23194         (__isleap): Remove; it has integer overflow problems.
23195         (leapyear): New function, without those problems.
23196         (ydhms_tm_diff): Remove; splitting into two parts.
23197         (ydhms_diff): New function, containing the arithmetic part of
23198         the old ydhms_tm_diff function.  Issue a compile-time
23199         diagnostic if we are not using C99 integer division.
23200         Avoid casts when possible.
23201         (guess_time_tm): New function, containing the checking part of
23202         the old ydhms_tm_diff function.  Return the new value, rather than
23203         the difference between it and the old.  Accept a new argument T
23204         so that *T specifies the old value.  Check for overflow in the result.
23205
23206         (__mktime_internal): Use a time_t offset, not a long int offset.
23207         This undoes the 2003-06-04 change, which is no longer needed now
23208         that we have better overflow checking.
23209         (localtime_offset): Likewise.
23210
23211         (__mktime_internal): Avoid harmful overflow on hosts where time_t
23212         and long are 64-bit but int is only 32-bit.
23213         (ydhms_diff): Use long int to store year1 and yday1.
23214         Issue a compile-time diagnostic if long int is not wide enough.
23215
23216         (__mktime_internal): Use long int to store adjusted year and yday.
23217         Use plain C rather than preprocessor commands, if that doesn't
23218         affect efficiency.
23219         Check for overflow (and try to repair) after each probe
23220         rather than checking only at the very end.  This avoids some bugs
23221         (e.g., southern hemisphere, behind GMT, and GMT offset at minimum time
23222         does not equal GMT offset at maximum time).
23223         Use integer to check for overflow rather than floating point; this
23224         is more portable to non-IEEE hosts, and is a tad faster.
23225         When we detect that we are oscillating between two values,
23226         don't check whether tm_isdst has the requested value, since
23227         we already know the answer.  When tm_isdst has the wrong value,
23228         use a different heuristic to find the right one, based on the
23229         extreme values actually observed in practice in tz2003a,
23230         rather than the (overly optimistic) "previous 3 calendar quarters".
23231
23232         (not_equal_tm, print_tm, check_result): Use "const T" rather than
23233         "T const" to accommodate glibc style.
23234         (check_result): Use less-confusing report format.  "long" -> "long int.
23235         (main): Likewise.
23236         Don't loop if the iteration overflows time_t.
23237         Allow a negative step in the iteration.
23238
23239 2003-07-06  Karl Berry  <karl@gnu.org>
23240
23241         * config/depcomp: update from automake.
23242         * config/config.sub: update from prep.
23243
23244 2003-07-03  Karl Berry  <karl@gnu.org>
23245
23246         * config/config.guess: update from prep.
23247
23248 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23249
23250         * m4/xreadlink.m4 (gl_XREADLINK): Don't check for sys/types.h, since
23251         xreadlink.c now includes it unconditionally.
23252
23253 2003-07-01  Paul Eggert  <eggert@twinsun.com>
23254
23255         * lib/xreadlink.c: Include <sys/types.h> unconditionally, instead of
23256         having it depend on HAVE_SYS_TYPES_H.
23257
23258 2003-07-01  Bruno Haible  <bruno@clisp.org>
23259
23260         * m4/ssize_t.m4 (gt_TYPE_SSIZE_T): Don't include <unistd.h>.
23261         <sys/types.h> should be sufficient.
23262         Reported by Paul Eggert.
23263
23264 2003-06-26  Karl Berry  <karl@gnu.org>
23265
23266         * config/depcomp: update from automake.
23267
23268 2003-06-26  Bruno Haible  <bruno@clisp.org>
23269
23270         * modules/human: Depend on module stdbool.
23271
23272 2003-06-25  Bruno Haible  <bruno@clisp.org>
23273
23274         * modules/readlink: New file.
23275         * modules/xreadlink: Depend on it.
23276         * MODULES.html.sh (func_all_modules): Add readlink.
23277
23278 2003-06-25  Bruno Haible  <bruno@clisp.org>
23279
23280         * m4/readlink.m4: New file.
23281
23282 2003-06-25  Bruno Haible  <bruno@clisp.org>
23283
23284         * lib/readlink.c: New file.
23285
23286 2003-06-22  Karl Berry  <karl@gnu.org>
23287
23288         * config/srclist.txt: update mkinstalldirs from automake.
23289         * config/mkinstalldirs: update.
23290
23291 2003-06-22  Bruno Haible  <bruno@clisp.org>
23292
23293         Portability to mingw32.
23294         * m4/ssize_t.m4: New file, from GNU gettext.
23295         * m4/safe-read.m4 (gl_PREREQ_SAFE_READ): Require gt_TYPE_SSIZE_T.
23296         * m4/xreadlink.m4 (gl_XREADLINK): Require gt_TYPE_SSIZE_T.
23297
23298 2003-06-22  Bruno Haible  <bruno@clisp.org>
23299
23300         * modules/safe-read: Add m4/ssize_t.m4.
23301         * modules/xreadlink: Add m4/ssize_t.m4.
23302
23303 2003-06-20  Bruno Haible  <bruno@clisp.org>
23304
23305         Assume C89, so PARAMS isn't needed.
23306         * lib/unicodeio.h (PARAMS): Remove.
23307         * lib/unicodeio.c: Don't use PARAMS.
23308
23309 2003-06-18  Karl Berry  <karl@gnu.org>
23310
23311         * config/config.{guess,sub}: update from prep.
23312
23313 2003-06-18  Jim Meyering  <jim@meyering.net>
23314
23315         Merge changes from coreutils.
23316         * lib/readutmp.c: Include <string.h> and <stdlib.h> unconditionally.
23317         Remove explicit declarations of xmalloc and realloc.
23318         Include xalloc.h.
23319         (read_utmp): Remove anachronistic cast of xmalloc.
23320
23321 2003-06-17  Paul Eggert  <eggert@twinsun.com>
23322
23323         Assume C89, so PARAMS isn't needed.
23324         * lib/backupfile.h (PARAMS): Remove.  All uses removed.
23325         * lib/closeout.h, lib/dirname.h, lib/filemode.h, lib/fsusage.h,
23326         lib/getdate.h, lib/getline.h, lib/group-member.h, lib/hard-locale.h,
23327         lib/hash.h, lib/linebuffer.h, lib/long-options.h, lib/makepath.h,
23328         lib/memcasecmp.h, lib/memcoll.h, lib/modechange.h, lib/mountlist.h,
23329         lib/path-concat.h, lib/physmem.h, lib/posixtm.h, lib/quote.h,
23330         lib/readutmp.h, lib/same.h, lib/save-cwd.h, lib/savedir.h,
23331         lib/stdio-safer.h, lib/strtoimax.c, lib/strverscmp.h,
23332         lib/unistd-safer.h, lib/version-etc.h, lib/xalloc.h, lib/xreadlink.h,
23333         lib/xstrtod.h, lib/xstrtol.h: Likewise.
23334         * lib/filemode.h, lib/hard-locale.h, lib/memcoll.h, lib/modechange.h,
23335         lib/physmem.h, lib/same.h, lib/strverscmp.h: Do not include config.h;
23336         no longer needed. Anyway, config.h should always be included before any
23337         other file.
23338
23339 2003-06-11  Simon Josefsson  <jas@extundo.com>
23340
23341         * modules/sysexits: New file.
23342         * MODULES.html.sh (func_all_modules): Add sysexits.
23343
23344 2003-06-11  Simon Josefsson  <jas@extundo.com>
23345
23346         * lib/sysexit_.h: New file.
23347
23348 2003-06-11  Derek Price  <derek@ximbiot.com>
23349
23350         * lib/stat.c [LSTAT]: Compile/use slash_aware_lstat only if it is
23351         necessary.
23352
23353 2003-06-11  Bruno Haible  <bruno@clisp.org>
23354
23355         * m4/sysexits.m4: New file.
23356
23357 2003-06-10  Simon Josefsson  <jas@extundo.com>
23358
23359         * lib/argp.h: New file, from glibc.
23360         * lib/argp-ba.c: New file, from glibc.
23361         * lib/argp-eexst.c: New file, from glibc.
23362         * lib/argp-fmtstream.c: New file, from glibc.
23363         * lib/argp-fmtstream.h: New file, from glibc.
23364         * lib/argp-fs-xinl.c: New file, from glibc.
23365         * lib/argp-help.c: New file, from glibc.
23366         * lib/argp-namefrob.h: New file, from glibc.
23367         * lib/argp-parse.c: New file, from glibc.
23368         * lib/argp-pv.c: New file, from glibc.
23369         * lib/argp-pvh.c: New file, from glibc.
23370         * lib/argp-xinl.c: New file, from glibc.
23371
23372 2003-06-10  Simon Josefsson  <jas@extundo.com>
23373
23374         * modules/strchrnul: New file.
23375
23376 2003-06-10  Simon Josefsson  <jas@extundo.com>
23377
23378         * modules/argp: New file.
23379
23380 2003-06-10  Simon Josefsson  <jas@extundo.com>
23381
23382         * m4/strchrnul.m4: New file.
23383
23384 2003-06-10  Simon Josefsson  <jas@extundo.com>
23385
23386         * lib/strchrnul.h: New file.
23387         * lib/strchrnul.c: New file.
23388
23389 2003-06-10  Bruno Haible  <bruno@clisp.org>
23390
23391         * MODULES.html.sh (func_all_modules): Add strchrnul and argp.
23392
23393 2003-06-07  Karl Berry  <karl@gnu.org>
23394
23395         * config/config.{guess,sub}: update from prep.
23396
23397 2003-06-07  Jim Meyering  <jim@meyering.net>
23398
23399         * modules/strtod: Use $(...) notation, not @...@ for
23400         AC_REPLACE'd variables.
23401         * modules/localcharset: Likewise.
23402
23403 2003-06-07  Jim Meyering  <jim@meyering.net>
23404
23405         * lib/readtokens.h: Put `Free Software Foundation, Inc.'
23406         in place of my name in the copyright comment.
23407         Remove definition and uses of __P.
23408
23409         From coreutils.
23410         * lib/stat.c: Don't declare xmalloc explicitly.
23411         Instead, include "xalloc.h".
23412         * lib/readtokens.c (readtokens): Remove anachronistic casts of xmalloc,
23413         xrealloc, and xcalloc return values.
23414         * lib/xgetcwd.c (xgetcwd): Include "xgetcwd.h".
23415         Improve comment.
23416         * lib/xgetcwd.h: Remove definition/uses of PARAMS.
23417
23418 2003-06-07  Bruno Haible  <bruno@clisp.org>
23419
23420         * modules/poll (Makefile.am): Use explicit creation rule for poll.h, to
23421         avoid AC_CONFIG_LINKS.
23422         * modules/fnmatch (Makefile.am): Use explicit creation rule for
23423         fnmatch.h, to avoid AC_CONFIG_LINKS.
23424         * modules/alloca (Makefile.am): Make creation of alloca.h Ctrl-C safe.
23425
23426 2003-06-07  Bruno Haible  <bruno@clisp.org>
23427
23428         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH, gl_FUNC_FNMATCH_POSIX,
23429         gl_FUNC_FNMATCH_GNU): Set FNMATCH_H instead of invoking
23430         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
23431         directory.
23432         * m4/poll.m4 (gl_FUNC_POLL): Set POLL_H instead of invoking
23433         AC_CONFIG_LINKS. Needed to allow for a different name of the lib
23434         directory.
23435
23436 2003-06-06  Jim Meyering  <jim@meyering.net>
23437
23438         Merge from coreutils.
23439         * lib/same.c: (same_name): Declare *_basename locals to be `const'.
23440         Consolidate declarations and initializations of *_base* locals.
23441
23442         Merge from coreutils.
23443         This avoids a core dump on systems without GNU putenv,
23444         when running `env -u SOME_ALREADY_UNSET_VARIABLE'.
23445         * lib/putenv.c (__set_errno, LOCK, UNLOCK): Define.
23446         (unsetenv): New static function, from GNU libc.
23447         (rpl_putenv): Use it.
23448
23449         * lib/modechange.c: Remove trailing blanks.
23450
23451         Merge from coreutils.
23452         * lib/fsusage.c: Remove declaration of statfs.
23453         It conflicted with one from OSF/1 5.1 in <sys/mount.h>.
23454
23455         * lib/posixtm.c: Include <stdbool.h> unconditionally.
23456
23457 2003-06-06  Jim Meyering  <jim@meyering.net>
23458
23459         * lib/stdbool_.h: Renamed from stdbool.h.in.
23460
23461 2003-06-06  Jim Meyering  <jim@meyering.net>
23462             Bruno Haible  <bruno@clisp.org>
23463
23464         * modules/stdbool: Reflect renaming: stdbool.h.in -> stdbool_.h.
23465         Adjust Makefile.am snippet not to redirect directly to target.
23466         Use $(STDBOOL_H) notation, not @STDBOOL_H@ for AC_REPLACE'd variables.
23467
23468 2003-06-05  Paul Eggert  <eggert@twinsun.com>
23469
23470         * lib/mktime.c (__mktime_internal): When resolving a tm_isdst
23471         mismatch, look in future quarters as well as past.  This fixes a
23472         bug when processing fall-backwards gaps immediately after a long
23473         period of daylight-saving time.
23474
23475         * lib/mktime.c: Assume freestanding C89 or better.
23476         (HAVE_LIMITS_H): Remove.  Assume it's 1.
23477         (__P): Remove; not used.
23478         (CHAR_BIT, INT_MIN, INT_MAX): Remove; <limits.h> defines them.
23479         (mktime, not_equal_tm, print_tm, check_result,
23480         main): Use prototypes.  Use const * where appropriate.
23481         (main): Fix typo in testing code that uncovered by above changes.
23482         (Local Variables): Remove -DHAVE_LIMITS_H from compile-command.
23483
23484 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23485
23486         * m4/human.m4 (gl_HUMAN): Require AM_STDBOOL_H.  Check for
23487         locale.h, localeconv.  This merges changes from coreutils.
23488
23489         * m4/mktime.m4 (AC_FUNC_MKTIME): New macro, taken from Autoconf CVS.
23490         It can be removed after the next Autoconf is released.
23491         * m4/exclude.m4 (gl_EXCLUDE): Don't check for sys/types.h; no loner
23492         needed.
23493
23494 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23495
23496         * lib/mktime.c: Fix Debian bug 177940
23497         <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=177940>.
23498         (localtime_offset): Now long int, not time_t, because we want it
23499         to be guaranteed to be signed.  All uses changed.
23500         (__mktime_internal): If overflow would occur when adding offset,
23501         don't add it.
23502
23503         Merge 'human' changes from coreutils.  Rewrite to support
23504         locale-specific notations like thousands separators.
23505         * lib/human.c: Simplify authorship notice.
23506         Include human.h immediately after config.h.
23507         <sys/types.h>, <stdio.h>: Do not include; no longer needed.
23508         <limits.h>: Do not include, since human.h does.
23509         (SIZE_MAX, UINTMAX_MAX): New macros.
23510         <strings.h>: Include if HAVE_STRINGS_H, not if !HAVE_STRING_H.
23511         <locale.h>: Include if HAVE_LOCALE_H and HAVE_LOCALECONV.
23512         (HUMAN_READABLE_SUFFIX_LENGTH_MAX): New macro.
23513         (power_letter): Renamed from suffixes.
23514         (generate_suffix_backwards): Remove.
23515         (adjust_value): Now takes int style (because of human.h changes)
23516         and long double value (for greater precision on some platforms).
23517         (group_number): New function.
23518         (human_readable): Use it.  Use integer options, not enum.
23519         Put the options before the sizes in the arg list.
23520         Support all the new options.
23521         The old human_readable function has been removed;
23522         use inttostr.h instead.
23523         (human_readable, default_block_size, humblock):
23524         Use uintmax_t, not int, for block sizes.
23525         (human_readable_inexact, block_size_types): Remove.
23526         (block_size_opts): New constant.
23527         (human_options): Renamed from human_block_size, with new signature
23528         that allows block sizes up to UINTMAX_MAX.  All callers changed.
23529         * lib/human.h: Add copyright and authorship notice.
23530         Include <limits.h> and <stdbool.h> unconditionally.
23531         (PARAMS): Remove.  All uses removed.
23532         (LONGEST_HUMAN_READABLE): Add support for thousands separator.
23533         (enum human_inexact_style): Remove tag; now a nameless enum.
23534         (human_floor, human_ceiling, human_round_to_even): Now have
23535         values 2, 0, 1 rather than -1, 1, 0.
23536         (human_group_digits, human_suppress_point_zero, human_autoscale,
23537         human_base_1024, human_SI, human_B): New constants.
23538         (human_readable_inexact, human_block_size): Remove.
23539         (human_readable): Size args are now uintmax_t, not int.
23540         (human_options): New decl.
23541
23542         * lib/exclude.c: (new_exclude, add_exclude): Remove casts that are
23543         unnecessary now that we assume C89 or better.  This change
23544         imported from coreutils.
23545
23546         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
23547         arbitrarily.  This is the same patch as 2003-05-28, but it got lost
23548         in the 2003-05-30 sync from glibc.
23549
23550         .h files should stand alone, but we shouldn't include <sys/types.h>
23551         if we can get away with just <stddef.h>.
23552
23553         * lib/__fpending.h, addext.c, backupfile.c, exclude.c, getline.c,
23554         malloc.c, putenv.c, realloc.c, strcasecmp.c: Include <stddef.h>
23555         rather than <sys/types.h>, as we merely need size_t.
23556         * lib/dirname.h, memcoll.h, xalloc.h, xmemcoll.h: Include <stddef.h>,
23557         to get size_t.
23558         * lib/hash.h, linebuffer.h, readtokens.h, stdio-safer.h, version-etc.h:
23559         Include <stdio.h>, to get FILE.
23560         * lib/memcasecmp.c: Don't include <sys/types.h>, as we can assume
23561         memcasecmp.h has included <stddef.h> and all we need is size_t.
23562         * lib/memcoll.c: Include "memcoll.h", which gets us size_t and checks
23563         our interface, instead of including <sys/types.h>
23564
23565 2003-06-04  Paul Eggert  <eggert@twinsun.com>
23566
23567         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): Comment out for
23568         now, as glibc mktime is buggy on non-glibc systems.
23569
23570 2003-06-03  Karl Berry  <karl@gnu.org>
23571
23572         * config/config.sub: update from prep.
23573
23574 2003-06-02  Paul Eggert  <eggert@twinsun.com>
23575
23576         [from coreutils]
23577         Fix some minor time-related bugs with POSIX time arguments.
23578         Some valid time stamps were being rejected (notably -1, and
23579         time stamps before 1900 on 64-bit hosts).  And some invalid
23580         time stamps were being accepted, e.g. September 31.
23581
23582         * lib/posixtm.h (posixtime): Return bool instead of time_t, so
23583         that we can return (time_t) -1 successfully.
23584         * lib/posixtm.c: Likewise.
23585         [HAVE_STDBOOL_H]: Include <stdbool.h>.
23586         (bool, false, true) [!HAVE_STDBOOL_H]: New type.
23587         (t): Remove static var.
23588         (year, posix_time_parse): Now takes struct tm * arg to modify, instead
23589         of static var.  All uses changed.
23590         (year): Do not reject years before 1900; they can occur with
23591         64-bit time_t.
23592         (posix_time_parse): Do not check for out-of-range components;
23593         that is now the caller's responsibility, since our checks were
23594         only approximations.
23595         (posixtime): Use mktime to check for out-of-range components,
23596         since it knows them exactly.
23597         If mktime returns (time_t) -1, check whether an error actually occurred
23598         by invoking localtime on -1.
23599         (main) [TEST_POSIXTIME]: Check for input data errors, and report
23600         posixtime failures better.
23601         Improve the test data (in comments only).
23602
23603 2003-06-02  Karl Berry  <karl@gnu.org>
23604
23605         * config/mkinstalldirs (version): new variable.
23606         (--version): new option.
23607         (usage): improve message.
23608
23609 2003-05-30  Karl Berry  <karl@gnu.org>
23610
23611         * lib/mktime.c: update from libc.
23612
23613 2003-05-30  Bruno Haible  <bruno@clisp.org>
23614
23615         * modules/gettext: Add files m4/nls.m4 and m4/po.m4.
23616         * config/config.rpath: Upgrade to gettext-0.12.1.
23617
23618 2003-05-30  Bruno Haible  <bruno@clisp.org>
23619
23620         * m4/gettext.m4: Upgrade to gettext-0.12.1.
23621         * m4/nls.m4: New file, from gettext-0.12.1.
23622         * m4/po.m4: New file, from gettext-0.12.1.
23623         * m4/progtest.m4: Upgrade to gettext-0.12.1.
23624
23625 2003-05-30  Bruno Haible  <bruno@clisp.org>
23626
23627         * lib/config.charset: Upgrade to gettext-0.12.1 and libiconv-1.9.1.
23628         * lib/localcharset.h: Likewise.
23629         * lib/localcharset.c: Likewise.
23630
23631 2003-05-29  Karl Berry  <karl@gnu.org>
23632
23633         * config/config.rpath: update from gettext.
23634
23635 2003-05-28  Paul Eggert  <eggert@twinsun.com>
23636
23637         Assume the headers required for C89 freestanding compilers.
23638         * m4/backupfile.m4 (gl_BACKUPFILE): Don't check for limits.h.
23639         * m4/fsusage.m4 (gl_PREREQ_FSUSAGE_EXTRA): Likewise.
23640         * m4/human.m4 (gl_HUMAN): Likewise.
23641         * m4/pathmax.m4 (gl_PATHMAX): Likewise.
23642         * m4/rpmatch.m4 (gl_FUNC_RPMATCH): Likewise.
23643         * m4/userspec.m4 (gl_USERSPEC): Likewise.
23644         * m4/xreadlink.m4 (gl_XREADLINK): Likewise.
23645         * m4/xstrtol.m4 (gl_PREREQ_XSTRTOL): Likewise.
23646         * m4/quote.m4 (gl_QUOTE): Don't check for stddef.h.
23647
23648 2003-05-28  Paul Eggert  <eggert@twinsun.com>
23649
23650         Assume the headers required for C89 freestanding compilers.
23651         * lib/addext.c, lib/backupfile.c, lib/fsusage.c, lib/human.c,
23652         lib/pathmax.h, lib/rpmatch.c, lib/userspec.c, lib/xreadlink.c,
23653         lib/xstrtol.c: Include <limits.h> without checking for HAVE_LIMITS_H.
23654         * lib/backupfile.c, lib/fsusage.c, lib/hash.c, lib/human.c,
23655         lib/safe-read.c, lib/userspec.c, lib/xstrtol.c (CHAR_BIT): Don't
23656         define, since <limits.h> is guaranteed to do that.
23657         * lib/fatal.c: Include <stdarg.h> without checking for __STDC__.
23658         * lib/exclude.c: Include <stdbool.h> unconditionally.
23659         * lib/tempname.c: Include <stddef.h> unconditionally.
23660         * lib/hash.c: Include <limits.h>, since we no longer define CHAR_BIT.
23661         * lib/modechange.c, rpmatch.c (NULL): Don't define, since
23662         <stddef.h> does that.
23663         * lib/quote.c: Dont include <stddef.h> or <sys/types.h>; not needed.
23664         * lib/safe-read.c (INT_MAX): Don't define, since <limits.h> does that.
23665         * lib/safe-read.c (TYPE_MINIMUM, TYPE_MAXIMUM): Remove; no longer
23666         needed.
23667         * lib/xstrtol.c: Likewise.
23668         * lib/safe-read.c: Remove TYPE_SIGNED; no longer needed.
23669         * lib/savedir.c: Include <stddef.h> instead of defining NULL.
23670
23671         * lib/addext.c (addext): Use assignment rather than cast, to avoid
23672         warnings on some platforms.
23673
23674         * lib/mktime.c (__mktime_internal): Do not reject negative timestamps
23675         arbitrarily.
23676
23677 2003-05-26  Jim Meyering  <jim@meyering.net>
23678
23679         Merge in a change from coreutils:
23680         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Test the cache variable, not one
23681         that is guaranteed to be `no'.  Use `no_such_member' to indicate
23682         that condition, rather than `-1' which is slightly misleading.
23683         Change the name of the cache variable to have the gl_ prefix.
23684         Prompted by a patch from Richard Dawe for DJGPP.
23685
23686 2003-05-24  Karl Berry  <karl@gnu.org>
23687
23688         * config/config.guess: update from prep.
23689
23690 2003-05-22  Karl Berry  <karl@gnu.org>
23691
23692         * gnulib-tool (func_usage): =LIBRARY not =libRARY in help msg.
23693
23694 2003-05-20  Karl Berry  <karl@gnu.org>
23695
23696         * config/config.guess: update from prep.
23697
23698 2003-05-18  Karl Berry  <karl@gnu.org>
23699
23700         * config/srclistvars.sh (TEXMF): use TEXMFROOT instead, since TEXMF
23701         might actually be set by the user.
23702
23703         * config/depcomp, install-sh, mdate-sh: update from automake.
23704
23705 2003-05-17  Bruno Haible  <bruno@clisp.org>
23706
23707         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Fix a quoting bug leading to an
23708         invalid expansion for AC_EGREP_CPP.
23709         * m4/strtoimax.m4 (gl_FUNC_STRTOIMAX): Likewise.
23710         * m4/strtoumax.m4 (gl_FUNC_STRTOUMAX): Likewise.
23711         Suggested by Akim Demaille <akim@epita.fr> in
23712         http://mail.gnu.org/archive/html/bug-autoconf/2003-05/threads.html
23713
23714 2003-05-12  Jim Meyering  <jim@meyering.net>
23715
23716         * lib/strftime.c (my_strftime): Let the `-' (no-pad) flag affect
23717         the space-padded-by-default conversion specifiers, %e, %k, %l.
23718
23719 2003-05-12  Bruno Haible  <bruno@clisp.org>
23720
23721         * lib/linebreak.c (iconv_string_length): Don't return -1 just because
23722         the string is longer than 4 KB.
23723
23724 2003-05-11  Karl Berry  <karl@gnu.org>
23725
23726         * config/config.{guess,sub}: update from prep.
23727
23728 2003-05-09  Bruno Haible  <bruno@clisp.org>
23729
23730         * modules/error: Add m4/strerror_r.m4 to file list.
23731
23732 2003-05-03  Bruno Haible  <bruno@clisp.org>
23733
23734         Upgrade to Unicode-4.0.
23735         * lib/linebreak.c (nonspacing_table_data): Change width of U+00AD,
23736         U+0350..U+0357, U+035D..U+035F, U+0600..U+0603, U+0610..U+0615,
23737         U+0656..U+0658, U+0A01, U+0AE2..U+0AE3, U+0CBC, U+17B4..U+17B5,
23738         U+17DD, U+1920..U+1922, U+1927..U+192B, U+1932, U+1939..U+193B
23739         from 1 to 0. Change width of U+0CBF, U+0CC6, U+180E from 0 to 1.
23740         (uc_width): Change width of U+4DC0..U+4DFF from 2 to 1. Change width
23741         of U+2A6D7..U+2F7FF, U+2FA1E..U+2FFFD, U+30000..U+3FFFD from 1 to 2.
23742         Change width of U+E0100..U+E01EF from 1 to 0.
23743
23744 2003-04-25  Jim Meyering  <jim@meyering.net>
23745
23746         * lib/copy-file.c (copy_file_preserving): Declare buf_size to be
23747         of type size_t, not int.
23748
23749 2003-04-25  Bruno Haible  <bruno@clisp.org>
23750
23751         * lib/copy-file.c: Include <stddef.h>, for size_t.
23752
23753 2003-04-21  Paul Eggert  <eggert@twinsun.com>
23754
23755         * m4/error.m4 (gl_ERROR): Do not put under dynamic conditions some
23756         code which expansion is under static control.  Patch imported from
23757         Akim Demaille's patch to Bison; see
23758         <http://mail.gnu.org/archive/html/bison-patches/2003-03/msg00057.html>.
23759
23760 2003-04-14  Bruno Haible  <bruno@clisp.org>
23761
23762         * m4/error.m4 (jm_PREREQ_ERROR): Use AC_FUNC_VPRINTF.
23763
23764 2003-04-11  Jim Meyering  <jim@meyering.net>
23765
23766         Merge changes from Coreutils.
23767
23768         2003-03-22  Jim Meyering  <jim@meyering.net>
23769
23770         * lib/strftime.c (widen): Cast alloca return value to proper type.
23771
23772         2003-01-19  Ulrich Drepper  <drepper@redhat.com>
23773
23774         From GNU libc.
23775         * lib/strftime.c (my_strftime): Handle very large width
23776         specifications for numeric values correctly.  Improve checks for
23777         overflow.
23778
23779         2003-01-19  Jim Meyering  <jim@meyering.net>
23780
23781         * lib/strftime.c (widen) [COMPILE_WIDE]: Merge nearly-identical
23782         definitions.
23783         (nl_get_alt_digit) [! defined my_strftime]: Define.
23784         (my_strftime) [_NL_CURRENT]: Merge nearly-identical uses of
23785         _nl_get_alt_digit and _nl_get_walt_digit.
23786
23787         * lib/strftime.c (my_strftime): Merge in locale-related changes from
23788         libc. These changes have no effect outside of _LIBC.
23789
23790 2003-04-10  Bruno Haible  <bruno@clisp.org>
23791
23792         * modules/findprog: New file.
23793         * MODULES.html.sh (func_all_modules): Add it.
23794
23795 2003-04-10  Bruno Haible  <bruno@clisp.org>
23796
23797         * m4/findprog.m4: New file.
23798         * m4/eaccess.m4: New file.
23799
23800 2003-04-10  Bruno Haible  <bruno@clisp.org>
23801
23802         * lib/findprog.h: New file, from GNU gettext.
23803         * lib/findprog.c: New file, from GNU gettext.
23804
23805 2003-04-05  Jim Meyering  <jim@meyering.net>
23806
23807         Merge changes from Coreutils.
23808
23809         * lib/exclude.h (PARAMS): Remove definition and uses.
23810         * lib/exclude.c: Remove uses of `PARAMS'.
23811
23812         * lib/dirname.c [TEST_DIRNAME]: Update build instructions for test.
23813         Add test-cases for DOS filenames. Declare program_name.
23814         (main): Set up program_name.  Patch by Rich Dawe.
23815
23816         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Detect any
23817         error from mntctl.
23818         Use mntctl's return value to drive the entry-processing loop, since
23819         we can't rely on the value of the vmt_length member in the last
23820         entry.  On some systems doing so could result in exhausting
23821         virtual memory.  Based in part on a patch from Mike Jetzer.
23822
23823 2003-04-04  Bruno Haible  <bruno@clisp.org>
23824
23825         * modules/linebreak: New file.
23826         * MODULES.html.sh (func_all_modules): Add it.
23827
23828 2003-04-04  Bruno Haible  <bruno@clisp.org>
23829
23830         * m4/linebreak.m4: New file.
23831
23832 2003-04-04  Bruno Haible  <bruno@clisp.org>
23833
23834         * lib/linebreak.h: New file, from GNU gettext.
23835         * lib/linebreak.c: New file, from GNU gettext with slight
23836         modifications.
23837         * lib/lbrkprop.h: New file, from GNU gettext.
23838
23839 2003-04-03  Bruno Haible  <bruno@clisp.org>
23840
23841         * modules/utf8-ucs4: New file.
23842         * modules/utf16-ucs4: New file.
23843         * modules/ucs4-utf8: New file.
23844         * modules/ucs4-utf16: New file.
23845         * MODULES.html.sh (func_all_modules): Add them.
23846
23847 2003-04-03  Bruno Haible  <bruno@clisp.org>
23848
23849         * m4/utf-ucs4.m4: New file.
23850         * m4/ucs4-utf.m4: New file.
23851
23852 2003-04-03  Bruno Haible  <bruno@clisp.org>
23853
23854         * lib/utf8-ucs4.h: New file, from GNU gettext.
23855         * lib/utf16-ucs4.h: New file, from GNU gettext.
23856         * lib/ucs4-utf8.h: New file, from GNU gettext.
23857         * lib/ucs4-utf16.h: New file, from GNU gettext.
23858
23859 2003-04-02  Bruno Haible  <bruno@clisp.org>
23860
23861         * modules/binary-io: New file.
23862         * MODULES.html.sh (func_all_modules): Add it.
23863
23864 2003-04-02  Bruno Haible  <bruno@clisp.org>
23865
23866         * lib/binary-io.h: New file, from GNU gettext.
23867
23868 2003-04-01  Bruno Haible  <bruno@clisp.org>
23869
23870         * modules/pathname: New file.
23871         * MODULES.html.sh (func_all_modules): Add it.
23872
23873 2003-04-01  Bruno Haible  <bruno@clisp.org>
23874
23875         * lib/pathname.h: New file, from GNU gettext.
23876         * lib/concatpath.c: New file, from GNU gettext.
23877
23878 2003-03-30  Bruno Haible  <bruno@clisp.org>
23879
23880         * m4/copy-file.m4 (gl_COPY_FILE): Add check for chown().
23881
23882 2003-03-30  Bruno Haible  <bruno@clisp.org>
23883
23884         * lib/copy-file.c (copy_file_preserving): Don't set owner if the
23885         function chown() doesn't exist.
23886
23887 2003-03-28  Bruno Haible  <bruno@clisp.org>
23888
23889         * modules/copy-file: New file.
23890         * MODULES.html.sh (func_all_modules): Add it.
23891
23892 2003-03-28  Bruno Haible  <bruno@clisp.org>
23893
23894         * m4/copy-file.m4: New file.
23895
23896 2003-03-28  Bruno Haible  <bruno@clisp.org>
23897
23898         * lib/copy-file.h: New file, from GNU gettext.
23899         * lib/copy-file.c: New file, from GNU gettext.
23900
23901 2003-03-18  Jim Meyering  <jim@meyering.net>
23902
23903         * lib/quote.c (quote_n): Fix typo in comment.
23904
23905 2003-03-18  Bruno Haible  <bruno@clisp.org>
23906
23907         * m4/onceonly.m4: Use m4_defn instead of defn, for better error
23908         checking.
23909         * m4/onceonly_2_57.m4: Likewise.
23910
23911 2003-03-17  Bruno Haible  <bruno@clisp.org>
23912
23913         * m4/onceonly.m4: Require autoconf 2.54 or newer.
23914         (m4_quote): Remove macro.
23915         * m4/onceonly_2_57.m4: Require autoconf 2.54 or newer.
23916
23917 2003-03-14  Jim Meyering  <jim@meyering.net>
23918
23919         Merge changes from Coreutils.
23920         * lib/obstack.h (obstack_object_size): Declare temporary, __o,
23921         to be const, in order to avoid warnings.
23922         (obstack_room): Likewise.
23923         (obstack_empty_p): Likewise.
23924
23925 2003-03-14  Bruno Haible  <bruno@clisp.org>
23926
23927         * m4/onceonly_2_57.m4 (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE,
23928         AC_CHECK_DECLS_ONCE): Quote AC_FOREACH variable-expansions properly.
23929
23930 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23931
23932         Merge changes from Bison.
23933         * lib/obstack.h: (__INT_TO_PTR) [__STDC__]: Cast result to
23934         (void *) to avoid diagnostic with native c89 on SGI IRIX 6.5
23935         when compiling Bison 1.875's `bitset bset = obstack_alloc
23936         (bobstack, bytes);'.  Problem reported by Nelson H. F. Beebe.
23937         * lib/hash.c: Include <stdbool.h> unconditionally.
23938
23939 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23940
23941         * m4/onceonly.m4 (m4_quote): New macro.
23942         (AC_CHECK_HEADERS_ONCE, AC_CHECK_FUNCS_ONCE, AC_CHECK_DECLS_ONCE):
23943         Quote AC_FOREACH variable-expansions properly.
23944
23945 2003-03-13  Paul Eggert  <eggert@twinsun.com>
23946
23947         * doc/COPYING.DOC, fdl.texi: Sync with latest FSF version.
23948
23949 2003-03-09  Paul Eggert  <eggert@twinsun.com>
23950
23951         * lib/argmatch.c (EXIT_FAILURE): Define if the system doesn't.
23952         Reported by Bruce Becker; see:
23953         http://mail.gnu.org/archive/html/bug-bison/2003-03/msg00017.html
23954
23955 2003-03-03  Paul Eggert  <eggert@twinsun.com>
23956             Bruno Haible  <bruno@clisp.org>
23957
23958         * lib/mbswidth.h: Include <wchar.h>. Needed for UnixWare 7.1.1.
23959         Reported by John Hughes, see
23960         http://mail.gnu.org/archive/html/bug-bison/2003-02/msg00030.html
23961
23962 2003-02-20  Bruno Haible  <bruno@clisp.org>
23963
23964         * MODULES.html.sh (func_all_modules): Add poll.
23965
23966 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23967
23968         * modules/poll: New file.
23969
23970 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23971
23972         * lib/poll_.h: New file.
23973         * lib/poll.c: New file.
23974
23975 2003-02-19  Paolo Bonzini  <bonzini@gnu.org>
23976
23977         * m4/poll.m4: New file.
23978
23979 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23980
23981         * modules/mathl: New file.
23982
23983 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
23984
23985         * lib/mathl.h: New file.
23986         * lib/acosl.c: New file.
23987         * lib/asinl.c: New file.
23988         * lib/atanl.c: New file.
23989         * lib/ceill.c: New file.
23990         * lib/cosl.c: New file.
23991         * lib/expl.c: New file.
23992         * lib/floorl.c: New file.
23993         * lib/frexpl.c: New file.
23994         * lib/ldexpl.c: New file.
23995         * lib/logl.c: New file.
23996         * lib/sincosl.c: New file.
23997         * lib/sinl.c: New file.
23998         * lib/sqrtl.c: New file.
23999         * lib/tanl.c: New file.
24000         * lib/trigl.c: New file.
24001         * lib/trigl.h: New file.
24002
24003 2003-02-18  Paolo Bonzini  <bonzini@gnu.org>
24004
24005         * m4/mathl.m4: New file.
24006
24007 2003-02-18  Bruno Haible  <bruno@clisp.org>
24008
24009         * MODULES.html.sh (func_all_modules): Add mathl.
24010
24011 2003-02-17  Bruno Haible  <bruno@clisp.org>
24012
24013         * modules/mkdtemp: New module.
24014         * MODULES.html.sh (func_all_modules): Add it.
24015
24016 2003-02-17  Bruno Haible  <bruno@clisp.org>
24017
24018         * m4/mkdtemp.m4: New file, from GNU gettext with modifications.
24019
24020 2003-02-17  Bruno Haible  <bruno@clisp.org>
24021
24022         * lib/mkdtemp.h: New file, from GNU gettext.
24023         * lib/mkdtemp.c: New file, from GNU gettext.
24024
24025 2003-02-02  Jim Meyering  <jim@meyering.net>
24026
24027         * m4/regex.m4 (jm_INCLUDED_REGEX): Detect broken re_search in
24028         e.g. glibc-2.2.93.
24029
24030 2003-01-31  Bruno Haible  <bruno@clisp.org>
24031
24032         * m4/rename.m4 (vb_FUNC_RENAME): Add a redirection from 'rename' to
24033         'rpl_rename'.
24034         * m4/strnlen.m4 (gl_FUNC_STRNLEN): Add a redirection from 'strnlen' to
24035         'rpl_strnlen'.
24036         * m4/strtod.m4 (gl_FUNC_STRTOD): Add a redirection from 'strtod' to
24037         'rpl_strtod'.
24038         * m4/utime.m4 (jm_FUNC_UTIME): Add a redirection from 'utime' to
24039         'rpl_utime'.
24040
24041 2003-01-31  Bruno Haible  <bruno@clisp.org>
24042
24043         * lib/rename.c: #undef rename before defining rpl_rename.
24044         * lib/strnlen.c: #undef strnlen, define rpl_strnlen instead of strnlen.
24045
24046 2003-01-30  Bruno Haible  <bruno@clisp.org>
24047
24048         * modules/vasnprintf, modules/vasprintf: New modules.
24049         * MODULES.html.sh (func_all_modules): Add them.
24050
24051 2003-01-30  Bruno Haible  <bruno@clisp.org>
24052
24053         * m4/signed.m4: New file, from GNU gettext.
24054         * m4/longdouble.m4: New file, from GNU gettext.
24055         * m4/wchar_t.m4: New file, from GNU gettext.
24056         * m4/wint_t.m4: New file, from GNU gettext.
24057         * m4/vasnprintf.m4: New file.
24058         * m4/vasprintf.m4: New file.
24059
24060 2003-01-30  Bruno Haible  <bruno@clisp.org>
24061
24062         * lib/printf-args.h: New file, from GNU gettext.
24063         * lib/printf-args.c: New file, from GNU gettext.
24064         * lib/printf-parse.h: New file, from GNU gettext.
24065         * lib/printf-parse.c: New file, from GNU gettext.
24066         * lib/vasnprintf.h: New file, from GNU gettext.
24067         * lib/vasnprintf.c: New file, from GNU gettext.
24068         * lib/asnprintf.c: New file, from GNU gettext.
24069         * lib/vasprintf.h: New file, from GNU gettext with modifications.
24070         * lib/vasprintf.c: New file, from GNU gettext.
24071         * lib/asprintf.c: New file, from GNU gettext.
24072
24073 2003-01-29  Bruno Haible  <bruno@clisp.org>
24074
24075         * modules/stpncpy: New module.
24076         * MODULES.html.sh (func_all_modules): Add it.
24077
24078 2003-01-29  Bruno Haible  <bruno@clisp.org>
24079
24080         * m4/stpncpy.m4: New file.
24081
24082 2003-01-29  Bruno Haible  <bruno@clisp.org>
24083
24084         * lib/stpncpy.h: New file, from GNU gettext with modifications.
24085         * lib/stpncpy.c: New file, from GNU gettext with modifications.
24086
24087 2003-01-28  Bruno Haible  <bruno@clisp.org>
24088
24089         * modules/c-ctype: New module.
24090         * MODULES.html.sh (func_all_modules): Add it.
24091
24092 2003-01-28  Bruno Haible  <bruno@clisp.org>
24093
24094         * lib/c-ctype.h: New file, from GNU gettext, with changes suggested by
24095         Paul Eggert.
24096         * lib/c-ctype.c: New file, from GNU gettext, with changes suggested by
24097         Paul Eggert.
24098
24099 2003-01-27  Bruno Haible  <bruno@clisp.org>
24100
24101         * modules/xsetenv: New module.
24102         * MODULES.html.sh (func_all_modules): Add it.
24103
24104 2003-01-27  Bruno Haible  <bruno@clisp.org>
24105
24106         * lib/xsetenv.h: New file, from GNU gettext.
24107         * lib/xsetenv.c: New file, from GNU gettext.
24108
24109 2003-01-23  Jim Meyering  <jim@meyering.net>
24110
24111         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Correct typo: s/-1/no/ that kept this
24112         from working on systems without dirfd (at least Irix and OSF1/Tru64).
24113
24114 2003-01-23  Bruno Haible  <bruno@clisp.org>
24115
24116         * modules/minmax: New module.
24117         * MODULES.html.sh (func_all_modules): Add it.
24118
24119 2003-01-23  Bruno Haible  <bruno@clisp.org>
24120
24121         * lib/minmax.h: New file, from GNU gettext, with comments from Paul
24122         Eggert.
24123
24124 2003-01-22  Bruno Haible  <bruno@clisp.org>
24125
24126         * modules/exit: New module.
24127         * MODULES.html.sh (func_all_modules): Add it.
24128
24129 2003-01-22  Bruno Haible  <bruno@clisp.org>
24130
24131         * lib/exit.h: New file, from GNU gettext.
24132
24133 2003-01-19  Bruno Haible  <bruno@clisp.org>
24134
24135         * gnulib-tool: Recognize option --extract-maintainer.
24136         (func_get_maintainer): New function.
24137         * modules/*: Add Maintainer entry.
24138
24139 2003-01-16  Jim Meyering  <jim@meyering.net>
24140
24141         * m4/regex.m4: The `regex' struct is both input and output.
24142         Initialize it before each use.  Patch by Tim Waugh.
24143
24144 2003-01-16  Bruno Haible  <bruno@clisp.org>
24145
24146         * MODULES.html.sh: Add a table of contents. Add the module name as
24147         leftmost column. Add hyperlinks.
24148
24149 2003-01-15  Bruno Haible  <bruno@clisp.org>
24150
24151         * m4/md5.m4 (gl_MD5): Require AC_C_INLINE.
24152
24153 2003-01-15  Bruno Haible  <bruno@clisp.org>
24154
24155         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): Also test the LL suffix.
24156         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Also test the ULL
24157         suffix.
24158
24159 2003-01-15  Bruno Haible  <bruno@clisp.org>
24160
24161         * m4/alloca.m4 (gl_FUNC_ALLOCA): Invoke AC_EGREP_CPP prerequisites.
24162
24163 2003-01-15  Bruno Haible  <bruno@clisp.org>
24164
24165         * lib/stpcpy.h (stpcpy): Use ANSI C function declarations.
24166         * lib/strcase.h (strcasecmp, strncasecmp): Likewise.
24167
24168 2003-01-14  Jim Meyering  <jim@meyering.net>
24169
24170         * lib/same.c (same_name): Tweak a comment.
24171
24172 2003-01-14  Bruno Haible  <bruno@clisp.org>
24173
24174         * lib/same.c (same_name): Reorder tests so as to avoid calling stat()
24175         when a string comparison is sufficient.
24176
24177 2003-01-14  Bruno Haible  <bruno@clisp.org>
24178
24179         * lib/readtokens.c (readtoken): Cast character to 'unsigned char', not
24180         'unsigned int'.
24181
24182 2003-01-14  Bruno Haible  <bruno@clisp.org>
24183
24184         * lib/hash-pjw.c: Add comment about low quality of this function.
24185
24186 2003-01-13  Bruno Haible  <bruno@clisp.org>
24187
24188         * modules/stpcpy: Distribute lib/stpcpy.h.
24189         * modules/setenv: Depend on alloca. Distribute lib/setenv.h.
24190
24191 2003-01-13  Bruno Haible  <bruno@clisp.org>
24192
24193         * modules/*: Add a description.
24194         * modules/strpbrk: Fix Makefile.am snippet.
24195         * modules/strtoimax: Fix dependencies.
24196         * modules/strtoumax: Likewise.
24197
24198 2003-01-13  Bruno Haible  <bruno@clisp.org>
24199
24200         * gnulib-tool (func_create_testdir): Substitute lib_OBJECTS.
24201         * modules/alloca (Makefile.am): All object files depend on alloca.h.
24202         * modules/stdbool (Makefile.am): All object files depend on stdbool.h.
24203
24204 2003-01-13  Bruno Haible  <bruno@clisp.org>
24205
24206         * gnulib-tool (func_create_testdir): Store config/* files in the main
24207         directory.
24208         * config.rpath: Move to ...
24209         * config/config.rpath: ... here.
24210         * modules/gettext: Contains config/config.rpath, not config.rpath.
24211         * modules/iconv: Likewise.
24212
24213 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24214
24215         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24216         to avoid collisions with libcurses and libreadline.
24217
24218         * m4/getstr.m4: Remove.
24219         * m4/getline.m4 (gl_PREREQ_GETLINE): Require AC_HEADER_STDC.
24220
24221 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24222
24223         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24224         to avoid collisions with libcurses and libreadline.
24225
24226         * lib/Makefile.am (libfetish_a_SOURCES): Remove getstr.c, getstr.h.
24227         * lib/getstr.h, getstr.c: Remove.
24228         * lib/getline.c: Include "getline.h", to check interface.
24229         Move body of old getstr.c here: this defines MIN_CHUNK and
24230         declares getdelim2, which is renamed from getstr.
24231         (getline, getdelim): Adjust to renaming of getstr -> getdelim2.
24232
24233         * lib/linebuffer.c (readlinebuffer): Renamed from readline.
24234         All uses changed.
24235         * lib/linebuffer.h: Likewise.
24236         (readline): Remove backward-compatibility macro.
24237
24238 2003-01-12  Paul Eggert  <eggert@twinsun.com>
24239
24240         Finish renaming getstr -> getdelim2 and readline -> readlinebuffer,
24241         to avoid collisions with libcurses and libreadline.
24242         * getstr: Remove.
24243         * MODULES.html.sh: Remove getstr.
24244         * modules/getline: Depend on unlocked-io, not getstr.
24245
24246 2003-01-12  Jim Meyering  <jim@meyering.net>
24247
24248         * lib/makepath.c: Don't test HAVE_ERRNO_H.  It's not necessary.
24249
24250 2003-01-10  Bruno Haible  <bruno@clisp.org>
24251
24252         * modules/alloca: Change Makefile.am requirements. Simplify Include
24253         requirements. Add lib/alloca_.h to file list.
24254
24255 2003-01-10  Bruno Haible  <bruno@clisp.org>
24256
24257         * m4/alloca.m4 (gl_FUNC_ALLOCA): Also define ALLOCA_H.
24258
24259 2003-01-10  Bruno Haible  <bruno@clisp.org>
24260
24261         * lib/alloca_.h: New file.
24262         * lib/getdate.y: Unconditionally include alloca.h.
24263         * lib/makepath.c: Likewise.
24264         * lib/setenv.c: Likewise.
24265         * lib/userspec.c: Likewise.
24266
24267 2003-01-09  Karl Berry  <karl@gnu.org>
24268
24269         * MODULES.html.sh: include `dirname $0` in PATH, to find
24270         gnulib-tool.
24271
24272 2003-01-09  Bruno Haible  <bruno@clisp.org>
24273
24274         * modules/stdbool: Change configure.ac, Makefile.am requirements.
24275         Simplify Include requirements. Add lib/stdbool.h.in to file list.
24276
24277 2003-01-09  Bruno Haible  <bruno@clisp.org>
24278
24279         * m4/stdbool.m4 (AM_STDBOOL_H): New macro.
24280
24281 2003-01-09  Bruno Haible  <bruno@clisp.org>
24282
24283         * lib/stdbool.h.in: New file.
24284
24285 2003-01-09  Bruno Haible  <bruno@clisp.org>
24286
24287         * gnulib-tool (func_all_modules): Ignore files ending in ~.
24288         * MODULES.html.sh: Likewise.
24289
24290 2003-01-08  Jim Meyering  <jim@meyering.net>
24291
24292         * lib/full-write.c: Undefine and define-away `const' after inclusion
24293         of errno.h, not before.  Suggestion from Bruno Haible.
24294
24295 2003-01-08  Bruno Haible  <bruno@clisp.org>
24296
24297         * modules/full-read: Depend on full-write.
24298
24299 2003-01-08  Bruno Haible  <bruno@clisp.org>
24300
24301         * lib/safe-read.c: Include specification header first, to ensure its
24302         selfcontainedness.
24303         * lib/full-write.c: Likewise.
24304
24305 2003-01-07  Jim Meyering  <jim@meyering.net>
24306
24307         * lib/full-write.c: Rework so that it may serve to define full_read,
24308         too.
24309         * lib/full-read.c: Simply #define FULL_READ and include full-write.c.
24310
24311 2003-01-07  Bruno Haible  <bruno@clisp.org>
24312
24313         * lib/strtoimax.c: Include <stdint.h> as an alternative to
24314         <inttypes.h>.
24315         * lib/xstrtol.h: Likewise.
24316         * lib/xstrtoimax.c: Likewise.
24317         * lib/xstrtoumax.c: Likewise.
24318         * lib/human.h: Likewise.
24319
24320         * lib/tempname.c: Include <inttypes.h> too. Avoids a compilation error
24321         on systems that have <inttypes.h> but not <stdint.h>.
24322
24323 2003-01-07  Bruno Haible  <bruno@clisp.org>
24324
24325         * MODULES.html.sh: Add copyright notice.
24326         (missed_files): Omit CVS directory entries.
24327         (func_module): Make it work with sed-3.02.
24328         * MODULES.txt: Remove file.
24329
24330 2003-01-06  Jim Meyering  <jim@meyering.net>
24331
24332         * lib/version-etc.c: Update year in translatable copyright string.
24333
24334 2003-01-03  Karl Berry  <karl@gnu.org>
24335
24336         * config/config.{guess,sub}: update from prep.
24337
24338 2003-01-02  Karl Berry  <karl@gnu.org>
24339
24340         * doc/COPYING.DOC: belatedly updated to 1.2.
24341
24342 2003-01-01  Karl Berry  <karl@gnu.org>
24343
24344         * gnulib-tool (func_verify_module): report module name $module in
24345         error message, not $1.
24346         * gnulib-tool (create-testdir): don't complain if destdir couldn't
24347         be created, only if it doesn't exist.
24348         * gnulib-tool (last_checkin_date): don't expand the $Date here.
24349
24350 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24351
24352         * m4/memcoll.m4 (gl_MEMCOLL): Require AC_FUNC_MEMCMP.
24353
24354 2002-12-31  Paul Eggert  <eggert@twinsun.com>
24355
24356         * lib/memcoll.c (memcoll): Fall back on a simple algorithm using
24357         memcmp if strcoll doesn't work.
24358
24359 2002-12-31  Bruno Haible  <bruno@clisp.org>
24360
24361         * lib/utime.c (utime_null): No need to call ftruncate if the file was
24362         nonempty.
24363
24364 2002-12-31  Bruno Haible  <bruno@clisp.org>
24365
24366         * lib/memcoll.c (STRCOLL): New macro.
24367         (memcoll): Use it.
24368
24369 2002-12-31  Bruno Haible  <bruno@clisp.org>
24370
24371         * lib/localcharset.h: New file.
24372         * lib/localcharset.c: Include it.
24373         * lib/unicodeio.c: Likewise.
24374
24375 2002-12-31  Bruno Haible  <bruno@clisp.org>
24376
24377         * lib/getstr.h (getstr): Define, to avoid clash with libcurses.
24378         * lib/linebuffer.h (readline): Define, to avoid clash with libreadline.
24379
24380 2002-12-31  Bruno Haible  <bruno@clisp.org>
24381
24382         * lib/getline.h: Include <stddef.h>, for size_t.
24383
24384         * lib/unicodeio.h: Include <stddef.h>, for size_t.
24385         * lib/unicodeio.c: Don't include <stddef.h>.
24386
24387 2002-12-31  Bruno Haible  <bruno@clisp.org>
24388
24389         * lib/getdate.y (get_date): Test HAVE_STRUCT_TM_TM_ZONE, not
24390         HAVE_TM_ZONE.
24391
24392 2002-12-24  Karl Berry  <karl@gnu.org>
24393
24394         * config/config.guess: update from prep.
24395
24396 2002-12-24  Bruno Haible  <bruno@clisp.org>
24397
24398         General infrasructure.
24399         * m4/README: Rewritten.
24400         * m4/onceonly.m4: New file.
24401         * m4/onceonly_2_57.m4: New file.
24402
24403         Module atexit.
24404         * m4/atexit.m4: New file.
24405
24406         Module strtod.
24407         * m4/strtod.m4: New file.
24408
24409         Module strtol.
24410         * m4/strtol.m4: New file.
24411
24412         Module strtoul.
24413         * m4/strtoul.m4: New file.
24414
24415         Module memchr.
24416         * m4/memchr.m4: New file.
24417
24418         Module memcmp.
24419         * m4/memcmp.m4 (gl_PREREQ_MEMCMP): New macro.
24420         (jm_FUNC_MEMCMP): Invoke it.
24421
24422         Module memcpy.
24423         * m4/memcpy.m4: New file.
24424
24425         Module memmove.
24426         * m4/memmove.m4: New file.
24427
24428         Module memset.
24429         * m4/memset.m4: New file.
24430
24431         Module strcspn.
24432         * m4/strcspn.m4: New file.
24433
24434         Module strpbrk.
24435         * m4/strpbrk.m4: New file.
24436
24437         Module strstr.
24438         * m4/strstr.m4: New file.
24439
24440         Module strerror.
24441         * m4/strerror.m4: New file.
24442
24443         Module mktime.
24444         * m4/mktime.m4: Renamed from jm-mktime.m4.
24445         (gl_PREREQ_MKTIME): New macro.
24446         (gl_FUNC_MKTIME): Renamed from jm_FUNC_MKTIME. Invoke gl_PREREQ_MKTIME.
24447
24448         Module malloc.
24449         * m4/malloc.m4 (gl_PREREQ_MALLOC): New macro.
24450         (jm_FUNC_MALLOC): Use AC_FUNC_MALLOC. Invoke gl_PREREQ_MALLOC.
24451         Don't define HAVE_DONE_WORKING_MALLOC_CHECK, since nothing uses it.
24452
24453         Module realloc.
24454         * m4/realloc.m4 (gl_PREREQ_REALLOC): New macro.
24455         (jm_FUNC_REALLOC): Use AC_FUNC_REALLOC. Invoke gl_PREREQ_REALLOC.
24456         Don't define HAVE_DONE_WORKING_REALLOC_CHECK, since nothing uses it.
24457
24458         Module strftime.
24459         * m4/tm_gmtoff.m4: New file, extracted from strftime.m4.
24460         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Use AC_FUNC_STRFTIME.
24461         Don't test for bcopy (we are not emacs). Invoke AC_TYPE_MBSTATE_T and
24462         gl_TM_GMTOFF.
24463         (_jm_STRFTIME_PREREQS, jm_FUNC_GNU_STRFTIME): Use onceonly macros.
24464
24465         Module xalloc.
24466         * m4/xalloc.m4: New file.
24467
24468         Module alloca.
24469         * m4/alloca.m4: New file.
24470
24471         Module putenv.
24472         * m4/putenv.m4 (gl_PREREQ_PUTENV): New macro.
24473         (jm_FUNC_PUTENV): Invoke it.
24474
24475         Module setenv.
24476         * m4/setenv.m4 (gt_FUNC_SETENV): New macro.
24477         (gt_CHECK_VAR_DECL): Fix quoting error that led to infinite loop in m4
24478         when invoked twice.
24479         (gt_PREREQ_SETENV, gt_PREREQ_UNSETENV): New macros, replacing old
24480         gt_FUNC_SETENV.
24481
24482         Module memrchr.
24483         * m4/memrchr.m4: New file.
24484
24485         Module stpcpy.
24486         * m4/stpcpy.m4: New file.
24487
24488         Module strcase.
24489         * m4/strcase.m4: New file.
24490
24491         Module strdup.
24492         * m4/strdup.m4: New file.
24493
24494         Module strnlen.
24495         * m4/strnlen.m4: New file.
24496
24497         Module strndup.
24498         * m4/strndup.m4: New file.
24499
24500         Module xstrtod.
24501         * m4/xstrtod.m4: New file.
24502
24503         Module xstrtol.
24504         * m4/xstrtol.m4: New file.
24505
24506         Module getdate.
24507         * m4/getdate.m4: New file.
24508
24509         Module unlocked-io.
24510         * m4/unlocked-io.m4: Renamed from jm-glibc-io.m4.
24511         (jm_FUNC_GLIBC_UNLOCKED_IO): Invoke AC_GNU_SOURCE. Use onceonly macros.
24512         * m4/jm-glibc-io.m4n: Remove file.
24513
24514         Module long-options.
24515         * m4/long-options.m4: New file.
24516
24517         Module md5.
24518         * m4/md5.m4: New file.
24519
24520         Module sha.
24521         * m4/sha.m4: New file.
24522
24523         Module getstr.
24524         * m4/getstr.m4: New file.
24525
24526         Module getline.
24527         * m4/getline.m4 (gl_PREREQ_GETLINE): New macro.
24528         (AM_FUNC_GETLINE): Invoke AC_GNU_SOURCE. Use <stdlib.h>, not
24529         <sys/types.h>, for size_t. Use the function name gnu_getline, not
24530         simply getline. Infoke gl_PREREQ_GETLINE.
24531
24532         Module obstack.
24533         * m4/obstack.m4: New file.
24534
24535         Module hash.
24536         * m4/hash.m4: New file.
24537
24538         Module readtokens.
24539         * m4/readtokens.m4: New file.
24540
24541         Module strverscmp.
24542         * m4/strverscmp.m4: New file.
24543
24544         Module stdbool.
24545         * m4/stdbool.m4 (AC_HEADER_STDBOOL): Add test for _Bool. Needed for
24546         OSF/1.
24547
24548         Module strtoll.
24549         * m4/strtoll.m4: New file.
24550
24551         Module strtoull.
24552         * m4/strtoull.m4: New file.
24553
24554         Module strtoimax.
24555         * m4/strtoimax.m4: New file.
24556
24557         Module strtoumax.
24558         * m4/strtoumax.m4: New file.
24559
24560         Module xstrtoimax.
24561         * m4/xstrtoimax.m4 (jm_XSTRTOIMAX): Renamed from
24562         jm_AC_PREREQ_XSTRTOIMAX.
24563         Moved the strtol prerequisites to strtol.m4.
24564         Moved the strtoll prerequisites to strtoll.m4.
24565         Moved the strtoimax prerequisites to strtoimax.m4.
24566
24567         Module xstrtoumax.
24568         * m4/xstrtoumax.m4 (jm_XSTRTOUMAX): Renamed from
24569         jm_AC_PREREQ_XSTRTOUMAX.
24570         Moved the strtoul prerequisites to strtoul.m4.
24571         Moved the strtoull prerequisites to strtoull.m4.
24572         Moved the strtoumax prerequisites to strtoumax.m4.
24573
24574         Module chown.
24575         * m4/chown.m4 (gl_PREREQ_CHOWN): New macro.
24576         (jm_FUNC_CHOWN): Use AC_FUNC_CHOWN. Invoke gl_PREREQ_CHOWN.
24577
24578         Module dup2.
24579         * m4/dup2.m4: New file.
24580
24581         Module ftruncate.
24582         * m4/ftruncate.m4 (gl_PREREQ_FTRUNCATE): New macro.
24583         (jm_FUNC_FTRUNCATE): Use AC_REPLACE_FUNCS. Invoke gl_PREREQ_FTRUNCATE.
24584
24585         Module getgroups.
24586         * m4/getgroups.m4 (gl_PREREQ_GETGROUPS): New macro.
24587         (jm_FUNC_GETGROUPS): Use AC_FUNC_GETGROUPS. Invoke gl_PREREQ_GETGROUPS.
24588
24589         Module gettimeofday.
24590         * m4/gettimeofday.m4 (gl_PREREQ_GETTIMEOFDAY): New macro.
24591         (AC_FUNC_GETTIMEOFDAY_CLOBBER): Use onceonly macros. Invoke
24592         gl_PREREQ_GETTIMEOFDAY.
24593
24594         Module mkdir.
24595         * m4/mkdir-slash.m4 (gl_PREREQ_MKDIR): New macro.
24596         (UTILS_FUNC_MKDIR_TRAILING_SLASH): Invoke gl_PREREQ_MKDIR.
24597
24598         Module mkstemp.
24599         * m4/mkstemp.m4 (gl_PREREQ_MKSTEMP): New macro.
24600         (jm_PREREQ_TEMPNAME): New macro, from prereq.m4. Also invoke
24601         jm_AC_TYPE_UINTMAX_T.
24602         (UTILS_FUNC_MKSTEMP): Invoke gl_PREREQ_MKSTEMP and jm_PREREQ_TEMPNAME.
24603
24604         Module stat.
24605         * m4/stat.m4 (gl_PREREQ_STAT): New macro.
24606         (jm_FUNC_STAT): Use AC_FUNC_STAT. Invoke gl_PREREQ_STAT.
24607
24608         Module lstat.
24609         * m4/lstat.m4 (gl_PREREQ_LSTAT): New macro.
24610         (jm_FUNC_LSTAT): Use AC_FUNC_LSTAT. Invoke gl_PREREQ_LSTAT.
24611
24612         Module timespec.
24613         * m4/timespec.m4 (gl_TIMESPEC): New macro.
24614         (jm_CHECK_TYPE_STRUCT_TIMESPEC): Add check for <sys/time.h>.
24615         * m4/st_mtim.m4: Indentation.
24616
24617         Module nanosleep.
24618         * m4/nanosleep.m4 (gl_PREREQ_NANOSLEEP): New macro.
24619         (jm_FUNC_NANOSLEEP): Add check for <sys/time.h>. Invoke
24620         gl_PREREQ_NANOSLEEP.
24621
24622         Module regex.
24623         * m4/regex.m4 (jm_PREREQ_REGEX): New macro.
24624         (jm_INCLUDED_REGEX): Invoke jm_PREREQ_REGEX.
24625         (gl_REGEX): New macro.
24626
24627         Module rename.
24628         * m4/rename.m4 (gl_PREREQ_RENAME): New macro.
24629         (vb_FUNC_RENAME): Invoke gl_PREREQ_RENAME.
24630
24631         Module rmdir.
24632         * m4/rmdir.m4: New file.
24633
24634         Module utime.
24635         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Use onceonly macros.
24636         * m4/utime.m4 (gl_PREREQ_UTIME): New macro.
24637         (jm_FUNC_UTIME): Invoke gl_PREREQ_UTIME.
24638
24639         Module dirname.
24640         * m4/dirname.m4: New file.
24641
24642         Module getopt.
24643         * m4/getopt.m4: New file.
24644
24645         Module unistd-safer.
24646         * m4/unistd-safer.m4: New file.
24647
24648         Module fnmatch.
24649         * m4/fnmatch.m4 (_AC_FUNC_FNMATCH_IF): Include <stdlib.h>, for exit()
24650         declaration.
24651         (gl_PREREQ_FNMATCH_EXTRA): New macro.
24652         (gl_FUNC_FNMATCH_POSIX): New macro.
24653         (gl_FUNC_FNMATCH_GNU): Renamed from AC_FUNC_FNMATCH_GNU. Invoke
24654         gl_PREREQ_FNMATCH_EXTRA. Use the function name gnu_fnmatch, not
24655         simply fnmatch.
24656
24657         Module exclude.
24658         * m4/exclude.m4: New file.
24659
24660         Module human.
24661         * m4/human.m4: New file.
24662
24663         Module acl.
24664         * m4/acl.m4: Nop.
24665
24666         Module backupfile.
24667         * m4/backupfile.m4: New file.
24668         * m4/d-ino.m4: Indentation.
24669
24670         Module fsusage.
24671         * m4/fsusage.m4 (gl_FSUSAGE): New macro.
24672         (jm_STATFS_TRUNCATES): New macro, from coreutils-4.5.4/configure.ac.
24673         (gl_PREREQ_FSUSAGE_EXTRA): New macro.
24674
24675         Module dirfd.
24676         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Invoke some AC_EGREP_CPP
24677         requirements.
24678
24679         Module euidaccess.
24680         * m4/euidaccess.m4: New file.
24681
24682         Module file-type.
24683         * m4/file-type.m4: New file.
24684
24685         Module fileblocks.
24686         * m4/fileblocks.m4: New file.
24687
24688         Module filemode.
24689         * m4/filemode.m4: New file.
24690
24691         Module isdir.
24692         * m4/isdir.m4: New file.
24693
24694         Module lchown.
24695         * m4/lchown.m4 (gl_PREREQ_LCHOWN): New macro.
24696         (jm_FUNC_LCHOWN): Invoke gl_PREREQ_LCHOWN.
24697
24698         Module makepath.
24699         * m4/makepath.m4: New file.
24700
24701         Module modechange.
24702         * m4/modechange.m4: New file.
24703
24704         Module mountlist.
24705         * m4/mountlist.m4: New file.
24706         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Use onceonly macros.
24707         Indentation.
24708
24709         Module path-concat.
24710         * m4/path-concat.m4: New file.
24711
24712         Module pathmax.
24713         * m4/pathmax.m4: New file.
24714
24715         Module same.
24716         * m4/same.m4: New file.
24717
24718         Module save-cwd.
24719         * m4/save-cwd.m4: New file.
24720
24721         Module savedir.
24722         * m4/savedir.m4: New file.
24723
24724         Module xgetcwd.
24725         * m4/xgetcwd.m4: New file.
24726         * m4/getcwd.m4 (AC_FUNC_GETCWD_NULL): Use onceonly macros.
24727
24728         Module xreadlink.
24729         * m4/xreadlink.m4: New file.
24730
24731         Module safe-read.
24732         * m4/safe-read.m4: New file.
24733
24734         Module safe-write.
24735         * m4/safe-write.m4: New file.
24736
24737         Module closeout.
24738         * m4/closeout.m4: New file.
24739
24740         Module stdio-safer.
24741         * m4/stdio-safer.m4: New file.
24742
24743         Module getpass.
24744         * m4/getpass.m4: New file.
24745
24746         Module getugroups.
24747         * m4/getugroups.m4: New file.
24748
24749         Module group-member.
24750         * m4/group-member.m4 (gl_PREREQ_GROUP_MEMBER): New macro.
24751         (jm_FUNC_GROUP_MEMBER): Invoke AC_GNU_SOURCE, gl_PREREQ_GROUP_MEMBER.
24752
24753         Module idcache.
24754         * m4/idcache.m4: New file.
24755
24756         Module userspec.
24757         * m4/userspec.m4: New file.
24758
24759         Module gettime.
24760         * m4/clock_time.m4: New file.
24761         * m4/gettime.m4: New file.
24762
24763         Module settime.
24764         * m4/settime.m4: New file.
24765
24766         Module posixtm.
24767         * m4/posixtm.m4: New file.
24768
24769         Module gethostname.
24770         * m4/gethostname.m4: New file.
24771
24772         Module canon-host.
24773         * m4/canon-host.m4: New file.
24774
24775         Module gettext.
24776         * m4/codeset.m4: New file, from gettext-0.11.5.
24777         * m4/gettext.m4: New file, from gettext-0.11.5.
24778         * m4/glibc21.m4: New file, from gettext-0.11.5.
24779         * m4/iconv.m4: New file, from gettext-0.11.5.
24780         * m4/intdiv0.m4: New file, from gettext-0.11.5.
24781         * m4/inttypes-pri.m4: New file, from gettext-0.11.5.
24782         * m4/inttypes.m4: New file, from gettext-0.11.5.
24783         * m4/inttypes_h.m4: New file, from gettext-0.11.5 with modifications.
24784         * m4/isc-posix.m4: New file, from gettext-0.11.5.
24785         * m4/lcmessage.m4: New file, from gettext-0.11.5.
24786         * m4/lib-ld.m4: New file, from gettext-0.11.5.
24787         * m4/lib-link.m4: New file, from gettext-0.11.5.
24788         * m4/lib-prefix.m4: New file, from gettext-0.11.5.
24789         * m4/progtest.m4: New file, from gettext-0.11.5.
24790         * m4/stdint_h.m4: New file, from gettext-0.11.5 with modifications.
24791         * m4/uintmax_t.m4: New file, from gettext-0.11.5 with modifications.
24792         * m4/ulonglong.m4: New file, from gettext-0.11.5 with modifications.
24793
24794         Module localcharset.
24795         * m4/localcharset.m4: New file.
24796
24797         Module hard-locale.
24798         * m4/hard-locale.m4: New file.
24799
24800         Module mbswidth.
24801         * m4/mbswidth.m4 (gl_MBSWIDTH): Renamed from jm_PREREQ_MBSWIDTH. Use
24802         onceonly macros.
24803         * m4/mbrtowc.m4: Add comment.
24804
24805         Module memcasecmp.
24806         * m4/memcasecmp.m4: New file.
24807
24808         Module memcoll.
24809         * m4/memcoll.m4: New file.
24810
24811         Module unicodeio.
24812         * m4/unicodeio.m4: New file.
24813
24814         Module rpmatch.
24815         * m4/rpmatch.m4: New file.
24816
24817         Module yesno.
24818         * m4/yesno.m4: New file.
24819
24820         Module exitfail.
24821         * m4/exitfail.m4: New file.
24822
24823         Module c-stack.
24824         * m4/c-stack.m4 (gl_C_STACK): New macro.
24825         (jm_PREREQ_C_STACK): Check for <sys/time.h>. Use onceonly macros.
24826
24827         Module error.
24828         * m4/error.m4 (gl_ERROR): New macro.
24829         (jm_PREREQ_ERROR): Use onceonly macros.
24830
24831         Module fatal.
24832         * m4/fatal.m4: New file.
24833
24834         Module getloadavg.
24835         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Use onceonly macros.
24836         (gl_FUNC_GETLOADAVG, gl_PREREQ_GETLOADAVG): New macros.
24837
24838         Module getpagesize.
24839         * m4/getpagesize.m4: New file.
24840
24841         Module getusershell.
24842         * m4/getusershell.m4: New file.
24843
24844         Module physmem.
24845         * m4/physmem.m4: New file.
24846
24847         Module posixver.
24848         * m4/posixver.m4: New file.
24849
24850         Module quotearg.
24851         * m4/quotearg.m4: New file.
24852
24853         Module quote.
24854         * m4/quote.m4: New file.
24855
24856         Module readutmp.
24857         * m4/readutmp.m4: New file, based on jm_PREREQ_READUTMP from prereq.m4.
24858
24859         Module sig2str.
24860         * m4/sig2str.m4: New file.
24861
24862         Other.
24863         * m4/longlong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Remove, moved to
24864         ulonglong.m4.
24865         * m4/intmax_t.m4: New file.
24866         * m4/d-type.m4: Indentation.
24867         * m4/jm-macros.m4: Update.
24868         * m4/prereq.m4 (jm_PREREQ): Update.
24869         (jm_PREREQ_ADDEXT): Remove, obsoleted by backupfile.m4.
24870         (jm_PREREQ_CANON_HOST): Remove, obsoleted by canon-host.m4.
24871         (jm_PREREQ_DIRNAME): Remove, obsoleted by dirname.m4.
24872         (jm_PREREQ_EXCLUDE): Remove, obsoleted by exclude.m4.
24873         (jm_PREREQ_GETPAGESIZE): Remove, obsoleted by getpagesize.m4.
24874         (jm_PREREQ_HARD_LOCALE): Remove, obsoleted by hard-locale.m4.
24875         (jm_PREREQ_HASH): Remove, obsoleted by hash.m4.
24876         (jm_PREREQ_HUMAN): Remove, obsoleted by human.m4.
24877         (jm_PREREQ_MEMCHR): Remove, obsoleted by memchr.m4.
24878         (jm_PREREQ_PHYSMEM): Remove, obsoleted by physmem.m4.
24879         (jm_PREREQ_POSIXVER): Remove, obsoleted by posixver.m4.
24880         (jm_PREREQ_QUOTEARG): Remove, obsoleted by quotearg.m4.
24881         (jm_PREREQ_READUTMP): Remove, obsoleted by readutmp.m4.
24882         (jm_PREREQ_REGEX): Remove, obsoleted by regex.m4.
24883         (jm_PREREQ_STRNLEN): Remove, obsoleted by strnlen.m4.
24884         (jm_PREREQ_TEMPNAME): Remove, obsoleted by mkstemp.m4.
24885         (jm_PREREQ_XGETCWD): Remove, obsoleted by xgetcwd.m4.
24886         (jm_PREREQ_XREADLINK): Remove, obsoleted by xreadlink.m4.
24887         * m4/readdir.m4 (jm_FUNC_READDIR): Use onceonly macros.
24888
24889 2002-12-24  Bruno Haible  <bruno@clisp.org>
24890
24891         * MODULES.txt: Update according to m4/ changes.
24892
24893         Module gettext.
24894         * config.rpath: New file, from gettext-0.11.5.
24895
24896         * modules/*: New module descriptions.
24897         * gnulib-tool: New file.
24898         * MODULES.html.sh: New file.
24899
24900 2002-12-21  Karl Berry  <karl@gnu.org>
24901
24902         * doc/fdl.texi: update to version 1.2.
24903
24904 2002-12-19  Karl Berry  <karl@gnu.org>
24905
24906         * config/config.guess: update from prep.
24907
24908 2002-12-18  Bruno Haible  <bruno@clisp.org>
24909
24910         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't test for localtime_r.
24911         * m4/jm-mktime.m4 (jm_FUNC_MKTIME): Likewise.
24912
24913 2002-12-17  Bruno Haible  <bruno@clisp.org>
24914
24915         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Remove checks for limits.h,
24916         stdlib.h, string.h.
24917
24918 2002-12-17  Bruno Haible  <bruno@clisp.org>
24919
24920         * lib/canon-host.c (strdup): Remove unused declaration.
24921
24922         * lib/fsusage.c: Include full_read.h.
24923         (get_fs_usage): Use full_read instead of safe_read.
24924
24925         * lib/utime.c (utime_null): Use SAFE_READ_ERROR.
24926
24927 2002-12-12  Karl Berry  <karl@gnu.org>
24928
24929         * config/config.guess: update from prep.
24930
24931 2002-12-11  Bruno Haible  <bruno@clisp.org>
24932
24933         * m4/setenv.m4: New file, from gettext-0.11.5.
24934
24935 2002-12-11  Bruno Haible  <bruno@clisp.org>
24936
24937         * lib/setenv.h: Rewritten to cope with systems that have setenv() but
24938         not unsetenv().
24939         * lib/setenv.c, unsetenv.c: Taken from glibc-2.2.4 with the following
24940         modifications:
24941
24942         2002-12-11  Bruno Haible  <bruno@clisp.org>
24943
24944                 * setenv.c (alloca): Fall back to malloc.
24945                 (freea): New macro.
24946                 (setenv): Use freea() to free memory allocated with alloca().
24947
24948         2002-11-13  Bruno Haible  <bruno@clisp.org>
24949
24950                 * setenv.c (compar_fn_t, __add_to_environ, setenv): Use ANSI C
24951                 function declarations.
24952                 * unsetenv.c (unsetenv): Likewise.
24953
24954         2002-03-04  Bruno Haible  <bruno@clisp.org>
24955
24956                 Portability to AIX 4.3.3.
24957                 * unsetenv.c: New file, extracted from setenv.c.
24958                 * setenv.c: Move the unsetenv() function to unsetenv.c.
24959
24960         2001-12-20  Bruno Haible  <bruno@clisp.org>
24961
24962                 * setenv.c (__add_to_environ): Don't call realloc(NULL,...),
24963                 use malloc instead. For SunOS 4.
24964
24965         2001-12-11  Bruno Haible  <bruno@clisp.org>
24966
24967                 * setenv.c: Declare alloca.
24968                 (compar_fn_t): New typedef.
24969                 (KNOWN_VALUE, STORE_VALUE): Use it.
24970
24971         * lib/Makefile.am (libfetish_a_SOURCES): Add setenv.c, unsetenv.c,
24972         setenv.h.
24973
24974 2002-12-10  Paul Eggert  <eggert@twinsun.com>
24975
24976         Port exclude.c and exclude.h to more non-GNU systems, e.g. Solaris 7.
24977         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE, EXCLUDE_WILDCARDS):
24978         Choose values that are less likely to collide with system fnmatch
24979         options.
24980         * lib/exclude.c (FNM_CASEFOLD, FNM_LEADING_DIR): Define to 0 if not
24981         defined (e.g., a pure POSIX system).
24982         (EXCLUDE_macros_do_not_collide_with_FNM_macros): Use FNM_PATHNAME
24983         instead of FNM_FILE_NAME, for compatibility with pure POSIX sytems.
24984
24985 2002-12-06  Paul Eggert  <eggert@twinsun.com>
24986
24987         Undo the 2001-07-02 change for jm-glibc-io, as it was too much of
24988         a pain in practice to deal with generated m4 files.  This change
24989         goes together with the 2002-12-04 unlocked-io.h change in ../lib.
24990
24991         * m4/Makefile.am.in (Makefile.am): Don't mention jm-glibc-io.m4n
24992         and jm-glibc-io.m4, as they are no longer a special case.
24993         * m4/jm-glibc-io.m4: Rename from jm-glibc-io.m4n, and remove the
24994         kludge and the auto-generation stuff.  Check only whether the
24995         functions are declared, not whether they exist, since older hosts
24996         that don't declare the functions can't use the optimization anyway.
24997
24998 2002-12-06  Jim Meyering  <jim@meyering.net>
24999
25000         * lib/error.c: Be consistent: change `#ifndef _LIBC' to `#if !_LIBC'.
25001
25002         Merge in changes from libc's misc/error.c, in preparation
25003         for the merge of gnulib's changes back into libc.
25004
25005         * lib/error.c (_): Define only if not already defined.
25006         Move definition to follow all #include directives.
25007         Include unlocked-io.h only if !_LIBC.
25008         [_LIBC]: Include <libio/libioP.h>.
25009         [USE_IN_LIBIO]: Include <libio/iolibio.h>
25010         (fflush): Tweak definition to use INTUSE.
25011         (putc): Define.
25012
25013 2002-12-05  Paul Eggert  <eggert@twinsun.com>
25014
25015         * lib/alloca.c [defined emacs]: Include "lisp.h".
25016         (xalloc_die) [defined emacs]: New macro.
25017         (free) [defined emacs && defined EMACS_FREE]: Define to EMACS_FREE.
25018         [! defined emacs]: Include <xalloc.h>.
25019         (POINTER_TYPE) [!defined POINTER_TYPE]: New macro.
25020         (pointer): Typedef to POINTER_TYPE *.
25021         (malloc): Remove decl; we now always use xmalloc.
25022         (alloca): Use old-style definition, since Emacs needs this.
25023         Check for arithmetic overflow when computing combined size.
25024
25025 2002-12-04  Paul Eggert  <eggert@twinsun.com>
25026
25027         Do not generate unlocked-io.h automatically, since it's easier to
25028         maintain it by hand.
25029
25030         * lib/unlocked-io.h: New file, from GNU diffutils,
25031         but with proper copyright notice and attribution.
25032         * lib/gen-uio: Remove.
25033         * lib/Makefile.am: Add copyright notice.
25034         (libfetish_a_SOURCES): Add unlocked-io.h.
25035         (BUILT_SOURCES, all-local): Remove unlocked-io.h.
25036         (DISTCLEANFILES, io_functions): Remove macros.
25037         (EXTRA_DIST): Remove gen_uio.
25038         (unlocked-io.h): Remove rule.
25039
25040 2002-12-04  Jim Meyering  <jim@meyering.net>
25041
25042         Reflect the fact that stat.c and lstat.c are no longer generated.
25043         * lib/Makefile.am (BUILT_SOURCES): Remove stat.c and lstat.c.
25044         (DISTCLEANFILES): Likewise.
25045         (EXTRA_DIST): Likewise.
25046         (all_local): Don't depend on stat.c or lstat.c.
25047         (stat.c, lstat.c): Remove rules.
25048         (EXTRA_DIST): Remove xstat.in.
25049
25050         * lib/xstat.in: Remove file.  Contents moved into stat.c.
25051         * lib/stat.c: New file.  Contents mostly from xstat.in.
25052         * lib/stat.c: Rework so that it may serve to define rpl_lstat, too.
25053         * lib/lstat.c: New file. Simply #define LSTAT and include stat.c.
25054
25055         * lib/safe-read.c: Rework so that it may serve to define safe_write,
25056         too.
25057         * lib/safe-write.c: Simply #define SAFE_WRITE and include safe-read.c.
25058
25059 2002-12-03  Jim Meyering  <jim@meyering.net>
25060
25061         * lib/safe-read.c, safe-write.c: Change variable names and comments,
25062         but not semantics, to minimize the differences between these two files.
25063         (safe_read): Change comment to mention SAFE_READ_ERROR.
25064
25065         * lib/safe-read.c (IS_EINTR): Define.
25066         (safe_read): Use IS_EINTR in place of in-function cpp directives.
25067
25068 2002-12-02  Jim Meyering  <jim@meyering.net>
25069
25070         * lib/safe-read.c (EINTR): Define.
25071         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
25072         (INT_MAX): Provide fallback.
25073         (safe_read): Rewrite to iterate IFF the read fails with EINTR.
25074
25075         * lib/safe-read.h (SAFE_READ_ERROR): Define.
25076
25077 2002-12-02  Bruno Haible  <bruno@clisp.org>
25078
25079         * lib/safe-write.c (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM):
25080         Define, taken from safe-read.c.
25081         (INT_MAX): Provide fallback.
25082         (safe_write): Rewrite to iterate IFF the write fails with EINTR.
25083         * lib/safe-write.h (SAFE_WRITE_ERROR): Define.
25084
25085         * lib/safe-read.c (EINTR): Remove definition.
25086         (safe_read): Don't use EINTR if it is absent.
25087
25088 2002-12-01  Jim Meyering  <jim@meyering.net>
25089
25090         * lib/safe-read.c: (safe_read): Also exit the loop when read returns
25091         zero.
25092         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM, INT_MAX): Define.
25093
25094 2002-11-27  Paul Eggert  <eggert@twinsun.com>
25095
25096         * lib/hash.c (hash_lookup, hash_get_first, hash_get_next,
25097         hash_find_entry, hash_rehash): Replace `if (limit <= value) abort ();'
25098         with `if (! (value < limit)) abort ();', for readability.
25099
25100 2002-11-26  Karl Berry  <karl@gnu.org>
25101
25102         * lib/strdup.c: copy from libc again, with jim's ok.
25103         * lib/.cppi-disable: re-add strdup.c
25104
25105 2002-11-25  Karl Berry  <karl@gnu.org>
25106
25107         * lib/strtoll.c: copy from libc, meaning we now #include <strtol.c>
25108         instead of "strtol.c".
25109
25110 2002-11-25  Karl Berry  <karl@gnu.org>
25111
25112         * config/install-sh: update from automake for variable quoting, $0 in
25113         error msgs, etc.
25114
25115         * config/srclist.txt ($LIBCSRC/time/mktime.c lib gpl): new entry.
25116         * config/srclist.txt ($LIBCSRC/sysdeps/generic/strtoll.c lib gpl): new
25117         entry.
25118
25119 2002-11-25  Jim Meyering  <jim@meyering.net>
25120
25121         * lib/mktime.c: Sync from libc, now that it has the latest fix.
25122
25123 2002-11-24  Karl Berry  <karl@gnu.org>
25124
25125         * lib/error.c, getopt.c, getopt.h, getopt1.c, obstack.c, regex.c,
25126         regex.h, strdup.c, strtoll.c, tempname.c: change license to gpl.
25127
25128 2002-11-24  Jim Meyering  <jim@meyering.net>
25129
25130         Update from coreutils:
25131
25132         * lib/mktime.c: Merge in changes from libc.
25133
25134         Avoid a link-time failure on some Linux systems.
25135         * lib/mktime.c (STATIC): Define to be empty (_LIBC) or `static'
25136         (otherwise).
25137         (__mon_yday): Declare with the STATIC attribute.
25138         (__mktime_internal): Likewise.
25139         Based on a report from Greg Schafer.
25140
25141 2002-11-23  Jim Meyering  <jim@meyering.net>
25142
25143         * lib/sig2str.c (str2signum, sig2str): Avoid a warning from gcc:
25144         Use `unsigned', not `int', as type of index.
25145
25146         * lib/xstat.in [@BEGIN_LSTAT_ONLY@]: Include <string.h>.
25147
25148         * lib/fsusage.c: Remove unneeded parentheses around operands of
25149         `defined'.
25150
25151 2002-11-22  Paul Eggert  <eggert@twinsun.com>
25152
25153         * lib/quotearg.h: Allow multiple inclusion by surrounding with
25154         "#ifndef QUOTEARG_H_".  Include <stddef.h>, for size_t,
25155         so that we can be included first.
25156         (PARAMS): Remove; we now assume C89 or later.  All uses removed.
25157         * lib/quotearg.c: Include quotearg.h immediately after config.h.
25158         No need to include stddef.h or sys/types.h any more.
25159         Surround local include files with "", not "<>".
25160         Assume HAVE_LIMITS_H unconditionally, as we assume C89.
25161         Similarly, assume HAVE_C_BACKSLASH_A, CHAR_BIT, UCHAR_MAX, UINT_MAX,
25162         HAVE_STDLIB_H, HAVE_STRING_H, STDC_HEADERS.
25163         (HAVE_MBSINIT): Undef if !HAVE_MBRTOWC.
25164         (mbsinit): Define to 1 if !defined mbsinit && !HAVE_MBSINIT.
25165         (ISPRINT): Remove; no longer needed now that we assume C89.
25166
25167         (clone_quoting_options, quotearg_buffer, quotearg_n_options):
25168         Preserve errno.
25169
25170         (quotearg_buffer_restyled, quotearg_n, quotearg_n_style,
25171         quotearg_char): Use SIZE_MAX rather than
25172         (size_t) -1 when we are talking about "infinity".
25173
25174         (quotearg_buffer_restyled): Fix bug when quoting trigraphs.
25175
25176 2002-11-22  Paul Eggert  <eggert@twinsun.com>
25177
25178         * lib/hash.c: Avoid use of <assert.h>, as the GNU Coding Standards
25179         hint that one should use `if (! x) abort ();' rather than `assert
25180         (x);', and anyway it's one less thing to worry about configuring.
25181         (hash_lookup, hash_get_first, hash_get_next, hash_find_entry,
25182         hash_rehash, hash_insert): Use abort rather than assert.
25183
25184 2002-11-22  Bruno Haible  <bruno@clisp.org>
25185
25186         * lib/safe-read.h: Assume C89. Add comments.
25187         (safe_read): Change return type to size_t.
25188         * lib/safe-read.c (safe_read): Change return type to size_t. Handle
25189         byte counts > SSIZE_MAX correctly.
25190         * lib/safe-write.h: New file.
25191         * lib/safe-write.c: New file.
25192         * lib/full-read.h: New file.
25193         * lib/full-read.c: New file.
25194         * lib/full-write.h: Assume C89. Add comments.
25195         * lib/full-write.c: Include safe-write.h.
25196         (full_write): Rewritten to use safe_write.
25197         Suggested by Jim Meyering and Paul Eggert.
25198
25199 2002-11-21  Jim Meyering  <jim@meyering.net>
25200
25201         * lib/strdup.c (strdup): Tweak comment and initial #if/#include.
25202
25203         Merge in changes from the coreutils.
25204
25205         2002-09-25  Paul Eggert  <eggert@twinsun.com>
25206         * lib/fsusage.c [! HAVE_INTTYPES_H && HAVE_STDINT_H] Include
25207         <stdint.h>.
25208         (UINTMAX_MAX) [!defined UINTMAX_MAX]: New macro.
25209         (PROPAGATE_ALL_ONES): Work even if X is unsigned and narrower than
25210         int.  Work more efficiently if X is the same width as uintmax_t.
25211         Do not compare X to -1, to avoid bogus compiler warning.
25212         (get_fs_usage): (uintmax_t) -1 -> UINTMAX_MAX to avoid a cast.
25213         Don't assume that f_frsize and f_bsize are the same type.
25214
25215         * lib/mountlist.c: #undef MNT_IGNORE before defining it, to avoid
25216         warning on FreeBSD.
25217
25218         * lib/makepath.c (make_path): Restore umask *before* creating the final
25219         component.
25220         (make_path): Minor reformatting.
25221
25222         * lib/xmalloc.c: Adjust to work with new autoconf macros,
25223         AC_FUNC_MALLOC and AC_FUNC_REALLOC: test #ifndef
25224         HAVE_MALLOC/HAVE_REALLOC.
25225
25226         * lib/mountlist.h (ME_DUMMY): Don't count entries of type `auto' as
25227         dummy ones.  At least on GNU/Linux systems, `auto' means something
25228         else.
25229         From Michael Stone.
25230
25231 2002-11-21  Bruno Haible  <bruno@clisp.org>
25232
25233         Remove case insensitive option matching.
25234         * lib/argmatch.h (argcasematch): Remove declaration.
25235         (ARGCASEMATCH): Remove macro.
25236         (__xargmatch_internal): Remove case_sensitive argument.
25237         (XARGMATCH): Update.
25238         (XARGCASEMATCH): Remove macro.
25239         * lib/argmatch.c (argmatch): Renamed from __argmatch_internal. Remove
25240         case_sensitive argument.
25241         (argcasematch): Remove function.
25242         (__xargmatch_internal): Remove case_sensitive argument.
25243         (main): Use XARGMATCH instead of XARGCASEMATCH.
25244
25245         * lib/xmalloc.c: Change compile-time error message. Add comment about
25246         required autoconf version.
25247
25248 2002-11-20  Paul Eggert  <eggert@twinsun.com>
25249
25250         Merge argmatch cleanups from Bison.  Assume C89.
25251
25252         * lib/argmatch.c: Include config.h here, not in argmatch.h.
25253         Include stdlib.h, for EXIT_FAILURE.
25254         Always include <string.h>, since we assume C89.
25255         (EXIT_FAILURE): Remove pre-C89 bug workaround.
25256         * lib/argmatch.h: Do not include <config.h> or <sys/types.h>.
25257         Include <stddef.h> instead, since it's all we need for size_t.
25258         (PARAMS): Remove.  All uses removed.
25259         (ARRAY_CARDINALITY): Do not bother to #undef.
25260         (ARRAY_CARDINALITY, ARGMATCH, ARGCASEMATCH, invalid_arg,
25261         ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25262         Remove unnecessary parentheses.
25263         (ARGMATCH_VALID, XARGMATCH, XARGCASEMATCH):
25264         Insert necessary parentheses.
25265         (ARGMATCH_CONSTRAINT, ARGMATCH_VERIFY): New macros.
25266         (ARGMATCH_ASSERT): Use ARGMATCH_CONSTRAINT.
25267
25268 2002-11-19  Bruno Haible  <bruno@clisp.org>
25269
25270         * lib/mbswidth.c: Include mbswidth.h right at the beginning.
25271         * lib/mbswidth.h: Include <stddef.h>, for size_t.
25272
25273         * lib/mbswidth.h (PARAMS): Remove macro.
25274         (mbswidth, mbsnwidth): Use ANSI C function declarations.
25275         * lib/mbswidth.c (mbswidth, mbsnwidth): Likewise.
25276
25277         * lib/gcd.h (PARAMS): Remove macro.
25278         (gcd): Use ANSI C function declarations.
25279         * lib/gcd.c (gcd): Likewise.
25280
25281 2002-11-15  Bruno Haible  <bruno@clisp.org>
25282
25283         * lib/strcspn.c: Include <stddef.h>.
25284         (strcspn): Use ANSI C function declaration. Change return type to
25285         size_t. Use NULL.
25286         * lib/strpbrk.c: Minimize diffs to glibc. Include <stddef.h>.
25287         (strpbrk): Use NULL.
25288         * lib/strpbrk.h (PARAMS): Remove macro.
25289         (strpbrk): Use ANSI C function declaration.
25290         * lib/strstr.c: Don't include <sys/types.h>.
25291         * lib/strstr.h (PARAMS): Remove macro.
25292         (strstr): Use ANSI C function declarations.
25293
25294 2002-11-14  Karl Berry  <karl@gnu.org>
25295
25296         * config/mkinstalldirs: `do' on separate line, instead of
25297         `for var; do'.
25298
25299 2002-11-06  Bruno Haible  <bruno@clisp.org>
25300
25301         * lib/gcd.h (gcd): Change argument type to 'unsigned long'.
25302         * lib/gcd.c (gcd): Likewise.
25303
25304 2002-11-05  Bruno Haible  <bruno@clisp.org>
25305
25306         * lib/gcd.h: New file, from gettext-0.11.5.
25307         * lib/gcd.c: New file, from gettext-0.11.5.
25308
25309 2002-11-05  Bruno Haible  <bruno@clisp.org>
25310
25311         * lib/error.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25312         * lib/getopt.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25313         * lib/obstack.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25314         * lib/regex.c [!_LIBC]: Include gettext.h instead of <libintl.h>.
25315
25316         * lib/argmatch.c: Include gettext.h instead of <locale.h> and
25317         <libintl.h>.
25318         * lib/makepath.c: Include gettext.h instead of <locale.h> and
25319         <libintl.h>.
25320
25321         * lib/closeout.c: Include gettext.h instead of <libintl.h>.
25322         * lib/human.c: Include gettext.h instead of <libintl.h>.
25323         * lib/quotearg.c: Include gettext.h instead of <libintl.h>.
25324         * lib/rpmatch.c: Include gettext.h instead of <libintl.h>.
25325         * lib/unicodeio.c: Include gettext.h instead of <libintl.h>.
25326         * lib/userspec.c: Include gettext.h instead of <libintl.h>.
25327         * lib/version-etc.c: Include gettext.h instead of <libintl.h>.
25328         * lib/xmalloc.c: Include gettext.h instead of <libintl.h>.
25329         (textdomain): Remove definition.
25330         * lib/xmemcoll.c: Include gettext.h instead of <libintl.h>.
25331
25332         * lib/long-options.c: Remove include of <libintl.h> and definition of
25333         _.
25334         * lib/same.c: Remove include of <libintl.h> and definition of _.
25335
25336 2002-11-04  Owen Taylor  <otaylor@redhat.com>
25337
25338         * lib/config.charset: A few additions for Solaris.
25339
25340 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25341
25342         Make it possible to build libcharset with CC=gcc CFLAGS="-x c++".
25343         * lib/localcharset.c (locale_charset): Declare as extern "C".
25344
25345 2002-11-04  Bruno Haible  <haible@clisp.cons.org>
25346
25347         * lib/config.charset: msdos in uk_UA uses CP1125.
25348
25349 2002-11-04  Bruno Haible  <bruno@clisp.org>
25350
25351         * lib/stpcpy.h: New file, from GNU gettext-0.11.5.
25352         * lib/strcase.h: New file, from GNU gettext-0.11.5.
25353         * lib/strpbrk.h: New file, from GNU gettext-0.11.5.
25354         * lib/strstr.h: New file, from GNU gettext-0.11.5.
25355         * lib/xgetcwd.h: New file, from GNU gettext-0.11.5.
25356
25357 2002-11-04  Bruno Haible  <bruno@clisp.org>
25358
25359         * lib/localcharset.c (locale_charset): Don't return an empty string.
25360
25361 2002-11-04  Bruno Haible  <bruno@clisp.org>
25362
25363         * lib/localcharset.c (get_charset_aliases): Add more Windows specific
25364         aliases.
25365
25366 2002-11-04  Bruno Haible  <bruno@clisp.org>
25367
25368         * lib/config.charset: Update for newest glibc. Add canonical names
25369         ISO-8859-14, KOI8-T, TCVN5712-1, GEORGIAN-PS.
25370
25371 2002-11-04  Bruno Haible  <bruno@clisp.org>
25372
25373         * lib/config.charset: Add support for NetBSD.
25374
25375 2002-11-04  Bruno Haible  <bruno@clisp.org>
25376
25377         * lib/config.charset [msdosdjgpp]: For Russian, use CP866.
25378
25379 2002-11-01  Bruno Haible  <bruno@clisp.org>
25380
25381         * configure.in: Add AC_CONFIG_AUX_DIR call.
25382         (AC_OUTPUT): Add m4/Makefile, lib/Makefile. Remove doc/Makefile,
25383         test/Makefile.
25384         * Makefile.in (subdirs): Add m4, lib. Remove doc, test.
25385
25386 2002-09-28  Karl Berry  <karl@gnu.org>
25387
25388         * config/srclist.txt: can't copy install-sh/mkinstalldirs from
25389         installed automake until the next release, since changes have been
25390         made.
25391
25392 2002-09-25  Karl Berry  <karl@gnu.org>
25393
25394         * lib/strdup.c: copy from libc/string (via ../config/srclist*).
25395         * lib/getopt*: copy from libc/posix.
25396         * lib/gettext.h: copy from gettext.
25397         * lib/.cppi-disable: add strdup.c, gettext.h.
25398
25399 2002-09-25  Karl Berry  <karl@gnu.org>
25400
25401         * config/srclist.txt: enable gettext.h check.
25402         * config/config.{guess,sub}: update from prep.
25403         * config/depcomp, install-sh, mdate-sh, missing, mkinstalldirs: update
25404                 from automake 1.6.3.
25405         See srclist*.
25406
25407 2002-08-23  Stefan Monnier  <monnier@cs.yale.edu>
25408
25409         * regex.c (PATFETCH): Remove the translating fetch.
25410         (PATFETCH_RAW): Rename to PATFETCH.
25411         (set_image_of_range): New fun.
25412         (SET_RANGE_TABLE_WORK_AREA): Use it.
25413         (regex_compile): Don't translate the pattern chars so eagerly.
25414         Only do it when inserting an `exactn' bytecode or when handling
25415         a char-range.
25416         (mutually_exclusive_p): Avoid empty statement.
25417
25418 2002-07-06  Jim Meyering  <meyering@lucent.com>
25419
25420         * m4/README: Don't mention Makefile.am.in.
25421         Outline how I've tested changes to .m4 files.  Yep, it's a pain.
25422
25423 2002-07-01  Jim Meyering  <meyering@lucent.com>
25424
25425         * lib/c-stack.c: Include sys/time.h.
25426         From Volker Borchert.
25427
25428 2002-06-26  Paul Eggert  <eggert@twinsun.com>
25429
25430         * m4/fnmatch.m4 (_AC_LIBOBJ_FNMATCH): Check for btowc.
25431
25432 2002-06-26  Paul Eggert  <eggert@twinsun.com>
25433
25434         * lib/fnmatch.c, fnmatch_loop.c (WIDE_CHAR_SUPPORT):
25435         New macro.  Use it uniformly instead of
25436         (defined HAVE_WCTYPE_H && defined HAVE_WCHAR_H).
25437         It also uses HAVE_BTOWC, to fix a porting bug on Solaris 2.5.1
25438         reported by Vin Shelton.
25439
25440 2002-06-22  Paul Eggert  <eggert@twinsun.com>
25441
25442         * lib/c-stack.h (segv_handler, c_stack_action) [! defined SA_SIGINFO]:
25443         Do not assume SA_SIGINFO behavior.
25444         Bug reported by Jim Meyering on NetBSD 1.5.2.
25445
25446 2002-06-22  Jim Meyering  <meyering@lucent.com>
25447
25448         * m4/c-stack.m4: New file, from diffutils-2.8.2.
25449         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_C_STACK.
25450
25451         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Don't require AC__GNU_SOURCE,
25452         now that configure.ac uses AC_GNU_SOURCE.
25453         (jm_MACROS): Rename: jm_FUNC_FNMATCH to AC_FUNC_FNMATCH_GNU.
25454         * m4/prereq.m4 (jm_PREREQ_EXCLUDE): Likewise, wrt jm_FUNC_FNMATCH.
25455
25456         Update to latest tools.  Suggestions from Paul Eggert.
25457         * m4/stdbool.m4: New file, from diffutils-2.8.2.
25458         * m4/gnu-source.m4: Update from diffutils-2.8.2.
25459         * m4/fnmatch.m4: Likewise.
25460         * m4/prereq.m4: Change each use of AC_CHECK_HEADERS(stdbool.h)
25461         to AC_HEADER_STDBOOL
25462
25463 2002-06-22  Jim Meyering  <meyering@lucent.com>
25464
25465         * lib/fnmatch.c (ISASCII, ISPRINT): Undefine, to avoid warning about
25466         redefinition due to Solaris 2.6's definition in /usr/include/sys/euc.h.
25467
25468 2002-06-22  Jim Meyering  <meyering@lucent.com>
25469
25470         * lib/c-stack.c, lib/c-stack.h: New files, from diffutils-2.8.2.
25471
25472         * lib/exitfail.c, exitfail.h: Likewise.
25473         * lib/Makefile.am (libfetish_a_SOURCES): Add exitfail.c and exitfail.h.
25474
25475         * lib/Makefile.am (libfetish_a_SOURCES): Add fnmatch_.h in place
25476         of fnmatch.h.
25477         (EXTRA_DIST): Add fnmatch_loop.c.
25478         (libfetish_a_SOURCES): Add c-stack.c and c-stack.h.
25479
25480         * lib/fnmatch_loop.c: New file, from diffutils-2.8.2.
25481         * lib/fnmatch.c: Update from diffutils-2.8.2.
25482         * lib/fnmatch_.h: New file.  From diffutils-2.8.2.
25483         * lib/fnmatch.h: Remove file.
25484
25485 2002-06-21  Jim Meyering  <meyering@lucent.com>
25486
25487         * m4/c-bs-a.m4: Add comment, from diffutils-2.8.2.
25488         * m4/mbrtowc.m4: Likewise.
25489
25490         * m4/mbstate_t.m4: Update from diffutils-2.8.2.
25491         * m4/mbswidth.m4: Reflect name change:
25492         s/AC_MBSTATE_T/AC_TYPE_MBSTATE_T.
25493         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
25494
25495         * m4/lib-link.m4: Update from gettext-0.11.2.
25496         * m4/gettext.m4: Likewise.
25497
25498         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for hurd.h.
25499         From Alfred M. Szmidt.
25500
25501 2002-06-18  Paul Eggert  <eggert@twinsun.com>
25502
25503         * lib/file-type.h: Report an error if neither S_ISREG nor
25504         S_IFREG is defined, instead of using a test specific to glibc
25505         2.2.  This should be safe, since POSIX requires S_ISREG and
25506         Unix Version 7 had S_IFREG.  We don't need to check for
25507         <sys/types.h> since we don't use any symbols that it defines.
25508
25509 2002-06-15  Richard Dawe  <richdawe@bigfoot.com>
25510
25511         * lib/Makefile.am (lstat.c, stat.c, .sin.sed): Use t-$@, rather than
25512         $@-t, so that each temporary file name is unique and valid in the first
25513         8 characters, for operation under DOS.
25514
25515 2002-06-15  Paul Eggert  <eggert@twinsun.com>
25516
25517         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Check for st_author.
25518
25519 2002-06-15  Jim Meyering  <meyering@lucent.com>
25520
25521         Work even with DJGPP 2.03, which lacks support for symlinks.
25522         From Richard Dawe.
25523         * lib/xstat.in (S_ISLNK): Define to 0 if neither S_ISLNK nor S_IFLNK
25524         is defined.
25525         * lib/lchown.c (S_ISLNK): Likewise.
25526
25527 2002-06-15  Jim Meyering  <meyering@lucent.com>
25528
25529         * lib/file-type.h (FILE_TYPE_H): Guard entire contents with #ifndef.
25530         For GNU libc 2.2 and newer, ensure that <sys/types.h> and <sys/stat.h>
25531         have been included before this file.
25532
25533 2002-06-14  Jim Meyering  <meyering@lucent.com>
25534
25535         * lib/file-type.h: Use the version from diffutils-2.8.2.
25536         * lib/file-type.c: Likewise.
25537
25538 2002-06-07  Jim Meyering  <meyering@lucent.com>
25539
25540         * m4/prereq.m4 (jm_PREREQ_STAT): Check for sys/param.h and sys/mount.h.
25541         They're needed at least for NetBSD 1.5.2.
25542         ($statxfs_includes): Include those same headers.
25543         ($statxfs_includes): Include sys/vfs.h if available.
25544         ($statxfs_includes): Likewise for sys/statvfs.h.
25545         Check for the following members in both structs statfs and statvfs:
25546         f_basetype, f_type, f_fsid.__val, f_namemax, f_namelen.
25547
25548 2002-06-01  Jim Meyering  <meyering@lucent.com>
25549
25550         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename macro:
25551         s/D_TYPE_IN_DIRENT/HAVE_STRUCT_DIRENT_D_TYPE/.
25552
25553 2002-05-28  Jim Meyering  <meyering@lucent.com>
25554
25555         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `mkdir', not `rmdir'.
25556         Reported by Volker Borchert.
25557
25558 2002-05-27  Jim Meyering  <meyering@lucent.com>
25559
25560         Fix a problem seen only on nonconforming systems whereby ls.c's
25561         use of localtime, and then of gettimeofday would cause trouble:
25562         the localtime call used to initialize rpl_gettimeofday's save
25563         mechanism would clobber ls's current local time information so
25564         that in any long listing the first file would always be listed
25565         with date 1970-01-01.  Analysis by Volker Borchert.
25566
25567         * lib/gettimeofday.c (localtime): Undefine.
25568         (rpl_localtime): New function.
25569
25570 2002-05-27  Jim Meyering  <meyering@lucent.com>
25571
25572         * m4/gettimeofday.m4 (AC_FUNC_GETTIMEOFDAY_CLOBBER): Also replace
25573         localtime.
25574
25575         * m4/readdir.m4 (jm_FUNC_READDIR): Undefine `rmdir' so we don't try to
25576         use the replacement function; it wouldn't resolve at link time.
25577         Reported by Volker Borchert.
25578
25579 2002-05-22  Jim Meyering  <meyering@lucent.com>
25580
25581         * lib/Makefile.am (libfetish_a_SOURCES): Add file-type.c and
25582         file-type.h.
25583         * lib/file-type.h: New file.
25584         * lib/file-type.c (file_type): New file/function.  Extracted from
25585         diffutils.
25586
25587 2002-04-30  Jim Meyering  <meyering@lucent.com>
25588
25589         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_STAT.
25590
25591 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25592
25593         * m4/prereq.m4 (jm_PREREQ_SIG2STR): Remove; all callers changed.
25594
25595 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25596
25597         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): Check for stdlib.h.
25598         Do not check for alloca.h (no longer used) or stdbool.h (was never
25599         used?).  Add AM_C_PROTOTYPES since hard-locale.h uses it.
25600
25601 2002-04-29  Paul Eggert  <eggert@twinsun.com>
25602
25603         * lib/hard-locale.c: Upgrade to version used in GNU Diffutils 2.8.1.
25604
25605 2002-04-29  Jim Meyering  <meyering@lucent.com>
25606
25607         * m4/jm-macros.m4 (jm_MACROS): Remove use of AC_FUNC_STRNLEN.
25608         * m4/prereq.m4: Add jm_PREREQ_STRNLEN.
25609         Use AC_FUNC_STRNLEN here instead.
25610
25611         * m4/jm-macros.m4: Don't AC_REQUIRE([AC_PROG_CC_STDC]).
25612         With autoconf-2.53a, it's part of AC_PROG_CC.
25613
25614 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25615
25616         * m4/jm-macros.m4 (jm_MACROS): Add AC_REPLACE_FUNCS(sig2str).
25617         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_SIG2STR.
25618
25619 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25620
25621         * lib/sig2str.h, lib/sig2str.c: New files.
25622         * lib/Makefile.am (libfetish_a_SOURCES): Add sig2str.h.
25623
25624 2002-04-28  Paul Eggert  <eggert@twinsun.com>
25625
25626         * lib/sig2str.h (SIGNUM_BOUND): Do not use WTERMSIG, to avoid
25627         depending on <sys/wait.h> and WTERMSIG.  Default to 64 instead
25628         of 127, since 64 is the largest conceivable number for ancient
25629         nonstandard hosts.
25630         * lib/sig2str.c: Do not include <sys/wait.h>; no longer needed.
25631
25632 2002-04-28  Jim Meyering  <meyering@lucent.com>
25633
25634         * lib/sig2str.c (WTERMSIG): Remove definition (unused).
25635
25636 2002-04-24  Jim Meyering  <meyering@lucent.com>
25637
25638         * m4/prereq.m4 (jm_PREREQ_HARD_LOCALE): New macro.
25639         (jm_PREREQ): Use it.
25640
25641         * m4/getloadavg.m4: Check for these headers: locale.h unistd.h
25642         mach/mach.h fcntl.h.
25643         Check for this function: setlocale.
25644
25645 2002-04-24  Jim Meyering  <meyering@lucent.com>
25646
25647         * lib/gettext.h: New file, from Gettext.
25648         * lib/Makefile.am (INCLUDES): Remove -I../intl.
25649         (libfetish_a_SOURCES): Add gettext.h.
25650
25651 2002-04-16  Jim Meyering  <meyering@lucent.com>
25652
25653         * m4/prereq.m4 (jm_PREREQ_READUTMP): Also check for these members:
25654         ut_pid, ut_id, ut_exit.
25655
25656 2002-04-16  Jim Meyering  <meyering@lucent.com>
25657
25658         * lib/readutmp.h (UT_TYPE): Remove definition (now in who.c).
25659         (HAVE_STRUCT_XTMP_UT_EXIT, HAVE_STRUCT_XTMP_UT_ID): Define.
25660         (HAVE_STRUCT_XTMP_UT_PID, HAVE_STRUCT_XTMP_UT_TYPE): Define.
25661
25662 2002-04-12  Jim Meyering  <meyering@lucent.com>
25663
25664         * m4/ls-mntd-fs.m4 (checking for getmntinfo function...): Remove
25665         now-bogus check for f_type in sys/mount.h.  Instead, just test for the
25666         existence of the getmntinfo function.  Needed for Darwin 5.3.
25667
25668         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Also detect when dirfd is a macro.
25669         This is necessary at least on Darwin 5.3.
25670
25671         * m4/jm-macros.m4: Don't AC_REPLACE(strnlen), now that we use
25672         AC_FUNC_STRNLEN.  Otherwise, we'd end up putting two copies of
25673         strnlen.o in the library, and that makes some versions of ranlib
25674         object.
25675
25676 2002-04-12  Jim Meyering  <meyering@lucent.com>
25677
25678         * lib/dirfd.h (dirfd): Elide prototype if dirfd is a macro.
25679
25680 2002-04-09  Jim Meyering  <meyering@lucent.com>
25681
25682         * m4/malloc.m4: (jm_FUNC_MALLOC): Change the `checking ...' message
25683         to be more precise.  Rather than saying we're checking whether the
25684         function `works', say what we're testing.
25685         * m4/realloc.m4 (jm_FUNC_REALLOC): Likewise.
25686         Reported by Bruno Haible.
25687
25688 2002-03-10  Jim Meyering  <meyering@lucent.com>
25689
25690         * lib/makepath.c (make_path): Remove a comma from a diagnostic.
25691         Suggestion from Santiago Vila.
25692
25693 2002-03-08  Jim Meyering  <meyering@lucent.com>
25694
25695         * lib/rename.c: Mention that this wrapper is needed also on
25696         mips-dec-ultrix4.4 systems.
25697
25698 2002-03-02  Jim Meyering  <meyering@lucent.com>
25699
25700         * lib/gettime.c (gettime): Test HAVE_CLOCK_GETTIME,
25701         not HAVE_CLOCK_SETTIME.
25702
25703 2002-02-27  Paul Eggert  <eggert@twinsun.com>
25704
25705         * m4/jm-macros.m4 (jm_MACROS): Do not replace stime; no longer used.
25706         Check for clock_settime.
25707
25708 2002-02-27  Paul Eggert  <eggert@twinsun.com>
25709
25710         * lib/nanosleep.h: Rename to....
25711         * lib/timespec.h: New name for nanosleep.h.  All uses changed.
25712
25713         * lib/gettime.c: New file.
25714         * lib/settime.c: New file.
25715         * lib/stime.c: Remove.
25716
25717         * lib/Makefile.am (libfetish_a_SOURCES): Add gettime.c, settime.c,
25718         timespec.h.  Remove nanosleep.h.
25719
25720 2002-02-25  Paul Eggert  <eggert@twinsun.com>
25721
25722         * m4/acl.m4: New file.
25723         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_ACL.
25724         Do not check for acl or sys/acl.h, as AC_FUNC_ACL does that now.
25725
25726 2002-02-25  Paul Eggert  <eggert@twinsun.com>
25727
25728         * lib/acl.c, lib/acl.h: New files.
25729         * lib/Makefile.am (libfetish_a_SOURCES): Add acl.h, acl.c.
25730
25731 2002-02-24  Jim Meyering  <meyering@lucent.com>
25732
25733         * lib/strnlen.c (strnlen): Define-away/undef so that an inconsistent
25734         prototype in string.h (on at least AIX4.3.2.0 w/gcc-2.95.3) doesn't
25735         cause trouble.  Reported by Nelson Beebe.
25736
25737 2002-02-23  Paul Eggert  <eggert@twinsun.com>
25738
25739         * lib/path-concat.c (xpath_concat): Reorder code to pacify
25740         compilers that don't know that xalloc_die never returns.
25741
25742 2002-02-20  Jim Meyering  <meyering@lucent.com>
25743
25744         * lib/getdate.c: Regenerate using bison-1.33.
25745
25746 2002-02-17  Jim Meyering  <meyering@lucent.com>
25747
25748         * config/config.guess (main): Don't use `head -1'; it's no longer
25749         portable. Use `sed 1q' instead.
25750
25751 2002-02-16  gettextize  <bug-gnu-gettext@gnu.org>
25752
25753         * m4/codeset.m4: Upgrade to gettext-0.11.
25754         * m4/gettext.m4: Upgrade to gettext-0.11.
25755         * m4/glibc21.m4: Upgrade to gettext-0.11.
25756         * m4/iconv.m4: Upgrade to gettext-0.11.
25757         * m4/isc-posix.m4: Upgrade to gettext-0.11.
25758         * m4/lcmessage.m4: Upgrade to gettext-0.11.
25759         * m4/lib-ld.m4: New file, from gettext-0.11.
25760         * m4/lib-link.m4: New file, from gettext-0.11.
25761         * m4/lib-prefix.m4: New file, from gettext-0.11.
25762         * m4/progtest.m4: Upgrade to gettext-0.11.
25763
25764 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25765
25766         * m4/prereq.m4 (jm_PREREQ_POSIXVER): New macro.
25767         (jm_PREREQ): Use it.
25768
25769 2002-02-15  Paul Eggert  <eggert@twinsun.com>
25770
25771         * lib/posixver.c, lib/posixver.h: New files.
25772         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25773
25774 2002-02-02  Paul Eggert  <eggert@twinsun.com>
25775             Bruno Haible  <bruno@clisp.org>
25776
25777         * lib/unicodeio.h (print_unicode_char): Add exit_on_error argument.
25778         (fwrite_success_callback): New declaration.
25779         * lib/unicodeio.c (unicode_to_mb): New function, extracted from
25780         print_unicode_char. Call failure callback instead of error.
25781         (fwrite_success_callback): New function.
25782         (exit_failure_callback): New function.
25783         (fallback_failure_callback): New function.
25784         (print_unicode_char): Call unicode_to_mb.
25785
25786 2002-01-26  Jim Meyering  <meyering@lucent.com>
25787
25788         * m4/jm-macros.m4 (jm_MACROS): Require autoconf-2.52g.
25789         * m4/strnlen.m4: Remove file, now that it's part of autoconf.
25790
25791 2002-01-26  Jim Meyering  <meyering@lucent.com>
25792
25793         * lib/Makefile.am (getdate$U.o): Depend on unlocked-io.h.
25794
25795 2002-01-22  Paul Eggert  <eggert@twinsun.com>
25796
25797         * m4/jm-macros.m4 (jm_MACROS): Require AC_FUNC_FSEEKO.
25798
25799 2002-01-22  Jim Meyering  <meyering@lucent.com>
25800
25801         * lib/Makefile.am (Makefile): Don't depend on $(BUILT_SOURCES).
25802         Otherwise, some versions of automake would omit the rule that makes
25803         Makefile from Makefile.in.
25804
25805 2002-01-21  Paul Eggert  <eggert@twinsun.com>
25806
25807         * lib/xmemcoll.h, lib/xmemcoll.c: New files.
25808         * lib/Makefile.am (libfetish_a_SOURCES): Add them.
25809         * lib/memcoll.c: Include errno.h, and declare errno if not defined.
25810         (memcoll): Set errno to zero if there is no error.
25811
25812         * lib/quotearg.c (quotearg_buffer_restyled):
25813         Fix bug with quoting buffers containing NUL when backslashing escapes.
25814         This bug was exposed by the other changes in this patch.
25815         (quotearg_n_options): New arg ARGSIZE.
25816         All callers changed.
25817         (quoting_options_from_style): New function.
25818         (quotearg_n_style): Use it.
25819         (quotearg_n_style_mem): New function.
25820
25821         * lib/quotearg.h (quotearg_n_style_mem): New function.
25822
25823 2002-01-19  Jim Meyering  <meyering@lucent.com>
25824
25825         * m4/jm-macros.m4 (jm_MACROS): Use AC_FUNC_STRNLEN.
25826         Remove useless quotes: DF_PROG="df".
25827         * m4/strnlen.m4: New file.
25828
25829 2002-01-16  Paul Eggert  <eggert@twinsun.com>
25830
25831         * lib/backupfile.c (ISDIGIT): Comment fix.
25832         * lib/getdate.y (ISDIGIT): Likewise.
25833         * lib/posixtm.c (ISDIGIT, year): Likewise.
25834         * lib/strverscmp.c (ISDIGIT): Likewise.
25835         * lib/userspec.c (ISDIGIT): Likewise.
25836
25837 2002-01-16  Jim Meyering  <meyering@lucent.com>
25838
25839         * lib/getdate.y: Add three semicolons, each just before a closing
25840         brace. Bison (as of version 1.31) no longer papers over that mistake.
25841
25842 2002-01-05  Jim Meyering  <meyering@lucent.com>
25843
25844         * lib/version-etc.c (version_etc_copyright): Update copyright year.
25845
25846 2001-12-19  Paul Eggert  <eggert@twinsun.com>
25847
25848         * lib/closeout.c (close_stdout_status): If ferror (stdout), do
25849         not silently exit merely because the output buffer happens to
25850         have nothing pending.
25851
25852 2001-12-18  Paul Eggert  <eggert@twinsun.com>
25853
25854         See the big note in ../ChangeLog.
25855         * lib/human.c (suffixes): Prefer K to k for 1024.
25856         (generate_suffix_backwards): New function.
25857         (human_readable_inexact): Use it.
25858         * lib/xstrtol.c (__xstrtol): If there is no number but there
25859         is a valid suffix, assume 1.  "MB" now means decimal, "MiB" binary.
25860         Accept 'K' as well as 'k'.
25861
25862 2001-12-15  Jim Meyering  <meyering@lucent.com>
25863
25864         * lib/regex.h (__restrict_arr): Update from libc.
25865
25866         * lib/mountlist.h (ME_REMOTE): Recognize file systems of type smbfs
25867         as `remote' if the name starts with `//'.  Suggested by Michael Stone.
25868         (STREQ): Define.
25869
25870 2001-12-14  Jim Meyering  <meyering@lucent.com>
25871
25872         * m4/jm-macros.m4 (jm_MACROS): Check for iswspace.
25873         Suggestion from Bruno Haible.
25874
25875 2001-12-10  Jim Meyering  <meyering@lucent.com>
25876
25877         * lib/linebuffer.c: Remove explicit declarations of xmalloc and
25878         xrealloc, Instead, include "xalloc.h".
25879         (initbuffer): Don't cast xmalloc return value to char*.
25880         (readline): Reword comment.
25881         Don't cast xrealloc return value to char*
25882         Return NULL, not 0.
25883
25884 2001-12-09  Jim Meyering  <meyering@lucent.com>
25885
25886         * lib/modechange.c (mode_compile): Add cast to avoid pedantic warning
25887         about `signed and unsigned type in conditional expression'.
25888         * lib/posixtm.c (posix_time_parse): Likewise.
25889
25890         * lib/xreadlink.c (xreadlink): Add cast to avoid a pedantic warning.
25891
25892         * lib/readtokens.c (readtoken): Declare an index to be of type unsigned
25893         to avoid a pedantic warning.
25894
25895         * lib/getstr.c: Don't include assert.h.
25896         (getstr): Remove warning-evoking assertions.
25897         Return -1 if offset parameter is out of bounds.
25898         Change the type of a local from int to size_t.
25899
25900         * lib/strftime.c (my_strftime_localtime_r): Include this function
25901         definition in the `#if ! HAVE_TM_GMTOFF' block.
25902
25903         * lib/xgethostname.c: Remove declarations of xmalloc and xrealloc.
25904         Include xalloc.h instead.
25905
25906 2001-12-02  Jim Meyering  <meyering@lucent.com>
25907
25908         * lib/tempname.c: Don't declare getenv, thus reverting the change of
25909         2001-11-18.  It's no longer necessary, now that stdlib.h is always
25910         included.
25911
25912         * lib/regex.c [!__BOUNDED_POINTERS__]: Define away __bounded,
25913         __unbounded, and __ptrvalue.  Reported by Uwe H. Steinfeld.
25914
25915 2001-11-30  Akim Demaille  <akim@epita.fr>
25916
25917         * lib/xstrdup.c: Include xalloc.h, so that xstrdup is declared
25918         before being defined.
25919
25920 2001-11-27  Paul Eggert  <eggert@twinsun.com>
25921
25922         * lib/quotearg.h (quotearg_n, quotearg_n_style):
25923         First arg is int, not unsigned.
25924         * lib/quotearg.c (quotearg_n, quotearg_n_style): Likewise.
25925         (SIZE_MAX, UINT_MAX): New macros.
25926         (quotearg_n_options): Abort if N is negative.
25927         Avoid overflow check on hosts where size_t is 64 bits and int
25928         is 32 bits, as overflow is impossible there.
25929         Fix off-by-one typo that caused unnecessary reallocation.
25930
25931 2001-11-27  Jim Meyering  <meyering@lucent.com>
25932
25933         * lib/tempname.c: Merge with version from libc.
25934         * lib/regex.c: Likewise.
25935
25936         * lib/tempname.c: Include stdlib.h unconditionally.  On some old
25937         systems for which STDC_HEADERS is 0, it was not included, resulting in
25938         a warning about an integer-to-pointer conversion problem with getenv.
25939         Reported by Volker Borchert.
25940
25941 2001-11-26  Jim Meyering  <meyering@lucent.com>
25942
25943         * lib/gtod.h: Remove file.
25944         * lib/Makefile.am (libfetish_a_SOURCES): Remove gtod.h.
25945         * lib/gettimeofday.c: Don't include gtod.h.
25946         (GTOD_init): Remove function.
25947         (rpl_gettimeofday): Do its job here instead, rather than aborting.
25948         Suggestion from Volker Borchert.
25949
25950 2001-11-23  Jim Meyering  <meyering@lucent.com>
25951
25952         * lib/hash.h (struct hash_table): Don't define here.  Merely declare
25953         it.
25954         * lib/hash.c (struct hash_table): Define it here instead.
25955
25956 2001-11-22  Jim Meyering  <meyering@lucent.com>
25957
25958         * lib/hash.h: Bracket contents of file with #ifndef HASH_H_ ... #endif.
25959
25960 2001-11-20  Jim Meyering  <meyering@lucent.com>
25961
25962         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Update comment to reflect that
25963         SunOS 4.1.4 and Solaris 2.5.1 lose, too.
25964
25965 2001-11-19  Jim Meyering  <meyering@lucent.com>
25966
25967         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Don't bother with a temporary
25968         directory.  Use "conftestXXXXXX" as the template.
25969         Suggestion from Paul Eggert.
25970
25971         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): Close each descriptor
25972         immediately, so the test doesn't mistakenly hit the max-open-files
25973         limit.
25974
25975 2001-11-18  Paul Eggert  <eggert@twinsun.com>
25976
25977         * lib/tempname.c (TMP_MAX): Remove; no longer needed.
25978         (TEMPORARIES): New macro.
25979         (__gen_tempname): Use TEMPORARIES rather than TMP_MAX.  This
25980         removes an artificial limitation (e.g. HP-UX 10.20, where
25981         TMP_MAX is 17576).
25982
25983 2001-11-18  Jim Meyering  <meyering@lucent.com>
25984
25985         * m4/prereq.m4 (jm_PREREQ_TEMPNAME): Check for declaration of getenv.
25986
25987 2001-11-18  Jim Meyering  <meyering@lucent.com>
25988
25989         * lib/tempname.c [!HAVE_DECL_GETENV]: Declare getenv to avoid warning
25990         on SunOS 4.
25991
25992         * lib/Makefile.am (Makefile): Depend on $(BUILT_SOURCES), so those
25993         files will be created before anything else.
25994
25995 2001-11-17  Paul Eggert  <eggert@twinsun.com>
25996
25997         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): Do not define
25998         WINSIZE_IN_PTEM if <termios.h> defines struct winsize.
25999
26000 2001-11-17  Jim Meyering  <meyering@lucent.com>
26001
26002         * m4/mkstemp.m4 (UTILS_FUNC_MKSTEMP): New file and macro.
26003         Prompted by a report from Bob Proulx.
26004
26005         * m4/jm-macros.m4 (jm_MACROS): Don't test for mkstemp here.
26006         Instead, require UTILS_FUNC_MKSTEMP.
26007
26008 2001-11-17  Jim Meyering  <meyering@lucent.com>
26009
26010         * m4/jm-macros.m4 (jm_MACROS): Remove code to set POW_LIBM.
26011         Now, that's done as part of AC_FUNC_STRTOD.
26012
26013 2001-11-17  Jim Meyering  <meyering@lucent.com>
26014
26015         * lib/modechange.c (mode_adjust): Fix error introduced on 1999-04-26
26016         that made e.g., `chmod a=,o=w,g=o F' cause F to be group readable
26017         rather than group writable.  Patch by Juan F. Codagnone.
26018
26019         * lib/readtokens.c: Remove explicit declarations of xmalloc and
26020         xrealloc, Instead, include "xalloc.h".
26021
26022         * lib/mountlist.c: Include unlocked-io.h after all system headers.
26023         Remove explicit declarations of xmalloc, xrealloc,
26024         and xstrdup.  Instead, include "xalloc.h".
26025
26026         * lib/argmatch.c, closeout.c, error.c, exclude.c: Include
26027         unlocked-io.h.
26028         * lib/fatal.c, getdate.y, getpass.c, getstr.c, getusershell.c:
26029         Likewise.
26030         * lib/mountlist.c, posixtm.c, readtokens.c, readutmp.c: Likewise.
26031
26032         * lib/regex.c, sha.c, version-etc.c, yesno.c: Likewise.
26033         Reported by Padraig Brady.
26034
26035         * lib/mkstemp.c: #undef mkstemp.
26036         Include config.h.
26037         (rpl_mkstemp): Rename from mkstemp.
26038         Protoize.
26039
26040 2001-11-16  Jim Meyering  <meyering@lucent.com>
26041
26042         * lib/physmem.c [HAVE_SYS_PSTAT_H]: Include <sys/pstat.h>.
26043         (physmem_total) [HAVE_PSTAT_GETSTATIC]: If sysconf couldn't be used to
26044         determine the amount of total physical memory, use pstat_getstatic.
26045         HPUX-11 doesn't define _SC_PHYS_PAGES.
26046         (physmem_available) [HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC]:
26047         If sysconf couldn't be used to determine the amount of available
26048         physical memory, use both pstat_getstatic and pstat_getdynamic.
26049         Based on a patch from Bob Proulx.
26050
26051 2001-11-10  Jim Meyering  <meyering@lucent.com>
26052
26053         * m4/prereq.m4 (jm_PREREQ_PHYSMEM): New function.
26054         (jm_PREREQ): Use it.
26055
26056 2001-11-09  Jim Meyering  <meyering@lucent.com>
26057
26058         * m4/jm-macros.m4: Require autoconf-2.52f.
26059         (AC_FUNC_ERROR_AT_LINE, AC_FUNC_OBSTACK, AC_FUNC_STRTOD):
26060         Use these AC_-prefixed names, not the AM_-prefixed ones.
26061
26062         * m4/afs.m4 (jm_AFS): Quote the body.  Patch by Akim Demaille.
26063
26064 2001-11-05  Jim Meyering  <meyering@lucent.com>
26065
26066         * lib/xstat.in (slash_aware_lstat): Correct a misleading comment.
26067
26068 2001-11-04  Jim Meyering  <meyering@lucent.com>
26069
26070         * m4/fpending.m4: Remove unused cruft that saved, set, and restored
26071         $DEFS.
26072
26073 2001-11-03  Jim Meyering  <meyering@lucent.com>
26074
26075         * m4/jm-glibc-io.m4n (jm_FUNC_GLIBC_UNLOCKED_IO): Quote first arg
26076         of AC_DEFUN.
26077
26078         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): Rework so dirfd.c doesn't have to
26079         know the name of the variable in the macro definition.
26080
26081 2001-11-03  Jim Meyering  <meyering@lucent.com>
26082
26083         * lib/argmatch.h (ARGMATCH_TO_ARGUMENT): Remove casts of first two args
26084         in argmatch_to_argument call.
26085
26086         * lib/dirfd.c (dirfd): Reflect the fact that DIR_TO_FD now takes an
26087         argument.
26088
26089         * lib/hash.c (hash_clear): Fix a bug that could lead to an infloop or
26090         e.g., a fault due to an attempt to free a NULL pointer.
26091
26092 2001-11-01  Jim Meyering  <meyering@lucent.com>
26093
26094         * m4/dirfd.m4 (UTILS_FUNC_DIRFD): New macro.
26095         * m4/jm-macros.m4 (jm_MACROS): Require UTILS_FUNC_DIRFD.
26096
26097 2001-11-01  Jim Meyering  <meyering@lucent.com>
26098
26099         * lib/dirfd.c, lib/dirfd.h: New files.
26100         * lib/Makefile.am (libfetish_a_SOURCES): Add dirfd.h.
26101
26102         * lib/hash.c (hash_print) [TESTING]: Clean up.
26103
26104 2001-10-22  Paul Eggert  <eggert@twinsun.com>
26105
26106         * lib/hard-locale.c (alloca): Define to __builtin_alloca if __GNUC__,
26107         to avoid a warning if -Wall.
26108
26109 2001-10-22  Jeff Bailey  <jbailey@outpost.dnsalias.org>
26110
26111         * README: New file
26112         * doc/*: Add COPYING, COPYING.LIB, COPYING.DOC, fdl.texi
26113         (per RMS's instructions, this is now the canonical source)
26114         * lgpl/, gpl/: New directories.
26115
26116 2001-10-21  Paul Eggert  <eggert@twinsun.com>
26117
26118         * lib/regex.c (uintptr_t): Remove macro and decl; it's config.h's job.
26119
26120 2001-10-21  Jim Meyering  <meyering@lucent.com>
26121
26122         * lib/obstack.c (_): Honor the setting of ENABLE_NLS.  Otherwise,
26123         this code would end up calling gettext even in packages built
26124         with --disable-nls.
26125         * lib/getopt.c (_): Likewise.
26126         * lib/regex.c (_): Likewise.
26127
26128 2001-10-20  Paul Eggert  <eggert@twinsun.com>
26129
26130         * m4/error.m4 (jm_PREREQ_ERROR):
26131         Do not invoke AC_CHECK_FUNCS with strerror_r, as
26132         AC_FUNC_STRERROR_R does that.
26133         Check for strerror declaration.
26134
26135         * m4/strerror_r.m4: Add copyright notice, as nontrivial m4 files
26136         are supposed to have them these days.
26137         (AC_FUNC_STRERROR_R): Always do char* test, so that it gets cached.
26138         Merge changes from latest Autoconf CVS.
26139         Rename ac_cv_func_strerror_r_works to ac_cv_func_strerror_r_char_p,
26140         and rename HAVE_WORKING_STRERROR_R to STRERROR_R_CHAR_P, since
26141         POSIX decided to standardize on the int flavor of strerror_r.
26142
26143 2001-10-20  Paul Eggert  <eggert@twinsun.com>
26144
26145         * lib/error.c (strerror_r): Do not declare unless !_LIBC.
26146         Do not check for HAVE_DECL_STRERROR_R missing unless STRERROR_R_CHAR_P.
26147         Use strerror_r that is only a macro, even if it is not a function.
26148         (strerror): Check for HAVE_DECL_STRERROR before declaring.
26149         (private_strerror): Use prototypes, not old-style function definition.
26150         (print_errno_message): New function.
26151         Support the POSIX 'int'-flavored strerror_r, as well as the traditional
26152         char*-flavored one.
26153         (error_tail, error, error_at_line): Use it.
26154
26155 2001-10-11  Jim Meyering  <meyering@lucent.com>
26156
26157         * lib/argmatch.c (argmatch_invalid): Use quotearg_n_style (0, ...
26158         and quote_n (1, ... to avoid clobbering a buffer.
26159
26160 2001-10-05  Jim Meyering  <meyering@lucent.com>
26161
26162         * lib/Makefile.am: (libfetish_a_SOURCES): Add hash-pjw.c and
26163         hash-pjw.h.
26164         * lib/hash-pjw.c: New file (factored out of fileutils' remove.c).
26165         * lib/hash-pjw.h: New file.
26166
26167 2001-09-30  Jim Meyering  <meyering@lucent.com>
26168
26169         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): See if
26170         `struct fsstat' has the `f_fstypename' member.
26171         Use that to define FS_TYPE, which is now used to make
26172         the getfsstat link test tighter.
26173
26174 2001-09-30  Jim Meyering  <meyering@lucent.com>
26175
26176         * lib/mountlist.c [MOUNTED_GETFSSTAT]:
26177         Include <sys/ucred.h>, for Apple Darwin.
26178         Include sys/mount.h and sys/fs_types.h only if available.
26179         (FS_TYPE): Define.
26180         (read_filesystem_list): Use FS_TYPE.
26181
26182 2001-09-29  Paul Eggert  <eggert@twinsun.com>
26183
26184         * lib/exclude.c (excluded_filename): 0 -> false, since it's
26185         a boolean context.
26186
26187 2001-09-29  Jim Meyering  <meyering@lucent.com>
26188
26189         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26190         [one-argument getmntent function]): Include stdio.h before mntent.h.
26191         SunOS 4.1.x needs it for the declaration of `FILE'.
26192         Patch by Volker Borchert.
26193
26194         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS)
26195         Check for these headers: sys/param.h sys/ucred.h sys/mount.h
26196         sys/fs_types.h, and make the link-test for getfsstat guard #include
26197         directives with appropriate #if HAVE_*_H tests so that we can
26198         detect getfsstat on Apple Darwin1.3.7 systems.
26199         Reported by Nelson Beebe.
26200         Fix harmless typo in cache variable name: s/getsstat/getfsstat/.
26201
26202 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26203
26204         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26205         #defines strtoimax.  Also treat the other strto* functions
26206         like strtoimax.
26207
26208         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
26209         Check for strtoul and strtoumax,
26210         as those declarations are made even in the signed case.
26211         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX):
26212         Likewise, for strtol and strtoimax.
26213
26214 2001-09-28  Paul Eggert  <eggert@twinsun.com>
26215
26216         Fix bug reported by Petter Reinholdtsen for HP-UX 10.20, which
26217         #defines strtoimax.  Also treat the other strto* functions
26218         like strtoimax.
26219
26220         * lib/xstrtol.c (strtol): Do not declare if HAVE_DECL_STRTOL.
26221         (strtoul): Do not declare if HAVE_DECL_STRTOUL.
26222         (strtoimax, strtoumax): Do not declare if already defined as a macro.
26223
26224 2001-09-26  Jim Meyering  <meyering@lucent.com>
26225
26226         Most macros in unlocked-io.h had the wrong number of arguments.
26227         * lib/gen-uio: New script.
26228         (USE_UNLOCKED_IO): Define to 1 if not already defined.
26229         * lib/unlocked-io.hin: Remove file.
26230         * lib/Makefile.am (unlocked-io.h): Rewrite to use a separate script,
26231         rather than trying to embed it here.
26232         (EXTRA_DIST): Add gen-uio.  Remove unlocked-io.hin
26233         Reported by Padraig Brady.
26234
26235 2001-09-25  Volker Borchert  <bt@teknon.de>
26236
26237         * lib/gettimeofday.c (rpl_gettimeofday): Declare local variable
26238         `result'.
26239
26240 2001-09-24  Jim Meyering  <meyering@lucent.com>
26241
26242         * m4/gettext.m4: Use the version from gettext-0.10.40, not CVS.
26243
26244 2001-09-23  Jim Meyering  <meyering@lucent.com>
26245
26246         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add a compile-test
26247         instead of the mere test for existence of mntent.h.  The latter
26248         would get a false-positive on AIX 3.4 systems.
26249         In the outer getmntent if-block, don't die if neither of the getmntent
26250         tests succeeds.  Instead, just fall through and continue with the
26251         remaining tests.
26252
26253 2001-09-23  Jim Meyering  <meyering@lucent.com>
26254
26255         * lib/mountlist.c: Remove useless parentheses in #if directives.
26256         (MOUNTED) [!defined MOUNTED]: Define to _PATH_MOUNTED, for when
26257         the deprecated MOUNTED symbol is no longer defined in mntent.h.
26258
26259 2001-09-22  Jim Meyering  <meyering@lucent.com>
26260
26261         * m4/gettext.m4: New file.  From gettext.
26262         * m4/lcmessage.m4: Sync with gettext -- this changes only comments.
26263         * m4/progtest.m4: Likewise
26264         * m4/isc-posix.m4: Decrement serial number to sync with gettext.
26265         * m4/glibc21.m4: Likewise.
26266
26267         * m4/libintl.m4: Remove.  No longer used.
26268
26269 2001-09-22  Jim Meyering  <meyering@lucent.com>
26270
26271         * lib/localcharset.c: Update from latest gettext.
26272         * lib/config.charset: Likewise.
26273
26274 2001-09-20  Jim Meyering  <meyering@lucent.com>
26275
26276         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of
26277         strtoimax.
26278         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of
26279         strtoumax.
26280
26281 2001-09-20  Jim Meyering  <meyering@lucent.com>
26282
26283         * lib/xstrtol.c (strtoimax): Guard declaration with
26284         `#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
26285         The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
26286         have their own, conflicting declaration of strtoimax in sys/inttypes.h.
26287         (strtoumax): Likewise, for completeness (it wasn't necessary).
26288
26289 2001-09-17  Paul Eggert  <eggert@twinsun.com>
26290
26291         * lib/strtoimax.c (HAVE_LONG_LONG):
26292         Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
26293         (strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
26294         to work around bug in IBM C compiler.
26295
26296 2001-09-17  Jim Meyering  <meyering@lucent.com>
26297
26298         * m4/chown.m4, fstypename.m4, getgroups.m4, gettimeofday.m4,
26299         * m4/jm-mktime.m4, lstat.m4, malloc.m4, memcmp.m4, mkdir-slash.m4,
26300         * m4/nanosleep.m4, putenv.m4, readdir.m4, realloc.m4, rename.m4,
26301         * m4/st_dm_mode.m4, stat.m4, strerror_r.m4, timespec.m4, utimbuf.m4,
26302         * m4/utimes.m4: Use AC_DEFINE rather than AC_DEFINE_UNQUOTED,
26303         whenever the right hand side need not be expanded by the shell.
26304
26305 2001-09-16  Paul Eggert  <eggert@twinsun.com>
26306
26307         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): Remove test for GNU C
26308         library.  It's not correct, as some older glibcs are buggy.
26309         fnmatch wasn't fixed until glibc 2.2.
26310
26311         Use AC_DEFINE, not AC_DEFINE_UNQUOTED, as there's no
26312         special shell magic here.
26313
26314 2001-09-16  Jim Meyering  <meyering@lucent.com>
26315
26316         * m4/mkdir-slash.m4 (UTILS_FUNC_MKDIR_TRAILING_SLASH): New file/macro.
26317         * m4/jm-macros.m4: Require it.
26318
26319 2001-09-16  Jim Meyering  <meyering@lucent.com>
26320
26321         * lib/mkdir.c: New file.
26322
26323 2001-09-15  Jim Meyering  <meyering@lucent.com>
26324
26325         * m4/jm-macros.m4: Check for help2man.
26326
26327 2001-09-11  Jim Meyering  <meyering@lucent.com>
26328
26329         * m4/host-os.m4 (UTILS_HOST_OS): New file/macro.
26330         The body, by Paul Eggert, was moved here from configure.in.
26331         * m4/jm-macros.m4: Require UTILS_HOST_OS.
26332
26333 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26334
26335         * m4/prereq.m4 (jm_PREREQ_XREADLINK): New macro.
26336         (jm_PREREQ): Use it.
26337
26338 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26339
26340         * lib/xreadlink.c (xreadlink): Omit size_t* arg.  All uses changed.
26341         Use ssize_t, not int, to store result of readlink.
26342         Check for ssize_t overflow as well as size_t overflow,
26343         as POSIX says the result of readlink is implementation-defined
26344         when ssize_t overflows.
26345         Remove unnecessary cast to char*.
26346         Use free+malloc instead of realloc, as the storage doesn't need
26347         to be preserved and it's clearer and can be more efficient that way.
26348         (SIZE_MAX, SSIZE_MAX): New macros, if <limits.h> doesn't declare.
26349         * lib/xreadlink.h (xreadlink): Update prototype.
26350
26351 2001-09-04  Paul Eggert  <eggert@twinsun.com>
26352
26353         * lib/xgetcwd.c: Revert some of the previous change; intead,
26354         fix the HAVE_GETCWD_NULL code to behave more like the
26355         !HAVE_GETCWD_NULL code used to.
26356
26357         Include "xalloc.h".
26358         (xgetcwd): Do not return NULL when memory is exhausted; instead,
26359         invoke xalloc_die.
26360
26361 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26362
26363         * m4/prereq.m4 (jm_PREREQ_XGETCWD): Check for limits.h and
26364         sys/param.h, as pathmax.h includes them.
26365
26366 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26367
26368         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_XGETCWD.
26369         (jm_PREREQ_XGETCWD): New macro.
26370
26371         * m4/getcwd.m4: New file.
26372
26373 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26374
26375         * lib/xgetcwd.c: Fix the !HAVE_GETCWD_NULL code to behave more
26376         like the HAVE_GETCWD_NULL code.
26377         Include pathmax.h if not HAVE_GETCWD.
26378         Do not include xalloc.h.
26379         (INITIAL_BUFFER_SIZE): New symbol.
26380         Do not use xmalloc / xrealloc, since the caller is responsible for
26381         handling errors.  Preserve errno around `free' during failure.
26382         Do not overrun buffer when using getwd.
26383
26384 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26385
26386         * lib/xgetcwd.c (xgetcwd): Use HAVE_GETCWD_NULL, not (defined
26387         __GLIBC__ && __GLIBC__ >= 2), to decide whether to use
26388         getcwd (NULL, 0).
26389
26390 2001-09-03  Paul Eggert  <eggert@twinsun.com>
26391
26392         * lib/exclude.c (fnmatch_no_wildcards): Fix confusion between
26393         usage of FNM_CASEFOLD and FNM_LEADING_DIR.  The bug was
26394         spotted by Jim Meyering.
26395
26396 2001-09-03  Jim Meyering  <meyering@lucent.com>
26397
26398         * lib/xreadlink.c (xreadlink): Preserve errno around `free' during
26399         failure.
26400
26401 2001-09-02  Jim Meyering  <meyering@lucent.com>
26402
26403         * lib/error.c: Update from GNU libc.
26404
26405 2001-09-01  Jim Meyering  <meyering@lucent.com>
26406
26407         * m4/jm-macros.m4 (jm_MACROS): Check for canonicalize_file_name.
26408         Used by df.
26409
26410 2001-09-01  Jim Meyering  <meyering@lucent.com>
26411
26412         * lib/xreadlink.c: New file.
26413         * lib/xreadlink.h: New file.
26414         * lib/Makefile.am (libfetish_a_SOURCES): Add xreadlink.c and
26415         xreadlink.h.
26416
26417         * lib/regex.c (uintptr_t) [!_LIBC]: Define to private_uintptr_t, so it
26418         doesn't conflict with sparc Solaris 7's definition in
26419         /usr/include/sys/int_types.h.
26420
26421         * lib/exclude.c: Use `""', not `<>' to #include non-system header
26422         files.
26423         (fnmatch_no_wildcards): Rewrite not to use function names, strcasecmp
26424         and strncasecmp as r-values.  Unixware didn't have declarations.
26425
26426 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26427
26428         * lib/xstrtol.h: Add copyright notice.
26429         (_DECLARE_XSTRTOL): Improve quality of diagnostic for
26430         LONGINT_INVALID_SUFFIX_CHAR.
26431
26432 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26433
26434         * lib/xstrtol.c (strtoimax): New decl.
26435
26436 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26437
26438         * lib/xgetcwd.c: Don't include pathmax.h.
26439         Include stdlib.h and unistd.h if available.
26440         Include xalloc.h.
26441         (xmalloc, xstrdup, free): Remove decls.
26442         (xgetcwd): Don't assume sizes fit in unsigned.
26443         Check for overflow when computing sizes.
26444         Simplify reallocation code.
26445
26446 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26447
26448         * lib/savedir.c (savedir): Remove size parameter, as POSIX says that
26449         a directory's st_size can have an arbitrary value, so the old
26450         usage could waste an arbitrary amount of memory.  All uses
26451         changed.
26452         * lib/savedir.h: Update prototype.
26453
26454 2001-08-31  Paul Eggert  <eggert@twinsun.com>
26455
26456         * lib/Makefile.am (libfetish_a_SOURCES): Remove strtoxmax.c.
26457
26458         * lib/strtoimax.c: Renamed from strtoxmax.c, removing the
26459         old strtoimax.c.
26460
26461         Also, make the following further changes to make this file's
26462         configuration more similar to that of strtol.c:
26463         (UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.  All uses changed.
26464         (strtoumax, uintmax_t, strtoull, strtol): Remove.
26465         (intmax_t, strtoimax, strtol, strtoll): New macros, if UNSIGNED.
26466         (strtoimax): Renamed from strtoumax.  All uses of unsigned values
26467         changed to signed values.
26468
26469         And make the following changes as well:
26470         Fix copyright notice, as 1999 was missing.
26471         (verify): New macro.
26472         (strtoimax): Check sizes at compile-time, not run-time.
26473         Prefer strtol to strtoll if both work.
26474         (main): Remove; it was not that useful and was a pain to maintain.
26475
26476         * lib/strtoumax.c: Include strtoimax.c, not strtouxmax.c.
26477
26478 2001-08-31  Jim Meyering  <meyering@lucent.com>
26479
26480         * lib/xgetcwd.c (xgetcwd): Reorganize to avoid some duplication.
26481         Use an initial, malloc'd, buffer of length 128 rather than
26482         a statically allocated one of length 1024.
26483
26484 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26485
26486         Simplify code, partly by assuming autoconf 2.52 semantics.
26487
26488         * m4/Makefile.am (EXTRA_DIST): Remove uintmax_t.m4.
26489
26490         * m4/inttypes.m4 (AC_PREREQ): Bump to 2.52.
26491         (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf in 2.52.
26492         All uses removed.
26493         (jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T):
26494         Move AC_REQUIRE to next-to-top level, to avoid confusion.
26495         Use 2.52's AC_CHECK_TYPE instead of merely looking for the header.
26496         * m4/prereq.m4 (jm_PREREQ_HUMAN): Don't require
26497         jm_AC_HEADER_INTTYPES_H.
26498         * m4/jm-macros.m4 (jm_MACROS): Likewise.
26499
26500         * m4/uintmax_t.m4: Remove, as it duplicates inttypes.m4.
26501
26502         * m4/xstrtoimax.m4 (jm_AC_PREREQ_XSTRTOIMAX):
26503         Quote first arg of AC_DEFUN.
26504         Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG
26505         since they are needed to parse the include file even if we need
26506         only xstrtoimax.  Simplify logic behind the args to AC_REPLACE.
26507         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Likewise,
26508         but with opposite signedness.
26509
26510 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26511
26512         Merge 'exclude' changes from tar 1.13.22.
26513         This fixes one or two unlikely storage allocation overflow bugs,
26514         but doesn't change user-visible behavior otherwise.
26515
26516 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26517
26518         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_EXCLUDE.
26519         (jm_PREREQ_EXCLUDE): New macro.
26520
26521 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26522
26523         * lib/quotearg.c: BSD/OS 4.1 wchar.h requires FILE and struct
26524         tm to be declared.
26525
26526 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26527
26528         * lib/hash.c: Remove '2001' from copyright notice.
26529
26530 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26531
26532         * lib/full-write.h: New file.
26533         * lib/Makefile.am (libfetish_a_SOURCES): Add full-write.h.
26534         * lib/full-write.c: Correct credits, as cccp.c no longer
26535         exists and anyway it was so heavily changed from the old cccp
26536         code as to be unrecognizable.  Include full-write.h.
26537         (full_write) Return size_t, with short writes meaning failure.
26538         All callers changed.  This fixes a bug with large buffers
26539         on 64-bit hosts.
26540         * lib/utime.c: Include full-write.h.
26541
26542 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26543
26544         * lib/exclude.c (bool): Declare, perhaps by including stdbool.h.
26545         (<sys/types.h>): Include only if HAVE_SYS_TYPES_H.
26546         (<stdlib.h>, <string.h>, <strings.h>, <inttypes.h>, <stdint.h>):
26547         Include if available.
26548         (<xalloc.h>): Include
26549         (SIZE_MAX): Define if <stdint.h> or <inttypes.h> doesn't.
26550         (verify): New macro.  Use it to verify that EXCLUDE macros do not
26551         collide with FNM macros.
26552         (struct patopts): New struct.
26553         (struct exclude): Use it, as exclude patterns now come with options.
26554         (new_exclude): Support above changes.
26555         (new_exclude, add_exclude_file):
26556         Initial size must now be a power of two to simplify overflow checking.
26557         (free_exclude, fnmatch_no_wildcards): New function.
26558         (excluded_filename): No longer requires options arg, as the options
26559         are determined by add_exclude.  Now returns bool, not int.
26560         (excluded_filename, add_exclude):
26561         Add support for the fancy new exclusion options.
26562         (add_exclude, add_exclude_file): Now takes int options arg.
26563         Check for arithmetic overflow when computing sizes.
26564         (add_exclude_file): xrealloc might modify errno, so don't
26565         realloc until after errno might be used.
26566
26567         * lib/exclude.h (EXCLUDE_ANCHORED, EXCLUDE_INCLUDE,EXCLUDE_WILDCARDS):
26568         New macros.
26569         (free_exclude): New decl.
26570         (add_exclude, add_exclude_file): Now takes int options arg.
26571         (excluded_filename): No longer requires options arg, as the options
26572         are determined by add_exclude.  Now returns bool, not int.
26573
26574 2001-08-30  Paul Eggert  <eggert@twinsun.com>
26575
26576         * lib/alloca.c (alloca): Arg is of type size_t, not unsigned.
26577
26578 2001-08-27  Jim Meyering  <meyering@lucent.com>
26579
26580         * lib/Makefile.am (libfetish_a_SOURCES): Add strtoxmax.c
26581
26582         * lib/version-etc.c (N_): Remove definition.
26583         Revert most of last change.
26584         Instead, simply don't mark the `Copyright...' string for translation.
26585         Based on advice from Paul Eggert.
26586
26587         * lib/strtoxmax.c: Tweak comment.
26588
26589 2001-08-26  Jim Meyering  <meyering@lucent.com>
26590
26591         * m4/jm-macros.m4: Require jm_AC_PREREQ_XSTRTOIMAX.
26592
26593         * m4/xstrtoimax.m4: New file.
26594         * m4/xstrtoumax.m4: Add comments explaining why we
26595         AC_REPLACE_FUNCS(strtol).
26596
26597 2001-08-26  Jim Meyering  <meyering@lucent.com>
26598
26599         * lib/version-etc.c (version_etc_copyright_fmt): Replace literal year
26600         of copyright with `%s' so translators don't get an untranslated
26601         message in 2002.
26602         (COPYRIGHT_YEAR): Define.
26603         (version_etc): Use fprintf rather than fputs.
26604         Suggestion from Ulrich Drepper.
26605
26606         * lib/Makefile.am (libfetish_a_SOURCES): Add xstrtoimax.c.
26607
26608         * lib/strtoll.c: New file, from GNU libc.
26609         * lib/xstrtoimax.c: New file.
26610
26611         * lib/xstrtol.h: Add xstrtoimax.
26612         * lib/strtoumax.c: New file.  Simply include "strtoumax.c".
26613         * lib/strtoimax.c: New file.  Likewise, but first define
26614         STRTOUXMAX_SIGNED.
26615
26616         * lib/strtoumax.c: Factor to work both for unsigned and signed types,
26617         ...
26618         * lib/strtoxmax.c: ... then renamed to this.
26619
26620 2001-08-18  Paul Eggert  <eggert@twinsun.com>
26621
26622         * m4/inttypes.m4: Add AC_PREREQ(2.13).
26623         (jm_AC_HEADER_INTTYPES_H): Test for intmax_t, too.
26624         (jm_AC_TYPE_INTMAX_T): New macro.
26625         (jm_AC_TYPE_UINTMAX_T): Moved here from uintmax_t.m4.
26626
26627         * m4/longlong.m4 (jm_AC_TYPE_LONG_LONG): New macro.
26628
26629         * m4/longlong.m4: Renamed from ulonglong.m4.
26630         * m4/inttypes.m4: Renamed from inttypes_h.m4.
26631         * m4/uintmax_t.m4: Removed.
26632
26633 2001-08-13  Paul Eggert  <eggert@twinsun.com>
26634
26635         * lib/Makefile.am (unlocked-io.h): Do not append "_unlocked" twice.
26636         Port to Solaris 8, where 'sed' requires a space after the 'r'
26637         command, and where sh dislikes "$/".  Clean up the spacing a bit.
26638         Redirect output to $tmp just once.
26639
26640 2001-08-12  Paul Eggert  <eggert@sic.twinsun.com>
26641
26642         * lib/addext.c (<errno.h>): Include.
26643         (errno): Declare if not defined.
26644         (addext): Work correctly when pathconf returns -1 and leaves
26645         errno alone because there is no limit.  Also, work even if
26646         pathconf returns a value greater than SIZE_MAX.
26647
26648 2001-08-12  Jim Meyering  <meyering@lucent.com>
26649
26650         * m4/afs.m4, assert.m4, bison.m4, check-decl.m4, chown.m4, d-ino.m4,
26651         d-type.m4, dos.m4, error.m4, fnmatch.m4, fpending.m4, fstypename.m4,
26652         fsusage.m4, ftruncate.m4, getgroups.m4, glibc.m4, gnu-source.m4,
26653         group-member.m4, jm-glibc-io.m4, jm-macros.m4, jm-mktime.m4,
26654         jm-winsz1.m4, jm-winsz2.m4, lchown.m4, lib-check.m4, libintl.m4,
26655         link-follow.m4, ls-mntd-fs.m4, lstat.m4, malloc.m4, mbrtowc.m4,
26656         mbstate_t.m4, mbswidth.m4, memcmp.m4, nanosleep.m4, perl.m4,
26657         prereq.m4, putenv.m4, readdir.m4, realloc.m4, regex.m4, rename.m4,
26658         rmdir-errno.m4, search-libs.m4, st_dm_mode.m4, st_mtim.m4, stat.m4,
26659         strftime.m4, timespec.m4, unlink-busy.m4, uptime.m4, utimbuf.m4,
26660         utime.m4, utimes.m4, xstrtoumax.m4:
26661         Quote the first argument in each use of AC_DEFUN.
26662
26663 2001-08-12  Jim Meyering  <meyering@lucent.com>
26664
26665         * lib/xgetcwd.c (xgetcwd) [defined __GLIBC__ && __GLIBC__ >= 2]:
26666         Simply `return getcwd (NULL, 0);'.
26667         [! (defined __GLIBC__ && __GLIBC__ >= 2)]:
26668         Use 1300 as initial value for length, not PATH_MAX.
26669
26670         * lib/pathmax.h: Clean up cpp syntax.
26671
26672 2001-08-12  Jim Meyering  <meyering@lucent.com>
26673
26674         * lib/gettimeofday.c: New file.
26675         * lib/gtod.h: New file.
26676         * lib/Makefile.am (libfetish_a_SOURCES): Add gtod.h.
26677
26678 2001-08-05  Jim Meyering  <meyering@lucent.com>
26679
26680         * m4/jm-macros.m4: Require autoconf-2.52.
26681
26682 2001-08-04  Jim Meyering  <meyering@lucent.com>
26683
26684         * lib/error.h (__attribute__): Remove `|| __STRICT_ANSI__' from #if
26685         stmt, to get in sync with glibc.
26686
26687 2001-08-03  Paul Eggert  <eggert@twinsun.com>
26688
26689         The following changes are from gettext 0.10.39 as maintained by
26690         Bruno Haible.
26691
26692         * lib/mbswidth.h (MBSW_REJECT_UNPRINTABLE, MBSW_REJECT_INVALID):
26693         Renamed from MBSW_ACCEPT_UNPRINTABLE and MBSW_ACCEPT_INVALID
26694         with inverted sense.  All uses changed.
26695
26696         * lib/mbswidth.c: Don't include <limits.h>.
26697         Include <stdlib.h> and <string.h> unconditionally.
26698         (iswcntrl, mbsinit, ISCNTRL): New macros.
26699         (mbsnwidth): Use K&R style function declarations.
26700         Don't bother checking for MB_LEN_MAX == 1, since the compiler
26701         can optimize it when MB_CUR_MAX == 1.
26702         The width of control characters is zero, not 1.
26703
26704 2001-08-03  Paul Eggert  <eggert@twinsun.com>
26705
26706         The following changes are from gettext 0.10.39 as maintained by
26707         Bruno Haible, except that getline.m4 continues to use AC_LIBOBJ.
26708
26709         * m4/codeset.m4: Upgrade to serial AM1.
26710         (AM_LANGINFO_CODESET): Renamed from jm_LANGINFO_CODESET;
26711         all uses changed.  Quote first arg of AC_DEFUN.
26712         (am_cv_langinfo_codeset): Renamed from jm_cv_langinfo_codeset.
26713
26714         * m4/iconv.m4: Upgrade to serial AM2.
26715         (AM_ICONV): Renamed from jm_ICONV; all uses changed.
26716         Add --with-libconv-prefix.
26717         Quote first arg of AC_DEFUN.  Add description for ICONV_CONST.
26718         (am_cv_func_iconv): Renamed from jm_cv_func_iconv.
26719         (am_cv_lib_iconv): Renamed from jm_cv_lib_iconv.
26720         (am_cv_proto_iconv): Renamed from jm_cv_proto_iconv.
26721         * m4/jm-macros.m4 (jm_MACROS): Reflect s/jm_/AM_/ renamings.
26722
26723         * m4/c-bs-a.m4 (AC_C_BACKSLASH_A): Quote first arg of AC_DEFUN.
26724         * m4/getline.m4 (AM_FUNC_GETLINE): Likewise.
26725         * m4/glibc21.m4 (jm_GLIBC21): Likewise.
26726         * m4/inttypes_h.m4 (jm_AC_HEADER_INTTYPES_H): Likewise.
26727         * m4/isc-posix.m4 (AC_ISC_POSIX): Likewise.
26728         * m4/lcmessage.m4 (AM_LC_MESSAGES): Likewise.
26729         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): Likewise.
26730         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Likewise.
26731         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Likewise.
26732
26733         * m4/getline.m4 (AM_FUNC_GETLINE): Don't bother checking for
26734         string.h any more.
26735
26736         * m4/progtest.m4 (AM_PATH_PROG_WITH_TEST): If not found, print "no",
26737         not the default value.
26738
26739         2001-06-25  Bruno Haible  <haible@clisp.cons.org>
26740         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Don't require AM_C_PROTOTYPES.
26741         Also check for mbsinit.  Needed for SCO 3.2v5.0.2.
26742         Also include <string.h>; this is where AIX 3.2.5 declares wcwidth.
26743         Also check for iswcntrl, used for wcwidth fallback.
26744         Use AC_TRY_COMPILE to emulate AC_CHECK_DECLS, for portability
26745         to Autoconf 2.13.
26746
26747 2001-08-03  Jim Meyering  <meyering@lucent.com>
26748
26749         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Use `#include', not `@%:@include',
26750         as it was in the original.  Reported by Paul Eggert.
26751
26752 2001-07-16  Jim Meyering  <meyering@lucent.com>
26753
26754         * m4/gettimeofday.m4: New file.
26755         Prompted by a report from Bernhard Baehr.
26756
26757 2001-07-15  Jim Meyering  <meyering@lucent.com>
26758
26759         * m4/Makefile.am.in (Makefile.am): Remove most of the unlocked-io.h
26760         stuff. Now it's in ../Makefile.cfg.
26761
26762 2001-07-15  Jim Meyering  <meyering@lucent.com>
26763
26764         * lib/Makefile.am (EXTRA_DIST): Add unlocked-io.hin.
26765         (BUILT_SOURCES): Add unlocked-io.h.
26766         (io_functions): Define.
26767         (unlocked-io.h): New rule.
26768         (DISTCLEANFILES): Add unlocked-io.h.
26769         (all-local): Depend on unlocked-io.h, to ensure it is created.
26770
26771         * lib/unlocked-io.hin: New file
26772
26773         * lib/regex.c: Update from glibc.
26774
26775 2001-07-05  Jim Meyering  <meyering@lucent.com>
26776
26777         * lib/Makefile.am (noinst_HEADERS): Remove definition, per new automake
26778         recommendation.
26779         (libfetish_a_SOURCES): Put all .h files here instead.
26780         Remove a thus-exposed (better checks in automake) duplicate and
26781         two unnecessary .h files.
26782
26783 2001-07-04  Jim Meyering  <meyering@lucent.com>
26784
26785         * m4/Makefile.am.in (glibc-io.struct): New target.  Rework the code
26786         that generates jm-glibc-io.m4 so that it doesn't trigger any make
26787         distcheck failure.
26788
26789 2001-07-02  Jim Meyering  <meyering@lucent.com>
26790
26791         The following changes were prompted by suggestions from Bruno Haible.
26792
26793         * m4/jm-glibc-io.m4n: New file, the template from which jm-glibc-io.m4
26794         is now generated.
26795         * m4/Makefile.am.in (Makefile.am): Include jm-glibc-io.m4n in emitted
26796         definition of EXTRA_DIST.
26797         (Makefile.am): Emit the dependency, `all-local: jm-glibc-io.m4' to
26798         ensure that the generated file is created/updated whenever the list
26799         of $(unlocked_functions) is changed.
26800         (jm-glibc-io.m4): New rule.
26801         (unlocked-io.h): New rule -- currently unused.
26802
26803 2001-06-24  Jim Meyering  <meyering@lucent.com>
26804
26805         * m4/regex.m4 (jm_INCLUDED_REGEX): Use a quadrigraph to represent an
26806         unmatched right bracket, rather than kludging it with an extra,
26807         falsely-matching quote in a comment.  Patch by Akim Demaille.
26808
26809 2001-06-11  Jim Meyering  <meyering@lucent.com>
26810
26811         * lib/regex.c: Update from GNU libc.
26812
26813 2001-05-27  Jim Meyering  <meyering@lucent.com>
26814
26815         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for ut_type in struct utmpx.
26816         Check for ut_type in struct utmp.
26817
26818 2001-05-27  Jim Meyering  <meyering@lucent.com>
26819
26820         * lib/readutmp.h (UT_TYPE): Define.
26821
26822 2001-05-24  Jim Meyering  <meyering@lucent.com>
26823
26824         * lib/argmatch.c: Include "quote.h".
26825         (argmatch_invalid): Remove explicit `' quotes.  Instead, use the
26826         quote function.  Reported by Göran Uddeborg.
26827
26828 2001-05-22  Jim Meyering  <meyering@lucent.com>
26829
26830         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Don't use AC_LIBOBJ(strftime),
26831         now that we use the package-supplied version unconditionally.
26832         (jm_FUNC_STRFTIME): Don't replace strftime, for the same reason.
26833
26834 2001-05-21  Jim Meyering  <meyering@lucent.com>
26835
26836         * m4/regex.m4: Change a couple backticks to single quotes to avoid
26837         shell syntax errors.
26838
26839 2001-05-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26840
26841         * m4/dos.m4 (jm_AC_DOS): Check for _WIN32, __WIN32__, and __MSDOS__.
26842
26843 2001-05-20  Paul Eggert  <eggert@twinsun.com>
26844
26845         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME):
26846         Don't bother to check library strftime, since
26847         we'll be using our own my_strftime function anyway.
26848         Define my_strftime instead of strftime.
26849
26850 2001-05-20  Alexandre Duret-Lutz  <duret_g@epita.fr>
26851
26852         * lib/dirname.c (dir_name): Compute append_dot using path, not newpath
26853         which is not yet declared.
26854
26855 2001-05-15  Jim Meyering  <meyering@lucent.com>
26856
26857         * m4/regex.m4: Use proper quoting so brackets appear in the test
26858         program.
26859         Reported by, and with help from, Bruno Haible.
26860
26861 2001-05-13  Jim Meyering  <meyering@lucent.com>
26862
26863         * m4/jm-macros.m4 (major_t, minor_t): Define to unsigned int if
26864         undefined.
26865
26866 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26867
26868         dirname code cleanup.  base_name now behaves more compatibly
26869         with POSIX basename when given file names that have trailing
26870         slashes, and similarly for dir_name.  Add new primitives
26871         base_len and dir_len.  Put the directory-name-related decls
26872         into dirname.h.
26873
26874         * lib/addext.c (ISSLASH, base_name): Remove; now in dirname.h.
26875         * lib/backupfile.c (base_name): Likewise.
26876         * lib/basename.c (FILESYSTEM_PREFIX_LEN, PARAMS, ISSLASH): Likewise.
26877         * lib/dirname.c (FILESYSTEM_PREFIX_LEN, ISSLASH): Likewise.
26878         * lib/makepath.c (strip_trailing_slashes): Likewise.
26879         * lib/path-concat.c (DIRECTORY_SEPARATOR, FILESYSTEM_PREFIX_LEN,
26880         ISSLASH): Likewise.
26881         * lib/rename.c (strip_trailing_slashes): Likewise.
26882         * lib/same.c (base_name): Likewise.
26883         * lib/stripslash.c (ISSLASH): Likewise.
26884
26885         * lib/addext.c: Include <dirname.h> after size_t is defined.
26886         * lib/backupfile.c: Likewise.
26887
26888         * lib/addext.c (addext): Use base_len to trim redundant
26889         trailing slashes instead of doing it ourselves.
26890         But do not trim the last slash if it is not redundant.
26891
26892         * lib/backupfile.c (find_backup_file_name,
26893         max_backup_version): Use base_len instead of rolling it ourselves.
26894         Handle the case of "" and (on DOS) "C:" correctly.
26895
26896         * lib/basename.c: Do not include <stdio.h>, <assert.h>; no longer
26897         needed. Include <string.h>, <dirname.h>.
26898         (base_name): Allow file names ending in slashes, other than names
26899         that are all slashes.  In this case, return the basename followed
26900         by the slashes.  This is more general, and can be used in places
26901         where the original base_name purposely had an assertion failure.
26902         (base_len): New function.
26903
26904         * lib/dirname.c: Include <string.h> instead of <stdlib.h>.
26905         Do not include <assert.h>; no longer needed.
26906         Include xalloc.h.
26907         (memrchr): Remove decl.
26908         (dir_name_r): Remove.
26909         (dir_len): Renamed from dirlen.  All callers changed.
26910         Rewrite in terms of base_name, for simplicity and consistency.
26911         (dir_name): Never return NULL.  All callers changed.
26912         Do not include <stdlib.h> in test program; no longer needed.
26913         return 0; is fine for test program.
26914
26915         * lib/dirname.h (DIRECTORY_SEPARATOR, ISSLASH, FILESYSTEM_PREFIX_LEN):
26916         New macros.
26917         (base_name, base_len, dir_len, strip_trailing_slashes): New decls.
26918
26919         * lib/path-concat.c (path_concat): Use base_len to compute
26920         base length, not strlen; this means we cannot rely on memcpy
26921         to null-terminate.
26922
26923         * lib/same.c (STREQ): Remove.
26924         (same_name): Handle the case where the basename ends in trailing '/'.
26925
26926         * lib/stripslash.c (strip_trailing_slashes): Return nonzero if
26927         a slash was stripped.  Do not strip the last slash after a
26928         file system prefix.
26929
26930 2001-05-11  Paul Eggert  <eggert@twinsun.com>
26931
26932         * lib/Makefile.am (libfetish_a_SOURCES):
26933         Add strftime.c, since we now compile it on all hosts.
26934
26935         * lib/strftime.c (my_strftime):
26936         Define to nstrftime if emacs, but only if my_strftime is not defined.
26937         (extra_args, extra_args_spec, extra_args_spec_iso): Rename from
26938         ut_argument, ut_argument_spec, ut_argument_spec_iso, respectively.
26939         Add one more extra argument: a nanoseconds value.
26940         All uses changed.
26941         (ns): New macro.
26942         (my_strftime function): Add %N format.
26943         (emacs_strftimeu): Renamed from emacs_strftime,
26944         with extra ut argument.
26945
26946 2001-05-09  Paul Eggert  <eggert@twinsun.com>
26947
26948         * m4/jm-macros.m4 (jm_MACROS): Do not check for fseeko; no longer used.
26949
26950 2001-04-21  Jim Meyering  <meyering@lucent.com>
26951
26952         * m4/rmdir-errno.m4: Write to a new file, so that a restrictive umask
26953         doesn't interfere.
26954
26955 2001-04-21  Alexandre Duret-Lutz  <duret_g@epita.fr>
26956
26957         * m4/ftruncate.m4: Check for chsize.
26958         Link with ftruncate.o unconditionally if ftruncate is missing.
26959         This was required when cross-compiling to i586-mingw32msvc.
26960
26961 2001-04-08  Jim Meyering  <meyering@lucent.com>
26962
26963         * lib/getdate.y (get_date): Set tm_isdst to -1 to ensure that it is
26964         recomputed; that's necessary when the offset spans a DST transition.
26965         Patch by David J. MacKenzie.  Reported by Hon-Yin Kok.
26966
26967 2001-04-02  Jim Meyering  <meyering@lucent.com>
26968
26969         * lib/regex.h, regex.c: Update from GNU libc.
26970
26971 2001-03-24  Jim Meyering  <meyering@lucent.com>
26972
26973         * m4/jm-macros.m4: Require autoconf-2.49d.
26974
26975 2001-03-20  Bruno Haible  <haible@clisp.cons.org>
26976
26977         * m4/iconv.m4 (jm_ICONV): Recommend GNU libiconv.
26978
26979 2001-03-19  Paul Eggert  <eggert@twinsun.com>
26980
26981         * lib/version-etc.c (version_etc_copyright): Update to 2001.
26982
26983 2001-03-17  Jim Meyering  <meyering@lucent.com>
26984
26985         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Remove my copy of AC_FUNC_MEMCMP,
26986         now that the version in autoconf is equivalent.
26987         (jm_FUNC_MEMCMP): Adjust to use AC_FUNC_MEMCMP.
26988
26989         * m4/error.m4 (jm_PREREQ_ERROR): Invoke AC_FUNC_STRERROR_R.
26990         Suggestion from Akim Demaille.
26991
26992         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_TEMPNAME.
26993         (jm_PREREQ_TEMPNAME): New function.
26994
26995 2001-03-16  Paul Eggert  <eggert@twinsun.com>
26996
26997         * lib/tempname.c (uint64_t): Define to uintmax_t if
26998         not defined, and if UINT64_MAX is not defined.
26999         Required at least for Vax Ultrix4.3, which doesn't define uint64_t.
27000         Reported by John David Anglin.
27001
27002 2001-03-15  Bruno Haible  <haible@clisp.cons.org>
27003
27004         * lib/localcharset.c (locale_charset): Allow wildcard syntax. Also
27005         resolve alias if codeset is empty.
27006         * lib/config.charset (BeOS): Use wildcard syntax.
27007
27008 2001-03-13  Jim Meyering  <meyering@lucent.com>
27009
27010         * lib/path-concat.c (path_concat)
27011         [FILESYSTEM_ACCEPTS_DRIVE_LETTER_PREFIX]: Don't insert a backslash when
27012         concatenating e.g., `C:' and `foo'.
27013         From Bruno Haible.
27014
27015 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
27016
27017         * lib/localcharset.c (locale_charset): Don't use
27018         setlocale(LC_CTYPE,NULL). Don't return NULL.
27019         * lib/unicodeio.c (print_unicode_char): Simplify accordingly.
27020
27021 2001-03-06  Bruno Haible  <haible@clisp.cons.org>
27022
27023         * lib/config.charset: Update for FreeBSD 4.2 and OSF/1 5.1. Add
27024         support for DOS/DJGPP.
27025
27026 2001-03-01  Paul Eggert  <eggert@twinsun.com>
27027
27028         * m4/jm-macros.m4 (jm_MACROS): Use mkstemp replacement if the system
27029         lacks mkstemp.  Compile our own tempname.c if we compile our own
27030         mkstemp.c, as mkstemp relies on tempname.
27031
27032 2001-03-01  Jim Meyering  <meyering@lucent.com>
27033
27034         * m4/dos.m4 (jm_AC_DOS): Remove extra backslashes, now that
27035         AH_VERBATIM really does output its argument verbatim.
27036
27037 2001-02-28  Paul Eggert  <eggert@twinsun.com>
27038
27039         * lib/Makefile.am (libfetish_a_SOURCES):
27040         Add dup-safer.c, fopen-safer.c.
27041         (noinst_HEADERS): Add stdio-safer.h, unistd-safer.h.
27042
27043         * lib/dup-safer.c, lib/fopen-safer.c, lib/stdio-safer.h:
27044         * lib/unistd-safer.h: New files.
27045
27046 2001-02-25  Paul Eggert  <eggert@twinsun.com>
27047
27048         The mkstemp replacement is taken from glibc 2.2.2, with some
27049         portability fixes for use outside glibc, as follows:
27050
27051         * lib/tempname.c (struct_stat64): New macro.
27052         (direxists, __gen_tempname): Use it.
27053         This avoids a portability problem with Solaris 8.
27054
27055         * lib/tempname.c (<config.h>): Include if HAVE_CONFIG_H.
27056         (<stddef.h>, <stdint.h>, <string.h>):
27057         Include only if STDC_HEADERS || _LIBC.
27058         (<fcntl.h>): Include only if HAVE_FCNTL_H || _LIBC.
27059         (<unistd.h>): Include only if HAVE_UNISTD_H || _LIBC.
27060         (<sys/time.h>): Include only if HAVE_SYS_TIME_H || _LIBC.
27061         (__set_errno): Define this macro if <errno.h> doesn't.
27062         (P_tmpdir, TMP_MAX, __GT_FILE, __GT_BIGFILE, __GT_DIR, __GT_NOCREATE):
27063         Define these macros if <stdio.h> doesn't.
27064         (S_ISDIR, S_IRUSR, S_IWUSR, S_IXUSR):
27065         Define these macros if <sys/stat.h>
27066         doesn't.  Ignore <sys/stat.h> S_ISDIR if STAT_MACROS_BROKEN.
27067         (stat64, __getpid, __gettimeofday, __mkdir, __open, __open64, lxstat64,
27068         __xstat64): Define if not _LIBC.
27069         (__secure_getenv): Define if ! (HAVE___SECURE_GETENV || _LIBC).
27070         (__gen_tempname): Invoke gettimeofday only if
27071         HAVE_GETTIMEOFDAY || _LIBC;
27072         otherwise, fall back on plain "time".
27073         Use macros like S_IRUSR | S_IWUSR rather than octal values like 0600.
27074
27075         * lib/mkstemp.c (__GT_FILE): Define to zero if not defined.
27076
27077         * lib/mkstemp.c, lib/tempname.c: New files, taken from glibc 2.2.2.
27078
27079 2001-02-18  Paul Eggert  <eggert@twinsun.com>
27080
27081         * m4/jm-macros.m4 (jm_CHECK_ALL_HEADERS): Check for sys/resource.h.
27082
27083 2001-02-17  Paul Eggert  <eggert@twinsun.com>
27084
27085         * m4/mbrtowc.m4: New file, defining jm_FUNC_MBRTOWC.
27086         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH):
27087         Use jm_FUNC_MBRTOWC, not AC_CHECK_FUNCS(mbrtowc).
27088         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Likewise.
27089
27090 2001-02-17  Paul Eggert  <eggert@twinsun.com>
27091
27092         * lib/mbswidth.c, quotearg.c (mbrtowc, mbsinit):
27093         Remove workaround macros for hosts that have mbrtowc but not
27094         mbstate_t, as we now insist on proper declarations for both
27095         before using mbrtowc.
27096
27097 2001-02-17  Jim Meyering  <meyering@lucent.com>
27098
27099         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Don't check for
27100         getmntent via AC_CHECK_FUNCS, since that would get a `no' and disrupt
27101         further attempts by AC_FUNC_GETMNTENT to check with e.g., -lgen on
27102         UnixWare 7.1.1.
27103
27104         * m4/mbrtowc.m4 (jm_FUNC_MBRTOWC): Adapt to use AC_CACHE_CHECK etc.,
27105         rather than AC_CACHE_VAL.
27106
27107 2001-02-17  Jim Meyering  <meyering@lucent.com>
27108
27109         * lib/strtoul.c: Sync from GNU libc.  Use double quotes, not <...>
27110         around included file name.
27111
27112         * lib/strnlen.c (__strnlen): Merge in a change from GNU libc.
27113
27114         * lib/strftime.c: Update from GNU libc (the only changes were to
27115         comments).
27116
27117 2001-02-17  Jim Meyering  <meyering@lucent.com>
27118
27119         * lib/regex.c: Update from libc.
27120
27121 2001-02-17  Bruno Haible  <haible@clisp.cons.org>
27122
27123         * lib/mbswidth.h (mbswidth): Also define as macro, to avoid prototype
27124         clash.
27125
27126 2001-02-16  Paul Eggert  <eggert@twinsun.com>
27127
27128         * lib/alloca.c (malloc): Undef before defining, since stdlib.h
27129         may have defined it.  Needed for Encore Umax-3.0.9.16b systems.
27130         Reported by Mark Hounschell via Paul Eggert.
27131
27132 2001-02-07  Jim Meyering  <meyering@lucent.com>
27133
27134         * m4/regex.m4 (jm_INCLUDED_REGEX): Add a test for the latest bug.
27135
27136 2001-02-05  Jim Meyering  <meyering@lucent.com>
27137
27138         * m4/jm-macros.m4: Require autoconf-2.14d (not yet released), because
27139         it includes the patch required for `large file' support with at least
27140         HP-UX's 10.20 /bin/cc.
27141
27142 2001-02-03  Jim Meyering  <meyering@lucent.com>
27143
27144         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Restore prior use of
27145         AS_IF, now that it works once again (mysteriously).
27146         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
27147
27148 2001-01-30  Jim Meyering  <meyering@lucent.com>
27149
27150         Don't use filenames that are 8.3-equivalent to "conftest" on DOS.
27151         * m4/chown.m4: Rename conftestchown to conftest.chown.
27152         * m4/rename.m4: s/conftestdir/conftest.d1/ and
27153         s/conftestdir2/conftest.d2/.
27154         * m4/utimes.m4: s/conftestdata/conftest.data/
27155         Inspired by Pavel Roskin's change in autoconf.
27156
27157 2001-01-30  Bruno Haible  <haible@clisp.cons.org>
27158
27159         * lib/config.charset: Update for FreeBSD 4.2.
27160
27161 2001-01-27  Jim Meyering  <meyering@lucent.com>
27162
27163         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Open-code what was
27164         a use of AS_IF.
27165         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Likewise.
27166
27167 2001-01-26  Jim Meyering  <meyering@lucent.com>
27168
27169         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Check for stddef.h, now that
27170         quotearg.c includes it.
27171
27172 2001-01-26  Jim Meyering  <meyering@lucent.com>
27173
27174         * lib/quotearg.c: Include stddef.h.
27175         * lib/quote.c: Include stddef.h.
27176         Reported by Axel Kittenberger.
27177
27178         * lib/xmalloc.c [HAVE_DONE_WORKING_MALLOC_CHECK]: Enclose error-evoking
27179         line in double quotes so that it evokes a better diagnostic.
27180         [HAVE_DONE_WORKING_REALLOC_CHECK]: Likewise.
27181         Reported by Axel Kittenberger.
27182
27183 2001-01-24  Stefan Monnier  <monnier@cs.yale.edu>
27184
27185         * regex.c (mutually_exclusive_p): Don't blindly handle `charset_not'
27186         as if it was a `charset'.
27187
27188 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27189
27190         * m4/iconv.m4 (jm_ICONV): Also check whether the iconv declaration
27191         has const.
27192
27193 2001-01-21  Bruno Haible  <haible@clisp.cons.org>
27194
27195         * lib/unicodeio.c (print_unicode_char): Cast the second iconv() arg,
27196         to avoid a warning.  Add back 'const' to inptr.
27197
27198 2001-01-20  Jim Meyering  <meyering@lucent.com>
27199
27200         Be sure that headers are checked before used in code compiled
27201         for the type checks.
27202         * m4/jm-macros.m4 (jm_MACROS): Remove all header checks.
27203         In place of that, invoke jm_CHECK_ALL_TYPES.
27204         (jm_CHECK_ALL_HEADERS): New functions with the above checks.
27205         (jm_CHECK_ALL_TYPES): Require jm_CHECK_ALL_HEADERS.
27206         Alan Iwi reported a build failure on an f300-fujitsu-uxpv4.1_ES;
27207         The check for ssize_t was mistakenly run before the test for unistd.h.
27208
27209         The configure-time check for stdbool.h was missing.
27210         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_HASH.
27211         (jm_PREREQ_HASH): New function.
27212
27213 2001-01-17  Jim Meyering  <meyering@lucent.com>
27214
27215         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use AS_IF, not AS_IFELSE,
27216         for autoconf-2.49c.
27217         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Likewise.
27218
27219 2001-01-16  Jim Meyering  <meyering@lucent.com>
27220
27221         * lib/basename.c: Include <stdio.h>, needed by assert on SunOS 4.
27222         From Bruno Haible.
27223
27224 2001-01-14  Jim Meyering  <meyering@lucent.com>
27225
27226         * m4/rename.m4: Use temporary directories named conftestdir{,2}, not
27227         foo and bar.  Create conftestdir/ in the script, not in the C code.
27228         Remove directories in the script, not in the C code.
27229         Remove conftestdir{,2} before trying to create the directory.
27230         Make the entire configure script fail if the mkdir fails.
27231
27232 2001-01-14  Jim Meyering  <meyering@lucent.com>
27233
27234         * lib/rename.c: New file.  From Volker Borchert.
27235         Include stdlib.h, string.h or strings.h, and xalloc.h.
27236         Use strip_trailing_slashes rather than open-coding it.
27237
27238 2001-01-03  Paul Eggert  <eggert@twinsun.com>
27239
27240         * lib/strftime.c: Sync with glibc time/strftime.c 1.81.
27241
27242 2001-01-03  Jim Meyering  <meyering@lucent.com>
27243
27244         * lib/unicodeio.c (print_unicode_char): Remove `const' from declaration
27245         of local `inptr' to avoid warning with some system declarations of
27246         iconv.
27247
27248 2001-01-02  Volker Borchert  <bt@teknon.de>
27249
27250         * m4/rename.m4: New file.
27251         * m4/jm-macros.m4 (jm_MACROS): Require vb_FUNC_RENAME.
27252
27253 2001-01-01  Jim Meyering  <meyering@lucent.com>
27254
27255         * m4/prereq.m4 (jm_PREREQ_READUTMP): Include utmp.h (if available),
27256         even on systems with utmpx.h.  It's necessary for the declaration of
27257         utmp's ut_user member.  Reported by Andreas Jaeger.
27258
27259         * m4/check-decl.m4 (jm_CHECK_DECLS): Include grp.h and pwd.h if
27260         available. They are required for the declarations of getgrgid and
27261         getpwuid resp.
27262         (_jm_DECL_HEADERS): Check for grp.h and pwd.h.
27263         Reported by Andreas Jaeger.
27264
27265 2001-01-01  Alexandre Duret-Lutz  <duret_g@epita.fr>
27266
27267         * m4/libintl.m4 (AM_GNU_GETTEXT): Define MKINSTALLDIRS by
27268         expanding the value of $ac_aux_dir, as in AM_MISSING_HAS_RUN,
27269         so `make install' also works in VPATH builds.
27270
27271 2000-12-31  Alexandre Duret-Lutz  <duret_g@epita.fr>
27272
27273         * m4/libintl.m4 (AM_WITH_NLS): When using AC_CONFIG_AUX_DIR,
27274         prepend $(top_srcdir) to the value of MKINSTALLDIRS so that it
27275         can be used in subdirectories.
27276
27277 2000-12-29  Paul Eggert  <eggert@twinsun.com>
27278
27279         * lib/modechange.c: Do not assume that mode_t uses the
27280         traditional octal encoding.  E.g. "chmod 1 FOO" should set
27281         the other-execute bit of FOO even if S_IXOTH != 1.
27282
27283         (SUID, SGID, SVTX, RUSR, WUSR, XUSR, RGRP, WGRP, XGRP, ROTH,
27284         WOTH, XOTH, ALLM): New macros.
27285         (S_ISUID, S_ISGID, S_ISVTX, S_IRUSR, S_IWUSR, S_IXUSR,
27286          S_IRGRP, S_IWGRP, S_IXGRP, S_IROTH, S_IWOTH, S_IXOTH):
27287         Use them.
27288         (S_ISGID): Fix typo; it was defaulting to the same value as S_ISUID.
27289         (S_IRWXU, S_IRWXG, S_IRWXO): Specify defaults in terms of the above.
27290         (mode_compile):
27291         No need to use uintmax_t; unsigned long is long enough.
27292         Don't bother to get suffix since we don't use it.
27293
27294 2000-12-26  Jim Meyering  <meyering@lucent.com>
27295
27296         * m4/dos.m4 (jm_AC_DOS): Rewrite (though it's still a stub) to work
27297         better with autoheader.
27298
27299 2000-12-24  Jim Meyering  <meyering@lucent.com>
27300
27301         * lib/hash.c (is_prime): Return explicit boolean values.
27302         (hash_get_first): Return NULL to appease Irix5.6's 89.
27303         Reported by Nelson Beebe.
27304
27305 2000-12-19  Bruno Haible  <haible@clisp.cons.org>
27306
27307         * lib/localcharset.c (locale_charset): Add support for Win32.
27308
27309 2000-12-18  Paul Eggert  <eggert@twinsun.com>
27310
27311         * lib/physmem.h, lib/physmem.c: New files.
27312
27313         * lib/Makefile.am (libfetish_a_SOURCES): Add physmem.c.
27314         (noinst_HEADERS): Add physmem.h.
27315
27316         * lib/xstrtol.c (__xstrtol): Add undocumented suffixes 'g' and
27317         't' for compatibility with Solaris 8 sort.
27318
27319 2000-12-18  Bruno Haible  <haible@clisp.cons.org>
27320
27321         * lib/config.charset: Add support for BeOS.
27322
27323 2000-12-17  Jim Meyering  <meyering@lucent.com>
27324
27325         * m4/dos.m4 (jm_AC_DOS): New file and macro.
27326         * m4/jm-macros.m4 (jm_MACROS): Require jm_AC_DOS.
27327
27328 2000-12-16  Jim Meyering  <meyering@lucent.com>
27329
27330         This bug had a serious impact on chown: `chown N:M FILE' (for integer
27331         N and M) would have treated it like `chown N:N FILE'.
27332
27333         * lib/userspec.c (parse_user_spec): Fix typo: s/u/g/.
27334
27335 2000-12-16  Jim Meyering  <meyering@lucent.com>
27336
27337         * lib/getusershell.c [!SHELLS_FILE && __DJGPP__]: Define
27338         SHELLS_FILE to a file name that's useful on djgpp systems.
27339         Include stdlib.h.
27340         (ADDITIONAL_DEFAULT_SHELLS): Define.
27341         (default_shells): Prepend ADDITIONAL_DEFAULT_SHELLS.
27342         Based mostly on a patch from Prashant TR.
27343
27344 2000-12-16  Bruno Haible  <haible@clisp.cons.org>
27345
27346         * lib/config.charset: Add ISO-8859-3, BIG5HKSCS, GB18030, JOHAB,
27347         VISCII, CP874, CP949, CP950, CP1250, CP1253, CP1254, CP1255, CP1256,
27348         CP1257 to the list of canonical encodings. Rename EUC-CN to GB2312.
27349
27350 2000-12-08  Andreas Schwab  <schwab@suse.de>
27351
27352         * lib/mbswidth.c (mbsnwidth): Don't loop endlessly when called with an
27353         invalid mulitbyte sequence and with the MBSW_ACCEPT_INVALID flag set.
27354
27355 2000-12-07  Jim Meyering  <meyering@lucent.com>
27356
27357         * lib/stripslash.c (ISSLASH): Define.
27358         (strip_trailing_slashes): Use ISSLASH rather than comparing against
27359         `/'.
27360         From Prashant TR.
27361
27362         * lib/dirname.c (FILESYSTEM_PREFIX_LEN): Define.
27363         (dir_name_r): Declare this function as static.
27364         [BACKSLASH_IS_PATH_SEPARATOR]: Fix a bug that'd
27365         manifest itself on a name containing a mix of slashes and
27366         backslashes.
27367         Make this function work with names starting with a DOS-style
27368         drive letter and colon prefix.
27369         (dir_name): Append `.' if necessary.
27370         Based mostly on patches from Prashant TR and Eli Zaretskii.
27371
27372         * lib/dirname.h (dir_name_r): Remove prototype.
27373
27374 2000-12-06  Paul Eggert  <eggert@twinsun.com>
27375
27376         * m4/off_t-format.m4: Remove this file.
27377         * m4/jm-macros.m4 (jm_MACROS): Remove jm_SYS_OFF_T_PRINTF_FORMAT.
27378
27379 2000-12-06  Jim Meyering  <meyering@lucent.com>
27380
27381         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): If we need the
27382         replacement strtoull, we may well need the replacement strtoul, too.
27383         Check for declarations of strtoul and strtoull.
27384         Check for strtol.  Mainly as a cue to cause automake to include
27385         strtol.c -- that file is included by each of strtoul.c and strtoull.c.
27386         Check for limits.h -- strtol.c needs it.
27387
27388 2000-12-05  Jim Meyering  <meyering@lucent.com>
27389
27390         * lib/dirname.c (dir_name_r): Add `const' in a few local declarations.
27391
27392 2000-12-04  Jim Meyering  <meyering@lucent.com>
27393
27394         * lib/path-concat.c: [!HAVE_DECL_MALLOC]: Declare malloc.
27395         Also include memory.h, stdlib.h, unistd.h if appropriate.
27396         Reported by Andreas Jaeger (conflicting declaration of malloc).
27397
27398 2000-12-02  Jim Meyering  <meyering@lucent.com>
27399
27400         * m4/off_t-format.m4 (OFF_T_PRINTF_FORMAT_STRING): New file/macro.
27401         * m4/jm-macros.m4 (jm_MACROS): require it.
27402
27403 2000-12-02  Jim Meyering  <meyering@lucent.com>
27404
27405         * lib/closeout.h: Make idempotent, to avoid some obscure warnings.
27406
27407 2000-12-01  Paul Eggert  <eggert@twinsun.com>
27408
27409         * lib/memrchr.c: Include <config.h> before any system include file.
27410
27411 2000-11-30  Jim Meyering  <meyering@lucent.com>
27412
27413         * m4/jm-macros.m4 (jm_MACROS): Check for stdint.h.
27414
27415 2000-11-30  Jim Meyering  <meyering@lucent.com>
27416
27417         * m4/getloadavg.m4: s/ifval/m4_ifval/ to accommodate new autoconf.
27418
27419 2000-11-29  Paul Eggert  <eggert@twinsun.com>
27420
27421         * lib/dirname.c (dir_name_r): Fix typo: int -> size_t.
27422
27423 2000-11-26  Jim Meyering  <meyering@lucent.com>
27424
27425         * lib/memcoll.c: Include sys/types.h.  From Werner Almesberger.
27426
27427 2000-11-22  Paul Eggert  <eggert@twinsun.com>
27428
27429         * lib/strftime.c (my_strftime): Do not invoke mbrlen with a
27430         size of (size_t) -1; it's not portable.
27431
27432 2000-11-17  Jim Meyering  <meyering@lucent.com>
27433
27434         * lib/strstr.c: Update from GNU libc.
27435
27436 2000-11-17  Akim Demaille  <akim@epita.fr>
27437
27438         * lib/obstack.h: Formatting changes.
27439         (obstack_grow, obstack_grow0): Don't cast WHERE at all: that would
27440         prevent type checking.
27441         (obstack_ptr_grow, obstack_ptr_grow_fast): When assigning, don't
27442         cast the value to (void *): assigning a `foo *' to a `void *'
27443         variable is valid.
27444         (obstack_int_grow, obstack_int_grow_fast): Don't cast AINT to int.
27445
27446 2000-11-16  Jim Meyering  <meyering@lucent.com>
27447
27448         * lib/strverscmp.c: Incorporate weak-alias-related changes from glibc.
27449
27450 2000-11-11  Jim Meyering  <meyering@lucent.com>
27451
27452         * lib/error.c: Add a couple #includes, merging from GNU libc version.
27453
27454 2000-11-10  Jim Meyering  <meyering@lucent.com>
27455
27456         * lib/obstack.h: Update from GNU libc.
27457         * lib/obstack.c: Likewise.
27458
27459 2000-11-08  Bruno Haible  <haible@clisp.cons.org>
27460
27461         * m4/jm-macros.m4 (jm_MACROS): Add test for wcrtomb.
27462
27463 2000-11-06  Paul Eggert  <eggert@twinsun.com>
27464
27465         * lib/getusershell.c (setusershell): Use rewind rather than
27466         fseek/fseeko, to avoid configuration hassles with fseeko.
27467         Don't bother opening SHELLS_FILE if shellstream is NULL;
27468         it's not necessary.
27469
27470 2000-11-05  Jim Meyering  <meyering@lucent.com>
27471
27472         * lib/makepath.h (make_dir): Declare.
27473         * lib/makepath.c (make_dir): Remove `static' attribute.
27474         Tweak a comment.
27475
27476 2000-11-04  Jim Meyering  <meyering@lucent.com>
27477
27478         * m4/regex.m4: Use the `m4_' prefix on `syscmd' and `m4_sysval'.
27479
27480 2000-11-04  Alexandre Duret-Lutz  <duret_g@epita.fr>
27481
27482         * lib/hash.c (hash_get_next): Fix a thinko:  when ENTRY is the
27483         last one in a bucket, advance to the next bucket.
27484
27485 2000-11-02  Vesselin Atanasov  <vesselin@bgnet.bg>
27486
27487         * lib/fnmatch.c: Do not comment out all the code if we are using
27488         the GNU C library, because in some cases we are replacing buggy
27489         code in the GNU C library itself.
27490
27491 2000-10-30  Stefan Monnier  <monnier@cs.yale.edu>
27492
27493         * regex.c (re_iswctype, re_wctype_to_bit): Fix braino.
27494         (regex_compile): Catch bogus \(\1\).
27495
27496 2000-10-30  Paul Eggert  <eggert@twinsun.com>
27497
27498         * lib/fnmatch.c (FOLD): Do not assume that characters are unsigned.
27499         (fnmatch): Fix some FNM_FILE_NAME and FNM_LEADING_DIR bugs,
27500         e.g. fnmatch("d*/*1", "d/s/1", FNM_FILE_NAME) incorrectly yielded zero.
27501
27502 2000-10-30  Paul Eggert  <eggert@twinsun.com>
27503
27504         * lib/error.h, getline.h, modechange.h:
27505         Remove "2000" from Copyright line, as the file hasn't been
27506         changed this year other than in the copyright notice.
27507
27508         * lib/xalloc.h: Add "2000" to Copyright line, as this file
27509         was changed this year.
27510
27511 2000-10-29  Jim Meyering  <meyering@lucent.com>
27512
27513         * m4/fsusage.m4: s/AC_SHELL_IFELSE/AS_IFELSE/ to match autoconf
27514         renaming.
27515         * m4/ls-mntd-fs.m4: Likewise
27516
27517 2000-10-29  Jim Meyering  <meyering@lucent.com>
27518
27519         * lib/xstat.in: Fix grammar in comment.
27520
27521 2000-10-29  Greg Louis  <glouis@dynamicro.on.ca>
27522
27523         * lib/regex.h (__restrict_arr): Move definition out of #ifndef block.
27524         Required because egcs-2.91.66 (aka 1.1.2) defines __restrict, but
27525         doesn't define __restrict_arr.
27526
27527 2000-10-28  Jim Meyering  <meyering@lucent.com>
27528
27529         * m4/prereq.m4 (jm_PREREQ): Add jm_PREREQ_MEMCHR.
27530         (jm_PREREQ_MEMCHR): New function.
27531
27532 2000-10-28  Jim Meyering  <meyering@lucent.com>
27533
27534         * lib/memchr.c: Update from libc.
27535         Adjust for portability:
27536         [HAVE_STDLIB_H]: Include stdlib.h.
27537         [HAVE_BP_SYM_H || _LIBC]: Guard inclusion of bp-sym.h.
27538         Undef __memchr, too.
27539         [!weak_alias]: Define __memchr to memchr.
27540
27541         * lib/regex.c: Update from libc.
27542         * lib/regex.h: Likewise.
27543         * lib/getopt1.c: Likewise.
27544         * lib/memcmp.c: Likewise.
27545
27546         * lib/getusershell.c (setusershell) [HAVE_FSEEKO]: Use fseeko.
27547         Avoid using fseek, when possible -- it's broken by design.
27548         Patch by Ulrich Drepper.
27549
27550 2000-10-27  Stefan Monnier  <monnier@cs.yale.edu>
27551
27552         * regex.c (POP_FAILURE_REG_OR_COUNT, re_match_2_internal)
27553         (re_match_2_internal, re_match_2_internal, re_match_2_internal):
27554         Giving in to popular pressure to shut up the compiler with casts.
27555
27556 2000-10-26  Jim Meyering  <meyering@lucent.com>
27557
27558         * lib/strftime.c: Update from libc.
27559
27560 2000-10-25  Stefan Monnier  <monnier@cs.yale.edu>
27561
27562         * regex.c: More `unsigned char' -> `re_char' changes.
27563         Also change several `int' into `re_wchar_t'.
27564         (PATTERN_STACK_EMPTY, PUSH_PATTERN_OP, POP_PATTERN_OP): Remove.
27565         (PUSH_FAILURE_POINTER): Don't cast any more.
27566         (POP_FAILURE_REG_OR_COUNT): Remove the cast that strips `const'.
27567         We want GCC to complain, since this piece of code makes
27568         re_match non-reentrant, which *should* be fixed.
27569         (GET_BUFFER_SPACE): Use size_t rather than unsigned long.
27570         (EXTEND_BUFFER): Use RETALLOC.
27571         (SET_LIST_BIT): Don't cast.
27572         (re_wchar_t): New type.
27573         (re_iswctype, re_wctype_to_bit): Make it crystal clear to GCC
27574         that those two functions will always properly return.
27575         (IMMEDIATE_QUIT_CHECK): Cast to void.
27576         (analyse_first): Use recursion rather than an explicit stack.
27577         (re_compile_fastmap): Can't fail anymore.
27578         (re_search_2): Don't check re_compile_fastmap for failure.
27579         (PUSH_NUMBER): Renamed from PUSH_FAILURE_COUNT.
27580         Now also sets the new value (passed in a new argument).
27581         (re_match_2_internal): Use it.
27582         Also, use a new var `reg' of type size_t when looping through regs
27583         rather than reuse the inappropriate `mcnt'.
27584
27585 2000-10-25  Jim Meyering  <meyering@lucent.com>
27586
27587         * lib/obstack.c: Update from libc.
27588
27589 2000-10-24  Kenichi Handa  <handa@etl.go.jp>
27590
27591         * regex.c (regex_compile): Change the way of handling a range from
27592         a char less than 256 to a char not less than 256.
27593
27594 2000-10-24  Andrew Innes  <andrewi@gnu.org>
27595
27596         * regex.c (IMMEDIATE_QUIT_CHECK): New macro, which does QUIT on
27597         NT-Emacs only.
27598         (re_match_2_internal): Use IMMEDIATE_QUIT_CHECK instead of QUIT,
27599         so that re_search functions only quit when callers expect them to.
27600
27601 2000-10-23  Jim Meyering  <meyering@lucent.com>
27602
27603         * lib/hard-locale.c (hard_locale): Revert last change -- it was simply
27604         wrong.  That set_locale call must not have any side effects.
27605         From Paul Eggert.
27606
27607 2000-10-22  Jim Meyering  <meyering@lucent.com>
27608
27609         * lib/md5.c (md5_process_block) [OP]: Use `rol', not CYCLIC.
27610         [CYCLIC]: Remove now-unused definition.
27611
27612         * lib/save-cwd.c (O_DIRECTORY): Define, if needed.
27613         (save_cwd) [HAVE_FCHDIR]: Use O_DIRECTORY when opening ".".
27614         Suggestion from Ulrich Drepper.
27615
27616 2000-10-21  Jim Meyering  <meyering@lucent.com>
27617
27618         * m4/check-decl.m4 (jm_CHECK_DECLS): Also check for memrchr.
27619         * m4/prereq.m4 (jm_PREREQ_DIRNAME): New macro.
27620         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memrchr.
27621
27622 2000-10-21  Jim Meyering  <meyering@lucent.com>
27623
27624         * lib/dirname.c (memrchr): Declare if necessary.
27625         (dir_name): Remove the restriction that there be no
27626         trailing slashes.  Now, this code skips past them, effectively
27627         ignoring them.
27628         [TEST_DIRNAME] (main): New unit tests.
27629
27630         * lib/memrchr.c: New file from GNU libc.
27631         Undef __memrchr, too.
27632         [!weak_alias]: Define __memrchr to memrchr.
27633         Guard weak_alias use with `#ifdef weak_alias'.
27634
27635 2000-10-21  Jim Meyering  <meyering@lucent.com>
27636
27637         * lib/dirname.c (dir_name_r): New function, factored out of dir_name.
27638         (dir_name): Use dir_name_r.
27639         * lib/dirname.h (dir_name_r): Declare it.
27640
27641 2000-10-17  Jim Meyering  <meyering@lucent.com>
27642
27643         * lib/quote.h (PARAMS): Define and use.
27644         Reported by Akim Demaille.
27645
27646         * lib/getopt.c: Update from libc.
27647
27648 2000-10-16  Jim Meyering  <meyering@lucent.com>
27649
27650         * lib/hard-locale.c (hard_locale): Use "", not 0 as 2nd arg to
27651         setlocale.
27652         From Jan Fedak.
27653
27654 2000-10-15  Stefan Monnier  <monnier@cs.yale.edu>
27655
27656         * regex.c (WIDE_CHAR_SUPPORT): Define if _LIBC as well.
27657
27658 2000-09-25  Jim Meyering  <meyering@lucent.com>
27659
27660         * lib/md5.h (rol): Define (from GnuPG).
27661
27662         * lib/sha.c: Give credit (GnuPG) where due.
27663         (M): Use rol rather than open-coding it.
27664         Add a FIXME comment.
27665
27666 2000-09-21  Jim Meyering  <meyering@lucent.com>
27667
27668         * lib/userspec.c (parse_user_spec): Remove debugging printf I'd added.
27669         Reported by Michael Stone.
27670
27671 2000-09-20  Jim Meyering  <meyering@lucent.com>
27672
27673         * lib/Makefile.am (libfetish_a_SOURCES): Add sha.c.
27674         (noinst_HEADERS): Add sha.h.
27675         Based on code from Scott G. Miller and from GnuPG.
27676
27677 2000-09-18  Jim Meyering  <meyering@lucent.com>
27678
27679         * m4/getloadavg.m4 (AC_FUNC_GETLOADAVG): Restore the initial value of
27680         LIBS. Otherwise, everyone ends up linking with -lelf for some
27681         configurations.
27682         Reported by Mike Stone.
27683
27684 2000-09-15  Jim Meyering  <meyering@lucent.com>
27685
27686         * lib/regex.c: Update from libc.
27687
27688 2000-09-10  Jim Meyering  <meyering@lucent.com>
27689
27690         * lib/getopt.c (_getopt_internal): Update from glibc.
27691
27692 2000-09-09  Jim Meyering  <meyering@lucent.com>
27693
27694         * lib/quotearg.c: Rename ISASCII to IN_CTYPE_DOMAIN, so people don't
27695         think it should be used as a general replacement for isascii.
27696         * lib/fnmatch.c: Likewise.
27697         * lib/mbswidth.c: Likewise
27698         * lib/regex.c: Likewise.
27699
27700         Don't use atoi.
27701         * lib/userspec.c: Include sys/param.h and limits.h.
27702         Include xstrtol.h.
27703         (CHAR_BIT, TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Define.
27704         (UID_T_MAX, GID_T_MAX, MAXUID, MAXGID): Define.
27705         (parse_user_spec): Use xstrtoul, not atoi when converting numeric
27706         UID, GID.  Check range.
27707
27708 2000-09-06  Jim Meyering  <meyering@lucent.com>
27709
27710         * lib/getopt.c (_getopt_internal): Update from glibc.
27711
27712 2000-08-30  Jim Meyering  <meyering@lucent.com>
27713
27714         * lib/strftime.c: Merge in changes from GNU libc.
27715
27716 2000-08-26  Jim Meyering  <meyering@lucent.com>
27717
27718         * m4/jm-macros.m4: Use jm_FUNC_FPENDING.
27719         * m4/fpending.m4: New file.
27720
27721 2000-08-26  Jim Meyering  <meyering@lucent.com>
27722
27723         * lib/closeout.c: Include "__fpending.h".
27724         (close_stdout_status): Return right away if there's nothing to flush.
27725
27726         * lib/Makefile.am (noinst_HEADERS): Add __fpending.h.
27727         * lib/__fpending.c: New file.
27728         * lib/__fpending.h: New file.
27729
27730 2000-08-20  Jim Meyering  <meyering@lucent.com>
27731
27732         * m4/check-decl.m4: Include utmp.h `#if HAVE_UTMP_H', rather than
27733         `#if !HAVE_UTMPX_H'.  The latter would lose on systems with neither
27734         utmp.h nor utmpx.h.  Reported by Eli Zaretskii.
27735
27736 2000-08-11  J. David Anglin  <dave@hiauly1.hia.nrc.ca>
27737
27738         Improve fileutils installation on systems where running
27739         programs (like install) can't be unlinked.
27740         * m4/unlink-busy.m4 (jm_FUNC_UNLINK_BUSY_TEXT): New file/macro.
27741         * m4/jm-macros.m4: Use jm_FUNC_UNLINK_BUSY_TEXT.
27742
27743 2000-08-07  Paul Eggert  <eggert@twinsun.com>
27744
27745         Standardize on "memory exhausted" instead of "Memory exhausted"
27746         or "virtual memory exhausted".
27747         * lib/obstack.c (print_and_abort): Use "memory exhausted", not
27748         "virtual memory exhausted".
27749         * lib/same.c (same_name): Invoke xalloc_die instead of printing
27750         our own message.
27751         * lib/userspec.c (parse_user_spec): Likewise.
27752         * lib/bumpalloc.h: comment fix
27753         * lib/same.c, userspec.c: Include xalloc.h.
27754
27755         * lib/xalloc.h (xalloc_msg_memory_exhausted): Now char const[],
27756         not char *const and pointing to a constant array.
27757         * lib/xmalloc.c (xalloc_msg_memory_exhausted): Likewise.
27758         (xrealloc): Comment fix.
27759
27760         * lib/userspec.c (parse_user_spec):
27761         Don't translate a message until just before returning,
27762         to avoid unnecessary translation.
27763
27764 2000-08-07  Jim Meyering  <meyering@lucent.com>
27765
27766         * lib/addext.c, argmatch.c, argmatch.h, backupfile.h, bumpalloc.h,
27767         chown.c, diacrit.h, dirname.h, dup2.c, exclude.h, fileblocks.c,
27768         fnmatch.c, fnmatch.h, fsusage.c, fsusage.h, getdate.h,
27769         getgroups.c, gethostname.c, getopt.h, group-member.c,
27770         hard-locale.c, hash.h, isdir.c, lchown.c, linebuffer.c,
27771         linebuffer.h, long-options.h, malloc.c, md5.c, md5.h, memchr.c,
27772         memcmp.c, memcoll.c, memset.c, mktime.c, modechange.h, obstack.h,
27773         pathmax.h, realloc.c, rmdir.c, safe-read.c, save-cwd.c, stime.c,
27774         stpcpy.c, strcasecmp.c, strcspn.c, strdup.c, stripslash.c,
27775         strstr.c, strtod.c, strtol.c, strtoul.c, strtoull.c, strtoumax.c,
27776         utime.c, version-etc.h, xalloc.h, xstrdup.c, xstrtoumax.c,
27777         yesno.c: Back out Copyright date changes for each file with no change
27778         this year.  This eases coordination with other programs using the same
27779         source code modules.  From Paul Eggert.
27780
27781 2000-08-06  Paul Eggert  <eggert@twinsun.com>
27782
27783         * m4/mbstate_t.m4 (AC_MBSTATE_T): Define mbstate_t to be int,
27784         not char, for compatibility with glibc 2.1.3 strftime.c.
27785
27786 2000-08-03  Greg McGary  <greg@mcgary.org>
27787
27788         * lib/regex.c (SET_HIGH_BOUND, MOVE_BUFFER_POINTER,
27789         ELSE_EXTEND_BUFFER_HIGH_BOUND): New macros.
27790         (EXTEND_BUFFER): Use them.
27791
27792 2000-08-01  Jim Meyering  <meyering@lucent.com>
27793
27794         * lib/dirname.c (ISSLASH): Define.
27795         (BACKSLASH_IS_PATH_SEPARATOR): Define.
27796         (dir_name) [BACKSLASH_IS_PATH_SEPARATOR]: Handle the case in which
27797         both `\' and `/' may be use as path separators.
27798         Based on a patch from Prashant TR.
27799
27800 2000-07-31  Paul Eggert  <eggert@twinsun.com>
27801
27802         * lib/quotearg.c (quotearg_n_options): Don't make the initial
27803         slot vector a constant, since it might get modified.
27804
27805 2000-07-31  Jim Meyering  <meyering@lucent.com>
27806
27807         * lib/xmalloc.c: Use `virtual memory exhausted', not
27808         `Memory exhausted'.
27809         * lib/obstack.c (print_and_abort): Likewise.
27810
27811 2000-07-30  Paul Eggert  <eggert@twinsun.com>
27812
27813         * lib/quotearg.c (quotearg_n_options): Preallocate a slot 0
27814         buffer, so that the caller can always quote one small
27815         component of a "memory exhausted" message in slot 0.
27816         From a suggestion by Jim Meyering.
27817
27818 2000-07-30  Jim Meyering  <meyering@lucent.com>
27819
27820         * lib/makepath.c (make_path): Quote the other instance, too.
27821
27822         * lib/quotearg.c (N_STATIC_SLOTVECS): Define.
27823         (STATIC_BUF_SIZE): Define.
27824         (quotearg_n_options): Use only statically allocated storage when
27825         N < N_STATIC_SLOTVECS and the length of the quoted result is smaller
27826         than STATIC_BUF_SIZE.
27827
27828 2000-07-29  Jim Meyering  <meyering@lucent.com>
27829
27830         * lib/diacrit.c (diacrit_diac): Use __MSDOS__ in favor of MSDOS.
27831         * lib/dirname.c (dir_name): Likewise.
27832
27833         * lib/basename.c (base_name): Use ISSLASH rather than comparing against
27834         `/'.
27835
27836         * lib/dirname.c (dir_name) [MSDOS]: Declare `lim' to be const.
27837         (dir_name): Assert that there are no trailing slashes.
27838
27839 2000-07-29  Bruno Haible  <haible@clisp.cons.org>
27840
27841         * lib/mbswidth.h (mbswidth): Add a flags argument.
27842         (mbswidth): New declaration.
27843         (MBSW_ACCEPT_INVALID, MBSW_ACCEPT_UNPRINTABLE): New macros.
27844         * lib/mbswidth.c (mbswidth): Add a flags argument.
27845         (mbsnwidth): New function.
27846
27847 2000-07-24  Jim Meyering  <meyering@lucent.com>
27848
27849         * lib/mbswidth.c: Remove useless #else.  From Bruno Haible.
27850
27851 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27852
27853         * m4/mbswidth.m4 (jm_PREREQ_MBSWIDTH): Check for wcwidth declaration.
27854
27855 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27856
27857         * lib/quotearg.c: Streamline by invoking multibyte code only if needed.
27858         <wchar.h>: Include only if HAVE_MBRTOWC && 1 < MB_LEN_MAX.
27859         (MB_CUR_MAX): Redefine to 1 if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX).
27860         (quotearg_buffer_restyled): If a unibyte locale, don't bother to
27861         invoke multibyte primitives.
27862
27863 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27864
27865         * lib/quotearg.c:
27866         Include <wchar.h> even if ! (HAVE_MBRTOWC && 1 < MB_LEN_MAX),
27867         so that mbstate_t is always defined.
27868
27869         Do not inspect MB_LEN_MAX, since it's incorrectly defined to
27870         be 1 in at least one GCC installation, and this configuration
27871         error is likely to be common.  Ignoring MB_LEN_MAX hurts
27872         performance on hosts that have mbrtowc but have only unibyte
27873         locales, but I assume these hosts are rare.
27874
27875 2000-07-23  Paul Eggert  <eggert@twinsun.com>
27876
27877         * lib/mbswidth.c (_XOPEN_SOURCE):
27878         Don't define; this causes problems on Solaris 7.
27879         (wcwidth) [!HAVE_DECL_WCWIDTH]: Declare.
27880
27881 2000-07-23  Jim Meyering  <meyering@lucent.com>
27882
27883         * m4/check-decl.m4 (jm_CHECK_DECLS): Check for declarations of these,
27884         too: getgrgid, getpwuid, getuid.
27885
27886 2000-07-23  Jim Meyering  <meyering@lucent.com>
27887
27888         * lib/basename.c (base_name): Add an assertion.
27889
27890 2000-07-23  Bruno Haible  <haible@clisp.cons.org>
27891
27892         * lib/quotearg.c: When the system forces us to redefine mbstate_t,
27893         shadow its mbsinit function.
27894
27895 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27896
27897         * lib/mbswidth.h: New file.
27898         * lib/mbswidth.c: New file.
27899         * lib/Makefile.am (libfetish_a_SOURCES): Add mbswidth.c.
27900         (noinst_HEADERS): Add mbswidth.h.
27901
27902 2000-07-17  Bruno Haible  <haible@clisp.cons.org>
27903
27904         * lib/config.charset: Add support for FreeBSD. Improve support for
27905         HP-UX and IRIX 6.
27906
27907 2000-07-16  Bruno Haible  <haible@clisp.cons.org>
27908
27909         * m4/mbswidth.m4: New file.
27910         * m4/prereq.m4 (jm_PREREQ): Call jm_PREREQ_MBSWIDTH.
27911
27912 2000-07-15  Jim Meyering  <meyering@lucent.com>
27913
27914         * lib/makepath.c: Include quote.h.
27915         (make_path): Convert "`%s'" in format strings to "%s", and wrap each
27916         corresponding argument in a `quote (...)' call.
27917         Give better diagnostics.
27918
27919         * lib/Makefile.am (libfetish_a_SOURCES): Add quote.c.
27920         (noinst_HEADERS): Add quote.h.
27921
27922         * lib/quote.c (quote, quote_n): New file.  Two functions taken verbatim
27923         from tar's src/misc.c.
27924         * lib/quote.h: New file.  Prototypes for same.
27925
27926 2000-07-14  Paul Eggert  <eggert@twinsun.com>
27927
27928         From a suggestion by Bruno Haible.
27929         * lib/quotearg.c (mbrtowc): Do not use HAVE_WCHAR_H in the definition.
27930         Use defined mbstate_t, not HAVE_MBSTATE_T_OBJECT,
27931         to decide whether to define the BeOS workaround macro;
27932         this adjusts to the change to AC_MBSTATE_T.
27933
27934 2000-07-14  Jim Meyering  <meyering@lucent.com>
27935
27936         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Require
27937         jm_AC_TYPE_UINTMAX_T.
27938
27939 2000-07-13  Paul Eggert  <eggert@twinsun.com>
27940
27941         * lib/quotearg.h (enum quoting style): New enum clocale_quoting_style.
27942
27943         * lib/quotearg.c (quoting_style_args, quoting_style_vals,
27944         quotearg_buffer_restyled): Add support for
27945         clocale_quoting_style.  Undo previous change to
27946         locale_quoting_style behavior, and undo the "{LEFT QUOTATION MARK}"
27947         and "{RIGHT QUOTATION MARK}" msgids.
27948
27949 2000-07-10  Paul Eggert  <eggert@twinsun.com>
27950
27951         From a suggestion by Bruno Haible.
27952         * m4/mbstate_t.m4 (AC_MBSTATE_T):
27953         Renamed from AC_MBSTATE_T_OBJECT.  All uses changed.
27954         Change from a two-part test, which defines both HAVE_MBSTATE_T_OBJECT
27955         and mbstate_t, to a single-part test that simply defines mbstate_t.
27956         * m4/prereq.m4 (jm_PREREQ_QUOTEARG):
27957         s/AC_MBSTATE_T_OBJECT/AC_MBSTATE_T/.
27958
27959 2000-07-10  Jim Meyering  <meyering@lucent.com>
27960
27961         * m4/strerror_r.m4: Mirror the correction made in autoconf.
27962
27963         * m4/gnu-source.m4: Output to confdefs.h directly.
27964         Suggestion from Akim Demaille.
27965
27966 2000-07-09  Paul Eggert  <eggert@twinsun.com>
27967
27968         The old behavior of quoting `like this' doesn't look good with
27969         newer, ISO-style fonts.  See:
27970         http://www.cl.cam.ac.uk/~mgk25/ucs/quotes.html
27971
27972         Instead, quote "like this" by default.  Let the translator
27973         tailor the locale-specific quoting behavior by providing
27974         translations for {LEFT QUOTATION MARK} and {RIGHT QUOTATION MARK}.
27975
27976         * lib/quotearg.c (N_): New macro.
27977         (gettext_default): New function.
27978         (quotearg_buffer_restyled): Use
27979         gettext_default ("{LEFT QUOTATION MARK}", "\"") for left quote, and
27980         gettext_default ("{RIGHT QUOTATION MARK}", "\"") for right quote.
27981
27982 2000-07-09  Jim Meyering  <meyering@lucent.com>
27983
27984         * m4/jm-macros.m4 (jm_MACROS): Add a test to see if -lm is required
27985         to link seq.  If so, set SEQ_LIBM to -lm.  From Bruno Haible.
27986
27987         * m4/gnu-source.m4 (AC__GNU_SOURCE): New file/macro.
27988         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require it.
27989
27990 2000-07-09  Jim Meyering  <meyering@lucent.com>
27991
27992         * lib/Most files: Update copyright dates to include 2000.
27993
27994 2000-07-08  Jim Meyering  <meyering@lucent.com>
27995
27996         * lib/xgethostname.c (ENAMETOOLONG): Define to an unlikely value
27997         if not defined.
27998         (xgethostname): Remove now-unnecessary #ifdef.
27999         Move declaration of `err' into loop where it's used.
28000
28001 2000-07-05  Paul Eggert  <eggert@twinsun.com>
28002         and Bruno Haible  <haible@clisp.cons.org>
28003
28004         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Test for mbstate_t
28005         only if the test for an object-type mbstate_t fails.  This
28006         prevents us from mistakenly reporting that mbstate_t is a
28007         system object type after we "#define mbstate_t int" to work
28008         around its lack.
28009
28010 2000-07-05  Paul Eggert  <eggert@twinsun.com>
28011         and Bruno Haible  <haible@clisp.cons.org>
28012
28013         * lib/quotearg.c (mbrtowc): Declare returned type, since BeOS doesn't.
28014
28015 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28016
28017         * m4/strerror_r.m4 (AC_FUNC_STRERROR_R): Pass a reasonably large buffer
28018         to strerror_r.
28019         Include <ctype.h> for use of isalpha.
28020
28021 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28022
28023         * lib/xgethostname.c (xgethostname): Protect against the SunOS 5.5 bug
28024         by allocating a larger buffer. Test the gethostname return value for
28025         being >= 0, not == 0, for BeOS.  Don't exhaust memory if gethostname
28026         returns an error and ENAMETOOLONG isn't defined.
28027
28028 2000-07-05  Bruno Haible  <haible@clisp.cons.org>
28029
28030         * lib/quotearg.c (struct quoting_options): Simplify quote_these_too
28031         dimension.
28032
28033 2000-07-04  Jim Meyering  <meyering@lucent.com>
28034
28035         * m4/fsusage.m4 (jm_FILE_SYSTEM_USAGE): Use plain old `echo' instead
28036         of the deprecated AC_CHECKING.
28037
28038 2000-07-04  Jim Meyering  <meyering@lucent.com>
28039
28040         * lib/strndup.c: [!HAVE_DECL_STRNLEN]: Declare strnlen.
28041         Reported by Bruno Haible.
28042
28043 2000-07-04  Jim Meyering  <meyering@lucent.com>
28044
28045         * lib/quotearg.c: Make inclusion of <wchar.h> independent of whether
28046         HAVE_MBRTOWC is set.  Required at least for irix-5.6, which
28047         lacks mbrtowc.
28048
28049 2000-07-03  Paul Eggert  <eggert@twinsun.com>
28050
28051         * m4/mbstate_t.m4 (AC_MBSTATE_T_OBJECT): Port to autoconf 2.13.
28052         Add AC_CHECK_HEADERS(stdlib.h), since we use HAVE_STDLIB_H.
28053
28054 2000-07-03  Paul Eggert  <eggert@twinsun.com>
28055         and Bruno Haible  <haible@clisp.cons.org>
28056
28057         * lib/quotearg.c (mbrtowc):
28058         Assign to *pwc, and return 1 only if result is nonzero.
28059         (iswprint): Use ISPRINT when substituting our own mbrtowc.
28060
28061 2000-07-03  Jim Meyering  <meyering@lucent.com>
28062
28063         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strnlen.
28064
28065 2000-07-03  Jim Meyering  <meyering@lucent.com>
28066
28067         * lib/readutmp.h: [HAVE_UTMPX_H]: Include <utmp.h> if HAVE_UTMP_H.
28068         This is necessary to get a definition of e.g., UTMP_FILE on
28069         HP-UX 10.20.
28070         From Bob Proulx.
28071
28072 2000-07-02  Jim Meyering  <meyering@lucent.com>
28073
28074         * m4/mbstate_t.m4: Also define mbstate_t, if necessary.
28075
28076         * m4/chown.m4: Replace each use of AC_SUBST(LIBOBJS)/LIBOBJS=... with
28077         AC_LIBOBJ(function_name).
28078         * m4/chown.m4: Likewise.
28079         * m4/fnmatch.m4: Likewise.
28080         * m4/ftruncate.m4: Likewise.
28081         * m4/getgroups.m4: Likewise.
28082         * m4/getline.m4: Likewise.
28083         * m4/group-member.m4: Likewise.
28084         * m4/jm-macros.m4: Likewise.
28085         * m4/lstat.m4: Likewise.
28086         * m4/malloc.m4: Likewise.
28087         * m4/memcmp.m4: Likewise.
28088         * m4/nanosleep.m4: Likewise.
28089         * m4/putenv.m4: Likewise.
28090         * m4/realloc.m4: Likewise.
28091         * m4/regex.m4: Likewise.
28092         * m4/stat.m4: Likewise.
28093         * m4/strftime.m4: Likewise.
28094
28095 2000-07-02  Jim Meyering  <meyering@lucent.com>
28096
28097         * lib/quotearg.c (mbstate_t): Don't define here.
28098
28099 2000-07-02  Jim Meyering  <meyering@lucent.com>
28100
28101         * lib/nanosleep.c (SIGCONT): Define if not already defined.
28102
28103 2000-07-01  Jim Meyering  <meyering@lucent.com>
28104
28105         * m4/uptime.m4: Put double quotes around use of $cross_compiling.
28106
28107 2000-07-01  Jim Meyering  <meyering@lucent.com>
28108
28109         * m4/ls-mntd-fs.m4: Remove a `FIXME' comment and fix the associated
28110         problem.
28111
28112 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
28113
28114         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Rename BeOS specific
28115         macro from MOUNTED_NEXT_DEV to MOUNTED_FS_STAT_DEV.
28116
28117 2000-07-01  Bruno Haible  <haible@clisp.cons.org>
28118
28119         * lib/mountlist.c: Use MOUNTED_FS_STAT_DEV instead of MOUNTED_NEXT_DEV,
28120         per change in ../m4/ls-mntd-fs.m4.
28121         (read_filesystem_list): Ignore symbolic links.
28122
28123 2000-06-29  Jim Meyering  <meyering@lucent.com>
28124
28125         * lib/same.c: Include <string.h> or <strings.h>, as appropriate,
28126         for declaration of strcmp.
28127
28128         * lib/long-options.c: Include <stdlib.h>, for declaration of exit.
28129
28130         * lib/mountlist.c (fsp_to_string) [HAVE_F_FSTYPENAME_IN_STATFS]:
28131         Avoid warning by casting result to `char *' to remove `const'.
28132
28133 2000-06-28  Jim Meyering  <meyering@lucent.com>
28134
28135         * m4/mbstate_t.m4: Use stdlib.h, not stdio.h.  The latter is not
28136         included by quotearg.c, for which we perform this test.  From
28137         Bruno Haible.
28138
28139 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
28140
28141         * m4/check-decl.m4 (_jm_DECL_HEADERS): Check for utmp.h as well.
28142         * m4/prereq.m4 (jm_PREREQ_READUTMP): Likewise. If either <utmp.h> or
28143         <utmpx.h> exists, put readutmp.o into LIBOBJS.
28144
28145 2000-06-27  Bruno Haible  <haible@clisp.cons.org>
28146
28147         * lib/Makefile.am (libfetish_a_SOURCES): Remove readutmp.c.
28148
28149 2000-06-26  Paul Eggert  <eggert@twinsun.com>
28150
28151         savedir now sets errno on failure and invokes xmalloc to get memory.
28152         Fix a couple of other minor bugs while we're at it.
28153
28154         * lib/savedir.c (<unistd.h>): Do not include; there's no need.
28155         (NAMLEN): Remove macro.
28156         (malloc, realloc): Remove decls.
28157         (stpcpy): Likewise.
28158         ("xalloc.h"): Include.
28159         (NAME_SIZE_DEFAULT): New macro.
28160         (savedir): Use xmalloc / xrealloc to allocate memory.
28161         Use NAME_SIZE_DEFAULT if name_size is negative or overflows to zero.
28162         Skip "" directory entries.
28163         Use strlen to calculate directory entry length, since the old method
28164         is rarely used these days and isn't worth supporting.
28165         Don't use a pointer after freeing it.
28166         Check for integer overflow when calculating allocation size.
28167         Use memcpy to copy entries, instead of stpcpy.
28168         Set errno properly when returning NULL.
28169         Check for readdir error.
28170
28171 2000-06-26  Jim Meyering  <meyering@lucent.com>
28172
28173         * lib/posixtm.c [HAVE_STDLIB_H]: Include stdlib.h, for decl of abort.
28174
28175 2000-06-25  Jim Meyering  <meyering@lucent.com>
28176
28177         * m4/mbstate_t.m4: Include stdio.h before wchar.h to work around
28178         Linux header bug when _XOPEN_SOURCE is defined to 500.
28179
28180 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28181
28182         * lib/unicodeio.c (print_unicode_char): Work around ansi2knr
28183         deficiency.
28184
28185 2000-06-25  Bruno Haible  <haible@clisp.cons.org>
28186
28187         * lib/getusershell.c (xmalloc, xrealloc): Remove functions.
28188         Include xalloc.h.
28189         Don't include <stdlib.h>.  Don't declare malloc, realloc.
28190
28191 2000-06-24  Jim Meyering  <meyering@lucent.com>
28192
28193         * m4/strerror_r.m4: Revive this file -- to try out an experimental
28194         version of AC_FUNC_STRERROR_R that may work even on BeOS, a system
28195         for which strerror does return char*, but which lacks a conveniently
28196         accessible declaration of the function.  If the compile-test says
28197         strerror_r doesn't work, then resort to a `run'-test that works on
28198         BeOS and segfaults on DEC Unix.
28199
28200 2000-06-24  Jim Meyering  <meyering@lucent.com>
28201
28202         * lib/error.c [!HAVE_DECL_STRERROR_R]: Declare strerror_r.
28203
28204 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28205
28206         * m4/mbstate_t.m4: New file, defining AC_MBSTATE_T_OBJECT.
28207         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Use it.  Add check for iswprint.
28208
28209 2000-06-23  Paul Eggert  <eggert@twinsun.com>
28210
28211         * lib/quotearg.c: Include <wctype.h> after <wchar.h>, for Solaris 2.5.
28212         (mbrtowc, mbstate_t): Define substitutes if
28213         HAVE_MBRTOWC && HAVE_WCHAR_H && !HAVE_MBSTATE_T_OBJECT.
28214         (iswprint): Define to 1 if !defined iswprint && !HAVE_ISWPRINT,
28215         not if ! (HAVE_MBRTOWC && HAVE_WCHAR_H).
28216
28217 2000-06-23  Jim Meyering  <meyering@lucent.com>
28218
28219         * m4/afs.m4: Add missing AC_MSG_RESULT.
28220         Reported by Bruno Haible.
28221
28222         * m4/fsusage.m4: s/AC_MSG_CHECKING/AC_CHECKING/.
28223         Suggestion from Bruno Haible.
28224
28225 2000-06-23  Jim Meyering  <meyering@lucent.com>
28226
28227         * lib/getpass.c: New file, from Bruno Haible.  Required for BeOS.
28228
28229 2000-06-21  Jim Meyering  <meyering@lucent.com>
28230
28231         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add getpass.
28232
28233 2000-06-21  Jim Meyering  <meyering@lucent.com>
28234
28235         * lib/Makefile.am (libfetish_a_SOURCES): Add getstr.c.
28236         (noinst_HEADERS): Add getstr.h.
28237
28238         * lib/getline.c (getstr): Move into a separate file.
28239         * lib/getstr.c (getstr): New file, extracted from getline.c, with
28240         the following changes: new parameter, delim2; both delim[12]
28241         parameters have type `int', not `char'.  The latter would lose
28242         with 8-bit delimiters.
28243         * lib/getstr.h: New file.
28244
28245 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28246
28247         * lib/xgetcwd.c (xgetcwd): If the required pathname length is smaller
28248         than 1024, return a memory chunk of least possible size, instead
28249         of size PATH_MAX + 2. In the loop, increment the size proportionally.
28250         Use free/xmalloc instead of xrealloc to avoid copying for very long
28251         paths.
28252
28253 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28254
28255         * lib/path-concat.c (path_concat): Don't access dir[-1] if dir is
28256         the empty string.
28257
28258 2000-06-21  Bruno Haible  <haible@clisp.cons.org>
28259
28260         * lib/canon-host.c (canon_host): Use malloc and memcpy to copy an
28261         address, not strdup.  Include <stdlib.h> and don't declare free().
28262
28263 2000-06-19  Jim Meyering  <meyering@lucent.com>
28264
28265         * lib/getloadavg.c [HAVE_NLIST_H] (NLIST_STRUCT): Define.
28266
28267 2000-06-18  Jim Meyering  <meyering@lucent.com>
28268
28269         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Remove mkdir.
28270
28271         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): Change the
28272         `checking whether...' message to be consistent with that of the
28273         lstat test.
28274
28275 2000-06-18  Jim Meyering  <meyering@lucent.com>
28276
28277         * lib/mkdir.c: Remove file, due mainly to copyright incompatibility.
28278         Besides, these days every porting target provides a mkdir function.
28279
28280         * lib/strnlen.c: Include memory.h, string.h, and/or strings.h as
28281         needed. (this snippet comes from src/system.h).
28282
28283 2000-06-16  Bruno Haible  <haible@clisp.cons.org>
28284
28285         * m4/glibc21.m4 (jm_GLIBC21): Define GLIBC21 for Makefiles, not for C.
28286
28287 2000-06-15  Paul Eggert  <eggert@twinsun.com>
28288
28289         * lib/human.c (adjust_value): New function.
28290         (human_readable_inexact): Apply rounding style even when
28291         printing approximate values.
28292
28293 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28294
28295         * lib/human.c (human_readable_inexact): Allow an input block
28296         size that is not a multiple of the output block size, and vice versa.
28297         Reported by Piergiorgio Sartor.
28298
28299 2000-06-14  Paul Eggert  <eggert@twinsun.com>
28300
28301         * lib/getdate.y (get_date): Apply relative times after time
28302         zone indicator, not before.  Reported by Todd A. Jacobs.
28303
28304 2000-06-13  Jim Meyering  <meyering@lucent.com>
28305
28306         * lib/Makefile.am (all-local): Depend on lstat.c and stat.c.
28307
28308         * lib/xstat.in [!HAVE_DECL_FREE]: Declare free in lstat.c.
28309
28310 2000-06-12  Paul Eggert  <eggert@twinsun.com>
28311
28312         * lib/xstat.in: Include <stdlib.h> in lstat, to declare "free".
28313
28314 2000-06-12  Jim Meyering  <meyering@lucent.com>
28315
28316         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Replace with
28317         AC_FUNC_GETLOADAVG from autoconf, and tweak the latter to accept an
28318         optional argument.
28319         * m4/jm-macros.m4: s/AM_FUNC_GETLOADAVG/AC_FUNC_GETLOADAVG/, and supply
28320         the optional argument, `lib'.
28321
28322 2000-06-08  Jim Meyering  <meyering@lucent.com>
28323
28324         * m4/largefile.m4: Remove file (now that it's part of autoconf).
28325
28326 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28327
28328         Rewrite largefile configuration so that we don't need to run
28329         getconf and don't need AC_CANONICAL_HOST.  [I'm leaving the use of
28330         AC_CANONICAL_HOST in configure.in -- jmm]
28331
28332         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS,
28333         AC_SYS_LARGEFILE_SPACE_APPEND): Remove.
28334         (AC_SYS_LARGEFILE_TEST_INCLUDES): New macro.
28335         (AC_SYS_LARGEFILE_MACRO_VALUE): Change arguments from
28336         CODE-TO-SET-DEFAULT to VALUE, INCLUDES, FUNCTION-BODY.
28337         All uses changed.
28338         Instead of inspecting the output of getconf, try to compile the
28339         test program without and with the macro definition.
28340         (AC_SYS_LARGEFILE): Do not require AC_CANONICAL_HOST or check
28341         for getconf.  Instead, check for the needed flags by compiling
28342         test programs.
28343
28344 2000-06-04  Paul Eggert  <eggert@twinsun.com>
28345
28346         * lib/strnlen.c: Include <config.h> if HAVE_CONFIG_H.
28347
28348 2000-06-04  Jim Meyering  <meyering@lucent.com>
28349
28350         * lib/getugroups.c (getugroups): Cast -1 to gid_t, for systems like
28351         SunOS 4.1.4 for which gid_t is an unsigned type.
28352
28353 2000-06-03  Jim Meyering  <meyering@lucent.com>
28354
28355         * m4/prereq.m4 (jm_PREREQ_HUMAN): Use []-quoted list in AC_CHECK_DECLS,
28356         now that autoconf requires that.
28357
28358         * m4/jm-glibc-io.m4: Add a kludge to make autoheader emit the required
28359         #undefs.  E.g., #undef HAVE_DECL_FERROR_UNLOCKED.
28360         Use []-quoted list in AC_CHECK_DECLS, now that autoconf requires that.
28361
28362 2000-06-03  Jim Meyering  <meyering@lucent.com>
28363
28364         * lib/strnlen.c [!HAVE_DECL_MEMCHR]: Declare memchr.
28365
28366 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28367
28368         * m4/glibc21.m4: New file.
28369         * m4/jm-macros.m4 (jm_MACROS): Call jm_GLIBC21.
28370
28371 2000-06-03  Bruno Haible  <haible@clisp.cons.org>
28372
28373         * lib/Makefile.am (install-exec-local): On systems with glibc-2.1 or
28374         newer, don't install charset.alias.
28375         * lib/config.charset: Change the Linux/glibc rules so they become empty
28376         on glibc-2.1 or newer.
28377
28378 2000-06-02  Jim Meyering  <meyering@lucent.com>
28379
28380         * lib/mountlist.c: Back out last change.  Instead, do this...
28381         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Set the
28382         me_dummy member using the same `ignore'-testing code.
28383         * lib/mountlist.h (ME_DUMMY): Add `autofs' to the list of ignored
28384         fs_type strings.
28385         From Mark D. Roth.
28386
28387 2000-05-29  Jim Meyering  <meyering@lucent.com>
28388
28389         * lib/mountlist.c (read_filesystem_list) [MOUNTED_VMOUNT]: Ignore
28390         mounts with the `ignore' attribute.  Based on a patch from
28391         Mark D. Roth.
28392
28393 2000-05-28  Jim Meyering  <meyering@lucent.com>
28394
28395         * m4/jm-macros.m4 (AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK): Rename from
28396         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28397         * m4/stat.m4: Likewise.
28398         * m4/lstat.m4: Likewise.
28399         * m4/lstat-slash.m4: Remove file (absorbed into autoconf).
28400
28401         * m4/jm-macros.m4 (AC_FUNC_STRERROR_R): Rename from jm_FUNC_STRERROR_R.
28402         * m4/strerror_r.m4: Remove file (absorbed into autoconf).
28403
28404 2000-05-26  Jim Meyering  <meyering@lucent.com>
28405
28406         * m4/uptime.m4: Use `$cross_compiling', not `$ac_cv_prog_cc_cross'.
28407
28408 2000-05-24  Jim Meyering  <meyering@lucent.com>
28409
28410         * m4/prereq.m4: Use []-quoted list in AC_CHECK_MEMBERS, now that
28411         autoconf requires that.
28412         * m4/lib-check.m4: Likewise.
28413         * m4/jm-macros.m4: Likewise.
28414         * m4/strftime.m4: Likewise.
28415
28416         * m4/check-decl.m4 (jm_CHECK_DECLS): Use []-quoted list in
28417         AC_CHECK_DECLS, now that autoconf requires that.
28418
28419 2000-05-22  Jim Meyering  <meyering@lucent.com>
28420
28421         * m4/stat.m4: Require jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
28422         * m4/lstat.m4: Likewise.
28423
28424 2000-05-22  Jim Meyering  <meyering@lucent.com>
28425
28426         * lib/makepath.c: Remove old, now-unnecessary `#ifdef __MSDOS__' block.
28427
28428 2000-05-20  Jim Meyering  <meyering@lucent.com>
28429
28430         * m4/prereq.m4 (jm_PREREQ_HUMAN): New macro.
28431         (jm_PREREQ): Use it.
28432
28433 2000-05-18  Jim Meyering  <meyering@lucent.com>
28434
28435         * lib/hash.c (hash_rehash): Fix a nasty bug: copy the free entry list
28436         back, too, since it may have been modified by allocate_entry.
28437         (hash_delete): Rewrite to use neither the assignment operator
28438         nor the comma operator in an if-expression.
28439
28440 2000-05-15  Paul Eggert  <eggert@twinsun.com>
28441
28442         * lib/closeout.c:
28443         <sys/stat.h>, <sys/types.h>, <unistd.h>, (STDOUT_FILENO):
28444         Remove; no longer needed.
28445         "quotearg.h": Add include.
28446         (file_name): Do not bother to explicitly initialize to NULL; it's less
28447         efficient on some hosts.
28448         (close_stdout_status): Remove test as to whether stdout was already
28449         closed; it breaks for the case "echo x | sort >&-".
28450         Quote file name colons.
28451         Do not assume that _("write error") lacks format strings.
28452
28453 2000-05-15  Jim Meyering  <meyering@lucent.com>
28454
28455         * lib/version-etc.c (version_etc_copyright): Update the copyright
28456         string used in all --version output.
28457
28458 2000-05-14  Jim Meyering  <meyering@lucent.com>
28459
28460         * lib/closeout.c (close_stdout_set_file_name): New function.
28461         (close_stdout_status): Use new file-scoped global.
28462         Return right away if fstat says the stdout file descriptor is invalid.
28463         * lib/closeout.h (close_stdout_set_file_name): Declare.
28464
28465 2000-05-10  Jim Meyering  <meyering@lucent.com>
28466
28467         * lib/closeout.c [default_exit_status]: New file-scoped variable.
28468         (close_stdout_set_status): New function.
28469         * lib/closeout.h (close_stdout_set_status): Declare.
28470
28471 2000-05-09  Jim Meyering  <meyering@lucent.com>
28472
28473         * m4/gettext.m4: Rename this...
28474         * m4/libintl.m4: ...to this.
28475
28476 2000-05-08  Jim Meyering  <meyering@lucent.com>
28477
28478         * lib/long-options.c: Don't include closeout.h.
28479         (parse_long_options): Don't call close_stdout for --version.
28480
28481 2000-05-06  Paul Eggert  <eggert@twinsun.com>
28482
28483         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _XOPEN_SOURCE to
28484         be 500, instead of _GNU_SOURCE to be 1, to work around glibc
28485         2.1.3 bug.  This avoids a clash when files like regex.c define
28486         _GNU_SOURCE.
28487
28488 2000-05-06  Jim Meyering  <meyering@lucent.com>
28489
28490         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add atexit.
28491         (AC_REPLACE_FUNCS): Add strnlen.
28492
28493         * m4/rmdir-errno.m4 (fetish_FUNC_RMDIR_NOTEMPTY): New macro and file.
28494         * m4/jm-macros.m4: Require fetish_FUNC_RMDIR_NOTEMPTY.
28495
28496         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Save and restore LIBS around
28497         AC_SEARCH_LIBS call for nanosleep.
28498         (LIB_NANOSLEEP): Set and AC_SUBST.
28499
28500 2000-05-06  Jim Meyering  <meyering@lucent.com>
28501
28502         * lib/strnlen.c: Undefine __strnlen and strnlen.
28503         [!weak_alias]: Define __strnlen to strnlen.
28504
28505         * lib/atexit.c: New file, from libiberty.
28506
28507 2000-05-06  Jim Meyering  <meyering@lucent.com>
28508
28509         * lib/closeout.c (close_stdout_status): Also check for errors on the
28510         stderr stream.
28511
28512 2000-05-05  Jim Meyering  <meyering@lucent.com>
28513
28514         * m4/jm-macros.m4 (jm_MACROS): Save and restore LIBS around
28515         AC_SEARCH_LIBS call for clock_gettime.
28516         (LIB_CLOCK_GETTIME): Set and AC_SUBST.
28517
28518         * m4/search-libs.m4: Update from autoconf.
28519
28520         su doesn't work on Solaris 2.6.
28521         * m4/lib-check.m4: When checking for struct spwd.sp_pwdp, also include
28522         <shadow.h>.  Reported by Dragos Harabor.
28523
28524 2000-05-05  Bruno Haible  <haible@clisp.cons.org>
28525
28526         * lib/localcharset.c (get_charset_aliases): Use malloc, realloc and
28527         memcpy instead of xmalloc, xrealloc, path_concat.
28528         (locale_charset): Treat empty environment variables as absent.
28529         (DIRECTORY_SEPARATOR, ISSLASH): New macros.
28530
28531 2000-05-04  Jim Meyering  <meyering@lucent.com>
28532
28533         * lib/getopt.c: Update from glibc.
28534         * lib/obstack.c: Likewise.
28535         * lib/obstack.h: Likewise.
28536         * lib/regex.c: Likewise.  NB: K&R compiler support is dropped for this
28537         file
28538
28539         * lib/regex.h: Likewise.
28540         * lib/strndup.c: Likewise.
28541         * lib/strnlen.c: New file, from glibc.
28542
28543 2000-05-03  Jim Meyering  <meyering@lucent.com>
28544
28545         * m4/check-decl.m4 (AC_CHECK_DECLS): Add strndup.
28546
28547 2000-05-02  Paul Eggert  <eggert@twinsun.com>
28548
28549         * m4/largefile.m4 (AC_SYS_LARGEFILE): Define _GNU_SOURCE if
28550         this is needed to make ftello visible (e.g. glibc 2.1.3).  Use
28551         compile-time test, rather than inspecting host and OS, to
28552         decide whether to define _LARGEFILE_SOURCE.
28553
28554 2000-05-01  Jim Meyering  <meyering@lucent.com>
28555
28556         * m4/fsusage.m4: Use AC_MSG_CHECKING instead of obsolete AC_CHECKING.
28557
28558         * m4/ls-mntd-fs.m4 (jm_LIST_MOUNTED_FILESYSTEMS): Add BeOS support.
28559         Based on a patch from Bruno Haible.
28560
28561 2000-05-01  Jim Meyering  <meyering@lucent.com>
28562
28563         * lib/full-write.c (full_write): Remove `FIXME' part of comment.
28564
28565 2000-04-29  Jim Meyering  <meyering@lucent.com>
28566
28567         * lib/path-concat.c: Declare strdup only if it's not defined.
28568         * lib/canon-host.c: Likewise.
28569
28570 2000-04-28  Jim Meyering  <meyering@lucent.com>
28571
28572         * lib/rpmatch.c [HAVE_LIMITS_H]: Include limits.h before regex.h to
28573         avoid redefinition warning on some systems (HPUX).  Otherwise, regex.h
28574         is included first, then limits.h is included by locale.h by libintl.h.
28575         From John David Anglin.
28576
28577 2000-04-25  Jim Meyering  <meyering@lucent.com>
28578
28579         * lib/makepath.c (S_IRWXUGO): Define.
28580         (make_path): Always perform explicit chmod if MODE specifies any
28581         of the `special' permission bits.  Prompted by a bug report against
28582         install from Mate Wierdl and Joost van Baal.
28583
28584 2000-04-18  Jim Meyering  <meyering@lucent.com>
28585
28586         * m4/prereq.m4 (jm_PREREQ_GETPAGESIZE): New macro.
28587         (jm_PREREQ): Use it.
28588
28589 2000-04-18  Jim Meyering  <meyering@lucent.com>
28590
28591         * lib/README: New file.
28592
28593         * lib/getpagesize.h [!getpagesize && HAVE_OS_H && B_PAGE_SIZE]: Define
28594         getpagesize.  For BeOS.  Based on a patch from Bruno Haible.
28595
28596 2000-04-17  Jim Meyering  <meyering@lucent.com>
28597
28598         Get it right :-)
28599         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Emit the
28600         actual #define via AH_VERBATIM.  Don't need separate AC_DEFINE.
28601         Suggestion from Akim Demaille.
28602
28603 2000-04-17  Jim Meyering  <meyering@lucent.com>
28604
28605         * lib/strftime.c (my_strftime) [strftime]: Declare strftime here, since
28606         the definition of it to rpl_strftime also defined-away the system's
28607         declaration.
28608
28609 2000-04-15  Jim Meyering  <meyering@lucent.com>
28610
28611         Use `C' to denote so-called `contiguous' files, the same way
28612         that tar does.
28613         * lib/filemode.c (S_ISCTG) [!S_ISCTG && S_IFCTG]: Define.
28614         (ftypelet): Use S_ISCTG.
28615         From Michael Deutschmann.
28616
28617 2000-04-14  Jim Meyering  <meyering@lucent.com>
28618
28619         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use the one-arg
28620         form of AC_DEFINE.  Otherwise, the #ifndef in AH_VERBATIM gets
28621         clobbered.
28622
28623 2000-04-14  Jim Meyering  <meyering@lucent.com>
28624
28625         * lib/strftime.c (my_strftime) [#ifdef strftime]: Declare strftime.
28626
28627 2000-04-13  Jim Meyering  <meyering@lucent.com>
28628
28629         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES) [_GNU_SOURCE]: Use new
28630         AH_VERBATIM to insert required #ifndef into config.h.in.
28631         Suggestion from Akim Demaille.
28632
28633 2000-04-12  Jim Meyering  <meyering@lucent.com>
28634
28635         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Use AC_CHECK_HEADERS, not
28636         `AC_CHECK_HEADER' to check for locale.h.  Thanks to a report from
28637         Christian Krackowizer.
28638
28639         More code moved from ../configure.in into (jm_CHECK_ALL_TYPES).
28640         * m4/jm-macros.m4 (_GNU_SOURCE): Define.
28641         (AC_SYS_LARGEFILE): Require.
28642         (AM_C_PROTOTYPES): Require.
28643
28644 2000-04-08  Jim Meyering  <meyering@lucent.com>
28645
28646         * lib/Makefile.am (charset.alias): Use t-$@, not $@-t so the DOS 8.3
28647         names don't conflict.  Reported by Eli Zaretskii.
28648
28649 2000-04-07  Jim Meyering  <meyering@lucent.com>
28650
28651         * lib/putenv.c: Move inclusion of errno.h so it follows that of
28652         sys/types.h, to work around system header problems on AIX 3.2.5.
28653         From Bruno Haible.
28654
28655 2000-04-07  Bruno Haible  <haible@clisp.cons.org>
28656
28657         * lib/unicodeio.c (print_unicode_char): Avoid triggering Solaris iconv
28658         bug.  Deal with the different error behavior of Irix iconv.
28659
28660 2000-04-05  Paul Eggert  <eggert@twinsun.com>
28661
28662         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Don't use -n32 on
28663         IRIX if the installer said otherwise.
28664
28665 2000-04-05  Jim Meyering  <meyering@lucent.com>
28666
28667         Portability tweaks required for ultrix4.3.
28668         * m4/check-decl.m4 [!HAVE_UTMPX_H] (headers): Include <utmp.h>.
28669         (jm_CHECK_DECLS): Add getutent to the list of functions.
28670         (_jm_DECL_HEADERS): Add utmpx.h.
28671         From John David Anglin.
28672
28673         * m4/strftime.m4: Back out the 2000-04-02 change.
28674         Instead of that change, simply undefine putenv in the test program.
28675
28676 2000-04-05  Jim Meyering  <meyering@lucent.com>
28677
28678         Portability tweaks required for ultrix4.3.
28679         * lib/readutmp.h [HAVE_UTMPX_H && !HAVE_DECL_GETUTENT]: Declare
28680         getutent.
28681         * lib/readutmp.c: Include sys/types.h before sys/stat.h.
28682         * lib/canon-host.c: Declare strdup.
28683         * lib/path-concat.c: Likewise.
28684         From John David Anglin.
28685
28686 2000-04-04  Jim Meyering  <meyering@lucent.com>
28687
28688         Be more DOS 8.3-friendly.
28689         * lib/ref-add.sin: Renamed from ref-add.sed.in.
28690         * lib/ref-del.sin: Renamed from ref-del.sed.in.
28691         * lib/Makefile.am: Reflect renaming.
28692         Reported by Eli Zaretskii.
28693
28694         Use a temporary file name that won't clash with `charset.alias'
28695         in the DOS 8.3 name space.
28696         * lib/Makefile.am (charset_tmp): Define.
28697         (install-exec-local): Use $(charset_tmp) instead of $(charset_alias)-t.
28698         (uninstall-local): Likewise.
28699         Reported by Eli Zaretskii.
28700
28701 2000-04-03  Jim Meyering  <meyering@lucent.com>
28702
28703         * m4/gettext.m4: Fix typo in comment.
28704
28705         * m4/codeset.m4 (AC_CHECK_HEADERS): Add langinfo.h (moved here from
28706         textutils/configure.in).  Suggestion from Paul Eggert.
28707         (AC_CHECK_FUNCS): Add nl_langinfo.  (also from textutils/configure.in)
28708
28709 2000-04-02  Paul Eggert  <eggert@twinsun.com>
28710
28711         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Set TZ environment
28712         variable in the shell rather than using putenv, which isn't
28713         portable.  This avoids the configure-time inter-test dependency
28714         on the potentially-renamed putenv function.
28715
28716 2000-03-30  Paul Eggert  <eggert@twinsun.com>
28717
28718         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Include <sys/stat.h>
28719         before checking struct stat.st_blksize, so that
28720         HAVE_STRUCT_STAT_ST_BLKSIZE is defined correctly.
28721
28722 2000-03-29  Paul Eggert  <eggert@twinsun.com>
28723
28724         * m4/strftime.m4 (_jm_STRFTIME_PREREQS): Check for strftime,
28725         since strftime.c uses HAVE_STRFTIME to decide whether to use
28726         the underlying strftime.
28727
28728 2000-03-29  Paul Eggert  <eggert@twinsun.com>
28729
28730         * lib/time/strftime.c (my_strftime): Make sure we call the system
28731         strftime, not ourselves, when invoking the underlying strftime.
28732
28733 2000-03-24  Jim Meyering  <meyering@lucent.com>
28734
28735         * lib/Makefile.am (EXTRA_DIST): Add ref-add.sed.in and ref-del.sed.in.
28736         (charset_alias): Define.
28737         (install-exec-local): Factor out common code.
28738         (uninstall-local): Split lines longer than 80.
28739         (ref-add.sed, ref-del.sed): Remove rules... (do the following instead)
28740         (SUFFIXES): Define.
28741         (.sed.in.sed): New rule.  Don't redirect directly to $@.
28742         (CLEANFILES): Add ref-add.sed and ref-del.sed.
28743
28744 2000-03-19  Bruno Haible  <haible@clisp.cons.org>
28745
28746         * lib/config.charset: Output a line containing "Packages using this
28747         file".
28748         * lib/ref-add.sed.in, lib/ref-del.sed.in: New files.
28749         * lib/Makefile.am (install-exec-local, uninstall-local, ref-add.sed,
28750         ref-del.sed): New rules.
28751
28752 2000-03-17  Jim Meyering  <meyering@lucent.com>
28753
28754         * lib/unicodeio.c (<string.h>): Include only #if HAVE_STRING_H.
28755         Otherwise, include <strings.h>
28756
28757 2000-03-17  Bruno Haible  <haible@clisp.cons.org>
28758
28759         * lib/unicodeio.c (utf8_wctomb): New function.
28760         (print_unicode_char): Pass the Unicode character to iconv in UTF-8
28761         format instead of in UCS-4 with platform dependent endianness.
28762
28763 2000-03-10  Jim Meyering  <meyering@lucent.com>
28764
28765         * m4/lib-check.m4: Look for getspnam in -lgen, too.
28766         From Marco Franzen.
28767
28768 2000-03-07  Paul Eggert  <eggert@twinsun.com>
28769
28770         * lib/savedir.c (savedir): Work even if directory size is
28771         negative; this can happen with some screwy NFS configurations.
28772
28773 2000-03-06  Jim Meyering  <meyering@lucent.com>
28774
28775         * lib/localcharset.c (get_charset_aliases): Don't try to free file_name
28776         if it's NULL (because we ran out of memory).  From Bruno Haible.
28777
28778 2000-03-05  Jim Meyering  <meyering@lucent.com>
28779
28780         * lib/localcharset.c ("path-concat.h"): Include.
28781         (get_charset_aliases): Use path_concat instead of ANSI string
28782         concatenation.
28783
28784         * lib/unicodeio.h (PARAMS): Define.
28785         Use it to guard prototype.
28786
28787 2000-03-04  Jim Meyering  <meyering@lucent.com>
28788
28789         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require AC_C_VOLATILE,
28790         for lib/localcharset.c.
28791
28792 2000-03-04  Jim Meyering  <meyering@lucent.com>
28793
28794         * lib/Makefile.am (install-exec-local): Create $(libdir) before
28795         installing into it.
28796         (uninstall-local): Uncomment this rule so `make distcheck' works
28797         once again.
28798
28799         * lib/unicodeio.c (<errno.h>): Include it.
28800         (errno): Declare if not defined.
28801
28802         * lib/localcharset.c: Add Bruno's comment justifying use of volatile.
28803
28804         * lib/config.charset: New version, incorporating remarks from a linux
28805         i18n mailing list.  From Bruno Haible.
28806
28807 2000-03-04  Bruno Haible  <haible@clisp.cons.org>
28808
28809         * m4/codeset.m4: New file.
28810         * m4/iconv.m4: New file.
28811         * m4/jm-macros.m4 (jm_MACROS): Call jm_LANGINFO_CODESET and jm_ICONV.
28812
28813 2000-03-03  Jim Meyering  <meyering@lucent.com>
28814
28815         * m4/regex.m4: Make sure re_compile_pattern accepts patterns like `{1'.
28816
28817 2000-03-02  Jim Meyering  <meyering@lucent.com>
28818
28819         * m4/timespec.m4: Require AC_HEADER_TIME before the cache check so
28820         the messages come out on separate lines.
28821
28822         * m4/jm-glibc-io.m4 (jm_FUNC_GLIBC_UNLOCKED_IO): Use AC_CHECK_DECLS,
28823         rather than jm_CHECK_DECLARATIONS.
28824         * m4/decl.m4: Remove now-unused file.
28825
28826         * m4/check-decl.m4 (AC_CHECK_DECLS): Add getlogin, ttyname, and
28827         geteuid.
28828
28829 2000-03-02  Jim Meyering  <meyering@lucent.com>
28830
28831         * lib/Makefile.am (EXTRA_DIST): Add config.charset.
28832
28833 2000-03-01  Jim Meyering  <meyering@lucent.com>
28834
28835         * lib/localcharset.c: Guard some #includes with `#if HAVE_...'.
28836         * lib/unicodeio.c: Likewise.
28837
28838 2000-03-01  Bruno Haible  <haible@clisp.cons.org>
28839
28840         * lib/config.charset: New file.
28841         * lib/localcharset.c: New file.
28842         * lib/unicodeio.h, lib/unicodeio.c: New files.
28843         * lib/Makefile.am (DEFS): Add -DLIBDIR=...
28844         (libfetish_a_SOURCES): Add localcharset.c and unicodeio.c.
28845         (noinst_HEADERS): Add unicodeio.h.
28846         (all-local, install-exec-local, charset.alias): New targets.
28847
28848 2000-02-28  Paul Eggert  <eggert@twinsun.com>
28849
28850         * lib/quotearg.c (ALERT_CHAR): New macro.
28851         (quotearg_buffer_restyled): Use it.
28852
28853 2000-02-27  Jim Meyering  <meyering@lucent.com>
28854
28855         * m4/check-decl.m4: Add getenv to the list.
28856
28857 2000-02-27  Jim Meyering  <meyering@lucent.com>
28858
28859         * lib/strtoumax.c: Fix typo in decl of strtoul: s/long long/long/.
28860         Guard declaration of strtoull also with `&& HAVE_UNSIGNED_LONG_LONG'.
28861
28862         * lib/backupfile.c: Guard inclusion of stdlib.h with
28863         `#if HAVE_STDLIB_H', not `#if STDC_HEADERS'.
28864         Declare malloc if needed.
28865
28866         * lib/backupfile.c: Use `#if !HAVE_DECL...' instead of
28867         `#ifndef HAVE_DECL..'
28868         now that autoconf always defines the HAVE_DECL_ symbols.
28869         * lib/human.c: Likewise.
28870         * lib/same.c: Likewise.
28871         * lib/strtoumax.c: Likewise.
28872
28873         * lib/backupfile.c: Arrange for cpp to fail if the configure-time
28874         declaration check was not run.
28875         * lib/hash.c: Likewise.
28876         * lib/human.c: Likewise.
28877         * lib/same.c: Likewise.
28878         * lib/strtoumax.c: Likewise.
28879
28880         * lib/userspec.c (parse_user_spec): If there is no `:' but there is a
28881         `.', then first look up the entire `.'-containing string as a login
28882         name.
28883
28884 2000-02-23  Jim Meyering  <meyering@lucent.com>
28885
28886         * m4/check-decl.m4: Now that we have the new AC_CHECK_DECLS, use it
28887         in place of my hack.
28888
28889 2000-02-18  Paul Eggert  <eggert@twinsun.com>
28890
28891         * lib/getdate.y: Handle two-digit years with leading zeros correctly.
28892         (textint): New typedef.
28893         (parser_control): Member year changed from int to textint.
28894         All uses changed.
28895         (YYSTYPE): Removed; replaced by %union with int and textint members.
28896         (tDAY, tDAY_UNIT, tDAYZONE, tHOUR_UNIT, tID, tLOCAL_ZONE, tMERIDIAN,
28897         tMINUTE_UNIT, tMONTH, tMONTH_UNIT tSEC_UNIT, tSNUMBER, tUNUMBER,
28898         tYEAR_UNIT, tZONE, o_merid): Now of type <intval>.
28899         (tSNUMBER, tUNUMBER): Now of type <textintval>.
28900         (date, number, to_year): Use width of number in digits, not its value,
28901         to determine whether it's a 2-digit year, or a 2-digit time.
28902         (yylex): Store number of digits of numeric tokens.
28903         Reported by John Kendall.
28904
28905         (parser_control): Changed from struct parser_control to typedef (for
28906         consistency).  All uses changed.
28907
28908         (tID): Removed; not used.
28909         (yylex): Return '?' for unknown identifiers, rather than (unused) tID.
28910
28911 2000-02-14  Paul Eggert  <eggert@twinsun.com>
28912
28913         * lib/getpagesize.h (getpagesize): Port to VMS for Alpha;
28914         adapted from changes to grep getpagesize.h by Martin P.J. Zinser.
28915
28916 2000-02-12  Jim Meyering  <meyering@lucent.com>
28917
28918         * lib/userspec.c (ISDIGIT): Define it.
28919         (isdigit): Remove definition.
28920         (is_number): Use ISDIGIT, not isdigit.
28921         <libintl.h>: Include.
28922         (_ and N_): Define.
28923         (parse_user_spec): Mark translatable strings.
28924
28925 2000-02-10  Jim Meyering  <meyering@lucent.com>
28926
28927         With these changes, nanosleep.[ch] are finally enough like the other
28928         lib/* replacement files to compile on a few more losing systems.
28929
28930         * lib/nanosleep.h: Don't include config.h.
28931         Remove prototype from declaration of nanosleep.
28932         (PARAMS): Remove now-unneeded definition.
28933         * lib/nanosleep.c: #undef nanosleep.
28934         (rpl_nanosleep): Rename from nanosleep.
28935
28936 2000-02-10  Jim Meyering  <meyering@lucent.com>
28937
28938         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Rename replacement function from
28939         gnu_nanosleep to rpl_nanosleep.
28940
28941 2000-02-09  Jim Meyering  <meyering@lucent.com>
28942
28943         * m4/lib-check.m4 (jm_LIB_CHECK): Fix typo: check for sp_pwdp in
28944         struct spwd, rather than in struct passwd.  Reported by Gaël Quéri.
28945
28946 2000-02-08  Akim Demaille  <akim@epita.fr>
28947
28948         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Quote square brackets with
28949         `[' and `]' and remove uses of `changequote'.
28950         (AC_SYS_LARGEFILE_MACRO_VALUE): Likewise.
28951         (AC_SYS_LARGEFILE): Likewise.
28952         * m4/gettext.m4 (AM_GNU_GETTEXT): Likewise.
28953         * m4/strftime.m4 (jm_FUNC_GNU_STRFTIME): Remove now-unnecessary use
28954         of changequote.
28955         * m4/regex.m4 (jm_INCLUDED_REGEX): Likewise.
28956         * m4/readdir.m4 (jm_FUNC_READDIR): Likewise
28957         * m4/memcmp.m4 (jm_AC_FUNC_MEMCMP): Likewise, and add `int' for main.
28958         * m4/getloadavg.m4 (AM_FUNC_GETLOADAVG): Likewise.
28959
28960 2000-02-05  Jim Meyering  <meyering@lucent.com>
28961
28962         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require most macros.
28963         Remove explicit use of AC_HEADER_TIME.  It is required by
28964         jm_CHECK_TYPE_STRUCT_TIMESPEC.  Using AC_HEADER_TIME and
28965         `AC_REQUIRE'ing jm_CHECK_TYPE_STRUCT_TIMESPEC provoked a but
28966         in autoconf whereby the expansion of the latter ended up preceding
28967         the expansion of its prerequisite, AC_HEADER_TIME.
28968         Reported by Volker Borchert.
28969
28970 2000-02-03  Jim Meyering  <meyering@lucent.com>
28971
28972         * m4/prereq.m4 (jm_PREREQ_READUTMP): Check for utmpxname.
28973
28974 2000-02-03  Jim Meyering  <meyering@lucent.com>
28975
28976         * lib/readutmp.c (read_utmp): Guard with `#ifdef UTMP_NAME_FUNCTION',
28977         rather than with `#if HAVE_UTMPNAME'.
28978
28979 2000-02-02  Jim Meyering  <meyering@lucent.com>
28980
28981         * m4/prereq.m4 (jm_PREREQ_ADDEXT): Fix typo that resulted in no
28982         definition of HAVE_PATHCONF: s/AC_CHECK_FUNC/AC_CHECK_FUNCS/.
28983         Reported by Eli Zaretskii.
28984
28985 2000-02-01  Jim Meyering  <meyering@lucent.com>
28986
28987         * lib/readutmp.h (UT_USER): Add parens.  From Andreas Schwab.
28988
28989 2000-01-31  Jim Meyering  <meyering@lucent.com>
28990
28991         * m4/check-decl.m4 (jm_CHECK_DECLS): Add nanosleep to the list of
28992         functions.  Add the time.h and sys/time.h headers along with the
28993         AC_REQUIRE'ment of AC_HEADER_TIME.
28994
28995 2000-01-31  Jim Meyering  <meyering@lucent.com>
28996
28997         * lib/nanosleep.h (nanosleep): Guard declaration with
28998         `#if ! HAVE_DECL_NANOSLEEP'.
28999         Without this, OFS gets a redeclaration error for rpl_nanosleep, due to
29000         the declaration in that vendor's sys/timers.h.
29001         Reported by Christian Krackowizer.
29002
29003         * lib/quotearg.c (ISASCII): Add #undef and move definition to follow
29004         inclusion of wctype.h to work around Solaris 2.6 namespace pollution.
29005         (ISPRINT): Likewise.
29006         Reported by Tom Tromey.
29007
29008 2000-01-30  Jim Meyering  <meyering@lucent.com>
29009
29010         * m4/lib-check.m4: Clean up some kludgy old shadow password tests.
29011
29012         * m4/prereq.m4 (utmp_includes): Define.
29013         Check for ut_user and ut_name members in both struct utmpx
29014         and struct utmp.
29015
29016 2000-01-30  Jim Meyering  <meyering@lucent.com>
29017
29018         * lib/readutmp.c (extract_trimmed_name): Use UT_USER instead of
29019         hard-coding uses of ->ut_name.  The latter doesn't work with new Linux
29020         header files where only utmpx.ut_user is declared.
29021
29022         * lib/readutmp.h (UT_USER): Define.
29023
29024 2000-01-29  Jim Meyering  <meyering@lucent.com>
29025
29026         * m4/lib-check.m4: New file containing library-related checks from
29027         fileutils and sh-utils (textutils had none).
29028
29029 2000-01-28  Jim Meyering  <meyering@lucent.com>
29030
29031         * m4/perl.m4: Change format of warning message to look more like that
29032         from the missing script.  Suggestion from François Pinard.
29033
29034 2000-01-25  Jim Meyering  <meyering@lucent.com>
29035
29036         * m4/timespec.m4: Require AC_HEADER_TIME, and include sys/time.h as
29037         well as time.h in the compile check.
29038         * m4/nanosleep.m4: Require AC_HEADER_TIME rather than simply using it.
29039         Fix typo in cross-compiling case: s/yes/no/.
29040
29041 2000-01-23  Jim Meyering  <meyering@lucent.com>
29042
29043         * m4/jm-macros.m4: Move df-related tests here from
29044         fileutils/configure.in
29045
29046         * m4/ls-mntd-fs.m4: s/list_mounted_fs/ac_list_mounted_fs/
29047         (jm_LIST_MOUNTED_FILESYSTEMS): Take two parameters.
29048
29049         * m4/fsusage.m4: New file.  Extracted from fileutils/configure.in.
29050         s/space/ac_fsusage_space/.
29051         (jm_FILE_SYSTEM_USAGE): Take two parameters.
29052
29053         * m4/ftruncate.m4: New file (derived from part of
29054         fileutils/configure.in).
29055         * m4/jm-macros.m4 (jm_FUNC_FTRUNCATE): AC_REQUIRE it.
29056         (jm_CHECK_ALL_TYPES): Require AC_HEADER_MAJOR and AC_HEADER_DIRENT.
29057
29058         * m4/jm-macros.m4 (OPTIONAL_BIN_PROGS, OPTIONAL_BIN_ZCRIPTS, MAN):
29059         AC_SUBST these here, rather than just in sh-util/configure.in, so
29060         that the now-shared-by-fileutils-and-textutils lib/Makefile.am are
29061         all the same.
29062         (AM_FUNC_OBSTACK): Add (from fileutils/configure.in).
29063         (AC_CHECK_FUNCS): Merge all checks from fileutils, textutils, sh-utils.
29064         (AM_FUNC_STRTOD): Added (from textutils', sh-utils' configure.in).
29065         (AC_SUBST(POW_LIBM)): Likewise.
29066         (AC_SUBST(DF_PROG)): Moved from fileutils/configure.in.
29067
29068 2000-01-23  Jim Meyering  <meyering@lucent.com>
29069
29070         * lib/Makefile.am (libfetish_a_SOURCES): Remove explicit mention of
29071         obstack.c.
29072
29073 2000-01-22  Jim Meyering  <meyering@lucent.com>
29074
29075         * m4/jm-macros.m4: Call AC_PROG_CC_STDC just before AC_C_CONST.
29076
29077         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): Add wctype.h.
29078
29079         * m4/jm-macros.m4 (AC_CHECK_HEADERS): Add checks from fileutils'
29080         configure.in
29081         (AC_CHECK_HEADERS): Likewise for sh-utils.
29082         (AC_CHECK_HEADERS): Likewise for textutils.
29083         Merge the three lists of headers.
29084
29085         * m4/prereq.m4 (jm_PREREQ_ADDEXT): New macro.  Parts moved here
29086         from fileutils' configure.in.
29087
29088         * m4/decl.m4: Remove kludgy `test -z $ac_...AC_CHECK_HEADERS(...)'
29089         code. Moved tests into their own function (_jm_DECL_HEADERS) in
29090         check-decl.m4.
29091
29092         * m4/check-decl.m4: Use #if rather than #ifdef.
29093         Add HAVE_DECL_STRTOUL and HAVE_DECL_STRTOULL.
29094         (jm_CHECK_DECLARATIONS): Add strtoul strtoull.
29095         (_jm_DECL_HEADERS): Define new function.
29096         (jm_CHECK_DECLARATIONS): Require it.
29097
29098 2000-01-22  Jim Meyering  <meyering@lucent.com>
29099
29100         * lib/strtoumax.c: [! HAVE_DECL_STRTOUL]: Declare strtoul.
29101         [! HAVE_DECL_STRTOULL]: Declare strtoull.
29102         Required for some AIX systems.  Reported by Christian Krackowizer.
29103         [TESTING] (main): New function.
29104
29105         1997-10-17  Eli Zaretskii  <eliz@is.elta.co.il>
29106         * lib/dirname.c (dir_name): Support for DOS-style file names with drive
29107         letters.
29108
29109         * lib/quotearg.c [HAVE_WCTYPE_H]: Include <wctype.h> for decl of
29110         iswprint.
29111
29112         * lib/strverscmp.c (ISDIGIT): Define.
29113         (strverscmp): Use ISDIGIT, not isdigit.
29114
29115 2000-01-19  Jim Meyering  <meyering@lucent.com>
29116
29117         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Include <sys/time.h>, too.
29118         Use AC_HEADER_TIME.  Volker Borchert reported that OpenBSD-2.3/sparc
29119         defines `struct timespec' in <sys/time.h>
29120
29121         * m4/c-bs-a.m4: Remove uses of changequote altogether.
29122         Thanks to Akim for explaining.
29123
29124 2000-01-17  Paul Eggert  <eggert@twinsun.com>
29125
29126         * lib/nanosleep.c (nanosleep):
29127         Don't use SA_INTERRUPT to decide whether to call sigaction, as
29128         POSIX.1 doesn't require SA_INTERRUPT and some systems
29129         (e.g. Solaris 7) don't define it.  Use SA_NOCLDSTOP instead;
29130         it's been part of POSIX.1 since day 1 (in 1988).
29131
29132 2000-01-17  Jim Meyering  <meyering@lucent.com>
29133
29134         * lib/interlock: Remove unused file.  Reported by François Pinard.
29135
29136 2000-01-16  Paul Eggert  <eggert@twinsun.com>
29137
29138         * lib/quotearg.c (quotearg_buffer_restyled): Do not quote
29139         alert, backslash, formfeed, and vertical tab unnecessarily in
29140         shell quoting style.
29141
29142 2000-01-16  Jim Meyering  <meyering@lucent.com>
29143
29144         * m4/jm-macros.m4: Require jm_FUNC_GROUP_MEMBER, jm_FUNC_PUTENV,
29145         AM_FUNC_ERROR_AT_LINE, jm_FUNC_GNU_STRFTIME, jm_FUNC_MKTIME,
29146         jm_FUNC_GETGROUPS AC_FUNC_VPRINTF, AC_FUNC_ALLOCA,
29147         AM_FUNC_GETLOADAVG, and jm_SYS_PROC_UPTIME.
29148
29149 2000-01-16  Jim Meyering  <meyering@lucent.com>
29150
29151         * m4/c-bs-a.m4: Use `changequote(<<,>>)', rather than `changequote(, )'
29152         because the latter didn't work.
29153
29154 2000-01-15  Jim Meyering  <meyering@lucent.com>
29155
29156         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add gethostname and getusershell.
29157         (AC_REPLACE_FUNCS): Add memcpy and memset.
29158         Add these, too: stime strcspn stpcpy strstr strtol strtoul.
29159         Add strpbrk.
29160         Add these: euidaccess memcmp mkdir rmdir rpmatch strndup strverscmp.
29161
29162 2000-01-12  Jim Meyering  <meyering@lucent.com>
29163
29164         * m4/prereq.m4 (jm_PREREQ_CANON_HOST): New macro.
29165         (jm_PREREQ): Use it.
29166         (jm_PREREQ_READUTMP): New macro.
29167         (jm_PREREQ): Use it.
29168
29169 2000-01-11  Paul Eggert  <eggert@twinsun.com>
29170
29171         Quote multibyte characters correctly.
29172         * m4/c-bs-a.m4: New file.
29173         * m4/prereq.m4 (jm_PREREQ_QUOTEARG): New macro.
29174         (jm_PREREQ): Use it.
29175
29176 2000-01-11  Paul Eggert  <eggert@twinsun.com>
29177
29178         * m4/uintmax_t.m4: Port to autoconf 2.13.
29179
29180 2000-01-08  Jim Meyering  <meyering@ascend.com>
29181
29182         * m4/strerror_r.m4 (jm_FUNC_STRERROR_R): New file/macro.
29183         * m4/jm-macros.m4 (jm_FUNC_STRERROR_R): Require it.
29184
29185 2000-01-04  Jim Meyering  <meyering@ascend.com>
29186
29187         * m4/d-type.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_TYPE): Rename from
29188         jm_STRUCT_DIRENT_D_TYPE.
29189         * m4/d-ino.m4 (jm_CHECK_TYPE_STRUCT_DIRENT_D_INO): Rename from
29190         jm_STRUCT_DIRENT_D_INO.
29191         * m4/utimbuf.m4 (jm_CHECK_TYPE_STRUCT_UTIMBUF): Rename from
29192         jm_STRUCT_UTIMBUF.
29193         * m4/jm-macros.m4: Reflect s/jm_STRUCT_/jm_CHECK_TYPE_STRUCT_/
29194         renamings.
29195         * m4/utime.m4: Likewise.
29196
29197         * m4/timespec.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): New file, macro.
29198         * m4/jm-macros.m4 (jm_CHECK_TYPE_STRUCT_TIMESPEC): Require it.
29199
29200 2000-01-03  Paul Eggert  <eggert@twinsun.com>
29201
29202         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): Search for nanosleep in -lrt
29203         (for Solaris 7) and in -lposix4 (for Solaris 2.5.1).
29204
29205 2000-01-02  Jim Meyering  <meyering@ascend.com>
29206
29207         * m4/search-libs.m4: Escape `$' in $3 of dnl comment.  I no longer
29208         remember if this is necessary.
29209
29210 1999-12-26  Jim Meyering  <meyering@ascend.com>
29211
29212         * m4/jm-macros.m4: Use it here.
29213         * m4/nanosleep.m4 (jm_FUNC_NANOSLEEP): New file/macro.
29214
29215 1999-12-23  Jim Meyering  <meyering@ascend.com>
29216
29217         * m4/jm-macros.m4: Check for clock_gettime (moved from
29218         fileutils/configure.in)
29219         Check for gettimeofday.
29220
29221 1999-12-20  Jim Meyering  <meyering@ascend.com>
29222
29223         * m4/strftime.m4: Remove kludge, now that I'm using the fixed
29224         autoconf-2.14a-1999-12-20.
29225
29226 1999-12-19  Jim Meyering  <meyering@ascend.com>
29227
29228         * m4/lstat-slash.m4: New file.
29229         * m4/jm-macros.m4: Use the new macro:
29230         jm_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK.
29231
29232 1999-12-07  Jim Meyering  <meyering@ascend.com>
29233
29234         * m4/perl.m4: Require that File::Compare be available, too.
29235         Too many systems seem to lack it.
29236
29237         * m4/strftime.m4: Add checks for most of the cpp macros tested in
29238         GNU's strftime.c.  Prompted by a patch from Paul Eggert.
29239
29240 1999-11-18  Paul Eggert  <eggert@twinsun.com>
29241
29242         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around a
29243         problem with the QNX 4.25 shell, which doesn't propagate exit
29244         status of failed commands inside shell assignments.
29245
29246 1999-11-17  Jim Meyering  <meyering@ascend.com>
29247
29248         * m4/gettext.m4: Use new AC_CONFIG_LINKS in place of AC_LINK_FILES.
29249
29250 1999-11-07  Jim Meyering  <meyering@ascend.com>
29251
29252         * m4/getloadavg.m4: Add `, 1, [FIXME]' to each use of AC_DEFINE.
29253
29254 1999-11-06  Jim Meyering  <meyering@ascend.com>
29255
29256         * m4/link-follow.m4 (jm_AC_FUNC_LINK_FOLLOWS_SYMLINK): New file/macro.
29257         * m4/jm-macros.m4 (jm_MACROS): Use it here.
29258
29259 1999-11-05  Jim Meyering  <meyering@ascend.com>
29260
29261         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Move some tests from
29262         configure.in of textutils, fileutils, and sh-utils into this one
29263         (shared between those packages) file.
29264         Use `AC_CHECK_MEMBERS((struct stat.st_blksize))' instead of deprecated
29265         AC_STRUCT_ST_BLKSIZE.
29266
29267 1999-11-03  Jim Meyering  <meyering@ascend.com>
29268
29269         * m4/ssize_t.m4: Remove file.  No longer needed since the new version
29270         of AC_CHECK_TYPE checks includes unistd.h.
29271         * m4/jm-macros.m4: Use straight `AC_CHECK_TYPE(ssize_t, int)'.
29272         Suggestion from Akim Demaille.
29273
29274 1999-10-30  Jim Meyering  <meyering@ascend.com>
29275
29276         * m4/uintmax_t.m4: Require 2.14a.  Remove backslash before backtick in
29277         m4-quoted string.
29278         * m4/ls-mntd-fs.m4: Likewise.
29279         * m4/jm-macros.m4: Likewise.  Also, use AC_TYPE_SSIZE_T instead
29280         * m4/jm-winsz1.m4: Likewise.
29281
29282         * m4/const.m4: Remove file, since the fix made it into the experimental
29283         version of autoconf.
29284         * m4/mktime.m4: Likewise.
29285
29286         * m4/check-type.m4: Remove file, now that the latest version of
29287         AC_CHECK_TYPE takes a third arg to specify additional #includes.
29288
29289         * m4/ssize_t.m4: New file, requires experimental version of autoconf.
29290         * m4/jm-macros.m4: Use new AC_TYPE_SSIZE_T instead of my hacked
29291         AC_CHECK_TYPE.
29292
29293 1999-10-04  Jim Meyering  <meyering@ascend.com>
29294
29295         * m4/jm-macros.m4: Don't require autoconf-2.14.1.
29296
29297 1999-09-22  Paul Eggert  <eggert@twinsun.com>
29298
29299         * m4/largefile.m4 (AC_SYS_LARGEFILE_FLAGS): Work around GCC
29300         2.95.1 bug with HP-UX 10.20.
29301
29302 1999-09-17  Jim Meyering  <meyering@ascend.com>
29303
29304         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add strdup.
29305         Paul Nevai reported a link failure on a NeXT CUBE with NeXTSTEP 3.3
29306         due to missing strdup (against sh-utils-2.0).
29307
29308 1999-08-29  Jim Meyering  <meyering@ascend.com>
29309
29310         * m4/jm-macros.m4: Require jm_BISON.
29311         * m4/bison.m4: New file.
29312
29313 1999-08-17  Paul Eggert  <eggert@twinsun.com>
29314
29315         * m4/largefile.m4 (AC_SYS_LARGEFILE): Fix typo: missing comma
29316         in value for _FILE_OFFSET_BITS, which broke ports to HP-UX 10.20.
29317
29318 1999-08-05  Jim Meyering  <meyering@ascend.com>
29319
29320         * m4/getline.m4: Rename test file from conftestdata to conftest.data
29321         to avoid conflicts with `conftest' on 8+3 filesystems.
29322         Suggestion from Eli Zaretskii.
29323
29324 1999-08-04  Jim Meyering  <meyering@ascend.com>
29325
29326         * m4/jm-macros.m4: Move a 4-line block of code from the configure.in of
29327         fileutils and sh-utils (textutils's getline test was inadequate).
29328         (AM_FUNC_GETLINE): Run this test.
29329         (AC_CHECK_FUNCS): Check for getdelim.
29330         Reported by Bob Proulx.
29331
29332 1999-08-02  Jim Meyering  <meyering@ascend.com>
29333
29334         * m4/jm-macros.m4: Add a comment.
29335
29336 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29337
29338         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): Check whether
29339         <inttypes.h> defines strtoumax as a macro (and not as a
29340         function).
29341
29342 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29343
29344         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): Make sure
29345         that we can shift, multiply and divide unsigned long long
29346         values; Ultrix cc can't do it.
29347
29348 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29349
29350         * m4/mktime.m4: New file, which is a preview of what should appear
29351         in the next public autoconf release.
29352
29353 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29354
29355         * m4/lfs.m4: Remove this file.
29356         * m4/largefile.m4: New file.  It contains the old contents of
29357         lfs.m4, except that all names with prefix AC_LFS have been
29358         changed to use the prefix AC_SYS_LARGEFILE instead, to be
29359         compatible with future autoconf versions.  Also, some minor m4
29360         quoting problems have been fixed.
29361
29362 1999-08-01  Paul Eggert  <eggert@twinsun.com>
29363
29364         * m4/gettext.m4 (AM_WITH_NLS): Remove unnecessary lines.
29365         Fix typo: $nls_cv_header_intl was misspelled as $nsl_cv_header_intl.
29366         (AM_GNU_GETTEXT): Fix problem with brackets and m4 quoting,
29367         and simplify the shell code.
29368
29369 1999-08-01  Jim Meyering  <meyering@ascend.com>
29370
29371         * m4/mktime.m4 (AC_FUNC_MKTIME): Undefine to avoid syntax errors from
29372         m4.
29373
29374 1999-07-20  Jim Meyering  <meyering@ascend.com>
29375
29376         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memmove.
29377
29378 1999-07-15  Jim Meyering  <meyering@ascend.com>
29379
29380         * m4/jm-macros.m4 (AC_CHECK_FUNCS): Check for getpagesize.
29381
29382 1999-05-22  Jim Meyering  <meyering@ascend.com>
29383
29384         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add memchr.
29385
29386 1999-05-20  Jim Meyering  <meyering@ascend.com>
29387
29388         * m4/search-libs.m4 [AC_SEARCH_LIBS]: Quote name in undefine.
29389         Add a colon after each `then' in case $4 is empty.
29390
29391 1999-05-16  Jim Meyering  <meyering@ascend.com>
29392
29393         * m4/search-libs.m4: New file to override autoconf's AC_SEARCH_LIBS.
29394
29395 1999-05-10  Jim Meyering  <meyering@ascend.com>
29396
29397         * m4/jm-mktime.m4: Reflect renaming: AM_FUNC_MKTIME -> AC_FUNC_MKTIME.
29398
29399         * m4/jm-macros.m4: Require 2.14.1, since we use newly-renamed
29400         AC_FUNC_MKTIME.
29401
29402 1999-05-10  Andreas Schwab  <schwab@issan.cs.uni-dortmund.de>
29403
29404         * m4/jm-mktime.m4, putenv.m4: Fix typos in config.h comments.
29405
29406 1999-05-04  Paul Eggert  <eggert@twinsun.com>
29407
29408         * m4/lfs.m4 (AC_LFS): -n32, -o32, and -n64 should be in CFLAGS,
29409         not CPPFLAGS, so that linking works correctly in IRIX.
29410
29411 1999-04-30  Paul Eggert  <eggert@twinsun.com>
29412
29413         * m4/jm-macros.m4 (AC_REPLACE_FUNCS): Add dup2.
29414
29415 1999-04-20  Paul Eggert  <eggert@twinsun.com>
29416
29417         * m4/uintmax_t.m4 (jm_AC_TYPE_UINTMAX_T): Move unsigned long
29418         long check into new jm_AC_TYPE_UNSIGNED_LONG_LONG macro.
29419         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): Require
29420         jm_AC_TYPE_UNSIGNED_LONG_LONG.
29421         * m4/ulonglong.m4 (jm_AC_TYPE_UNSIGNED_LONG_LONG): New file/macro.
29422
29423         * m4/lfs.m4: Port to AIX and HP-UX.  Support cross-compilation.
29424
29425 1999-04-20  Jim Meyering  <meyering@ascend.com>
29426
29427         * m4/xstrtoumax.m4: Require jm_AC_TYPE_UNSIGNED_LONG_LONG.
29428         AC_REPLACE xstroull if necessary.  From Paul Eggert.
29429         (AC_CHECK_FUNCS): Remove strtoull, strtoumax, strtouq.
29430
29431 1999-04-18  Jim Meyering  <meyering@ascend.com>
29432
29433         * m4/xstrtoumax.m4 (jm_AC_PREREQ_XSTRTOUMAX): New file/macro.
29434         * m4/jm-macros.m4: Use it.
29435
29436 1999-04-06  Jim Meyering  <meyering@ascend.com>
29437
29438         * m4/strftime.m4: Remove test for %f.
29439
29440 1999-03-29  Jim Meyering  <meyering@ascend.com>
29441
29442         * m4/jm-macros.m4 (jm_CHECK_ALL_TYPES): New macro, contains the
29443         superset of the AC_TYPE_* checks in the textutils, fileutils,
29444         and sh-utils, plus AC_TYPE_PID_T.  Paul Eggert suggested adding
29445         AC_TYPE_PID_T.
29446
29447 1999-03-28  Jim Meyering  <meyering@ascend.com>
29448
29449         * m4/jm-macros.m4: Define GNU_PACKAGE here.
29450         Be sure to AC_SUBST it, once again, so that @GNU_PACKAGE@ is
29451         replaced e.g., in the *.sh files of the sh-utils.
29452
29453 1999-03-20  Jim Meyering  <meyering@ascend.com>
29454
29455         * m4/jm-macros.m4: s/jm_WITH_REGEX/jm_INCLUDED_REGEX/.
29456         * m4/regex.m4 (jm_INCLUDED_REGEX): Rename from jm_WITH_REGEX.
29457         Don't depend on AM_GLIBC.  Suggestions from Alain Magloire.
29458
29459 1999-03-19  Jim Meyering  <meyering@ascend.com>
29460
29461         * m4/jm-winsz1.m4 (jm_WINSIZE_IN_PTEM): New macro.
29462
29463 1999-03-12  Jim Meyering  <meyering@ascend.com>
29464
29465         * m4/jm-macros.m4: Use AC_FUNC_SETVBUF_REVERSED.
29466
29467 1999-03-07  Jim Meyering  <meyering@ascend.com>
29468
29469         * m4/jm-glibc-io.m4: Use only those *_unlocked macros that are
29470         declared.
29471
29472 1999-02-17  Jim Meyering  <meyering@ascend.com>
29473
29474         * m4/gettext.m4 (AM_GNU_GETTEXT): Do `changequote' around use of
29475         brackets in macro definition.  From Eli Zaretskii and Alain Magloire.
29476
29477 1999-02-07  Jim Meyering  <meyering@ascend.com>
29478
29479         * m4/group-member.m4: New file -- extracted from sh-utils'
29480         configure.in.
29481
29482         1999-02-05  Eli Zaretskii  <eliz@is.elta.co.il>
29483         * m4/gettext.m4: Support DOS-style d:/foo/bar absolute file names.
29484
29485 1999-02-06  Jim Meyering  <meyering@ascend.com>
29486
29487         * m4/chown.m4: Use `AC_SUBST(LIBOBJS)' since we set LIBOBJS.
29488         * m4/fnmatch.m4: Likewise.
29489         * m4/getgroups.m4: Likewise.
29490         * m4/lstat.m4: Likewise.
29491         * m4/malloc.m4: Likewise.
29492         * m4/putenv.m4: Likewise.
29493         * m4/realloc.m4: Likewise.
29494         * m4/regex.m4: Likewise.
29495         * m4/stat.m4: Likewise.
29496         * m4/strftime.m4: Likewise.
29497         Suggestion from Alain Magloire.
29498
29499         * m4/chown.m4: Use `.$ac_objext', not `.o'.
29500         * m4/fnmatch.m4: Likewise.
29501         * m4/getgroups.m4: Likewise.
29502         * m4/getline.m4: Likewise.
29503         * m4/lstat.m4: Likewise.
29504         * m4/malloc.m4: Likewise.
29505         * m4/memcmp.m4: Likewise.
29506         * m4/putenv.m4: Likewise.
29507         * m4/realloc.m4: Likewise.
29508         * m4/regex.m4: Likewise.
29509         * m4/stat.m4: Likewise.
29510         * m4/strftime.m4: Likewise.
29511         Suggestion from Alain Magloire.
29512
29513         * m4/jm-macros.m4: Actually invoke jm_WITH_REGEX now that it requires
29514         an argument.
29515
29516         * m4/regex.m4: Add a run-time Test for proper operation of
29517         re_compile_pattern.
29518
29519 1999-01-31  Jim Meyering  <meyering@ascend.com>
29520
29521         * m4/getloadavg.m4: Check for locale.h and the function, setlocale.
29522
29523 1999-01-30  Jim Meyering  <meyering@ascend.com>
29524
29525         * m4/check-type.m4: Use 3-arg form of AC_DEFINE.
29526
29527         * m4/jm-mktime.m4: Make this a wrapper around the official
29528         AM_FUNC_MKTIME rather than my private copy, now that the official one
29529         is up to date.
29530         * m4/mktime.m4: Remove file.
29531
29532         * m4/getloadavg.m4: Use 3-arg form of AC_DEFINE.
29533         * m4/uptime.m4: Likewise.
29534         * m4/uintmax_t.m4: Likewise.
29535
29536 1999-01-28  Jim Meyering  <meyering@ascend.com>
29537
29538         * m4/jm-macros.m4: Use jm_AFS.
29539         * m4/afs.m4: New file (from fileutils' configure.in).
29540
29541         * m4/assert.m4: Use the 3-argument forms of AC_DEFINE* macros.
29542         * m4/chown.m4: Likewise.
29543         * m4/d-ino.m4: Likewise.
29544         * m4/d-type.m4: Likewise.
29545         * m4/fnmatch.m4: Likewise.
29546         * m4/getgroups.m4: Likewise.
29547         * m4/gettext.m4: Likewise.
29548         * m4/jm-mktime.m4: Likewise.
29549         * m4/jm-winsz2.m4: Likewise.
29550         * m4/lcmessage.m4: Likewise.
29551         * m4/ls-mntd-fs.m4: Likewise.
29552         * m4/malloc.m4: Likewise.
29553         * m4/memcmp.m4: Likewise.
29554         * m4/putenv.m4: Likewise.
29555         * m4/realloc.m4: Likewise.
29556         * m4/st_mtim.m4: Likewise.
29557         * m4/strftime.m4: Likewise.
29558
29559 1999-01-16  Jim Meyering  <meyering@ascend.com>
29560
29561         * m4/jm-macros.m4 (ARGMATCH_DIE): Define.
29562         (ARGMATCH_DIE_DECL): Define.
29563
29564 1999-01-12  Jim Meyering  <meyering@ascend.com>
29565
29566         * m4/Makefile.am.in: Rewrite to avoid using fmt.
29567         Reported by Lars Hecking.
29568
29569 1999-01-10  Jim Meyering  <meyering@ascend.com>
29570
29571         * m4/fstypename.m4: Use the new 3-arg form of AC_DEFINE instead of my
29572         gross kludge.
29573         * m4/inttypes_h.m4: Likewise.
29574         * m4/lstat.m4: Likewise.
29575         * m4/malloc.m4: Likewise.
29576         * m4/readdir.m4: Likewise.
29577         * m4/realloc.m4: Likewise.
29578         * m4/st_dm_mode.m4: Likewise.
29579         * m4/stat.m4: Likewise.
29580         * m4/utimbuf.m4: Likewise.
29581         * m4/utimes.m4: Likewise.
29582
29583         * m4/check-decl.m4: Use the new 3-arg form of AC_DEFINE instead of the
29584         AC_CHECK_FUNCS hack.  Now, it's still a hack, but at least the
29585         comments in config.h.in are meaningful.
29586
29587         * m4/jm-macros.m4: Require autoconf-2.13 here.
29588
29589         * m4/regex.m4: By default, don't use the included regex.c on systems
29590         with glibc 2.  Suggestion from Uli Drepper.
29591
29592 1999-01-02  Jim Meyering  <meyering@ascend.com>
29593
29594         * m4/jm-macros.m4: Replace strcasecmp and strncasecmp.
29595
29596 1998-12-18  Jim Meyering  <meyering@ascend.com>
29597
29598         * m4/Makefile.am.in (Makefile.am): Simplify rule.
29599         Based on a suggestion from Lars Hecking.
29600
29601 1998-11-16  Paul Eggert  <eggert@twinsun.com>
29602
29603         * m4/lfs.m4 (AC_LFS): Add support for HP-UX 10.20 and HP-UX 11.
29604
29605 1998-11-16  Jim Meyering  <meyering@ascend.com>
29606
29607         * m4/lfs.m4: Double-quote the `uname...` expression.
29608
29609 1998-11-14  Jim Meyering  <meyering@ascend.com>
29610
29611         * m4/lstat.m4: Correct comment.  POSIX does not permit it to succeed.
29612         * m4/stat.m4: Likewise.
29613
29614 1998-11-03  Jim Meyering  <meyering@ascend.com>
29615
29616         * m4/stat.m4: Rewrite to set HAVE_STAT_EMPTY_STRING_BUG.
29617         * m4/lstat.m4: Rewrite to set HAVE_LSTAT_EMPTY_STRING_BUG.
29618
29619 1998-10-18  Jim Meyering  <meyering@ascend.com>
29620
29621         * m4/check-decl.m4 (jm_CHECK_DECL_LOCALTIME_R): Remove macro.
29622
29623 1998-10-17  Jim Meyering  <meyering@ascend.com>
29624
29625         * m4/decl.m4 (jm_CHECK_DECLARATION): Don't hard-code which headers to
29626         include, though we still hard-code the `require'-like AC_CHECK_HEADERS
29627         calls for those previously hard-coded headers.  Instead, take a new
29628         parameter.
29629         (jm_CHECK_DECLARATIONS): Reflect interface change.
29630         * m4/check-decl.m4 (jm_CHECK_DECLS): Likewise.
29631         (jm_CHECK_DECL_LOCALTIME_R): New macro.
29632
29633         * m4/mktime.m4: Test for spring-forward gap before long-running test.
29634
29635 1998-10-14  Jim Meyering  <meyering@ascend.com>
29636
29637         * m4/mktime.m4: Use the more portable "TZ=PST8PDT,M4.1.0,M10.5.0"
29638         instead of "TZ=America/Vancouver".  From Paul Eggert.
29639
29640 1998-10-11  Jim Meyering  <meyering@ascend.com>
29641
29642         * m4/mktime.m4 (jm_AM_FUNC_MKTIME): New file and macro.
29643         This adds a test for a recently added compatibility fix for mktime.c.
29644         * m4/jm-mktime.m4: Require jm_AM_FUNC_MKTIME, not AM_FUNC_MKTIME.
29645
29646 1998-09-27  Jim Meyering  <meyering@ascend.com>
29647
29648         * m4/jm-macros.m4 (jm_MACROS): Require jm_FUNC_FNMATCH.
29649
29650         * m4/fnmatch.m4 (jm_FUNC_FNMATCH): New file/macro.  Extracted from
29651         ../configure.in, including a change from Gordon Matzigkeit to allow
29652         cross-compiling for the Hurd.
29653
29654         * m4/glibc.m4: New file/macro to test for the GNU C Library
29655         versions 1 and 2.  From Gordon Matzigkeit.
29656         Indent.
29657
29658 1998-09-21  Jim Meyering  <meyering@ascend.com>
29659
29660         * m4/chown.m4: Declare locals: before, after.  From Andries Brouwer.
29661
29662 1998-08-18  Paul Eggert  <eggert@twinsun.com>
29663
29664         Port nanosecond-resolution times to UnixWare 2.1.2 and
29665         pedantic Solaris 2.6.
29666
29667         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC): Renamed from
29668         AC_STRUCT_ST_MTIM.
29669         * m4/st_mtim.m4 (AC_STRUCT_ST_MTIM_NSEC):
29670         Generate name of ns member, instead of just 1 or undef.
29671         Allow for UnixWare 2.1.2 and Solaris 2.6 if in pedantic mode.
29672
29673 1998-08-15  Jim Meyering  <meyering@ascend.com>
29674
29675         * m4/ssize_t.m4 (jm_TYPE_SSIZE_T): Remove file.
29676         * m4/check-type.m4: New file.  Replacement for AC_CHECK_TYPE.
29677         * m4/jm-macros.m4: Use the new AC_CHECK_TYPE(ssize_t, int)
29678         instead of jm_TYPE_SSIZE_T.
29679
29680 1998-08-12  Jim Meyering  <meyering@ascend.com>
29681
29682         * m4/st_dm_mode.m4: New file.  From Johan Danielsson.
29683
29684 1998-08-02  Jim Meyering  <meyering@ascend.com>
29685
29686         * m4/st_mtim.m4: Use hack to avoid having to put #undef HAVE_ST_MTIM
29687         in acconfig.h manually.
29688
29689 1998-07-31  Paul Eggert  <eggert@twinsun.com>
29690
29691         * m4/st_mtim.m4: New file.
29692
29693 1998-07-28  Jim Meyering  <meyering@ascend.com>
29694
29695         * m4/utimes.m4: Undef stat.
29696
29697 1998-07-25  Jim Meyering  <meyering@ascend.com>
29698
29699         * m4/utime.m4 (jm_FUNC_UTIME): New file and macro.
29700         * m4/utimes.m4 (jm_FUNC_UTIMES_NULL): New file and macro.
29701
29702 1998-07-09  Manfred Hollstein  <manfred@s-direktnet.de>
29703
29704         * m4/chown.m4 (jm_FUNC_CHOWN): Add a check to verify that the
29705         uid and gid actually remain unchanged.
29706
29707 1998-07-07  Jim Meyering  <meyering@ascend.com>
29708
29709         * m4/jm-glibc-io.m4: Remove fclose_unlocked.
29710
29711 1998-07-04  Jim Meyering  <meyering@ascend.com>
29712
29713         * m4/regex.m4: Use syscmd, ifelse, and sysval.  Mainly as an exercise
29714         to prove that this macro can be used in packages without regex.c.
29715
29716 1998-07-04  Andreas Schwab  <schwab@issan.informatik.uni-dortmund.de>
29717
29718         * m4/gettext.m4 (AM_WITH_NLS): Remove intl/libintl.h if <libintl.h>
29719         is to be used.
29720
29721 1998-07-03  Jim Meyering  <meyering@ascend.com>
29722
29723         * m4/gettext.m4: Add -lintl if it's found to be necessary.
29724
29725         * m4/gettext.m4: New file -- from gettext-0.10.35.
29726         * m4/lcmessage.m4: Likewise.
29727         * m4/progtest.m4: Likewise.
29728
29729         * m4/regex.m4 (jm_WITH_REGEX): New file and macro.
29730         * m4/jm-macros.m4: Require the new macro.
29731
29732 1998-06-29  Jim Meyering  <meyering@ascend.com>
29733
29734         * m4/fstypename.m4: Include sys/param.h.  NetBSD 1.3.1 requires this
29735         for the definition of NGROUPS (used in a system header included
29736         by sys/mount.h).
29737
29738 1998-06-28  Jim Meyering  <meyering@ascend.com>
29739
29740         * m4/ls-mntd-fs.m4: New file.
29741         * m4/fstypename.m4: New file.
29742
29743         * m4/jm-macros.m4: Require the new macro.
29744         * m4/jm-glibc-io.m4: New file.
29745
29746 1998-05-19  Jim Meyering  <meyering@ascend.com>
29747
29748         * m4/jm-macros.m4: Add jm_FUNC_LCHOWN.
29749         * m4/lchown.m4: New file.
29750
29751         * m4/Makefile.am.in: New file.
29752         * m4/Makefile.am (Makefile.am): Depend on Makefile.am.in.
29753
29754 1998-05-14  Jim Meyering  <meyering@ascend.com>
29755
29756         * m4/Makefile.am (EXTRA_DIST): Add them.
29757         * m4/jm-macros.m4: New file.
29758         * m4/utimbuf.m4: New file.
29759
29760 1998-05-12  Jim Meyering  <meyering@ascend.com>
29761
29762         * m4/Makefile.am (EXTRA_DIST): Add isc-posix.m4.
29763
29764 1998-05-11  Jim Meyering  <meyering@ascend.com>
29765
29766         * m4/isc-posix.m4: New file.
29767
29768 1998-05-10  Jim Meyering  <meyering@ascend.com>